Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
Block Apple LLVM 21 from passing the JIT tool version check, as the JIT is
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

We should include at least some details about why it's incompatible IMO.

incompatible with it.
2 changes: 1 addition & 1 deletion Tools/jit/_llvm.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ async def _check_tool_version(
name: str, llvm_version: str, *, echo: bool = False
) -> bool:
output = await _run(name, ["--version"], echo=echo)
_llvm_version_pattern = re.compile(rf"version\s+{llvm_version}\.\d+\.\d+\S*\s+")
_llvm_version_pattern = re.compile(rf"(?<!Apple )LLVM version\s+{llvm_version}\.\d+\.\d+\S*\s+")
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

On my mac I had to add LLVM and clang to match the string. Can you please check?

Suggested change
_llvm_version_pattern = re.compile(rf"(?<!Apple )LLVM version\s+{llvm_version}\.\d+\.\d+\S*\s+")
_llvm_version_pattern = re.compile(rf"(?<!Apple )(LLVM|clang) version\s+{llvm_version}\.\d+\.\d+\S*\s+")

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

$ /Library/Developer/CommandLineTools/usr/bin/llvm-objdump --version
Apple LLVM version 21.0.0
  Optimized build.
...

$ /Library/Developer/CommandLineTools/usr/bin/clang --version
Apple clang version 21.0.0 (clang-2100.0.123.102)
Target: arm64-apple-darwin25.4.0
...

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Yep, I'm on MacOS as well and checked that we do need clang in the regex.

return bool(output and _llvm_version_pattern.search(output))


Expand Down
Loading