Skip to content

Conversation

@w2yehia
Copy link
Contributor

@w2yehia w2yehia commented Oct 9, 2024

No description provided.

@llvmbot llvmbot added compiler-rt PGO Profile Guided Optimizations labels Oct 9, 2024
@llvmbot
Copy link
Member

llvmbot commented Oct 9, 2024

@llvm/pr-subscribers-pgo

Author: Wael Yehia (w2yehia)

Changes

Full diff: https://github.com/llvm/llvm-project/pull/111736.diff

1 Files Affected:

  • (modified) compiler-rt/test/profile/instrprof-tmpdir.c (+2-1)
diff --git a/compiler-rt/test/profile/instrprof-tmpdir.c b/compiler-rt/test/profile/instrprof-tmpdir.c
index 6f323e7e6a01a5..5cc9af4455e00b 100644
--- a/compiler-rt/test/profile/instrprof-tmpdir.c
+++ b/compiler-rt/test/profile/instrprof-tmpdir.c
@@ -12,7 +12,8 @@
 // RUN: llvm-profdata show ./raw2.profraw | FileCheck %s -check-prefix TMPDIR
 //
 // Check that we fall back to the default path if TMPDIR is missing.
-// RUN: env -u TMPDIR LLVM_PROFILE_FILE="%%t/raw3.profraw" %run %t/binary 2>&1 | FileCheck %s -check-prefix MISSING
+// RUN: unset TMPDIR
+// RUN: env LLVM_PROFILE_FILE="%%t/raw3.profraw" %run %t/binary 2>&1 | FileCheck %s -check-prefix MISSING
 // RUN: llvm-profdata show ./default.profraw | FileCheck %s -check-prefix TMPDIR
 
 // TMPDIR: Maximum function count: 1

//
// Check that we fall back to the default path if TMPDIR is missing.
// RUN: env -u TMPDIR LLVM_PROFILE_FILE="%%t/raw3.profraw" %run %t/binary 2>&1 | FileCheck %s -check-prefix MISSING
// RUN: unset TMPDIR
Copy link
Collaborator

@hubert-reinterpretcast hubert-reinterpretcast Oct 9, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see no sign that unset is implemented in the LIT built-in shell:
https://github.com/llvm/llvm-project/blob/e82fcda1475b6708b7d314fd7a54e551306d5739/llvm/utils/lit/lit/TestRunner.py

The built-in env does not support env -i.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You're right, unset does not seem to be implemented in the built-in shell,
and since windows doesn't have unset, I'm making this an aix-only change.
Thanks.

@w2yehia w2yehia force-pushed the main branch 2 times, most recently from 5a0ab0f to 46f2fac Compare October 10, 2024 02:20
Copy link
Collaborator

@hubert-reinterpretcast hubert-reinterpretcast left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM; thanks!

@w2yehia w2yehia closed this Oct 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

compiler-rt PGO Profile Guided Optimizations

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants