HelloJOCL sigsegv on linux

classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

HelloJOCL sigsegv on linux

kaerwel
Hi all,

I have tried to run the HelloJOCL example but my jvm got a sig segv :

created CLContext [id: 140086599919776, platform: NVIDIA CUDA, profile: FULL_PROFILE, devices: 1]
using CLDevice [id: 140086600294256 name: GeForce 8400M GS type: GPU profile: FULL_PROFILE]
#
# A fatal error has been detected by the Java Runtime Environment:
#
#  SIGSEGV (0xb) at pc=0x00007f687f387b52, pid=16086, tid=140086771967744
#
# JRE version: 6.0_25-b06
# Java VM: Java HotSpot(TM) 64-Bit Server VM (20.0-b11 mixed mode linux-amd64 compressed oops)
# Problematic frame:
# C  [libc.so.6+0x7bb52]  __strerror_r+0x162
#
# An error report file with more information is saved as:
# /home/.../jocl/hs_err_pid16086.log
#
# If you would like to submit a bug report, please visit:
#   http://java.sun.com/webapps/bugreport/crash.jsp
# The crash happened outside the Java Virtual Machine in native code.
# See problematic frame for where to report the bug.
#

Does anyone have an idea about what happen and how solve this problem ?

Regards.
Reply | Threaded
Open this post in threaded view
|

Re: HelloJOCL sigsegv on linux

Sven Gothel
Administrator
On Tuesday, June 28, 2011 11:27:34 AM kaerwel [via jogamp] wrote:

>
> Hi all,
>
> I have tried to run the HelloJOCL example but my jvm got a sig segv :
>
> created CLContext [id: 140086599919776, platform: NVIDIA CUDA, profile:
> FULL_PROFILE, devices: 1]
> using CLDevice [id: 140086600294256 name: GeForce 8400M GS type: GPU
> profile: FULL_PROFILE]
> #
> # A fatal error has been detected by the Java Runtime Environment:
> #
> #  SIGSEGV (0xb) at pc=0x00007f687f387b52, pid=16086, tid=140086771967744
> #
> # JRE version: 6.0_25-b06
> # Java VM: Java HotSpot(TM) 64-Bit Server VM (20.0-b11 mixed mode
> linux-amd64 compressed oops)
> # Problematic frame:
> # C  [libc.so.6+0x7bb52]  __strerror_r+0x162
> #
> # An error report file with more information is saved as:
> #  http://pastebin.com/ed3jnf0C /home/.../jocl/hs_err_pid16086.log
> #
> # If you would like to submit a bug report, please visit:
> #   http://java.sun.com/webapps/bugreport/crash.jsp
> # The crash happened outside the Java Virtual Machine in native code.
> # See problematic frame for where to report the bug.
> #
>
> Does anyone have an idea about what happen and how solve this problem ?
>

The unit test went through w/ the latest builds @ jogamp.org.

I also merged with mbien/master (jocl and jocl-demos) and the HelloJOCL went through.
This will be visible soon on the autobuilds as well.
  http://jogamp.org/git/?p=jocl.git
  http://jogamp.org/git/?p=jocl-demos.git

Will verify this later on, sorry ..

~Sven


> Regards.
>
> _______________________________________________
> If you reply to this email, your message will be added to the discussion below:
> http://forum.jogamp.org/HelloJOCL-sigsegv-on-linux-tp3117173p3117173.html
> To start a new topic under jocl, email [hidden email]
> To unsubscribe from jocl, visit
health & wealth
mailto:
[hidden email] ; http://jausoft.com
land : +49 (471) 4707742 ; cell: +49 (151) 28145941
Timezone CET: PST+9, EST+6, UTC+1
Reply | Threaded
Open this post in threaded view
|

Re: HelloJOCL sigsegv on linux

Michael Bien
In reply to this post by kaerwel
  On 06/28/2011 11:27 AM, kaerwel [via jogamp] wrote:

> Hi all,
>
> I have tried to run the HelloJOCL example but my jvm got a sig segv :
>
> created CLContext [id: 140086599919776, platform: NVIDIA CUDA, profile:
> FULL_PROFILE, devices: 1]
> using CLDevice [id: 140086600294256 name: GeForce 8400M GS type: GPU
> profile: FULL_PROFILE]
> #
> # A fatal error has been detected by the Java Runtime Environment:
> #
> #  SIGSEGV (0xb) at pc=0x00007f687f387b52, pid=16086, tid=140086771967744
> #
> # JRE version: 6.0_25-b06
> # Java VM: Java HotSpot(TM) 64-Bit Server VM (20.0-b11 mixed mode
> linux-amd64 compressed oops)
> # Problematic frame:
> # C  [libc.so.6+0x7bb52]  __strerror_r+0x162
> #
> # An error report file with more information is saved as:
> #  http://pastebin.com/ed3jnf0C /home/.../jocl/hs_err_pid16086.log
> #
> # If you would like to submit a bug report, please visit:
> #   http://java.sun.com/webapps/bugreport/crash.jsp
> # The crash happened outside the Java Virtual Machine in native code.
> # See problematic frame for where to report the bug.
> #
>
> Does anyone have an idea about what happen and how solve this problem ?
>
> Regards.
>

Hi,

on which NV drivers are you running the demo?

java -jar jocl.jar:gluegen-rt.jar -Djava.library.path="path/to/jocl/libs:path/to/gluegen/libs" com.jogamp.opencl.util.CLInfo

will provide the full device and system properties readout.

I haven't had a segfault using jocl for a long time. Maybe reinstalling
the drivers will already solve the issue.
you could also try a different build:
https://github.com/downloads/mbien/jocl/jocl-0.9-bmanual-20110526-linux-amd64.zip

looking at the error log it looks like the compilation of the CL program
failed on your system and the getBuildLog() used for the exception
message caused the seg fault.


(btw did your JVM automatically upload the error log to pastebin? :D )

regards,
michael

--
http://michael-bien.com/

Reply | Threaded
Open this post in threaded view
|

Re: HelloJOCL sigsegv on linux

kaerwel
Thanks for your replies, and sorry for the delay of my own :(
Yes my jvm is so nice to direct upload to pastebin ;) he he

Still get the same segfault with your manual build.

Here is the CLInfo :

HOST_JRE: 1.6.0_25-b06
HOST_JVM: Java HotSpot(TM) 64-Bit Server VM
HOST_ARCH: amd64
HOST_NUM_CORES: 2
HOST_OS: Linux
HOST_LITTLE_ENDIAN: true
CL_BINDING_UNAVAILABLE_FUNCTIONS: [clCreateEventFromGLsyncKHR, clIcdGetPlatformIDsKHR]

CL_PLATFORM_NAME: NVIDIA CUDA
CL_PLATFORM_VERSION: OpenCL 1.0 CUDA 4.0.1
CL_PLATFORM_PROFILE: FULL_PROFILE
CL_PLATFORM_VENDOR: NVIDIA Corporation
CL_PLATFORM_ICD_SUFFIX_KHR: NV
CL_PLATFORM_EXTENSIONS: [cl_khr_icd, cl_khr_byte_addressable_store, cl_nv_compiler_options, cl_nv_pragma_unroll, cl_nv_device_attribute_query, cl_khr_gl_sharing]

 - CL_DEVICE_NAME: GeForce 8400M GS
 - CL_DEVICE_TYPE: GPU
 - CL_DEVICE_ENDIAN_LITTLE: true
 - CL_DEVICE_VERSION: OpenCL 1.0 CUDA
 - CL_DEVICE_PROFILE: FULL_PROFILE
 - CL_DEVICE_VENDOR: NVIDIA Corporation
 - CL_DEVICE_EXTENSIONS: [cl_khr_icd, cl_khr_byte_addressable_store, cl_nv_compiler_options, cl_nv_pragma_unroll, cl_nv_device_attribute_query, cl_khr_global_int32_base_atomics, cl_khr_gl_sharing, cl_khr_global_int32_extended_atomics]
 - CL_DEVICE_MAX_COMPUTE_UNITS: 2
 - CL_DEVICE_MAX_CLOCK_FREQUENCY: 800
 - CL_DEVICE_VENDOR_ID: 4318
 - CL_DEVICE_OPENCL_C_VERSION: com.jogamp.opencl.CLException$CLInvalidValueException: error while asking for info string [error: CL_INVALID_VALUE]
 - CL_DRIVER_VERSION: 275.09.07
 - CL_DEVICE_ADDRESS_BITS: 32
 - CL_DEVICE_PREFERRED_VECTOR_WIDTH_SHORT: 1
 - CL_DEVICE_PREFERRED_VECTOR_WIDTH_CHAR: 1
 - CL_DEVICE_PREFERRED_VECTOR_WIDTH_INT: 1
 - CL_DEVICE_PREFERRED_VECTOR_WIDTH_LONG: 1
 - CL_DEVICE_PREFERRED_VECTOR_WIDTH_FLOAT: 1
 - CL_DEVICE_PREFERRED_VECTOR_WIDTH_DOUBLE: 0
 - CL_DEVICE_NATIVE_VECTOR_WIDTH_CHAR: com.jogamp.opencl.CLException$CLInvalidValueException: error while asking for info value [error: CL_INVALID_VALUE]
 - CL_DEVICE_NATIVE_VECTOR_WIDTH_SHORT: com.jogamp.opencl.CLException$CLInvalidValueException: error while asking for info value [error: CL_INVALID_VALUE]
 - CL_DEVICE_NATIVE_VECTOR_WIDTH_INT: com.jogamp.opencl.CLException$CLInvalidValueException: error while asking for info value [error: CL_INVALID_VALUE]
 - CL_DEVICE_NATIVE_VECTOR_WIDTH_LONG: com.jogamp.opencl.CLException$CLInvalidValueException: error while asking for info value [error: CL_INVALID_VALUE]
 - CL_DEVICE_NATIVE_VECTOR_WIDTH_HALF: com.jogamp.opencl.CLException$CLInvalidValueException: error while asking for info value [error: CL_INVALID_VALUE]
 - CL_DEVICE_NATIVE_VECTOR_WIDTH_FLOAT: com.jogamp.opencl.CLException$CLInvalidValueException: error while asking for info value [error: CL_INVALID_VALUE]
 - CL_DEVICE_NATIVE_VECTOR_WIDTH_DOUBLE: com.jogamp.opencl.CLException$CLInvalidValueException: error while asking for info value [error: CL_INVALID_VALUE]
 - CL_DEVICE_MAX_WORK_GROUP_SIZE: 512
 - CL_DEVICE_MAX_WORK_ITEM_DIMENSIONS: 3
 - CL_DEVICE_MAX_WORK_ITEM_SIZES: [512, 512, 64]
 - CL_DEVICE_MAX_PARAMETER_SIZE: 4352
 - CL_DEVICE_MAX_MEM_ALLOC_SIZE: 134217728
 - CL_DEVICE_GLOBAL_MEM_SIZE: 133496832
 - CL_DEVICE_LOCAL_MEM_SIZE: 16384
 - CL_DEVICE_HOST_UNIFIED_MEMORY: com.jogamp.opencl.CLException$CLInvalidValueException: error while asking for info value [error: CL_INVALID_VALUE]
 - CL_DEVICE_MAX_CONSTANT_BUFFER_SIZE: 65536
 - CL_DEVICE_GLOBAL_MEM_CACHELINE_SIZE: 0
 - CL_DEVICE_GLOBAL_MEM_CACHE_SIZE: 0
 - CL_DEVICE_MAX_CONSTANT_ARGS: 9
 - CL_DEVICE_IMAGE_SUPPORT: true
 - CL_DEVICE_MAX_READ_IMAGE_ARGS: 128
 - CL_DEVICE_MAX_WRITE_IMAGE_ARGS: 8
 - CL_DEVICE_IMAGE2D_MAX_WIDTH: 4096
 - CL_DEVICE_IMAGE2D_MAX_HEIGHT: 32768
 - CL_DEVICE_IMAGE3D_MAX_WIDTH: 2048
 - CL_DEVICE_IMAGE3D_MAX_HEIGHT: 2048
 - CL_DEVICE_IMAGE3D_MAX_DEPTH: 2048
 - CL_DEVICE_MAX_SAMPLERS: 16
 - CL_DEVICE_PROFILING_TIMER_RESOLUTION: 1000
 - CL_DEVICE_EXECUTION_CAPABILITIES: [EXEC_KERNEL]
 - CL_DEVICE_HALF_FP_CONFIG: []
 - CL_DEVICE_SINGLE_FP_CONFIG: [INF_NAN, ROUND_TO_NEAREST, ROUND_TO_INF, ROUND_TO_ZERO, FMA]
 - CL_DEVICE_DOUBLE_FP_CONFIG: []
 - CL_DEVICE_LOCAL_MEM_TYPE: LOCAL
 - CL_DEVICE_GLOBAL_MEM_CACHE_TYPE: NONE
 - CL_DEVICE_QUEUE_PROPERTIES: [OUT_OF_ORDER_MODE, PROFILING_MODE]
 - CL_DEVICE_AVAILABLE: true
 - CL_DEVICE_COMPILER_AVAILABLE: true
 - CL_DEVICE_ERROR_CORRECTION_SUPPORT: false
 - cl_khr_fp16: false
 - cl_khr_fp64: false
 - cl_khr_gl_sharing | cl_APPLE_gl_sharing: true
Reply | Threaded
Open this post in threaded view
|

Re: HelloJOCL sigsegv on linux

Michael Bien
  i updated to the exact same driver version and tested on a GTX295 and
all OpenCL 1.0 tests are green (HelloJOCL works too..).

could be a driver issue. As i mentioned in my previous mail the segfault
happened as the exception string for a failed build was assembled
(asking the compiler for the build log). You could run into a cornercase
where the driver decides to invalidate the program when the build fails
or something like that (which would not be spec conform of course). NV
OpenCL drivers are known to be not up2date, I don't think i can do much
to resolve the issue.

You could try to install the AMD or Intel sdk and run it on the CPU if
you like.

best regards,
michael

On 07/06/2011 02:02 PM, kaerwel [via jogamp] wrote:

> Thanks for your replies, and sorry for the delay of my own :(
> Yes my jvm is so nice to direct upload to pastebin ;) he he
>
> Still get the same segfault with your manual build.
>
> Here is the CLInfo :
>
> HOST_JRE: 1.6.0_25-b06
> HOST_JVM: Java HotSpot(TM) 64-Bit Server VM
> HOST_ARCH: amd64
> HOST_NUM_CORES: 2
> HOST_OS: Linux
> HOST_LITTLE_ENDIAN: true
> CL_BINDING_UNAVAILABLE_FUNCTIONS: [clCreateEventFromGLsyncKHR,
> clIcdGetPlatformIDsKHR]
>
> CL_PLATFORM_NAME: NVIDIA CUDA
> CL_PLATFORM_VERSION: OpenCL 1.0 CUDA 4.0.1
> CL_PLATFORM_PROFILE: FULL_PROFILE
> CL_PLATFORM_VENDOR: NVIDIA Corporation
> CL_PLATFORM_ICD_SUFFIX_KHR: NV
> CL_PLATFORM_EXTENSIONS: [cl_khr_icd, cl_khr_byte_addressable_store,
> cl_nv_compiler_options, cl_nv_pragma_unroll, cl_nv_device_attribute_query,
> cl_khr_gl_sharing]
>
>   - CL_DEVICE_NAME: GeForce 8400M GS
>   - CL_DEVICE_TYPE: GPU
>   - CL_DEVICE_ENDIAN_LITTLE: true
>   - CL_DEVICE_VERSION: OpenCL 1.0 CUDA
>   - CL_DEVICE_PROFILE: FULL_PROFILE
>   - CL_DEVICE_VENDOR: NVIDIA Corporation
>   - CL_DEVICE_EXTENSIONS: [cl_khr_icd, cl_khr_byte_addressable_store,
> cl_nv_compiler_options, cl_nv_pragma_unroll, cl_nv_device_attribute_query,
> cl_khr_global_int32_base_atomics, cl_khr_gl_sharing,
> cl_khr_global_int32_extended_atomics]
>   - CL_DEVICE_MAX_COMPUTE_UNITS: 2
>   - CL_DEVICE_MAX_CLOCK_FREQUENCY: 800
>   - CL_DEVICE_VENDOR_ID: 4318
>   - CL_DEVICE_OPENCL_C_VERSION:
> com.jogamp.opencl.CLException$CLInvalidValueException: error while asking
> for info string [error: CL_INVALID_VALUE]
>   - CL_DRIVER_VERSION: 275.09.07
>   - CL_DEVICE_ADDRESS_BITS: 32
>   - CL_DEVICE_PREFERRED_VECTOR_WIDTH_SHORT: 1
>   - CL_DEVICE_PREFERRED_VECTOR_WIDTH_CHAR: 1
>   - CL_DEVICE_PREFERRED_VECTOR_WIDTH_INT: 1
>   - CL_DEVICE_PREFERRED_VECTOR_WIDTH_LONG: 1
>   - CL_DEVICE_PREFERRED_VECTOR_WIDTH_FLOAT: 1
>   - CL_DEVICE_PREFERRED_VECTOR_WIDTH_DOUBLE: 0
>   - CL_DEVICE_NATIVE_VECTOR_WIDTH_CHAR:
> com.jogamp.opencl.CLException$CLInvalidValueException: error while asking
> for info value [error: CL_INVALID_VALUE]
>   - CL_DEVICE_NATIVE_VECTOR_WIDTH_SHORT:
> com.jogamp.opencl.CLException$CLInvalidValueException: error while asking
> for info value [error: CL_INVALID_VALUE]
>   - CL_DEVICE_NATIVE_VECTOR_WIDTH_INT:
> com.jogamp.opencl.CLException$CLInvalidValueException: error while asking
> for info value [error: CL_INVALID_VALUE]
>   - CL_DEVICE_NATIVE_VECTOR_WIDTH_LONG:
> com.jogamp.opencl.CLException$CLInvalidValueException: error while asking
> for info value [error: CL_INVALID_VALUE]
>   - CL_DEVICE_NATIVE_VECTOR_WIDTH_HALF:
> com.jogamp.opencl.CLException$CLInvalidValueException: error while asking
> for info value [error: CL_INVALID_VALUE]
>   - CL_DEVICE_NATIVE_VECTOR_WIDTH_FLOAT:
> com.jogamp.opencl.CLException$CLInvalidValueException: error while asking
> for info value [error: CL_INVALID_VALUE]
>   - CL_DEVICE_NATIVE_VECTOR_WIDTH_DOUBLE:
> com.jogamp.opencl.CLException$CLInvalidValueException: error while asking
> for info value [error: CL_INVALID_VALUE]
>   - CL_DEVICE_MAX_WORK_GROUP_SIZE: 512
>   - CL_DEVICE_MAX_WORK_ITEM_DIMENSIONS: 3
>   - CL_DEVICE_MAX_WORK_ITEM_SIZES: [512, 512, 64]
>   - CL_DEVICE_MAX_PARAMETER_SIZE: 4352
>   - CL_DEVICE_MAX_MEM_ALLOC_SIZE: 134217728
>   - CL_DEVICE_GLOBAL_MEM_SIZE: 133496832
>   - CL_DEVICE_LOCAL_MEM_SIZE: 16384
>   - CL_DEVICE_HOST_UNIFIED_MEMORY:
> com.jogamp.opencl.CLException$CLInvalidValueException: error while asking
> for info value [error: CL_INVALID_VALUE]
>   - CL_DEVICE_MAX_CONSTANT_BUFFER_SIZE: 65536
>   - CL_DEVICE_GLOBAL_MEM_CACHELINE_SIZE: 0
>   - CL_DEVICE_GLOBAL_MEM_CACHE_SIZE: 0
>   - CL_DEVICE_MAX_CONSTANT_ARGS: 9
>   - CL_DEVICE_IMAGE_SUPPORT: true
>   - CL_DEVICE_MAX_READ_IMAGE_ARGS: 128
>   - CL_DEVICE_MAX_WRITE_IMAGE_ARGS: 8
>   - CL_DEVICE_IMAGE2D_MAX_WIDTH: 4096
>   - CL_DEVICE_IMAGE2D_MAX_HEIGHT: 32768
>   - CL_DEVICE_IMAGE3D_MAX_WIDTH: 2048
>   - CL_DEVICE_IMAGE3D_MAX_HEIGHT: 2048
>   - CL_DEVICE_IMAGE3D_MAX_DEPTH: 2048
>   - CL_DEVICE_MAX_SAMPLERS: 16
>   - CL_DEVICE_PROFILING_TIMER_RESOLUTION: 1000
>   - CL_DEVICE_EXECUTION_CAPABILITIES: [EXEC_KERNEL]
>   - CL_DEVICE_HALF_FP_CONFIG: []
>   - CL_DEVICE_SINGLE_FP_CONFIG: [INF_NAN, ROUND_TO_NEAREST, ROUND_TO_INF,
> ROUND_TO_ZERO, FMA]
>   - CL_DEVICE_DOUBLE_FP_CONFIG: []
>   - CL_DEVICE_LOCAL_MEM_TYPE: LOCAL
>   - CL_DEVICE_GLOBAL_MEM_CACHE_TYPE: NONE
>   - CL_DEVICE_QUEUE_PROPERTIES: [OUT_OF_ORDER_MODE, PROFILING_MODE]
>   - CL_DEVICE_AVAILABLE: true
>   - CL_DEVICE_COMPILER_AVAILABLE: true
>   - CL_DEVICE_ERROR_CORRECTION_SUPPORT: false
>   - cl_khr_fp16: false
>   - cl_khr_fp64: false
>   - cl_khr_gl_sharing | cl_APPLE_gl_sharing: true
>
> _______________________________________________
> If you reply to this email, your message will be added to the discussion below:
> http://forum.jogamp.org/HelloJOCL-sigsegv-on-linux-tp3117173p3144423.html
> To start a new topic under jogamp, email [hidden email]
> To unsubscribe from jogamp, visit
http://michael-bien.com/

Reply | Threaded
Open this post in threaded view
|

Re: HelloJOCL sigsegv on linux

kaerwel
I re-install all my debian with nvidia-glx=275.09.07-4 and nvidia-opencl-common and the HelloJOCL works nice now ... Strange.

Thanks for your help.