Skip to main content

IAR Embedded Workbench for RISC-V 3.40

Summary of extended keywords

In this section:

This table summarizes the extended keywords:

Extended keyword

Description

__interrupt

Specifies interrupt functions

__intrinsic

Reserved for compiler internal use only

__machine

Places an interrupt function in the linker section .mtext

__monitor

Specifies atomic execution of a function

__nmi

Makes it possible to set up interrupts correctly for GigaDevice devices when using ‑‑auto_vector_setup.

__no_alloc, __no_alloc16

Makes a constant available in the execution file

__no_alloc_str, __no_alloc_str16

Makes a string literal available in the execution file

__no_init

Places a data object in the linker section .noinit

__noreturn

Informs the compiler that the function will not return

__packed

Decreases data type alignment to 1

__preemptive

Saves CSR registers during interrupts, and enables global interrupts.

__root

Ensures that a function or variable is included in the object code even if unused

__ro_placement

Places constvolatile data in read-only memory.

__supervisor

Places an interrupt function in the linker section .stext

__task

Relaxes the rules for preserving registers

__user

Places an interrupt function in the linker section .utext

__weak

Declares a symbol to be externally weakly linked

Table 79. Extended keywords summary