mersenneforum.org  

Go Back   mersenneforum.org > Factoring Projects > Msieve

Reply
 
Thread Tools
Old 2011-09-02, 14:28   #1
EdH
 
EdH's Avatar
 
"Ed Hall"
Dec 2009
Adirondack Mtns

5×13×53 Posts
Default Has SSE2 recently been added to the msieve code?

I have an AMD machine that was running Aliqueit fine with msieve until I just upgraded msieve. Now I'm getting an illegal instruction error. This CPU does not have SSE2, as I discovered when trying to run YAFU a while back, so I'm wondering if that is now the msieve problem.

I'd like to run the latest possible version, but realize this machine is limited. Unfortunately, as limited as it is, this AMD machine had been running everything faster than all my Intel machines, up until now.

This isn't real urgent. I can just grab earlier versions and try them, but it would save a little compiling/testing time if the version is known.

In case it's not SSE2 that's causing me trouble, here's my cpu info for this machine:
Code:
vendor_id    : AuthenticAMD
cpu family    : 6
model        : 8
model name    : AMD Athlon(tm) Processor
stepping    : 1
cpu MHz        : 1795.623
cache size    : 64 KB
fdiv_bug    : no
hlt_bug        : no
f00f_bug    : no
coma_bug    : no
fpu        : yes
fpu_exception    : yes
cpuid level    : 1
wp        : yes
flags        : fpu vme de pse tsc msr pae mce cx8 mtrr pge mca cmov pat pse36 mmx fxsr sse syscall mmxext 3dnowext 3dnow up
bogomips    : 3591.24
clflush size    : 32
cache_alignment    : 32
address sizes    : 34 bits physical, 32 bits virtual
power management: ts
Thanks for any assistance.
EdH is offline   Reply With Quote
Old 2011-09-02, 15:20   #2
EdH
 
EdH's Avatar
 
"Ed Hall"
Dec 2009
Adirondack Mtns

344510 Posts
Default

OK, memory is a bad thing to rely on sometimes...

Anyway, I found some records that show that I've had to use an early version for quite some time on this machine. Actually, the version I was using was revision 423. So whatever changed way back then was the issue.

No further info is needed on this. I consider it resolved (until next time my memory takes a stroll). I'll revert back to 423 and move on.
EdH is offline   Reply With Quote
Old 2011-09-02, 16:06   #3
jasonp
Tribal Bullet
 
jasonp's Avatar
 
Oct 2004

348910 Posts
Default

I think what happened was that the default architecture on 32-bit builds was changed from -march=athlon-xp to -march=k8 long ago. The athlon xp flag would not work on a 64-bit system because that's a 32-bit processor, so the choice was either using k8 (which has SSE2) for everything or remembering to change a line in the Makefile every time you moved to a 64-bit system. Since I kept forgetting to do the latter, the choice was clear :)

I do wonder whether it's time to change the default machine flag to something like a core2 though...
jasonp is offline   Reply With Quote
Old 2011-09-02, 18:05   #4
EdH
 
EdH's Avatar
 
"Ed Hall"
Dec 2009
Adirondack Mtns

5×13×53 Posts
Default

Thank you!

I grafted that line from the revision 423 Makefile into the current one and now 636 is running on this machine. Guess I should have inquired earlier...

Thanks for a great program and support!
EdH is offline   Reply With Quote
Old 2011-09-02, 20:01   #5
jasonp
Tribal Bullet
 
jasonp's Avatar
 
Oct 2004

3·1,163 Posts
Default

No problem, you in particular seem to have suffered inordinately because of my code :)
jasonp is offline   Reply With Quote
Old 2011-09-03, 06:13   #6
debrouxl
 
debrouxl's Avatar
 
Sep 2009

977 Posts
Default

FWIW, on x86/x86_64 platforms, GCC 4.2 (first released in May 2007) and newer support -march=native, which triggers automatic detection of the processor family GCC is being run on, and determination of the best -march setting among the processor models supported by that GCC version :)
I've been using it locally for a while on two Core 2 (Duo) and an Athlon II X4 when compiling msieve.
debrouxl is offline   Reply With Quote
Old 2011-09-03, 14:49   #7
jasonp
Tribal Bullet
 
jasonp's Avatar
 
Oct 2004

3·1,163 Posts
Default

I've considered using that option before, but too many distros still ship with 4.1.x and I don't want to deal with people complaining that the build doesn't work because their gcc is too old. Though lately I haven't gotten many complaints about -march=k8, so probably enough machines do support SSE2.
jasonp is offline   Reply With Quote
Old 2011-09-03, 15:17   #8
EdH
 
EdH's Avatar
 
"Ed Hall"
Dec 2009
Adirondack Mtns

1101011101012 Posts
Default

@jasonp: I hope my suffering wasn't too disturbing.

@jasonp & debrouxl: I just tried:
Code:
OPT_FLAGS = -O3 -fomit-frame-pointer -march=native -DNDEBUG -D_LARGEFILE64_SOURCE
with SVN 636M on my one AMD and two of my Intel machines. They are all running Ubuntu (one Intel 11.04 and the others are 10.04) and gcc version 4.4.3 (Ubuntu 4.4.3-4ubuntu5) on the 10.04s, with gcc version 4.5.2 (Ubuntu/Linaro 4.5.2-8ubuntu4) on the 11.04. All seems fine. (Extra note: my Fedora F14 machine has gcc version 4.5.1 20100924 (Red Hat 4.5.1-4) (GCC) installed.)

My machines are pretty old, but the OS's aren't.

Thanks again for everything.
EdH is offline   Reply With Quote
Old 2012-10-03, 23:17   #9
Dubslow
Basketry That Evening!
 
Dubslow's Avatar
 
"Bunslow the Bold"
Jun 2011
40<A<43 -89<O<-88

3·2,399 Posts
Default

I would say it's definitely time to move the -march to native. I'd be shocked if there's still a distro that ships gcc 4.1.*. Even Ubuntu 11.04, as EdH points out in the post above me, ships with 4.5, and gcc stable is up to 4.7 now, with 4.8 under development.
Dubslow is offline   Reply With Quote
Old 2012-10-04, 10:58   #10
henryzz
Just call me Henry
 
henryzz's Avatar
 
"David"
Sep 2007
Cambridge (GMT/BST)

3×5×383 Posts
Default

Quote:
Originally Posted by Dubslow View Post
I would say it's definitely time to move the -march to native. I'd be shocked if there's still a distro that ships gcc 4.1.*. Even Ubuntu 11.04, as EdH points out in the post above me, ships with 4.5, and gcc stable is up to 4.7 now, with 4.8 under development.
What does Ubuntu 10.04 LTS ship with? There are probably a few with that still. It is supported until april 2013 I think.
henryzz is offline   Reply With Quote
Old 2012-10-04, 18:08   #11
Dubslow
Basketry That Evening!
 
Dubslow's Avatar
 
"Bunslow the Bold"
Jun 2011
40<A<43 -89<O<-88

3·2,399 Posts
Default

Quote:
Originally Posted by henryzz View Post
What does Ubuntu 10.04 LTS ship with? There are probably a few with that still. It is supported until april 2013 I think.
4.4.3. (The archives are plain text files, in which a Ctrl+F for "Package: gcc" found the following.)
Quote:
Package: gcc
Priority: optional
Section: devel
Installed-Size: 64
Maintainer: Ubuntu Developers <ubuntu-devel-discuss@lists.ubuntu.com>
Original-Maintainer: Debian GCC Maintainers <debian-gcc@lists.debian.org>
Architecture: amd64
Source: gcc-defaults (1.93ubuntu1)
Version: 4:4.4.3-1ubuntu1
Provides: c-compiler
Depends: cpp (>= 4:4.4.3-1ubuntu1), gcc-4.4 (>= 4.4.3-1)
Recommends: libc6-dev | libc-dev
Suggests: gcc-multilib, make, manpages-dev, autoconf, automake1.9, libtool, flex, bison, gdb, gcc-doc
Conflicts: gcc-doc (<< 1:2.95.3)
Filename: pool/main/g/gcc-defaults/gcc_4.4.3-1ubuntu1_amd64.deb
Size: 5064
MD5sum: b027e5fcc6ca184e35acd2de53bb9efe
SHA1: ec011247de204e0b0429fb34ab24301fbc27507f
SHA256: 13109570efcfb0899c61bf468939ce03b76bab1cfef4e56be7a599913195dd7e
Description: The GNU C compiler
This is the GNU C compiler, a fairly portable optimizing compiler for C.
.
This is a dependency package providing the default GNU C compiler.
Bugs: https://bugs.launchpad.net/ubuntu/+filebug
Build-Essential: yes
Origin: Ubuntu
Supported: 5y
Task: ubuntu-desktop, edubuntu-desktop, mythbuntu-backend-master, mythbuntu-backend-slave, mythbuntu-desktop, mythbuntu-frontend
Dubslow is offline   Reply With Quote
Reply

Thread Tools


Similar Threads
Thread Thread Starter Forum Replies Last Post
No results for Recently set up GPU 2 72 computer jschwar313 GPU to 72 3 2016-01-31 16:41
Contributions to msieve source code mickfrancis Msieve 23 2014-05-15 16:52
Source Code for msieve ? mohamed Msieve 8 2013-12-14 01:04
Recently added T.Rex mersennewiki 20 2011-04-09 02:23
Questions about SSE2 code and Factoring Joe O Software 2 2002-09-13 23:39

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

Wed Nov 25 23:30:38 UTC 2020 up 76 days, 20:41, 3 users, load averages: 1.02, 1.24, 1.29

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.