Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[PGO] Remove calls to __llvm_orderfile_dump() in instrprof-api.c test #79150

Merged
merged 1 commit into from
Jan 23, 2024

Conversation

qiongsiwu
Copy link
Contributor

#78285 added a test which calls __llvm_orderfile_dump(), a functionality that is not supported on many platforms. This PR removes the call to __llvm_orderfile_dump() to avoid it failing on unsupported platforms, and turn on the test for Windows, so we test the rest of the API that are supported.

@llvmbot llvmbot added compiler-rt PGO Profile Guided Optimizations labels Jan 23, 2024
@llvmbot
Copy link
Collaborator

llvmbot commented Jan 23, 2024

@llvm/pr-subscribers-pgo

Author: Qiongsi Wu (qiongsiwu)

Changes

#78285 added a test which calls __llvm_orderfile_dump(), a functionality that is not supported on many platforms. This PR removes the call to __llvm_orderfile_dump() to avoid it failing on unsupported platforms, and turn on the test for Windows, so we test the rest of the API that are supported.


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

1 Files Affected:

  • (modified) compiler-rt/test/profile/instrprof-api.c (-7)
diff --git a/compiler-rt/test/profile/instrprof-api.c b/compiler-rt/test/profile/instrprof-api.c
index fedec2d1afc48de..07c5b2f45390793 100644
--- a/compiler-rt/test/profile/instrprof-api.c
+++ b/compiler-rt/test/profile/instrprof-api.c
@@ -1,6 +1,3 @@
-// UNSUPPORTED: target={{.*windows.*}}
-// __llvm_orderfile_dump() is not supported on Windows.
-
 // Testing profile generate.
 // RUN: %clang_profgen %s -S -emit-llvm -o - | FileCheck %s --check-prefix=PROFGEN
 // RUN: %clang_pgogen %s -S -emit-llvm -o - | FileCheck %s --check-prefix=PROFGEN
@@ -38,12 +35,8 @@ int main() {
     return 2;
   // PROFGEN: %{{.*}} = call {{(signext )*}}i32 @__llvm_profile_dump()
   // PROFUSE-NOT: %{{.*}} = call {{(signext )*}}i32 @__llvm_profile_dump()
-  __llvm_orderfile_dump();
-  // PROFGEN: %{{.*}} = call {{(signext )*}}i32 @__llvm_orderfile_dump()
-  // PROFUSE-NOT: %{{.*}} = call {{(signext )*}}i32 @__llvm_orderfile_dump()
   return z + bar() - 11;
 }
 
 // PROFUSE-NOT: declare void @__llvm_profile_set_filename(ptr noundef)
 // PROFUSE-NOT: declare signext i32 @__llvm_profile_dump()
-// PROFUSE-NOT: declare signext i32 @__llvm_orderfile_dump()

@qiongsiwu
Copy link
Contributor Author

qiongsiwu commented Jan 23, 2024

Landing this PR. I will keep an eye on the Windows (https://lab.llvm.org/buildbot/#/builders/127) / Solaris(https://lab.llvm.org/buildbot/#/builders/72) buildbots that have reported problems before.

@qiongsiwu qiongsiwu merged commit 291ac25 into llvm:main Jan 23, 2024
6 checks passed
@qiongsiwu
Copy link
Contributor Author

Windows build succeeded https://lab.llvm.org/buildbot/#/builders/127/builds/61284.

@qiongsiwu
Copy link
Contributor Author

Solaris build succeeded https://lab.llvm.org/buildbot/#/builders/72/builds/2033.

@rorth
Copy link
Collaborator

rorth commented Jan 24, 2024

Solaris build succeeded https://lab.llvm.org/buildbot/#/builders/72/builds/2033.

Right: that's the sparcv9 one. Solaris/amd64 is fine, too. Thanks.

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.

None yet

4 participants