說真的,我很怕我根本就不知道我到底在問什麼...囧
我試著用apt-build編譯FireFox,並根據Core2Duo作最佳化。
因為我...不會寫程式,在這之前也對gcc之類的東西毫無概念。但還是很勉強的查了一些
資料出來:
march和mtune的区别
http://bit.ly/l9lSsK
Safe Cflags @ Gentoo Wiki
http://bit.ly/lRsTps
使用 apt-get build 編譯你的 firefox @ Ubuntu正體中文站
http://bit.ly/m6Wh9s
目前我的/etc/apt/apt-build.conf長這副德性:
build-dir = /var/cache/apt-build/build
repository-dir = /var/cache/apt-build/repository
Olevel = -O2
mtune = -mtune=core2
options = " "
make_options = "-j2"
我希望能盡量達到最好的效果,但...我根本不知該從何下手。
以下問題可能很可笑或根本牛頭不對馬嘴:
1.如果我只想盡量榨乾CPU,是不是就該用march?
2.我又在http://bit.ly/jld8sk中看到這段:
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.
也就是說,好像根本不用管-msse -msse2 -msse3之類的參數?但有個問題...那我那一行
mtune = -mtune=core2到底該怎麼改?直接改成mtune = -march=native這樣,還是在
options裡加上-march=native而mtune = -mtune=core2繼續保持原樣?可是這樣感覺很矛盾
。
3.我找到有一個是說/etc/makepkg.conf的檔案可以自訂成像這樣
CHOST="i686-pc-linux-gnu"
CFLAGS="-march=core2 -O3 -msse -msse2 -msse3 -pipe -fomit-frame-pointer"
,不過這好像是Arch Linux獨有的的設定檔?
4.所以...最後一個問題:我到底該怎麼做?囧
我已經盡我所能的查出可能有用的說明,也自己動手做過,只是還是不懂。希望這樣不會
感覺像是來乞討答案的...謝謝。
--
--
我試著用apt-build編譯FireFox,並根據Core2Duo作最佳化。
因為我...不會寫程式,在這之前也對gcc之類的東西毫無概念。但還是很勉強的查了一些
資料出來:
march和mtune的区别
http://bit.ly/l9lSsK
Safe Cflags @ Gentoo Wiki
http://bit.ly/lRsTps
使用 apt-get build 編譯你的 firefox @ Ubuntu正體中文站
http://bit.ly/m6Wh9s
目前我的/etc/apt/apt-build.conf長這副德性:
build-dir = /var/cache/apt-build/build
repository-dir = /var/cache/apt-build/repository
Olevel = -O2
mtune = -mtune=core2
options = " "
make_options = "-j2"
我希望能盡量達到最好的效果,但...我根本不知該從何下手。
以下問題可能很可笑或根本牛頭不對馬嘴:
1.如果我只想盡量榨乾CPU,是不是就該用march?
2.我又在http://bit.ly/jld8sk中看到這段:
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.
也就是說,好像根本不用管-msse -msse2 -msse3之類的參數?但有個問題...那我那一行
mtune = -mtune=core2到底該怎麼改?直接改成mtune = -march=native這樣,還是在
options裡加上-march=native而mtune = -mtune=core2繼續保持原樣?可是這樣感覺很矛盾
。
3.我找到有一個是說/etc/makepkg.conf的檔案可以自訂成像這樣
CHOST="i686-pc-linux-gnu"
CFLAGS="-march=core2 -O3 -msse -msse2 -msse3 -pipe -fomit-frame-pointer"
,不過這好像是Arch Linux獨有的的設定檔?
4.所以...最後一個問題:我到底該怎麼做?囧
我已經盡我所能的查出可能有用的說明,也自己動手做過,只是還是不懂。希望這樣不會
感覺像是來乞討答案的...謝謝。
--
推 defenser:我承認她們全都是我的後宮(  ̄ c ̄)y▇▇▇▇▇▇▇~※ 04/08 21:32
推 BSpowerx: ◤ 大砲 █● 04/08 21:34
推 cy0816: ▇▇▇▇▇▇▇▇▇▇04/08 21:35
→ Augustus5: ●04/08 21:35
→ LoveMakeLove: *******************04/08 21:35
推 Raptorjet:樓上那啥鬼04/08 21:38
--
All Comments