[all-commits] [llvm/llvm-project] 403b9c: [WebAssembly] Use RefTypeMem2Local instead of Mem2...

Heejin Ahn via All-commits all-commits at lists.llvm.org
Tue Mar 5 19:54:53 PST 2024


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 403b9cf1bb29d550c419ac5ecd2f764bf5cfa3c0
      https://github.com/llvm/llvm-project/commit/403b9cf1bb29d550c419ac5ecd2f764bf5cfa3c0
  Author: Heejin Ahn <aheejin at gmail.com>
  Date:   2024-03-05 (Tue, 05 Mar 2024)

  Changed paths:
    M llvm/include/llvm/Transforms/Utils.h
    M llvm/lib/Target/WebAssembly/WebAssemblyTargetMachine.cpp
    M llvm/lib/Transforms/Utils/Mem2Reg.cpp
    M llvm/test/CodeGen/WebAssembly/ref-type-mem2local.ll

  Log Message:
  -----------
  [WebAssembly] Use RefTypeMem2Local instead of Mem2Reg (#83196)

When reference-types feature is enabled, forcing mem2reg unconditionally
even in `-O0` has some problems described in #81575. This uses
RefTypeMem2Local pass added in #81965 instead. This also removes
`IsForced` parameter added in

https://github.com/llvm/llvm-project/commit/890146b19206827bc48ee1ae1dc1534ff2ff18d7
given that we don't need it anymore.

This may still hurt debug info related to reference type variables a
little during the backend transformation given that they are not stored
in memory anymore, but reference type variables are presumably rare and
it would be still a lot less damage than forcing mem2reg on the whole
program. Also this fixes the EH problem described in #81575.

Fixes #81575.



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list