[Openmp-commits] [PATCH] D112156: [OpenMP] Ensure broken assumptions print once, not thousands of times.
Shilei Tian via Phabricator via Openmp-commits
openmp-commits at lists.llvm.org
Wed Oct 20 10:41:35 PDT 2021
tianshilei1992 added inline comments.
================
Comment at: openmp/libomptarget/DeviceRTL/src/Debug.cpp:43
+ (file_high << 11) ^ (line);
+ if (hash != atomic::exchange(&AssertionFlag, hash, __ATOMIC_SEQ_CST))
+ PRINTF("ASSERTION failed: %s at %s, line %d\n", exp, file, line);
----------------
Seems better to wrap it with a function or macro like `PRINTF_ONCE`.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D112156/new/
https://reviews.llvm.org/D112156
More information about the Openmp-commits
mailing list