[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-core-devel
Subject:    Re: Proposal: dlopening the file dialog
From:       Thiago Macieira <thiago () kde ! org>
Date:       2007-03-29 18:50:11
Message-ID: 200703292050.17286.thiago () kde ! org
[Download RAW message or body]


David Faure wrote:
>- making kio smaller, without all those mostly-internal classes with
> lots of virtual methods, which according to Dirk leads to many
> unnecessary reallocations during startup

Uh, relocations :-)

Yep, that's actually a big cost. One that can be lessened by the use 
of -Bsymbolic-functions in KDE code as well as Qt code. Unfortunately, 
there's no released version of GNU binutils (ld) that contains that 
feature yet. I'd like KDE to support that switch just like Qt does.

It really improves the relocation performance, since it changes the global 
relocation (which is string-based and, therefore, requires hash tables 
and costly string comparisons on the rather long C++ mangled names) into 
local relocations: those are simple pointer arithmetic with the library's 
load address. What's more, direct calls will be made with direct relative 
jumps, instead of indirect through the PLT.

I don't have the numbers anymore, but when I tested a similar feature in 
KDE, it reduced the relocation table size greatly. The number of global 
relocations to local symbols dropped from ~1700 to 0 in kdecore.

You can call this the next big step after -fvisibility=hidden.

(The feature that I actually tested was visibility=protected, but that's 
currently broken in architectures without PIC executables)

-- 
  Thiago Macieira  -  thiago (AT) macieira.info - thiago (AT) kde.org
    PGP/GPG: 0x6EF45358; fingerprint:
    E067 918B B660 DBD1 105C  966C 33F5 F005 6EF4 5358

[Attachment #3 (application/pgp-signature)]

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic