Re: Help needed for debugging OCaml failure on m68k
Stéphane Glondu <[email protected]>
| Newsgroups | gmane.linux.debian.ports.68k |
|---|---|
| Message-ID | <[email protected]> |
Hi Adrian and all, Le 19/06/2024 à 14:04, John Paul Adrian Glaubitz a écrit : >> [...] the address of >> caml_state (a thread local variable) changes unexpectedly (goes from >> 0x402e5fac to 0x402e7454) after the following goto: >> >> >> https://salsa.debian.org/ocaml-team/ocaml/-/blob/debian/experimental/runtime/interp.c?ref_type=heads#L295 >> >> which leads to: >> >> >> https://salsa.debian.org/ocaml-team/ocaml/-/blob/debian/experimental/runtime/interp.c?ref_type=heads#L819 >> >> ...confirmed by adding: >> >> fprintf(stderr, "&caml_state = %p\n", &caml_state); >> >> before the goto and after the "Instruct(BRANCH):". > > Hmm, I guess then maybe Andreas Schwab or Geert Uytterhoeven might have an idea what > the problem with the TLS variable is. I'll CC both. I noticed that &caml_state changes when pc changes. Looking further, pc is a register variable pinned to a5. I guess this conflicts with the implementation of TLS...? I've removed the register pin and launched a build, and it goes past the problematic point. We'll see how it goes... Cheers,