LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 02-11-2011, 10:47 PM   #1
coreybrenner
LQ Newbie
 
Registered: Feb 2011
Location: Silly Valley
Distribution: Arch
Posts: 2

Rep: Reputation: 0
ELF Format Weaknesses? Ideas for a new file format?


Hello,

I've been noodling on the slow startup problems with KDE and other massive C++ projects, and I think I've come up with a generalized solution in the form of a packed PATRICIA trie as a symbol table. I have a more compact representation that I'm going to benchmark against the PATRICIA, but that's a different topic.

What I want to know is, are there any other weaknesses that others have encountered in the ELF file format? One of the original problems was lack of a platform specifier, which led the OpenBSD folks to develop "OLF" for a while, but which was resolved by annotating the ELF file in a specific way. FatELF makes ELF binaries fat, of course.

Are there other problems with ELF? Are there issues with the way that the file format is structured, that could be fixed by a different binary format? Specifically, are there issues inherent to the way the file format lays out sections that could be rearranged to make the representation easier and faster to load? Are there better ways to do PLT vs. GOT representations for 32 and 64 bit targets? Is there a way to reclaim %ebx (yeah, x86-specific)?

One thing that I'm thinking about is how to support more modern linkage schemes. The flat symbol namespace seems to me to be a hindrance to proper package and library construction. Of course, flat tables could be created which aliased a hierarchical scheme, to provide compatibility. How about a compact, efficient representation of data types in an object file, which can possibly be reflected upon by a language with those facilities?

Variant functions (for instance, a bog-standard implementation of a routine for i386, but one which uses all the newest whiz-bang vector instructions for a more modern CPU, existing in the same library, referenced by the same name, but bound at load time based upon what the kernel tells the loader the current platform is...)?

One feature I'm also thinking of is a "forward-only" load-time symbol resolution flag, which should make library interposition easier and more automatic, without having to resort to dlsym(RTLD_NEXT,...).

How about application bundles? A read-only filesystem within the bounds of the executable itself, for packing resources? Tunable knobs tucked into the binary itself, available to a program via a simple API?

I'd be interested to know what kinds of features folks would like to see, and what they'd consider useful attributes in a forward-looking file format.
 
Old 02-11-2011, 11:35 PM   #2
paulsm4
LQ Guru
 
Registered: Mar 2004
Distribution: SusE 8.2
Posts: 5,863
Blog Entries: 1

Rep: Reputation: Disabled
COFF, OMF, ELF, ELF-64, MAC-O, APK, etc. etc.

The one feature I'd like most is to not have to worry about another object format

ELF is fine, thank you
 
1 members found this post helpful.
Old 02-12-2011, 06:18 AM   #3
H_TeXMeX_H
LQ Guru
 
Registered: Oct 2005
Location: $RANDOM
Distribution: slackware64
Posts: 12,928
Blog Entries: 2

Rep: Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301
Maybe this will help:
http://upx.sourceforge.net/#downloadupx

However, I think we should just get rid of KDE and other massively bloated programs.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Difference between Linux ELF Format and win32 ELF Format cmemo Linux - Hardware 1 05-11-2007 05:32 PM
Difference between Linux ELF Format and win32 ELF Format cmemo Linux - General 1 05-11-2007 03:44 PM
Difference between Linux ELF Format and win32 ELF Format cmemo Linux - Software 1 05-11-2007 03:31 PM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 11:04 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration