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]

Bad profiling code from gcc-3.2 for m68k-linux


I'm trying to build a m68k-linux gcc compiler for coldfire, and its
producing the follwoing code sequence for profiling:

tanMp:
	link.w %a6,#-332
	move.l %d2,-(%sp)
	.data
	.align	2
.LP1:
	.long	0
	.text
	lea (.LP1,%pc),%a1
	jbsr _mcount

The lea doesn't look right.  I'm assuming its trying to put the
address of .LP1 into %a1 before calling _mcount.  If so, that syntax
looks like its placing the *sum* of .LP1 and %pc into %a1.

Should this be:

	lea (.LP1@PLTPC,%pc),%a1

and what does @PLTPC (as well as @GOTPC, @GOT) mean?

-- 
Peter Barada                                   Peter.Barada@motorola.com
Wizard                                         781-852-2768 (direct)
WaveMark Solutions(wholly owned by Motorola)   781-270-0193 (fax)


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