linux内核支持i7处理器,Gentoo Linux安装--Intel型号CPU的CFlags设置(包括intel core i7 & i5)...

Warning: GCC 4.2 and above support -march=native, which automatically detects the optimum settings to use based on your processor. -march=native also detects and applies additional settings beyond -march specific to your CPU, (eg. -msse4). Unless you have a specific reason not to (e.g. distcc cross-compiling), you should probably be using -march=native rather than anything listed below. To find out what -march=native actually picks on the local hardware see Safe Cflags#-march=native.

Contents[hide]

1Pentium

2Pentium w/ MMX

3Pentium Pro

4Pentium II

5Celeron (Mendocino), aka Celeron1

6Pentium III/ Mobile Celeron

7Celeron (Coppermine)

8Celeron (Willamette)

9Pentium M(Centrino)/Celeron M

10Mobile Pentium 4-M (Northwood)

11Pentium 4

12Pentium 4 (Prescott) / Celeron D

13Pentium D 8xx / 9xx

14Xeon w/o EM64T

15Xeon w/EM64T (also Pentium 4 P6xx or Celeron M 5xx)

16Intel Core Solo/Duo, Pentium Dual-Core T20xx/T21xx

17Core 2 Duo/Quad, Xeon 51xx/53xx/54xx/3360, Pentium Dual-Core T23xx+/Exxxx, Celeron Dual-Core

18Core i7 and Core i5, Xeon 55xx

19Atom 230, Atom 330, Atom N-Series

Pentiumvendor_id : GenuineIntel cpu family : 5 model : 2 model name : Pentium 75 - 200CHOST="i586-pc-linux-gnu" CFLAGS="-march=pentium -O2 -pipe -fomit-frame-pointer" CXXFLAGS="${CFLAGS}"

Pentium w/ MMXCHOST="i586-pc-linux-gnu" CFLAGS="-march=pentium-mmx -O2 -pipe -fomit-frame-pointer" CXXFLAGS="${CFLAGS}"

Pentium ProCHOST="i686-pc-linux-gnu" CFLAGS="-march=pentiumpro -O2 -pipe -fomit-frame-pointer" CXXFLAGS="${CFLAGS}"

Pentium IIvendor_id : GenuineIntel cpu family : 6 model : 3, 5CHOST="i686-pc-linux-gnu" CFLAGS="-march=pentium2 -O2 -pipe -fomit-frame-pointer" CXXFLAGS="${CFLAGS}"processor  : 0 vendor_id  : GenuineIntel cpu family  : 6 model  : 6 model name  : Mobile Pentium II stepping  : 10 cpu MHz  : 397.082 cache size  : 256 KB fdiv_bug  : no hlt_bug  : no f00f_bug  : no coma_bug  : no fpu  : yes fpu_exception  : yes cpuid level  : 2 wp  : yes flags  : fpu vme de pse tsc msr pae mce cx8 sep mtrr pge mca cmov pat pse36 mmx fxsr bogomips  : 794.75 clflush size  : 32

Celeron (Mendocino), aka Celeron1vendor_id : GenuineIntel cpu family : 6 model : 6 stepping : 0CHOST="i686-pc-linux-gnu" CFLAGS="-march=pentium2 -O2 -pipe -fomit-frame-pointer" CXXFLAGS="${CFLAGS}"processor  : 0 vendor_id  : GenuineIntel cpu family  : 6 model  : 6 model name  : Celeron (Mendocino) stepping  : 0 cpu MHz  : 334.108 cache size  : 128 KB fdiv_bug  : no hlt_bug  : no f00f_bug  : no coma_bug  : no fpu  : yes fpu_exception  : yes cpuid level  : 2 wp  : yes flags  : fpu vme de pse tsc msr pae mce cx8 sep mtrr pge mca cmov pat pse36 mmx fxsr up bogomips  : 686.94 clflush size  : 32

Pentium III/ Mobile Celeronvendor_id : GenuineIntel cpu family : 6 model : 7, 8, 11CHOST="i686-pc-linux-gnu" CFLAGS="-march=pentium3 -O2 -pipe -fomit-frame-pointer" CXXFLAGS="${CFLAGS}"processor  : 0 vendor_id  : GenuineIntel cpu family  : 6 model  : 8 model name  : Pentium III (Coppermine) stepping  : 6 cpu MHz  : 863.934 cache size  : 256 KB fdiv_bug  : no hlt_bug  : no f00f_bug  : no coma_bug  : no fpu  : yes fpu_exception  : yes cpuid level  : 2 wp  : yes flags  : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 mmx fxsr sse bogomips  : 1728.97 clflush size  : 32

Celeron (Coppermine)vendor_id  : GenuineIntel cpu family  : 6 model  : 8 stepping  : 10CHOST="i686-pc-linux-gnu" CFLAGS="-march=pentium3 -O2 -pipe -fomit-frame-pointer" CXXFLAGS="${CFLAGS}"

Celeron (Willamette)vendor_id  : GenuineIntel cpu family  : 15 model  : 1 model name  : Intel(R) Celeron(R) CPU XXXXGHz stepping  : 3CHOST="i686-pc-linux-gnu" CFLAGS="-march=pentium4 -O2 -pipe -fomit-frame-pointer" CXXFLAGS="${CFLAGS}"

Pentium M(Centrino)/Celeron Mvendor_id  : GenuineIntel cpu family  : 6 model  : 9 or 13 model name  : Intel(R) Pentium(R) M processor XXXXMHz

For gcc 3.3 or older:CHOST="i686-pc-linux-gnu" CFLAGS="-march=pentium3 -msse2 -O2 -pipe -fomit-frame-pointer" CXXFLAGS="${CFLAGS}"

For gcc 3.4 and later:CHOST="i686-pc-linux-gnu" CFLAGS="-march=pentium-m -O2 -pipe -fomit-frame-pointer" CXXFLAGS="${CFLAGS}"

The Celeron M is based on the Pentium M but it has half the L2 cache and does not support the SpeedStep technology.processor  : 0 vendor_id  : GenuineIntel cpu family  : 6 model  : 13 model name  : Intel(R) Pentium(R) M processor 2.00GHz stepping  : 8 cpu MHz  : 800.000 cache size  : 2048 KB fdiv_bug  : no hlt_bug  : no f00f_bug  : no coma_bug  : no fpu  : yes fpu_exception  : yes cpuid level  : 2 wp  : yes flags  : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat clflush dts acpi mmx fxsr sse sse2 ss tm pbe nx up bts est tm2 bogomips  : 1597.70 clflush size  : 64

Mobile Pentium 4-M (Northwood)vendor_id  : GenuineIntel cpu family  : 15 model  : 2 model name  : Mobile Intel(R) Pentium(R) 4 - M CPU X.XXGHzCHOST="i686-pc-linux-gnu" CFLAGS="-march=pentium4 -O2 -pipe -fomit-frame-pointer" CXXFLAGS="${CFLAGS}"

Pentium 4vendor_id  : GenuineIntel cpu family  : 15 model  : 0 or 1 or 2 model name  : Intel(R) Pentium(R) 4 CPU 1.70GHzCHOST="i686-pc-linux-gnu" CFLAGS="-march=pentium4 -O2 -pipe -fomit-frame-pointer" CXXFLAGS="${CFLAGS}"

Pentium 4 (Prescott) / Celeron Dvendor_id : GenuineIntel cpu family : 15 model : 3 or 4 model name  : Intel(R) Pentium(R) 4 CPU XXXGHz -or- Intel(R) Celeron(R) CPU XXXGHz

32-bit profile (x86):CHOST="i686-pc-linux-gnu" CFLAGS="-march=prescott -O2 -pipe -fomit-frame-pointer" CXXFLAGS="${CFLAGS}"

64-bit profile (amd64):CHOST="x86_64-pc-linux-gnu" CFLAGS="-march=nocona -O2 -pipe" CXXFLAGS="${CFLAGS}"

Note: You can verify the chip is a Prescott by looking for pni in the flags section of /proc/cpuinfo. This indicates support for SSE3.

In 2004, Intel started branding processors with the Prescott core as Intel Celeron D.

Pentium D 8xx / 9xxvendor_id : GenuineIntel cpu family : 15 model  : 4, 6 model name  : Intel(R) Pentium(R) D CPU x.xxGHz

32-bit profile (x86):CHOST="i686-pc-linux-gnu" CFLAGS="-march=prescott -O2 -pipe -fomit-frame-pointer" CXXFLAGS="${CFLAGS}"

64-bit profile (amd64):CHOST="x86_64-pc-linux-gnu" CFLAGS="-march=nocona -O2 -pipe" CXXFLAGS="${CFLAGS}"

Xeon w/o EM64Tvendor_id  : GenuineIntel cpu family  : 15 model  : 2 model name  : Intel(R) Xeon(TM) CPU 2.80GHzCHOST="i686-pc-linux-gnu" CFLAGS="-march=pentium4 -O2 -pipe -fomit-frame-pointer" CXXFLAGS="${CFLAGS}"

Xeon w/EM64T (also Pentium 4 P6xx or Celeron M 5xx)vendor_id  : GenuineIntel cpu family  : 15 model  : 4,6 model name  : Intel(R) Xeon(R) CPU XXXXMHz model name  : Intel(R) Celeron(R) M CPU 5xx @ XXXGHz

32-bit profile (x86):CHOST="i686-pc-linux-gnu" CFLAGS="-march=prescott -O2 -pipe -fomit-frame-pointer" CXXFLAGS="${CFLAGS}"

64-bit profile (amd64):CHOST="x86_64-pc-linux-gnu" CFLAGS="-march=nocona -O2 -pipe" CXXFLAGS="${CFLAGS}"

Intel Core Solo/Duo, Pentium Dual-Core T20xx/T21xxvendor_id  : GenuineIntel cpu family  : 6 model  : 14, 22 model name  : Genuine Intel(R) CPU TXXXX @ X.XXGHz model name  : Intel(R) Celeron(R) CPU 220 @ 1.20GHz model name  : Intel(R) Celeron(R) CPU 4X0 @ X.XXGHz model name  : Intel(R) Celeron(R) M CPU 4X0 @ X.XXGHzCHOST="i686-pc-linux-gnu" CFLAGS="-march=prescott -O2 -pipe -fomit-frame-pointer" CXXFLAGS="${CFLAGS}"

Notes:

It has been confirmed by hongjiu.lu@intel.com that prescott is the correct microarchitecture to use with this CPU. http://article.gmane.org/gmane.comp.gcc.devel/83870

The newer (eg. 420) Celeron-M processors are Core Solo based, not Pentium-M based. If your processor's family and model are 6 and 14, then you should use the -march=prescott option.

Both the Celeron 4x0 and 220 run fine with Processor family (Pentium M) selected in the kernel.

Core 2 Duo/Quad, Xeon 51xx/53xx/54xx/3360, Pentium Dual-Core T23xx+/Exxxx, Celeron Dual-Corevendor_id  : GenuineIntel cpu family  : 6 model  : 15, 23 model name  : Intel(R) Core(TM)2 CPU XXXX @ XXXGHz model name  : Intel(R) Celeron(R) CPU E3400 @ 2.60GHz model name  : Intel(R) Pentium(R) Dual CPU T23xx @ XXXGHz model name  : Intel(R) Xeon(R) CPU X3360

32 bit profile (x86) for < GCC 4.3:CHOST="i686-pc-linux-gnu" CFLAGS="-march=prescott -O2 -pipe -fomit-frame-pointer" CXXFLAGS="${CFLAGS}"

32 bit profile (x86) for >= GCC 4.3:CHOST="i686-pc-linux-gnu" CFLAGS="-march=core2 -O2 -pipe -fomit-frame-pointer" CXXFLAGS="${CFLAGS}"

64 bit profile (amd64) for < GCC 4.3CHOST="x86_64-pc-linux-gnu" CFLAGS="-march=nocona -O2 -pipe" CXXFLAGS="${CFLAGS}"

64 bit profile (amd64) for >= GCC 4.3CHOST="x86_64-pc-linux-gnu" CFLAGS="-march=core2 -O2 -pipe" CXXFLAGS="${CFLAGS}"

Core i7 and Core i5, Xeon 55xxvendor_id  : GenuineIntel cpu family  : 6 model  : 26 model name  : Intel(R) Core(TM) i7 CPU 920 @ 2.67GHzvendor_id  : GenuineIntel cpu family  : 6 model  : 37 model name  : Intel(R) Core(TM) i5 CPU 650 @ 3.20GHz / 660 @ 3.33 GHzvendor_id  : GenuineIntel cpu family  : 6 model  : 42 model name  : Intel(R) Core(TM) i5-2430M CPU @ 2.40GHz stepping  : 7 cpu MHz  : 2394.550 cache size  : 3072 KBvendor_id  : GenuineIntel cpu family  : 6 model  : 26 model name  : Intel(R) Xeon(R) CPU X5570 @ 2.93GHz

32 bit profile (x86)CHOST="i686-pc-linux-gnu" CFLAGS="-march=prescott -O2 -fomit-frame-pointer -pipe" CXXFLAGS="${CFLAGS}"

64 bit profile (amd64) for < GCC 4.3CHOST="x86_64-pc-linux-gnu" CFLAGS="-march=nocona -O2 -pipe" CXXFLAGS="${CFLAGS}"

64 bit profile (amd64) for GCC 4.3CHOST="x86_64-pc-linux-gnu" CFLAGS="-march=core2 -mtune=generic -O2 -pipe" CXXFLAGS="${CFLAGS}"

64 bit profile (amd64) for GCC 4.6CHOST="x86_64-pc-linux-gnu" CFLAGS="-march=corei7 -O2 -pipe" CXXFLAGS="${CFLAGS}"

Warning: Note that Sandy Bridge CPUs use a march and mtune of corei7-avx not corei7. See the man page for gcc.

Atom 230, Atom 330, Atom N-Seriesvendor_id  : GenuineIntel cpu family  : 6 model  : 28 model name  : Intel(R) Atom(TM) CPU 230 @ 1.60GHz stepping  : 2 cpu MHz  : 1596.175 cache size  : 512 KBvendor_id  : GenuineIntel cpu family  : 6 model  : 38 model name  : Genuine Intel(R) CPU @ 1.60GHz stepping  : 1 cpu MHz  : 1600.033 cache size  : 512 KB

32 bit profile (x86):CHOST="i686-pc-linux-gnu" CFLAGS="-march=atom -O2 -fomit-frame-pointer -pipe" CXXFLAGS="${CFLAGS}"

32 bit gcc 4.5.3 (x86)CHOST="i686-pc-linux-gnu" CFLAGS="-march=native -O2 -fomit-frame-pointer -pipe -mfpmath=sse" CXXFLAGS="${CFLAGS}"

These more aggressive flags above improve single threaded performance benchmarks (ie nbench) on the atom 330 with GCC 4.5.3 considerably, most notably there is a floating point performance increase of ~20%.

64 bit profile (amd64) for < GCC 4.3:CHOST="x86_64-pc-linux-gnu" CFLAGS="-march=nocona -O2 -pipe" CXXFLAGS="${CFLAGS}"

64 bit profile (amd64) for GCC 4.3 and 4.4:CHOST="x86_64-pc-linux-gnu" CFLAGS="-march=core2 -O2 -mtune=generic -pipe" CXXFLAGS="${CFLAGS}"

64 bit profile (amd64) for >= GCC 4.5:CHOST="x86_64-pc-linux-gnu" CFLAGS="-march=atom -O2 -pipe" CXXFLAGS="${CFLAGS}"

0b1331709591d260c1c78e86d0c51c18.png

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值