[llvm] [InstrProf] Inline ir-basic.proftext into test (PR #219329)
via llvm-commits
llvm-commits at lists.llvm.org
Thu Aug 27 16:53:29 PDT 2026
llvmorg-github-actions[bot] wrote:
<!--LLVM PR SUMMARY COMMENT-->
@llvm/pr-subscribers-pgo
Author: Ellis Hoag (ellishg)
<details>
<summary>Changes</summary>
`{fe,ir}-basic.proftext` are only used in `merge-incompatible.test`. Inline them into the test and remove the files from `Inputs/`.
---
Full diff: https://github.com/llvm/llvm-project/pull/219329.diff
3 Files Affected:
- (removed) llvm/test/tools/llvm-profdata/Inputs/fe-basic.proftext (-6)
- (removed) llvm/test/tools/llvm-profdata/Inputs/ir-basic.proftext (-6)
- (modified) llvm/test/tools/llvm-profdata/merge-incompatible.test (+21-5)
``````````diff
diff --git a/llvm/test/tools/llvm-profdata/Inputs/fe-basic.proftext b/llvm/test/tools/llvm-profdata/Inputs/fe-basic.proftext
deleted file mode 100644
index 34aa036401769..0000000000000
--- a/llvm/test/tools/llvm-profdata/Inputs/fe-basic.proftext
+++ /dev/null
@@ -1,6 +0,0 @@
-:fe
-foo
-29667547796
-2
-100
-90
diff --git a/llvm/test/tools/llvm-profdata/Inputs/ir-basic.proftext b/llvm/test/tools/llvm-profdata/Inputs/ir-basic.proftext
deleted file mode 100644
index b177a624a7b50..0000000000000
--- a/llvm/test/tools/llvm-profdata/Inputs/ir-basic.proftext
+++ /dev/null
@@ -1,6 +0,0 @@
-:ir
-foo2
-29667547796
-2
-100
-90
diff --git a/llvm/test/tools/llvm-profdata/merge-incompatible.test b/llvm/test/tools/llvm-profdata/merge-incompatible.test
index ea9eb0e95d834..b489b91200db7 100644
--- a/llvm/test/tools/llvm-profdata/merge-incompatible.test
+++ b/llvm/test/tools/llvm-profdata/merge-incompatible.test
@@ -1,21 +1,37 @@
RUN: export LSAN_OPTIONS=detect_leaks=0
RUN: rm -rf %t && split-file %s %t
-RUN: not llvm-profdata merge %p/Inputs/fe-basic.proftext %p/Inputs/ir-basic.proftext -o /dev/null 2>&1 | FileCheck %s
+RUN: not llvm-profdata merge %t/fe-basic.proftext %t/ir-basic.proftext -o /dev/null 2>&1 | FileCheck %s
CHECK: ir-basic.proftext: unsupported instrumentation profile format version: cannot merge IR generated profile with Clang generated profile
// We get a slightly different error message when using multiple threads because
// we do not know which files have incompatible kinds.
-RUN: not llvm-profdata merge %p/Inputs/fe-basic.proftext %p/Inputs/ir-basic.proftext --num-threads=2 -o /dev/null 2>&1 | FileCheck %s --check-prefix=THREADS
+RUN: not llvm-profdata merge %t/fe-basic.proftext %t/ir-basic.proftext --num-threads=2 -o /dev/null 2>&1 | FileCheck %s --check-prefix=THREADS
THREADS: unsupported instrumentation profile format version
// Single-byte-coverage profiles cannot be merged with count profiles, in either
// order, because the merged profile would be marked as coverage-only.
-RUN: not llvm-profdata merge %p/Inputs/ir-basic.proftext %t/coverage.proftext -o /dev/null 2>&1 | FileCheck %s --check-prefix=COVERAGE
-RUN: not llvm-profdata merge %t/coverage.proftext %p/Inputs/ir-basic.proftext -o /dev/null 2>&1 | FileCheck %s --check-prefix=COVERAGE
-RUN: not llvm-profdata merge %p/Inputs/ir-basic.proftext %t/coverage.proftext --num-threads=2 -o /dev/null 2>&1 | FileCheck %s --check-prefix=COVERAGE
+RUN: not llvm-profdata merge %t/ir-basic.proftext %t/coverage.proftext -o /dev/null 2>&1 | FileCheck %s --check-prefix=COVERAGE
+RUN: not llvm-profdata merge %t/coverage.proftext %t/ir-basic.proftext -o /dev/null 2>&1 | FileCheck %s --check-prefix=COVERAGE
+RUN: not llvm-profdata merge %t/ir-basic.proftext %t/coverage.proftext --num-threads=2 -o /dev/null 2>&1 | FileCheck %s --check-prefix=COVERAGE
COVERAGE: cannot merge single-byte and incrementing counter profiles
+//--- fe-basic.proftext
+:fe
+foo
+29667547796
+2
+100
+90
+
+//--- ir-basic.proftext
+:ir
+foo2
+29667547796
+2
+100
+90
+
//--- coverage.proftext
:ir
:single_byte_coverage
``````````
</details>
https://github.com/llvm/llvm-project/pull/219329
More information about the llvm-commits
mailing list