Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 17 additions & 17 deletions arch/arm/src/common/Toolchain.defs
Original file line number Diff line number Diff line change
Expand Up @@ -74,23 +74,6 @@ ifeq ($(CONFIG_MM_KASAN_ALL),y)
ARCHOPTIMIZATION += -fsanitize=kernel-address
endif

ifeq ($(CONFIG_ARM_THUMB),y)
ARCHOPTIMIZATION += -mthumb

# GCC Manual:
# -mthumb
# ... If you want to force assembler files to be interpreted as Thumb
# code, either add a `.thumb' directive to the source or pass the
# -mthumb option directly to the assembler by prefixing it with -Wa.

ARCHOPTIMIZATION += -Wa,-mthumb

# Outputs an implicit IT block when there is a conditional instruction
# without an enclosing IT block.

ARCHOPTIMIZATION += -Wa,-mimplicit-it=always
endif

ifeq ($(CONFIG_UNWINDER_ARM),y)
ARCHOPTIMIZATION += -funwind-tables -fasynchronous-unwind-tables
endif
Expand Down Expand Up @@ -144,6 +127,23 @@ endif

ARCHCPUFLAGS += $(TOOLCHAIN_MARCH) $(TOOLCHAIN_MTUNE) $(TOOLCHAIN_MFLOAT)

ifeq ($(CONFIG_ARM_THUMB),y)
ARCHCPUFLAGS += -mthumb

# GCC Manual:
# -mthumb
# ... If you want to force assembler files to be interpreted as Thumb
# code, either add a `.thumb' directive to the source or pass the
# -mthumb option directly to the assembler by prefixing it with -Wa.

ARCHCPUFLAGS += -Wa,-mthumb

# Outputs an implicit IT block when there is a conditional instruction
# without an enclosing IT block.

ARCHCPUFLAGS += -Wa,-mimplicit-it=always
endif

# Clang toolchain

ifeq ($(CONFIG_ARM_TOOLCHAIN_CLANG),y)
Expand Down