Bitcoin Forum
December 07, 2016, 06:46:58 PM *
News: Latest stable version of Bitcoin Core: 0.13.1  [Torrent].
 
   Home   Help Search Donate Login Register  
Pages: « 1 [2]  All
  Print  
Author Topic: Run my program in your Nvidia GPU (for bitcoins)  (Read 4173 times)
Luceo
Sr. Member
****
Offline Offline

Activity: 350


Per aspera ad astra!


View Profile
June 21, 2012, 11:07:07 AM
 #21

I tried the Makefile you PM'd me, got this output.

I tried modifying my 'working' Makefile (the one I sent you output from for CUDA), but no luck:

Code:
(3:648)# make
mkdir -p build/common
mkdir -p build/optimization
mkdir -p build/neural
mkdir -p build/genetic
mkdir -p build/game
mkdir -p build/tasks
mkdir -p build/loop
mkdir -p build/loopTest
mkdir -p build/test/
g++ -fpermissive -L/opt/cuda-toolkit/lib64 -m32 -ggdb -I src/ -I /opt/cuda-toolkit/include/ -DCPP_IMPL -DCUDA_IMPL -DSSE2_IMPL -c src/test/testMemoryLosses.cpp -o build/test/testMemoryLosses.o
g++ -fpermissive -L/opt/cuda-toolkit/lib64 -m32 -ggdb -I src/ -I /opt/cuda-toolkit/include/ -DCPP_IMPL -DCUDA_IMPL -DSSE2_IMPL -c src/common/chronometer.cpp -o build/common/chronometer.o
g++ -fpermissive -L/opt/cuda-toolkit/lib64 -m32 -ggdb -I src/ -I /opt/cuda-toolkit/include/ -DCPP_IMPL -DCUDA_IMPL -DSSE2_IMPL -c src/common/dummy.cpp -o build/common/dummy.o
g++ -fpermissive -L/opt/cuda-toolkit/lib64 -m32 -ggdb -I src/ -I /opt/cuda-toolkit/include/ -DCPP_IMPL -DCUDA_IMPL -DSSE2_IMPL -c src/common/enumerations.cpp -o build/common/enumerations.o
g++ -fpermissive -L/opt/cuda-toolkit/lib64 -m32 -ggdb -I src/ -I /opt/cuda-toolkit/include/ -DCPP_IMPL -DCUDA_IMPL -DSSE2_IMPL -c src/common/util.cpp -o build/common/util.o
/usr/local/cuda/bin/nvcc -I src/ -I /opt/cuda-toolkit/include/ -DCPP_IMPL -DCUDA_IMPL -DSSE2_IMPL -g -G -c -arch sm_11   src/optimization/cuda_code.cu -o build/optimization/cuda_code.o
g++ -fpermissive -L/opt/cuda-toolkit/lib64 -m32 -ggdb -I src/ -I /opt/cuda-toolkit/include/ -DCPP_IMPL -DCUDA_IMPL -DSSE2_IMPL -c src/optimization/factory.cpp -o build/optimization/factory.o
g++ -fpermissive -L/opt/cuda-toolkit/lib64 -m32 -ggdb -I src/ -I /opt/cuda-toolkit/include/ -DCPP_IMPL -DCUDA_IMPL -DSSE2_IMPL -c src/neural/interface.cpp -o build/neural/interface.o
g++ -fpermissive -L/opt/cuda-toolkit/lib64 -m32 -ggdb -I src/ -I /opt/cuda-toolkit/include/ -DCPP_IMPL -DCUDA_IMPL -DSSE2_IMPL -c src/neural/connection.cpp -o build/neural/connection.o
g++ -fpermissive -L/opt/cuda-toolkit/lib64 -m32 -ggdb -I src/ -I /opt/cuda-toolkit/include/ -DCPP_IMPL -DCUDA_IMPL -DSSE2_IMPL -c src/neural/neuralNet.cpp -o build/neural/neuralNet.o
g++ -fpermissive -L/opt/cuda-toolkit/lib64 -m32 -ggdb -I src/ -I /opt/cuda-toolkit/include/ -DCPP_IMPL -DCUDA_IMPL -DSSE2_IMPL -c src/neural/layer.cpp -o build/neural/layer.o
g++ -fpermissive -L/opt/cuda-toolkit/lib64 -m32 -ggdb -I src/ -I /opt/cuda-toolkit/include/ -DCPP_IMPL -DCUDA_IMPL -DSSE2_IMPL -c src/neural/inputLayer.cpp -o build/neural/inputLayer.o
g++ -fpermissive -L/opt/cuda-toolkit/lib64 -m32 -ggdb -I src/ -I /opt/cuda-toolkit/include/ -DCPP_IMPL -DCUDA_IMPL -DSSE2_IMPL -c src/neural/buffer.cpp -o build/neural/buffer.o
g++ -fpermissive -L/opt/cuda-toolkit/lib64 -m32 -ggdb -I src/ -I /opt/cuda-toolkit/include/ -DCPP_IMPL -DCUDA_IMPL -DSSE2_IMPL -c src/genetic/individual.cpp -o build/genetic/individual.o
g++ -fpermissive -L/opt/cuda-toolkit/lib64 -m32 -ggdb -I src/ -I /opt/cuda-toolkit/include/ -DCPP_IMPL -DCUDA_IMPL -DSSE2_IMPL -c src/genetic/task.cpp -o build/genetic/task.o
g++ -fpermissive -L/opt/cuda-toolkit/lib64 -m32 -ggdb -I src/ -I /opt/cuda-toolkit/include/ -DCPP_IMPL -DCUDA_IMPL -DSSE2_IMPL -c src/genetic/population.cpp -o build/genetic/population.o
g++ -fpermissive -L/opt/cuda-toolkit/lib64 -m32 -ggdb -I src/ -I /opt/cuda-toolkit/include/ -DCPP_IMPL -DCUDA_IMPL -DSSE2_IMPL -c src/game/reversiBoard.cpp -o build/game/reversiBoard.o
g++ -fpermissive -L/opt/cuda-toolkit/lib64 -m32 -ggdb -I src/ -I /opt/cuda-toolkit/include/ -DCPP_IMPL -DCUDA_IMPL -DSSE2_IMPL -c src/game/board.cpp -o build/game/board.o
g++ -fpermissive -L/opt/cuda-toolkit/lib64 -m32 -ggdb -I src/ -I /opt/cuda-toolkit/include/ -DCPP_IMPL -DCUDA_IMPL -DSSE2_IMPL -c src/tasks/reversiTask.cpp -o build/tasks/reversiTask.o
g++ -fpermissive -L/opt/cuda-toolkit/lib64 -m32 -ggdb -I src/ -I /opt/cuda-toolkit/include/ -DCPP_IMPL -DCUDA_IMPL -DSSE2_IMPL -c src/tasks/binaryTask.cpp -o build/tasks/binaryTask.o
g++ -fpermissive -L/opt/cuda-toolkit/lib64 -m32 -ggdb -I src/ -I /opt/cuda-toolkit/include/ -DCPP_IMPL -DCUDA_IMPL -DSSE2_IMPL -c src/tasks/classificationTask.cpp -o build/tasks/classificationTask.o
g++ -fpermissive -L/opt/cuda-toolkit/lib64 -m32 -ggdb -I src/ -I /opt/cuda-toolkit/include/ -DCPP_IMPL -DCUDA_IMPL -DSSE2_IMPL -c src/loop/rangeLoop.cpp -o build/loop/rangeLoop.o
g++ -fpermissive -L/opt/cuda-toolkit/lib64 -m32 -ggdb -I src/ -I /opt/cuda-toolkit/include/ -DCPP_IMPL -DCUDA_IMPL -DSSE2_IMPL -c src/loop/enumLoop.cpp -o build/loop/enumLoop.o
g++ -fpermissive -L/opt/cuda-toolkit/lib64 -m32 -ggdb -I src/ -I /opt/cuda-toolkit/include/ -DCPP_IMPL -DCUDA_IMPL -DSSE2_IMPL -c src/loop/genericPlotter.cpp -o build/loop/genericPlotter.o
g++ -fpermissive -L/opt/cuda-toolkit/lib64 -m32 -ggdb -I src/ -I /opt/cuda-toolkit/include/ -DCPP_IMPL -DCUDA_IMPL -DSSE2_IMPL -c src/loop/plot.cpp -o build/loop/plot.o
g++ -fpermissive -L/opt/cuda-toolkit/lib64 -m32 -ggdb -I src/ -I /opt/cuda-toolkit/include/ -DCPP_IMPL -DCUDA_IMPL -DSSE2_IMPL -c src/loop/loop.cpp -o build/loop/loop.o
g++ -fpermissive -L/opt/cuda-toolkit/lib64 -m32 -ggdb -I src/ -I /opt/cuda-toolkit/include/ -DCPP_IMPL -DCUDA_IMPL -DSSE2_IMPL -c src/loop/joinEnumLoop.cpp -o build/loop/joinEnumLoop.o
g++ -fpermissive -L/opt/cuda-toolkit/lib64 -m32 -ggdb -I src/ -I /opt/cuda-toolkit/include/ -DCPP_IMPL -DCUDA_IMPL -DSSE2_IMPL -c src/loop/test.cpp -o build/loop/test.o
g++ -fpermissive -L/opt/cuda-toolkit/lib64 -m32 -ggdb -I src/ -I /opt/cuda-toolkit/include/ -DCPP_IMPL -DCUDA_IMPL -DSSE2_IMPL -c src/loop/parametersMap.cpp -o build/loop/parametersMap.o
g++ -fpermissive -L/opt/cuda-toolkit/lib64 -m32 -ggdb -I src/ -I /opt/cuda-toolkit/include/ -DCPP_IMPL -DCUDA_IMPL -DSSE2_IMPL -c src/loopTest/taskPlotter.cpp -o build/loopTest/taskPlotter.o
g++ -fpermissive -L/opt/cuda-toolkit/lib64 -m32 -ggdb -I src/ -I /opt/cuda-toolkit/include/ -DCPP_IMPL -DCUDA_IMPL -DSSE2_IMPL -c src/loopTest/chronoPlotter.cpp -o build/loopTest/chronoPlotter.o
/usr/local/cuda/bin/nvcc -I src/ -I /opt/cuda-toolkit/include/ -DCPP_IMPL -DCUDA_IMPL -DSSE2_IMPL -L/opt/cuda-toolkit/lib64 -lcudart  build/test/testMemoryLosses.o build/common/chronometer.o build/common/dummy.o build/common/enumerations.o build/common/util.o build/optimization/factory.o build/neural/interface.o build/neural/connection.o build/neural/neuralNet.o build/neural/layer.o build/neural/inputLayer.o build/neural/buffer.o build/genetic/individual.o build/genetic/task.o build/genetic/population.o build/game/reversiBoard.o build/game/board.o build/tasks/reversiTask.o build/tasks/binaryTask.o build/tasks/classificationTask.o build/loop/rangeLoop.o build/loop/enumLoop.o build/loop/genericPlotter.o build/loop/plot.o build/loop/loop.o build/loop/joinEnumLoop.o build/loop/test.o build/loop/parametersMap.o build/loopTest/taskPlotter.o build/loopTest/chronoPlotter.o build/optimization/cuda_code.o -o bin/testMemoryLosses.exe
/usr/bin/ld: i386 architecture of input file `build/test/testMemoryLosses.o' is incompatible with i386:x86-64 output
/usr/bin/ld: i386 architecture of input file `build/common/chronometer.o' is incompatible with i386:x86-64 output
/usr/bin/ld: i386 architecture of input file `build/common/dummy.o' is incompatible with i386:x86-64 output
/usr/bin/ld: i386 architecture of input file `build/common/enumerations.o' is incompatible with i386:x86-64 output
/usr/bin/ld: i386 architecture of input file `build/common/util.o' is incompatible with i386:x86-64 output
/usr/bin/ld: i386 architecture of input file `build/optimization/factory.o' is incompatible with i386:x86-64 output
/usr/bin/ld: i386 architecture of input file `build/neural/interface.o' is incompatible with i386:x86-64 output
/usr/bin/ld: i386 architecture of input file `build/neural/connection.o' is incompatible with i386:x86-64 output
/usr/bin/ld: i386 architecture of input file `build/neural/neuralNet.o' is incompatible with i386:x86-64 output
/usr/bin/ld: i386 architecture of input file `build/neural/layer.o' is incompatible with i386:x86-64 output
/usr/bin/ld: i386 architecture of input file `build/neural/inputLayer.o' is incompatible with i386:x86-64 output
/usr/bin/ld: i386 architecture of input file `build/neural/buffer.o' is incompatible with i386:x86-64 output
/usr/bin/ld: i386 architecture of input file `build/genetic/individual.o' is incompatible with i386:x86-64 output
/usr/bin/ld: i386 architecture of input file `build/genetic/task.o' is incompatible with i386:x86-64 output
/usr/bin/ld: i386 architecture of input file `build/genetic/population.o' is incompatible with i386:x86-64 output
/usr/bin/ld: i386 architecture of input file `build/game/reversiBoard.o' is incompatible with i386:x86-64 output
/usr/bin/ld: i386 architecture of input file `build/game/board.o' is incompatible with i386:x86-64 output
/usr/bin/ld: i386 architecture of input file `build/tasks/reversiTask.o' is incompatible with i386:x86-64 output
/usr/bin/ld: i386 architecture of input file `build/tasks/binaryTask.o' is incompatible with i386:x86-64 output
/usr/bin/ld: i386 architecture of input file `build/tasks/classificationTask.o' is incompatible with i386:x86-64 output
/usr/bin/ld: i386 architecture of input file `build/loop/rangeLoop.o' is incompatible with i386:x86-64 output
/usr/bin/ld: i386 architecture of input file `build/loop/enumLoop.o' is incompatible with i386:x86-64 output
/usr/bin/ld: i386 architecture of input file `build/loop/genericPlotter.o' is incompatible with i386:x86-64 output
/usr/bin/ld: i386 architecture of input file `build/loop/plot.o' is incompatible with i386:x86-64 output
/usr/bin/ld: i386 architecture of input file `build/loop/loop.o' is incompatible with i386:x86-64 output
/usr/bin/ld: i386 architecture of input file `build/loop/joinEnumLoop.o' is incompatible with i386:x86-64 output
/usr/bin/ld: i386 architecture of input file `build/loop/test.o' is incompatible with i386:x86-64 output
/usr/bin/ld: i386 architecture of input file `build/loop/parametersMap.o' is incompatible with i386:x86-64 output
/usr/bin/ld: i386 architecture of input file `build/loopTest/taskPlotter.o' is incompatible with i386:x86-64 output
/usr/bin/ld: i386 architecture of input file `build/loopTest/chronoPlotter.o' is incompatible with i386:x86-64 output
build/test/testMemoryLosses.o: In function `testPopulation(ParametersMap*)':
/home/luceo/Downloads/preann/src/test/testMemoryLosses.cpp:65: undefined reference to `operator new(unsigned int)'
/home/luceo/Downloads/preann/src/test/testMemoryLosses.cpp:66: undefined reference to `operator new(unsigned int)'
/home/luceo/Downloads/preann/src/test/testMemoryLosses.cpp:67: undefined reference to `operator new(unsigned int)'
/home/luceo/Downloads/preann/src/test/testMemoryLosses.cpp:81: undefined reference to `operator new(unsigned int)'
build/test/testMemoryLosses.o: In function `main':
/home/luceo/Downloads/preann/src/test/testMemoryLosses.cpp:103: undefined reference to `operator new(unsigned int)'
build/test/testMemoryLosses.o:/home/luceo/Downloads/preann/src/test/testMemoryLosses.cpp:106: more undefined references to `operator new(unsigned int)' follow
build/common/dummy.o: In function `std::basic_string<char, std::char_traits<char>, std::allocator<char> > std::operator+<char, std::char_traits<char>, std::allocator<char> >(char const*, std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)':
/usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.0/../../../../include/c++/4.7.0/bits/basic_string.tcc:702: undefined reference to `std::string::reserve(unsigned int)'
/usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.0/../../../../include/c++/4.7.0/bits/basic_string.tcc:703: undefined reference to `std::string::append(char const*, unsigned int)'
build/common/util.o: In function `__gnu_cxx::new_allocator<void*>::allocate(unsigned int, void const*)':
/usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.0/../../../../include/c++/4.7.0/ext/new_allocator.h:94: undefined reference to `operator new(unsigned int)'
build/common/util.o: In function `__gnu_cxx::new_allocator<unsigned int>::allocate(unsigned int, void const*)':
/usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.0/../../../../include/c++/4.7.0/ext/new_allocator.h:94: undefined reference to `operator new(unsigned int)'
build/common/util.o: In function `__gnu_cxx::new_allocator<std::pair<unsigned int, unsigned int> >::allocate(unsigned int, void const*)':
/usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.0/../../../../include/c++/4.7.0/ext/new_allocator.h:94: undefined reference to `operator new(unsigned int)'
build/optimization/factory.o: In function `Buffer* func_newBuffer<(BufferType)0, float>(unsigned int, ImplementationType)':
/home/luceo/Downloads/preann/src/optimization/configFactory.h:28: undefined reference to `operator new(unsigned int)'
/home/luceo/Downloads/preann/src/optimization/configFactory.h:37: undefined reference to `operator new(unsigned int)'
build/optimization/factory.o:/home/luceo/Downloads/preann/src/optimization/configFactory.h:48: more undefined references to `operator new(unsigned int)' follow
build/optimization/factory.o: In function `XmmConnection<(BufferType)2, unsigned int>::_calculateAndAddTo(Buffer*)':
/home/luceo/Downloads/preann/src/template/xmmConnection.h:102: undefined reference to `XMMreal'
/home/luceo/Downloads/preann/src/template/xmmConnection.h:110: undefined reference to `XMMbinario'
/home/luceo/Downloads/preann/src/template/xmmConnection.h:118: undefined reference to `XMMbipolar'
build/optimization/factory.o: In function `XmmConnection<(BufferType)1, unsigned int>::_calculateAndAddTo(Buffer*)':
/home/luceo/Downloads/preann/src/template/xmmConnection.h:102: undefined reference to `XMMreal'
/home/luceo/Downloads/preann/src/template/xmmConnection.h:110: undefined reference to `XMMbinario'
/home/luceo/Downloads/preann/src/template/xmmConnection.h:118: undefined reference to `XMMbipolar'
build/optimization/factory.o: In function `XmmConnection<(BufferType)3, unsigned char>::_calculateAndAddTo(Buffer*)':
/home/luceo/Downloads/preann/src/template/xmmConnection.h:102: undefined reference to `XMMreal'
/home/luceo/Downloads/preann/src/template/xmmConnection.h:110: undefined reference to `XMMbinario'
/home/luceo/Downloads/preann/src/template/xmmConnection.h:118: undefined reference to `XMMbipolar'
build/optimization/factory.o: In function `XmmConnection<(BufferType)0, float>::_calculateAndAddTo(Buffer*)':
/home/luceo/Downloads/preann/src/template/xmmConnection.h:102: undefined reference to `XMMreal'
/home/luceo/Downloads/preann/src/template/xmmConnection.h:110: undefined reference to `XMMbinario'
/home/luceo/Downloads/preann/src/template/xmmConnection.h:118: undefined reference to `XMMbipolar'
build/neural/neuralNet.o: In function `NeuralNet::addLayer(unsigned int, BufferType, FunctionType)':
/home/luceo/Downloads/preann/src/neural/neuralNet.cpp:33: undefined reference to `operator new(unsigned int)'
build/neural/neuralNet.o: In function `NeuralNet::addInputLayer(Interface*)':
/home/luceo/Downloads/preann/src/neural/neuralNet.cpp:49: undefined reference to `operator new(unsigned int)'
build/neural/neuralNet.o: In function `NeuralNet::load(_IO_FILE*)':
/home/luceo/Downloads/preann/src/neural/neuralNet.cpp:196: undefined reference to `operator new(unsigned int)'
/home/luceo/Downloads/preann/src/neural/neuralNet.cpp:199: undefined reference to `operator new(unsigned int)'
build/neural/neuralNet.o: In function `__gnu_cxx::new_allocator<Layer*>::allocate(unsigned int, void const*)':
/usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.0/../../../../include/c++/4.7.0/ext/new_allocator.h:94: undefined reference to `operator new(unsigned int)'
build/neural/neuralNet.o:/usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.0/../../../../include/c++/4.7.0/ext/new_allocator.h:94: more undefined references to `operator new(unsigned int)' follow
collect2: error: ld returned 1 exit status
make: *** [bin/testMemoryLosses.exe] Error 1

I do have a lot of the stuff from multilib installed (I'm a gamer, so have to have a lot of it installed).

I'm not sure how difficult it will be to get this working, and how that compares to the difficulty of porting the assembly code.

1481136418
Hero Member
*
Offline Offline

Posts: 1481136418

View Profile Personal Message (Offline)

Ignore
1481136418
Reply with quote  #2

1481136418
Report to moderator
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction. Advertise here.
1481136418
Hero Member
*
Offline Offline

Posts: 1481136418

View Profile Personal Message (Offline)

Ignore
1481136418
Reply with quote  #2

1481136418
Report to moderator
jtimon
Legendary
*
Offline Offline

Activity: 1246


View Profile WWW
June 21, 2012, 05:20:43 PM
 #22

I'm not sure how difficult it will be to get this working, and how that compares to the difficulty of porting the assembly code.

Uff, after reading some webs and manuals, and trying it for less than half an hour I give up. Porting the assembly seems to really be a pain. I thought 64 bits wasn't going to be that different. Besides I don't touch that code for years and although it's documented, reading assembly...

Please, try to put the -m32 flag on nvcc too. If that doesn't work, I'll search for the new error (if it's different) or I'll use separate charts to compare the performance of each implementation.

2 different forms of free-money: Freicoin (free of basic interest because it's perishable), Mutual credit (no interest because it's abundant)
jtimon
Legendary
*
Offline Offline

Activity: 1246


View Profile WWW
June 21, 2012, 06:10:07 PM
 #23

Ok, I found out why the initial makefile didn't work for you. A stupid thing.  Embarrassed
You have to call "make all" explicitly and not just "make".
I was used to compile from eclipse and it put "all" there by default, but from console I did never actually tried just "make". Usually "make sse2" or "make all_emu". I should have noticed that before and you wouldn't had to take CXX_BASE out of the conditions. I thought "all" was in $(MAKECMDGOALS) by default when you call just "make". And don't know why I thought I tested it. My fault, sorry.
I've prepared this other makefile for you:

http://content.wuala.com/contents/jtimon/temp/MakefileForLuceo?dl=1

use "make cuda" to avoid the sse2 stuff

For trying the multilib thing, use this one:

http://content.wuala.com/contents/jtimon/temp/MakefileForLuceoSse2?dl=1

for this one use "make all"

I think that the permissive flag may not be necessary after all, but maybe that's unrelated.
Can you try removing that too (from the first one if it works)?

2 different forms of free-money: Freicoin (free of basic interest because it's perishable), Mutual credit (no interest because it's abundant)
DrHaribo
Legendary
*
Offline Offline

Activity: 1960


Bitminter.com Operator


View Profile WWW
June 25, 2012, 02:09:04 PM
 #24

Wow, Skynet in the making Cheesy

▶▶▶ Bitminter.com - Your trusted mining pool since 2011.
Pages: « 1 [2]  All
  Print  
 
Jump to:  

Sponsored by , a Bitcoin-accepting VPN.
Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!