raxtechbits / gpuocelot

Automatically exported from code.google.com/p/gpuocelot
0 stars 0 forks source link

ocelot segaults #26

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
Hi, i got newest ocelot and running memoryErrors from wiki crashes :

[Thread debugging using libthread_db enabled]
[New Thread 0x7f3822d42760 (LWP 21763)]

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0x7f3822d42760 (LWP 21763)]
0x00007f382269066b in executive::Executive::getSelectedISA (this=0xdec9d8) 
at ocelot/executive/implementation/Executive.cpp:358
358             }
(gdb) bt
#0  0x00007f382269066b in executive::Executive::getSelectedISA 
(this=0xdec9d8) at ocelot/executive/implementation/Executive.cpp:358
#1  0x00007f38226921c2 in executive::Executive::loadModule (this=0xdec9d8, 
path=<value optimized out>, translateToSelected=true, 
    stream=0x7fff2ad6d7d0) at ocelot/executive/implementation/
Executive.cpp:209
#2  0x00007f38217010f8 in cuda::CudaRuntime::registerFatBinary 
(this=0xdec4f8, binary=@0x6151a0)
    at ocelot/cuda/implementation/CudaRuntime.cpp:604
#3  0x00007f382170f5ab in cuda::CudaRuntimeBase::cudaRegisterFatBinary 
(this=<value optimized out>, fatCubin=0x6151a0)
    at ocelot/cuda/implementation/CudaRuntimeBase.cpp:1482
#4  0x000000000040a485 in 
__sti____cudaRegisterAll_47_tmpxft_0000112c_00000000_4_memoryErrors_cpp1_ii_41d2
9f55 
()
    at /tmp/tmpxft_0000112c_00000000-1_memoryErrors.cudafe1.stub.c:29
#5  0x000000000040f8c6 in ?? ()
#6  0x00007f3822d6e000 in ?? ()
#7  0x000000000040f7f0 in ?? ()
#8  0x0000000000000000 in ?? ()

Additionaly compiling LLVMExecutableKernel.cpp fails with

 g++ -DHAVE_CONFIG_H -I. -Wall -ansi -pedantic -Werror -std=c++0x -g -O2 -
MT libOcelotExecutive_la-LLVMExecutableKernel.lo -MD -MP -MF .deps/
libOcelotExecutive_la-LLVMExecutableKernel.Tpo -c ocelot/executive/
implementation/LLVMExecutableKernel.cpp  -fPIC -DPIC -o .libs/
libOcelotExecutive_la-LLVMExecutableKernel.o
cc1plus: warnings being treated as errors
ocelot/executive/implementation/LLVMExecutableKernel.cpp: In destructor 
'virtual executive::LLVMExecutableKernel::~LLVMExecutableKernel()':
ocelot/executive/implementation/LLVMExecutableKernel.cpp:47: error: 
possible problem detected in invocation of delete operator:
ocelot/executive/implementation/LLVMExecutableKernel.cpp:47: error: 
invalid use of incomplete type 'struct llvm::Module'
./ocelot/executive/interface/LLVMExecutableKernel.h:16: error: forward 
declaration of 'struct llvm::Module'
ocelot/executive/implementation/LLVMExecutableKernel.cpp:47: note: neither 
the destructor nor the class-specific operator delete will be called, even 
if they are declared when the class is defined.
make[1]: *** [libOcelotExecutive_la-LLVMExecutableKernel.lo] Error 1

Commenting out this line allowed me to compile, although obvious this is 
not a fix :).

Original issue reported on code.google.com by korgulec@gmail.com on 8 Sep 2009 at 9:45

GoogleCodeExporter commented 8 years ago
ifdef'ing HAVE_LLVM around delete module handles compilation.

The sagault is because selectedDevice is not initialized (I guess you forgot to 
call 
selectDeviceByISA or select on Executive).

Original comment by korgulec@gmail.com on 8 Sep 2009 at 10:14

GoogleCodeExporter commented 8 years ago
Should be fixed, see r129 .  Please verify that this resolves your problem.

Also as a warning. LLVM support is being added right now and the trunk may break
occasionally in LLVM related features in the near future.  We appreciate any bug
reports that we get during this transition as there are likely to be a lot of 
them.

Original comment by gregory....@gatech.edu on 9 Sep 2009 at 8:54