On 16/05/14 03:49 AM, DRC wrote:
> I don't even understand why that works at all, even without
> VirtualGL.  How does the application not get muldefs when linking
> with libGL?

The linker allows already-provided symbols to override what's in a
shared lib.  If you `objdump -T` you'll see the symbol listed as being
provided by "Base" rather than whatever lib. (At least on my Debian 7 box.)

> Some questions: (1) What happens if librrfaker.so is linked using
> -Wl,-z,interpose ?

My man page specifically says it "interposes before all symbols *but the 
primary executable*" so I can't  expect this to work.  And... actual 
testing confirms it doesn't.

> (2) Can the glGenBuffers() symbol be successfully loaded at all,
> perhaps using _glXGetProcAddress()?  Or does librrfaker always pick
> up the application's version?

dlsym(RTLD_NEXT, glGenBuffers) works fine in VGL code.  (Real libGL 
symbol.)  glXGetProcAddress, must work, of course, since viewperf itself 
(sometimes) uses it to get the real symbol.

> I am really not interested in implementing a symbol loader for every
> function that some random app decides it wants to override locally.
> That way lies madness.

It would be controllable madness in one sense, because it needn't be for
*every* symbol the app overrides, but the intersection of (app_overrides
and vgl_uses). The real problem with that, to my mind, is what if I
override a gl symbol for some reason such that everybody is required to
use this modified version or it won't work.  In this case we'd *want*
VGL to use the modified symbol.

> I think this needs to be pushed back to the Viewperf developers.
> Viewperf is an open source app, so it's not as if it is immutable.

That sounds like a better approach.  Will submit a ptach when I get 
spare time. (ha!)

-Nathan


------------------------------------------------------------------------------
"Accelerate Dev Cycles with Automated Cross-Browser Testing - For FREE
Instantly run your Selenium tests across 300+ browser/OS combos.
Get unparalleled scalability from the best Selenium testing platform available
Simple to use. Nothing to install. Get started now for free."
http://p.sf.net/sfu/SauceLabs
_______________________________________________
VirtualGL-Devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/virtualgl-devel

Reply via email to