Re: [問題] 在特定條件下,deque與vector的效能比較

看板C_and_CPP (C/C++)作者 (Neisseria)時間10年前 (2016/03/02 20:57), 10年前編輯推噓1(101)
留言2則, 1人參與, 最新討論串2/3 (看更多)
回饋一下原 po,試著用一點點最佳化 我記憶體不夠,iteration 調成 1000 萬次 系統:Debian GNU/Linux Jessie 8.3 g++ 版本:4.9.2 $ g++ -o file file.cpp -std=c++14 $ ./file 16313 17946 16363 $ g++ -o file file.cpp -std=c++14 -O3 $ ./file 2310 2330 2154 參考看看 -- ※ 發信站: 批踢踢實業坊(ptt.cc), 來自: 175.182.115.150 ※ 文章網址: https://www.ptt.cc/bbs/C_and_CPP/M.1456923474.A.F80.html

03/02 21:06, , 1F
十分感謝你,但是能試試看用O2或O3嗎?
03/02 21:06, 1F
※ 編輯: Neisseria (175.182.115.150), 03/02/2016 21:40:19

03/02 21:43, , 2F
感謝你的數據
03/02 21:43, 2F
文章代碼(AID): #1MrkDI-0 (C_and_CPP)
文章代碼(AID): #1MrkDI-0 (C_and_CPP)