Phoronix 近日測試發現,在幾乎所有低中高端英特爾處理器上,最新測試版內核 Linux 4.20 的表現比最新穩定版 4.19 有顯著的下降,而 AMD 的處理器不受影響。出現性能下降的原因與英特爾處理器漏洞修補有關,4.20 的主要改變是對英特爾支持超線程的處理器默認啟用了 STIBP,防止間接分支預測器的跨線程控制。
針對此事,Linus Torvalds 感到驚訝,他在郵件列表中表示自己在討論列表中居然沒有看到任何關于會影響性能的字眼。當在某些負載下性能下降 50% 時,應該先反問是否值得,而不是不管不顧。
This was marked for stable, and honestly, nowhere in the discussion did I see any mention of just *how* bad the performance impact of this was.
When performance goes down by 50% on some loads, people need to start asking themselves whether it was worth it. It‘s apparently better to just disable SMT entirely, which is what security-conscious people do anyway.
So why do that STIBP slow-down by default when the people who *really* care already disabled SMT?
I think we should use the same logic as for L1TF: we default to something that doesn’t kill performance. Warn once about it, and let the crazy people say “I‘d rather take a 50% performance hit than worry about a theoretical issue”。
—— Linus
他補充道,“我不認為代碼需要還原,但是無條件啟用 STIBP 的‘行為’需要更正。因為這付出的代價顯然比你們之前告知的更大。 ”
來自 Intel 的 Linux 資深人士 Arjan van de Ven 也表示,“在文檔中,AMD 官方已有建議不要默認這樣做,我可以代表 Intel 說我們的立場也是如此。”
-
英特爾
+關注
關注
61文章
10183瀏覽量
174153 -
內核
+關注
關注
3文章
1412瀏覽量
41181 -
Linux
+關注
關注
87文章
11479瀏覽量
213040
原文標題:Linus 不滿內核 4.20 性能下降
文章出處:【微信號:LinuxHub,微信公眾號:Linux愛好者】歡迎添加關注!文章轉載請注明出處。
發布評論請先 登錄
如何配置和驗證Linux內核參數
Linux內核編譯失敗?移動硬盤和虛擬機的那些事兒

樹莓派4 性能大比拼:標準Linux與實時Linux 4.19內核的延遲測試

基于OpenSBI的linux nommu實現

騰訊云內核團隊修復Linux關鍵Bug
嵌入式學習-飛凌嵌入式ElfBoard ELF 1板卡-Linux內核移植之內核簡介
飛凌嵌入式ElfBoard ELF 1板卡-Linux內核移植之內核簡介
嵌入式工程師都在找的【Linux內核調試技術】建議收藏!
deepin社區亮相第19屆中國Linux內核開發者大會
linux內核中通用HID觸摸驅動

詳解linux內核的uevent機制
linux驅動程序如何加載進內核
Linux內核中的頁面分配機制

評論