-
Notifications
You must be signed in to change notification settings - Fork 26
microblaze: Fix atomic boolean return value. #21
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
microblaze: Fix atomic boolean return value. #21
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As @keith-packard already pointed out, it would be good to pull in all the Microblaze patches in https://github.com/Xilinx/meta-xilinx/tree/master/meta-microblaze/recipes-devtools/gcc/gcc-12
I apologise I disappeared without notice, I've been busy with work. |
Good news is -as far as I could test- all picolibc tests except
I'll first take a look into what's happening with |
|
In atomic_compare_and_swapsi, fix boolean return value. Previously, it contained zero if successful and non-zero if unsuccessful. Signed-off-by: Kirk Meyer <kirk.meyer@sencore.com> Signed-off-by: David Holsgrove <david.holsgrove@xilinx.com> Fixes Zephyr SDK Issue #646. Patch file taken and applied from: https://github.com/Xilinx/meta-xilinx/blob/master/meta-microblaze/recipes-devtools/gcc/gcc-12/0009-Patch-microblaze-Fix-atomic-boolean-return-value.patch Signed-off-by: Alp Sayin <alpsayin@gmail.com>
In atomic_compare_and_swapsi, add side effects to prevent incorrect assumptions during optimization. Previously, the outputs were considered unused; this generated assembly code with undefined side effects after invocation of the atomic. Signed-off-by: Kirk Meyer <kirk.meyer@sencore.com> Signed-off-by: David Holsgrove <david.holsgrove@xilinx.com> Conflicts: gcc/config/microblaze/microblaze.md Attempts to fix picolibc Issue #460. Patch file taken and applied from: https://github.com/Xilinx/meta-xilinx/blob/master/meta-microblaze/recipes-devtools/gcc/gcc-12/0008-Patch-microblaze-Fix-atomic-side-effects.patch Signed-off-by: Alp Sayin <alpsayin@gmail.com>
a35ad90
to
b4654fb
Compare
Closing in favour of #24 |
In atomic_compare_and_swapsi, fix boolean return value. Previously, it contained zero if successful and non-zero if unsuccessful.
Fixes Zephyr SDK Issue zephyrproject-rtos/sdk-ng#646.
Patch file taken and applied from: https://github.com/Xilinx/meta-xilinx/blob/master/meta-microblaze/recipes-devtools/gcc/gcc-12/0009-Patch-microblaze-Fix-atomic-boolean-return-value.patch
CC @keith-packard