Follow @Openwall on Twitter for new release announcements and other news
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Sat, 2 Jun 2012 17:41:03 -0400
From: Rich Felker <>
Subject: Re: hm, libc crashes  loading libc

On Sat, Jun 02, 2012 at 11:18:39PM +0200, aep wrote:
> On Sat, 2 Jun 2012 16:32:25 -0400, Rich Felker wrote:
> >On Sat, Jun 02, 2012 at 03:30:14PM +0200, aep wrote:
> >>turns out the problem is that gcc 4.7.0 from archlinux adds
> >>--hash-style=gnu to ld, which musl cannot read.
> >
> >I can look into how much work it would be to add GNU hash support, or
> >whether it's possible to support linear searching the symbol table
> >when the hash table is missing...
> does hash-style=gnu add any benefit for the target audience? I am
> noticing no speed difference for my small C program, but maybe it
> becomes interesting when C++  is added to the game.

Like most GNU junk, it's oriented towards the case where N->infinity.
For small values of N (the number of symbols), standard ELF hash table
is going to perform at least as well, maybe even better...

Basically, it was designed for speed up Firefox loading it's ugly .so
files at runtime. The correct fix, since they're all code that's used
by a SINGLE PROGRAM, is to get rid of the .so's and link them into the
main program, but for no rational reason, the Firefox developers
refuse to do this. I suspect it's because their build system is broken
and it's hard for them to test changes to these files without building
them as separate .so's...


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.