|
From: | Luca Dariz |
Subject: | Re: [PATCH 5/5] add setting gs/fsbase |
Date: | Sat, 22 Apr 2023 13:17:06 +0200 |
Hi Sergey, Il 20/04/23 13:51, Sergey Bugaev ha scritto:
On Wed, Apr 19, 2023 at 11:52 PM Sergey Bugaev <bugaevc@gmail.com> wrote: We do reach the call to __thread_set_state (), but then it uses __mig_memcpy (), which is just 'return memcpy (...)'. And (because of the static build?), that memcpy () is the full real ifunc-selected memcpy. So it jumps to the memcpy@plt, which jumps to *(memcpy@got.plt), which is supposed to jump into the rtld and then run the ifunc resolver and do its smarts and eventually jump to the right memcpy...
I don't know if you already found a good solution for this, but if not maybe we could add an x86_64-specific plain syscall to set fsbase/gsbase during bootstrap, if it can make things more manageable.
Luca
[Prev in Thread] | Current Thread | [Next in Thread] |