28-03-2017, 06:52 PM
Rule 7-4-3 states that "... assembly instructions shall be encapsulated and isolated in either assembler functions or C++ functions.".
Does assembler functions refers to assembly directives (.func and .endfunc) used in a .S file or it refers to C++ functions that encapsulate the assembly instructions?
Is the example compliant?
asm.S
main.cpp
Does assembler functions refers to assembly directives (.func and .endfunc) used in a .S file or it refers to C++ functions that encapsulate the assembly instructions?
Is the example compliant?
asm.S
Code:
.global foo
.func foo
foo:
...
.endfunc
Code:
extern "C" {
void foo();
}
int main(void) {
...
foo();
...
}
<t></t>