llvm / llvm/llvm-project

[clang][crash] Clang crash for wasm target when processing a file using modules on macOS

Open
#164,113 0 comments 0 reactions 0 assignees View on GitHub
crash llvm:optimizations needs-reduction
Dominant language
LLVM
Stars
40.5k
Forks
18.7k
PR merge metrics
PR metrics pending

Description

I am using EMSDK. On versions 4.0.16 and 4.0.17, I see clang crashing on my MacBock on M4 Pro (macOS Tahoe 26.0.1).
I would like to draw your attention to the fact that the same code base with the same configuration compiles perfectly on Linux x86_64 (Fedora Workstation/Ubuntu).\
I have included the crash log in the [output.log](https://github.com/user-attachments/files/22986560/output.log) file. Below are the files that I was also asked to send in the event of a crash (I simply couldn't find any files with the mask `clang-22__.crash` in the location `/Users/aurum/Library/Logs/DiagnosticReports`).

[/var/folders/6g/b6tv394d3hx3zccjy5cs1mhc0000gn/T/app_mo_separator_unifier-09b611.cpp](https://github.com/user-attachments/files/22986558/app_mo_separator_unifier-09b611.cpp)
[/var/folders/6g/b6tv394d3hx3zccjy5cs1mhc0000gn/T/app_mo_separator_unifier-09b611.sh](https://github.com/user-attachments/files/22986559/app_mo_separator_unifier-09b611.sh)

Contributor guide

Open the contributing guide

Research direction

Start by reading output.log and inspecting the attached app_mo_separator_unifier-09b611.cpp and app_mo_separator_unifier-09b611.sh reproducer files. Run the reproducer in the reported macOS and wasm-target configuration, compare with the stated Linux behavior, and use the crash details to identify the failing compiler area. Done means the reproducer no longer crashes and a regression test covers the case.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp, macos, shell, wasm
Domain
compilers, operating-systems
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.