-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Michel Dänzer wrote: > I think we need to get to the bottom of this problem, as it keeps > getting more annoying, e.g. now with AIGLX it's not always easy to tell > whether direct rendering is being used, and when it's not, bugs may take > down the server instead of just the app, not to mention the inferior > performance. > >>From what I've gathered, the problem seems to be due to the DRI drivers > no longer being linked against libGL (again for AIGLX) and occurs with > apps that aren't linked to libGL directly but dlopen it, and do so > without RTLD_GLOBAL. This seems to be mostly the case with SDL, but I > don't think we can just discard it as a bug there, as even changing SDL > to dlopen libGL with RTLD_GLOBAL now won't help with games that ship > their own versions of SDL, etc.
That seems to be the source of the problem. This also explains why we're only seeing it recently. > The attached patch attempts to fix this in libGL by always dlopening > libGL itself with RTLD_GLOBAL before trying to dlopen the driver, and > dlclosing the handle obtained from dlopening libGL again before > returning. It works here, e.g. tremulous and slune now get direct > rendering without LD_PRELOAD=libGL.so.1 again. Ah. Very clever. I was thinking about solving this a different way. We have a way to get function pointers into the driver from the loader. I was thinking that we could use one of these mechanisms (either passing it in via the interface structure or via the getProcAddress method) to get the _glapi_* functions. That said, your patch is much lower impact, and I like it. -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2.2 (GNU/Linux) iD8DBQFExNdbX1gOwKyEAw8RAjmOAJ9MbWEoUDt40TS9WthElDMTDPet5QCfZcDu zErQQT/vDlW59JvzpxO3CRI= =MYG4 -----END PGP SIGNATURE----- ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys -- and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ Mesa3d-dev mailing list Mesa3d-dev@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/mesa3d-dev