Follow @Openwall on Twitter for new release announcements and other news
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date: Wed, 27 Feb 2019 08:10:28 -0500
From: Rich Felker <dalias@...c.org>
To: musl@...ts.openwall.com
Subject: Re: luajit musl ppc32 bss-plt

On Wed, Feb 27, 2019 at 05:17:56AM +0000, Doug Crawford wrote:
> Just wondering if anyone else was successful in running luajit with musl on ppc32.
> I have pretty much everything else working on our ppc32 target with
> musl except luajit which segfaults very early in
> __register_frame_info@....plt
> During the luajit build I noticed this output:DYNLINK 
>  libluajit..so../powerpc-buildroot-linux-musl/bin/ld: bss-plt forced
> due to lj_vm.o
> I am guessing that something in luajit-2.0.5/src/lj_vm.s is forcing
> the linker to use the older bss-plt. But, musl only supports
> secure-plt so this probably is not going to work.

That's correct. The difference in ABI is that the secure-plt form
requires a particular GOT register to be loaded as part of the
contract for calling a PLT entry. The function calls in the asm (and
in jit-generated code, if it calls to C functions) need to be modified
to either follow the secureplt ABI, or better yet, not to use the PLT
at all, and instead just load the function address from the GOT and
perform an indirect call/jmp to it (this is considerably more
efficient than using a PLT anyway).

Rich

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.