-
Notifications
You must be signed in to change notification settings - Fork 408
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
Fix cinaps on arm32 #4081
Fix cinaps on arm32 #4081
Conversation
Closes ocaml#4069 When `dynlink:false` is passed, the ARM backend emits MOVW/MOVT instructions which have relocations incompatible with PIC code. This is similar to ocaml#2527 (ocaml issue: ocaml/ocaml#8867). Signed-off-by: Etienne Millon <me@emillon.org>
The fix is just for cinaps but it looks like all places that pass #2527 has a discussion about whether to pass
So I think it's worth wondering if we should just remove this mechanism (and the This part would be done in a separate PR of course, this one is enough to fix the cinaps issue. |
@emillon: See ocaml#4081 - this might not work on arm32 otherwise. Co-authored-by: Etienne Millon <etienne.millon@gmail.com>
@emillon: See ocaml#4081 - this might not work on arm32 otherwise. Co-authored-by: Etienne Millon <etienne.millon@gmail.com> Signed-off-by: Ulysse Gérard <thevoodoos@gmail.com>
Yes, let's just disable this option everywhere until it's fixed with PIE. If you want to future proof things, you can add this value for dynlink:
This way we'll just need to update |
Actually, I'm not sure if |
@rgrinberg I've just opened #4085 which removes the |
I know that at Jane Street we have been using |
We don't do any optimization for normal executables (the ones produced by executable stanzas) at the moment - the piece of code linked in #4081 (comment) is equivalent to Do you mean adding a way to remove the |
Indeed, I forgot about this. Never-mind then. We might indeed want to allow this optimisation at Jane Street in the future, but we can cross that bridge when we come to it. In the meantime #4805 seems good. |
Thanks! I just merged it to master. This one might be useful if we cut a 2.7.x point release but I'm closing it in the meantime. |
I created #4095 to track this. |
@emillon: See ocaml#4081 - this might not work on arm32 otherwise. Co-authored-by: Etienne Millon <etienne.millon@gmail.com> Signed-off-by: Ulysse Gérard <thevoodoos@gmail.com>
Closes #4069
When
dynlink:false
is passed, the ARM backend emits MOVW/MOVT instructions which have relocations incompatible with PIC code.This is similar to #2527 (ocaml issue: ocaml/ocaml#8867).