New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

OpenCL error message enhancement #1574

Open
blark opened this Issue May 18, 2018 · 4 comments

Comments

Projects
None yet
4 participants
@blark

blark commented May 18, 2018

I am running into an OpenCL error when attempting to run hashcat on an IBM Power8 system. I have read that OpenCL isn't officially supported on the platform, but nevertheless it's installed and there are official Ubuntu packages... so I want to figure out why it isn't working. The current hashcat error message is no help:

clBuildProgram(): CL_BUILD_PROGRAM_FAILURE

* Device #1: Kernel /hashcat/OpenCL/m01000_a3-optimized.cl build failed - proceeding without this device.

I did some research and noticed that there is a this funciton:
clGetProgramBuildInfo(program, &device_id, CL_PROGRAM_BUILD_LOG, 0, NULL, &len);
and hashcat seems to implement the function as hc_clGetProgramBuildInfo but it is not invoked in hc_clBuildProgram on such errors. I am not comfortable enough with the source to make the necessary change myself to get the error log, but I think it would be great if this error were more verbose to allow for debugging/fixing things.

@blark blark changed the title from Error message enhancement to OpenCL error message enhancement May 18, 2018

@hops

This comment has been minimized.

Contributor

hops commented May 19, 2018

You will see the build log if you compile hashcat with make DEBUG=1.
For example:

* Device #2: build_opts '-cl-std=CL1.2 -I OpenCL -I /home/hops/src/hashcat/OpenCL -D VENDOR_ID=32 -D CUDA_ARCH=601 -D AMD_ROCM=0 -D VECT_SIZE=2 -D DEVICE_TYPE=4 -D DGST_R0=0 -D DGST_R1=3 -D DGST_R2=2 -D DGST_R3=1 -D DGST_ELEM=4 -D KERN_TYPE=1000 -D _unroll'
* Device #2: Kernel m01000_a3-optimized.f6f629d0.kernel not found in cache! Building may take a while...
clBuildProgram(): CL_BUILD_PROGRAM_FAILURE

<kernel>:178:24: error: expected ';' at end of declaration
  const u8 error = 0x23
                       ^
                       ;

* Device #2: Kernel /home/hops/src/hashcat/OpenCL/m01000_a3-optimized.cl build failed - proceeding without this device.
@blark

This comment has been minimized.

blark commented May 19, 2018

Thanks for the help!

I did try that actually, I tried to specify it on the command line and then I manually changed it in src/Makefile and I get no error output. Maybe there is no output? Not sure what's going on.

@jsteube

This comment has been minimized.

Member

jsteube commented Jun 14, 2018

Did you run make clean after changing the variable in Makefile?

@rikatz

This comment has been minimized.

rikatz commented Sep 16, 2018

Same problem here.

Running hashcat 4.2.1 in a ppc64 machine with 4 Tesla P100, and get the clBuildProgram(): CL_BUILD_PROGRAM_FAILURE

Did a make clean, and a make DEBUG=1 but nothing happens, only the error, no debug messages.

Any advice?

Thanks!

EDIT: Got some messages here:

* Device #4: build_opts '-cl-std=CL1.2 -I OpenCL -I /home/katz/hashcat-4.2.1/OpenCL -D VENDOR_ID=32 -D CUDA_ARCH=600 -D AMD_ROCM=0 -D VECT_SIZE=1 -D DEVICE_TYPE=4 -D DGST_R0=0 -D DGST_R1=3 -D DGST_R2=2 -D DGST_R3=1 -D DGST_ELEM=4 -D KERN_TYPE=0 -D _unroll'
* Device #4: Kernel m00000_a1-pure.0e14c4fb.kernel not found in cache! Building may take a while...
clBuildProgram(): CL_BUILD_PROGRAM_FAILURE
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment