aboutsummaryrefslogtreecommitdiff
path: root/examples/std
diff options
context:
space:
mode:
authorDario Nieuwenhuis <[email protected]>2023-05-16 01:21:28 +0200
committerDario Nieuwenhuis <[email protected]>2023-05-16 01:21:28 +0200
commit0c18a13cc056d4d54ca7261289615b2d03769a76 (patch)
tree8ee79c9d003bf8422ad185e937b00b2d957ee72e /examples/std
parent1a87f7477abdb033d960a6af63c95a9e0575e670 (diff)
rp/multicore: fix undefined behavior in multicore spawn.
It is UB to pass `entry` to core1 as `&mut`, because core0 keeps an aliasing pointer to that memory region, and actually writes to it (when `spawn_core1` returns, the stack frame gets deallocated and the memory gets reused). This violates noalias requirements. Added the fence just in case, een though it works without.
Diffstat (limited to 'examples/std')
0 files changed, 0 insertions, 0 deletions