Searched hist:ec295ea067cffb2b13f6d818de5a28a55428eb1b (Results 1 – 2 of 2) sorted by relevance
| /optee_os/core/include/ |
| H A D | gen-asm-defines.h | ec295ea067cffb2b13f6d818de5a28a55428eb1b Fri Mar 22 16:06:08 UTC 2019 Jerome Forissier <jerome.forissier@linaro.org> core: change the pattern used to generate asm-defines.h
This commit prepares support for the Clang compiler.
$O/core/include/generated/asm-defines.h is generated from core/arch/arm/kernel/asm-defines.c by the C compiler with the -S flag (generate assembler code), followed by some light post-processing with sed.
The intermediate file ($O/core/include/generated/.asm-defines.s) is actually not a valid assembler file. It contains illegal tokens, which where chosen to make it easy to parse with sed. For example:
==>SM_CTX_SIZE #256 sizeof(struct sm_ctx) @
...is turned into:
#define SM_CTX_SIZE 256 /* sizeof(struct sm_ctx) */
While this works fine with GCC, the Clang compiler won't accept to output invalid assembler. This commit slightly modifies the inline assembler so that the needed information is contained within a .ascii directive:
.ascii "==>SM_CTX_SIZE 248 sizeof(struct sm_ctx)" @
The 'c' constraint (%c0) is added to avoid the # prefix before an immediate value, which is not accepted by Clang either.
Signed-off-by: Jerome Forissier <jerome.forissier@linaro.org> Acked-by: Jens Wiklander <jens.wiklander@linaro.org>
|
| /optee_os/mk/ |
| H A D | compile.mk | ec295ea067cffb2b13f6d818de5a28a55428eb1b Fri Mar 22 16:06:08 UTC 2019 Jerome Forissier <jerome.forissier@linaro.org> core: change the pattern used to generate asm-defines.h
This commit prepares support for the Clang compiler.
$O/core/include/generated/asm-defines.h is generated from core/arch/arm/kernel/asm-defines.c by the C compiler with the -S flag (generate assembler code), followed by some light post-processing with sed.
The intermediate file ($O/core/include/generated/.asm-defines.s) is actually not a valid assembler file. It contains illegal tokens, which where chosen to make it easy to parse with sed. For example:
==>SM_CTX_SIZE #256 sizeof(struct sm_ctx) @
...is turned into:
#define SM_CTX_SIZE 256 /* sizeof(struct sm_ctx) */
While this works fine with GCC, the Clang compiler won't accept to output invalid assembler. This commit slightly modifies the inline assembler so that the needed information is contained within a .ascii directive:
.ascii "==>SM_CTX_SIZE 248 sizeof(struct sm_ctx)" @
The 'c' constraint (%c0) is added to avoid the # prefix before an immediate value, which is not accepted by Clang either.
Signed-off-by: Jerome Forissier <jerome.forissier@linaro.org> Acked-by: Jens Wiklander <jens.wiklander@linaro.org>
|