mersenneforum.org  

Go Back   mersenneforum.org > Factoring Projects > CADO-NFS

Reply
 
Thread Tools
Old 2009-05-28, 16:23   #23
thome
 
May 2009

2·11 Posts
Default

Quote:
Originally Posted by R.D. Silverman View Post
I will not be using the make files. I will do this under VC++ and use
windoze .dsw files..........

This will take some time.. I have little enough of it.
I have zero experience with windows, but I feel that it's a lot of work (not to discourage you -- much the contrary). Note that cmake claims to be able to build VC++ project files, so maybe you could try that.

E.
thome is offline   Reply With Quote
Old 2009-05-28, 19:08   #24
thome
 
May 2009

2·11 Posts
Default

Quote:
Originally Posted by frmky View Post
Having said all of this, it worked for a small example but when I tried a larger example, all of the algsqrt's failed with "condition (nab & 1) == 0 failed" or "the squares do not agree modulo n!" so there are probably one or more of the parameters that are completely inappropriate for larger numbers.
There are some known issues with snfs factorizations. sqrt code is probably over-zealous on some assumptions.

If you still have an example polynomial which fails, we can try to address the problem you encounter.

E.
thome is offline   Reply With Quote
Old 2009-05-30, 07:20   #25
frmky
 
frmky's Avatar
 
Jul 2003
So Cal

22·33·19 Posts
Default

Quote:
Originally Posted by thome View Post
There are some known issues with snfs factorizations. sqrt code is probably over-zealous on some assumptions.

If you still have an example polynomial which fails, we can try to address the problem you encounter.

E.
I must be doing something wrong, then, as a GNFS case just failed the same way. I can post the relations for you to download if you've got a fast enough connection to download a total of 1GB.
frmky is offline   Reply With Quote
Old 2009-05-31, 15:03   #26
fivemack
(loop (#_fork))
 
fivemack's Avatar
 
Feb 2006
Cambridge, England

142638 Posts
Default

I'm running through a medium SNFS example I have lying around (fibonacci(1039)); the matrix comes out as

Code:
Renumbering columns (including sorting w.r.t. weight)
Sorting columns by decreasing weight
small_nrows=5582216 small_ncols=5582056
Writing sparse representation to file
#T# writing sparse: 80.00
# Weight(M_small) = 259518490
Writing index file
#T# writing index file: 6.20
versus

Code:
Mon May 18 09:14:02 2009  matrix is 4854784 x 4855032 (1383.4 MB) with weight 336557789 (69.32/col)
Mon May 18 09:14:02 2009  sparse part has weight 314102671 (64.70/col)
Mon May 18 09:14:02 2009  matrix includes 64 packed rows
However, I wanted to see which of the bw routines was the sensible one to use on i7 for a matrix of this size, so did

Code:
nfsslave2@cow:/scratch/fib1039/with-cado$ /home/nfsslave2/cado/cado-nfs-20090528-r2167/build/cow/linalg/bwc/u128_bench snfs.small
and got
Code:
Using implementation "sliced"
no cache file snfs.small-sliced.bin
T0 Building cache file for snfs.small
code BUG() : condition x >> 16 == 0 failed in push at /home/nfsslave2/cado/cado-nfs-20090528-r2167/linalg/bwc/matmul-sliced.cpp:108 -- Abort
Aborted
What am I doing wrong?
fivemack is offline   Reply With Quote
Old 2009-05-31, 18:06   #27
Chris Card
 
Chris Card's Avatar
 
Aug 2004

2·5·13 Posts
Default

Quote:
Originally Posted by Jeff Gilchrist View Post
Anyone have success building this? I keep getting errors during the build process. Seems quite complex with pthreads and MPI versions available.
I tried to build it on Linux with gcc 4.4.0, and I got a couple of errors:
1./home/chris/cado-nfs-20090528-r2167/utils/ularith.h: In function ‘ularith_sqr_ul_2ul’:
/home/chris/cado-nfs-20090528-r2167/utils/ularith.h:386: error: ‘%’ constraint used with last operand
which was easily fixed by changing "%0" to "0" and
2. /home/chris/cado-nfs-20090528-r2167/utils/modredc_15ul.c: In function ‘modredc15ul_isprime’:
/home/chris/cado-nfs-20090528-r2167/utils/modredc_15ul.c:274: error: expected declaration or statement at end of input
which has got me stumped because I can't even see an implementation of modredc15ul_isprime anywhere, let alone in that file.

Chris
Chris Card is online now   Reply With Quote
Old 2009-05-31, 18:54   #28
akruppa
 
akruppa's Avatar
 
"Nancy"
Aug 2002
Alexandria

25·7·11 Posts
Default

The _isprime() functions is defined in modredc_2ul_common.c and gets renamed according to the modulus width that is used for the arithmetic. From the first error I take it that you're doing a 32 bit build (and with gcc 4.4.0, no less - good luck!). It's probably just a missing bracket in the asm macros, I'll look.

EDIT: modredc_2ul_common.c needs a } in line 915, after line "mod_intcmp (n, c5783688565841) != 0;"

Edit2: Tom, your question is strictly Manu's territory.

Alex

Last fiddled with by akruppa on 2009-05-31 at 21:01
akruppa is offline   Reply With Quote
Old 2009-05-31, 21:32   #29
fivemack
(loop (#_fork))
 
fivemack's Avatar
 
Feb 2006
Cambridge, England

6,323 Posts
Default

I'm not very good on French nicknames; is Manu Emmanuel Thomé?

Is there actually any point in people outside the development team attempting to run this code on reasonably-sized (days rather than minutes or weeks of linalg) examples yet?
fivemack is offline   Reply With Quote
Old 2009-06-02, 11:09   #30
thome
 
May 2009

2×11 Posts
Default

Quote:
Originally Posted by fivemack View Post
I'm not very good on French nicknames; is Manu Emmanuel Thomé?
yes.

Quote:
Originally Posted by fivemack View Post
Is there actually any point in people outside the development team attempting to run this code on reasonably-sized (days rather than minutes or weeks of linalg) examples yet?
absolutely.

For the problem you encounter, the fix is quite trivial. The ``good'' low-level code for matrix multiplication is not (yet) the default one. The default, a.k.a. ``sliced'' variant, chokes on matrices having zero blobs larger than 4096*65536. In order to use the better, faster variant called ``bucket'', add bwc_mm_impl=bucket to the params file. Or change the default in linalg/bwc/matmul.c.

E.
thome is offline   Reply With Quote
Old 2009-06-02, 11:15   #31
thome
 
May 2009

268 Posts
Default

Quote:
Originally Posted by fivemack View Post
However, I wanted to see which of the bw routines was the sensible one to use on i7 for a matrix of this size, so did

Code:
nfsslave2@cow:/scratch/fib1039/with-cado$ /home/nfsslave2/cado/cado-nfs-20090528-r2167/build/cow/linalg/bwc/u128_bench snfs.small
and got
Code:
Using implementation "sliced"
no cache file snfs.small-sliced.bin
T0 Building cache file for snfs.small
code BUG() : condition x >> 16 == 0 failed in push at /home/nfsslave2/cado/cado-nfs-20090528-r2167/linalg/bwc/matmul-sliced.cpp:108 -- Abort
Aborted
What am I doing wrong?
More in detail. You're doing it right. It's just that this particular variant can't cope with this matrix. It's a good thing to try out the different options with the *_bench programs (in that particular case, u128_bench uses sse-2).

Some defaults are set in matmul-bucket.cpp, you might also try to change them a bit -- notably the CUTOFF2 value, which is perhaps still a bit large. Such changes require to rebuild the cached matrix file called mat.h#.v#-something.bin ; so before re-running uXXX_bench, rm that file first.

E.
thome is offline   Reply With Quote
Old 2009-06-02, 15:26   #32
joral
 
joral's Avatar
 
Mar 2008

5·11 Posts
Default

I'm running into a different issue, attempting to run the process manually.

When I try to run the linear algebra, I get an error about

fopen(mat.info)

saying there is not such file. This is from memory, but I can get the exact error when I get home.

Is there some other process that I missed?
joral is offline   Reply With Quote
Old 2009-06-02, 19:18   #33
thome
 
May 2009

2·11 Posts
Default

Quote:
Originally Posted by joral View Post
I'm running into a different issue, attempting to run the process manually.

When I try to run the linear algebra, I get an error about

fopen(mat.info)

saying there is not such file. This is from memory, but I can get the exact error when I get home.

Is there some other process that I missed?
this is a shortcoming in the perl driver script, which I'm going to fix. A program called ``balance'' must have been run prior to reaching the point which reads mat.info (presumably ``u64n_prep''). ``balance'' populates the working directory with the matrix files. Unfortunately, the driver script is very crude and is content with an existing, yet empty subdir as a proof of completion for ``balance''. So pending a less crude behaviour from the bwc.pl script (which should come RSN), you may either:

- rmdir the empty directory (something like /path/to/matrix-<number>x<number>) and rerun bwc.pl with the same command line.

- run bwc.pl with ``:balance'' instead of ``:complete'' first. This will add the missing files.

This being said, unless you've really try to run the stuff manually and got it wrong, there's a possibility that the ``balance'' program wasn't found because of a nasty shell variable expansion problem which has been fixed last week. So I'll refresh the snapshot anyway, there's good chance your problem will be fixed.

E.
thome is offline   Reply With Quote
Reply

Thread Tools


Similar Threads
Thread Thread Starter Forum Replies Last Post
CADO-NFS on windows jux CADO-NFS 22 2019-11-12 12:08
CADO help henryzz CADO-NFS 4 2017-11-20 15:14
CADO and WinBlows akruppa Programming 22 2015-12-31 08:37
CADO-NFS skan Information & Answers 1 2013-10-22 07:00
CADO R.D. Silverman Factoring 4 2008-11-06 12:35

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

Thu Nov 26 13:30:19 UTC 2020 up 77 days, 10:41, 3 users, load averages: 1.22, 1.31, 1.49

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.