As a CUDA programmer, I know that having a computer with an NVIDIA graphics card is essential. However, it’s not always possible to have access to a desktop machine with a CUDA capable device.
In my case, I just sold my desktop PC so my only computing tool right now is a little 11″ Acer 1830T which doesn’t have an NVIDIA graphics card. I do have access via ssh to a GTX460 at the institute which is great for long simulations but when programming/debugging a new module I prefer working locally.
I don’t know if it’s possible to add a virtual graphics card in my OS linked to the institute’s card, so that I can run my code locally while the program is actually executing remotely I just found out this is possible with rcuda and it might be also possible with gpuocelot for it supports Remote CUDA Runtime. Surely, I can simulate this using sshfs + ssh with X11 forwarding but it just doesn’t feel the same.
While programming locally I’m not really concerned about performance so the solution I found is called gpuocelot. This framework allows you to run CUDA programs on NVIDIA or AMD GPU’s and of course X86 CPU‘s. The problem is that the documentation is very poor.
They have two installation “manuals”: manual 1 and manual 2. But just taking a look at the comments will make you give up before trying.
They provide you with some .deb files to make the installation process painless, but it didn’t work for me because they are compiled for Ubuntu 11.04/11.10. Without further ado, I’ll explain step by step how I did to get gpuocelot up and running in a clean Ubuntu 12.04 LTS installation.
Installing CUDA
The first step is to install the CUDA Toolkit. Here I installed CUDA 4.0 as this is robustly supported by gpuocelot. To do this just go here.
Assuming the file is in your Downloads folder, to install it just do
cd ~/Downloads chmod +x cudatoolkit_4.0.17_linux_32_ubuntu10.10.run sudo ./cudatoolkit_4.0.17_linux_32_ubuntu10.10.run
In my case the file name is for the 32-bit version.
Next we need to install gcc version 4.4 by typing the following
sudo update-alternatives \ --install /usr/bin/gcc gcc /usr/bin/gcc-4.6 40 \ --slave /usr/bin/g++ g++ /usr/bin/g++-4.6 sudo update-alternatives \ --install /usr/bin/gcc gcc /usr/bin/gcc-4.4 60 \ --slave /usr/bin/g++ g++ /usr/bin/g++-4.4
Then do
sudo update-alternatives --config gcc
and select the version 4.4, it was 0 in my case. Just to check everything went well, type
gcc --version
and make sure it says 4.4.
Next we need to add the proper paths in .bashrc, do
nano ~/.bashrc
and add:
export PATH=$PATH:/usr/local/cuda/bin export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/cuda/lib:/usr/local/lib export CPLUS_INCLUDE_PATH=/usr/local/cuda/include
to the end of the file, then press ctrl-x and y to save and exit. Finally do
source ~/.bashrc
and CUDA should be set up. You can check this by typing
nvcc --version
Now we’re ready to install gpuocelot, first download these files:
libboost-filesystem1.42.0_1.42.0-3ubuntu1_i386.deb libboost-system1.42.0_1.42.0-4ubuntu2_i386.deb libboost-thread1.42.0_1.42.0-4ubuntu2_i386.deb
you can do that from here.
Installing gpuocelot from a .deb file
Just download the .deb file for your system from here. In my case it was ocelot_2.1.1272_i386.deb. Then just double-click that and it should open in the Ubuntu software center, then you click install and wait. When it finishes installing just do, assuming the libboost files are in the Downloads folder.
cd ~/Downloads sudo dpkg -i libboost-system1.42.0_1.42.0-4ubuntu2_i386.deb sudo dpkg -i libboost-filesystem1.42.0_1.42.0-3ubuntu1_i386.deb sudo dpkg -i libboost-thread1.42.0_1.42.0-4ubuntu2_i386.deb
And that’s it, you can start executing CUDA programs, I’ll explain how to compile them at the end of this post.
Installing gpuocelot from the SVN
If you want to build gpuocelot for your system, then follow these steps.
Download gpuocelot and llvm sources from
svn checkout http://gpuocelot.googlecode.com/svn/trunk/ gpuocelot-read-on svn co http://llvm.org/svn/llvm-project/llvm/trunk llvm
Then install the necessary packages
sudo apt-get install libboost-all-dev sudo apt-get install flex bison scons libglu-dev
and downgrade the version of boost to 1.42
cd ~/Downloads sudo dpkg -i libboost-system1.42.0_1.42.0-4ubuntu2_i386.deb sudo dpkg -i libboost-filesystem1.42.0_1.42.0-3ubuntu1_i386.deb sudo dpkg -i libboost-thread1.42.0_1.42.0-4ubuntu2_i386.deb
Now install llvm
cd ~/llvm sudo ./configure sudo make install
Finally install gpuocelot with
cd ~/gpuocelot-read-only/ocelot sudo ./build.py --install
That’s it. Now let’s compile and execute our first CUDA program in gpuocelot.
Compiling
To compile you have to put a file called configure.ocelot in the same directory your code is. To configure this file you can check this guide. Here’s an example of the contents of this file:
{ ocelot: "ocelot", trace: { database: "traces/database.trace", memoryChecker: { enabled: false, checkInitialization: false }, raceDetector: { enabled: false, ignoreIrrelevantWrites: false }, debugger: { enabled: false, kernelFilter: "", alwaysAttach: true } }, cuda: { implementation: "CudaRuntime", tracePath: "trace/CudaAPI.trace" }, executive: { devices: [llvm], preferredISA: nvidia, optimizationLevel: full, defaultDeviceID: 0, asynchronousKernelLaunch: True, port: 2011, host: "127.0.0.1", workerThreadLimit: 8, warpSize: 16 }, optimizations: { subkernelSize: 10000, } }
You compile with
nvcc -c hello.cu -arch=sm_20 g++ -o hello.out hello.o `OcelotConfig -l`
And then you run as you normally would.
./hello.out
Here’s a hello world example to test your installation.
#include <stdio.h> #include <stdlib.h> #include <iostream> #include <cuda.h> using namespace std; #define imin(a,b) (a<b?a:b) const int N = 1*1024; const int threadsPerBlock = 512; const int blocksPerGrid = imin(32,(N+threadsPerBlock-1)/threadsPerBlock); __global__ void dot( float *a, float *b, float *c ) { __shared__ float cache[threadsPerBlock]; int tid = threadIdx.x + blockIdx.x * blockDim.x; int cacheIndex = threadIdx.x; float temp = 0; while (tid < N) { temp += a[tid] * b[tid]; tid += blockDim.x * gridDim.x; } cache[cacheIndex] = temp; __syncthreads(); int i = blockDim.x/2; while (i != 0) { if (cacheIndex < i){ cache[cacheIndex] += cache[cacheIndex + i]; } __syncthreads(); i /= 2; } if (cacheIndex == 0){ c[blockIdx.x] = cache[0]; } } int main( void ) { cout << "dot product" << endl; float *a, *b, c, *partial_c; float *dev_a, *dev_b, *dev_partial_c; a = new float[N]; b = new float[N]; partial_c = new float[N]; for (int i=0; i<N; i++) { a[i] = i; b[i] = i*2.0f; } cudaMalloc( (void**)&dev_a, N*sizeof(float) ) ; cudaMalloc( (void**)&dev_b, N*sizeof(float) ) ; cudaMalloc( (void**)&dev_partial_c, blocksPerGrid*sizeof(float) ) ; cudaMemcpy( dev_a, a, N*sizeof(float), cudaMemcpyHostToDevice ) ; cudaMemcpy( dev_b, b, N*sizeof(float), cudaMemcpyHostToDevice ) ; dot<<<blocksPerGrid,threadsPerBlock>>>( dev_a, dev_b, dev_partial_c ); cudaMemcpy( partial_c, dev_partial_c, blocksPerGrid*sizeof(float),cudaMemcpyDeviceToHost ) ; c = 0; for (int i=0; i<blocksPerGrid; i++) { c += partial_c[i]; } //checks result in CPU #define sum_sq(x) (x*(x+1)*(2*x+1)/6) float result = 2 * sum_sq( (float)(N - 1) ); cout << " GPU: " << c << endl; cout << " CPU: " << result << endl; cudaFree( dev_a ) ; cudaFree( dev_b ) ; cudaFree( dev_partial_c ) ; delete[] a; delete[] b; delete[] partial_c; }
This tutorial was very usefull. Thank you so much. Nice job.
Thank you very much for this guide. I got as far as compiling and running my .cu files, but the calculations done by the emulated GPU are completely wrong. I know the code is right because it runs fine on an actual CUDA machine in Visual Studio. Would you have any idea why that might be?
What kind of functions and resources are you using? (atomics, textures, curand, etc). I suggest you debug every operation you do and compare it to the CUDA output to pinpoint the problem. I would be interested to know what’s causing the discrepancy.
I would also be interested to know what caused the discrepancy. You may wish to submit your examples to the GPU Ocelot mailing list so we can take a closer look and figure out a solution.
http://gpuocelot.gatech.edu/contact/
Best of luck.
Thanks for sharing this. A small question. If I change llvm to emulated in the config file, I got a barrier deadlock.
——
Running on: “Ocelot PTX Emulator”
CUDA Capability Major/Minor version number: 2.1
dot product
terminate called after throwing an instance of ‘executive::RuntimeException’
what(): barrier deadlock:
——
Does it happen in your system too? I run many others examples without troubles, but I’m concerned about this sync exeption.
Regards.
It’s possible the emulator’s reconvergence mechanism is failing.
Try using IPDOM or barrier reconvergence by editing configure.ocelot as follows:
executive: {
…
devices: [“emulated”],
reconvergenceMechanism: “ipdom”,
…
}
or
executive: {
…
devices: [“emulated”],
reconvergenceMechanism: “barrier”,
…
}
It might be helpful if you could post your failing example(s) to the GPU Ocelot mailing list so we could debug whichever reconvergence mechanism you had enabled.
Best of luck.
I suppose you are trying to run the hello world code I posted, I changed llvm to emulated but it runs fine, I don’t get any errors. What versions are you using?
That’s strange. Yes, I’m running your code, with your config file and ocelot revision 2004.
Adding reconvergenceMechanism: “barrier”, as suggested by Andrew solves the problem. Using ipdom mechanism generates again
—–
./hello
Running on: “Ocelot PTX Emulator”
CUDA Capability Major/Minor version number: 2.1
dot product
terminate called after throwing an instance of ‘executive::RuntimeException’
what(): barrier deadlock:
context at: [PC: 64] ../src/hello.cu:45:1
——
Any clue of what causes this?
i have this problem
when i run a command
” sudo ./build.py –install ”
scons -Q install=true
Build rules for Ocelot….
Ocelot will be installed at /usr/local
config_h_build([“.release_build/configure.h”], [“configure.h.in”])
g++ -o .release_build/ocelot/parser/implementation/PTXLexer.os -c -O2 -Wall -Werror -std=c++0x -D_DEBUG -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -fPIC -I. -I/usr/include -I/usr/include -I/usr/local/include -I.release_build -I. ocelot/parser/implementation/PTXLexer.cpp
ocelot/parser/implementation/PTXLexer.cpp: In static member function ‘static std::string parser::PTXLexer::toString(int)’:
ocelot/parser/implementation/PTXLexer.cpp:51: error: ‘OPCODE_BFE’ was not declared in this scope
ocelot/parser/implementation/PTXLexer.cpp:143: error: ‘TOKEN_SM30’ was not declared in this scope
ocelot/parser/implementation/PTXLexer.cpp:144: error: ‘TOKEN_SM35’ was not declared in this scope
ocelot/parser/implementation/PTXLexer.cpp:202: error: ‘TOKEN_METADATA’ was not declared in this scope
ocelot/parser/implementation/PTXLexer.cpp:280: error: ‘TOKEN_TEXMODE_UNIFIED’ was not declared in this scope
ocelot/parser/implementation/PTXLexer.cpp:281: error: ‘TOKEN_TEXMODE_INDEPENDENT’ was not declared in this scope
ocelot/parser/implementation/PTXLexer.cpp:282: error: ‘TOKEN_PTR’ was not declared in this scope
scons: *** [.release_build/ocelot/parser/implementation/PTXLexer.os] Error 1
Build failed…
Build failed
I’ve the same problem. Any help?
I also have this problem.
check if you have an old ptxgrammar.hpp file installed in /usr/include or some other header lookup path
http://code.google.com/p/gpuocelot/issues/detail?id=79#c1
I got the same problem too. Anyone help me?
Thanks for the tutorial. However, I followed the instructions and get the following error:
ocelot/executive/implementation/LLVMModuleManager.cpp:968:54: error: ‘class llvm::ExecutionEngine’ has no member named ‘getTargetData’
The only difference that I did is to use
1 libboost-filesystem1.42.0_1.42.0-3ubuntu1_amd64.deb
2 libboost-system1.42.0_1.42.0-4ubuntu2_amd64.deb
3 libboost-thread1.42.0_1.42.0-4ubuntu2_amd64.deb
as it is 64-bit system.
Any help? Thank you so much.
Hello all, I have been very busy with master school so I I haven’t been able to try reproduce your errors. I recommend you post your problems to gpuocelot’s Google group directly: https://groups.google.com/forum/?fromgroups#!forum/gpuocelot
Thanks a lot, it really helped…
Wow thanks a lot!!! It really helped me a lot! I’m very thankful
I got this message on a 64 bits system:
ocelot/ocelot/ir/implementation/ExternalFunctionSet.cpp:27:36: fatal error: llvm/Target/TargetData.h: No such file or directory
Solved using the solution described here:
http://stackoverflow.com/questions/12888537/i-cannot-get-a-gpu-emulator-working
“I know this question is now closed but I found the solution for it. When I try to find TargetData.h, it does actually not exist. It was apparently renamed to llvm/DataLayout.h. So, If you simply change the inclussion from “llvm/Target/TargetData.h” to “llvm/DataLayout.h”, it is going to build correctly.”
The continued for a while, but now I have:
g++ -o .release_build/ocelot/executive/implementation/LLVMModuleManager.os -c -O2 -Wall -Werror -std=c++0x -D_DEBUG -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -fPIC -I. -I/usr/include -I/usr/include -I/usr/local/include -I.release_build -I. ocelot/executive/implementation/LLVMModuleManager.cpp
ocelot/executive/implementation/LLVMModuleManager.cpp: In function ‘void executive::optimize(llvm::Module&, translator::Translator::OptimizationLevel)’:
ocelot/executive/implementation/LLVMModuleManager.cpp:969: error: expected type-specifier
ocelot/executive/implementation/LLVMModuleManager.cpp:969: error: expected ‘)’
ocelot/executive/implementation/LLVMModuleManager.cpp:969: error: no matching function for call to ‘llvm::PassManager::add(int*)’
/usr/local/include/llvm/PassManager.h:55: note: candidates are: virtual void llvm::PassManager::add(llvm::Pass*)
scons: *** [.release_build/ocelot/executive/implementation/LLVMModuleManager.os] Error 1
Build failed…
Build failed
hello,
I got all the same issues as you but the last one.
I had ocelot working :
* compiling llvm (rev 169840) with gcc-4.4
* compiling ocelot (rev 2143) with gcc-4.6 (this is required with the last version from the svn repo, in order to workaround ‘nullptr’ erorrs).
* update-alternatives gcc to v4.4 to compile the cuda example presented in this webpage.
regards,
Damien
Hi, I’m new to CUDA and Ubuntu in general. I keep getting an error when I try to install the drivers:
ERROR: Unable to load the kernel module ‘nvidia.ko’. This happens most frequently when this kernel module was built against the wrong or improperly configured kernel sources, with a version of gcc that differs from the one used to build the target kernel, or if a driver such as rivafb, nvidiafb, or nouveau is present and prevents the NVIDIA kernel module from obtaining ownership of the NVIDIA graphics device(s), or NVIDIA GPU installed in this system is not supported by this NVIDIA Linux graphics driver release.
I have blacklisted these drivers:
rivafb
nvidiafb
nouveau
vga16fb
rivatv
amd76x_edac
The gcc version I have (when I run gcc -v)
gcc versions 4.6.3
I’m running Ubuntu 12.04 and can only get the CUDA 5 package (which is actually what I need) that I chose to download for Ubuntu 11.10.
Is there any additional information that could help?
Nevermind. I realized that I was just being not so smart. I wasn’t skipping over the driver installation and going straight to the Toolkit.
Finally Ocelot is working for me! Thanks!!!!
[…] card was insufficient. Finally, using few magical keywords in my Google search I located this blog entry which provided detailed installation procedure for the […]
Thanks, this help me !!!!!
Thanks man!! Amazing tutorial!!!
[…] found this guide helpful, it might have some additional details for installing things under ubuntu and/or […]
Does gpu Ocelot also support PyCuda.
I need to compile PyCuda files but don’t have access to GPU. What do I need to do ?
I don’t know how PyCuda works but for gpuocelot you need to compile in a special way so I don’t think it works out of the box. You should ask in a PyCuda mailing list / forum
Thanks for the great blog, helps a lot. However, I followed your installation steps, but when running your helloworld code, it turns out with following errors:
cuiwl@cuiwl-ThinkCentre-M57e:~/codes$ ./hello.out
dot product
terminate called after throwing an instance of ‘parser::PTXParser::Exception’
what():
Failed to parse file ‘hello.cu’:
1
2
3
4
5
6
7 .version 3.0
8 .target sm_20
9 .address_size 32
10
and the assembly code of helloworld (maybe)
any suggestions?
during llvm installation somany errors are indication.ocelot installation shows buid failed.please reply
I am doing a research project on cuda.I am installing gpu ocelot but the following errors are occured while llvm installation.I can’t go forward .please reply.
llvm[3]: Building Hexagon.td DAG instruction selector implementation with tblgen
llvm[3]: Building Hexagon.td subtarget information with tblgen
llvm[3]: Building Hexagon.td calling convention information with tblgen
llvm[3]: Building Hexagon.td DFA packetizer tables with tblgen
llvm[3]: Compiling HexagonAsmPrinter.cpp for Debug+Asserts build
In file included from HexagonAsmPrinter.cpp:22:
/home/mtech11/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCInst.h:34:57: warning:
extra ‘;’ inside a class [-pedantic]
MCInst(), MCID(0), packetStart(0), packetEnd(0) {};
^
/home/mtech11/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCInst.h:36:61: warning:
extra ‘;’ inside a class [-pedantic]
MCInst(), MCID(&mcid), packetStart(0), packetEnd(0) {};
^
/home/mtech11/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCInst.h:38:57: warning:
extra ‘;’ inside a class [-pedantic]
bool isPacketStart() const { return (packetStart); };
^
/home/mtech11/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCInst.h:39:53: warning:
extra ‘;’ inside a class [-pedantic]
bool isPacketEnd() const { return (packetEnd); };
^
/home/mtech11/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCInst.h:40:53: warning:
extra ‘;’ inside a class [-pedantic]
void setPacketStart(bool Y) { packetStart = Y; };
^
/home/mtech11/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCInst.h:41:49: warning:
extra ‘;’ inside a class [-pedantic]
void setPacketEnd(bool Y) { packetEnd = Y; };
^
/home/mtech11/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCInst.h:42:71: warning:
extra ‘;’ inside a class [-pedantic]
void resetPacket() { setPacketStart(false); setPacketEnd(false); };
^
/home/mtech11/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCInst.h:50:60: warning:
extra ‘;’ inside a class [-pedantic]
void setDesc(const MCInstrDesc& mcid) { MCID = &mcid; };
^
/home/mtech11/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCInst.h:51:61: warning:
extra ‘;’ inside a class [-pedantic]
const MCInstrDesc& getDesc(void) const { return *MCID; };
^
9 warnings generated.
llvm[3]: Compiling HexagonCFGOptimizer.cpp for Debug+Asserts build
llvm[3]: Compiling HexagonCallingConvLower.cpp for Debug+Asserts build
llvm[3]: Compiling HexagonExpandPredSpillCode.cpp for Debug+Asserts build
In file included from HexagonExpandPredSpillCode.cpp:25:
In file included from /home/mtech11/llvm/include/llvm/CodeGen/LatencyPriorityQueue.h:19:
/home/mtech11/llvm/include/llvm/CodeGen/ScheduleDAG.h:375:66: warning: extra ‘;’
inside a class [-pedantic]
bool isBoundaryNode() const { return NodeNum == BoundaryID; };
^
1 warning generated.
llvm[3]: Compiling HexagonFixupHwLoops.cpp for Debug+Asserts build
llvm[3]: Compiling HexagonFrameLowering.cpp for Debug+Asserts build
llvm[3]: Compiling HexagonHardwareLoops.cpp for Debug+Asserts build
llvm[3]: Compiling HexagonISelDAGToDAG.cpp for Debug+Asserts build
llvm[3]: Compiling HexagonISelLowering.cpp for Debug+Asserts build
llvm[3]: Compiling HexagonInstrInfo.cpp for Debug+Asserts build
llvm[3]: Compiling HexagonMCInstLower.cpp for Debug+Asserts build
In file included from HexagonMCInstLower.cpp:18:
/home/mtech11/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCInst.h:34:57: warning:
extra ‘;’ inside a class [-pedantic]
MCInst(), MCID(0), packetStart(0), packetEnd(0) {};
^
/home/mtech11/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCInst.h:36:61: warning:
extra ‘;’ inside a class [-pedantic]
MCInst(), MCID(&mcid), packetStart(0), packetEnd(0) {};
^
/home/mtech11/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCInst.h:38:57: warning:
extra ‘;’ inside a class [-pedantic]
bool isPacketStart() const { return (packetStart); };
^
/home/mtech11/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCInst.h:39:53: warning:
extra ‘;’ inside a class [-pedantic]
bool isPacketEnd() const { return (packetEnd); };
^
/home/mtech11/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCInst.h:40:53: warning:
extra ‘;’ inside a class [-pedantic]
void setPacketStart(bool Y) { packetStart = Y; };
^
/home/mtech11/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCInst.h:41:49: warning:
extra ‘;’ inside a class [-pedantic]
void setPacketEnd(bool Y) { packetEnd = Y; };
^
/home/mtech11/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCInst.h:42:71: warning:
extra ‘;’ inside a class [-pedantic]
void resetPacket() { setPacketStart(false); setPacketEnd(false); };
^
/home/mtech11/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCInst.h:50:60: warning:
extra ‘;’ inside a class [-pedantic]
void setDesc(const MCInstrDesc& mcid) { MCID = &mcid; };
^
/home/mtech11/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCInst.h:51:61: warning:
extra ‘;’ inside a class [-pedantic]
const MCInstrDesc& getDesc(void) const { return *MCID; };
^
9 warnings generated.
llvm[3]: Compiling HexagonMachineScheduler.cpp for Debug+Asserts build
In file included from HexagonMachineScheduler.cpp:17:
In file included from /home/mtech11/llvm/lib/Target/Hexagon/HexagonMachineScheduler.h:21:
In file included from /home/mtech11/llvm/include/llvm/CodeGen/MachineScheduler.h:32:
In file included from /home/mtech11/llvm/include/llvm/CodeGen/ScheduleDAGInstrs.h:23:
/home/mtech11/llvm/include/llvm/CodeGen/ScheduleDAG.h:375:66: warning: extra ‘;’
inside a class [-pedantic]
bool isBoundaryNode() const { return NodeNum == BoundaryID; };
^
1 warning generated.
llvm[3]: Compiling HexagonNewValueJump.cpp for Debug+Asserts build
In file included from HexagonNewValueJump.cpp:39:
In file included from /home/mtech11/llvm/include/llvm/CodeGen/ScheduleDAGInstrs.h:23:
/home/mtech11/llvm/include/llvm/CodeGen/ScheduleDAG.h:375:66: warning: extra ‘;’
inside a class [-pedantic]
bool isBoundaryNode() const { return NodeNum == BoundaryID; };
^
1 warning generated.
llvm[3]: Compiling HexagonPeephole.cpp for Debug+Asserts build
llvm[3]: Compiling HexagonRegisterInfo.cpp for Debug+Asserts build
llvm[3]: Compiling HexagonRemoveSZExtArgs.cpp for Debug+Asserts build
llvm[3]: Compiling HexagonSelectionDAGInfo.cpp for Debug+Asserts build
llvm[3]: Compiling HexagonSplitTFRCondSets.cpp for Debug+Asserts build
In file included from HexagonSplitTFRCondSets.cpp:34:
In file included from /home/mtech11/llvm/include/llvm/CodeGen/LatencyPriorityQueue.h:19:
/home/mtech11/llvm/include/llvm/CodeGen/ScheduleDAG.h:375:66: warning: extra ‘;’
inside a class [-pedantic]
bool isBoundaryNode() const { return NodeNum == BoundaryID; };
^
1 warning generated.
llvm[3]: Compiling HexagonSubtarget.cpp for Debug+Asserts build
llvm[3]: Compiling HexagonTargetMachine.cpp for Debug+Asserts build
In file included from HexagonTargetMachine.cpp:17:
In file included from /home/mtech11/llvm/lib/Target/Hexagon/HexagonMachineScheduler.h:21:
In file included from /home/mtech11/llvm/include/llvm/CodeGen/MachineScheduler.h:32:
In file included from /home/mtech11/llvm/include/llvm/CodeGen/ScheduleDAGInstrs.h:23:
/home/mtech11/llvm/include/llvm/CodeGen/ScheduleDAG.h:375:66: warning: extra ‘;’
inside a class [-pedantic]
bool isBoundaryNode() const { return NodeNum == BoundaryID; };
^
1 warning generated.
llvm[3]: Compiling HexagonTargetObjectFile.cpp for Debug+Asserts build
llvm[3]: Compiling HexagonVLIWPacketizer.cpp for Debug+Asserts build
In file included from HexagonVLIWPacketizer.cpp:25:
/home/mtech11/llvm/include/llvm/CodeGen/ScheduleDAG.h:375:66: warning: extra ‘;’
inside a class [-pedantic]
bool isBoundaryNode() const { return NodeNum == BoundaryID; };
^
1 warning generated.
llvm[3]: Building Debug+Asserts Archive Library libLLVMHexagonCodeGen.a
llvm[3]: Installing Debug+Asserts Archive Library /usr/local/lib/libLLVMHexagonCodeGen.a
make[4]: Entering directory `/home/mtech11/llvm/lib/Target/Hexagon/InstPrinter’
llvm[4]: Compiling HexagonInstPrinter.cpp for Debug+Asserts build
In file included from HexagonInstPrinter.cpp:18:
/home/mtech11/llvm/lib/Target/Hexagon/InstPrinter/../MCTargetDesc/HexagonMCInst.h:34:57: warning:
extra ‘;’ inside a class [-pedantic]
MCInst(), MCID(0), packetStart(0), packetEnd(0) {};
^
/home/mtech11/llvm/lib/Target/Hexagon/InstPrinter/../MCTargetDesc/HexagonMCInst.h:36:61: warning:
extra ‘;’ inside a class [-pedantic]
MCInst(), MCID(&mcid), packetStart(0), packetEnd(0) {};
^
/home/mtech11/llvm/lib/Target/Hexagon/InstPrinter/../MCTargetDesc/HexagonMCInst.h:38:57: warning:
extra ‘;’ inside a class [-pedantic]
bool isPacketStart() const { return (packetStart); };
^
/home/mtech11/llvm/lib/Target/Hexagon/InstPrinter/../MCTargetDesc/HexagonMCInst.h:39:53: warning:
extra ‘;’ inside a class [-pedantic]
bool isPacketEnd() const { return (packetEnd); };
^
/home/mtech11/llvm/lib/Target/Hexagon/InstPrinter/../MCTargetDesc/HexagonMCInst.h:40:53: warning:
extra ‘;’ inside a class [-pedantic]
void setPacketStart(bool Y) { packetStart = Y; };
^
/home/mtech11/llvm/lib/Target/Hexagon/InstPrinter/../MCTargetDesc/HexagonMCInst.h:41:49: warning:
extra ‘;’ inside a class [-pedantic]
void setPacketEnd(bool Y) { packetEnd = Y; };
^
/home/mtech11/llvm/lib/Target/Hexagon/InstPrinter/../MCTargetDesc/HexagonMCInst.h:42:71: warning:
extra ‘;’ inside a class [-pedantic]
void resetPacket() { setPacketStart(false); setPacketEnd(false); };
^
/home/mtech11/llvm/lib/Target/Hexagon/InstPrinter/../MCTargetDesc/HexagonMCInst.h:50:60: warning:
extra ‘;’ inside a class [-pedantic]
void setDesc(const MCInstrDesc& mcid) { MCID = &mcid; };
^
/home/mtech11/llvm/lib/Target/Hexagon/InstPrinter/../MCTargetDesc/HexagonMCInst.h:51:61: warning:
extra ‘;’ inside a class [-pedantic]
const MCInstrDesc& getDesc(void) const { return *MCID; };
^
9 warnings generated.
llvm[4]: Building Debug+Asserts Archive Library libLLVMHexagonAsmPrinter.a
llvm[4]: Installing Debug+Asserts Archive Library /usr/local/lib/libLLVMHexagonAsmPrinter.a
make[4]: Leaving directory `/home/mtech11/llvm/lib/Target/Hexagon/InstPrinter’
make[4]: Entering directory `/home/mtech11/llvm/lib/Target/Hexagon/TargetInfo’
llvm[4]: Compiling HexagonTargetInfo.cpp for Debug+Asserts build
llvm[4]: Building Debug+Asserts Archive Library libLLVMHexagonInfo.a
llvm[4]: Installing Debug+Asserts Archive Library /usr/local/lib/libLLVMHexagonInfo.a
make[4]: Leaving directory `/home/mtech11/llvm/lib/Target/Hexagon/TargetInfo’
make[4]: Entering directory `/home/mtech11/llvm/lib/Target/Hexagon/MCTargetDesc’
llvm[4]: Compiling HexagonMCInst.cpp for Debug+Asserts build
In file included from HexagonMCInst.cpp:16:
/home/mtech11/llvm/lib/Target/Hexagon/MCTargetDesc/../MCTargetDesc/HexagonMCInst.h:34:57: warning:
extra ‘;’ inside a class [-pedantic]
MCInst(), MCID(0), packetStart(0), packetEnd(0) {};
^
/home/mtech11/llvm/lib/Target/Hexagon/MCTargetDesc/../MCTargetDesc/HexagonMCInst.h:36:61: warning:
extra ‘;’ inside a class [-pedantic]
MCInst(), MCID(&mcid), packetStart(0), packetEnd(0) {};
^
/home/mtech11/llvm/lib/Target/Hexagon/MCTargetDesc/../MCTargetDesc/HexagonMCInst.h:38:57: warning:
extra ‘;’ inside a class [-pedantic]
bool isPacketStart() const { return (packetStart); };
^
/home/mtech11/llvm/lib/Target/Hexagon/MCTargetDesc/../MCTargetDesc/HexagonMCInst.h:39:53: warning:
extra ‘;’ inside a class [-pedantic]
bool isPacketEnd() const { return (packetEnd); };
^
/home/mtech11/llvm/lib/Target/Hexagon/MCTargetDesc/../MCTargetDesc/HexagonMCInst.h:40:53: warning:
extra ‘;’ inside a class [-pedantic]
void setPacketStart(bool Y) { packetStart = Y; };
^
/home/mtech11/llvm/lib/Target/Hexagon/MCTargetDesc/../MCTargetDesc/HexagonMCInst.h:41:49: warning:
extra ‘;’ inside a class [-pedantic]
void setPacketEnd(bool Y) { packetEnd = Y; };
^
/home/mtech11/llvm/lib/Target/Hexagon/MCTargetDesc/../MCTargetDesc/HexagonMCInst.h:42:71: warning:
extra ‘;’ inside a class [-pedantic]
void resetPacket() { setPacketStart(false); setPacketEnd(false); };
^
/home/mtech11/llvm/lib/Target/Hexagon/MCTargetDesc/../MCTargetDesc/HexagonMCInst.h:50:60: warning:
extra ‘;’ inside a class [-pedantic]
void setDesc(const MCInstrDesc& mcid) { MCID = &mcid; };
^
/home/mtech11/llvm/lib/Target/Hexagon/MCTargetDesc/../MCTargetDesc/HexagonMCInst.h:51:61: warning:
extra ‘;’ inside a class [-pedantic]
const MCInstrDesc& getDesc(void) const { return *MCID; };
^
9 warnings generated.
llvm[4]: Compiling HexagonMCTargetDesc.cpp for Debug+Asserts build
llvm[4]: Building Debug+Asserts Archive Library libLLVMHexagonDesc.a
llvm[4]: Installing Debug+Asserts Archive Library /usr/local/lib/libLLVMHexagonDesc.a
make[4]: Leaving directory `/home/mtech11/llvm/lib/Target/Hexagon/MCTargetDesc’
make[3]: Leaving directory `/home/mtech11/llvm/lib/Target/Hexagon’
make[2]: Leaving directory `/home/mtech11/llvm/lib/Target’
make[2]: Entering directory `/home/mtech11/llvm/lib/ExecutionEngine’
llvm[2]: Compiling ExecutionEngine.cpp for Debug+Asserts build
llvm[2]: Compiling ExecutionEngineBindings.cpp for Debug+Asserts build
llvm[2]: Compiling TargetSelect.cpp for Debug+Asserts build
llvm[2]: Building Debug+Asserts Archive Library libLLVMExecutionEngine.a
llvm[2]: Installing Debug+Asserts Archive Library /usr/local/lib/libLLVMExecutionEngine.a
make[3]: Entering directory `/home/mtech11/llvm/lib/ExecutionEngine/Interpreter’
llvm[3]: Compiling Execution.cpp for Debug+Asserts build
llvm[3]: Compiling ExternalFunctions.cpp for Debug+Asserts build
llvm[3]: Compiling Interpreter.cpp for Debug+Asserts build
llvm[3]: Building Debug+Asserts Archive Library libLLVMInterpreter.a
llvm[3]: Installing Debug+Asserts Archive Library /usr/local/lib/libLLVMInterpreter.a
make[3]: Leaving directory `/home/mtech11/llvm/lib/ExecutionEngine/Interpreter’
make[3]: Entering directory `/home/mtech11/llvm/lib/ExecutionEngine/JIT’
llvm[3]: Compiling JIT.cpp for Debug+Asserts build
llvm[3]: Compiling JITDwarfEmitter.cpp for Debug+Asserts build
llvm[3]: Compiling JITEmitter.cpp for Debug+Asserts build
llvm[3]: Compiling JITMemoryManager.cpp for Debug+Asserts build
llvm[3]: Building Debug+Asserts Archive Library libLLVMJIT.a
llvm[3]: Installing Debug+Asserts Archive Library /usr/local/lib/libLLVMJIT.a
make[3]: Leaving directory `/home/mtech11/llvm/lib/ExecutionEngine/JIT’
make[3]: Entering directory `/home/mtech11/llvm/lib/ExecutionEngine/MCJIT’
llvm[3]: Compiling MCJIT.cpp for Debug+Asserts build
llvm[3]: Compiling SectionMemoryManager.cpp for Debug+Asserts build
llvm[3]: Building Debug+Asserts Archive Library libLLVMMCJIT.a
llvm[3]: Installing Debug+Asserts Archive Library /usr/local/lib/libLLVMMCJIT.a
make[3]: Leaving directory `/home/mtech11/llvm/lib/ExecutionEngine/MCJIT’
make[3]: Entering directory `/home/mtech11/llvm/lib/ExecutionEngine/RuntimeDyld’
llvm[3]: Compiling GDBRegistrar.cpp for Debug+Asserts build
llvm[3]: Compiling RuntimeDyld.cpp for Debug+Asserts build
llvm[3]: Compiling RuntimeDyldELF.cpp for Debug+Asserts build
llvm[3]: Compiling RuntimeDyldMachO.cpp for Debug+Asserts build
llvm[3]: Building Debug+Asserts Archive Library libLLVMRuntimeDyld.a
llvm[3]: Installing Debug+Asserts Archive Library /usr/local/lib/libLLVMRuntimeDyld.a
make[3]: Leaving directory `/home/mtech11/llvm/lib/ExecutionEngine/RuntimeDyld’
make[2]: Leaving directory `/home/mtech11/llvm/lib/ExecutionEngine’
make[2]: Entering directory `/home/mtech11/llvm/lib/Linker’
llvm[2]: Compiling LinkModules.cpp for Debug+Asserts build
llvm[2]: Compiling Linker.cpp for Debug+Asserts build
llvm[2]: Building Debug+Asserts Archive Library libLLVMLinker.a
llvm[2]: Installing Debug+Asserts Archive Library /usr/local/lib/libLLVMLinker.a
make[2]: Leaving directory `/home/mtech11/llvm/lib/Linker’
make[2]: Entering directory `/home/mtech11/llvm/lib/MC’
llvm[2]: Compiling ELFObjectWriter.cpp for Debug+Asserts build
llvm[2]: Compiling MCAsmBackend.cpp for Debug+Asserts build
llvm[2]: Compiling MCAsmInfo.cpp for Debug+Asserts build
llvm[2]: Compiling MCAsmInfoDarwin.cpp for Debug+Asserts build
llvm[2]: Compiling MCAsmStreamer.cpp for Debug+Asserts build
llvm[2]: Compiling MCAssembler.cpp for Debug+Asserts build
llvm[2]: Compiling MCAtom.cpp for Debug+Asserts build
llvm[2]: Compiling MCCodeEmitter.cpp for Debug+Asserts build
llvm[2]: Compiling MCContext.cpp for Debug+Asserts build
llvm[2]: Compiling MCDwarf.cpp for Debug+Asserts build
llvm[2]: Compiling MCELF.cpp for Debug+Asserts build
llvm[2]: Compiling MCELFObjectTargetWriter.cpp for Debug+Asserts build
llvm[2]: Compiling MCELFStreamer.cpp for Debug+Asserts build
llvm[2]: Compiling MCExpr.cpp for Debug+Asserts build
llvm[2]: Compiling MCInst.cpp for Debug+Asserts build
llvm[2]: Compiling MCInstPrinter.cpp for Debug+Asserts build
llvm[2]: Compiling MCInstrAnalysis.cpp for Debug+Asserts build
llvm[2]: Compiling MCLabel.cpp for Debug+Asserts build
llvm[2]: Compiling MCMachOStreamer.cpp for Debug+Asserts build
llvm[2]: Compiling MCMachObjectTargetWriter.cpp for Debug+Asserts build
In file included from MCMachObjectTargetWriter.cpp:10:
/home/mtech11/llvm/include/llvm/MC/MCMachObjectWriter.h:51:26: warning: extra
‘;’ inside a class [-pedantic]
virtual void reset() {};
^
1 warning generated.
llvm[2]: Compiling MCModule.cpp for Debug+Asserts build
llvm[2]: Compiling MCNullStreamer.cpp for Debug+Asserts build
llvm[2]: Compiling MCObjectFileInfo.cpp for Debug+Asserts build
llvm[2]: Compiling MCObjectStreamer.cpp for Debug+Asserts build
llvm[2]: Compiling MCObjectWriter.cpp for Debug+Asserts build
llvm[2]: Compiling MCPureStreamer.cpp for Debug+Asserts build
llvm[2]: Compiling MCRegisterInfo.cpp for Debug+Asserts build
llvm[2]: Compiling MCSection.cpp for Debug+Asserts build
llvm[2]: Compiling MCSectionCOFF.cpp for Debug+Asserts build
llvm[2]: Compiling MCSectionELF.cpp for Debug+Asserts build
llvm[2]: Compiling MCSectionMachO.cpp for Debug+Asserts build
llvm[2]: Compiling MCStreamer.cpp for Debug+Asserts build
llvm[2]: Compiling MCSubtargetInfo.cpp for Debug+Asserts build
llvm[2]: Compiling MCSymbol.cpp for Debug+Asserts build
llvm[2]: Compiling MCValue.cpp for Debug+Asserts build
llvm[2]: Compiling MCWin64EH.cpp for Debug+Asserts build
llvm[2]: Compiling MachObjectWriter.cpp for Debug+Asserts build
In file included from MachObjectWriter.cpp:10:
/home/mtech11/llvm/include/llvm/MC/MCMachObjectWriter.h:51:26: warning: extra
‘;’ inside a class [-pedantic]
virtual void reset() {};
^
1 warning generated.
llvm[2]: Compiling SubtargetFeature.cpp for Debug+Asserts build
llvm[2]: Compiling WinCOFFObjectWriter.cpp for Debug+Asserts build
llvm[2]: Compiling WinCOFFStreamer.cpp for Debug+Asserts build
llvm[2]: Building Debug+Asserts Archive Library libLLVMMC.a
llvm[2]: Installing Debug+Asserts Archive Library /usr/local/lib/libLLVMMC.a
make[3]: Entering directory `/home/mtech11/llvm/lib/MC/MCParser’
llvm[3]: Compiling AsmLexer.cpp for Debug+Asserts build
llvm[3]: Compiling AsmParser.cpp for Debug+Asserts build
llvm[3]: Compiling COFFAsmParser.cpp for Debug+Asserts build
llvm[3]: Compiling DarwinAsmParser.cpp for Debug+Asserts build
llvm[3]: Compiling ELFAsmParser.cpp for Debug+Asserts build
llvm[3]: Compiling MCAsmLexer.cpp for Debug+Asserts build
llvm[3]: Compiling MCAsmParser.cpp for Debug+Asserts build
llvm[3]: Compiling MCAsmParserExtension.cpp for Debug+Asserts build
llvm[3]: Compiling MCTargetAsmParser.cpp for Debug+Asserts build
llvm[3]: Building Debug+Asserts Archive Library libLLVMMCParser.a
llvm[3]: Installing Debug+Asserts Archive Library /usr/local/lib/libLLVMMCParser.a
make[3]: Leaving directory `/home/mtech11/llvm/lib/MC/MCParser’
make[3]: Entering directory `/home/mtech11/llvm/lib/MC/MCDisassembler’
llvm[3]: Compiling Disassembler.cpp for Debug+Asserts build
llvm[3]: Building Debug+Asserts Archive Library libLLVMMCDisassembler.a
llvm[3]: Installing Debug+Asserts Archive Library /usr/local/lib/libLLVMMCDisassembler.a
make[3]: Leaving directory `/home/mtech11/llvm/lib/MC/MCDisassembler’
make[2]: Leaving directory `/home/mtech11/llvm/lib/MC’
make[2]: Entering directory `/home/mtech11/llvm/lib/Object’
llvm[2]: Compiling Archive.cpp for Debug+Asserts build
llvm[2]: Compiling Binary.cpp for Debug+Asserts build
llvm[2]: Compiling COFFObjectFile.cpp for Debug+Asserts build
llvm[2]: Compiling ELFObjectFile.cpp for Debug+Asserts build
llvm[2]: Compiling Error.cpp for Debug+Asserts build
llvm[2]: Compiling MachOObject.cpp for Debug+Asserts build
llvm[2]: Compiling MachOObjectFile.cpp for Debug+Asserts build
llvm[2]: Compiling Object.cpp for Debug+Asserts build
llvm[2]: Compiling ObjectFile.cpp for Debug+Asserts build
llvm[2]: Building Debug+Asserts Archive Library libLLVMObject.a
llvm[2]: Installing Debug+Asserts Archive Library /usr/local/lib/libLLVMObject.a
make[2]: Leaving directory `/home/mtech11/llvm/lib/Object’
make[2]: Entering directory `/home/mtech11/llvm/lib/Option’
llvm[2]: Compiling Arg.cpp for Debug+Asserts build
llvm[2]: Compiling ArgList.cpp for Debug+Asserts build
llvm[2]: Compiling OptTable.cpp for Debug+Asserts build
llvm[2]: Compiling Option.cpp for Debug+Asserts build
llvm[2]: Building Debug+Asserts Archive Library libLLVMOption.a
llvm[2]: Installing Debug+Asserts Archive Library /usr/local/lib/libLLVMOption.a
make[2]: Leaving directory `/home/mtech11/llvm/lib/Option’
make[2]: Entering directory `/home/mtech11/llvm/lib/DebugInfo’
llvm[2]: Compiling DIContext.cpp for Debug+Asserts build
llvm[2]: Compiling DWARFAbbreviationDeclaration.cpp for Debug+Asserts build
llvm[2]: Compiling DWARFCompileUnit.cpp for Debug+Asserts build
llvm[2]: Compiling DWARFContext.cpp for Debug+Asserts build
llvm[2]: Compiling DWARFDebugAbbrev.cpp for Debug+Asserts build
llvm[2]: Compiling DWARFDebugArangeSet.cpp for Debug+Asserts build
llvm[2]: Compiling DWARFDebugAranges.cpp for Debug+Asserts build
llvm[2]: Compiling DWARFDebugFrame.cpp for Debug+Asserts build
llvm[2]: Compiling DWARFDebugInfoEntry.cpp for Debug+Asserts build
llvm[2]: Compiling DWARFDebugLine.cpp for Debug+Asserts build
llvm[2]: Compiling DWARFDebugRangeList.cpp for Debug+Asserts build
llvm[2]: Compiling DWARFFormValue.cpp for Debug+Asserts build
llvm[2]: Building Debug+Asserts Archive Library libLLVMDebugInfo.a
llvm[2]: Installing Debug+Asserts Archive Library /usr/local/lib/libLLVMDebugInfo.a
make[2]: Leaving directory `/home/mtech11/llvm/lib/DebugInfo’
make[1]: Leaving directory `/home/mtech11/llvm/lib’
make[1]: Entering directory `/home/mtech11/llvm/tools/llvm-config’
llvm[1]: Compiling llvm-config.cpp for Debug+Asserts build
llvm[1]: Linking Debug+Asserts executable llvm-config
llvm[1]: ======= Finished Linking Debug+Asserts Executable llvm-config
llvm[1]: Installing Debug+Asserts /usr/local/bin/llvm-config
make[1]: Leaving directory `/home/mtech11/llvm/tools/llvm-config’
make[1]: Entering directory `/home/mtech11/llvm/tools’
make[2]: Entering directory `/home/mtech11/llvm/tools/llvm-config’
make[2]: Nothing to be done for `install’.
make[2]: Leaving directory `/home/mtech11/llvm/tools/llvm-config’
make[2]: Entering directory `/home/mtech11/llvm/tools/opt’
llvm[2]: Compiling AnalysisWrappers.cpp for Debug+Asserts build
llvm[2]: Compiling GraphPrinters.cpp for Debug+Asserts build
llvm[2]: Compiling PrintSCC.cpp for Debug+Asserts build
llvm[2]: Compiling opt.cpp for Debug+Asserts build
In file included from opt.cpp:29:
In file included from /home/mtech11/llvm/include/llvm/LinkAllIR.h:31:
/home/mtech11/llvm/include/llvm/Support/Process.h:118:48: warning: extra ‘;’
inside a class [-pedantic]
size_t page_size() const { return PageSize; };
^
1 warning generated.
llvm[2]: Linking Debug+Asserts executable opt
llvm[2]: ======= Finished Linking Debug+Asserts Executable opt
llvm[2]: Installing Debug+Asserts /usr/local/bin/opt
make[2]: Leaving directory `/home/mtech11/llvm/tools/opt’
make[2]: Entering directory `/home/mtech11/llvm/tools/llvm-as’
llvm[2]: Compiling llvm-as.cpp for Debug+Asserts build
llvm[2]: Linking Debug+Asserts executable llvm-as
llvm[2]: ======= Finished Linking Debug+Asserts Executable llvm-as
llvm[2]: Installing Debug+Asserts /usr/local/bin/llvm-as
make[2]: Leaving directory `/home/mtech11/llvm/tools/llvm-as’
make[2]: Entering directory `/home/mtech11/llvm/tools/llvm-dis’
llvm[2]: Compiling llvm-dis.cpp for Debug+Asserts build
llvm[2]: Linking Debug+Asserts executable llvm-dis
llvm[2]: ======= Finished Linking Debug+Asserts Executable llvm-dis
llvm[2]: Installing Debug+Asserts /usr/local/bin/llvm-dis
make[2]: Leaving directory `/home/mtech11/llvm/tools/llvm-dis’
make[2]: Entering directory `/home/mtech11/llvm/tools/llc’
llvm[2]: Compiling llc.cpp for Debug+Asserts build
llvm[2]: Linking Debug+Asserts executable llc
/home/mtech11/llvm/Debug+Asserts/lib/libLLVMNVPTXCodeGen.a(NVPTXAsmPrinter.o): In function `llvm::LineReader::readLine(unsigned int)’:
/home/mtech11/llvm/include/llvm/Support/raw_ostream.h:79: undefined reference to `std::basic_istream<char, std::char_traits >::seekg(long, std::_Ios_Seekdir)’
collect2: ld returned 1 exit status
clang: error: linker (via gcc) command failed with exit code 1 (use -v to see invocation)
make[2]: *** [/home/mtech11/llvm/Debug+Asserts/bin/llc] Error 1
make[2]: Leaving directory `/home/mtech11/llvm/tools/llc’
make[1]: *** [llc/.makeinstall] Error 2
make[1]: Leaving directory `/home/mtech11/llvm/tools’
make: *** [install] Error 1
Yours tutorial was a great help.Thank you! 🙂
This tutorial is very usefull.i couild install gpu ocelot in my ubuntu 11.04 and doing further steps of my thesis.Thank you.
I successfully installed gpuocelot but during compilation of the example program you provided I get the following error:
g++ -o hello.out hello.o `OcelotConfig -l`
/usr/bin/ld: cannot find -lLLVMAsmParser
/usr/bin/ld: cannot find -lLLVMX86Disassembler
/usr/bin/ld: cannot find -lLLVMX86AsmParser
/usr/bin/ld: cannot find -lLLVMX86CodeGen
/usr/bin/ld: cannot find -lLLVMSelectionDAG
/usr/bin/ld: cannot find -lLLVMAsmPrinter
/usr/bin/ld: cannot find -lLLVMMCParser
/usr/bin/ld: cannot find -lLLVMX86AsmPrinter
/usr/bin/ld: cannot find -lLLVMX86Utils
/usr/bin/ld: cannot find -lLLVMX86Info
/usr/bin/ld: cannot find -lLLVMJIT
/usr/bin/ld: cannot find -lLLVMExecutionEngine
/usr/bin/ld: cannot find -lLLVMCodeGen
/usr/bin/ld: cannot find -lLLVMScalarOpts
/usr/bin/ld: cannot find -lLLVMInstCombine
/usr/bin/ld: cannot find -lLLVMTransformUtils
/usr/bin/ld: cannot find -lLLVMipa
/usr/bin/ld: cannot find -lLLVMAnalysis
/usr/bin/ld: cannot find -lLLVMTarget
/usr/bin/ld: cannot find -lLLVMMC
/usr/bin/ld: cannot find -lLLVMCore
/usr/bin/ld: cannot find -lLLVMSupport
collect2: ld returned 1 exit status
Thank you very much! That was very useful for me too!
I had to search the files on google because I didn’t find them on that link.
I also had to comment a line in the archive LLVMRuntimeLibrary due to while I was executing the line sudo ./build.py –install it couldn’t build.
After those corrections, everything worked in the right way!
Thanks again!
I tried this but it fails at the second step. Both steps for installing gcc 4.4 fail because of missing files. This is on a fresh ubuntu 12.04 installation, so the problem is not on my side. There is probably some prior step that needs to be done, but I wouldn’t know what.
This tutorial is very good. But I still got some errors. I'd like to share my fix.
I installed Ocelot with the ocelot_2.1.2181_amd64.deb Feb 5th Release. when i ran: g++ -o hello.out hello.o OcelotConfig -l
And I got following error:
OcelotConfig?: command not found hello.o: In function `main’: tmpxft_00000d01_00000000-3_hello.cudafe1.cpp:(.text+0xa6): undefined reference to `cudaMalloc’ tmpxft_00000d01_00000000-3_hello.cudafe1.cpp:(.text+0xb7): undefined reference to `cudaMalloc’ tmpxft_00000d01_00000000-3_hello.cudafe1.cpp:(.text+0xc8): undefined reference to `cudaMalloc’ tmpxft_00000d01_00000000-3_hello.cudafe1.cpp:(.text+0xe2): undefined reference to `cudaMemcpy’ tmpxft_00000d01_00000000-3_hello.cudafe1.cpp:(.text+0xfc): undefined reference to `cudaMemcpy’ tmpxft_00000d01_00000000-3_hello.cudafe1.cpp:(.text+0x156): undefined reference to `cudaConfigureCall’ tmpxft_00000d01_00000000-3_hello.cudafe1.cpp:(.text+0x18b): undefined reference to `cudaMemcpy’ tmpxft_00000d01_00000000-3_hello.cudafe1.cpp:(.text+0x230): undefined reference to `cudaFree’ tmpxft_00000d01_00000000-3_hello.cudafe1.cpp:(.text+0x23c): undefined reference to `cudaFree’ tmpxft_00000d01_00000000-3_hello.cudafe1.cpp:(.text+0x248): undefined reference to `cudaFree’
No idea why this happens, but I did the following and it works.
1. Rename the Ocelot library file from locelot.so to libocelot.so in ocelot library directory. for me, it's /usr/l/checkout/gpuocelot/ocelot/build_local/lib
2. ran with:
g++ -o hello.out hello.o -L/usr/l/checkout/gpuocelot/ocelot/build_local/lib -locelot
and it works like magic.
I am using Ubuntu 12.04 and cuda 5.0
Hi, Leyong Tan,
I’ve the same problem and my instalation. But on path “/usr/l/checkout/gpuocelot/ocelot/build_local/lib” the oncelot lib even tha correct name.
So, I try execute following this comands and not work.
g++ -o hello.out hello.o -L /usr/l/checkout/gpuocelot/ocelot/build_local/lib -locelot
Thank you
Thanks! Worked here without any trouble at all.
Thanks for sharing such a detailed guide. I only had a little problem with installing GpuOcelot using Ubuntu Software Center but other than that.. it worked well for me !!
THanks,
Anh
[…] Although the GPU Ocelot has proved to be a real good emulator but it lacks good documentation. However, there has been some great individual efforts that provides vital source of information for beginners like me. One such great piece of work can be found here (https://barefeg.wordpress.com/2012/06/16/how-to-install-gpuocelot-in-ubuntu-12-04/). […]
[…] Although the GPU Ocelot has proved to be a real good emulator but it lacks good documentation. However, there has been some great individual efforts that provides vital source of information for beginners like me. One such great piece of work can be found here. […]
I am getting the following errors, can you please point out my mistake..
OcelotConfig: command not found
hello.o: In function `main’:
tmpxft_00003686_00000000-1_hello.cudafe1.cpp:(.text+0xaf): undefined reference to `cudaMalloc’
tmpxft_00003686_00000000-1_hello.cudafe1.cpp:(.text+0xc3): undefined reference to `cudaMalloc’
tmpxft_00003686_00000000-1_hello.cudafe1.cpp:(.text+0xd7): undefined reference to `cudaMalloc’
tmpxft_00003686_00000000-1_hello.cudafe1.cpp:(.text+0xfb): undefined reference to `cudaMemcpy’
tmpxft_00003686_00000000-1_hello.cudafe1.cpp:(.text+0x11f): undefined reference to `cudaMemcpy’
tmpxft_00003686_00000000-1_hello.cudafe1.cpp:(.text+0x1ab): undefined reference to `cudaConfigureCall’
tmpxft_00003686_00000000-1_hello.cudafe1.cpp:(.text+0x1ef): undefined reference to `cudaMemcpy’
tmpxft_00003686_00000000-1_hello.cudafe1.cpp:(.text+0x2a7): undefined reference to `cudaFree’
tmpxft_00003686_00000000-1_hello.cudafe1.cpp:(.text+0x2b3): undefined reference to `cudaFree’
tmpxft_00003686_00000000-1_hello.cudafe1.cpp:(.text+0x2bf): undefined reference to `cudaFree’
hello.o: In function `__cudaUnregisterBinaryUtil()’:
tmpxft_00003686_00000000-1_hello.cudafe1.cpp:(.text+0x312): undefined reference to `__cudaUnregisterFatBinary’
hello.o: In function `__device_stub__Z3dotPfS_S_(float*, float*, float*)’:
tmpxft_00003686_00000000-1_hello.cudafe1.cpp:(.text+0x335): undefined reference to `cudaSetupArgument’
tmpxft_00003686_00000000-1_hello.cudafe1.cpp:(.text+0x359): undefined reference to `cudaSetupArgument’
tmpxft_00003686_00000000-1_hello.cudafe1.cpp:(.text+0x37d): undefined reference to `cudaSetupArgument’
hello.o: In function `__sti____cudaRegisterAll_40_tmpxft_00003686_00000000_4_hello_cpp1_ii_f26a2827()’:
tmpxft_00003686_00000000-1_hello.cudafe1.cpp:(.text+0x3db): undefined reference to `__cudaRegisterFatBinary’
tmpxft_00003686_00000000-1_hello.cudafe1.cpp:(.text+0x442): undefined reference to `__cudaRegisterFunction’
hello.o: In function `cudaError cudaLaunch(char*)’:
tmpxft_00003686_00000000-1_hello.cudafe1.cpp:(.text._Z10cudaLaunchIcE9cudaErrorPT_[cudaError cudaLaunch(char*)]+0xd): undefined reference to `cudaLaunch’
collect2: ld returned 1 exit status
If you are using 64bit architecture try this
g++ -o hello.out hello.cu -L/usr/local/cuda/lib64 -lcudart
Thanks a dozen for this tutorial.
Just a suggestion. Update the post for 64bit architecture
especially this last bit should be there
g++ -o hello.out hello.cu -L/usr/local/cuda/lib64 -lcudart
This would make the tutorial complete.
correction
nvcc -c hello.cu -arch=sm_20
g++ -o hello.out hello.o -L/usr/local/cuda/lib64 -lcudart
./hello.out
My code is getting compiled using the new library but ./hello.out is giving the error ‘error of loading shared libraries: libcudart.so.4: wrong ELF class: ELFCLASS32’
Thanks for the great tutorial. I thought I was successful in compiling ocelot. after the installation, I compiled backprop benchmark from rodinia with the -locelot and -locelotTrace flag. Build was successful. However, after the binary did not run on my x86 ubuntu 12.04 machine as it could not find CUDA – capable device. Which should have been ocelot as far as I understand it.
compile command:
backprop_cuda.o: backprop_cuda.cu backprop.h
$(NVCC) $(NVCC_FLAGS) -c backprop_cuda.cu -locelot -L/usr/lib/nvidia-304/ -L/usr/local/lib
run time error:
$./backprop 128
Random number generator seed: 7
Input layer size : 128
Starting training kernel
Performing GPU computation
bpnn kernel error: no CUDA-capable device is detected
Could anyone help me with this?
Thanks
Hi.
Thank you for the installation guide. It was really helpful. I installed gpuocelot without any error.
But when I took you hello.cu file, compiled it and when try to run “./hello”, its displaying ‘dot product’ and the run is not coming. Please help me.
Thanks,
Thomas
Forgot to mention. I’m trying to use ‘llvm’ option. Its working fine with ’emulated’ option. Is there any other changes i need to make in configure.ocelot while running with ‘llvm’ option.
Thanks,
Tedy
Hi,
Thank you for the installation guide. When I fire “sudo ./build.py –install”, it fails with the following message.
Glew disabled: not found
Ocelot will be installed at /usr/local
config_h_build([“.release_build/configure.h”], [“configure.h.in”])
g++ -o .release_build/OcelotConfig -L/usr/local/lib .release_build/ocelot/tools/OcelotConfig.o -L/usr/lib -L/usr/local/lib -locelot -lboost_system -lboost_filesystem -lboost_thread -ldl -lrt -lpthread -lLLVMAsmParser -lLLVMX86Disassembler -lLLVMX86AsmParser -lLLVMX86CodeGen -lLLVMSelectionDAG -lLLVMAsmPrinter -lLLVMX86Desc -lLLVMObject -lLLVMMCParser -lLLVMBitReader -lLLVMMCDisassembler -lLLVMX86Info -lLLVMX86AsmPrinter -lLLVMX86Utils -lLLVMJIT -lLLVMExecutionEngine -lLLVMCodeGen -lLLVMScalarOpts -lLLVMInstCombine -lLLVMTransformUtils -lLLVMipa -lLLVMAnalysis -lLLVMTarget -lLLVMMC -lLLVMCore -lLLVMSupport
/usr/local/lib/libocelot.so: undefined reference to `setupterm’
/usr/local/lib/libocelot.so: undefined reference to `tigetnum’
/usr/local/lib/libocelot.so: undefined reference to `uncompress’
/usr/local/lib/libocelot.so: undefined reference to `compress2′
/usr/local/lib/libocelot.so: undefined reference to `crc32′
/usr/local/lib/libocelot.so: undefined reference to `compressBound’
/usr/local/lib/libocelot.so: undefined reference to `set_curterm’
/usr/local/lib/libocelot.so: undefined reference to `del_curterm’
collect2: error: ld returned 1 exit status
scons: *** [.release_build/OcelotConfig] Error 1
Can someone guide me how to resolve this issue?
Animesh,
I have the same issue. Did you find a solution?
Hi,I am having a lot of trouble setting GPUOCELOT up. I have it installed with all the required libraries, but now when I try to execute the simple program above in this tutorial, it compiles fine and during runtime, when there is a kernel call, I get a ‘parser::PTXParser::Exception’. I am getting real tired of trying to make this work and I am somewhat desperate as I need to do some cuda programming for a project and can’t afford a gpu right now. Its gotten to the pint that I would be willing to pay someone for a linux image with gpuocelot perfectly working.
why when I type:
sudo update-alternatives \
–install /usr/bin/gcc gcc /usr/bin/gcc-4.4 60 \
–slave /usr/bin/g++ g++ /usr/bin/g++-4.4
The only thing I get is :
update-alternatives: error: alternative path /usr/bin/gcc-4.4 doesn’t exist.
I cannot install gcc-4.4, What am I doing wrong?
¡¡Muchas gracias!! Fue de gran ayuda.
Hi and thank you for the tutorial it really helps … I got as far as installing LLVM but when I do
sudo ./build.py –install
I get the error below
any idea what could be causing this?
scons -Q install=true
Build rules for Ocelot….
Glew disabled: not found
llvm-config: unknown component name: jit
Ocelot will be installed at /usr/local
config_h_build([“.release_build/configure.h”], [“configure.h.in”])
g++ -o .release_build/ocelot/ir/implementation/ExternalFunctionSet.os -c -O2 -Wall -Werror -std=c++0x -D_DEBUG -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -fPIC -I. -I/usr/include -I/usr/include -I/usr/local/include -I.release_build -I. ocelot/ir/implementation/ExternalFunctionSet.cpp
ocelot/ir/implementation/ExternalFunctionSet.cpp:26: fatal error: llvm/PassManager.h: No such file or directory
compilation terminated.
scons: *** [.release_build/ocelot/ir/implementation/ExternalFunctionSet.os] Error 1
Build failed…
Build failed
did you find a solution for this?
i got a similar error:
scons -Q install=true
Build rules for Ocelot….
llvm-config: unknown component name: jit
Ocelot will be installed at /usr/local
config_h_build([“.release_build/configure.h”], [“configure.h.in”])
g++ -o .release_build/ocelot/ir/implementation/ExternalFunctionSet.os -c -O2 -Wall -Werror -std=c++0x -D_DEBUG -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -fPIC -I. -I/usr/include -I/usr/include -I/usr/local/include -I.release_build -I. ocelot/ir/implementation/ExternalFunctionSet.cpp
In file included from /usr/local/include/llvm/Support/FileSystem.h:30,
from /usr/local/include/llvm/Object/Binary.h:19,
from /usr/local/include/llvm/Object/SymbolicFile.h:17,
from /usr/local/include/llvm/Object/ObjectFile.h:18,
from /usr/local/include/llvm/ExecutionEngine/RuntimeDyld.h:20,
from /usr/local/include/llvm/ExecutionEngine/ExecutionEngine.h:18,
from ocelot/ir/implementation/ExternalFunctionSet.cpp:28:
/usr/local/include/llvm/ADT/IntrusiveRefCntPtr.h:24: fatal error: atomic: No such file or directory
compilation terminated.
scons: *** [.release_build/ocelot/ir/implementation/ExternalFunctionSet.os] Error 1
Build failed…
Build failed
Dear ALL,
Thank you so much for this tutorial.
Every thing compiles fine, but when I run ./hello.out it prints dot product and then it does not show anything for like 20 minutes, the program does not exit and nothing happens.
Is there any command to know the status of my Graphical Card is running the program or not. Please help .
I really appreciate your time and consideration in advance.
Sincerely,
[…] https://barefeg.wordpress.com/2012/06/16/how-to-install-gpuocelot-in-ubuntu-12-04/ […]
I have some problems with building, maybe someone can help me.
This are the last lines from build.py output:
In file included from /usr/local/include/llvm/IR/Module.h:18,
from ocelot/ir/implementation/ExternalFunctionSet.cpp:31:
/usr/local/include/llvm/ADT/OwningPtr.h:73: error: only declarations of constructors can be ‘explicit’
/usr/local/include/llvm/ADT/OwningPtr.h:136: error: only declarations of constructors can be ‘explicit’
In file included from /usr/local/include/llvm/IR/Attributes.h:19,
from /usr/local/include/llvm/IR/Argument.h:19,
from /usr/local/include/llvm/IR/Function.h:21,
from /usr/local/include/llvm/IR/Module.h:19,
from ocelot/ir/implementation/ExternalFunctionSet.cpp:31:
/usr/local/include/llvm/ADT/ArrayRef.h:83: error: expected constructor, destructor, or type conversion before ‘ArrayRef’
scons: *** [.release_build/ocelot/ir/implementation/ExternalFunctionSet.os] Error 1
Build failed…
Build failed