We develop code for embedded PowerPC architectures.
Our compiler supports something called asm Macros.
Here an excerpt from the handbook:
asm Macro Syntax
An asm macro definition looks much like a function definition, including a return type and parameter list, and function body.
The syntax is:
asm [volatile] [return-type] macro-name ( [ parameter-list ] ) { % storage-mode-list (must start in column 1) ! register-list (“!” must be first non-whitespace) asm-code } (must start in column 1
Is this standard C? My compiler does not list this as an extension in his handbook.
Clarification after first answer:
I'm aware the part withen { }
is not defined by standard C. I meant the function like construct after asm
and before the closing )
.