Arm Community
Arm Community
  • Site
  • User
  • Site
  • Search
  • User
Arm Community blogs
Arm Community blogs
Tools, Software and IDEs blog Arm Compiler 6.12: Bringing in security and improved performance
  • Blogs
  • Mentions
  • Sub-Groups
  • Tags
  • Jump...
  • Cancel
More blogs in Arm Community blogs
  • AI blog

  • Announcements

  • Architectures and Processors blog

  • Automotive blog

  • Embedded and Microcontrollers blog

  • Internet of Things (IoT) blog

  • Laptops and Desktops blog

  • Mobile, Graphics, and Gaming blog

  • Operating Systems blog

  • Servers and Cloud Computing blog

  • SoC Design and Simulation blog

  • Tools, Software and IDEs blog

Tags
  • Keil MDK
  • Arm Development Studio
  • Arm Compiler 6
  • Helium
  • Arm Compiler
  • Security
  • Neoverse
Actions
  • RSS
  • More
  • Cancel
Related blog posts
Related forum threads

Arm Compiler 6.12: Bringing in security and improved performance

Peterson Quadros
Peterson Quadros
April 11, 2019
4 minute read time.

Introducing Arm Compiler 6.12 which is now available to evaluate or download as part of the below integrated toolkits:

  • Arm Development Studio 2019.0
  • Keil MDK version 5.27

Outstanding performance

As always, Arm is constantly investing to improve our optimizations and overall performance across all workloads.

Arm Compiler 6.12 delivers the highest-ever CoreMark score of 4.02 CoreMarks/MHz on a Cortex-M33. It also delivers significant improvement for range of specific workloads such as the CMSIS-DSP and CMSIS-NN software libraries.

 Performance of Cortex-M33 graph

CMSIS-DSP Performance Improvement graph Arm Compiler 6.12 over Arm Compiler 6.9 for Cortex-M33

Arm Compiler 6.12 new features

In this release, Arm Compiler 6.12 adds full support to two new features:

1. Stack protection

Arm Compiler 6.12 now provides full support for stack protection, a security feature to protect against attacks that try to exploit memory access errors, thereby improving the overall resilience and integrity of the system.

The way this is done is by inserting a guard variable onto the stack frame for each vulnerable function or for all functions. The prologue of a function stores a guard variable onto the stack frame. Before returning from the function, the function epilogue checks the guard variable to make sure that it has not been overwritten. A guard variable that is overwritten indicates a buffer overflow, and the checking code alerts the run-time Environment.

Stack protection can be enabled by using the compiler options -fstack-protector, -fstack-protector-all, -fstack-protector-strong.

The initial value of its guard variable is taken from a global variable:

void *__stack_chk_guard;

A suitable value must be provided in this variable. For example, a suitable implementation might set this variable to a random value when the program is loaded, and before the first protected function is entered. The value must remain unchanged during the life of the program.

When the checking code detects that the guard variable on the stack has been modified, it notifies the run-time environment by calling the function:

void __stack_chk_fail(void);

Optimizations can affect stack protection. The following are simple examples of when this can happen:

  • Inlining can affect whether a function is protected.
  • Removal of an unused variable can prevent a function from being protected

2. Global named register variables

Arm Compiler 6.12 supports the use of global named register variables to enable faster access to these variables than if they were stored in memory, thereby giving a slight performance gain. This feature is only available for aarch32 state.

Using register and _asm keywords allows direct manipulation of a core register as if it were a 'C' variable.

register Type VariableName __asm("Reg")

where,

Type = datatype of the variable - can be char or any 8-bit, 16-bit, or 32-bit integer type, or their respective pointer types.

VariableName = Name of the variable

Reg = Core register to use to store the variable - Can be R5-R11

 Arm recommends that the following registers are not used as global named register variables because the Arm ABI reserves them for use as a frame pointer if needed.

  • R7 in T32 state
  • R11 in A32 state.

For example, to use register R5 as a global named register for an integer foo, you must use:

register int foo __asm("R5")

In the above example, you must compile with -ffixed-r5 (see -ffixed-rN) as the Arm standard library has not been built with any -ffixed-rN option.

If you want to link application code containing global named register variables with the Arm standard library, then:

  • To ensure correct run-time behaviour, ensure that the library code does not call code that uses the global named register variables in your application code.
  • The library code might push and pop the register to stack, even if your application code uses this register as a global named register variable.

Although giving a performance gain, the use of global named register variables can result in increase in code size since the core register is no longer available to the compiler for other operations. If too many global named register variables are declared, then code size increases significantly. In some cases, the program might not compile, simply because there are insufficient registers available to compute a particular expression.

Installation and useful resources

If you are new to Arm Compiler, then you can evaluate it in Arm Development Studio or Keil MDK. For existing Arm Compiler users, refer to Accessing Arm Compiler from Arm Development Studio or Accessing Arm Compiler from Keil MDK in their respective user guides.

For the list of changes and supported features, refer to the Arm Compiler 6.12 Release note. Further resources can be found in the Arm Compiler 6.12 Documentation.

If you are using Arm Compiler 5.x and are planning to migrate to Arm Compiler 6, the Migration and Compatibility Guide provides lots of helpful information and advice.

Learn more about Arm Compiler 6.12

Anonymous
Tools, Software and IDEs blog
  • GCC 15: Continuously Improving

    Tamar Christina
    Tamar Christina
    GCC 15 brings major Arm optimizations: enhanced vectorization, FP8 support, Neoverse tuning, and 3–5% performance gains on SPEC CPU 2017.
    • June 26, 2025
  • GitHub and Arm are transforming development on Windows for developers

    Pareena Verma
    Pareena Verma
    Develop, test, and deploy natively on Windows on Arm with GitHub-hosted Arm runners—faster CI/CD, AI tooling, and full dev stack, no emulation needed.
    • May 20, 2025
  • What is new in LLVM 20?

    Volodymyr Turanskyy
    Volodymyr Turanskyy
    Discover what's new in LLVM 20, including Armv9.6-A support, SVE2.1 features, and key performance and code generation improvements.
    • April 29, 2025