Skip to content

Commit

Permalink
Revert "FROMPULL: arch: arm: cortex_m: add memory to the clobber list"
Browse files Browse the repository at this point in the history
This reverts commit 00ff8b6.

Reason for revert: Commit landed upstream in zephyrproject-rtos/zephyr@63890e2

Original change's description:
> FROMPULL: arch: arm: cortex_m: add memory to the clobber list
>
> Add "memory" to the clobber list"
>
> From GCC 14 the compiler optimizes away memory accesses that do not
> impact the asm block. Adding the memory to the clobber list lets the
> compiler know that the memory state is to be preserved.
>
> zephyrproject-rtos/zephyr#80579
>
> BUG=b:376282914
>
> Change-Id: I990e2256d0019361b3ef1f736095ebca3806a6e1
> Signed-off-by: Wilfried Chauveau <wilfried.chauveau@arm.com>
> Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/zephyr/+/5976801
> Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
> Tested-by: Jeremy Bettis <jbettis@chromium.org>

BUG=b:376282914

Change-Id: I8458857a2e52c8174257d0d3e94ac766dcf54027
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/zephyr/+/5994230
Tested-by: Yuval Peress <peress@google.com>
Auto-Submit: Yuval Peress <peress@google.com>
Reviewed-by: Fabio Baltieri <fabiobaltieri@google.com>
Commit-Queue: Yuval Peress <peress@google.com>
  • Loading branch information
yperess authored and Chromeos LUCI committed Nov 5, 2024
1 parent 7fb5ec8 commit cb60f14
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion arch/arm/core/cortex_m/thread.c
Original file line number Diff line number Diff line change
Expand Up @@ -588,7 +588,7 @@ void arch_switch_to_main_thread(struct k_thread *main_thread, char *stack_ptr,
"bx r4\n" /* We don’t intend to return, so there is no need to link. */
:
: "r" (_main), "r" (stack_ptr)
: "r0", "r1", "r2", "r3", "r4", "ip", "lr", "memory");
: "r0", "r1", "r2", "r3", "r4", "ip", "lr");

CODE_UNREACHABLE;
}
Expand Down

0 comments on commit cb60f14

Please # to comment.