Skip to content

add llvm package#69

Closed
adeebshihadeh wants to merge 2 commits intomasterfrom
add-llvm-package
Closed

add llvm package#69
adeebshihadeh wants to merge 2 commits intomasterfrom
add-llvm-package

Conversation

@adeebshihadeh
Copy link
Copy Markdown
Contributor

Summary

  • Builds LLVM 20.1.4 from source with only X86 + AArch64 targets
  • Ships just libLLVM.so/libLLVM.dylib — what tinygrad needs for its CPU codegen backend via ctypes
  • Disables all unnecessary features (zlib, zstd, terminfo, tools, bindings) to minimize wheel size (~50-80MB)

Test plan

  • CI builds on linux-x86_64, linux-arm64, macos
  • Smoketest loads libLLVM and verifies X86 + AArch64 targets are present
  • Distro tests pass

🤖 Generated with Claude Code

adeebshihadeh and others added 2 commits April 6, 2026 09:55
Builds LLVM 20.1.4 from source with only X86 and AArch64 targets,
producing a minimal libLLVM.so/dylib for tinygrad's CPU code generation
backend. Disables all unnecessary features (zlib, zstd, terminfo, tools)
to keep the wheel small (~50-80MB vs ~1GB for full LLVM).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
The shared dylib target lives in tools/llvm-shlib/, so
LLVM_INCLUDE_TOOLS=OFF prevented it from being generated.
Remove that flag and build only the LLVM target directly.
Copy from build dir instead of install prefix.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@adeebshihadeh adeebshihadeh deleted the add-llvm-package branch April 25, 2026 18:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant