On Freitag 29 Mai 2009, Graham Murray wrote: > Stroller <strol...@stellar.eclipse.co.uk> writes: > > But, surely "-march=" also instructs gcc to support the additional > > instructions. Suggest you re-read Daniel's post that I was replying > > to. > > > > What's the difference between supporting the "certain set of > > instructions" with "-march=" and doing so with USEs? > > > > Or doesn't "-march=" support additional "certain sets of > > instructions". What does it do, then? > > I am not sure, > > $ gcc -Q --help=target -march=core2 > The following options are target specific: > -m128bit-long-double [disabled] > -m32 [enabled] > -m3dnow [disabled] > -m3dnowa [disabled] > -m64 [disabled] > -m80387 [enabled] > -m96bit-long-double [enabled] > -mabm [disabled] > -maccumulate-outgoing-args [disabled] > -maes [disabled] > -malign-double [disabled] > -malign-functions= > -malign-jumps= > -malign-loops= > -malign-stringops [enabled] > -march= core2 > -masm= > -mavx [disabled] > -mbranch-cost= > -mcld [disabled] > -mcmodel= > -mcx16 [disabled] > -mfancy-math-387 [enabled] > -mfma [disabled] > -mforce-drap [disabled] > -mfp-ret-in-387 [enabled] > -mfpmath= > -mfused-madd [enabled] > -mglibc [enabled] > -mhard-float [enabled] > -mieee-fp [enabled] > -mincoming-stack-boundary= > -minline-all-stringops [disabled] > -minline-stringops-dynamically [disabled] > -mintel-syntax [disabled] > -mlarge-data-threshold= > -mmmx [disabled] > -mms-bitfields [disabled] > -mno-align-stringops [disabled] > -mno-fancy-math-387 [disabled] > -mno-fused-madd [disabled] > -mno-push-args [disabled] > -mno-red-zone [disabled] > -mno-sse4 [enabled] > -momit-leaf-frame-pointer [disabled] > -mpc > -mpclmul [disabled] > -mpopcnt [disabled] > -mpreferred-stack-boundary= > -mpush-args [enabled] > -mrecip [disabled] > -mred-zone [enabled] > -mregparm= > -mrtd [disabled] > -msahf [disabled] > -msoft-float [disabled] > -msse [disabled] > -msse2 [disabled] > -msse2avx [disabled] > -msse3 [disabled] > -msse4 [disabled] > -msse4.1 [disabled] > -msse4.2 [disabled] > -msse4a [disabled] > -msse5 [disabled] > -msseregparm [disabled] > -mssse3 [disabled] > -mstack-arg-probe [disabled] > -mstackrealign [enabled] > -mstringop-strategy= > -mtls-dialect= > -mtls-direct-seg-refs [enabled] > -mtune= > -muclibc [disabled] > -mveclibabi=
get this: dev.gentoo.org/~dirtyepic/bin/analyze-x86 and let it run, for example: /analyze-x86 /bin/gzip Checking vendor_id string... AuthenticAMD 64 Disassembling /bin/gzip, please wait... i486: 0 i586: 0 ppro: 36 mmx: 46 3dnow: 0 ext3dnow: 0 sse: 0 sse2: 4 sse3: 0 /bin/gzip will run on AMD Athlon64 or higher processor. or this: /analyze-x86 /bin/bash Checking vendor_id string... AuthenticAMD 64 Disassembling /bin/bash, please wait... i486: 0 i586: 0 ppro: 369 mmx: 876 3dnow: 0 ext3dnow: 0 sse: 120 sse2: 0 sse3: 0 /bin/bash will run on Pentium III (pentium3) or higher processor. and march=k8-sse3 -msse3 -O2 -pipe were my flags. Seems that a lot of stuff got turned on ;) mplayer is even more 'interessting': ./analyze-x86 /usr/bin/mplayer Checking vendor_id string... AuthenticAMD 64 Disassembling /usr/bin/mplayer, please wait... i486: 3948 i586: 14 ppro: 7573 mmx: 164986 3dnow: 5331 ext3dnow: 768 sse: 31407 sse2: 27712 sse3: 51 This binary was found to contain the cpuid instruction. It may be able to conditionally execute instructions if they are supported on the host (i586+). /usr/bin/mplayer will run on AMD Athlon64 w/ SSE3 or higher processor.