cygming.h (TARGET_STRIP_NAME_ENCODING): Don't override default.
authorDanny Smith <dannysmith@users.sourceforge.net>
Tue, 11 Sep 2007 01:38:40 +0000 (01:38 +0000)
committerDanny Smith <dannysmith@gcc.gnu.org>
Tue, 11 Sep 2007 01:38:40 +0000 (01:38 +0000)
* config/i386/cygming.h (TARGET_STRIP_NAME_ENCODING): Don't
override default.
* config/i386/i386.c (get_dllimport_decl): Don't strip
FASTCALL_PREFIX.

From-SVN: r128362

gcc/ChangeLog
gcc/config/i386/cygming.h
gcc/config/i386/i386.c

index 2ed812ce9b5588e2fc0c4f3e7b0b94b6d30b481e..e55071362f73f8217cb41f1dc8f97cef83c834fd 100644 (file)
@@ -1,3 +1,10 @@
+2007-09-11  Danny Smith  <dannysmith@users.sourceforge.net>
+
+       * config/i386/cygming.h (TARGET_STRIP_NAME_ENCODING): Don't
+       override default.
+       * config/i386/i386.c (get_dllimport_decl): Don't strip
+       FASTCALL_PREFIX.
+
 2007-09-10  Janis Johnson  <janis187@us.ibm.com>
 
        PR c/30013
index d0968e3c534528ce3e6f6a76ed69f75fe65a2374..6b1c13652df81ea376419ee1d42cb7890650cf60 100644 (file)
@@ -183,8 +183,6 @@ do {                                                                        \
    Note that we can be called twice on the same decl.  */
 
 #define SUBTARGET_ENCODE_SECTION_INFO  i386_pe_encode_section_info
-#undef  TARGET_STRIP_NAME_ENCODING
-#define TARGET_STRIP_NAME_ENCODING  i386_pe_strip_name_encoding_full
 
 /* Output a common block.  */
 #undef ASM_OUTPUT_ALIGNED_DECL_COMMON
index ce7c19b46ec59ecbd5b6eb77e4558f0c64d289cd..57fb628a48948b89c61df8af8eb260bad048b772 100644 (file)
@@ -7820,14 +7820,7 @@ get_dllimport_decl (tree decl)
 
   name = IDENTIFIER_POINTER (DECL_ASSEMBLER_NAME (decl));
   name = targetm.strip_name_encoding (name);
-  if (name[0] == FASTCALL_PREFIX)
-    {
-      name++;
-      prefix = "*__imp_";
-    }
-  else
-    prefix = "*__imp__";
-
+  prefix = name[0] == FASTCALL_PREFIX  ?  "*__imp_": "*__imp__";
   namelen = strlen (name);
   prefixlen = strlen (prefix);
   imp_name = (char *) alloca (namelen + prefixlen + 1);