Commit 56438cc
committed
Honor PTX_SIM_KERNELFILE override on CUDA >= 6.0
The PTX_SIM_USE_PTX_FILE / PTX_SIM_KERNELFILE override, documented in the
README for simulating a hand-edited PTX file without recompiling the
application, was only implemented in the legacy pre-CUDA-6.0 PTX loading
branch of cuobjdumpParseBinary.
On CUDA 6.0+ the active #if (CUDART_VERSION >= 6000) branch loads PTX
solely from the cuobjdump-extracted filename (which is regenerated on every
run), so the override silently had no effect even though the "overriding
embedded ptx ... (PTX_SIM_USE_PTX_FILE is set)" message was still printed
during initialization.
Honor PTX_SIM_KERNELFILE in the CUDART_VERSION >= 6000 loading loop as
well, gated on both PTX_SIM_USE_PTX_FILE and PTX_SIM_KERNELFILE being set
so default behavior is unchanged. PTXInfo (register/shared-memory usage) is
still loaded from the originally extracted file.1 parent 6c3cf4f commit 56438cc
1 file changed
Lines changed: 13 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3802 | 3802 | | |
3803 | 3803 | | |
3804 | 3804 | | |
| 3805 | + | |
| 3806 | + | |
| 3807 | + | |
| 3808 | + | |
| 3809 | + | |
| 3810 | + | |
| 3811 | + | |
| 3812 | + | |
| 3813 | + | |
| 3814 | + | |
| 3815 | + | |
| 3816 | + | |
| 3817 | + | |
3805 | 3818 | | |
3806 | 3819 | | |
3807 | 3820 | | |
| |||
0 commit comments