ARM embedded (-Cparmv7m), wrong field addresses when a record is declared absolute.
Original Reporter info from Mantis: Bernd
-
Reporter name: Bernd
Original Reporter info from Mantis: Bernd
- Reporter name: Bernd
Description:
The compiler calculates wrong field addresses, when a record is declared absolute. Pascal test program and generated Assembler file are attached.
main:
mov r12,r13
stmfd r13!,{r11,r14}
sub r11,r12,#4
sub r13,r13,#40
bl FPC_INITIALIZEUNITS
mov r0,#536870912 // address calculation for p1
orr r0,r0,#100
ldr r1,.Lj5
str r0,[r1]
mov r0,#536870912 // address calculation for p2.
orr r0,r0,#100 // same as for p1. Offset of 4 is missing.
ldr r1,.Lj8
str r0,[r1]
Compiler call: arm-embedded-fpc -Parm -Tembedded -Cparmv7m -Wpstm32f103re -XParm-embedded- -s test.pas
Mantis conversion info:
- Mantis ID: 21949
- OS: Embedded
- Build: 21033
- Platform: ARM/Cortex M3
- Version: 2.7.1
- Fixed in version: 3.0.0
- Fixed in revision: 28978 (#7c34dc51)