From 4364e2429cd4e3a640cbb84e565420fcfa830478 Mon Sep 17 00:00:00 2001 From: Matthew Voss Date: Mon, 27 Feb 2023 14:04:27 -0800 Subject: [PATCH] [NFC][PGO] Prefix duplicate profile MemOp entry diagnostic with 'warning:' Adding this prefix will indicate clearly that the compiler doesn't exit when it hits this diagnostic. Searches for other non-fatal diagnostics will also be able to find this diagnostic easily. --- llvm/lib/Transforms/Instrumentation/PGOMemOPSizeOpt.cpp | 2 +- llvm/test/Transforms/PGOProfile/consecutive-zeros.ll | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/llvm/lib/Transforms/Instrumentation/PGOMemOPSizeOpt.cpp b/llvm/lib/Transforms/Instrumentation/PGOMemOPSizeOpt.cpp index 35db848..2906fe1 100644 --- a/llvm/lib/Transforms/Instrumentation/PGOMemOPSizeOpt.cpp +++ b/llvm/lib/Transforms/Instrumentation/PGOMemOPSizeOpt.cpp @@ -317,7 +317,7 @@ bool MemOPSizeOpt::perform(MemOp MO) { } if (!SeenSizeId.insert(V).second) { - errs() << "Invalid Profile Data in Function " << Func.getName() + errs() << "warning: Invalid Profile Data in Function " << Func.getName() << ": Two identical values in MemOp value counts.\n"; return false; } diff --git a/llvm/test/Transforms/PGOProfile/consecutive-zeros.ll b/llvm/test/Transforms/PGOProfile/consecutive-zeros.ll index 6634838..a7337d0 100644 --- a/llvm/test/Transforms/PGOProfile/consecutive-zeros.ll +++ b/llvm/test/Transforms/PGOProfile/consecutive-zeros.ll @@ -5,7 +5,7 @@ target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16 target triple = "x86_64-unknown-linux-gnu" define void @foo(ptr %dst, ptr %src, ptr %a, i32 %n) { -; CHECK: Invalid Profile +; CHECK: warning: Invalid Profile entry: br label %for.cond -- 2.7.4