mersenneforum.org  

Go Back   mersenneforum.org > Great Internet Mersenne Prime Search > Hardware > GPU Computing

Reply
 
Thread Tools
Old 2013-01-24, 02:43   #1
Dubslow
Basketry That Evening!
 
Dubslow's Avatar
 
"Bunslow the Bold"
Jun 2011
40<A<43 -89<O<-88

3·29·83 Posts
Default CUDA-gcc incompatibility workaround

So I have a new OS install, with gcc 4.7.2, which as yet is unsupported by CUDA 5. I have no intentions of installing a second compiler, so does anyone know of another work around?

I suppose all I really need is a way to compile mfaktc, CUDALucas, and Msieve (or someone to do it for me).

PS Does anyone know of a free/libre replacement for nvcc? (And I suppose you'd need to duplicate the libs as well )

Last fiddled with by Dubslow on 2013-01-24 at 03:03
Dubslow is offline   Reply With Quote
Old 2013-01-26, 05:41   #2
Ken_g6
 
Ken_g6's Avatar
 
Jan 2005
Caught in a sieve

5·79 Posts
Default

See if your package manager has a CUDA dev package. Mine does, but it requires uninstalling the proprietary driver, which means I couldn't play games. But if you don't want to play games, it might work for you.

Edit: P.S. I do plan to install a second compiler - in a virtual machine.

Last fiddled with by Ken_g6 on 2013-01-26 at 05:41
Ken_g6 is offline   Reply With Quote
Old 2013-01-26, 07:34   #3
Dubslow
Basketry That Evening!
 
Dubslow's Avatar
 
"Bunslow the Bold"
Jun 2011
40<A<43 -89<O<-88

722110 Posts
Default

Bleh.

On the other hand, based on something I read a few hours ago, is it possible to mount my old installation (as I have already done) and then chroot into it? Does chroot change the entire environment, so that I would be using the new kernel with the old file system and programs? I think this bears research, and any comments/tips/advice are greatly appreciated.
Dubslow is offline   Reply With Quote
Old 2013-01-26, 14:42   #4
owftheevil
 
owftheevil's Avatar
 
"Carl Darby"
Oct 2012
Spring Mountains, Nevada

32×5×7 Posts
Default

Its a bit flaky, but this worked for me, at least to get CUDALucus built on Ubuntu12.10.

Copy all of cuda-5.0 to /usr/local/ or wherever you want to put it, make a link cuda linking to cuda 5.0 in the same place, then in cuda5.0/include/ edit line 80 of host_config.h, changing the 6 to a 7.

gcc4.7 really isn't supported by cuda5.0, so some things won't build. CUDALucas does and seems to work ok, but I haven't tried mfaktc. Some of the examples in the SDK do not work.

Now a warning. On my box, with any 300+ driver on Ubuntu12.04 or 12.10, CUDALucas2.04 and later occasionally hang on the cudaMemcpy in lucas_square. Toolkit version 4.2 or 5.0, built with gcc4.6 or 4.7 don't make any difference.
owftheevil is offline   Reply With Quote
Old 2013-01-26, 16:03   #5
chalsall
If I May
 
chalsall's Avatar
 
"Chris Halsall"
Sep 2002
Barbados

2·112·47 Posts
Default

Quote:
Originally Posted by Dubslow View Post
Does chroot change the entire environment, so that I would be using the new kernel with the old file system and programs? I think this bears research, and any comments/tips/advice are greatly appreciated.
chroot changes the root of the file system. So the "host" kernel will be running the chroot'ed programs. Keep in mind that any dynamically linked libraries are pulled from the chroot'ed file system as well.
chalsall is offline   Reply With Quote
Old 2013-01-26, 17:18   #6
Dubslow
Basketry That Evening!
 
Dubslow's Avatar
 
"Bunslow the Bold"
Jun 2011
40<A<43 -89<O<-88

1C3516 Posts
Default

Quote:
Originally Posted by owftheevil View Post
Its a bit flaky, but this worked for me, at least to get CUDALucus built on Ubuntu12.10.

Copy all of cuda-5.0 to /usr/local/ or wherever you want to put it, make a link cuda linking to cuda 5.0 in the same place, then in cuda5.0/include/ edit line 80 of host_config.h, changing the 6 to a 7.

gcc4.7 really isn't supported by cuda5.0, so some things won't build. CUDALucas does and seems to work ok, but I haven't tried mfaktc. Some of the examples in the SDK do not work.

Now a warning. On my box, with any 300+ driver on Ubuntu12.04 or 12.10, CUDALucas2.04 and later occasionally hang on the cudaMemcpy in lucas_square. Toolkit version 4.2 or 5.0, built with gcc4.6 or 4.7 don't make any difference.
Well, the 5.0 installer wouldn't even install properly, so I don't have anything in the cuda-5.0 folder.

I was however able to copy my 4.<something> environment over to the new system with gcc 4.7, edit out the the thingy in the header file and compile CUDALucas; I was not, however, able to test it, due to driver issues. Hopefully that will be resolved soon.

Quote:
Originally Posted by chalsall View Post
chroot changes the root of the file system. So the "host" kernel will be running the chroot'ed programs. Keep in mind that any dynamically linked libraries are pulled from the chroot'ed file system as well.
Okay, that sounds about like what I had described. I might give it a go then.
Dubslow is offline   Reply With Quote
Reply



Similar Threads
Thread Thread Starter Forum Replies Last Post
Suspect Software Incompatibility Dionysus Software 3 2016-02-07 13:49
CUDA 5.5 ET_ GPU Computing 2 2013-06-13 15:50
Best CUDA GPU for the $$ Christenson GPU Computing 24 2011-05-01 00:06
CUDA P-1? nucleon GPU Computing 2 2010-11-17 17:52
Crash on ecm -pm1 -resume (+workaround) Andi47 GMP-ECM 3 2010-04-17 00:27

All times are UTC. The time now is 14:51.


Fri Jul 7 14:51:45 UTC 2023 up 323 days, 12:20, 0 users, load averages: 1.09, 1.12, 1.11

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2023, Jelsoft Enterprises Ltd.

This forum has received and complied with 0 (zero) government requests for information.

Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation.
A copy of the license is included in the FAQ.

≠ ± ∓ ÷ × · − √ ‰ ⊗ ⊕ ⊖ ⊘ ⊙ ≤ ≥ ≦ ≧ ≨ ≩ ≺ ≻ ≼ ≽ ⊏ ⊐ ⊑ ⊒ ² ³ °
∠ ∟ ° ≅ ~ ‖ ⟂ ⫛
≡ ≜ ≈ ∝ ∞ ≪ ≫ ⌊⌋ ⌈⌉ ∘ ∏ ∐ ∑ ∧ ∨ ∩ ∪ ⨀ ⊕ ⊗ 𝖕 𝖖 𝖗 ⊲ ⊳
∅ ∖ ∁ ↦ ↣ ∩ ∪ ⊆ ⊂ ⊄ ⊊ ⊇ ⊃ ⊅ ⊋ ⊖ ∈ ∉ ∋ ∌ ℕ ℤ ℚ ℝ ℂ ℵ ℶ ℷ ℸ 𝓟
¬ ∨ ∧ ⊕ → ← ⇒ ⇐ ⇔ ∀ ∃ ∄ ∴ ∵ ⊤ ⊥ ⊢ ⊨ ⫤ ⊣ … ⋯ ⋮ ⋰ ⋱
∫ ∬ ∭ ∮ ∯ ∰ ∇ ∆ δ ∂ ℱ ℒ ℓ
𝛢𝛼 𝛣𝛽 𝛤𝛾 𝛥𝛿 𝛦𝜀𝜖 𝛧𝜁 𝛨𝜂 𝛩𝜃𝜗 𝛪𝜄 𝛫𝜅 𝛬𝜆 𝛭𝜇 𝛮𝜈 𝛯𝜉 𝛰𝜊 𝛱𝜋 𝛲𝜌 𝛴𝜎𝜍 𝛵𝜏 𝛶𝜐 𝛷𝜙𝜑 𝛸𝜒 𝛹𝜓 𝛺𝜔