mersenneforum.org  

Go Back   mersenneforum.org > Factoring Projects > Msieve

Reply
 
Thread Tools
Old 2018-01-01, 17:02   #1
xilman
Bamboozled!
 
xilman's Avatar
 
"π’‰Ίπ’ŒŒπ’‡·π’†·π’€­"
May 2003
Down not across

299316 Posts
Default CUDA 9 and sm_20

The latest CUDA compiler no longer supports the cc2.x architecture. This has caused a number of problems and has now hit msieve's Makefile.

Anyone want to decide what to do and update msieve appropriately?

I'd do it but there are doubtless folks here more skilled than I am. For a start, I have no capability to build under Windoze.

FWIW, GMP-ECM has hit the same issue. I'm responsible for the CUDA build there but we explicitly don't support native Windoze builds and so the problem can be safely ignored for the time being.

Added in edit: I really don't want to do it. An attempt to kludge my way through led me in to a twisty little maze of nvcc options all different.

Last fiddled with by xilman on 2018-01-01 at 17:31
xilman is offline   Reply With Quote
Old 2018-01-01, 18:08   #2
xilman
Bamboozled!
 
xilman's Avatar
 
"π’‰Ίπ’ŒŒπ’‡·π’†·π’€­"
May 2003
Down not across

29×367 Posts
Default

It gets worse:
Code:
pcl@anubis ~/nums/msieve-code/trunk $ ./msieve -i W852.n -g 0 -t 6 -np
integrator failed nan inf
Oh well, lets see whether CADO-NFS still works.

Nope it didn't.

I can see the New Year's resolution is to get the old tool kits working again. Ho hum.

Last fiddled with by xilman on 2018-01-01 at 19:00
xilman is offline   Reply With Quote
Old 2021-01-25, 22:48   #3
kruoli
 
kruoli's Avatar
 
"Oliver"
Sep 2017
Porta Westfalica, DE

467 Posts
Default

This message occured with "recent" CADO-NFS 2.3.0 with CUDA. For reference, since this was the only exact search result for that exact message I got on Google, I got it working by removing every temporary or intermediate file in the executable's directory. Before that, it crashed with the exact same message.
kruoli is offline   Reply With Quote
Old 2021-01-26, 07:33   #4
kruoli
 
kruoli's Avatar
 
"Oliver"
Sep 2017
Porta Westfalica, DE

467 Posts
Minus

Quote:
Originally Posted by kruoli View Post
... CADO-NFS 2.3.0 ...
Sleep more, think more...
I have no idea why I was thinking about CADO, this is of course totally wrong. Sorry for the misinformation. I was using msieve, SVN 998, and had the problem.
kruoli is offline   Reply With Quote
Old 2021-01-26, 16:42   #5
chris2be8
 
chris2be8's Avatar
 
Sep 2009

202510 Posts
Default

The last time I had to install msieve on a system with a CUDA capable GPU I had to update the Makefiles as follows:
Code:
chris@sirius:~/factordb$ diff -u /home/chris/msieve.1030/trunk/Makefile /home/chris/msieve.1030.cuda/trunk/Makefile 
--- /home/chris/msieve.1030/trunk/Makefile	2019-12-07 19:15:56.039498635 +0000
+++ /home/chris/msieve.1030.cuda/trunk/Makefile	2019-12-07 20:01:18.819251935 +0000
@@ -196,8 +196,8 @@
 
 #---------------------------------- GPU file lists -------------------------
 
+#	stage1_core_sm20.ptx 
 GPU_OBJS += \
-	stage1_core_sm20.ptx \
 	stage1_core_sm30.ptx \
 	stage1_core_sm35.ptx \
 	stage1_core_sm50.ptx \
@@ -334,8 +334,8 @@
 
 # GPU build rules
 
-stage1_core_sm20.ptx: $(NFS_GPU_HDR)
-	$(NVCC) -arch sm_20 -ptx -o $@ $<
+#stage1_core_sm20.ptx: $(NFS_GPU_HDR)
+#	$(NVCC) -arch sm_20 -ptx -o $@ $<
 
 stage1_core_sm30.ptx: $(NFS_GPU_HDR)
 	$(NVCC) -arch sm_30 -ptx -o $@ $<
@@ -347,4 +347,4 @@
 	$(NVCC) -arch sm_50 -ptx -o $@ $<
 
 cub/built:
-	cd cub && make WIN=$(WIN) WIN64=$(WIN64) sm=200,300,350,520 && cd ..
+	cd cub && make WIN=$(WIN) WIN64=$(WIN64) sm=300,350,520 && cd ..
Code:
chris@sirius:~/factordb$ diff -u /home/chris/msieve.1030/trunk/cub/Makefile /home/chris/msieve.1030.cuda/trunk/cub/Makefile 
--- /home/chris/msieve.1030/trunk/cub/Makefile	2019-12-07 19:16:01.763534223 +0000
+++ /home/chris/msieve.1030.cuda/trunk/cub/Makefile	2019-12-09 21:40:42.328453882 +0000
@@ -16,7 +16,7 @@
 	NVCC = "$(shell which nvcc)"
 	CUDA_ROOT = $(shell dirname $(NVCC))/../
 	EXT = so
-	NVCCFLAGS += -Xptxas -v -Xcudafe -\# -shared -Xptxas -abi=no \
+	NVCCFLAGS += -Xptxas -v -Xcudafe -\# -shared \
 			-Xcompiler -fPIC -Xcompiler -fvisibility=hidden
 endif
 
@@ -43,14 +43,6 @@
     SM_TARGETS 	+= -gencode=arch=compute_30,code=\"sm_30,compute_30\"
     SM_DEF 		+= -DSM300
 endif
-ifeq (210, $(findstring 210, $(SM_ARCH)))
-    SM_TARGETS 	+= -gencode=arch=compute_20,code=\"sm_21,compute_20\"
-    SM_DEF 		+= -DSM210
-endif
-ifeq (200, $(findstring 200, $(SM_ARCH)))
-    SM_TARGETS 	+= -gencode=arch=compute_20,code=\"sm_20,compute_20\"
-    SM_DEF 		+= -DSM200
-endif
 
 rwildcard=$(foreach d,$(wildcard $1*),$(call rwildcard,$d/,$2) $(filter $(subst *,%,$2),$d))
After that it worked for me.

Chris
chris2be8 is offline   Reply With Quote
Old 2021-01-26, 17:40   #6
Brian Gladman
 
Brian Gladman's Avatar
 
May 2008
Worcester, United Kingdom

2·263 Posts
Default

Quote:
Originally Posted by xilman View Post
The latest CUDA compiler no longer supports the cc2.x architecture. This has caused a number of problems and has now hit msieve's Makefile.

Anyone want to decide what to do and update msieve appropriately?

I'd do it but there are doubtless folks here more skilled than I am. For a start, I have no capability to build under Windoze.

FWIW, GMP-ECM has hit the same issue. I'm responsible for the CUDA build there but we explicitly don't support native Windoze builds and so the problem can be safely ignored for the time being.

Added in edit: I really don't want to do it. An attempt to kludge my way through led me in to a twisty little maze of nvcc options all different.
GMP-ECM explicitly does support native Windows builds and has done so for many years (I maintain this part of the build which uses Microsoft Visual Studio). I also fully support the CUDA build of MSIEVE on Windows.

Last fiddled with by Brian Gladman on 2021-01-26 at 17:44
Brian Gladman is offline   Reply With Quote
Old 2021-01-26, 17:59   #7
xilman
Bamboozled!
 
xilman's Avatar
 
"π’‰Ίπ’ŒŒπ’‡·π’†·π’€­"
May 2003
Down not across

29×367 Posts
Default

Quote:
Originally Posted by Brian Gladman View Post
GMP-ECM explicitly does support native Windows builds and has done so for many years (I maintain this part of the build which uses Microsoft Visual Studio). I also fully support the CUDA build of MSIEVE on Windows.
Excellent!

Do you have fully static builds available? As I can't get anything to work natively it might be worth trying to run a Windows executable under WINE.
xilman is offline   Reply With Quote
Old 2021-01-26, 18:35   #8
Brian Gladman
 
Brian Gladman's Avatar
 
May 2008
Worcester, United Kingdom

2×263 Posts
Default

Quote:
Originally Posted by xilman View Post
Excellent!

Do you have fully static builds available? As I can't get anything to work natively it might be worth trying to run a Windows executable under WINE.
HI Paul,

The builds in the official repositories for GMP-ECM and MSIEVE are both static. If you don't know the repository locations I can let you have them (I am not sure about posting their locations here).
Brian Gladman is offline   Reply With Quote
Old 2021-01-26, 22:25   #9
firejuggler
 
firejuggler's Avatar
 
Apr 2010
Over the rainbow

1001111010012 Posts
Default

I would love a ptx compatible with a compute ability 7.5....
firejuggler is offline   Reply With Quote
Old 2021-01-27, 03:24   #10
Happy5214
 
Happy5214's Avatar
 
"Alexander"
Nov 2008
The Alamo City

2·3·5·19 Posts
Default

Quote:
Originally Posted by firejuggler View Post
I would love a ptx compatible with a compute ability 7.5....
Seconded. Attempting to build msieve and GMP-ECM on my brand-new Kubuntu Focus (RTX 2060) was very frustrating, and I still don't think I did it right.

Last fiddled with by Happy5214 on 2021-01-27 at 03:24 Reason: Clarify
Happy5214 is offline   Reply With Quote
Old 2021-01-27, 09:40   #11
Brian Gladman
 
Brian Gladman's Avatar
 
May 2008
Worcester, United Kingdom

52610 Posts
Default

Quote:
Originally Posted by Happy5214 View Post
Seconded. Attempting to build msieve and GMP-ECM on my brand-new Kubuntu Focus (RTX 2060) was very frustrating, and I still don't think I did it right.
Anyone who is having problems in building Windows x64 CUDA versions of MSIEVE or GMP-ECM using Visual Studio 2019 is welcome to report their issues here and I will do what I can to help.
Brian Gladman is offline   Reply With Quote
Reply

Thread Tools


Similar Threads
Thread Thread Starter Forum Replies Last Post
CUDA 5.5 ET_ GPU Computing 2 2013-06-13 15:50
AVX CPU LL vs CUDA LL nucleon GPU Computing 11 2012-01-04 17:52
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
CUDA? Xentar Conjectures 'R Us 6 2010-03-31 07:43

All times are UTC. The time now is 12:18.

Wed Apr 14 12:18:29 UTC 2021 up 6 days, 6:59, 0 users, load averages: 3.52, 2.80, 2.39

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2021, 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.