Skip to content

Commit 4750711

Browse files
committed
tests/arm_mpu_pxn: Insist that trivial functions are not inlined
GCC 14 takes a look these functions which are just 'return true' and inlines them even though they has the noinline attribute set. Insist a bit harder by adding a compiler_barrier to them. Signed-off-by: Keith Packard <[email protected]>
1 parent b8cf909 commit 4750711

File tree

1 file changed

+2
-0
lines changed
  • tests/arch/arm/arm_mpu_pxn/src

1 file changed

+2
-0
lines changed

tests/arch/arm/arm_mpu_pxn/src/main.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818
*/
1919
__customramfunc bool custom_ram_func(void)
2020
{
21+
compiler_barrier();
2122
return true;
2223
}
2324

@@ -28,6 +29,7 @@ __customramfunc bool custom_ram_func(void)
2829
*/
2930
__ramfunc bool ram_function(void)
3031
{
32+
compiler_barrier();
3133
return true;
3234
}
3335

0 commit comments

Comments
 (0)