mersenneforum.org mtsieve
 Register FAQ Search Today's Posts Mark Forums Read

2020-05-29, 10:35   #320
rogue

"Mark"
Apr 2003
Between here and the

2·3,169 Posts

Quote:
 Originally Posted by Citrix I was finally able to modify the GPU code. I had to do the Perl portion manually. The script did not work for me. It goes into an infinite while loop. The code did compile. Though I cannot get the code to run. I have tried the original gcwsievecl.exe from mtsieve and that does not work either. afsievecl.exe does not work either. ppsieve (open cl) etc works fine. Any thoughts on how to fix this.
Hmm. Are you getting an error at runtime with gcwsievecl? If so, what error are you getting?

In the meantime, I'll do some tests to see if it is working for me. Maybe I broke something with a more recent change.

Last fiddled with by rogue on 2020-05-29 at 10:36

2020-05-29, 23:10   #321
Citrix

Jun 2003

22·5·79 Posts

Quote:
 Originally Posted by rogue Hmm. Are you getting an error at runtime with gcwsievecl? If so, what error are you getting? In the meantime, I'll do some tests to see if it is working for me. Maybe I broke something with a more recent change.

No message, It does crash before the start banner is printed. Possibly I am not using the input line correctly.

I am using :- Should I be using something else? Both programs crash for me.

Code:
gcwsievecl.exe -p 3770000000000 -P 4000000000000 -b 2 -n 825 -N 1000 -s +
afsievecl.exe -n 825 -N 1000

Even using "any*cl.exe -h" will crash and not print the help options.

 2020-05-30, 01:19 #322 Citrix     Jun 2003 22×5×79 Posts Looking at the code more closely - In the make file for linking the *cl files the $(GPUCPPFLAGS) and$(*_GPU_OBJS) is missing so the compiler does not even build the GPU.o files. I now have Code: gcwsievecl: $(GPU_CORE_OBJS)$(PRIMESIEVE_OBJS) $(ASM_OBJS)$(GCW_OBJS) $(GCW_GPU_OBJS)$(CC) $(CPPFLAGS)$(LDFLAGS) -o $@$^ $(GPUCPPFLAGS)$(GPULDFLAGS) $(EXTRALDFLAGS) In ip_CullenWoodallApp->GetDevice() ; there is no function defined as GetDevice. Maybe an object of device type needs to be created under CullenWoodallGpuWorker. Then use function *GetDeviceIdPtr or GetDeviceId (in device.h) Are you able to correct the code?  2020-05-30, 12:51 #323 rogue "Mark" Apr 2003 Between here and the 143028 Posts I really messed up the makefile for GPU builds. You need this line: GCW_GPU_OBJS=cullen_woodall/CullenWoodallApp_gpu.o cullen_woodall/CullenWoodallWorker.o cullen_woodall/CullenWoodallGpuWorker_gpu.o and this line: gcwsievecl:$(GPU_CORE_OBJS) $(PRIMESIEVE_OBJS)$(ASM_OBJS) $(GCW_GPU_OBJS)$(CC) $(CPPFLAGS)$(LDFLAGS) -o $@$^ $(GPULDFLAGS)$(EXTRALDFLAGS) to get a clean build. I haven't tested it yet, but I know that I have to fix the other OpenCL exes. Thanks for the find. BTW, I just committed an updated makefile that should fix all OpenCL exes. Last fiddled with by rogue on 2020-05-30 at 13:02
 2020-05-30, 15:15 #324 Citrix     Jun 2003 62C16 Posts It did not work for me.
2020-05-30, 15:16   #325
rogue

"Mark"
Apr 2003
Between here and the

2×3,169 Posts

Quote:
 Originally Posted by Citrix It did not work for me.
Did not compile or failed when it ran?

2020-05-30, 16:38   #326
Citrix

Jun 2003

22×5×79 Posts

Quote:
 Originally Posted by rogue Did not compile or failed when it ran?
Did not compile - "too many paths"

 2020-05-30, 16:51 #327 rogue     "Mark" Apr 2003 Between here and the 2·3,169 Posts I made another change to the makefile which might address the issue. Both gcwsieve and gcwsievecl run on Windows, but I haven't tried any GPU workers. It builds, but fails on OS X, for an unknown reason that I have to look into.
2020-05-30, 16:57   #328
Citrix

Jun 2003

158010 Posts

Quote:
 Originally Posted by rogue I made another change to the makefile which might address the issue. Both gcwsieve and gcwsievecl run on Windows, but I haven't tried any GPU workers. It builds, but fails on OS X, for an unknown reason that I have to look into.
Where do you get the new makefile from?

2020-05-30, 17:32   #329
rogue

"Mark"
Apr 2003
Between here and the

2·3,169 Posts

Quote:
 Originally Posted by Citrix Where do you get the new makefile from?

Last fiddled with by rogue on 2020-05-30 at 17:33

2020-05-30, 17:54   #330
Citrix

Jun 2003

22·5·79 Posts

Quote:
 Originally Posted by rogue I had committed to svn.
You need to add gcwsievecl to

GPU_PROGS=afsievecl mfsievecl gfndsievecl pixsievecl xyyxsievecl

Compiles for me and at least I get
"gcwsievecl.exe -p 3770000000000 -P 4000000000000 -b 2 -n 825 -N 1000 -s +
gcwsieve v1.2, a program to find factors numbers of the form n*b^n+1 and n*b^n-1
Sieve started: 377e10 < p < 4e12 with 0 terms (825 <= n <= 1000, n*2^n+1) (expecting 0 factors)"

Then it crashes.

Last fiddled with by Citrix on 2020-05-30 at 18:05