glGetProgramBinary unsupported?

When I query the binary, I really get a binary and nothing human readable. I was expecting to see the generated assembly code like how Nvidia returns it. It's really difficult to write a maxFLOPS test without seeing this assembly. Moreover the Midgard architecture is a mixmatch between old school VLIW and scalar so I never know whether scalar or vector MULs are being generated from my code.

  • The binary format that is returned from glGetProgramBinary is entirely driver dependent and depending on GPU vendor, it can be GPU family dependent as well.

    You're lucky when grabbing the binary results that Nvidia returns because they use ARB assembly for their program binaries. This is human readable because they keep it in ASCII.

    Most other companies will be returning a binary representation that isn't human readable.

    Qualcomm for example returns the program compiled to the native architecture of the GPU, plus a bunch of metadata, and also the original program's sources. They return this "encrypted" with a simple XOR "encryption" to keep it from being human readable.

    Really need either a shader disassembler to disassemble program binaries, or a host shader assembler that outputs the shader source in a human readable fashion.

    Companies tend to dislike divulging any information about the GPU, which includes the ISA that the GPU runs.

    If a fully documented ISA was released from companies it helps enthusiastic individuals with reversing their GPU and writing open source drivers.

    A shader compiler really helps individuals when optimizing for a platform though. AMD's ShaderAnalyzer tool is a good example of a great shader compiler that shows the compiled shader sources and bottlenecks on that particular platform.

    Just my two cents.

Reply Children
No data
More questions in this forum
There are no posts to show. This could be because there are no posts in this forum or due to a filter.