Bug 14514 - arm-none-eabi cortex-m3: Cannot represent T32_OFFSET_IMM relocation in this object file format
Summary: arm-none-eabi cortex-m3: Cannot represent T32_OFFSET_IMM relocation in this o...
Status: RESOLVED INVALID
Alias: None
Product: binutils
Classification: Unclassified
Component: gas (show other bugs)
Version: 2.22
: P3 critical
Target Milestone: ---
Assignee: Not yet assigned to anyone
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-08-23 20:47 UTC by Mike
Modified: 2012-09-24 10:30 UTC (History)
1 user (show)

See Also:
Host:
Target:
Build:
Last reconfirmed:


Attachments
Assembler file which does not build. (805 bytes, application/octet-stream)
2012-08-23 20:47 UTC, Mike
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Mike 2012-08-23 20:47:43 UTC
Created attachment 6611 [details]
Assembler file which does not build.

I've build the gnu toolchain for target arm-none-eabi and cpu cortex-m3. I've adapted my application which initially was developed with IAR Embedded Workbench to be compiled with gcc. The software also has some assembler files to be assembled. When I build the software the assembler complains with the following error message:

Error: cannot represent T32_OFFSET_IMM relocation in this object file format.

The assembler instructions forcing the error always are LDR commands, e.g.:

LDR	r4, (EXC_PRI_IRQ_MASKED)	/*  lock irq */

The Problem in this case is the value represented by EXC_PRI_IRQ_MASKED. Here is the definition of this expression:

#define EXC_PRI_IRQ_MASKED  0x60

I've tried several versions of binutils (also HEAD), gcc and newLib but the problem remains.
Comment 1 Marcin Bukat 2012-09-21 12:12:45 UTC
It should be IMO
ldr r4,=EXC_PRI_IRQ_MASKED
Comment 2 Mike 2012-09-24 10:30:21 UTC
Hi,

you are right. I've fixed the assembler statements as you proposed and now it builds. Thanks!