On 22/04/2025 8:46 pm, Stefano Stabellini wrote:
> On Tue, 22 Apr 2025, Andrew Cooper wrote:
>> Compilers estimate the size of an asm() block for inlining purposes.
>>
>> Constructs such as ALTERNATIVE appear large due to the metadata, depsite 
>> often
>> only being a handful of instructions.  asm inline() overrides the estimation
>> to identify the block as being small.
>>
>> This has a substantial impact on inlining decisions, expected to be for the
>> better given that the compiler has a more accurate picture to work with.
>>
>> Signed-off-by: Andrew Cooper <andrew.coop...@citrix.com>
> Hi Andrew,
>
> If we are going to use asm_inline, please add a note to
> docs/misra/C-language-toolchain.rst where we keep record of all the
> language extensions we use.

It's just asm(), and that's already discussed.

I'm not sure what else you think is warranted.

~Andrew

Reply via email to