[flang-commits] [PATCH] D104851: [flang] Add runtime interface for SYSTEM_CLOCK
Diana Picus via Phabricator via flang-commits
flang-commits at lists.llvm.org
Thu Jun 24 05:32:42 PDT 2021
rovka created this revision.
rovka added reviewers: klausler, jeanPerier.
rovka added a project: Flang.
Herald added a subscriber: jdoerfert.
rovka requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.
SYSTEM_CLOCK may take up to 3 optional parameters, all of which are
INTENT(OUT). The COUNT and COUNT_MAX parameters are integer scalars,
while COUNT_RATE may be a real or integer scalar. This patch declares
the latter as a real scalar, to allow for better precision where
possible. Lowering can handle the conversion to integer if necessary.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D104851
Files:
flang/runtime/time-intrinsic.h
Index: flang/runtime/time-intrinsic.h
===================================================================
--- flang/runtime/time-intrinsic.h
+++ flang/runtime/time-intrinsic.h
@@ -22,6 +22,9 @@
// real kind.
double RTNAME(CpuTime)();
+void RTNAME(SystemClock)(CppTypeFor<TypeCategory::Integer, 8> *Count,
+ CppTypeFor<TypeCategory::Real, 8> *CountRate,
+ CppTypeFor<TypeCategory::Integer, 8> *CountMax);
} // extern "C"
} // namespace Fortran::runtime
#endif // FORTRAN_RUNTIME_TIME_INTRINSIC_H_
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D104851.354223.patch
Type: text/x-patch
Size: 509 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/flang-commits/attachments/20210624/d54ce0e4/attachment.bin>
More information about the flang-commits
mailing list