Add PRESERVE8 directive

Add this directive to inform the linker that codes in this file preserve 8-byte alignment of the stack, thus eliminating `Warning: L6306W: '~PRES8' section irq_handler_chain.o(.data) should not use the address of 'REQ8' function irq_add_tail_to_free_list.`.
ref: https://developer.arm.com/documentation/100068/0620/Migrating-from-armasm-to-the-armclang-Integrated-Assembler/Miscellaneous-directives
This commit is contained in:
reiyawea 2024-11-28 12:05:09 +08:00 committed by GitHub
parent efe2103f9b
commit ac9b71d64c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -62,6 +62,7 @@ irq_handler_chain_slots:
.set next_slot_number, next_slot_number + 1
.endr
.eabi_attribute Tag_ABI_align_preserved, 1
irq_handler_chain_first_slot:
#ifndef __riscv
push {r0, lr} // Save EXC_RETURN token, so `pop {r0, pc}` will return from interrupt