Turn off L1 caching on Fermi GPUs via the driver API?

I’m looking for an equivalent to the compiler flag “-Xptxas -dlcm=cg” for generating .cubin files, but need to generate .ptx files that will be loaded via the driver API and compiled at run-time. Is it possible to turn off L1 caching in this situation, perhaps via a driver API function? I’ve been unable to find anything about this in the documentation so far.


I have the same problem with SDK 4.0. Can anybody help us?

I have solved this problem finally.

I tried to replace all of “ld” ptx_isa instruction to “ld.cs”, but I didn’t notice, that “ld” instruction used for params too. This caused an error.

The correct form is put cache modifier only to the “ld.global” instructions, like “ld.cs.global”…