[llvm-bugs] [Bug 50434] New: wasm32: v128.load32_zero not used with equivalent pattern
via llvm-bugs
llvm-bugs at lists.llvm.org
Fri May 21 07:37:56 PDT 2021
https://bugs.llvm.org/show_bug.cgi?id=50434
Bug ID: 50434
Summary: wasm32: v128.load32_zero not used with equivalent
pattern
Product: libraries
Version: trunk
Hardware: PC
OS: All
Status: NEW
Severity: enhancement
Priority: P
Component: Backend: WebAssembly
Assignee: unassignedbugs at nondot.org
Reporter: alex at crichton.co
CC: llvm-bugs at lists.llvm.org
Given this LLVM IR:
; ModuleID = 'foo.3a1fbbbh-cgu.0'
source_filename = "foo.3a1fbbbh-cgu.0"
target datalayout = "e-m:e-p:32:32-i64:64-n32:64-S128"
target triple = "wasm32-unknown-wasi"
; Function Attrs: norecurse nounwind readonly willreturn
define dso_local <4 x i32> @v128_load32_zero(i32* nocapture readonly %a, <4 x
i32> %b) unnamed_addr #0 {
start:
%_3 = load i32, i32* %a, align 4
%_5.12.vec.insert.i.i = insertelement <4 x i32> <i32 poison, i32 0, i32 0,
i32 0>, i32 %_3, i32 0
ret <4 x i32> %_5.12.vec.insert.i.i
}
attributes #0 = { norecurse nounwind readonly willreturn "target-cpu"="generic"
"target-features"="+simd128" }
this doesn't currently optimize to use the `v128.load32_zero` intrinsic, it
requires using the `llvm.wasm.load32.zero` intrinsic. While not super
problematic it'd be nice if this equivalent pattern was recognized because it'd
allow easy configuration of the alignment on `v128.load32_zero` since it
happens via the `load` instruction separately.
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20210521/9360acec/attachment.html>
More information about the llvm-bugs
mailing list