看板 Fortran 關於我們 聯絡資訊
最近要評估計算的時間 所以希望能夠列出程式計算時間 我找到etime和dtime兩種方式可以紀錄user和system的時間 但是在試用的情況下,發現他都沒有紀錄到時間 我是用intel fortran的compiler。 上網查到intel fortran compiler的使用手冊,照他的example去測試 依然沒有將時間紀錄下來 USE IFPORT REAL(4) I, TA(2) I = DTIME(TA) write(*,*) 'Program has been running for', I, 'seconds.' write(*,*) ' This includes', TA(1), 'seconds of user time and', & & TA(2), 'seconds of system time.' 這是他使用手冊上的範例 但是我顯示的都是0.0000000E+00 請問有沒有有經驗的版有可以分享一下,或是指出我有錯誤的地方。 謝謝 -- ※ 發信站: 批踢踢實業坊(ptt.cc) ◆ From: 140.109.112.98 ※ 編輯: s06yji3 來自: 140.109.112.98 (09/04 18:30)
BrianCashman:因為它的解析度只有到秒,且需乘1e3 單位才會正確 09/04 22:04