-
Notifications
You must be signed in to change notification settings - Fork 117
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
ATOMIC_CAS cann't work on ARM #23
Comments
ATOMIC_CAS makes use of __sync_bool_compare_and_swap which I believe it's provided by the compiler also on ARM. Could you provide the exception and the stacktrace (and maybe a coredump) for your crash? |
@luokj I think I understand what is your problem. |
Thank you for reply. I use other code from github, so I don't give a
helpful information.
2017-10-24 7:49 GMT+08:00 Andrea Guzzo <notifications@github.com>:
… @luokj <https://github.com/luokj> I think I understand what is your
problem.
Is it crashing at runtime with an "Unhandled fault: Alignment Exception".
Adding "-mno-unaligned-access" to CFLAGS should fix.
I'll check myself when I'll have access again to a linux ARM system.
Note that maybe on linux you can configure the linux kernel at runtime
(/proc/cpu/alignment) to ignore the exception and don't kill the process.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#23 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AK8LHF1l28MG4nnNLhOcbX3lQRhp52_Oks5svSX0gaJpZM4PhgkX>
.
|
Ok, packing some structures was overriding the natural alignment and obviously making it not work on ARM unless the "-maligned-access" option was passed to the compiler (but then with obvious performance loss because of unaligned memory access) Fixed in 172f5a |
Use hash function on ARM platform, but it crash when callinig ht_create
The text was updated successfully, but these errors were encountered: