Skip to content

[MemProf] Add missing header to list of installed headers. #79413

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

Merged
merged 1 commit into from
Jan 26, 2024

Conversation

Enna1
Copy link
Contributor

@Enna1 Enna1 commented Jan 25, 2024

There were buildbot failures when running memprof tests:
Failed Tests (12):
MemProfiler-x86_64-linux :: TestCases/interface_test.cpp
MemProfiler-x86_64-linux :: TestCases/log_path_test.cpp
MemProfiler-x86_64-linux :: TestCases/memprof_merge_mib.cpp
MemProfiler-x86_64-linux :: TestCases/memprof_profile_dump.cpp
MemProfiler-x86_64-linux :: TestCases/profile_reset.cpp
MemProfiler-x86_64-linux :: TestCases/unaligned_loads_and_stores.cpp
MemProfiler-x86_64-linux-dynamic :: TestCases/interface_test.cpp
MemProfiler-x86_64-linux-dynamic :: TestCases/log_path_test.cpp
MemProfiler-x86_64-linux-dynamic :: TestCases/memprof_merge_mib.cpp
MemProfiler-x86_64-linux-dynamic :: TestCases/memprof_profile_dump.cpp
MemProfiler-x86_64-linux-dynamic :: TestCases/profile_reset.cpp
MemProfiler-x86_64-linux-dynamic :: TestCases/unaligned_loads_and_stores.cpp

See

I suspect the failure is because when build with
-DLLVM_ENABLE_RUNTIMES=compiler-rt -DCOMPILER_RT_BUILD_SANITIZERS=OFF,
the headers sanitizer/allocator_interface.h and sanitizer/common_interface_defs.h
are not copied to the build tree, and not installed.
But in the failed memprof tests,
sanitizer/allocator_interface.h or sanitizer/memprof_interface.h is included.

This patch adds sanitizer/allocator_interface.h and sanitizer/memprof_interface.h to memprof headers if COMPILER_RT_BUILD_SANITIZERS is false.

There were buildbot failures when running memprof tests:
********************
Failed Tests (12):
  MemProfiler-x86_64-linux :: TestCases/interface_test.cpp
  MemProfiler-x86_64-linux :: TestCases/log_path_test.cpp
  MemProfiler-x86_64-linux :: TestCases/memprof_merge_mib.cpp
  MemProfiler-x86_64-linux :: TestCases/memprof_profile_dump.cpp
  MemProfiler-x86_64-linux :: TestCases/profile_reset.cpp
  MemProfiler-x86_64-linux :: TestCases/unaligned_loads_and_stores.cpp
  MemProfiler-x86_64-linux-dynamic :: TestCases/interface_test.cpp
  MemProfiler-x86_64-linux-dynamic :: TestCases/log_path_test.cpp
  MemProfiler-x86_64-linux-dynamic :: TestCases/memprof_merge_mib.cpp
  MemProfiler-x86_64-linux-dynamic :: TestCases/memprof_profile_dump.cpp
  MemProfiler-x86_64-linux-dynamic :: TestCases/profile_reset.cpp
  MemProfiler-x86_64-linux-dynamic :: TestCases/unaligned_loads_and_stores.cpp

See
- https://lab.llvm.org/buildbot/#/builders/258/builds/8852
- https://lab.llvm.org/buildbot/#/builders/258/builds/12876

I suspect the failure is because when build with
-DLLVM_ENABLE_RUNTIMES=compiler-rt -DCOMPILER_RT_BUILD_SANITIZERS=OFF,
the headers sanitizer/allocator_interface.h and
sanitizer/common_interface_defs.h are not be copied to the build tree,
and not installed.
But in the failed memprof tests,
sanitizer/allocator_interface.h or sanitizer/memprof_interface.h is included.

This patch adds sanitizer/allocator_interface.h and sanitizer/memprof_interface.h
to memprof headers if COMPILER_RT_BUILD_SANITIZERS is false.
@Enna1
Copy link
Contributor Author

Enna1 commented Jan 25, 2024

I found https://reviews.llvm.org/D90190, it seems that why we decouple COMPILER_RT_BUILD_MEMPROF from COMPILER_RT_BUILD_SANITIZERS.

@Enna1
Copy link
Contributor Author

Enna1 commented Jan 25, 2024

cc @AaronBallman reported this buildbot failure in #69625

Copy link
Contributor

@teresajohnson teresajohnson left a comment

Choose a reason for hiding this comment

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

Thanks for fixing this! Was not aware of the failures.

@Enna1 Enna1 merged commit 0a3b5ec into main Jan 26, 2024
@Enna1 Enna1 deleted the users/Enna1/memprof-fix-buildbot branch January 26, 2024 01:18
Enna1 added a commit that referenced this pull request Jan 26, 2024
Enna1 added a commit that referenced this pull request Jan 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants