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

Use check_include_file_cxx instead of check_include_file to find mm_malloc.h #4649

Merged
merged 2 commits into from
May 2, 2024

Conversation

fruffy
Copy link
Collaborator

@fruffy fruffy commented May 2, 2024

It looks like the other function never finds mm_malloc.h

@fruffy fruffy requested a review from jafingerhut May 2, 2024 17:37
@fruffy fruffy added the core Topics concerning the core segments of the compiler (frontend, midend, parser) label May 2, 2024
@fruffy fruffy added this pull request to the merge queue May 2, 2024
Merged via the queue into main with commit c170f45 May 2, 2024
16 of 17 checks passed
@fruffy fruffy deleted the fruffy/fix_include_file_search branch May 2, 2024 21:02
@jafingerhut
Copy link
Contributor

I know this is already merged, but as a confirmation, I built on an Ubuntu 20.04 aarch64 system with these changes. The build succeeded, and resulting binaries passed at least a few tests.

@ChrisDodd
Copy link
Contributor

I think @asl originally put in this include for some particular variation (gcc vs clang perhaps, from the comment). It might be good if he can recall under what condition the include was required originally.

@asl
Copy link
Contributor

asl commented May 3, 2024

@ChrisDodd The particular change was added in #4609 in order to fix noexcept / no-noexcept problem of posix_memalign declaration. It's really a mess that depends on combination of compilers and libc flavours. Unfortunately, we have to do something like this as we re-define posix_memalign override later.

Thinking about this more, maybe we'd resort to cmake-stage check whether posix_memalign is defined with noexcept specifier or not. And use this for redefine.

@fruffy
Copy link
Collaborator Author

fruffy commented May 3, 2024

I think @asl originally put in this include for some particular variation (gcc vs clang perhaps, from the comment). It might be good if he can recall under what condition the include was required originally.

Yes, I ran into this trying to compile a unity build with clang (#4595) and this was the fix we came up with.

Thinking about this more, maybe we'd resort to cmake-stage check whether posix_memalign is defined with noexcept specifier or not. And use this for redefine.

The CMake check sounds good, but I am not sure whether we can check the noexcept?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
core Topics concerning the core segments of the compiler (frontend, midend, parser)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants