Comments (32)
I guess there is a symbolic link in the test directory, is that right?
Yes, build
directory is a symlink to cocl
directory inside which I build the package.
OFFSET_32BIT=1 py.test -svx test/test_branching.py
passed, now running all with
OFFSET_32BIT=1 py.test -svx
from coriander.
Please define:
export OFFSET_32BIT=1
And also CLANG_HOME
And try again
For an initial test, let's try like this:
OFFSET_32BIT=1 py.test -svx test/test_branching.py
The -sv
will mean we see all the output. -x
will make it stop after first failure
The files you see are intermediate files, and are normal.
(reposted, because original email reply didnt work with markdown)
from coriander.
Also, it looks like it is recursing. I guess there is a symbolic link in the test directory, is that right?
(reposting, so sequence is correct)
from coriander.
OFFSET_32BIT=1 py.test -svx test/test_branching.py
passed
Excellent news!
from coriander.
env CLANG_HOME=/usr/lib/llvm-3.8/ OFFSET_32BIT=1 py.test-3 -sv -r a|highlight --src-lang=c -O html -I
output
https://www.dropbox.com/s/ozgs7aqpngtlovy/cocl_py.test-3.html
from coriander.
You sent me an html file, containing build output. I'm not very keen on opening random html snippets in my browser on the whole :-) Can you paste the output into https://gist.github.com please.
from coriander.
Ok - https://gist.github.com/inferrna/c82d8ab873ae3b6101c928c87a388f72
from coriander.
Ok. Lets pick one single error, and just fix that one please :-)
Can you run:
OFFSET32_BIT=1 CLANG_HOME=/usr/lib/llvm-3.8 py.test -svx test/test_compile.py -k pointerpointer.cu-mykernel
and then send me:
- full output from this (via gist)
- following files:
/tmp/testprog-device.ll
/tmp/testprog-device.cl
Just for reference purposes, on my box, this test gives the following output:
$ OFFSET32_BIT=1 CLANG_HOME=/usr/lib/llvm-3.8_ py.test -svx test/test_compile.py -k pointerpointer.cu-mykernel
============================= test session starts ==============================
platform linux -- Python 3.5.1+, pytest-3.0.3, py-1.4.31, pluggy-0.4.0 -- /env/env3cl/bin/python3
cachedir: .cache
rootdir: /home/cuda-on-cl, inifile: pytest.ini
plugins: pep8-1.0.6
collecting 1 itemsmarking xfail
marking xfail
marking xfail
marking xfail
collected 10 items
test/test_compile.py::test_compile[test/pointerpointer.cu-mykernel] X server found. dri2 connection failed!
DRM_IOCTL_I915_GEM_APERTURE failed: Invalid argument
Assuming 131072kB available aperture size.
May lead to reduced performance or incorrect rendering.
get chip id failed: -1 [22]
param: 4, val: 0
X server found. dri2 connection failed!
DRM_IOCTL_I915_GEM_APERTURE failed: Invalid argument
Assuming 131072kB available aperture size.
May lead to reduced performance or incorrect rendering.
get chip id failed: -1 [22]
param: 4, val: 0
X server found. dri2 connection failed!
DRM_IOCTL_I915_GEM_APERTURE failed: Invalid argument
Assuming 131072kB available aperture size.
May lead to reduced performance or incorrect rendering.
get chip id failed: -1 [22]
param: 4, val: 0
X server found. dri2 connection failed!
DRM_IOCTL_I915_GEM_APERTURE failed: Invalid argument
Assuming 131072kB available aperture size.
May lead to reduced performance or incorrect rendering.
get chip id failed: -1 [22]
param: 4, val: 0
X server found. dri2 connection failed!
DRM_IOCTL_I915_GEM_APERTURE failed: Invalid argument
Assuming 131072kB available aperture size.
May lead to reduced performance or incorrect rendering.
get chip id failed: -1 [22]
param: 4, val: 0
X server found. dri2 connection failed!
DRM_IOCTL_I915_GEM_APERTURE failed: Invalid argument
Assuming 131072kB available aperture size.
May lead to reduced performance or incorrect rendering.
get chip id failed: -1 [22]
param: 4, val: 0
X server found. dri2 connection failed!
DRM_IOCTL_I915_GEM_APERTURE failed: Invalid argument
Assuming 131072kB available aperture size.
May lead to reduced performance or incorrect rendering.
get chip id failed: -1 [22]
param: 4, val: 0
X server found. dri2 connection failed!
DRM_IOCTL_I915_GEM_APERTURE failed: Invalid argument
Assuming 131072kB available aperture size.
May lead to reduced performance or incorrect rendering.
get chip id failed: -1 [22]
param: 4, val: 0
X server found. dri2 connection failed!
DRM_IOCTL_I915_GEM_APERTURE failed: Invalid argument
Assuming 131072kB available aperture size.
May lead to reduced performance or incorrect rendering.
get chip id failed: -1 [22]
param: 4, val: 0
X server found. dri2 connection failed!
DRM_IOCTL_I915_GEM_APERTURE failed: Invalid argument
Assuming 131072kB available aperture size.
May lead to reduced performance or incorrect rendering.
get chip id failed: -1 [22]
param: 4, val: 0
X server found. dri2 connection failed!
DRM_IOCTL_I915_GEM_APERTURE failed: Invalid argument
Assuming 131072kB available aperture size.
May lead to reduced performance or incorrect rendering.
get chip id failed: -1 [22]
param: 4, val: 0
context <pyopencl.Context at 0x1a7a030 on <pyopencl.Device 'Intel(R) HD Graphics 5500 BroadWell U-Processor GT2' on 'Intel Gen OCL Driver' at 0x7f8146ff8fe0>>
options []
bin/cocl -c /tmp/testprog.cu
+ /usr/lib/llvm-3.8_/bin/clang++ -DUSE_CLEW -std=c++11 -x cuda --cuda-gpu-arch=sm_30 --cuda-device-only -emit-llvm -O0 -S -I/usr/lib/llvm-3.8_/include -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -I/usr/lib/llvm-3.8_/include -std=c++11 -fPIC -fvisibility-inlines-hidden -Wall -W -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wno-missing-field-initializers -pedantic -Wno-long-long -Wno-maybe-uninitialized -Wdelete-non-virtual-dtor -Wno-comment -std=c++11 -ffunction-sections -fdata-sections -O2 -fexceptions -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -I/home/ubuntu/git/cuda-on-cl/include/EasyCL -I/home/ubuntu/git/cuda-on-cl/include/cocl -I/home/ubuntu/git/cuda-on-cl/src -I/home/ubuntu/git/cuda-on-cl/src/EasyCL -I/home/ubuntu/git/cuda-on-cl/src/EasyCL/thirdparty/clew/include -include /home/ubuntu/git/cuda-on-cl/include/cocl/cocl.h -include /home/ubuntu/git/cuda-on-cl/include/cocl/fake_funcs.h -include /home/ubuntu/git/cuda-on-cl/include/cocl/cocl_deviceside.h -I/home/ubuntu/git/cuda-on-cl/include /tmp/testprog.cu -o /tmp/testprog-device-noopt.ll
warning: unknown warning option '-Wno-maybe-uninitialized'; did you mean '-Wno-uninitialized'? [-Wunknown-warning-option]
1 warning generated.
+ /usr/lib/llvm-3.8_/bin/opt -S -o /tmp/testprog-device.ll /tmp/testprog-device-noopt.ll
+ /usr/lib/llvm-3.8_/bin/clang++ -DUSE_CLEW -std=c++11 -x cuda --cuda-host-only -emit-llvm -O3 -S -I/usr/lib/llvm-3.8_/include -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -I/usr/lib/llvm-3.8_/include -std=c++11 -fPIC -fvisibility-inlines-hidden -Wall -W -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wno-missing-field-initializers -pedantic -Wno-long-long -Wno-maybe-uninitialized -Wdelete-non-virtual-dtor -Wno-comment -std=c++11 -ffunction-sections -fdata-sections -O2 -fexceptions -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -I/home/ubuntu/git/cuda-on-cl/include -I/home/ubuntu/git/cuda-on-cl/include/EasyCL -I/home/ubuntu/git/cuda-on-cl/include/cocl -I/home/ubuntu/git/cuda-on-cl/src -I/home/ubuntu/git/cuda-on-cl/src/EasyCL/thirdparty/clew/include -I/home/ubuntu/git/cuda-on-cl/src/EasyCL -I/usr/lib/llvm-3.8_/include -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -I/usr/lib/llvm-3.8_/include -std=c++11 -fPIC -fvisibility-inlines-hidden -Wall -W -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wno-missing-field-initializers -pedantic -Wno-long-long -Wno-maybe-uninitialized -Wdelete-non-virtual-dtor -Wno-comment -std=c++11 -ffunction-sections -fdata-sections -O2 -fexceptions -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -include /home/ubuntu/git/cuda-on-cl/include/cocl/cocl.h -include /home/ubuntu/git/cuda-on-cl/include/cocl/fake_funcs.h -include /home/ubuntu/git/cuda-on-cl/include/cocl/cocl_hostside.h /tmp/testprog.cu -o /tmp/testprog-hostraw.ll
warning: unknown warning option '-Wno-maybe-uninitialized'; did you mean '-Wno-uninitialized'? [-Wunknown-warning-option]
warning: unknown warning option '-Wno-maybe-uninitialized'; did you mean '-Wno-uninitialized'? [-Wunknown-warning-option]
2 warnings generated.
+ /home/ubuntu/git/cuda-on-cl/build/patch-hostside --hostrawfile /tmp/testprog-hostraw.ll --devicellfile /tmp/testprog-device.ll --hostpatchedfile /tmp/testprog-hostpatched.ll
+ /usr/lib/llvm-3.8_/bin/clang++ -I/usr/lib/llvm-3.8_/include -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -I/usr/lib/llvm-3.8_/include -std=c++11 -fPIC -fvisibility-inlines-hidden -Wall -W -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wno-missing-field-initializers -pedantic -Wno-long-long -Wno-maybe-uninitialized -Wdelete-non-virtual-dtor -Wno-comment -std=c++11 -ffunction-sections -fdata-sections -O2 -fexceptions -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -DUSE_CLEW -c /tmp/testprog-hostpatched.ll -O3 -o /tmp/testprog.o
clang: warning: argument unused during compilation: '-I /usr/lib/llvm-3.8_/include'
clang: warning: argument unused during compilation: '-I /usr/lib/llvm-3.8_/include'
warning: unknown warning option '-Wno-maybe-uninitialized'; did you mean '-Wno-uninitialized'? [-Wunknown-warning-option]
1 warning generated.
+ [ ! 1 ]
build/ir-to-opencl --inputfile /tmp/testprog-device.ll --outputfile /tmp/testprog-device.cl --kernelname --add_ir_to_cl
terminate called after throwing an instance of 'std::runtime_error'
what(): Couldnt find kernel
mangledname _Z8mykernelPfP8MyStructi
options []
bin/cocl -c /tmp/testprog.cu
+ /usr/lib/llvm-3.8_/bin/clang++ -DUSE_CLEW -std=c++11 -x cuda --cuda-gpu-arch=sm_30 --cuda-device-only -emit-llvm -O0 -S -I/usr/lib/llvm-3.8_/include -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -I/usr/lib/llvm-3.8_/include -std=c++11 -fPIC -fvisibility-inlines-hidden -Wall -W -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wno-missing-field-initializers -pedantic -Wno-long-long -Wno-maybe-uninitialized -Wdelete-non-virtual-dtor -Wno-comment -std=c++11 -ffunction-sections -fdata-sections -O2 -fexceptions -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -I/home/ubuntu/git/cuda-on-cl/include/EasyCL -I/home/ubuntu/git/cuda-on-cl/include/cocl -I/home/ubuntu/git/cuda-on-cl/src -I/home/ubuntu/git/cuda-on-cl/src/EasyCL -I/home/ubuntu/git/cuda-on-cl/src/EasyCL/thirdparty/clew/include -include /home/ubuntu/git/cuda-on-cl/include/cocl/cocl.h -include /home/ubuntu/git/cuda-on-cl/include/cocl/fake_funcs.h -include /home/ubuntu/git/cuda-on-cl/include/cocl/cocl_deviceside.h -I/home/ubuntu/git/cuda-on-cl/include /tmp/testprog.cu -o /tmp/testprog-device-noopt.ll
warning: unknown warning option '-Wno-maybe-uninitialized'; did you mean '-Wno-uninitialized'? [-Wunknown-warning-option]
1 warning generated.
+ /usr/lib/llvm-3.8_/bin/opt -S -o /tmp/testprog-device.ll /tmp/testprog-device-noopt.ll
+ /usr/lib/llvm-3.8_/bin/clang++ -DUSE_CLEW -std=c++11 -x cuda --cuda-host-only -emit-llvm -O3 -S -I/usr/lib/llvm-3.8_/include -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -I/usr/lib/llvm-3.8_/include -std=c++11 -fPIC -fvisibility-inlines-hidden -Wall -W -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wno-missing-field-initializers -pedantic -Wno-long-long -Wno-maybe-uninitialized -Wdelete-non-virtual-dtor -Wno-comment -std=c++11 -ffunction-sections -fdata-sections -O2 -fexceptions -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -I/home/ubuntu/git/cuda-on-cl/include -I/home/ubuntu/git/cuda-on-cl/include/EasyCL -I/home/ubuntu/git/cuda-on-cl/include/cocl -I/home/ubuntu/git/cuda-on-cl/src -I/home/ubuntu/git/cuda-on-cl/src/EasyCL/thirdparty/clew/include -I/home/ubuntu/git/cuda-on-cl/src/EasyCL -I/usr/lib/llvm-3.8_/include -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -I/usr/lib/llvm-3.8_/include -std=c++11 -fPIC -fvisibility-inlines-hidden -Wall -W -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wno-missing-field-initializers -pedantic -Wno-long-long -Wno-maybe-uninitialized -Wdelete-non-virtual-dtor -Wno-comment -std=c++11 -ffunction-sections -fdata-sections -O2 -fexceptions -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -include /home/ubuntu/git/cuda-on-cl/include/cocl/cocl.h -include /home/ubuntu/git/cuda-on-cl/include/cocl/fake_funcs.h -include /home/ubuntu/git/cuda-on-cl/include/cocl/cocl_hostside.h /tmp/testprog.cu -o /tmp/testprog-hostraw.ll
warning: unknown warning option '-Wno-maybe-uninitialized'; did you mean '-Wno-uninitialized'? [-Wunknown-warning-option]
warning: unknown warning option '-Wno-maybe-uninitialized'; did you mean '-Wno-uninitialized'? [-Wunknown-warning-option]
2 warnings generated.
+ /home/ubuntu/git/cuda-on-cl/build/patch-hostside --hostrawfile /tmp/testprog-hostraw.ll --devicellfile /tmp/testprog-device.ll --hostpatchedfile /tmp/testprog-hostpatched.ll
+ /usr/lib/llvm-3.8_/bin/clang++ -I/usr/lib/llvm-3.8_/include -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -I/usr/lib/llvm-3.8_/include -std=c++11 -fPIC -fvisibility-inlines-hidden -Wall -W -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wno-missing-field-initializers -pedantic -Wno-long-long -Wno-maybe-uninitialized -Wdelete-non-virtual-dtor -Wno-comment -std=c++11 -ffunction-sections -fdata-sections -O2 -fexceptions -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -DUSE_CLEW -c /tmp/testprog-hostpatched.ll -O3 -o /tmp/testprog.o
clang: warning: argument unused during compilation: '-I /usr/lib/llvm-3.8_/include'
clang: warning: argument unused during compilation: '-I /usr/lib/llvm-3.8_/include'
warning: unknown warning option '-Wno-maybe-uninitialized'; did you mean '-Wno-uninitialized'? [-Wunknown-warning-option]
1 warning generated.
+ [ ! 1 ]
build/ir-to-opencl --inputfile /tmp/testprog-device.ll --outputfile /tmp/testprog-device.cl --kernelname _Z8mykernelPfP8MyStructi --add_ir_to_cl
PASSED
============================== 9 tests deselected ==============================
==================== 1 passed, 9 deselected in 3.51 seconds ===================```
from coriander.
(or you can choose if you want:
OFFSET32_BIT=1 CLANG_HOME=/usr/lib/llvm-3.8 py.test -svx test/test_compile.py -k pointerpointer.cu-myte6kernel
This passes ok for me too. Similar output to the above
...
2 warnings generated.
clang: warning: argument unused during compilation: '-I /usr/lib/llvm-3.8_/include'
clang: warning: argument unused during compilation: '-I /usr/lib/llvm-3.8_/include'
warning: unknown warning option '-Wno-maybe-uninitialized'; did you mean '-Wno-uninitialized'? [-Wunknown-warning-option]
1 warning generated.
build/ir-to-opencl --inputfile /tmp/testprog-device.ll --outputfile /tmp/testprog-device.cl --kernelname --add_ir_to_cl
terminate called after throwing an instance of 'std::runtime_error'
what(): Couldnt find kernel
mangledname _Z11myte6kernelP16TensorEvaluator6PfP9GpuDeviceiii
options []
bin/cocl -c /tmp/testprog.cu
warning: unknown warning option '-Wno-maybe-uninitialized'; did you mean '-Wno-uninitialized'? [-Wunknown-warning-option]
1 warning generated.
warning: unknown warning option '-Wno-maybe-uninitialized'; did you mean '-Wno-uninitialized'? [-Wunknown-warning-option]
warning: unknown warning option '-Wno-maybe-uninitialized'; did you mean '-Wno-uninitialized'? [-Wunknown-warning-option]
2 warnings generated.
clang: warning: argument unused during compilation: '-I /usr/lib/llvm-3.8_/include'
clang: warning: argument unused during compilation: '-I /usr/lib/llvm-3.8_/include'
warning: unknown warning option '-Wno-maybe-uninitialized'; did you mean '-Wno-uninitialized'? [-Wunknown-warning-option]
1 warning generated.
build/ir-to-opencl --inputfile /tmp/testprog-device.ll --outputfile /tmp/testprog-device.cl --kernelname _Z11myte6kernelP16TensorEvaluator6PfP9GpuDeviceiii --add_ir_to_cl
PASSED
============================== 9 tests deselected ==============================
==================== 1 passed, 9 deselected in 3.52 seconds ============
from coriander.
https://gist.github.com/inferrna/d1e608b4bdec84f7ace00993be608252
$ OFFSET32_BIT=1 CLANG_HOME=/usr/lib/llvm-3.8 py.test -svx test/test_compile.py -k pointerpointer.cu-mykernel
======================================================================== test session starts =========================================================================
platform linux -- Python 3.5.2, pytest-2.9.1, py-1.4.31, pluggy-0.3.1 -- /usr/bin/python3
cachedir: .cache
rootdir: /media/Compressed/Drivers_bios/src/dev/tensorflow-cl/third_party/cuda-on-cl, inifile: pytest.ini
collecting 0 itemsmarking xfail
marking xfail
marking xfail
marking xfail
collected 9 items
test/test_compile.py::test_compile[test/pointerpointer.cu-mykernel] context <pyopencl.Context at 0x2e1ea40 on <pyopencl.Device 'Pitcairn' on 'AMD Accelerated Parallel Processing' at 0x2eaac00>>
options []
bin/cocl -c /tmp/testprog.cu
warning: unknown warning option '-Wno-maybe-uninitialized'; did you mean '-Wno-uninitialized'? [-Wunknown-warning-option]
1 warning generated.
warning: unknown warning option '-Wno-maybe-uninitialized'; did you mean '-Wno-uninitialized'? [-Wunknown-warning-option]
warning: unknown warning option '-Wno-maybe-uninitialized'; did you mean '-Wno-uninitialized'? [-Wunknown-warning-option]
2 warnings generated.
clang: warning: argument unused during compilation: '-I /usr/lib/llvm-3.8/include'
clang: warning: argument unused during compilation: '-I /usr/lib/llvm-3.8/include'
warning: unknown warning option '-Wno-maybe-uninitialized'; did you mean '-Wno-uninitialized'? [-Wunknown-warning-option]
1 warning generated.
build/ir-to-opencl --inputfile /tmp/testprog-device.ll --outputfile /tmp/testprog-device.cl --kernelname --add_ir_to_cl
terminate called after throwing an instance of 'std::runtime_error'
what(): Couldnt find kernel
mangledname _Z8mykernelPfP8MyStructi
options []
bin/cocl -c /tmp/testprog.cu
warning: unknown warning option '-Wno-maybe-uninitialized'; did you mean '-Wno-uninitialized'? [-Wunknown-warning-option]
1 warning generated.
warning: unknown warning option '-Wno-maybe-uninitialized'; did you mean '-Wno-uninitialized'? [-Wunknown-warning-option]
warning: unknown warning option '-Wno-maybe-uninitialized'; did you mean '-Wno-uninitialized'? [-Wunknown-warning-option]
2 warnings generated.
clang: warning: argument unused during compilation: '-I /usr/lib/llvm-3.8/include'
clang: warning: argument unused during compilation: '-I /usr/lib/llvm-3.8/include'
warning: unknown warning option '-Wno-maybe-uninitialized'; did you mean '-Wno-uninitialized'? [-Wunknown-warning-option]
1 warning generated.
build/ir-to-opencl --inputfile /tmp/testprog-device.ll --outputfile /tmp/testprog-device.cl --kernelname _Z8mykernelPfP8MyStructi --add_ir_to_cl
/usr/local/lib/python3.5/dist-packages/pyopencl/__init__.py:206: CompilerWarning: Non-empty compiler output encountered. Set the environment variable PYOPENCL_COMPILER_OUTPUT=1 to see more.
"to see more.", CompilerWarning)
PASSED
======================================================== 8 tests deselected by '-kpointerpointer.cu-mykernel' ========================================================
=============================================================== 1 passed, 8 deselected in 5.40 seconds ===============================================================```
from coriander.
Ok. mykernel
passes, I noticed that after my first post :-P How about myte6kernel
?
from coriander.
Gist https://gist.github.com/inferrna/d1e608b4bdec84f7ace00993be608252
updated with new test output
from coriander.
Hmmm, ok, I see. I can fix that. I htink :-)
from coriander.
Try now, using branch dev
?
from coriander.
Test passed in dev branch, gist https://gist.github.com/inferrna/c82d8ab873ae3b6101c928c87a388f72 also updated with all tests output
from coriander.
Cool :-) Does that mean that all non-xfailing tests are passing now? Possible to see the output of OFFSET_32BIT=1 CLANG_HOME=/usr/lib/llvm-3.8 py.test -v
?
from coriander.
https://gist.github.com/inferrna/c82d8ab873ae3b6101c928c87a388f72 updated with
CLANG_HOME=/usr/lib/llvm-3.8/ OFFSET_32BIT=1 py.test-3 -v -r a
from coriander.
Excellent! All passing :-) You can ignore the xfail
s, thats ok.
What about the tests in the build
directory? ie, if you do:
cd build
make run-tests
?
from coriander.
Here it is https://gist.github.com/inferrna/604e9f84ea69f3031f54a84e5edf641a
And almost forget - last pytest run ended with segfault.
$ OFFSET32_BIT=1 CLANG_HOME=/usr/lib/llvm-3.8 py.test -svx test/tf/test_tf.py
======================================================================== test session starts =========================================================================
platform linux -- Python 3.5.2, pytest-2.9.1, py-1.4.31, pluggy-0.3.1 -- /usr/bin/python3
cachedir: .cache
rootdir: /media/Compressed/Drivers_bios/src/dev/tensorflow-cl/third_party/cuda-on-cl, inifile: pytest.ini
collected 2 items
test/tf/test_tf.py::test_cwise_sqrt <- test/test/test/test/test/test/test/test/test/test/test/test/test/test/test/test/test/test/test/test/test/test/test/test/test/test/test/test/test/test/test/test/test/test/test/test/test/test/test/test/test/tf/test_tf.py context <pyopencl.Context at 0x2df5410 on <pyopencl.Device 'Pitcairn' on 'AMD Accelerated Parallel Processing' at 0x2e80150>>
options []
opt_options []
iropencl_options []
/usr/lib/llvm-3.8/bin/opt -S test/tf/samples/cwise_op_gpu_sqrt-device-noopt.ll -o /tmp/test-opt.ll
build/ir-to-opencl --inputfile /tmp/test-opt.ll --outputfile /tmp/test-device.cl --kernelname _ZN5Eigen8internal15EigenMetaKernelINS_15TensorEvaluatorIKNS_14TensorAssignOpINS_9TensorMapINS_6TensorIfLi1ELi1EiEELi16ENS_11MakePointerEEEKNS_18TensorCwiseUnaryOpINS0_14scalar_sqrt_opIfEEKNS4_INS5_IKfLi1ELi1EiEELi16ES7_EEEEEENS_9GpuDeviceEEEiEEvT_T0_
Segmentation fault (core dumped)
from coriander.
Ok. the make-runtests
is passing (there's just one that is failing, because it needs >=2 gpus available to run. Thats fine)
For cwise test ... hmmm.... we should first find which executable is crashing. from the output above, it looks like it is opt
that is crashing??? Can you try running:
/usr/lib/llvm-3.8/bin/opt -S test/tf/samples/cwise_op_gpu_sqrt-device-noopt.ll -o /tmp/test-opt.ll
build/ir-to-opencl --inputfile /tmp/test-opt.ll --outputfile /tmp/test-device.cl --kernelname _ZN5Eigen8internal15EigenMetaKernelINS_15TensorEvaluatorIKNS_14TensorAssignOpINS_9TensorMapINS_6TensorIfLi1ELi1EiEELi16ENS_11MakePointerEEEKNS_18TensorCwiseUnaryOpINS0_14scalar_sqrt_opIfEEKNS4_INS5_IKfLi1ELi1EiEELi16ES7_EEEEEENS_9GpuDeviceEEEiEEvT_T0_
... and see what happens? I kind of doubt it is opt
that is crashing, because it's a standard part of clang, and the input is just hte output from running clang -x cuda
on the input .cu
file.
from coriander.
Well... I need to know which line in the python script crashed. Can you give the full output from running OFFSET32_BIT=1 CLANG_HOME=/usr/lib/llvm-3.8 py.test -svx test/tf/test_tf.py
please? (I think there must be some python stack trace too somewhere?)
from coriander.
Actually, hold off a sec. let me update the script, to print out a bit more info.
from coriander.
added a bit more debug output, in de5b094 Can you pul down the latest changes to dev branch, and give the full output for OFFSET32_BIT=1 CLANG_HOME=/usr/lib/llvm-3.8 py.test -svx test/tf/test_tf.py
please? Also, can you provide the following files, if they exist:
- /tmp/test-opt.ll
- /tmp/test-device.cl
from coriander.
======================================================================== test session starts =========================================================================
platform linux -- Python 3.5.2, pytest-2.9.1, py-1.4.31, pluggy-0.3.1 -- /usr/bin/python3
cachedir: .cache
rootdir: /media/Compressed/Drivers_bios/src/dev/tensorflow-cl/third_party/cuda-on-cl, inifile: pytest.ini
collected 2 items
test/tf/test_tf.py::test_cwise_sqrt context <pyopencl.Context at 0x1fa8c50 on <pyopencl.Device 'Pitcairn' on 'AMD Accelerated Parallel Processing' at 0x204a120>>
options []
opt_options []
iropencl_options []
running [/usr/lib/llvm-3.8/bin/opt -S test/tf/samples/cwise_op_gpu_sqrt-device-noopt.ll -o /tmp/test-opt.ll]
running [build/ir-to-opencl --inputfile /tmp/test-opt.ll --outputfile /tmp/test-device.cl --kernelname _ZN5Eigen8internal15EigenMetaKernelINS_15TensorEvaluatorIKNS_14TensorAssignOpINS_9TensorMapINS_6TensorIfLi1ELi1EiEELi16ENS_11MakePointerEEEKNS_18TensorCwiseUnaryOpINS0_14scalar_sqrt_opIfEEKNS4_INS5_IKfLi1ELi1EiEELi16ES7_EEEEEENS_9GpuDeviceEEEiEEvT_T0_]
creating program...
building kernel...
Segmentation fault (core dumped)
Both /tmp/test-opt.ll and /tmp/test-device.cl: https://gist.github.com/inferrna/2c5a56c385e51b63366a96b9d29178f0
I tried to compile /tmp/test-device.cl with pyopencl and it failed when I selected Pitcairn device, but compiled success for CPU. Both devices were present by amd catalyst driver. After I tried to build and analyse this kernel with AMD CodeXL - and with selected Pitcairn device it also failed. You may try to debug it this way. Also it very possible to be just problem of my system configuration - I'm using catalyst 15.12 with patched 4.7 kernel.
from coriander.
Ok. So, the segfault is probably happening inside the GPU driver, at the time of compiling the OpenCL code.
What we need to do probably. "we" meaning: "you" :-P. Is: comment out bits of the code, until we find a single line that if we comment/uncomment changes whether it crashes or not. Ideally the line should be the simplest line possible, ie preferably some assignment or something, not just a call to another function.
I would start by commenting out hte entire contents of the kernel funtoin, ie _ZN5Eigen8internal15EigenMetaKernelINS_15TensorEvaluatorIKNS_14TensorAssignOpINS_9TensorMapINS_6TensorIfLi1ELi1EiEELi16ENS_11MakePointerEEEKNS_18TensorCwiseUnaryOpINS0_14scalar_sqrt_opIfEEKNS4_INS5_IKfLi1ELi1EiEELi16ES7_EEEEEENS_9GpuDeviceEEEiEEvT_T0_
, and compile it, eg using pyopencl. And see if it still crashes. If it still crashes, get back to me, and I'll suggest what else we can commetn out. If it doesnt crash, then gradually uncomment lines in the kernel function, until you find the first line that, uncommenting it, casesu the compiler to crash.
from coriander.
Kernel name seems too long
>>> s = open("/tmp/test-device.cl.orig", "r").read().replace("_ZN5Eigen8internal15EigenMetaKernelINS_15TensorEvaluatorIKNS_14TensorAssignOpINS_9TensorMapINS_6TensorIfLi1ELi1EiEELi16ENS_11MakePointerEEEKNS_18TensorCwiseUnaryOpINS0_14scalar_sqrt_opIfEEKNS4_INS5_IKfLi1ELi1EiEELi16ES7_EEEEEENS_9GpuDeviceEEEiEEvT_T0_", "o"*246)
>>> cl.Program(ctx, s).build()
<pyopencl.Program object at 0x7f9a7bf67630>
>>> s = open("/tmp/test-device.cl.orig", "r").read().replace("_ZN5Eigen8internal15EigenMetaKernelINS_15TensorEvaluatorIKNS_14TensorAssignOpINS_9TensorMapINS_6TensorIfLi1ELi1EiEELi16ENS_11MakePointerEEEKNS_18TensorCwiseUnaryOpINS0_14scalar_sqrt_opIfEEKNS4_INS5_IKfLi1ELi1EiEELi16ES7_EEEEEENS_9GpuDeviceEEEiEEvT_T0_", "o"*247)
>>> cl.Program(ctx, s).build()
<pyopencl.Program object at 0x7f9a7bf67b00>
>>> s = open("/tmp/test-device.cl.orig", "r").read().replace("_ZN5Eigen8internal15EigenMetaKernelINS_15TensorEvaluatorIKNS_14TensorAssignOpINS_9TensorMapINS_6TensorIfLi1ELi1EiEELi16ENS_11MakePointerEEEKNS_18TensorCwiseUnaryOpINS0_14scalar_sqrt_opIfEEKNS4_INS5_IKfLi1ELi1EiEELi16ES7_EEEEEENS_9GpuDeviceEEEiEEvT_T0_", "o"*248)
>>> cl.Program(ctx, s).build()
Segmentation fault (core dumped)
from coriander.
from coriander.
Updated dev
branch with a draft fix. Can you pull down the latest dev
branch, and see to what extent that fixes the issue with long fnciton names, and the failing tests? 4b3d457
from coriander.
Kernel compiled but test failed
https://gist.github.com/inferrna/ccbcedec405c600970a5a097cf995571
from coriander.
from coriander.
Test passed. I also started to run all tests and will report result later
from coriander.
from coriander.
Related Issues (20)
- cocl_py cuda_sample.cu dont work HOT 3
- when run "make -j 8 tests", something went wrong,seems like the "PIE object" problem. HOT 5
- How much work would it be to update to OpenCL 3.0/Cuda 12...cuda has always been back wards compatable HOT 1
- CMake issues
- Cython Integration
- i.MX8M Vivante GPU not working (Sorry I messed up, delete this)
- i.MX8M Vivante GPU Not Working HOT 1
- MacOS installation error [Errno 2] No such file or directory HOT 3
- tests compilation problem HOT 1
- run install and get error HOT 1
- I'm extremely impressed by this project. HOT 2
- questions about cuda api HOT 1
- Windows installation HOT 1
- help with make run-tests HOT 1
- Issue installing on MacOS10.15.5 HOT 2
- Question about generating an executable with multiple source files HOT 1
- Success compiling and running cuda_example.cu on Apple M1 Big sur HOT 1
- diffs to compile for clang 9
- documenting fix for clang error: reference to host function from device HOT 1
- update on compiling with big sure and clang11: HOT 8
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from coriander.