HELLO·Android
系统源代码
IT资讯
技术文章
我的收藏
注册
登录
-
我收藏的文章
创建代码块
我的代码块
我的账号
Android 10
|
10.0.0_r6
下载
查看原文件
收藏
根目录
prebuilts
go
darwin-x86
src
cmd
compile
internal
ssa
rewritegeneric.go
// Code generated from gen/generic.rules; DO NOT EDIT. // generated with: cd gen; go run *.go package ssa import "fmt" import "math" import "cmd/internal/obj" import "cmd/internal/objabi" import "cmd/compile/internal/types" var _ = fmt.Println // in case not otherwise used var _ = math.MinInt8 // in case not otherwise used var _ = obj.ANOP // in case not otherwise used var _ = objabi.GOROOT // in case not otherwise used var _ = types.TypeMem // in case not otherwise used func rewriteValuegeneric(v *Value) bool { switch v.Op { case OpAdd16: return rewriteValuegeneric_OpAdd16_0(v) || rewriteValuegeneric_OpAdd16_10(v) || rewriteValuegeneric_OpAdd16_20(v) || rewriteValuegeneric_OpAdd16_30(v) case OpAdd32: return rewriteValuegeneric_OpAdd32_0(v) || rewriteValuegeneric_OpAdd32_10(v) || rewriteValuegeneric_OpAdd32_20(v) || rewriteValuegeneric_OpAdd32_30(v) case OpAdd32F: return rewriteValuegeneric_OpAdd32F_0(v) case OpAdd64: return rewriteValuegeneric_OpAdd64_0(v) || rewriteValuegeneric_OpAdd64_10(v) || rewriteValuegeneric_OpAdd64_20(v) || rewriteValuegeneric_OpAdd64_30(v) case OpAdd64F: return rewriteValuegeneric_OpAdd64F_0(v) case OpAdd8: return rewriteValuegeneric_OpAdd8_0(v) || rewriteValuegeneric_OpAdd8_10(v) || rewriteValuegeneric_OpAdd8_20(v) || rewriteValuegeneric_OpAdd8_30(v) case OpAddPtr: return rewriteValuegeneric_OpAddPtr_0(v) case OpAnd16: return rewriteValuegeneric_OpAnd16_0(v) || rewriteValuegeneric_OpAnd16_10(v) || rewriteValuegeneric_OpAnd16_20(v) case OpAnd32: return rewriteValuegeneric_OpAnd32_0(v) || rewriteValuegeneric_OpAnd32_10(v) || rewriteValuegeneric_OpAnd32_20(v) case OpAnd64: return rewriteValuegeneric_OpAnd64_0(v) || rewriteValuegeneric_OpAnd64_10(v) || rewriteValuegeneric_OpAnd64_20(v) case OpAnd8: return rewriteValuegeneric_OpAnd8_0(v) || rewriteValuegeneric_OpAnd8_10(v) || rewriteValuegeneric_OpAnd8_20(v) case OpArraySelect: return rewriteValuegeneric_OpArraySelect_0(v) case OpCom16: return rewriteValuegeneric_OpCom16_0(v) case OpCom32: return rewriteValuegeneric_OpCom32_0(v) case OpCom64: return rewriteValuegeneric_OpCom64_0(v) case OpCom8: return rewriteValuegeneric_OpCom8_0(v) case OpConstInterface: return rewriteValuegeneric_OpConstInterface_0(v) case OpConstSlice: return rewriteValuegeneric_OpConstSlice_0(v) case OpConstString: return rewriteValuegeneric_OpConstString_0(v) case OpConvert: return rewriteValuegeneric_OpConvert_0(v) case OpCvt32Fto32: return rewriteValuegeneric_OpCvt32Fto32_0(v) case OpCvt32Fto64: return rewriteValuegeneric_OpCvt32Fto64_0(v) case OpCvt32Fto64F: return rewriteValuegeneric_OpCvt32Fto64F_0(v) case OpCvt32to32F: return rewriteValuegeneric_OpCvt32to32F_0(v) case OpCvt32to64F: return rewriteValuegeneric_OpCvt32to64F_0(v) case OpCvt64Fto32: return rewriteValuegeneric_OpCvt64Fto32_0(v) case OpCvt64Fto32F: return rewriteValuegeneric_OpCvt64Fto32F_0(v) case OpCvt64Fto64: return rewriteValuegeneric_OpCvt64Fto64_0(v) case OpCvt64to32F: return rewriteValuegeneric_OpCvt64to32F_0(v) case OpCvt64to64F: return rewriteValuegeneric_OpCvt64to64F_0(v) case OpDiv16: return rewriteValuegeneric_OpDiv16_0(v) case OpDiv16u: return rewriteValuegeneric_OpDiv16u_0(v) case OpDiv32: return rewriteValuegeneric_OpDiv32_0(v) case OpDiv32F: return rewriteValuegeneric_OpDiv32F_0(v) case OpDiv32u: return rewriteValuegeneric_OpDiv32u_0(v) case OpDiv64: return rewriteValuegeneric_OpDiv64_0(v) case OpDiv64F: return rewriteValuegeneric_OpDiv64F_0(v) case OpDiv64u: return rewriteValuegeneric_OpDiv64u_0(v) case OpDiv8: return rewriteValuegeneric_OpDiv8_0(v) case OpDiv8u: return rewriteValuegeneric_OpDiv8u_0(v) case OpEq16: return rewriteValuegeneric_OpEq16_0(v) case OpEq32: return rewriteValuegeneric_OpEq32_0(v) case OpEq32F: return rewriteValuegeneric_OpEq32F_0(v) case OpEq64: return rewriteValuegeneric_OpEq64_0(v) case OpEq64F: return rewriteValuegeneric_OpEq64F_0(v) case OpEq8: return rewriteValuegeneric_OpEq8_0(v) case OpEqB: return rewriteValuegeneric_OpEqB_0(v) case OpEqInter: return rewriteValuegeneric_OpEqInter_0(v) case OpEqPtr: return rewriteValuegeneric_OpEqPtr_0(v) || rewriteValuegeneric_OpEqPtr_10(v) || rewriteValuegeneric_OpEqPtr_20(v) case OpEqSlice: return rewriteValuegeneric_OpEqSlice_0(v) case OpGeq16: return rewriteValuegeneric_OpGeq16_0(v) case OpGeq16U: return rewriteValuegeneric_OpGeq16U_0(v) case OpGeq32: return rewriteValuegeneric_OpGeq32_0(v) case OpGeq32F: return rewriteValuegeneric_OpGeq32F_0(v) case OpGeq32U: return rewriteValuegeneric_OpGeq32U_0(v) case OpGeq64: return rewriteValuegeneric_OpGeq64_0(v) case OpGeq64F: return rewriteValuegeneric_OpGeq64F_0(v) case OpGeq64U: return rewriteValuegeneric_OpGeq64U_0(v) case OpGeq8: return rewriteValuegeneric_OpGeq8_0(v) case OpGeq8U: return rewriteValuegeneric_OpGeq8U_0(v) case OpGreater16: return rewriteValuegeneric_OpGreater16_0(v) case OpGreater16U: return rewriteValuegeneric_OpGreater16U_0(v) case OpGreater32: return rewriteValuegeneric_OpGreater32_0(v) case OpGreater32F: return rewriteValuegeneric_OpGreater32F_0(v) case OpGreater32U: return rewriteValuegeneric_OpGreater32U_0(v) case OpGreater64: return rewriteValuegeneric_OpGreater64_0(v) case OpGreater64F: return rewriteValuegeneric_OpGreater64F_0(v) case OpGreater64U: return rewriteValuegeneric_OpGreater64U_0(v) case OpGreater8: return rewriteValuegeneric_OpGreater8_0(v) case OpGreater8U: return rewriteValuegeneric_OpGreater8U_0(v) case OpIMake: return rewriteValuegeneric_OpIMake_0(v) case OpInterCall: return rewriteValuegeneric_OpInterCall_0(v) case OpIsInBounds: return rewriteValuegeneric_OpIsInBounds_0(v) || rewriteValuegeneric_OpIsInBounds_10(v) || rewriteValuegeneric_OpIsInBounds_20(v) || rewriteValuegeneric_OpIsInBounds_30(v) case OpIsNonNil: return rewriteValuegeneric_OpIsNonNil_0(v) case OpIsSliceInBounds: return rewriteValuegeneric_OpIsSliceInBounds_0(v) case OpLeq16: return rewriteValuegeneric_OpLeq16_0(v) case OpLeq16U: return rewriteValuegeneric_OpLeq16U_0(v) case OpLeq32: return rewriteValuegeneric_OpLeq32_0(v) case OpLeq32F: return rewriteValuegeneric_OpLeq32F_0(v) case OpLeq32U: return rewriteValuegeneric_OpLeq32U_0(v) case OpLeq64: return rewriteValuegeneric_OpLeq64_0(v) case OpLeq64F: return rewriteValuegeneric_OpLeq64F_0(v) case OpLeq64U: return rewriteValuegeneric_OpLeq64U_0(v) case OpLeq8: return rewriteValuegeneric_OpLeq8_0(v) case OpLeq8U: return rewriteValuegeneric_OpLeq8U_0(v) case OpLess16: return rewriteValuegeneric_OpLess16_0(v) case OpLess16U: return rewriteValuegeneric_OpLess16U_0(v) case OpLess32: return rewriteValuegeneric_OpLess32_0(v) case OpLess32F: return rewriteValuegeneric_OpLess32F_0(v) case OpLess32U: return rewriteValuegeneric_OpLess32U_0(v) case OpLess64: return rewriteValuegeneric_OpLess64_0(v) case OpLess64F: return rewriteValuegeneric_OpLess64F_0(v) case OpLess64U: return rewriteValuegeneric_OpLess64U_0(v) case OpLess8: return rewriteValuegeneric_OpLess8_0(v) case OpLess8U: return rewriteValuegeneric_OpLess8U_0(v) case OpLoad: return rewriteValuegeneric_OpLoad_0(v) || rewriteValuegeneric_OpLoad_10(v) || rewriteValuegeneric_OpLoad_20(v) case OpLsh16x16: return rewriteValuegeneric_OpLsh16x16_0(v) case OpLsh16x32: return rewriteValuegeneric_OpLsh16x32_0(v) case OpLsh16x64: return rewriteValuegeneric_OpLsh16x64_0(v) case OpLsh16x8: return rewriteValuegeneric_OpLsh16x8_0(v) case OpLsh32x16: return rewriteValuegeneric_OpLsh32x16_0(v) case OpLsh32x32: return rewriteValuegeneric_OpLsh32x32_0(v) case OpLsh32x64: return rewriteValuegeneric_OpLsh32x64_0(v) case OpLsh32x8: return rewriteValuegeneric_OpLsh32x8_0(v) case OpLsh64x16: return rewriteValuegeneric_OpLsh64x16_0(v) case OpLsh64x32: return rewriteValuegeneric_OpLsh64x32_0(v) case OpLsh64x64: return rewriteValuegeneric_OpLsh64x64_0(v) case OpLsh64x8: return rewriteValuegeneric_OpLsh64x8_0(v) case OpLsh8x16: return rewriteValuegeneric_OpLsh8x16_0(v) case OpLsh8x32: return rewriteValuegeneric_OpLsh8x32_0(v) case OpLsh8x64: return rewriteValuegeneric_OpLsh8x64_0(v) case OpLsh8x8: return rewriteValuegeneric_OpLsh8x8_0(v) case OpMod16: return rewriteValuegeneric_OpMod16_0(v) case OpMod16u: return rewriteValuegeneric_OpMod16u_0(v) case OpMod32: return rewriteValuegeneric_OpMod32_0(v) case OpMod32u: return rewriteValuegeneric_OpMod32u_0(v) case OpMod64: return rewriteValuegeneric_OpMod64_0(v) case OpMod64u: return rewriteValuegeneric_OpMod64u_0(v) case OpMod8: return rewriteValuegeneric_OpMod8_0(v) case OpMod8u: return rewriteValuegeneric_OpMod8u_0(v) case OpMove: return rewriteValuegeneric_OpMove_0(v) || rewriteValuegeneric_OpMove_10(v) || rewriteValuegeneric_OpMove_20(v) case OpMul16: return rewriteValuegeneric_OpMul16_0(v) || rewriteValuegeneric_OpMul16_10(v) case OpMul32: return rewriteValuegeneric_OpMul32_0(v) || rewriteValuegeneric_OpMul32_10(v) case OpMul32F: return rewriteValuegeneric_OpMul32F_0(v) case OpMul64: return rewriteValuegeneric_OpMul64_0(v) || rewriteValuegeneric_OpMul64_10(v) case OpMul64F: return rewriteValuegeneric_OpMul64F_0(v) case OpMul8: return rewriteValuegeneric_OpMul8_0(v) || rewriteValuegeneric_OpMul8_10(v) case OpNeg16: return rewriteValuegeneric_OpNeg16_0(v) case OpNeg32: return rewriteValuegeneric_OpNeg32_0(v) case OpNeg32F: return rewriteValuegeneric_OpNeg32F_0(v) case OpNeg64: return rewriteValuegeneric_OpNeg64_0(v) case OpNeg64F: return rewriteValuegeneric_OpNeg64F_0(v) case OpNeg8: return rewriteValuegeneric_OpNeg8_0(v) case OpNeq16: return rewriteValuegeneric_OpNeq16_0(v) case OpNeq32: return rewriteValuegeneric_OpNeq32_0(v) case OpNeq32F: return rewriteValuegeneric_OpNeq32F_0(v) case OpNeq64: return rewriteValuegeneric_OpNeq64_0(v) case OpNeq64F: return rewriteValuegeneric_OpNeq64F_0(v) case OpNeq8: return rewriteValuegeneric_OpNeq8_0(v) case OpNeqB: return rewriteValuegeneric_OpNeqB_0(v) case OpNeqInter: return rewriteValuegeneric_OpNeqInter_0(v) case OpNeqPtr: return rewriteValuegeneric_OpNeqPtr_0(v) || rewriteValuegeneric_OpNeqPtr_10(v) || rewriteValuegeneric_OpNeqPtr_20(v) case OpNeqSlice: return rewriteValuegeneric_OpNeqSlice_0(v) case OpNilCheck: return rewriteValuegeneric_OpNilCheck_0(v) case OpNot: return rewriteValuegeneric_OpNot_0(v) || rewriteValuegeneric_OpNot_10(v) || rewriteValuegeneric_OpNot_20(v) || rewriteValuegeneric_OpNot_30(v) || rewriteValuegeneric_OpNot_40(v) case OpOffPtr: return rewriteValuegeneric_OpOffPtr_0(v) case OpOr16: return rewriteValuegeneric_OpOr16_0(v) || rewriteValuegeneric_OpOr16_10(v) || rewriteValuegeneric_OpOr16_20(v) case OpOr32: return rewriteValuegeneric_OpOr32_0(v) || rewriteValuegeneric_OpOr32_10(v) || rewriteValuegeneric_OpOr32_20(v) case OpOr64: return rewriteValuegeneric_OpOr64_0(v) || rewriteValuegeneric_OpOr64_10(v) || rewriteValuegeneric_OpOr64_20(v) case OpOr8: return rewriteValuegeneric_OpOr8_0(v) || rewriteValuegeneric_OpOr8_10(v) || rewriteValuegeneric_OpOr8_20(v) case OpPhi: return rewriteValuegeneric_OpPhi_0(v) case OpPtrIndex: return rewriteValuegeneric_OpPtrIndex_0(v) case OpRound32F: return rewriteValuegeneric_OpRound32F_0(v) case OpRound64F: return rewriteValuegeneric_OpRound64F_0(v) case OpRsh16Ux16: return rewriteValuegeneric_OpRsh16Ux16_0(v) case OpRsh16Ux32: return rewriteValuegeneric_OpRsh16Ux32_0(v) case OpRsh16Ux64: return rewriteValuegeneric_OpRsh16Ux64_0(v) case OpRsh16Ux8: return rewriteValuegeneric_OpRsh16Ux8_0(v) case OpRsh16x16: return rewriteValuegeneric_OpRsh16x16_0(v) case OpRsh16x32: return rewriteValuegeneric_OpRsh16x32_0(v) case OpRsh16x64: return rewriteValuegeneric_OpRsh16x64_0(v) case OpRsh16x8: return rewriteValuegeneric_OpRsh16x8_0(v) case OpRsh32Ux16: return rewriteValuegeneric_OpRsh32Ux16_0(v) case OpRsh32Ux32: return rewriteValuegeneric_OpRsh32Ux32_0(v) case OpRsh32Ux64: return rewriteValuegeneric_OpRsh32Ux64_0(v) case OpRsh32Ux8: return rewriteValuegeneric_OpRsh32Ux8_0(v) case OpRsh32x16: return rewriteValuegeneric_OpRsh32x16_0(v) case OpRsh32x32: return rewriteValuegeneric_OpRsh32x32_0(v) case OpRsh32x64: return rewriteValuegeneric_OpRsh32x64_0(v) case OpRsh32x8: return rewriteValuegeneric_OpRsh32x8_0(v) case OpRsh64Ux16: return rewriteValuegeneric_OpRsh64Ux16_0(v) case OpRsh64Ux32: return rewriteValuegeneric_OpRsh64Ux32_0(v) case OpRsh64Ux64: return rewriteValuegeneric_OpRsh64Ux64_0(v) case OpRsh64Ux8: return rewriteValuegeneric_OpRsh64Ux8_0(v) case OpRsh64x16: return rewriteValuegeneric_OpRsh64x16_0(v) case OpRsh64x32: return rewriteValuegeneric_OpRsh64x32_0(v) case OpRsh64x64: return rewriteValuegeneric_OpRsh64x64_0(v) case OpRsh64x8: return rewriteValuegeneric_OpRsh64x8_0(v) case OpRsh8Ux16: return rewriteValuegeneric_OpRsh8Ux16_0(v) case OpRsh8Ux32: return rewriteValuegeneric_OpRsh8Ux32_0(v) case OpRsh8Ux64: return rewriteValuegeneric_OpRsh8Ux64_0(v) case OpRsh8Ux8: return rewriteValuegeneric_OpRsh8Ux8_0(v) case OpRsh8x16: return rewriteValuegeneric_OpRsh8x16_0(v) case OpRsh8x32: return rewriteValuegeneric_OpRsh8x32_0(v) case OpRsh8x64: return rewriteValuegeneric_OpRsh8x64_0(v) case OpRsh8x8: return rewriteValuegeneric_OpRsh8x8_0(v) case OpSignExt16to32: return rewriteValuegeneric_OpSignExt16to32_0(v) case OpSignExt16to64: return rewriteValuegeneric_OpSignExt16to64_0(v) case OpSignExt32to64: return rewriteValuegeneric_OpSignExt32to64_0(v) case OpSignExt8to16: return rewriteValuegeneric_OpSignExt8to16_0(v) case OpSignExt8to32: return rewriteValuegeneric_OpSignExt8to32_0(v) case OpSignExt8to64: return rewriteValuegeneric_OpSignExt8to64_0(v) case OpSliceCap: return rewriteValuegeneric_OpSliceCap_0(v) case OpSliceLen: return rewriteValuegeneric_OpSliceLen_0(v) case OpSlicePtr: return rewriteValuegeneric_OpSlicePtr_0(v) case OpSlicemask: return rewriteValuegeneric_OpSlicemask_0(v) case OpSqrt: return rewriteValuegeneric_OpSqrt_0(v) case OpStaticCall: return rewriteValuegeneric_OpStaticCall_0(v) case OpStore: return rewriteValuegeneric_OpStore_0(v) || rewriteValuegeneric_OpStore_10(v) || rewriteValuegeneric_OpStore_20(v) case OpStringLen: return rewriteValuegeneric_OpStringLen_0(v) case OpStringPtr: return rewriteValuegeneric_OpStringPtr_0(v) case OpStructSelect: return rewriteValuegeneric_OpStructSelect_0(v) || rewriteValuegeneric_OpStructSelect_10(v) case OpSub16: return rewriteValuegeneric_OpSub16_0(v) || rewriteValuegeneric_OpSub16_10(v) case OpSub32: return rewriteValuegeneric_OpSub32_0(v) || rewriteValuegeneric_OpSub32_10(v) case OpSub32F: return rewriteValuegeneric_OpSub32F_0(v) case OpSub64: return rewriteValuegeneric_OpSub64_0(v) || rewriteValuegeneric_OpSub64_10(v) case OpSub64F: return rewriteValuegeneric_OpSub64F_0(v) case OpSub8: return rewriteValuegeneric_OpSub8_0(v) || rewriteValuegeneric_OpSub8_10(v) case OpTrunc16to8: return rewriteValuegeneric_OpTrunc16to8_0(v) case OpTrunc32to16: return rewriteValuegeneric_OpTrunc32to16_0(v) case OpTrunc32to8: return rewriteValuegeneric_OpTrunc32to8_0(v) case OpTrunc64to16: return rewriteValuegeneric_OpTrunc64to16_0(v) case OpTrunc64to32: return rewriteValuegeneric_OpTrunc64to32_0(v) case OpTrunc64to8: return rewriteValuegeneric_OpTrunc64to8_0(v) case OpXor16: return rewriteValuegeneric_OpXor16_0(v) || rewriteValuegeneric_OpXor16_10(v) case OpXor32: return rewriteValuegeneric_OpXor32_0(v) || rewriteValuegeneric_OpXor32_10(v) case OpXor64: return rewriteValuegeneric_OpXor64_0(v) || rewriteValuegeneric_OpXor64_10(v) case OpXor8: return rewriteValuegeneric_OpXor8_0(v) || rewriteValuegeneric_OpXor8_10(v) case OpZero: return rewriteValuegeneric_OpZero_0(v) case OpZeroExt16to32: return rewriteValuegeneric_OpZeroExt16to32_0(v) case OpZeroExt16to64: return rewriteValuegeneric_OpZeroExt16to64_0(v) case OpZeroExt32to64: return rewriteValuegeneric_OpZeroExt32to64_0(v) case OpZeroExt8to16: return rewriteValuegeneric_OpZeroExt8to16_0(v) case OpZeroExt8to32: return rewriteValuegeneric_OpZeroExt8to32_0(v) case OpZeroExt8to64: return rewriteValuegeneric_OpZeroExt8to64_0(v) } return false } func rewriteValuegeneric_OpAdd16_0(v *Value) bool { b := v.Block _ = b // match: (Add16 (Const16 [c]) (Const16 [d])) // cond: // result: (Const16 [int64(int16(c+d))]) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst16 { break } c := v_0.AuxInt v_1 := v.Args[1] if v_1.Op != OpConst16 { break } d := v_1.AuxInt v.reset(OpConst16) v.AuxInt = int64(int16(c + d)) return true } // match: (Add16 (Const16 [d]) (Const16 [c])) // cond: // result: (Const16 [int64(int16(c+d))]) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst16 { break } d := v_0.AuxInt v_1 := v.Args[1] if v_1.Op != OpConst16 { break } c := v_1.AuxInt v.reset(OpConst16) v.AuxInt = int64(int16(c + d)) return true } // match: (Add16
(Mul16 x y) (Mul16 x z)) // cond: // result: (Mul16 x (Add16
y z)) for { t := v.Type _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpMul16 { break } _ = v_0.Args[1] x := v_0.Args[0] y := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpMul16 { break } _ = v_1.Args[1] if x != v_1.Args[0] { break } z := v_1.Args[1] v.reset(OpMul16) v.AddArg(x) v0 := b.NewValue0(v.Pos, OpAdd16, t) v0.AddArg(y) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add16
(Mul16 y x) (Mul16 x z)) // cond: // result: (Mul16 x (Add16
y z)) for { t := v.Type _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpMul16 { break } _ = v_0.Args[1] y := v_0.Args[0] x := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpMul16 { break } _ = v_1.Args[1] if x != v_1.Args[0] { break } z := v_1.Args[1] v.reset(OpMul16) v.AddArg(x) v0 := b.NewValue0(v.Pos, OpAdd16, t) v0.AddArg(y) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add16
(Mul16 x y) (Mul16 z x)) // cond: // result: (Mul16 x (Add16
y z)) for { t := v.Type _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpMul16 { break } _ = v_0.Args[1] x := v_0.Args[0] y := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpMul16 { break } _ = v_1.Args[1] z := v_1.Args[0] if x != v_1.Args[1] { break } v.reset(OpMul16) v.AddArg(x) v0 := b.NewValue0(v.Pos, OpAdd16, t) v0.AddArg(y) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add16
(Mul16 y x) (Mul16 z x)) // cond: // result: (Mul16 x (Add16
y z)) for { t := v.Type _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpMul16 { break } _ = v_0.Args[1] y := v_0.Args[0] x := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpMul16 { break } _ = v_1.Args[1] z := v_1.Args[0] if x != v_1.Args[1] { break } v.reset(OpMul16) v.AddArg(x) v0 := b.NewValue0(v.Pos, OpAdd16, t) v0.AddArg(y) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add16
(Mul16 x z) (Mul16 x y)) // cond: // result: (Mul16 x (Add16
y z)) for { t := v.Type _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpMul16 { break } _ = v_0.Args[1] x := v_0.Args[0] z := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpMul16 { break } _ = v_1.Args[1] if x != v_1.Args[0] { break } y := v_1.Args[1] v.reset(OpMul16) v.AddArg(x) v0 := b.NewValue0(v.Pos, OpAdd16, t) v0.AddArg(y) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add16
(Mul16 z x) (Mul16 x y)) // cond: // result: (Mul16 x (Add16
y z)) for { t := v.Type _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpMul16 { break } _ = v_0.Args[1] z := v_0.Args[0] x := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpMul16 { break } _ = v_1.Args[1] if x != v_1.Args[0] { break } y := v_1.Args[1] v.reset(OpMul16) v.AddArg(x) v0 := b.NewValue0(v.Pos, OpAdd16, t) v0.AddArg(y) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add16
(Mul16 x z) (Mul16 y x)) // cond: // result: (Mul16 x (Add16
y z)) for { t := v.Type _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpMul16 { break } _ = v_0.Args[1] x := v_0.Args[0] z := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpMul16 { break } _ = v_1.Args[1] y := v_1.Args[0] if x != v_1.Args[1] { break } v.reset(OpMul16) v.AddArg(x) v0 := b.NewValue0(v.Pos, OpAdd16, t) v0.AddArg(y) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add16
(Mul16 z x) (Mul16 y x)) // cond: // result: (Mul16 x (Add16
y z)) for { t := v.Type _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpMul16 { break } _ = v_0.Args[1] z := v_0.Args[0] x := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpMul16 { break } _ = v_1.Args[1] y := v_1.Args[0] if x != v_1.Args[1] { break } v.reset(OpMul16) v.AddArg(x) v0 := b.NewValue0(v.Pos, OpAdd16, t) v0.AddArg(y) v0.AddArg(z) v.AddArg(v0) return true } return false } func rewriteValuegeneric_OpAdd16_10(v *Value) bool { b := v.Block _ = b // match: (Add16 (Const16 [0]) x) // cond: // result: x for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst16 { break } if v_0.AuxInt != 0 { break } x := v.Args[1] v.reset(OpCopy) v.Type = x.Type v.AddArg(x) return true } // match: (Add16 x (Const16 [0])) // cond: // result: x for { _ = v.Args[1] x := v.Args[0] v_1 := v.Args[1] if v_1.Op != OpConst16 { break } if v_1.AuxInt != 0 { break } v.reset(OpCopy) v.Type = x.Type v.AddArg(x) return true } // match: (Add16 (Const16 [1]) (Com16 x)) // cond: // result: (Neg16 x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst16 { break } if v_0.AuxInt != 1 { break } v_1 := v.Args[1] if v_1.Op != OpCom16 { break } x := v_1.Args[0] v.reset(OpNeg16) v.AddArg(x) return true } // match: (Add16 (Com16 x) (Const16 [1])) // cond: // result: (Neg16 x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpCom16 { break } x := v_0.Args[0] v_1 := v.Args[1] if v_1.Op != OpConst16 { break } if v_1.AuxInt != 1 { break } v.reset(OpNeg16) v.AddArg(x) return true } // match: (Add16 (Add16 i:(Const16
) z) x) // cond: (z.Op != OpConst16 && x.Op != OpConst16) // result: (Add16 i (Add16
z x)) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpAdd16 { break } _ = v_0.Args[1] i := v_0.Args[0] if i.Op != OpConst16 { break } t := i.Type z := v_0.Args[1] x := v.Args[1] if !(z.Op != OpConst16 && x.Op != OpConst16) { break } v.reset(OpAdd16) v.AddArg(i) v0 := b.NewValue0(v.Pos, OpAdd16, t) v0.AddArg(z) v0.AddArg(x) v.AddArg(v0) return true } // match: (Add16 (Add16 z i:(Const16
)) x) // cond: (z.Op != OpConst16 && x.Op != OpConst16) // result: (Add16 i (Add16
z x)) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpAdd16 { break } _ = v_0.Args[1] z := v_0.Args[0] i := v_0.Args[1] if i.Op != OpConst16 { break } t := i.Type x := v.Args[1] if !(z.Op != OpConst16 && x.Op != OpConst16) { break } v.reset(OpAdd16) v.AddArg(i) v0 := b.NewValue0(v.Pos, OpAdd16, t) v0.AddArg(z) v0.AddArg(x) v.AddArg(v0) return true } // match: (Add16 x (Add16 i:(Const16
) z)) // cond: (z.Op != OpConst16 && x.Op != OpConst16) // result: (Add16 i (Add16
z x)) for { _ = v.Args[1] x := v.Args[0] v_1 := v.Args[1] if v_1.Op != OpAdd16 { break } _ = v_1.Args[1] i := v_1.Args[0] if i.Op != OpConst16 { break } t := i.Type z := v_1.Args[1] if !(z.Op != OpConst16 && x.Op != OpConst16) { break } v.reset(OpAdd16) v.AddArg(i) v0 := b.NewValue0(v.Pos, OpAdd16, t) v0.AddArg(z) v0.AddArg(x) v.AddArg(v0) return true } // match: (Add16 x (Add16 z i:(Const16
))) // cond: (z.Op != OpConst16 && x.Op != OpConst16) // result: (Add16 i (Add16
z x)) for { _ = v.Args[1] x := v.Args[0] v_1 := v.Args[1] if v_1.Op != OpAdd16 { break } _ = v_1.Args[1] z := v_1.Args[0] i := v_1.Args[1] if i.Op != OpConst16 { break } t := i.Type if !(z.Op != OpConst16 && x.Op != OpConst16) { break } v.reset(OpAdd16) v.AddArg(i) v0 := b.NewValue0(v.Pos, OpAdd16, t) v0.AddArg(z) v0.AddArg(x) v.AddArg(v0) return true } // match: (Add16 (Sub16 i:(Const16
) z) x) // cond: (z.Op != OpConst16 && x.Op != OpConst16) // result: (Add16 i (Sub16
x z)) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpSub16 { break } _ = v_0.Args[1] i := v_0.Args[0] if i.Op != OpConst16 { break } t := i.Type z := v_0.Args[1] x := v.Args[1] if !(z.Op != OpConst16 && x.Op != OpConst16) { break } v.reset(OpAdd16) v.AddArg(i) v0 := b.NewValue0(v.Pos, OpSub16, t) v0.AddArg(x) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add16 x (Sub16 i:(Const16
) z)) // cond: (z.Op != OpConst16 && x.Op != OpConst16) // result: (Add16 i (Sub16
x z)) for { _ = v.Args[1] x := v.Args[0] v_1 := v.Args[1] if v_1.Op != OpSub16 { break } _ = v_1.Args[1] i := v_1.Args[0] if i.Op != OpConst16 { break } t := i.Type z := v_1.Args[1] if !(z.Op != OpConst16 && x.Op != OpConst16) { break } v.reset(OpAdd16) v.AddArg(i) v0 := b.NewValue0(v.Pos, OpSub16, t) v0.AddArg(x) v0.AddArg(z) v.AddArg(v0) return true } return false } func rewriteValuegeneric_OpAdd16_20(v *Value) bool { b := v.Block _ = b // match: (Add16 x (Sub16 i:(Const16
) z)) // cond: (z.Op != OpConst16 && x.Op != OpConst16) // result: (Add16 i (Sub16
x z)) for { _ = v.Args[1] x := v.Args[0] v_1 := v.Args[1] if v_1.Op != OpSub16 { break } _ = v_1.Args[1] i := v_1.Args[0] if i.Op != OpConst16 { break } t := i.Type z := v_1.Args[1] if !(z.Op != OpConst16 && x.Op != OpConst16) { break } v.reset(OpAdd16) v.AddArg(i) v0 := b.NewValue0(v.Pos, OpSub16, t) v0.AddArg(x) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add16 (Sub16 i:(Const16
) z) x) // cond: (z.Op != OpConst16 && x.Op != OpConst16) // result: (Add16 i (Sub16
x z)) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpSub16 { break } _ = v_0.Args[1] i := v_0.Args[0] if i.Op != OpConst16 { break } t := i.Type z := v_0.Args[1] x := v.Args[1] if !(z.Op != OpConst16 && x.Op != OpConst16) { break } v.reset(OpAdd16) v.AddArg(i) v0 := b.NewValue0(v.Pos, OpSub16, t) v0.AddArg(x) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add16 (Sub16 z i:(Const16
)) x) // cond: (z.Op != OpConst16 && x.Op != OpConst16) // result: (Sub16 (Add16
x z) i) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpSub16 { break } _ = v_0.Args[1] z := v_0.Args[0] i := v_0.Args[1] if i.Op != OpConst16 { break } t := i.Type x := v.Args[1] if !(z.Op != OpConst16 && x.Op != OpConst16) { break } v.reset(OpSub16) v0 := b.NewValue0(v.Pos, OpAdd16, t) v0.AddArg(x) v0.AddArg(z) v.AddArg(v0) v.AddArg(i) return true } // match: (Add16 x (Sub16 z i:(Const16
))) // cond: (z.Op != OpConst16 && x.Op != OpConst16) // result: (Sub16 (Add16
x z) i) for { _ = v.Args[1] x := v.Args[0] v_1 := v.Args[1] if v_1.Op != OpSub16 { break } _ = v_1.Args[1] z := v_1.Args[0] i := v_1.Args[1] if i.Op != OpConst16 { break } t := i.Type if !(z.Op != OpConst16 && x.Op != OpConst16) { break } v.reset(OpSub16) v0 := b.NewValue0(v.Pos, OpAdd16, t) v0.AddArg(x) v0.AddArg(z) v.AddArg(v0) v.AddArg(i) return true } // match: (Add16 x (Sub16 z i:(Const16
))) // cond: (z.Op != OpConst16 && x.Op != OpConst16) // result: (Sub16 (Add16
x z) i) for { _ = v.Args[1] x := v.Args[0] v_1 := v.Args[1] if v_1.Op != OpSub16 { break } _ = v_1.Args[1] z := v_1.Args[0] i := v_1.Args[1] if i.Op != OpConst16 { break } t := i.Type if !(z.Op != OpConst16 && x.Op != OpConst16) { break } v.reset(OpSub16) v0 := b.NewValue0(v.Pos, OpAdd16, t) v0.AddArg(x) v0.AddArg(z) v.AddArg(v0) v.AddArg(i) return true } // match: (Add16 (Sub16 z i:(Const16
)) x) // cond: (z.Op != OpConst16 && x.Op != OpConst16) // result: (Sub16 (Add16
x z) i) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpSub16 { break } _ = v_0.Args[1] z := v_0.Args[0] i := v_0.Args[1] if i.Op != OpConst16 { break } t := i.Type x := v.Args[1] if !(z.Op != OpConst16 && x.Op != OpConst16) { break } v.reset(OpSub16) v0 := b.NewValue0(v.Pos, OpAdd16, t) v0.AddArg(x) v0.AddArg(z) v.AddArg(v0) v.AddArg(i) return true } // match: (Add16 (Const16
[c]) (Add16 (Const16
[d]) x)) // cond: // result: (Add16 (Const16
[int64(int16(c+d))]) x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst16 { break } t := v_0.Type c := v_0.AuxInt v_1 := v.Args[1] if v_1.Op != OpAdd16 { break } _ = v_1.Args[1] v_1_0 := v_1.Args[0] if v_1_0.Op != OpConst16 { break } if v_1_0.Type != t { break } d := v_1_0.AuxInt x := v_1.Args[1] v.reset(OpAdd16) v0 := b.NewValue0(v.Pos, OpConst16, t) v0.AuxInt = int64(int16(c + d)) v.AddArg(v0) v.AddArg(x) return true } // match: (Add16 (Const16
[c]) (Add16 x (Const16
[d]))) // cond: // result: (Add16 (Const16
[int64(int16(c+d))]) x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst16 { break } t := v_0.Type c := v_0.AuxInt v_1 := v.Args[1] if v_1.Op != OpAdd16 { break } _ = v_1.Args[1] x := v_1.Args[0] v_1_1 := v_1.Args[1] if v_1_1.Op != OpConst16 { break } if v_1_1.Type != t { break } d := v_1_1.AuxInt v.reset(OpAdd16) v0 := b.NewValue0(v.Pos, OpConst16, t) v0.AuxInt = int64(int16(c + d)) v.AddArg(v0) v.AddArg(x) return true } // match: (Add16 (Add16 (Const16
[d]) x) (Const16
[c])) // cond: // result: (Add16 (Const16
[int64(int16(c+d))]) x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpAdd16 { break } _ = v_0.Args[1] v_0_0 := v_0.Args[0] if v_0_0.Op != OpConst16 { break } t := v_0_0.Type d := v_0_0.AuxInt x := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpConst16 { break } if v_1.Type != t { break } c := v_1.AuxInt v.reset(OpAdd16) v0 := b.NewValue0(v.Pos, OpConst16, t) v0.AuxInt = int64(int16(c + d)) v.AddArg(v0) v.AddArg(x) return true } // match: (Add16 (Add16 x (Const16
[d])) (Const16
[c])) // cond: // result: (Add16 (Const16
[int64(int16(c+d))]) x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpAdd16 { break } _ = v_0.Args[1] x := v_0.Args[0] v_0_1 := v_0.Args[1] if v_0_1.Op != OpConst16 { break } t := v_0_1.Type d := v_0_1.AuxInt v_1 := v.Args[1] if v_1.Op != OpConst16 { break } if v_1.Type != t { break } c := v_1.AuxInt v.reset(OpAdd16) v0 := b.NewValue0(v.Pos, OpConst16, t) v0.AuxInt = int64(int16(c + d)) v.AddArg(v0) v.AddArg(x) return true } return false } func rewriteValuegeneric_OpAdd16_30(v *Value) bool { b := v.Block _ = b // match: (Add16 (Const16
[c]) (Sub16 (Const16
[d]) x)) // cond: // result: (Sub16 (Const16
[int64(int16(c+d))]) x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst16 { break } t := v_0.Type c := v_0.AuxInt v_1 := v.Args[1] if v_1.Op != OpSub16 { break } _ = v_1.Args[1] v_1_0 := v_1.Args[0] if v_1_0.Op != OpConst16 { break } if v_1_0.Type != t { break } d := v_1_0.AuxInt x := v_1.Args[1] v.reset(OpSub16) v0 := b.NewValue0(v.Pos, OpConst16, t) v0.AuxInt = int64(int16(c + d)) v.AddArg(v0) v.AddArg(x) return true } // match: (Add16 (Sub16 (Const16
[d]) x) (Const16
[c])) // cond: // result: (Sub16 (Const16
[int64(int16(c+d))]) x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpSub16 { break } _ = v_0.Args[1] v_0_0 := v_0.Args[0] if v_0_0.Op != OpConst16 { break } t := v_0_0.Type d := v_0_0.AuxInt x := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpConst16 { break } if v_1.Type != t { break } c := v_1.AuxInt v.reset(OpSub16) v0 := b.NewValue0(v.Pos, OpConst16, t) v0.AuxInt = int64(int16(c + d)) v.AddArg(v0) v.AddArg(x) return true } // match: (Add16 (Const16
[c]) (Sub16 x (Const16
[d]))) // cond: // result: (Add16 (Const16
[int64(int16(c-d))]) x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst16 { break } t := v_0.Type c := v_0.AuxInt v_1 := v.Args[1] if v_1.Op != OpSub16 { break } _ = v_1.Args[1] x := v_1.Args[0] v_1_1 := v_1.Args[1] if v_1_1.Op != OpConst16 { break } if v_1_1.Type != t { break } d := v_1_1.AuxInt v.reset(OpAdd16) v0 := b.NewValue0(v.Pos, OpConst16, t) v0.AuxInt = int64(int16(c - d)) v.AddArg(v0) v.AddArg(x) return true } // match: (Add16 (Sub16 x (Const16
[d])) (Const16
[c])) // cond: // result: (Add16 (Const16
[int64(int16(c-d))]) x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpSub16 { break } _ = v_0.Args[1] x := v_0.Args[0] v_0_1 := v_0.Args[1] if v_0_1.Op != OpConst16 { break } t := v_0_1.Type d := v_0_1.AuxInt v_1 := v.Args[1] if v_1.Op != OpConst16 { break } if v_1.Type != t { break } c := v_1.AuxInt v.reset(OpAdd16) v0 := b.NewValue0(v.Pos, OpConst16, t) v0.AuxInt = int64(int16(c - d)) v.AddArg(v0) v.AddArg(x) return true } return false } func rewriteValuegeneric_OpAdd32_0(v *Value) bool { b := v.Block _ = b // match: (Add32 (Const32 [c]) (Const32 [d])) // cond: // result: (Const32 [int64(int32(c+d))]) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst32 { break } c := v_0.AuxInt v_1 := v.Args[1] if v_1.Op != OpConst32 { break } d := v_1.AuxInt v.reset(OpConst32) v.AuxInt = int64(int32(c + d)) return true } // match: (Add32 (Const32 [d]) (Const32 [c])) // cond: // result: (Const32 [int64(int32(c+d))]) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst32 { break } d := v_0.AuxInt v_1 := v.Args[1] if v_1.Op != OpConst32 { break } c := v_1.AuxInt v.reset(OpConst32) v.AuxInt = int64(int32(c + d)) return true } // match: (Add32
(Mul32 x y) (Mul32 x z)) // cond: // result: (Mul32 x (Add32
y z)) for { t := v.Type _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpMul32 { break } _ = v_0.Args[1] x := v_0.Args[0] y := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpMul32 { break } _ = v_1.Args[1] if x != v_1.Args[0] { break } z := v_1.Args[1] v.reset(OpMul32) v.AddArg(x) v0 := b.NewValue0(v.Pos, OpAdd32, t) v0.AddArg(y) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add32
(Mul32 y x) (Mul32 x z)) // cond: // result: (Mul32 x (Add32
y z)) for { t := v.Type _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpMul32 { break } _ = v_0.Args[1] y := v_0.Args[0] x := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpMul32 { break } _ = v_1.Args[1] if x != v_1.Args[0] { break } z := v_1.Args[1] v.reset(OpMul32) v.AddArg(x) v0 := b.NewValue0(v.Pos, OpAdd32, t) v0.AddArg(y) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add32
(Mul32 x y) (Mul32 z x)) // cond: // result: (Mul32 x (Add32
y z)) for { t := v.Type _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpMul32 { break } _ = v_0.Args[1] x := v_0.Args[0] y := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpMul32 { break } _ = v_1.Args[1] z := v_1.Args[0] if x != v_1.Args[1] { break } v.reset(OpMul32) v.AddArg(x) v0 := b.NewValue0(v.Pos, OpAdd32, t) v0.AddArg(y) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add32
(Mul32 y x) (Mul32 z x)) // cond: // result: (Mul32 x (Add32
y z)) for { t := v.Type _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpMul32 { break } _ = v_0.Args[1] y := v_0.Args[0] x := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpMul32 { break } _ = v_1.Args[1] z := v_1.Args[0] if x != v_1.Args[1] { break } v.reset(OpMul32) v.AddArg(x) v0 := b.NewValue0(v.Pos, OpAdd32, t) v0.AddArg(y) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add32
(Mul32 x z) (Mul32 x y)) // cond: // result: (Mul32 x (Add32
y z)) for { t := v.Type _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpMul32 { break } _ = v_0.Args[1] x := v_0.Args[0] z := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpMul32 { break } _ = v_1.Args[1] if x != v_1.Args[0] { break } y := v_1.Args[1] v.reset(OpMul32) v.AddArg(x) v0 := b.NewValue0(v.Pos, OpAdd32, t) v0.AddArg(y) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add32
(Mul32 z x) (Mul32 x y)) // cond: // result: (Mul32 x (Add32
y z)) for { t := v.Type _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpMul32 { break } _ = v_0.Args[1] z := v_0.Args[0] x := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpMul32 { break } _ = v_1.Args[1] if x != v_1.Args[0] { break } y := v_1.Args[1] v.reset(OpMul32) v.AddArg(x) v0 := b.NewValue0(v.Pos, OpAdd32, t) v0.AddArg(y) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add32
(Mul32 x z) (Mul32 y x)) // cond: // result: (Mul32 x (Add32
y z)) for { t := v.Type _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpMul32 { break } _ = v_0.Args[1] x := v_0.Args[0] z := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpMul32 { break } _ = v_1.Args[1] y := v_1.Args[0] if x != v_1.Args[1] { break } v.reset(OpMul32) v.AddArg(x) v0 := b.NewValue0(v.Pos, OpAdd32, t) v0.AddArg(y) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add32
(Mul32 z x) (Mul32 y x)) // cond: // result: (Mul32 x (Add32
y z)) for { t := v.Type _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpMul32 { break } _ = v_0.Args[1] z := v_0.Args[0] x := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpMul32 { break } _ = v_1.Args[1] y := v_1.Args[0] if x != v_1.Args[1] { break } v.reset(OpMul32) v.AddArg(x) v0 := b.NewValue0(v.Pos, OpAdd32, t) v0.AddArg(y) v0.AddArg(z) v.AddArg(v0) return true } return false } func rewriteValuegeneric_OpAdd32_10(v *Value) bool { b := v.Block _ = b // match: (Add32 (Const32 [0]) x) // cond: // result: x for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst32 { break } if v_0.AuxInt != 0 { break } x := v.Args[1] v.reset(OpCopy) v.Type = x.Type v.AddArg(x) return true } // match: (Add32 x (Const32 [0])) // cond: // result: x for { _ = v.Args[1] x := v.Args[0] v_1 := v.Args[1] if v_1.Op != OpConst32 { break } if v_1.AuxInt != 0 { break } v.reset(OpCopy) v.Type = x.Type v.AddArg(x) return true } // match: (Add32 (Const32 [1]) (Com32 x)) // cond: // result: (Neg32 x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst32 { break } if v_0.AuxInt != 1 { break } v_1 := v.Args[1] if v_1.Op != OpCom32 { break } x := v_1.Args[0] v.reset(OpNeg32) v.AddArg(x) return true } // match: (Add32 (Com32 x) (Const32 [1])) // cond: // result: (Neg32 x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpCom32 { break } x := v_0.Args[0] v_1 := v.Args[1] if v_1.Op != OpConst32 { break } if v_1.AuxInt != 1 { break } v.reset(OpNeg32) v.AddArg(x) return true } // match: (Add32 (Add32 i:(Const32
) z) x) // cond: (z.Op != OpConst32 && x.Op != OpConst32) // result: (Add32 i (Add32
z x)) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpAdd32 { break } _ = v_0.Args[1] i := v_0.Args[0] if i.Op != OpConst32 { break } t := i.Type z := v_0.Args[1] x := v.Args[1] if !(z.Op != OpConst32 && x.Op != OpConst32) { break } v.reset(OpAdd32) v.AddArg(i) v0 := b.NewValue0(v.Pos, OpAdd32, t) v0.AddArg(z) v0.AddArg(x) v.AddArg(v0) return true } // match: (Add32 (Add32 z i:(Const32
)) x) // cond: (z.Op != OpConst32 && x.Op != OpConst32) // result: (Add32 i (Add32
z x)) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpAdd32 { break } _ = v_0.Args[1] z := v_0.Args[0] i := v_0.Args[1] if i.Op != OpConst32 { break } t := i.Type x := v.Args[1] if !(z.Op != OpConst32 && x.Op != OpConst32) { break } v.reset(OpAdd32) v.AddArg(i) v0 := b.NewValue0(v.Pos, OpAdd32, t) v0.AddArg(z) v0.AddArg(x) v.AddArg(v0) return true } // match: (Add32 x (Add32 i:(Const32
) z)) // cond: (z.Op != OpConst32 && x.Op != OpConst32) // result: (Add32 i (Add32
z x)) for { _ = v.Args[1] x := v.Args[0] v_1 := v.Args[1] if v_1.Op != OpAdd32 { break } _ = v_1.Args[1] i := v_1.Args[0] if i.Op != OpConst32 { break } t := i.Type z := v_1.Args[1] if !(z.Op != OpConst32 && x.Op != OpConst32) { break } v.reset(OpAdd32) v.AddArg(i) v0 := b.NewValue0(v.Pos, OpAdd32, t) v0.AddArg(z) v0.AddArg(x) v.AddArg(v0) return true } // match: (Add32 x (Add32 z i:(Const32
))) // cond: (z.Op != OpConst32 && x.Op != OpConst32) // result: (Add32 i (Add32
z x)) for { _ = v.Args[1] x := v.Args[0] v_1 := v.Args[1] if v_1.Op != OpAdd32 { break } _ = v_1.Args[1] z := v_1.Args[0] i := v_1.Args[1] if i.Op != OpConst32 { break } t := i.Type if !(z.Op != OpConst32 && x.Op != OpConst32) { break } v.reset(OpAdd32) v.AddArg(i) v0 := b.NewValue0(v.Pos, OpAdd32, t) v0.AddArg(z) v0.AddArg(x) v.AddArg(v0) return true } // match: (Add32 (Sub32 i:(Const32
) z) x) // cond: (z.Op != OpConst32 && x.Op != OpConst32) // result: (Add32 i (Sub32
x z)) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpSub32 { break } _ = v_0.Args[1] i := v_0.Args[0] if i.Op != OpConst32 { break } t := i.Type z := v_0.Args[1] x := v.Args[1] if !(z.Op != OpConst32 && x.Op != OpConst32) { break } v.reset(OpAdd32) v.AddArg(i) v0 := b.NewValue0(v.Pos, OpSub32, t) v0.AddArg(x) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add32 x (Sub32 i:(Const32
) z)) // cond: (z.Op != OpConst32 && x.Op != OpConst32) // result: (Add32 i (Sub32
x z)) for { _ = v.Args[1] x := v.Args[0] v_1 := v.Args[1] if v_1.Op != OpSub32 { break } _ = v_1.Args[1] i := v_1.Args[0] if i.Op != OpConst32 { break } t := i.Type z := v_1.Args[1] if !(z.Op != OpConst32 && x.Op != OpConst32) { break } v.reset(OpAdd32) v.AddArg(i) v0 := b.NewValue0(v.Pos, OpSub32, t) v0.AddArg(x) v0.AddArg(z) v.AddArg(v0) return true } return false } func rewriteValuegeneric_OpAdd32_20(v *Value) bool { b := v.Block _ = b // match: (Add32 x (Sub32 i:(Const32
) z)) // cond: (z.Op != OpConst32 && x.Op != OpConst32) // result: (Add32 i (Sub32
x z)) for { _ = v.Args[1] x := v.Args[0] v_1 := v.Args[1] if v_1.Op != OpSub32 { break } _ = v_1.Args[1] i := v_1.Args[0] if i.Op != OpConst32 { break } t := i.Type z := v_1.Args[1] if !(z.Op != OpConst32 && x.Op != OpConst32) { break } v.reset(OpAdd32) v.AddArg(i) v0 := b.NewValue0(v.Pos, OpSub32, t) v0.AddArg(x) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add32 (Sub32 i:(Const32
) z) x) // cond: (z.Op != OpConst32 && x.Op != OpConst32) // result: (Add32 i (Sub32
x z)) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpSub32 { break } _ = v_0.Args[1] i := v_0.Args[0] if i.Op != OpConst32 { break } t := i.Type z := v_0.Args[1] x := v.Args[1] if !(z.Op != OpConst32 && x.Op != OpConst32) { break } v.reset(OpAdd32) v.AddArg(i) v0 := b.NewValue0(v.Pos, OpSub32, t) v0.AddArg(x) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add32 (Sub32 z i:(Const32
)) x) // cond: (z.Op != OpConst32 && x.Op != OpConst32) // result: (Sub32 (Add32
x z) i) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpSub32 { break } _ = v_0.Args[1] z := v_0.Args[0] i := v_0.Args[1] if i.Op != OpConst32 { break } t := i.Type x := v.Args[1] if !(z.Op != OpConst32 && x.Op != OpConst32) { break } v.reset(OpSub32) v0 := b.NewValue0(v.Pos, OpAdd32, t) v0.AddArg(x) v0.AddArg(z) v.AddArg(v0) v.AddArg(i) return true } // match: (Add32 x (Sub32 z i:(Const32
))) // cond: (z.Op != OpConst32 && x.Op != OpConst32) // result: (Sub32 (Add32
x z) i) for { _ = v.Args[1] x := v.Args[0] v_1 := v.Args[1] if v_1.Op != OpSub32 { break } _ = v_1.Args[1] z := v_1.Args[0] i := v_1.Args[1] if i.Op != OpConst32 { break } t := i.Type if !(z.Op != OpConst32 && x.Op != OpConst32) { break } v.reset(OpSub32) v0 := b.NewValue0(v.Pos, OpAdd32, t) v0.AddArg(x) v0.AddArg(z) v.AddArg(v0) v.AddArg(i) return true } // match: (Add32 x (Sub32 z i:(Const32
))) // cond: (z.Op != OpConst32 && x.Op != OpConst32) // result: (Sub32 (Add32
x z) i) for { _ = v.Args[1] x := v.Args[0] v_1 := v.Args[1] if v_1.Op != OpSub32 { break } _ = v_1.Args[1] z := v_1.Args[0] i := v_1.Args[1] if i.Op != OpConst32 { break } t := i.Type if !(z.Op != OpConst32 && x.Op != OpConst32) { break } v.reset(OpSub32) v0 := b.NewValue0(v.Pos, OpAdd32, t) v0.AddArg(x) v0.AddArg(z) v.AddArg(v0) v.AddArg(i) return true } // match: (Add32 (Sub32 z i:(Const32
)) x) // cond: (z.Op != OpConst32 && x.Op != OpConst32) // result: (Sub32 (Add32
x z) i) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpSub32 { break } _ = v_0.Args[1] z := v_0.Args[0] i := v_0.Args[1] if i.Op != OpConst32 { break } t := i.Type x := v.Args[1] if !(z.Op != OpConst32 && x.Op != OpConst32) { break } v.reset(OpSub32) v0 := b.NewValue0(v.Pos, OpAdd32, t) v0.AddArg(x) v0.AddArg(z) v.AddArg(v0) v.AddArg(i) return true } // match: (Add32 (Const32
[c]) (Add32 (Const32
[d]) x)) // cond: // result: (Add32 (Const32
[int64(int32(c+d))]) x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst32 { break } t := v_0.Type c := v_0.AuxInt v_1 := v.Args[1] if v_1.Op != OpAdd32 { break } _ = v_1.Args[1] v_1_0 := v_1.Args[0] if v_1_0.Op != OpConst32 { break } if v_1_0.Type != t { break } d := v_1_0.AuxInt x := v_1.Args[1] v.reset(OpAdd32) v0 := b.NewValue0(v.Pos, OpConst32, t) v0.AuxInt = int64(int32(c + d)) v.AddArg(v0) v.AddArg(x) return true } // match: (Add32 (Const32
[c]) (Add32 x (Const32
[d]))) // cond: // result: (Add32 (Const32
[int64(int32(c+d))]) x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst32 { break } t := v_0.Type c := v_0.AuxInt v_1 := v.Args[1] if v_1.Op != OpAdd32 { break } _ = v_1.Args[1] x := v_1.Args[0] v_1_1 := v_1.Args[1] if v_1_1.Op != OpConst32 { break } if v_1_1.Type != t { break } d := v_1_1.AuxInt v.reset(OpAdd32) v0 := b.NewValue0(v.Pos, OpConst32, t) v0.AuxInt = int64(int32(c + d)) v.AddArg(v0) v.AddArg(x) return true } // match: (Add32 (Add32 (Const32
[d]) x) (Const32
[c])) // cond: // result: (Add32 (Const32
[int64(int32(c+d))]) x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpAdd32 { break } _ = v_0.Args[1] v_0_0 := v_0.Args[0] if v_0_0.Op != OpConst32 { break } t := v_0_0.Type d := v_0_0.AuxInt x := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpConst32 { break } if v_1.Type != t { break } c := v_1.AuxInt v.reset(OpAdd32) v0 := b.NewValue0(v.Pos, OpConst32, t) v0.AuxInt = int64(int32(c + d)) v.AddArg(v0) v.AddArg(x) return true } // match: (Add32 (Add32 x (Const32
[d])) (Const32
[c])) // cond: // result: (Add32 (Const32
[int64(int32(c+d))]) x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpAdd32 { break } _ = v_0.Args[1] x := v_0.Args[0] v_0_1 := v_0.Args[1] if v_0_1.Op != OpConst32 { break } t := v_0_1.Type d := v_0_1.AuxInt v_1 := v.Args[1] if v_1.Op != OpConst32 { break } if v_1.Type != t { break } c := v_1.AuxInt v.reset(OpAdd32) v0 := b.NewValue0(v.Pos, OpConst32, t) v0.AuxInt = int64(int32(c + d)) v.AddArg(v0) v.AddArg(x) return true } return false } func rewriteValuegeneric_OpAdd32_30(v *Value) bool { b := v.Block _ = b // match: (Add32 (Const32
[c]) (Sub32 (Const32
[d]) x)) // cond: // result: (Sub32 (Const32
[int64(int32(c+d))]) x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst32 { break } t := v_0.Type c := v_0.AuxInt v_1 := v.Args[1] if v_1.Op != OpSub32 { break } _ = v_1.Args[1] v_1_0 := v_1.Args[0] if v_1_0.Op != OpConst32 { break } if v_1_0.Type != t { break } d := v_1_0.AuxInt x := v_1.Args[1] v.reset(OpSub32) v0 := b.NewValue0(v.Pos, OpConst32, t) v0.AuxInt = int64(int32(c + d)) v.AddArg(v0) v.AddArg(x) return true } // match: (Add32 (Sub32 (Const32
[d]) x) (Const32
[c])) // cond: // result: (Sub32 (Const32
[int64(int32(c+d))]) x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpSub32 { break } _ = v_0.Args[1] v_0_0 := v_0.Args[0] if v_0_0.Op != OpConst32 { break } t := v_0_0.Type d := v_0_0.AuxInt x := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpConst32 { break } if v_1.Type != t { break } c := v_1.AuxInt v.reset(OpSub32) v0 := b.NewValue0(v.Pos, OpConst32, t) v0.AuxInt = int64(int32(c + d)) v.AddArg(v0) v.AddArg(x) return true } // match: (Add32 (Const32
[c]) (Sub32 x (Const32
[d]))) // cond: // result: (Add32 (Const32
[int64(int32(c-d))]) x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst32 { break } t := v_0.Type c := v_0.AuxInt v_1 := v.Args[1] if v_1.Op != OpSub32 { break } _ = v_1.Args[1] x := v_1.Args[0] v_1_1 := v_1.Args[1] if v_1_1.Op != OpConst32 { break } if v_1_1.Type != t { break } d := v_1_1.AuxInt v.reset(OpAdd32) v0 := b.NewValue0(v.Pos, OpConst32, t) v0.AuxInt = int64(int32(c - d)) v.AddArg(v0) v.AddArg(x) return true } // match: (Add32 (Sub32 x (Const32
[d])) (Const32
[c])) // cond: // result: (Add32 (Const32
[int64(int32(c-d))]) x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpSub32 { break } _ = v_0.Args[1] x := v_0.Args[0] v_0_1 := v_0.Args[1] if v_0_1.Op != OpConst32 { break } t := v_0_1.Type d := v_0_1.AuxInt v_1 := v.Args[1] if v_1.Op != OpConst32 { break } if v_1.Type != t { break } c := v_1.AuxInt v.reset(OpAdd32) v0 := b.NewValue0(v.Pos, OpConst32, t) v0.AuxInt = int64(int32(c - d)) v.AddArg(v0) v.AddArg(x) return true } return false } func rewriteValuegeneric_OpAdd32F_0(v *Value) bool { // match: (Add32F (Const32F [c]) (Const32F [d])) // cond: // result: (Const32F [auxFrom32F(auxTo32F(c) + auxTo32F(d))]) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst32F { break } c := v_0.AuxInt v_1 := v.Args[1] if v_1.Op != OpConst32F { break } d := v_1.AuxInt v.reset(OpConst32F) v.AuxInt = auxFrom32F(auxTo32F(c) + auxTo32F(d)) return true } // match: (Add32F (Const32F [d]) (Const32F [c])) // cond: // result: (Const32F [auxFrom32F(auxTo32F(c) + auxTo32F(d))]) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst32F { break } d := v_0.AuxInt v_1 := v.Args[1] if v_1.Op != OpConst32F { break } c := v_1.AuxInt v.reset(OpConst32F) v.AuxInt = auxFrom32F(auxTo32F(c) + auxTo32F(d)) return true } return false } func rewriteValuegeneric_OpAdd64_0(v *Value) bool { b := v.Block _ = b // match: (Add64 (Const64 [c]) (Const64 [d])) // cond: // result: (Const64 [c+d]) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst64 { break } c := v_0.AuxInt v_1 := v.Args[1] if v_1.Op != OpConst64 { break } d := v_1.AuxInt v.reset(OpConst64) v.AuxInt = c + d return true } // match: (Add64 (Const64 [d]) (Const64 [c])) // cond: // result: (Const64 [c+d]) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst64 { break } d := v_0.AuxInt v_1 := v.Args[1] if v_1.Op != OpConst64 { break } c := v_1.AuxInt v.reset(OpConst64) v.AuxInt = c + d return true } // match: (Add64
(Mul64 x y) (Mul64 x z)) // cond: // result: (Mul64 x (Add64
y z)) for { t := v.Type _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpMul64 { break } _ = v_0.Args[1] x := v_0.Args[0] y := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpMul64 { break } _ = v_1.Args[1] if x != v_1.Args[0] { break } z := v_1.Args[1] v.reset(OpMul64) v.AddArg(x) v0 := b.NewValue0(v.Pos, OpAdd64, t) v0.AddArg(y) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add64
(Mul64 y x) (Mul64 x z)) // cond: // result: (Mul64 x (Add64
y z)) for { t := v.Type _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpMul64 { break } _ = v_0.Args[1] y := v_0.Args[0] x := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpMul64 { break } _ = v_1.Args[1] if x != v_1.Args[0] { break } z := v_1.Args[1] v.reset(OpMul64) v.AddArg(x) v0 := b.NewValue0(v.Pos, OpAdd64, t) v0.AddArg(y) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add64
(Mul64 x y) (Mul64 z x)) // cond: // result: (Mul64 x (Add64
y z)) for { t := v.Type _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpMul64 { break } _ = v_0.Args[1] x := v_0.Args[0] y := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpMul64 { break } _ = v_1.Args[1] z := v_1.Args[0] if x != v_1.Args[1] { break } v.reset(OpMul64) v.AddArg(x) v0 := b.NewValue0(v.Pos, OpAdd64, t) v0.AddArg(y) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add64
(Mul64 y x) (Mul64 z x)) // cond: // result: (Mul64 x (Add64
y z)) for { t := v.Type _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpMul64 { break } _ = v_0.Args[1] y := v_0.Args[0] x := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpMul64 { break } _ = v_1.Args[1] z := v_1.Args[0] if x != v_1.Args[1] { break } v.reset(OpMul64) v.AddArg(x) v0 := b.NewValue0(v.Pos, OpAdd64, t) v0.AddArg(y) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add64
(Mul64 x z) (Mul64 x y)) // cond: // result: (Mul64 x (Add64
y z)) for { t := v.Type _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpMul64 { break } _ = v_0.Args[1] x := v_0.Args[0] z := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpMul64 { break } _ = v_1.Args[1] if x != v_1.Args[0] { break } y := v_1.Args[1] v.reset(OpMul64) v.AddArg(x) v0 := b.NewValue0(v.Pos, OpAdd64, t) v0.AddArg(y) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add64
(Mul64 z x) (Mul64 x y)) // cond: // result: (Mul64 x (Add64
y z)) for { t := v.Type _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpMul64 { break } _ = v_0.Args[1] z := v_0.Args[0] x := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpMul64 { break } _ = v_1.Args[1] if x != v_1.Args[0] { break } y := v_1.Args[1] v.reset(OpMul64) v.AddArg(x) v0 := b.NewValue0(v.Pos, OpAdd64, t) v0.AddArg(y) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add64
(Mul64 x z) (Mul64 y x)) // cond: // result: (Mul64 x (Add64
y z)) for { t := v.Type _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpMul64 { break } _ = v_0.Args[1] x := v_0.Args[0] z := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpMul64 { break } _ = v_1.Args[1] y := v_1.Args[0] if x != v_1.Args[1] { break } v.reset(OpMul64) v.AddArg(x) v0 := b.NewValue0(v.Pos, OpAdd64, t) v0.AddArg(y) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add64
(Mul64 z x) (Mul64 y x)) // cond: // result: (Mul64 x (Add64
y z)) for { t := v.Type _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpMul64 { break } _ = v_0.Args[1] z := v_0.Args[0] x := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpMul64 { break } _ = v_1.Args[1] y := v_1.Args[0] if x != v_1.Args[1] { break } v.reset(OpMul64) v.AddArg(x) v0 := b.NewValue0(v.Pos, OpAdd64, t) v0.AddArg(y) v0.AddArg(z) v.AddArg(v0) return true } return false } func rewriteValuegeneric_OpAdd64_10(v *Value) bool { b := v.Block _ = b // match: (Add64 (Const64 [0]) x) // cond: // result: x for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst64 { break } if v_0.AuxInt != 0 { break } x := v.Args[1] v.reset(OpCopy) v.Type = x.Type v.AddArg(x) return true } // match: (Add64 x (Const64 [0])) // cond: // result: x for { _ = v.Args[1] x := v.Args[0] v_1 := v.Args[1] if v_1.Op != OpConst64 { break } if v_1.AuxInt != 0 { break } v.reset(OpCopy) v.Type = x.Type v.AddArg(x) return true } // match: (Add64 (Const64 [1]) (Com64 x)) // cond: // result: (Neg64 x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst64 { break } if v_0.AuxInt != 1 { break } v_1 := v.Args[1] if v_1.Op != OpCom64 { break } x := v_1.Args[0] v.reset(OpNeg64) v.AddArg(x) return true } // match: (Add64 (Com64 x) (Const64 [1])) // cond: // result: (Neg64 x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpCom64 { break } x := v_0.Args[0] v_1 := v.Args[1] if v_1.Op != OpConst64 { break } if v_1.AuxInt != 1 { break } v.reset(OpNeg64) v.AddArg(x) return true } // match: (Add64 (Add64 i:(Const64
) z) x) // cond: (z.Op != OpConst64 && x.Op != OpConst64) // result: (Add64 i (Add64
z x)) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpAdd64 { break } _ = v_0.Args[1] i := v_0.Args[0] if i.Op != OpConst64 { break } t := i.Type z := v_0.Args[1] x := v.Args[1] if !(z.Op != OpConst64 && x.Op != OpConst64) { break } v.reset(OpAdd64) v.AddArg(i) v0 := b.NewValue0(v.Pos, OpAdd64, t) v0.AddArg(z) v0.AddArg(x) v.AddArg(v0) return true } // match: (Add64 (Add64 z i:(Const64
)) x) // cond: (z.Op != OpConst64 && x.Op != OpConst64) // result: (Add64 i (Add64
z x)) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpAdd64 { break } _ = v_0.Args[1] z := v_0.Args[0] i := v_0.Args[1] if i.Op != OpConst64 { break } t := i.Type x := v.Args[1] if !(z.Op != OpConst64 && x.Op != OpConst64) { break } v.reset(OpAdd64) v.AddArg(i) v0 := b.NewValue0(v.Pos, OpAdd64, t) v0.AddArg(z) v0.AddArg(x) v.AddArg(v0) return true } // match: (Add64 x (Add64 i:(Const64
) z)) // cond: (z.Op != OpConst64 && x.Op != OpConst64) // result: (Add64 i (Add64
z x)) for { _ = v.Args[1] x := v.Args[0] v_1 := v.Args[1] if v_1.Op != OpAdd64 { break } _ = v_1.Args[1] i := v_1.Args[0] if i.Op != OpConst64 { break } t := i.Type z := v_1.Args[1] if !(z.Op != OpConst64 && x.Op != OpConst64) { break } v.reset(OpAdd64) v.AddArg(i) v0 := b.NewValue0(v.Pos, OpAdd64, t) v0.AddArg(z) v0.AddArg(x) v.AddArg(v0) return true } // match: (Add64 x (Add64 z i:(Const64
))) // cond: (z.Op != OpConst64 && x.Op != OpConst64) // result: (Add64 i (Add64
z x)) for { _ = v.Args[1] x := v.Args[0] v_1 := v.Args[1] if v_1.Op != OpAdd64 { break } _ = v_1.Args[1] z := v_1.Args[0] i := v_1.Args[1] if i.Op != OpConst64 { break } t := i.Type if !(z.Op != OpConst64 && x.Op != OpConst64) { break } v.reset(OpAdd64) v.AddArg(i) v0 := b.NewValue0(v.Pos, OpAdd64, t) v0.AddArg(z) v0.AddArg(x) v.AddArg(v0) return true } // match: (Add64 (Sub64 i:(Const64
) z) x) // cond: (z.Op != OpConst64 && x.Op != OpConst64) // result: (Add64 i (Sub64
x z)) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpSub64 { break } _ = v_0.Args[1] i := v_0.Args[0] if i.Op != OpConst64 { break } t := i.Type z := v_0.Args[1] x := v.Args[1] if !(z.Op != OpConst64 && x.Op != OpConst64) { break } v.reset(OpAdd64) v.AddArg(i) v0 := b.NewValue0(v.Pos, OpSub64, t) v0.AddArg(x) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add64 x (Sub64 i:(Const64
) z)) // cond: (z.Op != OpConst64 && x.Op != OpConst64) // result: (Add64 i (Sub64
x z)) for { _ = v.Args[1] x := v.Args[0] v_1 := v.Args[1] if v_1.Op != OpSub64 { break } _ = v_1.Args[1] i := v_1.Args[0] if i.Op != OpConst64 { break } t := i.Type z := v_1.Args[1] if !(z.Op != OpConst64 && x.Op != OpConst64) { break } v.reset(OpAdd64) v.AddArg(i) v0 := b.NewValue0(v.Pos, OpSub64, t) v0.AddArg(x) v0.AddArg(z) v.AddArg(v0) return true } return false } func rewriteValuegeneric_OpAdd64_20(v *Value) bool { b := v.Block _ = b // match: (Add64 x (Sub64 i:(Const64
) z)) // cond: (z.Op != OpConst64 && x.Op != OpConst64) // result: (Add64 i (Sub64
x z)) for { _ = v.Args[1] x := v.Args[0] v_1 := v.Args[1] if v_1.Op != OpSub64 { break } _ = v_1.Args[1] i := v_1.Args[0] if i.Op != OpConst64 { break } t := i.Type z := v_1.Args[1] if !(z.Op != OpConst64 && x.Op != OpConst64) { break } v.reset(OpAdd64) v.AddArg(i) v0 := b.NewValue0(v.Pos, OpSub64, t) v0.AddArg(x) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add64 (Sub64 i:(Const64
) z) x) // cond: (z.Op != OpConst64 && x.Op != OpConst64) // result: (Add64 i (Sub64
x z)) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpSub64 { break } _ = v_0.Args[1] i := v_0.Args[0] if i.Op != OpConst64 { break } t := i.Type z := v_0.Args[1] x := v.Args[1] if !(z.Op != OpConst64 && x.Op != OpConst64) { break } v.reset(OpAdd64) v.AddArg(i) v0 := b.NewValue0(v.Pos, OpSub64, t) v0.AddArg(x) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add64 (Sub64 z i:(Const64
)) x) // cond: (z.Op != OpConst64 && x.Op != OpConst64) // result: (Sub64 (Add64
x z) i) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpSub64 { break } _ = v_0.Args[1] z := v_0.Args[0] i := v_0.Args[1] if i.Op != OpConst64 { break } t := i.Type x := v.Args[1] if !(z.Op != OpConst64 && x.Op != OpConst64) { break } v.reset(OpSub64) v0 := b.NewValue0(v.Pos, OpAdd64, t) v0.AddArg(x) v0.AddArg(z) v.AddArg(v0) v.AddArg(i) return true } // match: (Add64 x (Sub64 z i:(Const64
))) // cond: (z.Op != OpConst64 && x.Op != OpConst64) // result: (Sub64 (Add64
x z) i) for { _ = v.Args[1] x := v.Args[0] v_1 := v.Args[1] if v_1.Op != OpSub64 { break } _ = v_1.Args[1] z := v_1.Args[0] i := v_1.Args[1] if i.Op != OpConst64 { break } t := i.Type if !(z.Op != OpConst64 && x.Op != OpConst64) { break } v.reset(OpSub64) v0 := b.NewValue0(v.Pos, OpAdd64, t) v0.AddArg(x) v0.AddArg(z) v.AddArg(v0) v.AddArg(i) return true } // match: (Add64 x (Sub64 z i:(Const64
))) // cond: (z.Op != OpConst64 && x.Op != OpConst64) // result: (Sub64 (Add64
x z) i) for { _ = v.Args[1] x := v.Args[0] v_1 := v.Args[1] if v_1.Op != OpSub64 { break } _ = v_1.Args[1] z := v_1.Args[0] i := v_1.Args[1] if i.Op != OpConst64 { break } t := i.Type if !(z.Op != OpConst64 && x.Op != OpConst64) { break } v.reset(OpSub64) v0 := b.NewValue0(v.Pos, OpAdd64, t) v0.AddArg(x) v0.AddArg(z) v.AddArg(v0) v.AddArg(i) return true } // match: (Add64 (Sub64 z i:(Const64
)) x) // cond: (z.Op != OpConst64 && x.Op != OpConst64) // result: (Sub64 (Add64
x z) i) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpSub64 { break } _ = v_0.Args[1] z := v_0.Args[0] i := v_0.Args[1] if i.Op != OpConst64 { break } t := i.Type x := v.Args[1] if !(z.Op != OpConst64 && x.Op != OpConst64) { break } v.reset(OpSub64) v0 := b.NewValue0(v.Pos, OpAdd64, t) v0.AddArg(x) v0.AddArg(z) v.AddArg(v0) v.AddArg(i) return true } // match: (Add64 (Const64
[c]) (Add64 (Const64
[d]) x)) // cond: // result: (Add64 (Const64
[c+d]) x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst64 { break } t := v_0.Type c := v_0.AuxInt v_1 := v.Args[1] if v_1.Op != OpAdd64 { break } _ = v_1.Args[1] v_1_0 := v_1.Args[0] if v_1_0.Op != OpConst64 { break } if v_1_0.Type != t { break } d := v_1_0.AuxInt x := v_1.Args[1] v.reset(OpAdd64) v0 := b.NewValue0(v.Pos, OpConst64, t) v0.AuxInt = c + d v.AddArg(v0) v.AddArg(x) return true } // match: (Add64 (Const64
[c]) (Add64 x (Const64
[d]))) // cond: // result: (Add64 (Const64
[c+d]) x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst64 { break } t := v_0.Type c := v_0.AuxInt v_1 := v.Args[1] if v_1.Op != OpAdd64 { break } _ = v_1.Args[1] x := v_1.Args[0] v_1_1 := v_1.Args[1] if v_1_1.Op != OpConst64 { break } if v_1_1.Type != t { break } d := v_1_1.AuxInt v.reset(OpAdd64) v0 := b.NewValue0(v.Pos, OpConst64, t) v0.AuxInt = c + d v.AddArg(v0) v.AddArg(x) return true } // match: (Add64 (Add64 (Const64
[d]) x) (Const64
[c])) // cond: // result: (Add64 (Const64
[c+d]) x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpAdd64 { break } _ = v_0.Args[1] v_0_0 := v_0.Args[0] if v_0_0.Op != OpConst64 { break } t := v_0_0.Type d := v_0_0.AuxInt x := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpConst64 { break } if v_1.Type != t { break } c := v_1.AuxInt v.reset(OpAdd64) v0 := b.NewValue0(v.Pos, OpConst64, t) v0.AuxInt = c + d v.AddArg(v0) v.AddArg(x) return true } // match: (Add64 (Add64 x (Const64
[d])) (Const64
[c])) // cond: // result: (Add64 (Const64
[c+d]) x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpAdd64 { break } _ = v_0.Args[1] x := v_0.Args[0] v_0_1 := v_0.Args[1] if v_0_1.Op != OpConst64 { break } t := v_0_1.Type d := v_0_1.AuxInt v_1 := v.Args[1] if v_1.Op != OpConst64 { break } if v_1.Type != t { break } c := v_1.AuxInt v.reset(OpAdd64) v0 := b.NewValue0(v.Pos, OpConst64, t) v0.AuxInt = c + d v.AddArg(v0) v.AddArg(x) return true } return false } func rewriteValuegeneric_OpAdd64_30(v *Value) bool { b := v.Block _ = b // match: (Add64 (Const64
[c]) (Sub64 (Const64
[d]) x)) // cond: // result: (Sub64 (Const64
[c+d]) x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst64 { break } t := v_0.Type c := v_0.AuxInt v_1 := v.Args[1] if v_1.Op != OpSub64 { break } _ = v_1.Args[1] v_1_0 := v_1.Args[0] if v_1_0.Op != OpConst64 { break } if v_1_0.Type != t { break } d := v_1_0.AuxInt x := v_1.Args[1] v.reset(OpSub64) v0 := b.NewValue0(v.Pos, OpConst64, t) v0.AuxInt = c + d v.AddArg(v0) v.AddArg(x) return true } // match: (Add64 (Sub64 (Const64
[d]) x) (Const64
[c])) // cond: // result: (Sub64 (Const64
[c+d]) x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpSub64 { break } _ = v_0.Args[1] v_0_0 := v_0.Args[0] if v_0_0.Op != OpConst64 { break } t := v_0_0.Type d := v_0_0.AuxInt x := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpConst64 { break } if v_1.Type != t { break } c := v_1.AuxInt v.reset(OpSub64) v0 := b.NewValue0(v.Pos, OpConst64, t) v0.AuxInt = c + d v.AddArg(v0) v.AddArg(x) return true } // match: (Add64 (Const64
[c]) (Sub64 x (Const64
[d]))) // cond: // result: (Add64 (Const64
[c-d]) x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst64 { break } t := v_0.Type c := v_0.AuxInt v_1 := v.Args[1] if v_1.Op != OpSub64 { break } _ = v_1.Args[1] x := v_1.Args[0] v_1_1 := v_1.Args[1] if v_1_1.Op != OpConst64 { break } if v_1_1.Type != t { break } d := v_1_1.AuxInt v.reset(OpAdd64) v0 := b.NewValue0(v.Pos, OpConst64, t) v0.AuxInt = c - d v.AddArg(v0) v.AddArg(x) return true } // match: (Add64 (Sub64 x (Const64
[d])) (Const64
[c])) // cond: // result: (Add64 (Const64
[c-d]) x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpSub64 { break } _ = v_0.Args[1] x := v_0.Args[0] v_0_1 := v_0.Args[1] if v_0_1.Op != OpConst64 { break } t := v_0_1.Type d := v_0_1.AuxInt v_1 := v.Args[1] if v_1.Op != OpConst64 { break } if v_1.Type != t { break } c := v_1.AuxInt v.reset(OpAdd64) v0 := b.NewValue0(v.Pos, OpConst64, t) v0.AuxInt = c - d v.AddArg(v0) v.AddArg(x) return true } return false } func rewriteValuegeneric_OpAdd64F_0(v *Value) bool { // match: (Add64F (Const64F [c]) (Const64F [d])) // cond: // result: (Const64F [auxFrom64F(auxTo64F(c) + auxTo64F(d))]) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst64F { break } c := v_0.AuxInt v_1 := v.Args[1] if v_1.Op != OpConst64F { break } d := v_1.AuxInt v.reset(OpConst64F) v.AuxInt = auxFrom64F(auxTo64F(c) + auxTo64F(d)) return true } // match: (Add64F (Const64F [d]) (Const64F [c])) // cond: // result: (Const64F [auxFrom64F(auxTo64F(c) + auxTo64F(d))]) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst64F { break } d := v_0.AuxInt v_1 := v.Args[1] if v_1.Op != OpConst64F { break } c := v_1.AuxInt v.reset(OpConst64F) v.AuxInt = auxFrom64F(auxTo64F(c) + auxTo64F(d)) return true } return false } func rewriteValuegeneric_OpAdd8_0(v *Value) bool { b := v.Block _ = b // match: (Add8 (Const8 [c]) (Const8 [d])) // cond: // result: (Const8 [int64(int8(c+d))]) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst8 { break } c := v_0.AuxInt v_1 := v.Args[1] if v_1.Op != OpConst8 { break } d := v_1.AuxInt v.reset(OpConst8) v.AuxInt = int64(int8(c + d)) return true } // match: (Add8 (Const8 [d]) (Const8 [c])) // cond: // result: (Const8 [int64(int8(c+d))]) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst8 { break } d := v_0.AuxInt v_1 := v.Args[1] if v_1.Op != OpConst8 { break } c := v_1.AuxInt v.reset(OpConst8) v.AuxInt = int64(int8(c + d)) return true } // match: (Add8
(Mul8 x y) (Mul8 x z)) // cond: // result: (Mul8 x (Add8
y z)) for { t := v.Type _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpMul8 { break } _ = v_0.Args[1] x := v_0.Args[0] y := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpMul8 { break } _ = v_1.Args[1] if x != v_1.Args[0] { break } z := v_1.Args[1] v.reset(OpMul8) v.AddArg(x) v0 := b.NewValue0(v.Pos, OpAdd8, t) v0.AddArg(y) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add8
(Mul8 y x) (Mul8 x z)) // cond: // result: (Mul8 x (Add8
y z)) for { t := v.Type _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpMul8 { break } _ = v_0.Args[1] y := v_0.Args[0] x := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpMul8 { break } _ = v_1.Args[1] if x != v_1.Args[0] { break } z := v_1.Args[1] v.reset(OpMul8) v.AddArg(x) v0 := b.NewValue0(v.Pos, OpAdd8, t) v0.AddArg(y) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add8
(Mul8 x y) (Mul8 z x)) // cond: // result: (Mul8 x (Add8
y z)) for { t := v.Type _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpMul8 { break } _ = v_0.Args[1] x := v_0.Args[0] y := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpMul8 { break } _ = v_1.Args[1] z := v_1.Args[0] if x != v_1.Args[1] { break } v.reset(OpMul8) v.AddArg(x) v0 := b.NewValue0(v.Pos, OpAdd8, t) v0.AddArg(y) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add8
(Mul8 y x) (Mul8 z x)) // cond: // result: (Mul8 x (Add8
y z)) for { t := v.Type _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpMul8 { break } _ = v_0.Args[1] y := v_0.Args[0] x := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpMul8 { break } _ = v_1.Args[1] z := v_1.Args[0] if x != v_1.Args[1] { break } v.reset(OpMul8) v.AddArg(x) v0 := b.NewValue0(v.Pos, OpAdd8, t) v0.AddArg(y) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add8
(Mul8 x z) (Mul8 x y)) // cond: // result: (Mul8 x (Add8
y z)) for { t := v.Type _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpMul8 { break } _ = v_0.Args[1] x := v_0.Args[0] z := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpMul8 { break } _ = v_1.Args[1] if x != v_1.Args[0] { break } y := v_1.Args[1] v.reset(OpMul8) v.AddArg(x) v0 := b.NewValue0(v.Pos, OpAdd8, t) v0.AddArg(y) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add8
(Mul8 z x) (Mul8 x y)) // cond: // result: (Mul8 x (Add8
y z)) for { t := v.Type _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpMul8 { break } _ = v_0.Args[1] z := v_0.Args[0] x := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpMul8 { break } _ = v_1.Args[1] if x != v_1.Args[0] { break } y := v_1.Args[1] v.reset(OpMul8) v.AddArg(x) v0 := b.NewValue0(v.Pos, OpAdd8, t) v0.AddArg(y) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add8
(Mul8 x z) (Mul8 y x)) // cond: // result: (Mul8 x (Add8
y z)) for { t := v.Type _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpMul8 { break } _ = v_0.Args[1] x := v_0.Args[0] z := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpMul8 { break } _ = v_1.Args[1] y := v_1.Args[0] if x != v_1.Args[1] { break } v.reset(OpMul8) v.AddArg(x) v0 := b.NewValue0(v.Pos, OpAdd8, t) v0.AddArg(y) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add8
(Mul8 z x) (Mul8 y x)) // cond: // result: (Mul8 x (Add8
y z)) for { t := v.Type _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpMul8 { break } _ = v_0.Args[1] z := v_0.Args[0] x := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpMul8 { break } _ = v_1.Args[1] y := v_1.Args[0] if x != v_1.Args[1] { break } v.reset(OpMul8) v.AddArg(x) v0 := b.NewValue0(v.Pos, OpAdd8, t) v0.AddArg(y) v0.AddArg(z) v.AddArg(v0) return true } return false } func rewriteValuegeneric_OpAdd8_10(v *Value) bool { b := v.Block _ = b // match: (Add8 (Const8 [0]) x) // cond: // result: x for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst8 { break } if v_0.AuxInt != 0 { break } x := v.Args[1] v.reset(OpCopy) v.Type = x.Type v.AddArg(x) return true } // match: (Add8 x (Const8 [0])) // cond: // result: x for { _ = v.Args[1] x := v.Args[0] v_1 := v.Args[1] if v_1.Op != OpConst8 { break } if v_1.AuxInt != 0 { break } v.reset(OpCopy) v.Type = x.Type v.AddArg(x) return true } // match: (Add8 (Const8 [1]) (Com8 x)) // cond: // result: (Neg8 x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst8 { break } if v_0.AuxInt != 1 { break } v_1 := v.Args[1] if v_1.Op != OpCom8 { break } x := v_1.Args[0] v.reset(OpNeg8) v.AddArg(x) return true } // match: (Add8 (Com8 x) (Const8 [1])) // cond: // result: (Neg8 x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpCom8 { break } x := v_0.Args[0] v_1 := v.Args[1] if v_1.Op != OpConst8 { break } if v_1.AuxInt != 1 { break } v.reset(OpNeg8) v.AddArg(x) return true } // match: (Add8 (Add8 i:(Const8
) z) x) // cond: (z.Op != OpConst8 && x.Op != OpConst8) // result: (Add8 i (Add8
z x)) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpAdd8 { break } _ = v_0.Args[1] i := v_0.Args[0] if i.Op != OpConst8 { break } t := i.Type z := v_0.Args[1] x := v.Args[1] if !(z.Op != OpConst8 && x.Op != OpConst8) { break } v.reset(OpAdd8) v.AddArg(i) v0 := b.NewValue0(v.Pos, OpAdd8, t) v0.AddArg(z) v0.AddArg(x) v.AddArg(v0) return true } // match: (Add8 (Add8 z i:(Const8
)) x) // cond: (z.Op != OpConst8 && x.Op != OpConst8) // result: (Add8 i (Add8
z x)) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpAdd8 { break } _ = v_0.Args[1] z := v_0.Args[0] i := v_0.Args[1] if i.Op != OpConst8 { break } t := i.Type x := v.Args[1] if !(z.Op != OpConst8 && x.Op != OpConst8) { break } v.reset(OpAdd8) v.AddArg(i) v0 := b.NewValue0(v.Pos, OpAdd8, t) v0.AddArg(z) v0.AddArg(x) v.AddArg(v0) return true } // match: (Add8 x (Add8 i:(Const8
) z)) // cond: (z.Op != OpConst8 && x.Op != OpConst8) // result: (Add8 i (Add8
z x)) for { _ = v.Args[1] x := v.Args[0] v_1 := v.Args[1] if v_1.Op != OpAdd8 { break } _ = v_1.Args[1] i := v_1.Args[0] if i.Op != OpConst8 { break } t := i.Type z := v_1.Args[1] if !(z.Op != OpConst8 && x.Op != OpConst8) { break } v.reset(OpAdd8) v.AddArg(i) v0 := b.NewValue0(v.Pos, OpAdd8, t) v0.AddArg(z) v0.AddArg(x) v.AddArg(v0) return true } // match: (Add8 x (Add8 z i:(Const8
))) // cond: (z.Op != OpConst8 && x.Op != OpConst8) // result: (Add8 i (Add8
z x)) for { _ = v.Args[1] x := v.Args[0] v_1 := v.Args[1] if v_1.Op != OpAdd8 { break } _ = v_1.Args[1] z := v_1.Args[0] i := v_1.Args[1] if i.Op != OpConst8 { break } t := i.Type if !(z.Op != OpConst8 && x.Op != OpConst8) { break } v.reset(OpAdd8) v.AddArg(i) v0 := b.NewValue0(v.Pos, OpAdd8, t) v0.AddArg(z) v0.AddArg(x) v.AddArg(v0) return true } // match: (Add8 (Sub8 i:(Const8
) z) x) // cond: (z.Op != OpConst8 && x.Op != OpConst8) // result: (Add8 i (Sub8
x z)) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpSub8 { break } _ = v_0.Args[1] i := v_0.Args[0] if i.Op != OpConst8 { break } t := i.Type z := v_0.Args[1] x := v.Args[1] if !(z.Op != OpConst8 && x.Op != OpConst8) { break } v.reset(OpAdd8) v.AddArg(i) v0 := b.NewValue0(v.Pos, OpSub8, t) v0.AddArg(x) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add8 x (Sub8 i:(Const8
) z)) // cond: (z.Op != OpConst8 && x.Op != OpConst8) // result: (Add8 i (Sub8
x z)) for { _ = v.Args[1] x := v.Args[0] v_1 := v.Args[1] if v_1.Op != OpSub8 { break } _ = v_1.Args[1] i := v_1.Args[0] if i.Op != OpConst8 { break } t := i.Type z := v_1.Args[1] if !(z.Op != OpConst8 && x.Op != OpConst8) { break } v.reset(OpAdd8) v.AddArg(i) v0 := b.NewValue0(v.Pos, OpSub8, t) v0.AddArg(x) v0.AddArg(z) v.AddArg(v0) return true } return false } func rewriteValuegeneric_OpAdd8_20(v *Value) bool { b := v.Block _ = b // match: (Add8 x (Sub8 i:(Const8
) z)) // cond: (z.Op != OpConst8 && x.Op != OpConst8) // result: (Add8 i (Sub8
x z)) for { _ = v.Args[1] x := v.Args[0] v_1 := v.Args[1] if v_1.Op != OpSub8 { break } _ = v_1.Args[1] i := v_1.Args[0] if i.Op != OpConst8 { break } t := i.Type z := v_1.Args[1] if !(z.Op != OpConst8 && x.Op != OpConst8) { break } v.reset(OpAdd8) v.AddArg(i) v0 := b.NewValue0(v.Pos, OpSub8, t) v0.AddArg(x) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add8 (Sub8 i:(Const8
) z) x) // cond: (z.Op != OpConst8 && x.Op != OpConst8) // result: (Add8 i (Sub8
x z)) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpSub8 { break } _ = v_0.Args[1] i := v_0.Args[0] if i.Op != OpConst8 { break } t := i.Type z := v_0.Args[1] x := v.Args[1] if !(z.Op != OpConst8 && x.Op != OpConst8) { break } v.reset(OpAdd8) v.AddArg(i) v0 := b.NewValue0(v.Pos, OpSub8, t) v0.AddArg(x) v0.AddArg(z) v.AddArg(v0) return true } // match: (Add8 (Sub8 z i:(Const8
)) x) // cond: (z.Op != OpConst8 && x.Op != OpConst8) // result: (Sub8 (Add8
x z) i) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpSub8 { break } _ = v_0.Args[1] z := v_0.Args[0] i := v_0.Args[1] if i.Op != OpConst8 { break } t := i.Type x := v.Args[1] if !(z.Op != OpConst8 && x.Op != OpConst8) { break } v.reset(OpSub8) v0 := b.NewValue0(v.Pos, OpAdd8, t) v0.AddArg(x) v0.AddArg(z) v.AddArg(v0) v.AddArg(i) return true } // match: (Add8 x (Sub8 z i:(Const8
))) // cond: (z.Op != OpConst8 && x.Op != OpConst8) // result: (Sub8 (Add8
x z) i) for { _ = v.Args[1] x := v.Args[0] v_1 := v.Args[1] if v_1.Op != OpSub8 { break } _ = v_1.Args[1] z := v_1.Args[0] i := v_1.Args[1] if i.Op != OpConst8 { break } t := i.Type if !(z.Op != OpConst8 && x.Op != OpConst8) { break } v.reset(OpSub8) v0 := b.NewValue0(v.Pos, OpAdd8, t) v0.AddArg(x) v0.AddArg(z) v.AddArg(v0) v.AddArg(i) return true } // match: (Add8 x (Sub8 z i:(Const8
))) // cond: (z.Op != OpConst8 && x.Op != OpConst8) // result: (Sub8 (Add8
x z) i) for { _ = v.Args[1] x := v.Args[0] v_1 := v.Args[1] if v_1.Op != OpSub8 { break } _ = v_1.Args[1] z := v_1.Args[0] i := v_1.Args[1] if i.Op != OpConst8 { break } t := i.Type if !(z.Op != OpConst8 && x.Op != OpConst8) { break } v.reset(OpSub8) v0 := b.NewValue0(v.Pos, OpAdd8, t) v0.AddArg(x) v0.AddArg(z) v.AddArg(v0) v.AddArg(i) return true } // match: (Add8 (Sub8 z i:(Const8
)) x) // cond: (z.Op != OpConst8 && x.Op != OpConst8) // result: (Sub8 (Add8
x z) i) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpSub8 { break } _ = v_0.Args[1] z := v_0.Args[0] i := v_0.Args[1] if i.Op != OpConst8 { break } t := i.Type x := v.Args[1] if !(z.Op != OpConst8 && x.Op != OpConst8) { break } v.reset(OpSub8) v0 := b.NewValue0(v.Pos, OpAdd8, t) v0.AddArg(x) v0.AddArg(z) v.AddArg(v0) v.AddArg(i) return true } // match: (Add8 (Const8
[c]) (Add8 (Const8
[d]) x)) // cond: // result: (Add8 (Const8
[int64(int8(c+d))]) x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst8 { break } t := v_0.Type c := v_0.AuxInt v_1 := v.Args[1] if v_1.Op != OpAdd8 { break } _ = v_1.Args[1] v_1_0 := v_1.Args[0] if v_1_0.Op != OpConst8 { break } if v_1_0.Type != t { break } d := v_1_0.AuxInt x := v_1.Args[1] v.reset(OpAdd8) v0 := b.NewValue0(v.Pos, OpConst8, t) v0.AuxInt = int64(int8(c + d)) v.AddArg(v0) v.AddArg(x) return true } // match: (Add8 (Const8
[c]) (Add8 x (Const8
[d]))) // cond: // result: (Add8 (Const8
[int64(int8(c+d))]) x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst8 { break } t := v_0.Type c := v_0.AuxInt v_1 := v.Args[1] if v_1.Op != OpAdd8 { break } _ = v_1.Args[1] x := v_1.Args[0] v_1_1 := v_1.Args[1] if v_1_1.Op != OpConst8 { break } if v_1_1.Type != t { break } d := v_1_1.AuxInt v.reset(OpAdd8) v0 := b.NewValue0(v.Pos, OpConst8, t) v0.AuxInt = int64(int8(c + d)) v.AddArg(v0) v.AddArg(x) return true } // match: (Add8 (Add8 (Const8
[d]) x) (Const8
[c])) // cond: // result: (Add8 (Const8
[int64(int8(c+d))]) x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpAdd8 { break } _ = v_0.Args[1] v_0_0 := v_0.Args[0] if v_0_0.Op != OpConst8 { break } t := v_0_0.Type d := v_0_0.AuxInt x := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpConst8 { break } if v_1.Type != t { break } c := v_1.AuxInt v.reset(OpAdd8) v0 := b.NewValue0(v.Pos, OpConst8, t) v0.AuxInt = int64(int8(c + d)) v.AddArg(v0) v.AddArg(x) return true } // match: (Add8 (Add8 x (Const8
[d])) (Const8
[c])) // cond: // result: (Add8 (Const8
[int64(int8(c+d))]) x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpAdd8 { break } _ = v_0.Args[1] x := v_0.Args[0] v_0_1 := v_0.Args[1] if v_0_1.Op != OpConst8 { break } t := v_0_1.Type d := v_0_1.AuxInt v_1 := v.Args[1] if v_1.Op != OpConst8 { break } if v_1.Type != t { break } c := v_1.AuxInt v.reset(OpAdd8) v0 := b.NewValue0(v.Pos, OpConst8, t) v0.AuxInt = int64(int8(c + d)) v.AddArg(v0) v.AddArg(x) return true } return false } func rewriteValuegeneric_OpAdd8_30(v *Value) bool { b := v.Block _ = b // match: (Add8 (Const8
[c]) (Sub8 (Const8
[d]) x)) // cond: // result: (Sub8 (Const8
[int64(int8(c+d))]) x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst8 { break } t := v_0.Type c := v_0.AuxInt v_1 := v.Args[1] if v_1.Op != OpSub8 { break } _ = v_1.Args[1] v_1_0 := v_1.Args[0] if v_1_0.Op != OpConst8 { break } if v_1_0.Type != t { break } d := v_1_0.AuxInt x := v_1.Args[1] v.reset(OpSub8) v0 := b.NewValue0(v.Pos, OpConst8, t) v0.AuxInt = int64(int8(c + d)) v.AddArg(v0) v.AddArg(x) return true } // match: (Add8 (Sub8 (Const8
[d]) x) (Const8
[c])) // cond: // result: (Sub8 (Const8
[int64(int8(c+d))]) x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpSub8 { break } _ = v_0.Args[1] v_0_0 := v_0.Args[0] if v_0_0.Op != OpConst8 { break } t := v_0_0.Type d := v_0_0.AuxInt x := v_0.Args[1] v_1 := v.Args[1] if v_1.Op != OpConst8 { break } if v_1.Type != t { break } c := v_1.AuxInt v.reset(OpSub8) v0 := b.NewValue0(v.Pos, OpConst8, t) v0.AuxInt = int64(int8(c + d)) v.AddArg(v0) v.AddArg(x) return true } // match: (Add8 (Const8
[c]) (Sub8 x (Const8
[d]))) // cond: // result: (Add8 (Const8
[int64(int8(c-d))]) x) for { _ = v.Args[1] v_0 := v.Args[0] if v_0.Op != OpConst8 { break } t := v_0.Type c := v_0.AuxInt v_1 := v.Args[1] if v_1.Op != OpSub8 { break } _ = v_1.Args[1] x := v_1.Args[0] v_1_1 := v_1.Args[1] if v_1_1.Op != OpConst8 { break } if v_1_1.Type != t { break } d := v_1_1.AuxInt v.reset(OpAdd8) v0 := b.NewValue0(v.Pos, OpConst8, t) v0.AuxInt = int64(int8(c - d)) v.AddArg(v0) v.AddArg(x) return true } // match: (Add8 (Sub8 x (Const8