Skip to content

Add disk caching for Water backend via object files#1093

Open
Hardcode84 wants to merge 1 commit intoiree-org:mainfrom
Hardcode84:water-backend-caching
Open

Add disk caching for Water backend via object files#1093
Hardcode84 wants to merge 1 commit intoiree-org:mainfrom
Hardcode84:water-backend-caching

Conversation

@Hardcode84
Copy link
Contributor

@Hardcode84 Hardcode84 commented Mar 10, 2026

After JIT compilation, dump the host object file (which embeds the GPU binary) to the cache directory. On cache hit, load the .o directly into the execution engine, skipping MLIR parsing, LLVM IR translation, and host code compilation entirely.

  • Add ExecutionEngine::loadFromObjectFile (C++ + Python binding).
  • Enable object cache by default so dump_to_object_file works.
  • Include use_water_backend in cache hash to avoid collisions.
  • Add testWaterBackendCache covering miss, store, hit, and correctness.

This was the last significant functionality gap comparing to the current wave_runtime.

@Hardcode84 Hardcode84 force-pushed the water-backend-caching branch from 3694ae0 to 9660f5d Compare March 10, 2026 11:36
@Hardcode84 Hardcode84 requested review from ftynse and harsh-nod March 10, 2026 11:40
After JIT compilation, dump the host object file (which embeds the GPU
binary) to the cache directory.  On cache hit, load the .o directly
into the execution engine, skipping MLIR parsing, LLVM IR translation,
and host code compilation entirely.

- Add ExecutionEngine::loadFromObjectFile (C++ + Python binding).
- Enable object cache by default so dump_to_object_file works.
- Include use_water_backend in cache hash to avoid collisions.
- Add testWaterBackendCache covering miss, store, hit, and correctness.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Ivan Butygin <ivan.butygin@gmail.com>
@Hardcode84 Hardcode84 force-pushed the water-backend-caching branch from 9660f5d to 1f97430 Compare March 20, 2026 18:59
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