-
Notifications
You must be signed in to change notification settings - Fork 178
BOLT only failed with --hugify #297
Comments
Found on LLVM 14.0.1
|
@pingzhaozz can you add simple test to reproduce it? |
I upload my sample code to: https://github.com/pingzhaozz/perf_sample The BOLT process would be like:
|
@pingzhaozz this error is due to PIE binary, now you can use hugify for no-pie binaries. I will add the support for PIE soon, need some time to prepare the patch |
Thanks for the quick answer. |
Hello @pingzhaozz, https://reviews.llvm.org/D129107 this patch contains the support of PIE binaries, you can try to use it. |
@yavtuk Cool! I'll take a try and give you feedback next week. |
@yavtuk I checked the patch: https://reviews.llvm.org/D129107 and llvm-bolt works with This is without
This is with
|
@pingzhaozz sure, I'll check but give me some time to find my notes |
@pingzhaozz At first glance section addresses are fine, let’s check the support, starting from the OS level:
BTW you can uncommend the string and rebuild bolt to get more details (hugify.cpp): // Enables a very verbose logging to stderr useful when debugging https://github.com/llvm/llvm-project/blob/main/bolt/runtime/hugify.cpp#L16 |
@yavtuk hello, do you have any update about this patch? Has hugify PIE patch been merged? |
@PeterYang12 hello, you can find the patch to upstream here: https://reviews.llvm.org/D129107 |
I can find the patch on https://reviews.llvm.org/D129107. But I didn't see the patch in https://github.com/llvm/llvm-project/tree/main/bolt . Since our project will clone the project from github. |
The problem I met only happens when I use
--hugify
.I have a program which works well with BOLT.
I want to try the
--hugify
option. It passed BOLT process. But when I ran it, it will core dump. And problem seems at the entrypoint: (0x10a0 is the disassamble _start address
), but different from readelf header. core dump happens at the _start(0x10a0) with segfault. GDB can't capture since program not start yet.But when I ran it, it will core dump. And problem seems at the entrypoint: (
0x10a0 is the disassamble _start address
), but different from readelf. core dump happens at the _start(0x10a0) with segfault. GDB can't capture since program not start yet.I have hugepage in my system:
I can't find --hugify manual or guide to help debug this issue. If anyone knows this problem, pls help comment. Thanks a lot!
The text was updated successfully, but these errors were encountered: