Skip to content

docs: Add troubleshooting guide for fat LTO miscompilation#1286

Merged
sagar-a16z merged 1 commit intoa16z:mainfrom
LayerZero-Research:fix/lookup-bits-uninterleave
Feb 27, 2026
Merged

docs: Add troubleshooting guide for fat LTO miscompilation#1286
sagar-a16z merged 1 commit intoa16z:mainfrom
LayerZero-Research:fix/lookup-bits-uninterleave

Conversation

@zouguangxian
Copy link
Copy Markdown
Contributor

@zouguangxian zouguangxian commented Feb 23, 2026

Description

Adds docs/troubleshooting.md documenting a known fat LTO miscompilation that causes zkvm::lookup_table::equal::test::prefix_suffix to fail under --release. This class of issue is tracked upstream in rust-lang/rust#116941.

What's covered

  • Quick workaround summary — prefer lto = "thin" (the default), or use RUSTFLAGS="-C no-prepopulate-passes" if fat LTO is required.
  • Detailed configuration matrix with reproduction commands and exact error output for:
    1. lto = "fat" — triggers the miscompile (prefix_suffix assertion failure).
    2. lto = "thin" — recommended, all tests pass.
    3. lto = "fat" + -C no-prepopulate-passes — avoids the miscompile but may increase trace lengths, causing advice_e2e_dory to fail unless max_trace_length is bumped (e.g. 1 << 161 << 17).

@zouguangxian zouguangxian force-pushed the fix/lookup-bits-uninterleave branch 2 times, most recently from bc1f9f7 to 820d00d Compare February 25, 2026 13:42
@zouguangxian zouguangxian changed the title fix: Correct length calculation in LookupBits::uninterleave docs: Add troubleshooting guide for fat LTO miscompilation Feb 25, 2026
@zouguangxian zouguangxian force-pushed the fix/lookup-bits-uninterleave branch from 820d00d to 70b27d6 Compare February 25, 2026 13:56
@sagar-a16z
Copy link
Copy Markdown
Contributor

maybe we should create an outstanding issue that tracks the upstream rust issue. So we can keep track of when this sensitivity goes away.

@moodlezoup
Copy link
Copy Markdown
Collaborator

let's move this into the existing troubleshooting page: https://github.com/a16z/jolt/blob/main/book/src/usage/troubleshooting.md

@zouguangxian zouguangxian force-pushed the fix/lookup-bits-uninterleave branch from 70b27d6 to a86726d Compare February 26, 2026 01:19
@zouguangxian
Copy link
Copy Markdown
Contributor Author

let's move this into the existing troubleshooting page: https://github.com/a16z/jolt/blob/main/book/src/usage/troubleshooting.md

migrated

@sagar-a16z sagar-a16z merged commit 292be44 into a16z:main Feb 27, 2026
14 checks passed
@zouguangxian zouguangxian deleted the fix/lookup-bits-uninterleave branch February 28, 2026 03:00
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.

3 participants