Skip to content

Commit b7c0e89

Browse files
author
Matthew Macovsky
committed
Fix IAR assembler errors on except.S
Fixes two errors produced on except.S by the IAR assembler (as seen in issue #13200). The first: "'ALIGN' is illegal. Use directive ALIGNROM or ALIGNRAM (the first parameter is raised to the power of 2, the second is a 32-bit fill value)." Fixed by changing ALIGN to ALIGNROM 2 to align to a 4-byte boundary (mirroring what ALIGN does in the ARM except.S). The second (on THUMB): "Must be placed inside a section" Fixed by moving THUMB after the SECTION directive so that it affects that section.
1 parent aa882d3 commit b7c0e89

File tree

1 file changed

+2
-2
lines changed
  • platform/source/TARGET_CORTEX_M/TOOLCHAIN_IAR

1 file changed

+2
-2
lines changed

platform/source/TARGET_CORTEX_M/TOOLCHAIN_IAR/except.S

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,9 +36,9 @@ FAULT_TYPE_BUS_FAULT EQU 0x30
3636
FAULT_TYPE_USAGE_FAULT EQU 0x40
3737

3838
PRESERVE8
39-
THUMB
4039

4140
SECTION .text:CODE:NOROOT(2)
41+
THUMB
4242

4343
HardFault_Handler
4444
EXPORT HardFault_Handler
@@ -111,7 +111,7 @@ Fault_Handler_Continue2
111111
#else
112112
B .
113113
#endif
114-
ALIGN
114+
ALIGNROM 2
115115
#endif
116116

117117
END

0 commit comments

Comments
 (0)