This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Checker and Binutils 2.12


On Fri, Mar 15, 2002 at 05:33:58PM -0500, Allen Barnett wrote:
> 
> A "simplified" test case (which doesn't require Checker) can be found at 
> www.lignumcomputing.com/ld/ld-example.tar.gz (1.2k). Edit the LDPATH variable 
> in the Makefile to pick a version of ld to use.

I wan't able to reproduce your problem.  For starters, the versions of
gcc-2.95 I have easy access to wouldn't compile your testcase.  Due
to an interaction between -fprefix-function-name and naming functions
with asm ("name"), the assembly output used names like

chkr.*main

which the assembler doesn't like at all.  OK, so I fixed this gcc bug
by

--- gcc-2.95/gcc/varasm.c~	Wed Mar 28 18:32:17 2001
+++ gcc-2.95/gcc/varasm.c	Fri Mar 22 13:56:40 2002
@@ -1684,10 +1684,11 @@ assemble_name (file, name)
   char *real_name;
   tree id;
 
-  STRIP_NAME_ENCODING (real_name, name);
   if (flag_prefix_function_name 
-      && ! bcmp (real_name, CHKR_PREFIX, CHKR_PREFIX_SIZE))
-    real_name = real_name + CHKR_PREFIX_SIZE;
+      && ! bcmp (name, CHKR_PREFIX, CHKR_PREFIX_SIZE))
+    name = name + CHKR_PREFIX_SIZE;
+
+  STRIP_NAME_ENCODING (real_name, name);
 
   id = maybe_get_identifier (real_name);
   if (id)

and then the testcase compiled and linked without errors.  This was
using current CVS versions of gcc-2.95 and mainline CVS binutils.

-- 
Alan Modra
IBM OzLabs - Linux Technology Centre


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]