mersenneforum.org  

Go Back   mersenneforum.org > Factoring Projects > Factoring

Reply
 
Thread Tools
Old 2017-12-29, 17:07   #1
chris2be8
 
chris2be8's Avatar
 
Sep 2009

35048 Posts
Default Compiling 64 bit lattice siever on gcc 4.8.5

Hello,

I'm trying to compile the 64 bit lattice siever on a system with gcc 4.8.5 and get:
Code:
lasieve4_64/athlon64> make liblasieve.a
...
m4  -Dn_i_bits=0 ls-defs.asm mpqs_td.asm > mpqs_td.s
gcc -c mpqs_td.s
mpqs_td.s: Assembler messages:
mpqs_td.s:249: Error: incorrect register `%r9' used with `w' suffix
mpqs_td.s:280: Error: incorrect register `%r9' used with `w' suffix
mpqs_td.s:283: Error: incorrect register `%rsi' used with `w' suffix
mpqs_td.s:313: Error: incorrect register `%r9' used with `w' suffix
Makefile:56: recipe for target 'mpqs_td.o' failed
make: *** [mpqs_td.o] Error 1
Looking in mpqs_td.s the failing lines are:
Code:
        cmpw $27,%r9
        cmpw $27,%r9
        movw %rsi,10(%rdi,%r9,2)
        cmpw $27,%r9
The same code compiles OK on gcc 4.8.3 so it looks as if gcc is now rejecting something it used to accept.

And a bit further up the code I saw:
Code:
         cmpq $27,%r9
which compiles OK. I'm tempted to change the failing cmpw's to cmpq's. But I don't know what to do with the movw (someday I need to learn Intel assembly language). Any suggestions?

Chris
chris2be8 is offline   Reply With Quote
Old 2017-12-29, 17:28   #2
axn
 
axn's Avatar
 
Jun 2003

13·359 Posts
Default

Quote:
Originally Posted by chris2be8 View Post
I'm tempted to change the failing cmpw's to cmpq's. But I don't know what to do with the movw (someday I need to learn Intel assembly language). Any suggestions?
cmpq, movq, etc...

EDIT: w = word = 16 bits, l = long = 32 bits, q = qword = 64 bits. movw, movl, movq, cmpw, cmpl, cmpq, and so on...

Last fiddled with by axn on 2017-12-29 at 17:29
axn is offline   Reply With Quote
Old 2017-12-29, 17:31   #3
bsquared
 
bsquared's Avatar
 
"Ben"
Feb 2007

1100110011002 Posts
Default

Quote:
Originally Posted by chris2be8 View Post
I'm tempted to change the failing cmpw's to cmpq's. But I don't know what to do with the movw (someday I need to learn Intel assembly language). Any suggestions?

Chris
The error should go away either by changing the 'w's to 'q', or by adding 'w's to the r9's (and changing rsi to si in the movw). Hard to say which is correct without a broader understanding of what the code is doing. Register naming reference: https://en.wikipedia.org/wiki/X86#Structure

Last fiddled with by bsquared on 2017-12-29 at 17:32
bsquared is offline   Reply With Quote
Old 2017-12-30, 08:24   #4
Gimarel
 
Apr 2010

22×5×7 Posts
Default

There's a patch in thread http://www.mersenneforum.org/showthread.php?t=21633
Gimarel is offline   Reply With Quote
Old 2017-12-30, 17:35   #5
chris2be8
 
chris2be8's Avatar
 
Sep 2009

111010001002 Posts
Default

Thanks, it compiles cleanly with that patch.

Chris
chris2be8 is offline   Reply With Quote
Old 2018-02-06, 16:35   #6
VictordeHolland
 
VictordeHolland's Avatar
 
"Victor de Hollander"
Aug 2011
the Netherlands

117610 Posts
Default

Are there any (new) pre-compiled .exe for win64 of lasieve4I<11-16> available?
The ones I'm using in combination with the the factmsieve.py (0.76) script and msieveSVN988 must be quite old?? It's not that I really need them, the ones I have work on my Win7 PC with Sandy-bridge CPU. Just curious if there are any newer (faster) ones available?

https://github.com/radii/ggnfs
Doesn't seem to have had updates in years?
and it requires CWEB (I assume from https://github.com/ascherer/cweb ) which won't <make> in msys64/mingw64.

I also noticed this thread:
http://www.mersenneforum.org/showthread.php?t=21633
that there are some problems with the assembly code??

[edit]
BTW, I have very limited experience with compiling myself.

Last fiddled with by VictordeHolland on 2018-02-06 at 16:37 Reason: can compile as long as it has a working <make> or <make install>
VictordeHolland is offline   Reply With Quote
Old 2018-02-06, 17:22   #7
henryzz
Just call me Henry
 
henryzz's Avatar
 
"David"
Sep 2007
Cambridge (GMT)

2·3·13·73 Posts
Default

Quote:
Originally Posted by VictordeHolland View Post
Are there any (new) pre-compiled .exe for win64 of lasieve4I<11-16> available?
The ones I'm using in combination with the the factmsieve.py (0.76) script and msieveSVN988 must be quite old?? It's not that I really need them, the ones I have work on my Win7 PC with Sandy-bridge CPU. Just curious if there are any newer (faster) ones available?

https://github.com/radii/ggnfs
Doesn't seem to have had updates in years?
and it requires CWEB (I assume from https://github.com/ascherer/cweb ) which won't <make> in msys64/mingw64.

I also noticed this thread:
http://www.mersenneforum.org/showthread.php?t=21633
that there are some problems with the assembly code??

[edit]
BTW, I have very limited experience with compiling myself.
If you have working 64-bit binaries then you won't gain any speed. There are a few things like ETA that aren't in some binaries but nothing crucial.
henryzz is offline   Reply With Quote
Reply

Thread Tools


Similar Threads
Thread Thread Starter Forum Replies Last Post
QS Lattice Siever R.D. Silverman Factoring 31 2018-10-08 17:17
OpenCL accellerated lattice siever pstach Factoring 1 2014-05-23 01:03
Shape of a CUDA lattice siever fivemack Programming 2 2012-12-16 01:07
Msieve / lattice siever with degree 7/8 poly Batalov Msieve 54 2010-01-13 19:45
ggnfs lattice siever misses some primes fivemack Factoring 1 2008-01-18 13:47

All times are UTC. The time now is 21:13.

Fri Aug 7 21:13:22 UTC 2020 up 21 days, 17 hrs, 1 user, load averages: 2.51, 2.14, 1.98

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