This is the mail archive of the libc-ports@sources.redhat.com mailing list for the libc-ports 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: [ARM] Alignment trap in dynamic linker


On Wed, Nov 18, 2009 at 03:46:53PM -0500, Daniel Jacobowitz wrote:
> Relocations are generated during compilation/assembly.  They go
> wherever the source code needs them.  So you get to figure out what
> libc/librt are putting at those addresses that generates a relocation.

Tried with gcc-4.4.1, binutils-2.20 and glibc-2.10.1
# cat /proc/cpu/alignment
Alignment trap: cat (232) PC=0x4000ac0c Instr=0xe7951002 Address=0x40230c0b FSR 0x001
Alignment trap: cat (232) PC=0x4000ac18 Instr=0xe7851002 Address=0x40230c0b FSR 0x801
Alignment trap: cat (232) PC=0x4000ac0c Instr=0xe7951002 Address=0x40231282 FSR 0x001
Alignment trap: cat (232) PC=0x4000ac18 Instr=0xe7851002 Address=0x40231282 FSR 0x801
User:           319
System:         0
Skipped:        0
Half:           0
Word:           4
Multi:          0
User faults:    3 (fixup+warn)

$arm-v4t-linux-gnueabi-objdump -R libc-2.10.1.so | grep "[2b] "
00124c0b R_ARM_RELATIVE    *ABS*
00125282 R_ARM_RELATIVE    *ABS*
$ arm-v4t-linux-gnueabi-objdump -R librt-2.10.1.so | grep "[2b] "
00005862 R_ARM_RELATIVE    *ABS*

$ arm-v4t-linux-gnueabi-objdump -h libc-2.10.1.so
Sections:
Idx Name          Size      VMA       LMA       File off  Algn
<snip>
 18 .eh_frame     0001465c  00121140  00121140  00121140  2**2
                  CONTENTS, ALLOC, LOAD, READONLY, DATA
 19 .hash         00003144  0013579c  0013579c  0013579c  2**2
                  CONTENTS, ALLOC, LOAD, READONLY, DATA

> Whatever it is, you'd probably get an unaligned fault trying to access it.

So it seems to be in the ".eh_frame" section. It is yet unclear to me where
it comes from.

	ladis


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