use pattern matching for NEON vfold cases
This commit is contained in:
parent
c95482e8e0
commit
44ee417d40
@ -62,9 +62,9 @@ def fold_add {a:T=[_]E if nvec{T}} = emit{E, ntyp{'vaddv', T}, a}
|
||||
def fold_addw{a:T=[_]E if nveci{T}} = emit{w_d{E}, ntyp{'vaddlv', T}, a}
|
||||
def fold_min {a:T=[_]E if nvec{T} and ~nveci{T,64}} = emit{E, ntyp{'vminv', T}, a}
|
||||
def fold_max {a:T=[_]E if nvec{T} and ~nveci{T,64}} = emit{E, ntyp{'vmaxv', T}, a}
|
||||
def vfold{F, x:T if nvec{T} and ~nveci{T,64} and same{F, min}} = fold_min{x}
|
||||
def vfold{F, x:T if nvec{T} and ~nveci{T,64} and same{F, max}} = fold_max{x}
|
||||
def vfold{F, x:T if nvec{T} and same{F, +}} = fold_add{x}
|
||||
def vfold{(min), x:T if nvec{T} and ~nveci{T,64}} = fold_min{x}
|
||||
def vfold{(max), x:T if nvec{T} and ~nveci{T,64}} = fold_max{x}
|
||||
def vfold{(+), x:T if nvec{T}} = fold_add{x}
|
||||
|
||||
def store{ptr:*E, x:V=[_]E, vl if nvec{V} and vl*width{E}<=64} = {
|
||||
def E=ty_u{vl*width{E}}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user