aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/CodeGen/CodeGen.cpp
diff options
context:
space:
mode:
authorMats Petersson <mats.petersson@arm.com>2022-04-08 19:04:47 +0100
committerMats Petersson <mats.petersson@arm.com>2022-04-11 10:44:33 +0100
commit3d0e0e1027203fe5e89104ad81ee7bb53e525f95 (patch)
tree56483c9fc0acf18fc8036270d5d99f9a75f7a474 /llvm/lib/CodeGen/CodeGen.cpp
parent1e803d305ac5404c76169c89f4a442204c595dd8 (diff)
downloadllvm-3d0e0e1027203fe5e89104ad81ee7bb53e525f95.zip
llvm-3d0e0e1027203fe5e89104ad81ee7bb53e525f95.tar.gz
llvm-3d0e0e1027203fe5e89104ad81ee7bb53e525f95.tar.bz2
[flang][runtime] Prefer process time over thread time in CPU_TIME
Most Fortran compilers appear to return the process time for calls to CPU_TIME, where the flang implementation prior to this change was returning the time used by the current thread. This would cause incorrect time being reported when for example OpenMP is used to share work across multiple CPUs. This patch changes the order so the selection of "what time to return" so that if there is a process time to report, that is the reported value, and only if that is not available, the thread time is considerd instead. Reviewed By: jeanPerier Differential Revision: https://reviews.llvm.org/D123416
Diffstat (limited to 'llvm/lib/CodeGen/CodeGen.cpp')
0 files changed, 0 insertions, 0 deletions