Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Will programs compiled w/ -march=pentium3 run on pentium4's?
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
gcasillo
l33t
l33t


Joined: 23 Sep 2003
Posts: 739
Location: Cincinnati, Ohio, USA

PostPosted: Wed Oct 27, 2004 6:26 am    Post subject: Will programs compiled w/ -march=pentium3 run on pentium4's? Reply with quote

My laptop died on me last week. It is a 1.6GHz P4. I compiled everything with "-march=pentium4." Naturally, the backup I was issued is a 600MHz P3. PITA, but since I keep almost all of my data backed up and most of my work is on servers, I decided to reinstall from stage 1 and compile everything with "-march=pentium3."

When my P4 laptop returns, I'd like to pick up where I left off. Will my programs compiled with pentium3 run on it? Or will I get a bunch of "Invalid instruction" errors again and have to start over?
Back to top
View user's profile Send private message
gcasillo
l33t
l33t


Joined: 23 Sep 2003
Posts: 739
Location: Cincinnati, Ohio, USA

PostPosted: Thu Oct 28, 2004 6:12 am    Post subject: Reply with quote

I guess its time to try and see what happens.
Back to top
View user's profile Send private message
kaffeen
Tux's lil' helper
Tux's lil' helper


Joined: 27 Jan 2004
Posts: 139
Location: The Frozen North

PostPosted: Thu Oct 28, 2004 6:33 am    Post subject: Reply with quote

According to make.conf.example, the code should not work if you try to use it on a Pentium 3 if it was compiled with -march=pentium4. The text from make.conf is :
Quote:
# -march=<cpu-type> means to take full advantage of the ABI and instructions
# for the particular CPU; this will break compatibility with older CPUs (for
# example, -march=athlon-xp code will not run on a regular Athlon, and
# -march=i686 code will not run on a Pentium Classic.


Edit: I misunderstood you and got it backwards. -march=pentium3 will work with a Pentium4, just not vice versa.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum