[compiler-rt] [compiler-rt] Write ASAN/TSAN reports to a global for crash reporting (PR #200526)
Vitaly Buka via llvm-commits
llvm-commits at lists.llvm.org
Sun May 31 22:09:42 PDT 2026
================
@@ -139,71 +139,100 @@ static const char *ExternalMopDesc(bool first, bool write) {
: (write ? "Previous modifying" : "Previous read-only");
}
-static void PrintMop(const ReportMop *mop, bool first) {
+# define Output(...) \
+ if (out) { \
+ int written = internal_snprintf(out, outlen, __VA_ARGS__); \
+ out += written; \
+ outlen -= written; \
+ } else { \
+ Printf(__VA_ARGS__); \
+ }
+
+static void PrintMop(const ReportMop* mop, bool first, char* out = nullptr,
----------------
vitalybuka wrote:
please use InternalScopedString& out
https://github.com/llvm/llvm-project/pull/200526
More information about the llvm-commits
mailing list