|
Message-ID: <CAMo8Bf+MnbOHVHwML4v-8cb9Lx0rqhRDiq2D+LdMoA=1_VUgdg@mail.gmail.com> Date: Thu, 28 Mar 2024 17:48:50 -0700 From: Max Filippov <jcmvbkbc@...il.com> To: Rich Felker <dalias@...c.org> Cc: musl@...ts.openwall.com Subject: Re: [RFC v2 0/2] xtensa FDPIC port On Thu, Mar 28, 2024 at 4:00 PM Rich Felker <dalias@...c.org> wrote: > On Thu, Mar 28, 2024 at 01:03:17PM -0700, Max Filippov wrote: > > functional/dlopen fails with the > > src/functional/dlopen.c:39: dlsym main failed: (null) > > There's no failure in the dlsym call, but the pointers don't match. > > Is this something related to canonical function descriptors? Is it > musl's fault or a bug in the tooling? I suspect the latter. Yes, dlsym() returns the pointer into def.dso->funcdescs, but (void *)main returns the pointer to the canonical function descriptor. I understand that the linker must use the R_XTENSA_FUNCDESC relocation for the locally defined global symbol instead of the .rofixup entries. > > functional/ and regression/ pthread-related failures are expected > > because the robust list functions are not available in the linux-user > > mode. These particular tests pass in full system emulation. > > > > math tests fail with ULP differences. > > > > I have also added the following changes to the abi tests to fix the > > build: > > > > diff --git a/src/api/sys_sem.c b/src/api/sys_sem.c > > index a473cad0a2aa..bd4df9a4fe70 100644 > > --- a/src/api/sys_sem.c > > +++ b/src/api/sys_sem.c > > @@ -18,7 +18,11 @@ C(SETALL) > > { > > struct semid_ds x; > > F(struct ipc_perm,sem_perm) > > +#ifdef __xtensa__ > > +F(unsigned long, sem_nsems) > > +#else > > F(unsigned short, sem_nsems) > > +#endif > > This is invalid and indicates an error in the port; the whole point of > the tests is to catch that so it can be fixed. POSIX requires I must have misinterpreted that. Will fix it. > sem_nsems to have type unsigned short. I believe Linux has this wrong > on some (most? all?) archs and we just fix it by replacing the rest > with padding. -- Thanks. -- Max
Powered by blists - more mailing lists
Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.