[Xorg] The big multiconsole nasty

Keith Whitwell keith at tungstengraphics.com
Tue Jul 6 09:27:55 PDT 2004


Adam Jackson wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
> 
> On Tuesday 06 July 2004 11:41, Matthieu Herrb wrote:
> 
>>Keith Whitwell wrote:
>>
>>>Daniel Stone wrote:
>>>
>>>>In Debrix (the modular build of the X.Org server), dlloader is used
>>>>everywhere, and I feel tremendously good about it.
>>>
>>>Hooray!
>>
>>Is it possible to have OS independant binary modules with this loader?
> 
> 
> Short answer no, long answer yes.  It's tricky but not impossible.  To get a 
> portable ELF module, for example, you'd need to a) only use symbols defined 
> in the server (and the libraries it's linked against) or in other modules, 
> and b) not rely on any OS-specific features of the linker (versioned symbols 
> on Linux might be an instance of this, but are there any ELF platforms that 
> don't have this?).  There might be one or two other caveats but that's all 
> that springs to mind ATM.  That will get you portability among OSes with the 
> same ABI and a common subset of supported binary formats.  I would expect, 
> for example, that Linux-x86-ELF modules would have little trouble on 
> FreeBSD-x86 (either directly or using their Linux emulation).
> 
> I would posit, however, that OS-independence in drivers is a false economy.  
> OSes are cheap, get a multi-boot rig and compile them all directly.  Or use a 
> cross-compiler.  From the perspective of the graphics card manufacturer, 
> you'd need to have the target platform around for testing anyway if you're 
> going to declare it a supported platform.
> 
> Finally, if all else fails, it may be possible to keep the old loader around 
> specifically for obstreperous vendors who don't feel like adding another 
> machine to the compile farm.  This would need some hacking to make work - in 
> my tests the two module loaders are _not_ cross-callable - but it should be 
> doable.

Ugh.  That would be the ugliest.  If it goes, it should go completely.

Note that most drivers nowadays include a kernel component, so OS-independent 
modules in the userspace are pretty pointless.

Does anyone test that these modules actually can be run on another O/S?  Does 
anyone care if they can't?  Does any vendor actually make use of this?

If someone really cares about cross-platform drivers, the module loader in 
XFree86 isn't a great place to start.  For starters, there's the kernel 
problem I mentioned, but also I have to question how useful OS-independence is 
if you don't also gain CPU-independence.

For my 2 cents, it's a feature that sounds useful but isn't, and just makes 
life hard for people trying to do real work with the X server.

Keith





More information about the xorg mailing list