View previous topic :: View next topic |
Author |
Message |
calhoun Tux's lil' helper
Joined: 14 Nov 2003 Posts: 91 Location: Point Pleasant, NJ
|
Posted: Tue Jan 06, 2004 5:23 pm Post subject: CPU registers question |
|
|
I have a Pentium 4 at work and Athlon Tbird / XP at home. What USE flags should I use for each processor type? (ie MMX, SSE, 3Dnow ...)
Pentium 4
Athlon Tbird
Athlon XP
Thanks in advance
|
|
Back to top |
|
|
Instinct82 n00b
Joined: 16 Aug 2003 Posts: 42 Location: Trier, Germany
|
Posted: Tue Jan 06, 2004 5:28 pm Post subject: |
|
|
Searching the forums will give you many different USE flags for your systems.
Some common "safe" flags can be found here: http://www.freehackers.org/gentoo/gccflags/flag_gcc3.html _________________ my gentoo boxes
Desktop:
AMD Athlon XP 2000+
512MB DDR
GeForce3 Ti200
Samsung SyncMaster 193T
Laptop:
Asus M6800N 1,5GHz
768MB DDR
Radeon 9600 Mobility
Router:
Intel Pentium 90, 128MB RAM, True Headless |
|
Back to top |
|
|
adaptr Watchman
Joined: 06 Oct 2002 Posts: 6730 Location: Rotterdam, Netherlands
|
Posted: Tue Jan 06, 2004 6:23 pm Post subject: |
|
|
If you have a running Linux on either system (pop in the LiveCD...) this is what you do:
Code: |
#cat /proc/cpuinfo | grep flags
|
This will give you a list of processor flags, including any supported instruction set extensions.
These include mmx, 3dnow, sse and sse2.
All but sse2 can be enabled / used in Gentoo at will, since gcc does not have an sse2 option yet (AFAIK).
Instinct - smart reply, but those are not USE flags - they're C flags.
Still a good idea, of course - they may have a bigger impact on performance than the CPU USE flags (especially -O3).
Note that, while -O3 seems to be quite stable now, the kernel still prohibits using it - it will always compile with -O2. |
|
Back to top |
|
|
calhoun Tux's lil' helper
Joined: 14 Nov 2003 Posts: 91 Location: Point Pleasant, NJ
|
Posted: Tue Jan 06, 2004 6:31 pm Post subject: |
|
|
adaptr wrote: | If you have a running Linux on either system (pop in the LiveCD...) this is what you do:
Code: |
#cat /proc/cpuinfo | grep flags
|
This will give you a list of processor flags, including any supported instruction set extensions.
These include mmx, 3dnow, sse and sse2.
All but sse2 can be enabled / used in Gentoo at will, since gcc does not have an sse2 option yet (AFAIK).
Instinct - smart reply, but those are not USE flags - they're C flags.
Still a good idea, of course - they may have a bigger impact on performance than the CPU USE flags (especially -O3).
Note that, while -O3 seems to be quite stable now, the kernel still prohibits using it - it will always compile with -O2. |
Thanks for the reply. I was referring to the USE= in make.conf, but I guess they can also be set in the CFLAGS= area too. If I set them in CFLAGS, should I still set them in the USE= line?
Back to the original question, does sse work on both Pentium 4 and Athlon chips? Same question for MMX and 3DNow. I tried finding this info on Intel/AMD pages but I don't think i was searching for the right thing. |
|
Back to top |
|
|
calhoun Tux's lil' helper
Joined: 14 Nov 2003 Posts: 91 Location: Point Pleasant, NJ
|
|
Back to top |
|
|
Tamerz Apprentice
Joined: 29 Apr 2003 Posts: 232 Location: Chicago IL, USA
|
Posted: Tue Jan 06, 2004 6:57 pm Post subject: Re: CPU registers question |
|
|
Pentium 4 - MMX, SSE, SSE2
Athlon Tbird - Not really sure
Athlon XP - MMX, SSE, 3DNow |
|
Back to top |
|
|
floffe Guru
Joined: 24 Nov 2003 Posts: 414 Location: Linköping, Sweden
|
Posted: Tue Jan 06, 2004 7:06 pm Post subject: |
|
|
3dnow is amd only. There is an enhanced variant, I don't remember what it's called, that is on recent athlons (I think athlon-xp and up)
athlon-xp can handle sse, but not sse2. |
|
Back to top |
|
|
adaptr Watchman
Joined: 06 Oct 2002 Posts: 6730 Location: Rotterdam, Netherlands
|
Posted: Tue Jan 06, 2004 9:28 pm Post subject: |
|
|
calhoun wrote: | Thanks for the reply. I was referring to the USE= in make.conf, but I guess they can also be set in the CFLAGS= area too. |
No they can't - where did you get that idea ?
calhoun wrote: | If I set them in CFLAGS, should I still set them in the USE= line? |
Yes, of course - if you want to use them.
These two uses are separate from eachother: the compiler settings determine the instruction set the compiler will use to generate the code, but the USE flags will indicate whether you want support for these functions in situations where there are alternatives available, i.e. you want to compile with MMX but it could also be compiled with plain integer instructions.
For more info you will need to read/learn a little about CPU's in general.
calhoun wrote: | Back to the original question, does sse work on both Pentium 4 and Athlon chips? Same question for MMX and 3DNow. |
Same answer: run the code. read the result. remember the result. |
|
Back to top |
|
|
|
|
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
|
|