Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[WebAssembly] Add RefTypeMem2Local pass #81965

Merged
merged 6 commits into from
Feb 27, 2024
Merged

[WebAssembly] Add RefTypeMem2Local pass #81965

merged 6 commits into from
Feb 27, 2024

Commits on Feb 16, 2024

  1. [WebAssembly] Add RefTypeMem2Local pass

    This adds `WebAssemblyRefTypeMem2Local` pass, which changes the address
    spaces of reference type `alloca`s to `addrspace(1)`. This in turn
    changes the address spaces of all `load` and `store` instructions that
    use the `alloca`s.
    
    `addrspace(1)` is `WASM_ADDRESS_SPACE_VAR`, and loads and stores to this
    address space become `local.get`s and `local.set`s, thanks to the Wasm
    local IR support added in
    llvm@82f92e3.
    
    In a follow-up PR, I am planning to replace the usage of mem2reg pass
    with this to solve the reference type `alloca` problems described in
     llvm#81575.
    aheejin committed Feb 16, 2024
    Configuration menu
    Copy the full SHA
    58beb2a View commit details
    Browse the repository at this point in the history
  2. Update llvm/lib/Target/WebAssembly/WebAssemblyRefTypeMem2Local.cpp

    Co-authored-by: xortoast <xortoast@proton.me>
    aheejin and xortoast authored Feb 16, 2024
    Configuration menu
    Copy the full SHA
    d5493d9 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    a2b29e3 View commit details
    Browse the repository at this point in the history
  4. change order

    aheejin committed Feb 16, 2024
    Configuration menu
    Copy the full SHA
    b1ec1f7 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    9831fb3 View commit details
    Browse the repository at this point in the history

Commits on Feb 23, 2024

  1. Configuration menu
    Copy the full SHA
    8514faf View commit details
    Browse the repository at this point in the history