Mark __aeabi_lmul section as allocatable and executable (#722)
When using a linker script which does not provide a .time_critical. section that is marked "ax" and wrongly define PICO_INT64_OPS_IN_RAM=1 this would generate a malformed executable with strange runtime bugs in the worst case.
This commit is contained in:
parent
b7e82b638a
commit
bc3484e793
@ -10,11 +10,16 @@
|
||||
|
||||
#include "pico/asm_helper.S"
|
||||
|
||||
.macro int64_section name
|
||||
#if PICO_INT64_OPS_IN_RAM
|
||||
.section RAM_SECTION_NAME(__aeabi_lmul)
|
||||
.section RAM_SECTION_NAME(\name), "ax"
|
||||
#else
|
||||
.section SECTION_NAME(__aeabi_lmul)
|
||||
.section SECTION_NAME(\name), "ax"
|
||||
#endif
|
||||
.endm
|
||||
|
||||
int64_section __aeabi_lmul
|
||||
|
||||
wrapper_func __aeabi_lmul
|
||||
muls r1, r2
|
||||
muls r3, r0
|
||||
@ -41,4 +46,3 @@ wrapper_func __aeabi_lmul
|
||||
adcs r1, r2
|
||||
add r1, r12
|
||||
bx lr
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user