Note: all versions of oclHashcat have been replaced by a unified OpenCL CPU/GPU version, now known simply as hashcat. Since modern hashcat dynamically compiles the kernels that it needs, the kernel removal technique described here is no longer necessary (unless you are running the legacy oclHashcat for some reason).
Every new compute capability increases the number of kernels required for oclhc, which in turn increases its size. There are currently 11 compute capabilities for Nvidia, and they have to be multiplied by the number of supported hashes and by two (for 32 bit and 64 bit OS). A simple batch script can be made to delete obsolete kernels and free space.
There are multiple ways to identify the compute capability of your GPU. A reliable and easy way would be to launch CudaExample500.bat and look at the “Device #1” string oclhc prints. In this example a GTX Titan and a 64 bit OS are used, so it should be “Device #1: Kernel ./kernels/4318/m00500.sm_35.64.ptx”. This means that GTX Titan's compute capability is sm_35, which is the only architecture that should be kept.
The batch script, found below, should be copied and placed into kernels\4318 folder inside oclhc, in a “delete.bat” file.
del *.32.ptx del *.sm_10.64.ptx del *.sm_11.64.ptx del *.sm_12.64.ptx del *.sm_13.64.ptx del *.sm_20.64.ptx del *.sm_21.64.ptx del *.sm_30.64.ptx del *.sm_35.64.ptx del *.sm_37.64.ptx del *.sm_50.64.ptx del *.sm_52.64.ptx
Now, the batch script above deletes all 32 bit kernels and all 64 bit kernels. The line “del *.sm_35.64.ptx” should be removed from the file for the aforementioned example.
Once all is done, run the batch file and it will delete all obsolete kernels.