return true
}
// match: (Lsh16x16 x y)
- // result: (SLW x (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-16] (ZeroExt16to64 y)))))
+ // result: (SLW x (ISEL [0] y (MOVDconst [-1]) (CMPU (ZeroExt16to64 y) (MOVDconst [16]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SLW)
- v0 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v1 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v2.AuxInt = -16
+ v0 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v0.AuxInt = 0
+ v1 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v1.AuxInt = -1
+ v2 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
v3 := b.NewValue0(v.Pos, OpZeroExt16to64, typ.UInt64)
v3.AddArg(y)
- v2.AddArg(v3)
- v1.AddArg(v2)
- v0.AddArg2(y, v1)
+ v4 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v4.AuxInt = 16
+ v2.AddArg2(v3, v4)
+ v0.AddArg3(y, v1, v2)
v.AddArg2(x, v0)
return true
}
return true
}
// match: (Lsh16x32 x y)
- // result: (SLW x (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-16] (ZeroExt32to64 y)))))
+ // result: (SLW x (ISEL [0] y (MOVDconst [-1]) (CMPU y (MOVDconst [16]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SLW)
- v0 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v1 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v2.AuxInt = -16
- v3 := b.NewValue0(v.Pos, OpZeroExt32to64, typ.UInt64)
- v3.AddArg(y)
- v2.AddArg(v3)
- v1.AddArg(v2)
- v0.AddArg2(y, v1)
+ v0 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v0.AuxInt = 0
+ v1 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v1.AuxInt = -1
+ v2 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
+ v3 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v3.AuxInt = 16
+ v2.AddArg2(y, v3)
+ v0.AddArg3(y, v1, v2)
v.AddArg2(x, v0)
return true
}
return true
}
// match: (Lsh16x64 x y)
- // result: (SLW x (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-16] y))))
+ // result: (SLW x (ISEL [0] y (MOVDconst [-1]) (CMPU y (MOVDconst [16]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SLW)
- v0 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v1 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v2.AuxInt = -16
- v2.AddArg(y)
- v1.AddArg(v2)
- v0.AddArg2(y, v1)
+ v0 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v0.AuxInt = 0
+ v1 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v1.AuxInt = -1
+ v2 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
+ v3 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v3.AuxInt = 16
+ v2.AddArg2(y, v3)
+ v0.AddArg3(y, v1, v2)
v.AddArg2(x, v0)
return true
}
return true
}
// match: (Lsh16x8 x y)
- // result: (SLW x (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-16] (ZeroExt8to64 y)))))
+ // result: (SLW x (ISEL [0] y (MOVDconst [-1]) (CMPU (ZeroExt8to64 y) (MOVDconst [16]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SLW)
- v0 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v1 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v2.AuxInt = -16
+ v0 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v0.AuxInt = 0
+ v1 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v1.AuxInt = -1
+ v2 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
v3 := b.NewValue0(v.Pos, OpZeroExt8to64, typ.UInt64)
v3.AddArg(y)
- v2.AddArg(v3)
- v1.AddArg(v2)
- v0.AddArg2(y, v1)
+ v4 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v4.AuxInt = 16
+ v2.AddArg2(v3, v4)
+ v0.AddArg3(y, v1, v2)
v.AddArg2(x, v0)
return true
}
return true
}
// match: (Lsh32x16 x y)
- // result: (SLW x (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-32] (ZeroExt16to64 y)))))
+ // result: (SLW x (ISEL [0] y (MOVDconst [-1]) (CMPU (ZeroExt16to64 y) (MOVDconst [32]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SLW)
- v0 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v1 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v2.AuxInt = -32
+ v0 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v0.AuxInt = 0
+ v1 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v1.AuxInt = -1
+ v2 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
v3 := b.NewValue0(v.Pos, OpZeroExt16to64, typ.UInt64)
v3.AddArg(y)
- v2.AddArg(v3)
- v1.AddArg(v2)
- v0.AddArg2(y, v1)
+ v4 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v4.AuxInt = 32
+ v2.AddArg2(v3, v4)
+ v0.AddArg3(y, v1, v2)
v.AddArg2(x, v0)
return true
}
return true
}
// match: (Lsh32x32 x y)
- // result: (SLW x (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-32] (ZeroExt32to64 y)))))
+ // result: (SLW x (ISEL [0] y (MOVDconst [-1]) (CMPU y (MOVDconst [32]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SLW)
- v0 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v1 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v2.AuxInt = -32
- v3 := b.NewValue0(v.Pos, OpZeroExt32to64, typ.UInt64)
- v3.AddArg(y)
- v2.AddArg(v3)
- v1.AddArg(v2)
- v0.AddArg2(y, v1)
+ v0 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v0.AuxInt = 0
+ v1 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v1.AuxInt = -1
+ v2 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
+ v3 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v3.AuxInt = 32
+ v2.AddArg2(y, v3)
+ v0.AddArg3(y, v1, v2)
v.AddArg2(x, v0)
return true
}
return true
}
// match: (Lsh32x64 x y)
- // result: (SLW x (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-32] y))))
+ // result: (SLW x (ISEL [0] y (MOVDconst [-1]) (CMPU y (MOVDconst [32]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SLW)
- v0 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v1 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v2.AuxInt = -32
- v2.AddArg(y)
- v1.AddArg(v2)
- v0.AddArg2(y, v1)
+ v0 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v0.AuxInt = 0
+ v1 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v1.AuxInt = -1
+ v2 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
+ v3 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v3.AuxInt = 32
+ v2.AddArg2(y, v3)
+ v0.AddArg3(y, v1, v2)
v.AddArg2(x, v0)
return true
}
return true
}
// match: (Lsh32x8 x y)
- // result: (SLW x (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-32] (ZeroExt8to64 y)))))
+ // result: (SLW x (ISEL [0] y (MOVDconst [-1]) (CMPU (ZeroExt8to64 y) (MOVDconst [32]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SLW)
- v0 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v1 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v2.AuxInt = -32
+ v0 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v0.AuxInt = 0
+ v1 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v1.AuxInt = -1
+ v2 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
v3 := b.NewValue0(v.Pos, OpZeroExt8to64, typ.UInt64)
v3.AddArg(y)
- v2.AddArg(v3)
- v1.AddArg(v2)
- v0.AddArg2(y, v1)
+ v4 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v4.AuxInt = 32
+ v2.AddArg2(v3, v4)
+ v0.AddArg3(y, v1, v2)
v.AddArg2(x, v0)
return true
}
return true
}
// match: (Lsh64x16 x y)
- // result: (SLD x (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-64] (ZeroExt16to64 y)))))
+ // result: (SLD x (ISEL [0] y (MOVDconst [-1]) (CMPU (ZeroExt16to64 y) (MOVDconst [64]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SLD)
- v0 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v1 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v2.AuxInt = -64
+ v0 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v0.AuxInt = 0
+ v1 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v1.AuxInt = -1
+ v2 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
v3 := b.NewValue0(v.Pos, OpZeroExt16to64, typ.UInt64)
v3.AddArg(y)
- v2.AddArg(v3)
- v1.AddArg(v2)
- v0.AddArg2(y, v1)
+ v4 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v4.AuxInt = 64
+ v2.AddArg2(v3, v4)
+ v0.AddArg3(y, v1, v2)
v.AddArg2(x, v0)
return true
}
return true
}
// match: (Lsh64x32 x y)
- // result: (SLD x (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-64] (ZeroExt32to64 y)))))
+ // result: (SLD x (ISEL [0] y (MOVDconst [-1]) (CMPU y (MOVDconst [64]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SLD)
- v0 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v1 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v2.AuxInt = -64
- v3 := b.NewValue0(v.Pos, OpZeroExt32to64, typ.UInt64)
- v3.AddArg(y)
- v2.AddArg(v3)
- v1.AddArg(v2)
- v0.AddArg2(y, v1)
+ v0 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v0.AuxInt = 0
+ v1 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v1.AuxInt = -1
+ v2 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
+ v3 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v3.AuxInt = 64
+ v2.AddArg2(y, v3)
+ v0.AddArg3(y, v1, v2)
v.AddArg2(x, v0)
return true
}
return true
}
// match: (Lsh64x64 x y)
- // result: (SLD x (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-64] y))))
+ // result: (SLD x (ISEL [0] y (MOVDconst [-1]) (CMPU y (MOVDconst [64]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SLD)
- v0 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v1 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v2.AuxInt = -64
- v2.AddArg(y)
- v1.AddArg(v2)
- v0.AddArg2(y, v1)
+ v0 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v0.AuxInt = 0
+ v1 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v1.AuxInt = -1
+ v2 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
+ v3 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v3.AuxInt = 64
+ v2.AddArg2(y, v3)
+ v0.AddArg3(y, v1, v2)
v.AddArg2(x, v0)
return true
}
return true
}
// match: (Lsh64x8 x y)
- // result: (SLD x (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-64] (ZeroExt8to64 y)))))
+ // result: (SLD x (ISEL [0] y (MOVDconst [-1]) (CMPU (ZeroExt8to64 y) (MOVDconst [64]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SLD)
- v0 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v1 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v2.AuxInt = -64
+ v0 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v0.AuxInt = 0
+ v1 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v1.AuxInt = -1
+ v2 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
v3 := b.NewValue0(v.Pos, OpZeroExt8to64, typ.UInt64)
v3.AddArg(y)
- v2.AddArg(v3)
- v1.AddArg(v2)
- v0.AddArg2(y, v1)
+ v4 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v4.AuxInt = 64
+ v2.AddArg2(v3, v4)
+ v0.AddArg3(y, v1, v2)
v.AddArg2(x, v0)
return true
}
return true
}
// match: (Lsh8x16 x y)
- // result: (SLW x (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-8] (ZeroExt16to64 y)))))
+ // result: (SLW x (ISEL [0] y (MOVDconst [-1]) (CMPU (ZeroExt16to64 y) (MOVDconst [8]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SLW)
- v0 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v1 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v2.AuxInt = -8
+ v0 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v0.AuxInt = 0
+ v1 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v1.AuxInt = -1
+ v2 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
v3 := b.NewValue0(v.Pos, OpZeroExt16to64, typ.UInt64)
v3.AddArg(y)
- v2.AddArg(v3)
- v1.AddArg(v2)
- v0.AddArg2(y, v1)
+ v4 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v4.AuxInt = 8
+ v2.AddArg2(v3, v4)
+ v0.AddArg3(y, v1, v2)
v.AddArg2(x, v0)
return true
}
return true
}
// match: (Lsh8x32 x y)
- // result: (SLW x (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-8] (ZeroExt32to64 y)))))
+ // result: (SLW x (ISEL [0] y (MOVDconst [-1]) (CMPU y (MOVDconst [8]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SLW)
- v0 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v1 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v2.AuxInt = -8
- v3 := b.NewValue0(v.Pos, OpZeroExt32to64, typ.UInt64)
- v3.AddArg(y)
- v2.AddArg(v3)
- v1.AddArg(v2)
- v0.AddArg2(y, v1)
+ v0 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v0.AuxInt = 0
+ v1 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v1.AuxInt = -1
+ v2 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
+ v3 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v3.AuxInt = 8
+ v2.AddArg2(y, v3)
+ v0.AddArg3(y, v1, v2)
v.AddArg2(x, v0)
return true
}
return true
}
// match: (Lsh8x64 x y)
- // result: (SLW x (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-8] y))))
+ // result: (SLW x (ISEL [0] y (MOVDconst [-1]) (CMPU y (MOVDconst [8]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SLW)
- v0 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v1 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v2.AuxInt = -8
- v2.AddArg(y)
- v1.AddArg(v2)
- v0.AddArg2(y, v1)
+ v0 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v0.AuxInt = 0
+ v1 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v1.AuxInt = -1
+ v2 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
+ v3 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v3.AuxInt = 8
+ v2.AddArg2(y, v3)
+ v0.AddArg3(y, v1, v2)
v.AddArg2(x, v0)
return true
}
return true
}
// match: (Lsh8x8 x y)
- // result: (SLW x (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-8] (ZeroExt8to64 y)))))
+ // result: (SLW x (ISEL [0] y (MOVDconst [-1]) (CMPU (ZeroExt8to64 y) (MOVDconst [8]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SLW)
- v0 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v1 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v2.AuxInt = -8
+ v0 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v0.AuxInt = 0
+ v1 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v1.AuxInt = -1
+ v2 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
v3 := b.NewValue0(v.Pos, OpZeroExt8to64, typ.UInt64)
v3.AddArg(y)
- v2.AddArg(v3)
- v1.AddArg(v2)
- v0.AddArg2(y, v1)
+ v4 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v4.AuxInt = 8
+ v2.AddArg2(v3, v4)
+ v0.AddArg3(y, v1, v2)
v.AddArg2(x, v0)
return true
}
v_2 := v.Args[2]
v_1 := v.Args[1]
v_0 := v.Args[0]
+ // match: (ISEL [0] (ANDconst [d] y) (MOVDconst [-1]) (CMPU (ANDconst [d] y) (MOVDconst [c])))
+ // cond: c >= d
+ // result: (ANDconst [d] y)
+ for {
+ if v.AuxInt != 0 || v_0.Op != OpPPC64ANDconst {
+ break
+ }
+ d := v_0.AuxInt
+ y := v_0.Args[0]
+ if v_1.Op != OpPPC64MOVDconst || v_1.AuxInt != -1 || v_2.Op != OpPPC64CMPU {
+ break
+ }
+ _ = v_2.Args[1]
+ v_2_0 := v_2.Args[0]
+ if v_2_0.Op != OpPPC64ANDconst || v_2_0.AuxInt != d || y != v_2_0.Args[0] {
+ break
+ }
+ v_2_1 := v_2.Args[1]
+ if v_2_1.Op != OpPPC64MOVDconst {
+ break
+ }
+ c := v_2_1.AuxInt
+ if !(c >= d) {
+ break
+ }
+ v.reset(OpPPC64ANDconst)
+ v.AuxInt = d
+ v.AddArg(y)
+ return true
+ }
+ // match: (ISEL [0] (ANDconst [d] y) (MOVDconst [-1]) (CMPUconst [c] (ANDconst [d] y)))
+ // cond: c >= d
+ // result: (ANDconst [d] y)
+ for {
+ if v.AuxInt != 0 || v_0.Op != OpPPC64ANDconst {
+ break
+ }
+ d := v_0.AuxInt
+ y := v_0.Args[0]
+ if v_1.Op != OpPPC64MOVDconst || v_1.AuxInt != -1 || v_2.Op != OpPPC64CMPUconst {
+ break
+ }
+ c := v_2.AuxInt
+ v_2_0 := v_2.Args[0]
+ if v_2_0.Op != OpPPC64ANDconst || v_2_0.AuxInt != d || y != v_2_0.Args[0] || !(c >= d) {
+ break
+ }
+ v.reset(OpPPC64ANDconst)
+ v.AuxInt = d
+ v.AddArg(y)
+ return true
+ }
// match: (ISEL [2] x _ (FlagEQ))
// result: x
for {
return true
}
// match: (Rsh16Ux16 x y)
- // result: (SRW (ZeroExt16to32 x) (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-16] (ZeroExt16to64 y)))))
+ // result: (SRW (ZeroExt16to32 x) (ISEL [0] y (MOVDconst [-1]) (CMPU (ZeroExt16to64 y) (MOVDconst [16]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SRW)
v0 := b.NewValue0(v.Pos, OpZeroExt16to32, typ.UInt32)
v0.AddArg(x)
- v1 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v3 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v3.AuxInt = -16
+ v1 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v1.AuxInt = 0
+ v2 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v2.AuxInt = -1
+ v3 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
v4 := b.NewValue0(v.Pos, OpZeroExt16to64, typ.UInt64)
v4.AddArg(y)
- v3.AddArg(v4)
- v2.AddArg(v3)
- v1.AddArg2(y, v2)
+ v5 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v5.AuxInt = 16
+ v3.AddArg2(v4, v5)
+ v1.AddArg3(y, v2, v3)
v.AddArg2(v0, v1)
return true
}
return true
}
// match: (Rsh16Ux32 x y)
- // result: (SRW (ZeroExt16to32 x) (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-16] (ZeroExt32to64 y)))))
+ // result: (SRW (ZeroExt16to32 x) (ISEL [0] y (MOVDconst [-1]) (CMPU y (MOVDconst [16]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SRW)
v0 := b.NewValue0(v.Pos, OpZeroExt16to32, typ.UInt32)
v0.AddArg(x)
- v1 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v3 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v3.AuxInt = -16
- v4 := b.NewValue0(v.Pos, OpZeroExt32to64, typ.UInt64)
- v4.AddArg(y)
- v3.AddArg(v4)
- v2.AddArg(v3)
- v1.AddArg2(y, v2)
+ v1 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v1.AuxInt = 0
+ v2 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v2.AuxInt = -1
+ v3 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
+ v4 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v4.AuxInt = 16
+ v3.AddArg2(y, v4)
+ v1.AddArg3(y, v2, v3)
v.AddArg2(v0, v1)
return true
}
return true
}
// match: (Rsh16Ux64 x y)
- // result: (SRW (ZeroExt16to32 x) (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-16] y))))
+ // result: (SRW (ZeroExt16to32 x) (ISEL [0] y (MOVDconst [-1]) (CMPU y (MOVDconst [16]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SRW)
v0 := b.NewValue0(v.Pos, OpZeroExt16to32, typ.UInt32)
v0.AddArg(x)
- v1 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v3 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v3.AuxInt = -16
- v3.AddArg(y)
- v2.AddArg(v3)
- v1.AddArg2(y, v2)
+ v1 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v1.AuxInt = 0
+ v2 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v2.AuxInt = -1
+ v3 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
+ v4 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v4.AuxInt = 16
+ v3.AddArg2(y, v4)
+ v1.AddArg3(y, v2, v3)
v.AddArg2(v0, v1)
return true
}
return true
}
// match: (Rsh16Ux8 x y)
- // result: (SRW (ZeroExt16to32 x) (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-16] (ZeroExt8to64 y)))))
+ // result: (SRW (ZeroExt16to32 x) (ISEL [0] y (MOVDconst [-1]) (CMPU (ZeroExt8to64 y) (MOVDconst [16]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SRW)
v0 := b.NewValue0(v.Pos, OpZeroExt16to32, typ.UInt32)
v0.AddArg(x)
- v1 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v3 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v3.AuxInt = -16
+ v1 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v1.AuxInt = 0
+ v2 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v2.AuxInt = -1
+ v3 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
v4 := b.NewValue0(v.Pos, OpZeroExt8to64, typ.UInt64)
v4.AddArg(y)
- v3.AddArg(v4)
- v2.AddArg(v3)
- v1.AddArg2(y, v2)
+ v5 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v5.AuxInt = 16
+ v3.AddArg2(v4, v5)
+ v1.AddArg3(y, v2, v3)
v.AddArg2(v0, v1)
return true
}
return true
}
// match: (Rsh16x16 x y)
- // result: (SRAW (SignExt16to32 x) (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-16] (ZeroExt16to64 y)))))
+ // result: (SRAW (SignExt16to32 x) (ISEL [0] y (MOVDconst [-1]) (CMPU (ZeroExt16to64 y) (MOVDconst [16]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SRAW)
v0 := b.NewValue0(v.Pos, OpSignExt16to32, typ.Int32)
v0.AddArg(x)
- v1 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v3 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v3.AuxInt = -16
+ v1 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v1.AuxInt = 0
+ v2 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v2.AuxInt = -1
+ v3 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
v4 := b.NewValue0(v.Pos, OpZeroExt16to64, typ.UInt64)
v4.AddArg(y)
- v3.AddArg(v4)
- v2.AddArg(v3)
- v1.AddArg2(y, v2)
+ v5 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v5.AuxInt = 16
+ v3.AddArg2(v4, v5)
+ v1.AddArg3(y, v2, v3)
v.AddArg2(v0, v1)
return true
}
return true
}
// match: (Rsh16x32 x y)
- // result: (SRAW (SignExt16to32 x) (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-16] (ZeroExt32to64 y)))))
+ // result: (SRAW (SignExt16to32 x) (ISEL [0] y (MOVDconst [-1]) (CMPU y (MOVDconst [16]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SRAW)
v0 := b.NewValue0(v.Pos, OpSignExt16to32, typ.Int32)
v0.AddArg(x)
- v1 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v3 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v3.AuxInt = -16
- v4 := b.NewValue0(v.Pos, OpZeroExt32to64, typ.UInt64)
- v4.AddArg(y)
- v3.AddArg(v4)
- v2.AddArg(v3)
- v1.AddArg2(y, v2)
+ v1 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v1.AuxInt = 0
+ v2 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v2.AuxInt = -1
+ v3 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
+ v4 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v4.AuxInt = 16
+ v3.AddArg2(y, v4)
+ v1.AddArg3(y, v2, v3)
v.AddArg2(v0, v1)
return true
}
return true
}
// match: (Rsh16x64 x y)
- // result: (SRAW (SignExt16to32 x) (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-16] y))))
+ // result: (SRAW (SignExt16to32 x) (ISEL [0] y (MOVDconst [-1]) (CMPU y (MOVDconst [16]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SRAW)
v0 := b.NewValue0(v.Pos, OpSignExt16to32, typ.Int32)
v0.AddArg(x)
- v1 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v3 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v3.AuxInt = -16
- v3.AddArg(y)
- v2.AddArg(v3)
- v1.AddArg2(y, v2)
+ v1 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v1.AuxInt = 0
+ v2 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v2.AuxInt = -1
+ v3 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
+ v4 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v4.AuxInt = 16
+ v3.AddArg2(y, v4)
+ v1.AddArg3(y, v2, v3)
v.AddArg2(v0, v1)
return true
}
return true
}
// match: (Rsh16x8 x y)
- // result: (SRAW (SignExt16to32 x) (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-16] (ZeroExt8to64 y)))))
+ // result: (SRAW (SignExt16to32 x) (ISEL [0] y (MOVDconst [-1]) (CMPU (ZeroExt8to64 y) (MOVDconst [16]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SRAW)
v0 := b.NewValue0(v.Pos, OpSignExt16to32, typ.Int32)
v0.AddArg(x)
- v1 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v3 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v3.AuxInt = -16
+ v1 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v1.AuxInt = 0
+ v2 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v2.AuxInt = -1
+ v3 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
v4 := b.NewValue0(v.Pos, OpZeroExt8to64, typ.UInt64)
v4.AddArg(y)
- v3.AddArg(v4)
- v2.AddArg(v3)
- v1.AddArg2(y, v2)
+ v5 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v5.AuxInt = 16
+ v3.AddArg2(v4, v5)
+ v1.AddArg3(y, v2, v3)
v.AddArg2(v0, v1)
return true
}
return true
}
// match: (Rsh32Ux16 x y)
- // result: (SRW x (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-32] (ZeroExt16to64 y)))))
+ // result: (SRW x (ISEL [0] y (MOVDconst [-1]) (CMPU (ZeroExt16to64 y) (MOVDconst [32]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SRW)
- v0 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v1 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v2.AuxInt = -32
+ v0 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v0.AuxInt = 0
+ v1 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v1.AuxInt = -1
+ v2 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
v3 := b.NewValue0(v.Pos, OpZeroExt16to64, typ.UInt64)
v3.AddArg(y)
- v2.AddArg(v3)
- v1.AddArg(v2)
- v0.AddArg2(y, v1)
+ v4 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v4.AuxInt = 32
+ v2.AddArg2(v3, v4)
+ v0.AddArg3(y, v1, v2)
v.AddArg2(x, v0)
return true
}
return true
}
// match: (Rsh32Ux32 x y)
- // result: (SRW x (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-32] (ZeroExt32to64 y)))))
+ // result: (SRW x (ISEL [0] y (MOVDconst [-1]) (CMPU y (MOVDconst [32]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SRW)
- v0 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v1 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v2.AuxInt = -32
- v3 := b.NewValue0(v.Pos, OpZeroExt32to64, typ.UInt64)
- v3.AddArg(y)
- v2.AddArg(v3)
- v1.AddArg(v2)
- v0.AddArg2(y, v1)
+ v0 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v0.AuxInt = 0
+ v1 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v1.AuxInt = -1
+ v2 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
+ v3 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v3.AuxInt = 32
+ v2.AddArg2(y, v3)
+ v0.AddArg3(y, v1, v2)
v.AddArg2(x, v0)
return true
}
break
}
// match: (Rsh32Ux64 x y)
- // result: (SRW x (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-32] y))))
+ // result: (SRW x (ISEL [0] y (MOVDconst [-1]) (CMPU y (MOVDconst [32]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SRW)
- v0 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v1 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v2.AuxInt = -32
- v2.AddArg(y)
- v1.AddArg(v2)
- v0.AddArg2(y, v1)
+ v0 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v0.AuxInt = 0
+ v1 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v1.AuxInt = -1
+ v2 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
+ v3 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v3.AuxInt = 32
+ v2.AddArg2(y, v3)
+ v0.AddArg3(y, v1, v2)
v.AddArg2(x, v0)
return true
}
return true
}
// match: (Rsh32Ux8 x y)
- // result: (SRW x (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-32] (ZeroExt8to64 y)))))
+ // result: (SRW x (ISEL [0] y (MOVDconst [-1]) (CMPU (ZeroExt8to64 y) (MOVDconst [32]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SRW)
- v0 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v1 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v2.AuxInt = -32
+ v0 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v0.AuxInt = 0
+ v1 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v1.AuxInt = -1
+ v2 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
v3 := b.NewValue0(v.Pos, OpZeroExt8to64, typ.UInt64)
v3.AddArg(y)
- v2.AddArg(v3)
- v1.AddArg(v2)
- v0.AddArg2(y, v1)
+ v4 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v4.AuxInt = 32
+ v2.AddArg2(v3, v4)
+ v0.AddArg3(y, v1, v2)
v.AddArg2(x, v0)
return true
}
return true
}
// match: (Rsh32x16 x y)
- // result: (SRAW x (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-32] (ZeroExt16to64 y)))))
+ // result: (SRAW x (ISEL [0] y (MOVDconst [-1]) (CMPU (ZeroExt16to64 y) (MOVDconst [32]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SRAW)
- v0 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v1 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v2.AuxInt = -32
+ v0 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v0.AuxInt = 0
+ v1 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v1.AuxInt = -1
+ v2 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
v3 := b.NewValue0(v.Pos, OpZeroExt16to64, typ.UInt64)
v3.AddArg(y)
- v2.AddArg(v3)
- v1.AddArg(v2)
- v0.AddArg2(y, v1)
+ v4 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v4.AuxInt = 32
+ v2.AddArg2(v3, v4)
+ v0.AddArg3(y, v1, v2)
v.AddArg2(x, v0)
return true
}
return true
}
// match: (Rsh32x32 x y)
- // result: (SRAW x (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-32] (ZeroExt32to64 y)))))
+ // result: (SRAW x (ISEL [0] y (MOVDconst [-1]) (CMPU y (MOVDconst [32]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SRAW)
- v0 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v1 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v2.AuxInt = -32
- v3 := b.NewValue0(v.Pos, OpZeroExt32to64, typ.UInt64)
- v3.AddArg(y)
- v2.AddArg(v3)
- v1.AddArg(v2)
- v0.AddArg2(y, v1)
+ v0 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v0.AuxInt = 0
+ v1 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v1.AuxInt = -1
+ v2 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
+ v3 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v3.AuxInt = 32
+ v2.AddArg2(y, v3)
+ v0.AddArg3(y, v1, v2)
v.AddArg2(x, v0)
return true
}
break
}
// match: (Rsh32x64 x y)
- // result: (SRAW x (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-32] y))))
+ // result: (SRAW x (ISEL [0] y (MOVDconst [-1]) (CMPU y (MOVDconst [32]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SRAW)
- v0 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v1 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v2.AuxInt = -32
- v2.AddArg(y)
- v1.AddArg(v2)
- v0.AddArg2(y, v1)
+ v0 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v0.AuxInt = 0
+ v1 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v1.AuxInt = -1
+ v2 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
+ v3 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v3.AuxInt = 32
+ v2.AddArg2(y, v3)
+ v0.AddArg3(y, v1, v2)
v.AddArg2(x, v0)
return true
}
return true
}
// match: (Rsh32x8 x y)
- // result: (SRAW x (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-32] (ZeroExt8to64 y)))))
+ // result: (SRAW x (ISEL [0] y (MOVDconst [-1]) (CMPU (ZeroExt8to64 y) (MOVDconst [32]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SRAW)
- v0 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v1 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v2.AuxInt = -32
+ v0 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v0.AuxInt = 0
+ v1 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v1.AuxInt = -1
+ v2 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
v3 := b.NewValue0(v.Pos, OpZeroExt8to64, typ.UInt64)
v3.AddArg(y)
- v2.AddArg(v3)
- v1.AddArg(v2)
- v0.AddArg2(y, v1)
+ v4 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v4.AuxInt = 32
+ v2.AddArg2(v3, v4)
+ v0.AddArg3(y, v1, v2)
v.AddArg2(x, v0)
return true
}
return true
}
// match: (Rsh64Ux16 x y)
- // result: (SRD x (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-64] (ZeroExt16to64 y)))))
+ // result: (SRD x (ISEL [0] y (MOVDconst [-1]) (CMPU (ZeroExt16to64 y) (MOVDconst [64]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SRD)
- v0 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v1 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v2.AuxInt = -64
+ v0 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v0.AuxInt = 0
+ v1 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v1.AuxInt = -1
+ v2 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
v3 := b.NewValue0(v.Pos, OpZeroExt16to64, typ.UInt64)
v3.AddArg(y)
- v2.AddArg(v3)
- v1.AddArg(v2)
- v0.AddArg2(y, v1)
+ v4 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v4.AuxInt = 64
+ v2.AddArg2(v3, v4)
+ v0.AddArg3(y, v1, v2)
v.AddArg2(x, v0)
return true
}
return true
}
// match: (Rsh64Ux32 x y)
- // result: (SRD x (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-64] (ZeroExt32to64 y)))))
+ // result: (SRD x (ISEL [0] y (MOVDconst [-1]) (CMPU y (MOVDconst [64]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SRD)
- v0 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v1 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v2.AuxInt = -64
- v3 := b.NewValue0(v.Pos, OpZeroExt32to64, typ.UInt64)
- v3.AddArg(y)
- v2.AddArg(v3)
- v1.AddArg(v2)
- v0.AddArg2(y, v1)
+ v0 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v0.AuxInt = 0
+ v1 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v1.AuxInt = -1
+ v2 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
+ v3 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v3.AuxInt = 64
+ v2.AddArg2(y, v3)
+ v0.AddArg3(y, v1, v2)
v.AddArg2(x, v0)
return true
}
break
}
// match: (Rsh64Ux64 x y)
- // result: (SRD x (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-64] y))))
+ // result: (SRD x (ISEL [0] y (MOVDconst [-1]) (CMPU y (MOVDconst [64]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SRD)
- v0 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v1 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v2.AuxInt = -64
- v2.AddArg(y)
- v1.AddArg(v2)
- v0.AddArg2(y, v1)
+ v0 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v0.AuxInt = 0
+ v1 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v1.AuxInt = -1
+ v2 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
+ v3 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v3.AuxInt = 64
+ v2.AddArg2(y, v3)
+ v0.AddArg3(y, v1, v2)
v.AddArg2(x, v0)
return true
}
return true
}
// match: (Rsh64Ux8 x y)
- // result: (SRD x (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-64] (ZeroExt8to64 y)))))
+ // result: (SRD x (ISEL [0] y (MOVDconst [-1]) (CMPU (ZeroExt8to64 y) (MOVDconst [64]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SRD)
- v0 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v1 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v2.AuxInt = -64
+ v0 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v0.AuxInt = 0
+ v1 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v1.AuxInt = -1
+ v2 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
v3 := b.NewValue0(v.Pos, OpZeroExt8to64, typ.UInt64)
v3.AddArg(y)
- v2.AddArg(v3)
- v1.AddArg(v2)
- v0.AddArg2(y, v1)
+ v4 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v4.AuxInt = 64
+ v2.AddArg2(v3, v4)
+ v0.AddArg3(y, v1, v2)
v.AddArg2(x, v0)
return true
}
return true
}
// match: (Rsh64x16 x y)
- // result: (SRAD x (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-64] (ZeroExt16to64 y)))))
+ // result: (SRAD x (ISEL [0] y (MOVDconst [-1]) (CMPU (ZeroExt16to64 y) (MOVDconst [64]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SRAD)
- v0 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v1 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v2.AuxInt = -64
+ v0 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v0.AuxInt = 0
+ v1 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v1.AuxInt = -1
+ v2 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
v3 := b.NewValue0(v.Pos, OpZeroExt16to64, typ.UInt64)
v3.AddArg(y)
- v2.AddArg(v3)
- v1.AddArg(v2)
- v0.AddArg2(y, v1)
+ v4 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v4.AuxInt = 64
+ v2.AddArg2(v3, v4)
+ v0.AddArg3(y, v1, v2)
v.AddArg2(x, v0)
return true
}
return true
}
// match: (Rsh64x32 x y)
- // result: (SRAD x (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-64] (ZeroExt32to64 y)))))
+ // result: (SRAD x (ISEL [0] y (MOVDconst [-1]) (CMPU y (MOVDconst [64]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SRAD)
- v0 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v1 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v2.AuxInt = -64
- v3 := b.NewValue0(v.Pos, OpZeroExt32to64, typ.UInt64)
- v3.AddArg(y)
- v2.AddArg(v3)
- v1.AddArg(v2)
- v0.AddArg2(y, v1)
+ v0 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v0.AuxInt = 0
+ v1 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v1.AuxInt = -1
+ v2 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
+ v3 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v3.AuxInt = 64
+ v2.AddArg2(y, v3)
+ v0.AddArg3(y, v1, v2)
v.AddArg2(x, v0)
return true
}
break
}
// match: (Rsh64x64 x y)
- // result: (SRAD x (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-64] y))))
+ // result: (SRAD x (ISEL [0] y (MOVDconst [-1]) (CMPU y (MOVDconst [64]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SRAD)
- v0 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v1 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v2.AuxInt = -64
- v2.AddArg(y)
- v1.AddArg(v2)
- v0.AddArg2(y, v1)
+ v0 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v0.AuxInt = 0
+ v1 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v1.AuxInt = -1
+ v2 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
+ v3 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v3.AuxInt = 64
+ v2.AddArg2(y, v3)
+ v0.AddArg3(y, v1, v2)
v.AddArg2(x, v0)
return true
}
return true
}
// match: (Rsh64x8 x y)
- // result: (SRAD x (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-64] (ZeroExt8to64 y)))))
+ // result: (SRAD x (ISEL [0] y (MOVDconst [-1]) (CMPU (ZeroExt8to64 y) (MOVDconst [64]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SRAD)
- v0 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v1 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v2.AuxInt = -64
+ v0 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v0.AuxInt = 0
+ v1 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v1.AuxInt = -1
+ v2 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
v3 := b.NewValue0(v.Pos, OpZeroExt8to64, typ.UInt64)
v3.AddArg(y)
- v2.AddArg(v3)
- v1.AddArg(v2)
- v0.AddArg2(y, v1)
+ v4 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v4.AuxInt = 64
+ v2.AddArg2(v3, v4)
+ v0.AddArg3(y, v1, v2)
v.AddArg2(x, v0)
return true
}
return true
}
// match: (Rsh8Ux16 x y)
- // result: (SRW (ZeroExt8to32 x) (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-8] (ZeroExt16to64 y)))))
+ // result: (SRW (ZeroExt8to32 x) (ISEL [0] y (MOVDconst [-1]) (CMPU (ZeroExt16to64 y) (MOVDconst [8]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SRW)
v0 := b.NewValue0(v.Pos, OpZeroExt8to32, typ.UInt32)
v0.AddArg(x)
- v1 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v3 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v3.AuxInt = -8
+ v1 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v1.AuxInt = 0
+ v2 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v2.AuxInt = -1
+ v3 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
v4 := b.NewValue0(v.Pos, OpZeroExt16to64, typ.UInt64)
v4.AddArg(y)
- v3.AddArg(v4)
- v2.AddArg(v3)
- v1.AddArg2(y, v2)
+ v5 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v5.AuxInt = 8
+ v3.AddArg2(v4, v5)
+ v1.AddArg3(y, v2, v3)
v.AddArg2(v0, v1)
return true
}
return true
}
// match: (Rsh8Ux32 x y)
- // result: (SRW (ZeroExt8to32 x) (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-8] (ZeroExt32to64 y)))))
+ // result: (SRW (ZeroExt8to32 x) (ISEL [0] y (MOVDconst [-1]) (CMPU y (MOVDconst [8]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SRW)
v0 := b.NewValue0(v.Pos, OpZeroExt8to32, typ.UInt32)
v0.AddArg(x)
- v1 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v3 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v3.AuxInt = -8
- v4 := b.NewValue0(v.Pos, OpZeroExt32to64, typ.UInt64)
- v4.AddArg(y)
- v3.AddArg(v4)
- v2.AddArg(v3)
- v1.AddArg2(y, v2)
+ v1 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v1.AuxInt = 0
+ v2 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v2.AuxInt = -1
+ v3 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
+ v4 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v4.AuxInt = 8
+ v3.AddArg2(y, v4)
+ v1.AddArg3(y, v2, v3)
v.AddArg2(v0, v1)
return true
}
return true
}
// match: (Rsh8Ux64 x y)
- // result: (SRW (ZeroExt8to32 x) (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-8] y))))
+ // result: (SRW (ZeroExt8to32 x) (ISEL [0] y (MOVDconst [-1]) (CMPU y (MOVDconst [8]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SRW)
v0 := b.NewValue0(v.Pos, OpZeroExt8to32, typ.UInt32)
v0.AddArg(x)
- v1 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v3 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v3.AuxInt = -8
- v3.AddArg(y)
- v2.AddArg(v3)
- v1.AddArg2(y, v2)
+ v1 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v1.AuxInt = 0
+ v2 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v2.AuxInt = -1
+ v3 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
+ v4 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v4.AuxInt = 8
+ v3.AddArg2(y, v4)
+ v1.AddArg3(y, v2, v3)
v.AddArg2(v0, v1)
return true
}
return true
}
// match: (Rsh8Ux8 x y)
- // result: (SRW (ZeroExt8to32 x) (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-8] (ZeroExt8to64 y)))))
+ // result: (SRW (ZeroExt8to32 x) (ISEL [0] y (MOVDconst [-1]) (CMPU (ZeroExt8to64 y) (MOVDconst [8]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SRW)
v0 := b.NewValue0(v.Pos, OpZeroExt8to32, typ.UInt32)
v0.AddArg(x)
- v1 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v3 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v3.AuxInt = -8
+ v1 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v1.AuxInt = 0
+ v2 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v2.AuxInt = -1
+ v3 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
v4 := b.NewValue0(v.Pos, OpZeroExt8to64, typ.UInt64)
v4.AddArg(y)
- v3.AddArg(v4)
- v2.AddArg(v3)
- v1.AddArg2(y, v2)
+ v5 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v5.AuxInt = 8
+ v3.AddArg2(v4, v5)
+ v1.AddArg3(y, v2, v3)
v.AddArg2(v0, v1)
return true
}
return true
}
// match: (Rsh8x16 x y)
- // result: (SRAW (SignExt8to32 x) (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-8] (ZeroExt16to64 y)))))
+ // result: (SRAW (SignExt8to32 x) (ISEL [0] y (MOVDconst [-1]) (CMPU (ZeroExt16to64 y) (MOVDconst [8]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SRAW)
v0 := b.NewValue0(v.Pos, OpSignExt8to32, typ.Int32)
v0.AddArg(x)
- v1 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v3 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v3.AuxInt = -8
+ v1 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v1.AuxInt = 0
+ v2 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v2.AuxInt = -1
+ v3 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
v4 := b.NewValue0(v.Pos, OpZeroExt16to64, typ.UInt64)
v4.AddArg(y)
- v3.AddArg(v4)
- v2.AddArg(v3)
- v1.AddArg2(y, v2)
+ v5 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v5.AuxInt = 8
+ v3.AddArg2(v4, v5)
+ v1.AddArg3(y, v2, v3)
v.AddArg2(v0, v1)
return true
}
return true
}
// match: (Rsh8x32 x y)
- // result: (SRAW (SignExt8to32 x) (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-8] (ZeroExt32to64 y)))))
+ // result: (SRAW (SignExt8to32 x) (ISEL [0] y (MOVDconst [-1]) (CMPU y (MOVDconst [8]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SRAW)
v0 := b.NewValue0(v.Pos, OpSignExt8to32, typ.Int32)
v0.AddArg(x)
- v1 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v3 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v3.AuxInt = -8
- v4 := b.NewValue0(v.Pos, OpZeroExt32to64, typ.UInt64)
- v4.AddArg(y)
- v3.AddArg(v4)
- v2.AddArg(v3)
- v1.AddArg2(y, v2)
+ v1 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v1.AuxInt = 0
+ v2 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v2.AuxInt = -1
+ v3 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
+ v4 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v4.AuxInt = 8
+ v3.AddArg2(y, v4)
+ v1.AddArg3(y, v2, v3)
v.AddArg2(v0, v1)
return true
}
return true
}
// match: (Rsh8x64 x y)
- // result: (SRAW (SignExt8to32 x) (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-8] y))))
+ // result: (SRAW (SignExt8to32 x) (ISEL [0] y (MOVDconst [-1]) (CMPU y (MOVDconst [8]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SRAW)
v0 := b.NewValue0(v.Pos, OpSignExt8to32, typ.Int32)
v0.AddArg(x)
- v1 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v3 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v3.AuxInt = -8
- v3.AddArg(y)
- v2.AddArg(v3)
- v1.AddArg2(y, v2)
+ v1 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v1.AuxInt = 0
+ v2 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v2.AuxInt = -1
+ v3 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
+ v4 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v4.AuxInt = 8
+ v3.AddArg2(y, v4)
+ v1.AddArg3(y, v2, v3)
v.AddArg2(v0, v1)
return true
}
return true
}
// match: (Rsh8x8 x y)
- // result: (SRAW (SignExt8to32 x) (ORN y <typ.Int64> (MaskIfNotCarry (ADDconstForCarry [-8] (ZeroExt8to64 y)))))
+ // result: (SRAW (SignExt8to32 x) (ISEL [0] y (MOVDconst [-1]) (CMPU (ZeroExt8to64 y) (MOVDconst [8]))))
for {
x := v_0
y := v_1
v.reset(OpPPC64SRAW)
v0 := b.NewValue0(v.Pos, OpSignExt8to32, typ.Int32)
v0.AddArg(x)
- v1 := b.NewValue0(v.Pos, OpPPC64ORN, typ.Int64)
- v2 := b.NewValue0(v.Pos, OpPPC64MaskIfNotCarry, typ.Int64)
- v3 := b.NewValue0(v.Pos, OpPPC64ADDconstForCarry, types.TypeFlags)
- v3.AuxInt = -8
+ v1 := b.NewValue0(v.Pos, OpPPC64ISEL, typ.Int32)
+ v1.AuxInt = 0
+ v2 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v2.AuxInt = -1
+ v3 := b.NewValue0(v.Pos, OpPPC64CMPU, types.TypeFlags)
v4 := b.NewValue0(v.Pos, OpZeroExt8to64, typ.UInt64)
v4.AddArg(y)
- v3.AddArg(v4)
- v2.AddArg(v3)
- v1.AddArg2(y, v2)
+ v5 := b.NewValue0(v.Pos, OpPPC64MOVDconst, typ.Int64)
+ v5.AuxInt = 8
+ v3.AddArg2(v4, v5)
+ v1.AddArg3(y, v2, v3)
v.AddArg2(v0, v1)
return true
}