From: Todd Neal Date: Wed, 3 Feb 2016 11:21:24 +0000 (-0500) Subject: [dev.ssa] cmd/compile: rewrites for constant shifts X-Git-Tag: go1.7beta1~1623^2^2~64 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=93a0b0f315a1b37e59449740dc5e5bb692b0d9f5;p=gostls13.git [dev.ssa] cmd/compile: rewrites for constant shifts Add rewrite rules to optimize constant shifts. Fixes #10637 Change-Id: I74b724d3e81aeb7098c696d02c050f7fdfd5b523 Reviewed-on: https://go-review.googlesource.com/19106 Reviewed-by: Keith Randall Run-TryBot: Todd Neal TryBot-Result: Gobot Gobot --- diff --git a/src/cmd/compile/internal/gc/testdata/arithConst_ssa.go b/src/cmd/compile/internal/gc/testdata/arithConst_ssa.go index 93420aee66..782d2df8c8 100644 --- a/src/cmd/compile/internal/gc/testdata/arithConst_ssa.go +++ b/src/cmd/compile/internal/gc/testdata/arithConst_ssa.go @@ -2,1811 +2,1903 @@ package main import "fmt" +//go:noinline func add_uint64_0_ssa(a uint64) uint64 { - switch { - } return a + 0 } + +//go:noinline func add_0_uint64_ssa(a uint64) uint64 { - switch { - } return 0 + a } +//go:noinline func add_uint64_1_ssa(a uint64) uint64 { - switch { - } return a + 1 } + +//go:noinline func add_1_uint64_ssa(a uint64) uint64 { - switch { - } return 1 + a } +//go:noinline func add_uint64_4294967296_ssa(a uint64) uint64 { - switch { - } return a + 4294967296 } + +//go:noinline func add_4294967296_uint64_ssa(a uint64) uint64 { - switch { - } return 4294967296 + a } +//go:noinline func add_uint64_18446744073709551615_ssa(a uint64) uint64 { - switch { - } return a + 18446744073709551615 } + +//go:noinline func add_18446744073709551615_uint64_ssa(a uint64) uint64 { - switch { - } return 18446744073709551615 + a } +//go:noinline func sub_uint64_0_ssa(a uint64) uint64 { - switch { - } return a - 0 } + +//go:noinline func sub_0_uint64_ssa(a uint64) uint64 { - switch { - } return 0 - a } +//go:noinline func sub_uint64_1_ssa(a uint64) uint64 { - switch { - } return a - 1 } + +//go:noinline func sub_1_uint64_ssa(a uint64) uint64 { - switch { - } return 1 - a } +//go:noinline func sub_uint64_4294967296_ssa(a uint64) uint64 { - switch { - } return a - 4294967296 } + +//go:noinline func sub_4294967296_uint64_ssa(a uint64) uint64 { - switch { - } return 4294967296 - a } +//go:noinline func sub_uint64_18446744073709551615_ssa(a uint64) uint64 { - switch { - } return a - 18446744073709551615 } + +//go:noinline func sub_18446744073709551615_uint64_ssa(a uint64) uint64 { - switch { - } return 18446744073709551615 - a } +//go:noinline func div_0_uint64_ssa(a uint64) uint64 { - switch { - } return 0 / a } +//go:noinline func div_uint64_1_ssa(a uint64) uint64 { - switch { - } return a / 1 } + +//go:noinline func div_1_uint64_ssa(a uint64) uint64 { - switch { - } return 1 / a } +//go:noinline func div_uint64_4294967296_ssa(a uint64) uint64 { - switch { - } return a / 4294967296 } + +//go:noinline func div_4294967296_uint64_ssa(a uint64) uint64 { - switch { - } return 4294967296 / a } +//go:noinline func div_uint64_18446744073709551615_ssa(a uint64) uint64 { - switch { - } return a / 18446744073709551615 } + +//go:noinline func div_18446744073709551615_uint64_ssa(a uint64) uint64 { - switch { - } return 18446744073709551615 / a } +//go:noinline func mul_uint64_0_ssa(a uint64) uint64 { - switch { - } return a * 0 } + +//go:noinline func mul_0_uint64_ssa(a uint64) uint64 { - switch { - } return 0 * a } +//go:noinline func mul_uint64_1_ssa(a uint64) uint64 { - switch { - } return a * 1 } + +//go:noinline func mul_1_uint64_ssa(a uint64) uint64 { - switch { - } return 1 * a } +//go:noinline func mul_uint64_4294967296_ssa(a uint64) uint64 { - switch { - } return a * 4294967296 } + +//go:noinline func mul_4294967296_uint64_ssa(a uint64) uint64 { - switch { - } return 4294967296 * a } +//go:noinline func mul_uint64_18446744073709551615_ssa(a uint64) uint64 { - switch { - } return a * 18446744073709551615 } + +//go:noinline func mul_18446744073709551615_uint64_ssa(a uint64) uint64 { - switch { - } return 18446744073709551615 * a } +//go:noinline +func lsh_uint64_0_ssa(a uint64) uint64 { + return a << 0 +} + +//go:noinline +func lsh_0_uint64_ssa(a uint64) uint64 { + return 0 << a +} + +//go:noinline +func lsh_uint64_1_ssa(a uint64) uint64 { + return a << 1 +} + +//go:noinline +func lsh_1_uint64_ssa(a uint64) uint64 { + return 1 << a +} + +//go:noinline +func lsh_uint64_4294967296_ssa(a uint64) uint64 { + return a << 4294967296 +} + +//go:noinline +func lsh_4294967296_uint64_ssa(a uint64) uint64 { + return 4294967296 << a +} + +//go:noinline +func lsh_uint64_18446744073709551615_ssa(a uint64) uint64 { + return a << 18446744073709551615 +} + +//go:noinline +func lsh_18446744073709551615_uint64_ssa(a uint64) uint64 { + return 18446744073709551615 << a +} + +//go:noinline +func rsh_uint64_0_ssa(a uint64) uint64 { + return a >> 0 +} + +//go:noinline +func rsh_0_uint64_ssa(a uint64) uint64 { + return 0 >> a +} + +//go:noinline +func rsh_uint64_1_ssa(a uint64) uint64 { + return a >> 1 +} + +//go:noinline +func rsh_1_uint64_ssa(a uint64) uint64 { + return 1 >> a +} + +//go:noinline +func rsh_uint64_4294967296_ssa(a uint64) uint64 { + return a >> 4294967296 +} + +//go:noinline +func rsh_4294967296_uint64_ssa(a uint64) uint64 { + return 4294967296 >> a +} + +//go:noinline +func rsh_uint64_18446744073709551615_ssa(a uint64) uint64 { + return a >> 18446744073709551615 +} + +//go:noinline +func rsh_18446744073709551615_uint64_ssa(a uint64) uint64 { + return 18446744073709551615 >> a +} + +//go:noinline func add_int64_Neg9223372036854775808_ssa(a int64) int64 { - switch { - } return a + -9223372036854775808 } + +//go:noinline func add_Neg9223372036854775808_int64_ssa(a int64) int64 { - switch { - } return -9223372036854775808 + a } +//go:noinline func add_int64_Neg9223372036854775807_ssa(a int64) int64 { - switch { - } return a + -9223372036854775807 } + +//go:noinline func add_Neg9223372036854775807_int64_ssa(a int64) int64 { - switch { - } return -9223372036854775807 + a } +//go:noinline func add_int64_Neg4294967296_ssa(a int64) int64 { - switch { - } return a + -4294967296 } + +//go:noinline func add_Neg4294967296_int64_ssa(a int64) int64 { - switch { - } return -4294967296 + a } +//go:noinline func add_int64_Neg1_ssa(a int64) int64 { - switch { - } return a + -1 } + +//go:noinline func add_Neg1_int64_ssa(a int64) int64 { - switch { - } return -1 + a } +//go:noinline func add_int64_0_ssa(a int64) int64 { - switch { - } return a + 0 } + +//go:noinline func add_0_int64_ssa(a int64) int64 { - switch { - } return 0 + a } +//go:noinline func add_int64_1_ssa(a int64) int64 { - switch { - } return a + 1 } + +//go:noinline func add_1_int64_ssa(a int64) int64 { - switch { - } return 1 + a } +//go:noinline func add_int64_4294967296_ssa(a int64) int64 { - switch { - } return a + 4294967296 } + +//go:noinline func add_4294967296_int64_ssa(a int64) int64 { - switch { - } return 4294967296 + a } +//go:noinline func add_int64_9223372036854775806_ssa(a int64) int64 { - switch { - } return a + 9223372036854775806 } + +//go:noinline func add_9223372036854775806_int64_ssa(a int64) int64 { - switch { - } return 9223372036854775806 + a } +//go:noinline func add_int64_9223372036854775807_ssa(a int64) int64 { - switch { - } return a + 9223372036854775807 } + +//go:noinline func add_9223372036854775807_int64_ssa(a int64) int64 { - switch { - } return 9223372036854775807 + a } +//go:noinline func sub_int64_Neg9223372036854775808_ssa(a int64) int64 { - switch { - } return a - -9223372036854775808 } + +//go:noinline func sub_Neg9223372036854775808_int64_ssa(a int64) int64 { - switch { - } return -9223372036854775808 - a } +//go:noinline func sub_int64_Neg9223372036854775807_ssa(a int64) int64 { - switch { - } return a - -9223372036854775807 } + +//go:noinline func sub_Neg9223372036854775807_int64_ssa(a int64) int64 { - switch { - } return -9223372036854775807 - a } +//go:noinline func sub_int64_Neg4294967296_ssa(a int64) int64 { - switch { - } return a - -4294967296 } + +//go:noinline func sub_Neg4294967296_int64_ssa(a int64) int64 { - switch { - } return -4294967296 - a } +//go:noinline func sub_int64_Neg1_ssa(a int64) int64 { - switch { - } return a - -1 } + +//go:noinline func sub_Neg1_int64_ssa(a int64) int64 { - switch { - } return -1 - a } +//go:noinline func sub_int64_0_ssa(a int64) int64 { - switch { - } return a - 0 } + +//go:noinline func sub_0_int64_ssa(a int64) int64 { - switch { - } return 0 - a } +//go:noinline func sub_int64_1_ssa(a int64) int64 { - switch { - } return a - 1 } + +//go:noinline func sub_1_int64_ssa(a int64) int64 { - switch { - } return 1 - a } +//go:noinline func sub_int64_4294967296_ssa(a int64) int64 { - switch { - } return a - 4294967296 } + +//go:noinline func sub_4294967296_int64_ssa(a int64) int64 { - switch { - } return 4294967296 - a } +//go:noinline func sub_int64_9223372036854775806_ssa(a int64) int64 { - switch { - } return a - 9223372036854775806 } + +//go:noinline func sub_9223372036854775806_int64_ssa(a int64) int64 { - switch { - } return 9223372036854775806 - a } +//go:noinline func sub_int64_9223372036854775807_ssa(a int64) int64 { - switch { - } return a - 9223372036854775807 } + +//go:noinline func sub_9223372036854775807_int64_ssa(a int64) int64 { - switch { - } return 9223372036854775807 - a } +//go:noinline func div_int64_Neg9223372036854775808_ssa(a int64) int64 { - switch { - } return a / -9223372036854775808 } + +//go:noinline func div_Neg9223372036854775808_int64_ssa(a int64) int64 { - switch { - } return -9223372036854775808 / a } +//go:noinline func div_int64_Neg9223372036854775807_ssa(a int64) int64 { - switch { - } return a / -9223372036854775807 } + +//go:noinline func div_Neg9223372036854775807_int64_ssa(a int64) int64 { - switch { - } return -9223372036854775807 / a } +//go:noinline func div_int64_Neg4294967296_ssa(a int64) int64 { - switch { - } return a / -4294967296 } + +//go:noinline func div_Neg4294967296_int64_ssa(a int64) int64 { - switch { - } return -4294967296 / a } +//go:noinline func div_int64_Neg1_ssa(a int64) int64 { - switch { - } return a / -1 } + +//go:noinline func div_Neg1_int64_ssa(a int64) int64 { - switch { - } return -1 / a } +//go:noinline func div_0_int64_ssa(a int64) int64 { - switch { - } return 0 / a } +//go:noinline func div_int64_1_ssa(a int64) int64 { - switch { - } return a / 1 } + +//go:noinline func div_1_int64_ssa(a int64) int64 { - switch { - } return 1 / a } +//go:noinline func div_int64_4294967296_ssa(a int64) int64 { - switch { - } return a / 4294967296 } + +//go:noinline func div_4294967296_int64_ssa(a int64) int64 { - switch { - } return 4294967296 / a } +//go:noinline func div_int64_9223372036854775806_ssa(a int64) int64 { - switch { - } return a / 9223372036854775806 } + +//go:noinline func div_9223372036854775806_int64_ssa(a int64) int64 { - switch { - } return 9223372036854775806 / a } +//go:noinline func div_int64_9223372036854775807_ssa(a int64) int64 { - switch { - } return a / 9223372036854775807 } + +//go:noinline func div_9223372036854775807_int64_ssa(a int64) int64 { - switch { - } return 9223372036854775807 / a } +//go:noinline func mul_int64_Neg9223372036854775808_ssa(a int64) int64 { - switch { - } return a * -9223372036854775808 } + +//go:noinline func mul_Neg9223372036854775808_int64_ssa(a int64) int64 { - switch { - } return -9223372036854775808 * a } +//go:noinline func mul_int64_Neg9223372036854775807_ssa(a int64) int64 { - switch { - } return a * -9223372036854775807 } + +//go:noinline func mul_Neg9223372036854775807_int64_ssa(a int64) int64 { - switch { - } return -9223372036854775807 * a } +//go:noinline func mul_int64_Neg4294967296_ssa(a int64) int64 { - switch { - } return a * -4294967296 } + +//go:noinline func mul_Neg4294967296_int64_ssa(a int64) int64 { - switch { - } return -4294967296 * a } +//go:noinline func mul_int64_Neg1_ssa(a int64) int64 { - switch { - } return a * -1 } + +//go:noinline func mul_Neg1_int64_ssa(a int64) int64 { - switch { - } return -1 * a } +//go:noinline func mul_int64_0_ssa(a int64) int64 { - switch { - } return a * 0 } + +//go:noinline func mul_0_int64_ssa(a int64) int64 { - switch { - } return 0 * a } +//go:noinline func mul_int64_1_ssa(a int64) int64 { - switch { - } return a * 1 } + +//go:noinline func mul_1_int64_ssa(a int64) int64 { - switch { - } return 1 * a } +//go:noinline func mul_int64_4294967296_ssa(a int64) int64 { - switch { - } return a * 4294967296 } + +//go:noinline func mul_4294967296_int64_ssa(a int64) int64 { - switch { - } return 4294967296 * a } +//go:noinline func mul_int64_9223372036854775806_ssa(a int64) int64 { - switch { - } return a * 9223372036854775806 } + +//go:noinline func mul_9223372036854775806_int64_ssa(a int64) int64 { - switch { - } return 9223372036854775806 * a } +//go:noinline func mul_int64_9223372036854775807_ssa(a int64) int64 { - switch { - } return a * 9223372036854775807 } + +//go:noinline func mul_9223372036854775807_int64_ssa(a int64) int64 { - switch { - } return 9223372036854775807 * a } +//go:noinline func add_uint32_0_ssa(a uint32) uint32 { - switch { - } return a + 0 } + +//go:noinline func add_0_uint32_ssa(a uint32) uint32 { - switch { - } return 0 + a } +//go:noinline func add_uint32_1_ssa(a uint32) uint32 { - switch { - } return a + 1 } + +//go:noinline func add_1_uint32_ssa(a uint32) uint32 { - switch { - } return 1 + a } +//go:noinline func add_uint32_4294967295_ssa(a uint32) uint32 { - switch { - } return a + 4294967295 } + +//go:noinline func add_4294967295_uint32_ssa(a uint32) uint32 { - switch { - } return 4294967295 + a } +//go:noinline func sub_uint32_0_ssa(a uint32) uint32 { - switch { - } return a - 0 } + +//go:noinline func sub_0_uint32_ssa(a uint32) uint32 { - switch { - } return 0 - a } +//go:noinline func sub_uint32_1_ssa(a uint32) uint32 { - switch { - } return a - 1 } + +//go:noinline func sub_1_uint32_ssa(a uint32) uint32 { - switch { - } return 1 - a } +//go:noinline func sub_uint32_4294967295_ssa(a uint32) uint32 { - switch { - } return a - 4294967295 } + +//go:noinline func sub_4294967295_uint32_ssa(a uint32) uint32 { - switch { - } return 4294967295 - a } +//go:noinline func div_0_uint32_ssa(a uint32) uint32 { - switch { - } return 0 / a } +//go:noinline func div_uint32_1_ssa(a uint32) uint32 { - switch { - } return a / 1 } + +//go:noinline func div_1_uint32_ssa(a uint32) uint32 { - switch { - } return 1 / a } +//go:noinline func div_uint32_4294967295_ssa(a uint32) uint32 { - switch { - } return a / 4294967295 } + +//go:noinline func div_4294967295_uint32_ssa(a uint32) uint32 { - switch { - } return 4294967295 / a } +//go:noinline func mul_uint32_0_ssa(a uint32) uint32 { - switch { - } return a * 0 } + +//go:noinline func mul_0_uint32_ssa(a uint32) uint32 { - switch { - } return 0 * a } +//go:noinline func mul_uint32_1_ssa(a uint32) uint32 { - switch { - } return a * 1 } + +//go:noinline func mul_1_uint32_ssa(a uint32) uint32 { - switch { - } return 1 * a } +//go:noinline func mul_uint32_4294967295_ssa(a uint32) uint32 { - switch { - } return a * 4294967295 } + +//go:noinline func mul_4294967295_uint32_ssa(a uint32) uint32 { - switch { - } return 4294967295 * a } +//go:noinline +func lsh_uint32_0_ssa(a uint32) uint32 { + return a << 0 +} + +//go:noinline +func lsh_0_uint32_ssa(a uint32) uint32 { + return 0 << a +} + +//go:noinline +func lsh_uint32_1_ssa(a uint32) uint32 { + return a << 1 +} + +//go:noinline +func lsh_1_uint32_ssa(a uint32) uint32 { + return 1 << a +} + +//go:noinline +func lsh_uint32_4294967295_ssa(a uint32) uint32 { + return a << 4294967295 +} + +//go:noinline +func lsh_4294967295_uint32_ssa(a uint32) uint32 { + return 4294967295 << a +} + +//go:noinline +func rsh_uint32_0_ssa(a uint32) uint32 { + return a >> 0 +} + +//go:noinline +func rsh_0_uint32_ssa(a uint32) uint32 { + return 0 >> a +} + +//go:noinline +func rsh_uint32_1_ssa(a uint32) uint32 { + return a >> 1 +} + +//go:noinline +func rsh_1_uint32_ssa(a uint32) uint32 { + return 1 >> a +} + +//go:noinline +func rsh_uint32_4294967295_ssa(a uint32) uint32 { + return a >> 4294967295 +} + +//go:noinline +func rsh_4294967295_uint32_ssa(a uint32) uint32 { + return 4294967295 >> a +} + +//go:noinline func add_int32_Neg2147483648_ssa(a int32) int32 { - switch { - } return a + -2147483648 } + +//go:noinline func add_Neg2147483648_int32_ssa(a int32) int32 { - switch { - } return -2147483648 + a } +//go:noinline func add_int32_Neg2147483647_ssa(a int32) int32 { - switch { - } return a + -2147483647 } + +//go:noinline func add_Neg2147483647_int32_ssa(a int32) int32 { - switch { - } return -2147483647 + a } +//go:noinline func add_int32_Neg1_ssa(a int32) int32 { - switch { - } return a + -1 } + +//go:noinline func add_Neg1_int32_ssa(a int32) int32 { - switch { - } return -1 + a } +//go:noinline func add_int32_0_ssa(a int32) int32 { - switch { - } return a + 0 } + +//go:noinline func add_0_int32_ssa(a int32) int32 { - switch { - } return 0 + a } +//go:noinline func add_int32_1_ssa(a int32) int32 { - switch { - } return a + 1 } + +//go:noinline func add_1_int32_ssa(a int32) int32 { - switch { - } return 1 + a } +//go:noinline func add_int32_2147483647_ssa(a int32) int32 { - switch { - } return a + 2147483647 } + +//go:noinline func add_2147483647_int32_ssa(a int32) int32 { - switch { - } return 2147483647 + a } +//go:noinline func sub_int32_Neg2147483648_ssa(a int32) int32 { - switch { - } return a - -2147483648 } + +//go:noinline func sub_Neg2147483648_int32_ssa(a int32) int32 { - switch { - } return -2147483648 - a } +//go:noinline func sub_int32_Neg2147483647_ssa(a int32) int32 { - switch { - } return a - -2147483647 } + +//go:noinline func sub_Neg2147483647_int32_ssa(a int32) int32 { - switch { - } return -2147483647 - a } +//go:noinline func sub_int32_Neg1_ssa(a int32) int32 { - switch { - } return a - -1 } + +//go:noinline func sub_Neg1_int32_ssa(a int32) int32 { - switch { - } return -1 - a } +//go:noinline func sub_int32_0_ssa(a int32) int32 { - switch { - } return a - 0 } + +//go:noinline func sub_0_int32_ssa(a int32) int32 { - switch { - } return 0 - a } +//go:noinline func sub_int32_1_ssa(a int32) int32 { - switch { - } return a - 1 } + +//go:noinline func sub_1_int32_ssa(a int32) int32 { - switch { - } return 1 - a } +//go:noinline func sub_int32_2147483647_ssa(a int32) int32 { - switch { - } return a - 2147483647 } + +//go:noinline func sub_2147483647_int32_ssa(a int32) int32 { - switch { - } return 2147483647 - a } +//go:noinline func div_int32_Neg2147483648_ssa(a int32) int32 { - switch { - } return a / -2147483648 } + +//go:noinline func div_Neg2147483648_int32_ssa(a int32) int32 { - switch { - } return -2147483648 / a } +//go:noinline func div_int32_Neg2147483647_ssa(a int32) int32 { - switch { - } return a / -2147483647 } + +//go:noinline func div_Neg2147483647_int32_ssa(a int32) int32 { - switch { - } return -2147483647 / a } +//go:noinline func div_int32_Neg1_ssa(a int32) int32 { - switch { - } return a / -1 } + +//go:noinline func div_Neg1_int32_ssa(a int32) int32 { - switch { - } return -1 / a } +//go:noinline func div_0_int32_ssa(a int32) int32 { - switch { - } return 0 / a } +//go:noinline func div_int32_1_ssa(a int32) int32 { - switch { - } return a / 1 } + +//go:noinline func div_1_int32_ssa(a int32) int32 { - switch { - } return 1 / a } +//go:noinline func div_int32_2147483647_ssa(a int32) int32 { - switch { - } return a / 2147483647 } + +//go:noinline func div_2147483647_int32_ssa(a int32) int32 { - switch { - } return 2147483647 / a } +//go:noinline func mul_int32_Neg2147483648_ssa(a int32) int32 { - switch { - } return a * -2147483648 } + +//go:noinline func mul_Neg2147483648_int32_ssa(a int32) int32 { - switch { - } return -2147483648 * a } +//go:noinline func mul_int32_Neg2147483647_ssa(a int32) int32 { - switch { - } return a * -2147483647 } + +//go:noinline func mul_Neg2147483647_int32_ssa(a int32) int32 { - switch { - } return -2147483647 * a } +//go:noinline func mul_int32_Neg1_ssa(a int32) int32 { - switch { - } return a * -1 } + +//go:noinline func mul_Neg1_int32_ssa(a int32) int32 { - switch { - } return -1 * a } +//go:noinline func mul_int32_0_ssa(a int32) int32 { - switch { - } return a * 0 } + +//go:noinline func mul_0_int32_ssa(a int32) int32 { - switch { - } return 0 * a } +//go:noinline func mul_int32_1_ssa(a int32) int32 { - switch { - } return a * 1 } + +//go:noinline func mul_1_int32_ssa(a int32) int32 { - switch { - } return 1 * a } +//go:noinline func mul_int32_2147483647_ssa(a int32) int32 { - switch { - } return a * 2147483647 } + +//go:noinline func mul_2147483647_int32_ssa(a int32) int32 { - switch { - } return 2147483647 * a } +//go:noinline func add_uint16_0_ssa(a uint16) uint16 { - switch { - } return a + 0 } + +//go:noinline func add_0_uint16_ssa(a uint16) uint16 { - switch { - } return 0 + a } +//go:noinline func add_uint16_1_ssa(a uint16) uint16 { - switch { - } return a + 1 } + +//go:noinline func add_1_uint16_ssa(a uint16) uint16 { - switch { - } return 1 + a } +//go:noinline func add_uint16_65535_ssa(a uint16) uint16 { - switch { - } return a + 65535 } + +//go:noinline func add_65535_uint16_ssa(a uint16) uint16 { - switch { - } return 65535 + a } +//go:noinline func sub_uint16_0_ssa(a uint16) uint16 { - switch { - } return a - 0 } + +//go:noinline func sub_0_uint16_ssa(a uint16) uint16 { - switch { - } return 0 - a } +//go:noinline func sub_uint16_1_ssa(a uint16) uint16 { - switch { - } return a - 1 } + +//go:noinline func sub_1_uint16_ssa(a uint16) uint16 { - switch { - } return 1 - a } +//go:noinline func sub_uint16_65535_ssa(a uint16) uint16 { - switch { - } return a - 65535 } + +//go:noinline func sub_65535_uint16_ssa(a uint16) uint16 { - switch { - } return 65535 - a } +//go:noinline func div_0_uint16_ssa(a uint16) uint16 { - switch { - } return 0 / a } +//go:noinline func div_uint16_1_ssa(a uint16) uint16 { - switch { - } return a / 1 } + +//go:noinline func div_1_uint16_ssa(a uint16) uint16 { - switch { - } return 1 / a } +//go:noinline func div_uint16_65535_ssa(a uint16) uint16 { - switch { - } return a / 65535 } + +//go:noinline func div_65535_uint16_ssa(a uint16) uint16 { - switch { - } return 65535 / a } +//go:noinline func mul_uint16_0_ssa(a uint16) uint16 { - switch { - } return a * 0 } + +//go:noinline func mul_0_uint16_ssa(a uint16) uint16 { - switch { - } return 0 * a } +//go:noinline func mul_uint16_1_ssa(a uint16) uint16 { - switch { - } return a * 1 } + +//go:noinline func mul_1_uint16_ssa(a uint16) uint16 { - switch { - } return 1 * a } +//go:noinline func mul_uint16_65535_ssa(a uint16) uint16 { - switch { - } return a * 65535 } + +//go:noinline func mul_65535_uint16_ssa(a uint16) uint16 { - switch { - } return 65535 * a } +//go:noinline +func lsh_uint16_0_ssa(a uint16) uint16 { + return a << 0 +} + +//go:noinline +func lsh_0_uint16_ssa(a uint16) uint16 { + return 0 << a +} + +//go:noinline +func lsh_uint16_1_ssa(a uint16) uint16 { + return a << 1 +} + +//go:noinline +func lsh_1_uint16_ssa(a uint16) uint16 { + return 1 << a +} + +//go:noinline +func lsh_uint16_65535_ssa(a uint16) uint16 { + return a << 65535 +} + +//go:noinline +func lsh_65535_uint16_ssa(a uint16) uint16 { + return 65535 << a +} + +//go:noinline +func rsh_uint16_0_ssa(a uint16) uint16 { + return a >> 0 +} + +//go:noinline +func rsh_0_uint16_ssa(a uint16) uint16 { + return 0 >> a +} + +//go:noinline +func rsh_uint16_1_ssa(a uint16) uint16 { + return a >> 1 +} + +//go:noinline +func rsh_1_uint16_ssa(a uint16) uint16 { + return 1 >> a +} + +//go:noinline +func rsh_uint16_65535_ssa(a uint16) uint16 { + return a >> 65535 +} + +//go:noinline +func rsh_65535_uint16_ssa(a uint16) uint16 { + return 65535 >> a +} + +//go:noinline func add_int16_Neg32768_ssa(a int16) int16 { - switch { - } return a + -32768 } + +//go:noinline func add_Neg32768_int16_ssa(a int16) int16 { - switch { - } return -32768 + a } +//go:noinline func add_int16_Neg32767_ssa(a int16) int16 { - switch { - } return a + -32767 } + +//go:noinline func add_Neg32767_int16_ssa(a int16) int16 { - switch { - } return -32767 + a } +//go:noinline func add_int16_Neg1_ssa(a int16) int16 { - switch { - } return a + -1 } + +//go:noinline func add_Neg1_int16_ssa(a int16) int16 { - switch { - } return -1 + a } +//go:noinline func add_int16_0_ssa(a int16) int16 { - switch { - } return a + 0 } + +//go:noinline func add_0_int16_ssa(a int16) int16 { - switch { - } return 0 + a } +//go:noinline func add_int16_1_ssa(a int16) int16 { - switch { - } return a + 1 } + +//go:noinline func add_1_int16_ssa(a int16) int16 { - switch { - } return 1 + a } +//go:noinline func add_int16_32766_ssa(a int16) int16 { - switch { - } return a + 32766 } + +//go:noinline func add_32766_int16_ssa(a int16) int16 { - switch { - } return 32766 + a } +//go:noinline func add_int16_32767_ssa(a int16) int16 { - switch { - } return a + 32767 } + +//go:noinline func add_32767_int16_ssa(a int16) int16 { - switch { - } return 32767 + a } +//go:noinline func sub_int16_Neg32768_ssa(a int16) int16 { - switch { - } return a - -32768 } + +//go:noinline func sub_Neg32768_int16_ssa(a int16) int16 { - switch { - } return -32768 - a } +//go:noinline func sub_int16_Neg32767_ssa(a int16) int16 { - switch { - } return a - -32767 } + +//go:noinline func sub_Neg32767_int16_ssa(a int16) int16 { - switch { - } return -32767 - a } +//go:noinline func sub_int16_Neg1_ssa(a int16) int16 { - switch { - } return a - -1 } + +//go:noinline func sub_Neg1_int16_ssa(a int16) int16 { - switch { - } return -1 - a } +//go:noinline func sub_int16_0_ssa(a int16) int16 { - switch { - } return a - 0 } + +//go:noinline func sub_0_int16_ssa(a int16) int16 { - switch { - } return 0 - a } +//go:noinline func sub_int16_1_ssa(a int16) int16 { - switch { - } return a - 1 } + +//go:noinline func sub_1_int16_ssa(a int16) int16 { - switch { - } return 1 - a } +//go:noinline func sub_int16_32766_ssa(a int16) int16 { - switch { - } return a - 32766 } + +//go:noinline func sub_32766_int16_ssa(a int16) int16 { - switch { - } return 32766 - a } +//go:noinline func sub_int16_32767_ssa(a int16) int16 { - switch { - } return a - 32767 } + +//go:noinline func sub_32767_int16_ssa(a int16) int16 { - switch { - } return 32767 - a } +//go:noinline func div_int16_Neg32768_ssa(a int16) int16 { - switch { - } return a / -32768 } + +//go:noinline func div_Neg32768_int16_ssa(a int16) int16 { - switch { - } return -32768 / a } +//go:noinline func div_int16_Neg32767_ssa(a int16) int16 { - switch { - } return a / -32767 } + +//go:noinline func div_Neg32767_int16_ssa(a int16) int16 { - switch { - } return -32767 / a } +//go:noinline func div_int16_Neg1_ssa(a int16) int16 { - switch { - } return a / -1 } + +//go:noinline func div_Neg1_int16_ssa(a int16) int16 { - switch { - } return -1 / a } +//go:noinline func div_0_int16_ssa(a int16) int16 { - switch { - } return 0 / a } +//go:noinline func div_int16_1_ssa(a int16) int16 { - switch { - } return a / 1 } + +//go:noinline func div_1_int16_ssa(a int16) int16 { - switch { - } return 1 / a } +//go:noinline func div_int16_32766_ssa(a int16) int16 { - switch { - } return a / 32766 } + +//go:noinline func div_32766_int16_ssa(a int16) int16 { - switch { - } return 32766 / a } +//go:noinline func div_int16_32767_ssa(a int16) int16 { - switch { - } return a / 32767 } + +//go:noinline func div_32767_int16_ssa(a int16) int16 { - switch { - } return 32767 / a } +//go:noinline func mul_int16_Neg32768_ssa(a int16) int16 { - switch { - } return a * -32768 } + +//go:noinline func mul_Neg32768_int16_ssa(a int16) int16 { - switch { - } return -32768 * a } +//go:noinline func mul_int16_Neg32767_ssa(a int16) int16 { - switch { - } return a * -32767 } + +//go:noinline func mul_Neg32767_int16_ssa(a int16) int16 { - switch { - } return -32767 * a } +//go:noinline func mul_int16_Neg1_ssa(a int16) int16 { - switch { - } return a * -1 } + +//go:noinline func mul_Neg1_int16_ssa(a int16) int16 { - switch { - } return -1 * a } +//go:noinline func mul_int16_0_ssa(a int16) int16 { - switch { - } return a * 0 } + +//go:noinline func mul_0_int16_ssa(a int16) int16 { - switch { - } return 0 * a } +//go:noinline func mul_int16_1_ssa(a int16) int16 { - switch { - } return a * 1 } + +//go:noinline func mul_1_int16_ssa(a int16) int16 { - switch { - } return 1 * a } +//go:noinline func mul_int16_32766_ssa(a int16) int16 { - switch { - } return a * 32766 } + +//go:noinline func mul_32766_int16_ssa(a int16) int16 { - switch { - } return 32766 * a } +//go:noinline func mul_int16_32767_ssa(a int16) int16 { - switch { - } return a * 32767 } + +//go:noinline func mul_32767_int16_ssa(a int16) int16 { - switch { - } return 32767 * a } +//go:noinline func add_uint8_0_ssa(a uint8) uint8 { - switch { - } return a + 0 } + +//go:noinline func add_0_uint8_ssa(a uint8) uint8 { - switch { - } return 0 + a } +//go:noinline func add_uint8_1_ssa(a uint8) uint8 { - switch { - } return a + 1 } + +//go:noinline func add_1_uint8_ssa(a uint8) uint8 { - switch { - } return 1 + a } +//go:noinline func add_uint8_255_ssa(a uint8) uint8 { - switch { - } return a + 255 } + +//go:noinline func add_255_uint8_ssa(a uint8) uint8 { - switch { - } return 255 + a } +//go:noinline func sub_uint8_0_ssa(a uint8) uint8 { - switch { - } return a - 0 } + +//go:noinline func sub_0_uint8_ssa(a uint8) uint8 { - switch { - } return 0 - a } +//go:noinline func sub_uint8_1_ssa(a uint8) uint8 { - switch { - } return a - 1 } + +//go:noinline func sub_1_uint8_ssa(a uint8) uint8 { - switch { - } return 1 - a } +//go:noinline func sub_uint8_255_ssa(a uint8) uint8 { - switch { - } return a - 255 } + +//go:noinline func sub_255_uint8_ssa(a uint8) uint8 { - switch { - } return 255 - a } +//go:noinline func div_0_uint8_ssa(a uint8) uint8 { - switch { - } return 0 / a } +//go:noinline func div_uint8_1_ssa(a uint8) uint8 { - switch { - } return a / 1 } + +//go:noinline func div_1_uint8_ssa(a uint8) uint8 { - switch { - } return 1 / a } +//go:noinline func div_uint8_255_ssa(a uint8) uint8 { - switch { - } return a / 255 } + +//go:noinline func div_255_uint8_ssa(a uint8) uint8 { - switch { - } return 255 / a } +//go:noinline func mul_uint8_0_ssa(a uint8) uint8 { - switch { - } return a * 0 } + +//go:noinline func mul_0_uint8_ssa(a uint8) uint8 { - switch { - } return 0 * a } +//go:noinline func mul_uint8_1_ssa(a uint8) uint8 { - switch { - } return a * 1 } + +//go:noinline func mul_1_uint8_ssa(a uint8) uint8 { - switch { - } return 1 * a } +//go:noinline func mul_uint8_255_ssa(a uint8) uint8 { - switch { - } return a * 255 } + +//go:noinline func mul_255_uint8_ssa(a uint8) uint8 { - switch { - } return 255 * a } -func add_int8_Neg128_ssa(a int8) int8 { - switch { - } - return a + -128 +//go:noinline +func lsh_uint8_0_ssa(a uint8) uint8 { + return a << 0 } -func add_Neg128_int8_ssa(a int8) int8 { - switch { - } - return -128 + a + +//go:noinline +func lsh_0_uint8_ssa(a uint8) uint8 { + return 0 << a } -func add_int8_Neg127_ssa(a int8) int8 { - switch { - } - return a + -127 +//go:noinline +func lsh_uint8_1_ssa(a uint8) uint8 { + return a << 1 } -func add_Neg127_int8_ssa(a int8) int8 { - switch { - } - return -127 + a + +//go:noinline +func lsh_1_uint8_ssa(a uint8) uint8 { + return 1 << a } -func add_int8_Neg1_ssa(a int8) int8 { - switch { - } - return a + -1 +//go:noinline +func lsh_uint8_255_ssa(a uint8) uint8 { + return a << 255 } -func add_Neg1_int8_ssa(a int8) int8 { - switch { - } - return -1 + a + +//go:noinline +func lsh_255_uint8_ssa(a uint8) uint8 { + return 255 << a } -func add_int8_0_ssa(a int8) int8 { - switch { - } - return a + 0 +//go:noinline +func rsh_uint8_0_ssa(a uint8) uint8 { + return a >> 0 } -func add_0_int8_ssa(a int8) int8 { - switch { - } + +//go:noinline +func rsh_0_uint8_ssa(a uint8) uint8 { + return 0 >> a +} + +//go:noinline +func rsh_uint8_1_ssa(a uint8) uint8 { + return a >> 1 +} + +//go:noinline +func rsh_1_uint8_ssa(a uint8) uint8 { + return 1 >> a +} + +//go:noinline +func rsh_uint8_255_ssa(a uint8) uint8 { + return a >> 255 +} + +//go:noinline +func rsh_255_uint8_ssa(a uint8) uint8 { + return 255 >> a +} + +//go:noinline +func add_int8_Neg128_ssa(a int8) int8 { + return a + -128 +} + +//go:noinline +func add_Neg128_int8_ssa(a int8) int8 { + return -128 + a +} + +//go:noinline +func add_int8_Neg127_ssa(a int8) int8 { + return a + -127 +} + +//go:noinline +func add_Neg127_int8_ssa(a int8) int8 { + return -127 + a +} + +//go:noinline +func add_int8_Neg1_ssa(a int8) int8 { + return a + -1 +} + +//go:noinline +func add_Neg1_int8_ssa(a int8) int8 { + return -1 + a +} + +//go:noinline +func add_int8_0_ssa(a int8) int8 { + return a + 0 +} + +//go:noinline +func add_0_int8_ssa(a int8) int8 { return 0 + a } +//go:noinline func add_int8_1_ssa(a int8) int8 { - switch { - } return a + 1 } + +//go:noinline func add_1_int8_ssa(a int8) int8 { - switch { - } return 1 + a } +//go:noinline func add_int8_126_ssa(a int8) int8 { - switch { - } return a + 126 } + +//go:noinline func add_126_int8_ssa(a int8) int8 { - switch { - } return 126 + a } +//go:noinline func add_int8_127_ssa(a int8) int8 { - switch { - } return a + 127 } + +//go:noinline func add_127_int8_ssa(a int8) int8 { - switch { - } return 127 + a } +//go:noinline func sub_int8_Neg128_ssa(a int8) int8 { - switch { - } return a - -128 } + +//go:noinline func sub_Neg128_int8_ssa(a int8) int8 { - switch { - } return -128 - a } +//go:noinline func sub_int8_Neg127_ssa(a int8) int8 { - switch { - } return a - -127 } + +//go:noinline func sub_Neg127_int8_ssa(a int8) int8 { - switch { - } return -127 - a } +//go:noinline func sub_int8_Neg1_ssa(a int8) int8 { - switch { - } return a - -1 } + +//go:noinline func sub_Neg1_int8_ssa(a int8) int8 { - switch { - } return -1 - a } +//go:noinline func sub_int8_0_ssa(a int8) int8 { - switch { - } return a - 0 } + +//go:noinline func sub_0_int8_ssa(a int8) int8 { - switch { - } return 0 - a } +//go:noinline func sub_int8_1_ssa(a int8) int8 { - switch { - } return a - 1 } + +//go:noinline func sub_1_int8_ssa(a int8) int8 { - switch { - } return 1 - a } +//go:noinline func sub_int8_126_ssa(a int8) int8 { - switch { - } return a - 126 } + +//go:noinline func sub_126_int8_ssa(a int8) int8 { - switch { - } return 126 - a } +//go:noinline func sub_int8_127_ssa(a int8) int8 { - switch { - } return a - 127 } + +//go:noinline func sub_127_int8_ssa(a int8) int8 { - switch { - } return 127 - a } +//go:noinline func div_int8_Neg128_ssa(a int8) int8 { - switch { - } return a / -128 } + +//go:noinline func div_Neg128_int8_ssa(a int8) int8 { - switch { - } return -128 / a } +//go:noinline func div_int8_Neg127_ssa(a int8) int8 { - switch { - } return a / -127 } + +//go:noinline func div_Neg127_int8_ssa(a int8) int8 { - switch { - } return -127 / a } +//go:noinline func div_int8_Neg1_ssa(a int8) int8 { - switch { - } return a / -1 } + +//go:noinline func div_Neg1_int8_ssa(a int8) int8 { - switch { - } return -1 / a } +//go:noinline func div_0_int8_ssa(a int8) int8 { - switch { - } return 0 / a } +//go:noinline func div_int8_1_ssa(a int8) int8 { - switch { - } return a / 1 } + +//go:noinline func div_1_int8_ssa(a int8) int8 { - switch { - } return 1 / a } +//go:noinline func div_int8_126_ssa(a int8) int8 { - switch { - } return a / 126 } + +//go:noinline func div_126_int8_ssa(a int8) int8 { - switch { - } return 126 / a } +//go:noinline func div_int8_127_ssa(a int8) int8 { - switch { - } return a / 127 } + +//go:noinline func div_127_int8_ssa(a int8) int8 { - switch { - } return 127 / a } +//go:noinline func mul_int8_Neg128_ssa(a int8) int8 { - switch { - } return a * -128 } + +//go:noinline func mul_Neg128_int8_ssa(a int8) int8 { - switch { - } return -128 * a } +//go:noinline func mul_int8_Neg127_ssa(a int8) int8 { - switch { - } return a * -127 } + +//go:noinline func mul_Neg127_int8_ssa(a int8) int8 { - switch { - } return -127 * a } +//go:noinline func mul_int8_Neg1_ssa(a int8) int8 { - switch { - } return a * -1 } + +//go:noinline func mul_Neg1_int8_ssa(a int8) int8 { - switch { - } return -1 * a } +//go:noinline func mul_int8_0_ssa(a int8) int8 { - switch { - } return a * 0 } + +//go:noinline func mul_0_int8_ssa(a int8) int8 { - switch { - } return 0 * a } +//go:noinline func mul_int8_1_ssa(a int8) int8 { - switch { - } return a * 1 } + +//go:noinline func mul_1_int8_ssa(a int8) int8 { - switch { - } return 1 * a } +//go:noinline func mul_int8_126_ssa(a int8) int8 { - switch { - } return a * 126 } + +//go:noinline func mul_126_int8_ssa(a int8) int8 { - switch { - } return 126 * a } +//go:noinline func mul_int8_127_ssa(a int8) int8 { - switch { - } return a * 127 } + +//go:noinline func mul_127_int8_ssa(a int8) int8 { - switch { - } return 127 * a } @@ -1814,1528 +1906,7718 @@ var failed bool func main() { - if got := div_0_uint64_ssa(1); got != 0 { - fmt.Printf("div_uint64 0/1 = %d, wanted 0\n", got) + if got := add_0_uint64_ssa(0); got != 0 { + fmt.Printf("add_uint64 0+0 = %d, wanted 0\n", got) failed = true } - if got := div_0_uint64_ssa(4294967296); got != 0 { - fmt.Printf("div_uint64 0/4294967296 = %d, wanted 0\n", got) + if got := add_uint64_0_ssa(0); got != 0 { + fmt.Printf("add_uint64 0+0 = %d, wanted 0\n", got) failed = true } - if got := div_0_uint64_ssa(18446744073709551615); got != 0 { - fmt.Printf("div_uint64 0/18446744073709551615 = %d, wanted 0\n", got) + if got := add_0_uint64_ssa(1); got != 1 { + fmt.Printf("add_uint64 0+1 = %d, wanted 1\n", got) failed = true } - if got := div_uint64_1_ssa(0); got != 0 { - fmt.Printf("div_uint64 0/1 = %d, wanted 0\n", got) + if got := add_uint64_0_ssa(1); got != 1 { + fmt.Printf("add_uint64 1+0 = %d, wanted 1\n", got) failed = true } - if got := div_1_uint64_ssa(1); got != 1 { - fmt.Printf("div_uint64 1/1 = %d, wanted 1\n", got) + if got := add_0_uint64_ssa(4294967296); got != 4294967296 { + fmt.Printf("add_uint64 0+4294967296 = %d, wanted 4294967296\n", got) failed = true } - if got := div_uint64_1_ssa(1); got != 1 { - fmt.Printf("div_uint64 1/1 = %d, wanted 1\n", got) + if got := add_uint64_0_ssa(4294967296); got != 4294967296 { + fmt.Printf("add_uint64 4294967296+0 = %d, wanted 4294967296\n", got) failed = true } - if got := div_1_uint64_ssa(4294967296); got != 0 { - fmt.Printf("div_uint64 1/4294967296 = %d, wanted 0\n", got) + if got := add_0_uint64_ssa(18446744073709551615); got != 18446744073709551615 { + fmt.Printf("add_uint64 0+18446744073709551615 = %d, wanted 18446744073709551615\n", got) failed = true } - if got := div_uint64_1_ssa(4294967296); got != 4294967296 { - fmt.Printf("div_uint64 4294967296/1 = %d, wanted 4294967296\n", got) + if got := add_uint64_0_ssa(18446744073709551615); got != 18446744073709551615 { + fmt.Printf("add_uint64 18446744073709551615+0 = %d, wanted 18446744073709551615\n", got) failed = true } - if got := div_1_uint64_ssa(18446744073709551615); got != 0 { - fmt.Printf("div_uint64 1/18446744073709551615 = %d, wanted 0\n", got) + if got := add_1_uint64_ssa(0); got != 1 { + fmt.Printf("add_uint64 1+0 = %d, wanted 1\n", got) failed = true } - if got := div_uint64_1_ssa(18446744073709551615); got != 18446744073709551615 { - fmt.Printf("div_uint64 18446744073709551615/1 = %d, wanted 18446744073709551615\n", got) + if got := add_uint64_1_ssa(0); got != 1 { + fmt.Printf("add_uint64 0+1 = %d, wanted 1\n", got) failed = true } - if got := div_uint64_4294967296_ssa(0); got != 0 { - fmt.Printf("div_uint64 0/4294967296 = %d, wanted 0\n", got) + if got := add_1_uint64_ssa(1); got != 2 { + fmt.Printf("add_uint64 1+1 = %d, wanted 2\n", got) failed = true } - if got := div_4294967296_uint64_ssa(1); got != 4294967296 { - fmt.Printf("div_uint64 4294967296/1 = %d, wanted 4294967296\n", got) + if got := add_uint64_1_ssa(1); got != 2 { + fmt.Printf("add_uint64 1+1 = %d, wanted 2\n", got) failed = true } - if got := div_uint64_4294967296_ssa(1); got != 0 { - fmt.Printf("div_uint64 1/4294967296 = %d, wanted 0\n", got) + if got := add_1_uint64_ssa(4294967296); got != 4294967297 { + fmt.Printf("add_uint64 1+4294967296 = %d, wanted 4294967297\n", got) failed = true } - if got := div_4294967296_uint64_ssa(4294967296); got != 1 { - fmt.Printf("div_uint64 4294967296/4294967296 = %d, wanted 1\n", got) + if got := add_uint64_1_ssa(4294967296); got != 4294967297 { + fmt.Printf("add_uint64 4294967296+1 = %d, wanted 4294967297\n", got) failed = true } - if got := div_uint64_4294967296_ssa(4294967296); got != 1 { - fmt.Printf("div_uint64 4294967296/4294967296 = %d, wanted 1\n", got) + if got := add_1_uint64_ssa(18446744073709551615); got != 0 { + fmt.Printf("add_uint64 1+18446744073709551615 = %d, wanted 0\n", got) failed = true } - if got := div_4294967296_uint64_ssa(18446744073709551615); got != 0 { - fmt.Printf("div_uint64 4294967296/18446744073709551615 = %d, wanted 0\n", got) + if got := add_uint64_1_ssa(18446744073709551615); got != 0 { + fmt.Printf("add_uint64 18446744073709551615+1 = %d, wanted 0\n", got) failed = true } - if got := div_uint64_4294967296_ssa(18446744073709551615); got != 4294967295 { - fmt.Printf("div_uint64 18446744073709551615/4294967296 = %d, wanted 4294967295\n", got) + if got := add_4294967296_uint64_ssa(0); got != 4294967296 { + fmt.Printf("add_uint64 4294967296+0 = %d, wanted 4294967296\n", got) failed = true } - if got := div_uint64_18446744073709551615_ssa(0); got != 0 { - fmt.Printf("div_uint64 0/18446744073709551615 = %d, wanted 0\n", got) + if got := add_uint64_4294967296_ssa(0); got != 4294967296 { + fmt.Printf("add_uint64 0+4294967296 = %d, wanted 4294967296\n", got) failed = true } - if got := div_18446744073709551615_uint64_ssa(1); got != 18446744073709551615 { - fmt.Printf("div_uint64 18446744073709551615/1 = %d, wanted 18446744073709551615\n", got) + if got := add_4294967296_uint64_ssa(1); got != 4294967297 { + fmt.Printf("add_uint64 4294967296+1 = %d, wanted 4294967297\n", got) failed = true } - if got := div_uint64_18446744073709551615_ssa(1); got != 0 { - fmt.Printf("div_uint64 1/18446744073709551615 = %d, wanted 0\n", got) + if got := add_uint64_4294967296_ssa(1); got != 4294967297 { + fmt.Printf("add_uint64 1+4294967296 = %d, wanted 4294967297\n", got) failed = true } - if got := div_18446744073709551615_uint64_ssa(4294967296); got != 4294967295 { - fmt.Printf("div_uint64 18446744073709551615/4294967296 = %d, wanted 4294967295\n", got) + if got := add_4294967296_uint64_ssa(4294967296); got != 8589934592 { + fmt.Printf("add_uint64 4294967296+4294967296 = %d, wanted 8589934592\n", got) failed = true } - if got := div_uint64_18446744073709551615_ssa(4294967296); got != 0 { - fmt.Printf("div_uint64 4294967296/18446744073709551615 = %d, wanted 0\n", got) + if got := add_uint64_4294967296_ssa(4294967296); got != 8589934592 { + fmt.Printf("add_uint64 4294967296+4294967296 = %d, wanted 8589934592\n", got) failed = true } - if got := div_18446744073709551615_uint64_ssa(18446744073709551615); got != 1 { - fmt.Printf("div_uint64 18446744073709551615/18446744073709551615 = %d, wanted 1\n", got) + if got := add_4294967296_uint64_ssa(18446744073709551615); got != 4294967295 { + fmt.Printf("add_uint64 4294967296+18446744073709551615 = %d, wanted 4294967295\n", got) failed = true } - if got := div_uint64_18446744073709551615_ssa(18446744073709551615); got != 1 { - fmt.Printf("div_uint64 18446744073709551615/18446744073709551615 = %d, wanted 1\n", got) + if got := add_uint64_4294967296_ssa(18446744073709551615); got != 4294967295 { + fmt.Printf("add_uint64 18446744073709551615+4294967296 = %d, wanted 4294967295\n", got) failed = true } - if got := div_Neg9223372036854775808_int64_ssa(-9223372036854775808); got != 1 { - fmt.Printf("div_int64 -9223372036854775808/-9223372036854775808 = %d, wanted 1\n", got) + if got := add_18446744073709551615_uint64_ssa(0); got != 18446744073709551615 { + fmt.Printf("add_uint64 18446744073709551615+0 = %d, wanted 18446744073709551615\n", got) failed = true } - if got := div_int64_Neg9223372036854775808_ssa(-9223372036854775808); got != 1 { - fmt.Printf("div_int64 -9223372036854775808/-9223372036854775808 = %d, wanted 1\n", got) + if got := add_uint64_18446744073709551615_ssa(0); got != 18446744073709551615 { + fmt.Printf("add_uint64 0+18446744073709551615 = %d, wanted 18446744073709551615\n", got) failed = true } - if got := div_Neg9223372036854775808_int64_ssa(-9223372036854775807); got != 1 { - fmt.Printf("div_int64 -9223372036854775808/-9223372036854775807 = %d, wanted 1\n", got) + if got := add_18446744073709551615_uint64_ssa(1); got != 0 { + fmt.Printf("add_uint64 18446744073709551615+1 = %d, wanted 0\n", got) failed = true } - if got := div_int64_Neg9223372036854775808_ssa(-9223372036854775807); got != 0 { - fmt.Printf("div_int64 -9223372036854775807/-9223372036854775808 = %d, wanted 0\n", got) + if got := add_uint64_18446744073709551615_ssa(1); got != 0 { + fmt.Printf("add_uint64 1+18446744073709551615 = %d, wanted 0\n", got) failed = true } - if got := div_Neg9223372036854775808_int64_ssa(-4294967296); got != 2147483648 { - fmt.Printf("div_int64 -9223372036854775808/-4294967296 = %d, wanted 2147483648\n", got) + if got := add_18446744073709551615_uint64_ssa(4294967296); got != 4294967295 { + fmt.Printf("add_uint64 18446744073709551615+4294967296 = %d, wanted 4294967295\n", got) failed = true } - if got := div_int64_Neg9223372036854775808_ssa(-4294967296); got != 0 { - fmt.Printf("div_int64 -4294967296/-9223372036854775808 = %d, wanted 0\n", got) + if got := add_uint64_18446744073709551615_ssa(4294967296); got != 4294967295 { + fmt.Printf("add_uint64 4294967296+18446744073709551615 = %d, wanted 4294967295\n", got) failed = true } - if got := div_Neg9223372036854775808_int64_ssa(-1); got != -9223372036854775808 { - fmt.Printf("div_int64 -9223372036854775808/-1 = %d, wanted -9223372036854775808\n", got) + if got := add_18446744073709551615_uint64_ssa(18446744073709551615); got != 18446744073709551614 { + fmt.Printf("add_uint64 18446744073709551615+18446744073709551615 = %d, wanted 18446744073709551614\n", got) failed = true } - if got := div_int64_Neg9223372036854775808_ssa(-1); got != 0 { - fmt.Printf("div_int64 -1/-9223372036854775808 = %d, wanted 0\n", got) + if got := add_uint64_18446744073709551615_ssa(18446744073709551615); got != 18446744073709551614 { + fmt.Printf("add_uint64 18446744073709551615+18446744073709551615 = %d, wanted 18446744073709551614\n", got) failed = true } - if got := div_int64_Neg9223372036854775808_ssa(0); got != 0 { - fmt.Printf("div_int64 0/-9223372036854775808 = %d, wanted 0\n", got) + if got := sub_0_uint64_ssa(0); got != 0 { + fmt.Printf("sub_uint64 0-0 = %d, wanted 0\n", got) failed = true } - if got := div_Neg9223372036854775808_int64_ssa(1); got != -9223372036854775808 { - fmt.Printf("div_int64 -9223372036854775808/1 = %d, wanted -9223372036854775808\n", got) + if got := sub_uint64_0_ssa(0); got != 0 { + fmt.Printf("sub_uint64 0-0 = %d, wanted 0\n", got) failed = true } - if got := div_int64_Neg9223372036854775808_ssa(1); got != 0 { - fmt.Printf("div_int64 1/-9223372036854775808 = %d, wanted 0\n", got) + if got := sub_0_uint64_ssa(1); got != 18446744073709551615 { + fmt.Printf("sub_uint64 0-1 = %d, wanted 18446744073709551615\n", got) failed = true } - if got := div_Neg9223372036854775808_int64_ssa(4294967296); got != -2147483648 { - fmt.Printf("div_int64 -9223372036854775808/4294967296 = %d, wanted -2147483648\n", got) + if got := sub_uint64_0_ssa(1); got != 1 { + fmt.Printf("sub_uint64 1-0 = %d, wanted 1\n", got) failed = true } - if got := div_int64_Neg9223372036854775808_ssa(4294967296); got != 0 { - fmt.Printf("div_int64 4294967296/-9223372036854775808 = %d, wanted 0\n", got) + if got := sub_0_uint64_ssa(4294967296); got != 18446744069414584320 { + fmt.Printf("sub_uint64 0-4294967296 = %d, wanted 18446744069414584320\n", got) failed = true } - if got := div_Neg9223372036854775808_int64_ssa(9223372036854775806); got != -1 { - fmt.Printf("div_int64 -9223372036854775808/9223372036854775806 = %d, wanted -1\n", got) + if got := sub_uint64_0_ssa(4294967296); got != 4294967296 { + fmt.Printf("sub_uint64 4294967296-0 = %d, wanted 4294967296\n", got) failed = true } - if got := div_int64_Neg9223372036854775808_ssa(9223372036854775806); got != 0 { - fmt.Printf("div_int64 9223372036854775806/-9223372036854775808 = %d, wanted 0\n", got) + if got := sub_0_uint64_ssa(18446744073709551615); got != 1 { + fmt.Printf("sub_uint64 0-18446744073709551615 = %d, wanted 1\n", got) failed = true } - if got := div_Neg9223372036854775808_int64_ssa(9223372036854775807); got != -1 { - fmt.Printf("div_int64 -9223372036854775808/9223372036854775807 = %d, wanted -1\n", got) + if got := sub_uint64_0_ssa(18446744073709551615); got != 18446744073709551615 { + fmt.Printf("sub_uint64 18446744073709551615-0 = %d, wanted 18446744073709551615\n", got) failed = true } - if got := div_int64_Neg9223372036854775808_ssa(9223372036854775807); got != 0 { - fmt.Printf("div_int64 9223372036854775807/-9223372036854775808 = %d, wanted 0\n", got) + if got := sub_1_uint64_ssa(0); got != 1 { + fmt.Printf("sub_uint64 1-0 = %d, wanted 1\n", got) failed = true } - if got := div_Neg9223372036854775807_int64_ssa(-9223372036854775808); got != 0 { - fmt.Printf("div_int64 -9223372036854775807/-9223372036854775808 = %d, wanted 0\n", got) + if got := sub_uint64_1_ssa(0); got != 18446744073709551615 { + fmt.Printf("sub_uint64 0-1 = %d, wanted 18446744073709551615\n", got) failed = true } - if got := div_int64_Neg9223372036854775807_ssa(-9223372036854775808); got != 1 { - fmt.Printf("div_int64 -9223372036854775808/-9223372036854775807 = %d, wanted 1\n", got) + if got := sub_1_uint64_ssa(1); got != 0 { + fmt.Printf("sub_uint64 1-1 = %d, wanted 0\n", got) failed = true } - if got := div_Neg9223372036854775807_int64_ssa(-9223372036854775807); got != 1 { - fmt.Printf("div_int64 -9223372036854775807/-9223372036854775807 = %d, wanted 1\n", got) + if got := sub_uint64_1_ssa(1); got != 0 { + fmt.Printf("sub_uint64 1-1 = %d, wanted 0\n", got) failed = true } - if got := div_int64_Neg9223372036854775807_ssa(-9223372036854775807); got != 1 { - fmt.Printf("div_int64 -9223372036854775807/-9223372036854775807 = %d, wanted 1\n", got) + if got := sub_1_uint64_ssa(4294967296); got != 18446744069414584321 { + fmt.Printf("sub_uint64 1-4294967296 = %d, wanted 18446744069414584321\n", got) failed = true } - if got := div_Neg9223372036854775807_int64_ssa(-4294967296); got != 2147483647 { - fmt.Printf("div_int64 -9223372036854775807/-4294967296 = %d, wanted 2147483647\n", got) + if got := sub_uint64_1_ssa(4294967296); got != 4294967295 { + fmt.Printf("sub_uint64 4294967296-1 = %d, wanted 4294967295\n", got) failed = true } - if got := div_int64_Neg9223372036854775807_ssa(-4294967296); got != 0 { - fmt.Printf("div_int64 -4294967296/-9223372036854775807 = %d, wanted 0\n", got) + if got := sub_1_uint64_ssa(18446744073709551615); got != 2 { + fmt.Printf("sub_uint64 1-18446744073709551615 = %d, wanted 2\n", got) failed = true } - if got := div_Neg9223372036854775807_int64_ssa(-1); got != 9223372036854775807 { - fmt.Printf("div_int64 -9223372036854775807/-1 = %d, wanted 9223372036854775807\n", got) + if got := sub_uint64_1_ssa(18446744073709551615); got != 18446744073709551614 { + fmt.Printf("sub_uint64 18446744073709551615-1 = %d, wanted 18446744073709551614\n", got) failed = true } - if got := div_int64_Neg9223372036854775807_ssa(-1); got != 0 { - fmt.Printf("div_int64 -1/-9223372036854775807 = %d, wanted 0\n", got) + if got := sub_4294967296_uint64_ssa(0); got != 4294967296 { + fmt.Printf("sub_uint64 4294967296-0 = %d, wanted 4294967296\n", got) failed = true } - if got := div_int64_Neg9223372036854775807_ssa(0); got != 0 { - fmt.Printf("div_int64 0/-9223372036854775807 = %d, wanted 0\n", got) + if got := sub_uint64_4294967296_ssa(0); got != 18446744069414584320 { + fmt.Printf("sub_uint64 0-4294967296 = %d, wanted 18446744069414584320\n", got) failed = true } - if got := div_Neg9223372036854775807_int64_ssa(1); got != -9223372036854775807 { - fmt.Printf("div_int64 -9223372036854775807/1 = %d, wanted -9223372036854775807\n", got) + if got := sub_4294967296_uint64_ssa(1); got != 4294967295 { + fmt.Printf("sub_uint64 4294967296-1 = %d, wanted 4294967295\n", got) failed = true } - if got := div_int64_Neg9223372036854775807_ssa(1); got != 0 { - fmt.Printf("div_int64 1/-9223372036854775807 = %d, wanted 0\n", got) + if got := sub_uint64_4294967296_ssa(1); got != 18446744069414584321 { + fmt.Printf("sub_uint64 1-4294967296 = %d, wanted 18446744069414584321\n", got) failed = true } - if got := div_Neg9223372036854775807_int64_ssa(4294967296); got != -2147483647 { - fmt.Printf("div_int64 -9223372036854775807/4294967296 = %d, wanted -2147483647\n", got) + if got := sub_4294967296_uint64_ssa(4294967296); got != 0 { + fmt.Printf("sub_uint64 4294967296-4294967296 = %d, wanted 0\n", got) failed = true } - if got := div_int64_Neg9223372036854775807_ssa(4294967296); got != 0 { - fmt.Printf("div_int64 4294967296/-9223372036854775807 = %d, wanted 0\n", got) + if got := sub_uint64_4294967296_ssa(4294967296); got != 0 { + fmt.Printf("sub_uint64 4294967296-4294967296 = %d, wanted 0\n", got) failed = true } - if got := div_Neg9223372036854775807_int64_ssa(9223372036854775806); got != -1 { - fmt.Printf("div_int64 -9223372036854775807/9223372036854775806 = %d, wanted -1\n", got) + if got := sub_4294967296_uint64_ssa(18446744073709551615); got != 4294967297 { + fmt.Printf("sub_uint64 4294967296-18446744073709551615 = %d, wanted 4294967297\n", got) failed = true } - if got := div_int64_Neg9223372036854775807_ssa(9223372036854775806); got != 0 { - fmt.Printf("div_int64 9223372036854775806/-9223372036854775807 = %d, wanted 0\n", got) + if got := sub_uint64_4294967296_ssa(18446744073709551615); got != 18446744069414584319 { + fmt.Printf("sub_uint64 18446744073709551615-4294967296 = %d, wanted 18446744069414584319\n", got) failed = true } - if got := div_Neg9223372036854775807_int64_ssa(9223372036854775807); got != -1 { - fmt.Printf("div_int64 -9223372036854775807/9223372036854775807 = %d, wanted -1\n", got) + if got := sub_18446744073709551615_uint64_ssa(0); got != 18446744073709551615 { + fmt.Printf("sub_uint64 18446744073709551615-0 = %d, wanted 18446744073709551615\n", got) failed = true } - if got := div_int64_Neg9223372036854775807_ssa(9223372036854775807); got != -1 { - fmt.Printf("div_int64 9223372036854775807/-9223372036854775807 = %d, wanted -1\n", got) + if got := sub_uint64_18446744073709551615_ssa(0); got != 1 { + fmt.Printf("sub_uint64 0-18446744073709551615 = %d, wanted 1\n", got) failed = true } - if got := div_Neg4294967296_int64_ssa(-9223372036854775808); got != 0 { - fmt.Printf("div_int64 -4294967296/-9223372036854775808 = %d, wanted 0\n", got) + if got := sub_18446744073709551615_uint64_ssa(1); got != 18446744073709551614 { + fmt.Printf("sub_uint64 18446744073709551615-1 = %d, wanted 18446744073709551614\n", got) failed = true } - if got := div_int64_Neg4294967296_ssa(-9223372036854775808); got != 2147483648 { - fmt.Printf("div_int64 -9223372036854775808/-4294967296 = %d, wanted 2147483648\n", got) + if got := sub_uint64_18446744073709551615_ssa(1); got != 2 { + fmt.Printf("sub_uint64 1-18446744073709551615 = %d, wanted 2\n", got) failed = true } - if got := div_Neg4294967296_int64_ssa(-9223372036854775807); got != 0 { - fmt.Printf("div_int64 -4294967296/-9223372036854775807 = %d, wanted 0\n", got) + if got := sub_18446744073709551615_uint64_ssa(4294967296); got != 18446744069414584319 { + fmt.Printf("sub_uint64 18446744073709551615-4294967296 = %d, wanted 18446744069414584319\n", got) failed = true } - if got := div_int64_Neg4294967296_ssa(-9223372036854775807); got != 2147483647 { - fmt.Printf("div_int64 -9223372036854775807/-4294967296 = %d, wanted 2147483647\n", got) + if got := sub_uint64_18446744073709551615_ssa(4294967296); got != 4294967297 { + fmt.Printf("sub_uint64 4294967296-18446744073709551615 = %d, wanted 4294967297\n", got) failed = true } - if got := div_Neg4294967296_int64_ssa(-4294967296); got != 1 { - fmt.Printf("div_int64 -4294967296/-4294967296 = %d, wanted 1\n", got) + if got := sub_18446744073709551615_uint64_ssa(18446744073709551615); got != 0 { + fmt.Printf("sub_uint64 18446744073709551615-18446744073709551615 = %d, wanted 0\n", got) failed = true } - if got := div_int64_Neg4294967296_ssa(-4294967296); got != 1 { - fmt.Printf("div_int64 -4294967296/-4294967296 = %d, wanted 1\n", got) + if got := sub_uint64_18446744073709551615_ssa(18446744073709551615); got != 0 { + fmt.Printf("sub_uint64 18446744073709551615-18446744073709551615 = %d, wanted 0\n", got) failed = true } - if got := div_Neg4294967296_int64_ssa(-1); got != 4294967296 { - fmt.Printf("div_int64 -4294967296/-1 = %d, wanted 4294967296\n", got) + if got := div_0_uint64_ssa(1); got != 0 { + fmt.Printf("div_uint64 0/1 = %d, wanted 0\n", got) failed = true } - if got := div_int64_Neg4294967296_ssa(-1); got != 0 { - fmt.Printf("div_int64 -1/-4294967296 = %d, wanted 0\n", got) + if got := div_0_uint64_ssa(4294967296); got != 0 { + fmt.Printf("div_uint64 0/4294967296 = %d, wanted 0\n", got) failed = true } - if got := div_int64_Neg4294967296_ssa(0); got != 0 { - fmt.Printf("div_int64 0/-4294967296 = %d, wanted 0\n", got) + if got := div_0_uint64_ssa(18446744073709551615); got != 0 { + fmt.Printf("div_uint64 0/18446744073709551615 = %d, wanted 0\n", got) failed = true } - if got := div_Neg4294967296_int64_ssa(1); got != -4294967296 { - fmt.Printf("div_int64 -4294967296/1 = %d, wanted -4294967296\n", got) + if got := div_uint64_1_ssa(0); got != 0 { + fmt.Printf("div_uint64 0/1 = %d, wanted 0\n", got) failed = true } - if got := div_int64_Neg4294967296_ssa(1); got != 0 { - fmt.Printf("div_int64 1/-4294967296 = %d, wanted 0\n", got) + if got := div_1_uint64_ssa(1); got != 1 { + fmt.Printf("div_uint64 1/1 = %d, wanted 1\n", got) failed = true } - if got := div_Neg4294967296_int64_ssa(4294967296); got != -1 { - fmt.Printf("div_int64 -4294967296/4294967296 = %d, wanted -1\n", got) + if got := div_uint64_1_ssa(1); got != 1 { + fmt.Printf("div_uint64 1/1 = %d, wanted 1\n", got) failed = true } - if got := div_int64_Neg4294967296_ssa(4294967296); got != -1 { - fmt.Printf("div_int64 4294967296/-4294967296 = %d, wanted -1\n", got) + if got := div_1_uint64_ssa(4294967296); got != 0 { + fmt.Printf("div_uint64 1/4294967296 = %d, wanted 0\n", got) failed = true } - if got := div_Neg4294967296_int64_ssa(9223372036854775806); got != 0 { - fmt.Printf("div_int64 -4294967296/9223372036854775806 = %d, wanted 0\n", got) + if got := div_uint64_1_ssa(4294967296); got != 4294967296 { + fmt.Printf("div_uint64 4294967296/1 = %d, wanted 4294967296\n", got) failed = true } - if got := div_int64_Neg4294967296_ssa(9223372036854775806); got != -2147483647 { - fmt.Printf("div_int64 9223372036854775806/-4294967296 = %d, wanted -2147483647\n", got) + if got := div_1_uint64_ssa(18446744073709551615); got != 0 { + fmt.Printf("div_uint64 1/18446744073709551615 = %d, wanted 0\n", got) failed = true } - if got := div_Neg4294967296_int64_ssa(9223372036854775807); got != 0 { - fmt.Printf("div_int64 -4294967296/9223372036854775807 = %d, wanted 0\n", got) + if got := div_uint64_1_ssa(18446744073709551615); got != 18446744073709551615 { + fmt.Printf("div_uint64 18446744073709551615/1 = %d, wanted 18446744073709551615\n", got) failed = true } - if got := div_int64_Neg4294967296_ssa(9223372036854775807); got != -2147483647 { - fmt.Printf("div_int64 9223372036854775807/-4294967296 = %d, wanted -2147483647\n", got) + if got := div_uint64_4294967296_ssa(0); got != 0 { + fmt.Printf("div_uint64 0/4294967296 = %d, wanted 0\n", got) failed = true } - if got := div_Neg1_int64_ssa(-9223372036854775808); got != 0 { - fmt.Printf("div_int64 -1/-9223372036854775808 = %d, wanted 0\n", got) + if got := div_4294967296_uint64_ssa(1); got != 4294967296 { + fmt.Printf("div_uint64 4294967296/1 = %d, wanted 4294967296\n", got) failed = true } - if got := div_int64_Neg1_ssa(-9223372036854775808); got != -9223372036854775808 { - fmt.Printf("div_int64 -9223372036854775808/-1 = %d, wanted -9223372036854775808\n", got) + if got := div_uint64_4294967296_ssa(1); got != 0 { + fmt.Printf("div_uint64 1/4294967296 = %d, wanted 0\n", got) failed = true } - if got := div_Neg1_int64_ssa(-9223372036854775807); got != 0 { - fmt.Printf("div_int64 -1/-9223372036854775807 = %d, wanted 0\n", got) + if got := div_4294967296_uint64_ssa(4294967296); got != 1 { + fmt.Printf("div_uint64 4294967296/4294967296 = %d, wanted 1\n", got) failed = true } - if got := div_int64_Neg1_ssa(-9223372036854775807); got != 9223372036854775807 { - fmt.Printf("div_int64 -9223372036854775807/-1 = %d, wanted 9223372036854775807\n", got) + if got := div_uint64_4294967296_ssa(4294967296); got != 1 { + fmt.Printf("div_uint64 4294967296/4294967296 = %d, wanted 1\n", got) failed = true } - if got := div_Neg1_int64_ssa(-4294967296); got != 0 { - fmt.Printf("div_int64 -1/-4294967296 = %d, wanted 0\n", got) + if got := div_4294967296_uint64_ssa(18446744073709551615); got != 0 { + fmt.Printf("div_uint64 4294967296/18446744073709551615 = %d, wanted 0\n", got) failed = true } - if got := div_int64_Neg1_ssa(-4294967296); got != 4294967296 { - fmt.Printf("div_int64 -4294967296/-1 = %d, wanted 4294967296\n", got) + if got := div_uint64_4294967296_ssa(18446744073709551615); got != 4294967295 { + fmt.Printf("div_uint64 18446744073709551615/4294967296 = %d, wanted 4294967295\n", got) failed = true } - if got := div_Neg1_int64_ssa(-1); got != 1 { - fmt.Printf("div_int64 -1/-1 = %d, wanted 1\n", got) + if got := div_uint64_18446744073709551615_ssa(0); got != 0 { + fmt.Printf("div_uint64 0/18446744073709551615 = %d, wanted 0\n", got) failed = true } - if got := div_int64_Neg1_ssa(-1); got != 1 { - fmt.Printf("div_int64 -1/-1 = %d, wanted 1\n", got) + if got := div_18446744073709551615_uint64_ssa(1); got != 18446744073709551615 { + fmt.Printf("div_uint64 18446744073709551615/1 = %d, wanted 18446744073709551615\n", got) failed = true } - if got := div_int64_Neg1_ssa(0); got != 0 { - fmt.Printf("div_int64 0/-1 = %d, wanted 0\n", got) + if got := div_uint64_18446744073709551615_ssa(1); got != 0 { + fmt.Printf("div_uint64 1/18446744073709551615 = %d, wanted 0\n", got) failed = true } - if got := div_Neg1_int64_ssa(1); got != -1 { - fmt.Printf("div_int64 -1/1 = %d, wanted -1\n", got) + if got := div_18446744073709551615_uint64_ssa(4294967296); got != 4294967295 { + fmt.Printf("div_uint64 18446744073709551615/4294967296 = %d, wanted 4294967295\n", got) failed = true } - if got := div_int64_Neg1_ssa(1); got != -1 { - fmt.Printf("div_int64 1/-1 = %d, wanted -1\n", got) + if got := div_uint64_18446744073709551615_ssa(4294967296); got != 0 { + fmt.Printf("div_uint64 4294967296/18446744073709551615 = %d, wanted 0\n", got) failed = true } - if got := div_Neg1_int64_ssa(4294967296); got != 0 { - fmt.Printf("div_int64 -1/4294967296 = %d, wanted 0\n", got) + if got := div_18446744073709551615_uint64_ssa(18446744073709551615); got != 1 { + fmt.Printf("div_uint64 18446744073709551615/18446744073709551615 = %d, wanted 1\n", got) failed = true } - if got := div_int64_Neg1_ssa(4294967296); got != -4294967296 { - fmt.Printf("div_int64 4294967296/-1 = %d, wanted -4294967296\n", got) + if got := div_uint64_18446744073709551615_ssa(18446744073709551615); got != 1 { + fmt.Printf("div_uint64 18446744073709551615/18446744073709551615 = %d, wanted 1\n", got) failed = true } - if got := div_Neg1_int64_ssa(9223372036854775806); got != 0 { - fmt.Printf("div_int64 -1/9223372036854775806 = %d, wanted 0\n", got) + if got := mul_0_uint64_ssa(0); got != 0 { + fmt.Printf("mul_uint64 0*0 = %d, wanted 0\n", got) failed = true } - if got := div_int64_Neg1_ssa(9223372036854775806); got != -9223372036854775806 { - fmt.Printf("div_int64 9223372036854775806/-1 = %d, wanted -9223372036854775806\n", got) + if got := mul_uint64_0_ssa(0); got != 0 { + fmt.Printf("mul_uint64 0*0 = %d, wanted 0\n", got) failed = true } - if got := div_Neg1_int64_ssa(9223372036854775807); got != 0 { - fmt.Printf("div_int64 -1/9223372036854775807 = %d, wanted 0\n", got) + if got := mul_0_uint64_ssa(1); got != 0 { + fmt.Printf("mul_uint64 0*1 = %d, wanted 0\n", got) failed = true } - if got := div_int64_Neg1_ssa(9223372036854775807); got != -9223372036854775807 { - fmt.Printf("div_int64 9223372036854775807/-1 = %d, wanted -9223372036854775807\n", got) + if got := mul_uint64_0_ssa(1); got != 0 { + fmt.Printf("mul_uint64 1*0 = %d, wanted 0\n", got) failed = true } - if got := div_0_int64_ssa(-9223372036854775808); got != 0 { - fmt.Printf("div_int64 0/-9223372036854775808 = %d, wanted 0\n", got) + if got := mul_0_uint64_ssa(4294967296); got != 0 { + fmt.Printf("mul_uint64 0*4294967296 = %d, wanted 0\n", got) failed = true } - if got := div_0_int64_ssa(-9223372036854775807); got != 0 { - fmt.Printf("div_int64 0/-9223372036854775807 = %d, wanted 0\n", got) + if got := mul_uint64_0_ssa(4294967296); got != 0 { + fmt.Printf("mul_uint64 4294967296*0 = %d, wanted 0\n", got) failed = true } - if got := div_0_int64_ssa(-4294967296); got != 0 { - fmt.Printf("div_int64 0/-4294967296 = %d, wanted 0\n", got) + if got := mul_0_uint64_ssa(18446744073709551615); got != 0 { + fmt.Printf("mul_uint64 0*18446744073709551615 = %d, wanted 0\n", got) failed = true } - if got := div_0_int64_ssa(-1); got != 0 { - fmt.Printf("div_int64 0/-1 = %d, wanted 0\n", got) + if got := mul_uint64_0_ssa(18446744073709551615); got != 0 { + fmt.Printf("mul_uint64 18446744073709551615*0 = %d, wanted 0\n", got) failed = true } - if got := div_0_int64_ssa(1); got != 0 { - fmt.Printf("div_int64 0/1 = %d, wanted 0\n", got) + if got := mul_1_uint64_ssa(0); got != 0 { + fmt.Printf("mul_uint64 1*0 = %d, wanted 0\n", got) failed = true } - if got := div_0_int64_ssa(4294967296); got != 0 { - fmt.Printf("div_int64 0/4294967296 = %d, wanted 0\n", got) + if got := mul_uint64_1_ssa(0); got != 0 { + fmt.Printf("mul_uint64 0*1 = %d, wanted 0\n", got) failed = true } - if got := div_0_int64_ssa(9223372036854775806); got != 0 { - fmt.Printf("div_int64 0/9223372036854775806 = %d, wanted 0\n", got) + if got := mul_1_uint64_ssa(1); got != 1 { + fmt.Printf("mul_uint64 1*1 = %d, wanted 1\n", got) failed = true } - if got := div_0_int64_ssa(9223372036854775807); got != 0 { - fmt.Printf("div_int64 0/9223372036854775807 = %d, wanted 0\n", got) + if got := mul_uint64_1_ssa(1); got != 1 { + fmt.Printf("mul_uint64 1*1 = %d, wanted 1\n", got) failed = true } - if got := div_1_int64_ssa(-9223372036854775808); got != 0 { - fmt.Printf("div_int64 1/-9223372036854775808 = %d, wanted 0\n", got) + if got := mul_1_uint64_ssa(4294967296); got != 4294967296 { + fmt.Printf("mul_uint64 1*4294967296 = %d, wanted 4294967296\n", got) failed = true } - if got := div_int64_1_ssa(-9223372036854775808); got != -9223372036854775808 { - fmt.Printf("div_int64 -9223372036854775808/1 = %d, wanted -9223372036854775808\n", got) + if got := mul_uint64_1_ssa(4294967296); got != 4294967296 { + fmt.Printf("mul_uint64 4294967296*1 = %d, wanted 4294967296\n", got) failed = true } - if got := div_1_int64_ssa(-9223372036854775807); got != 0 { - fmt.Printf("div_int64 1/-9223372036854775807 = %d, wanted 0\n", got) + if got := mul_1_uint64_ssa(18446744073709551615); got != 18446744073709551615 { + fmt.Printf("mul_uint64 1*18446744073709551615 = %d, wanted 18446744073709551615\n", got) failed = true } - if got := div_int64_1_ssa(-9223372036854775807); got != -9223372036854775807 { - fmt.Printf("div_int64 -9223372036854775807/1 = %d, wanted -9223372036854775807\n", got) + if got := mul_uint64_1_ssa(18446744073709551615); got != 18446744073709551615 { + fmt.Printf("mul_uint64 18446744073709551615*1 = %d, wanted 18446744073709551615\n", got) failed = true } - if got := div_1_int64_ssa(-4294967296); got != 0 { - fmt.Printf("div_int64 1/-4294967296 = %d, wanted 0\n", got) + if got := mul_4294967296_uint64_ssa(0); got != 0 { + fmt.Printf("mul_uint64 4294967296*0 = %d, wanted 0\n", got) failed = true } - if got := div_int64_1_ssa(-4294967296); got != -4294967296 { - fmt.Printf("div_int64 -4294967296/1 = %d, wanted -4294967296\n", got) + if got := mul_uint64_4294967296_ssa(0); got != 0 { + fmt.Printf("mul_uint64 0*4294967296 = %d, wanted 0\n", got) failed = true } - if got := div_1_int64_ssa(-1); got != -1 { - fmt.Printf("div_int64 1/-1 = %d, wanted -1\n", got) + if got := mul_4294967296_uint64_ssa(1); got != 4294967296 { + fmt.Printf("mul_uint64 4294967296*1 = %d, wanted 4294967296\n", got) failed = true } - if got := div_int64_1_ssa(-1); got != -1 { - fmt.Printf("div_int64 -1/1 = %d, wanted -1\n", got) + if got := mul_uint64_4294967296_ssa(1); got != 4294967296 { + fmt.Printf("mul_uint64 1*4294967296 = %d, wanted 4294967296\n", got) failed = true } - if got := div_int64_1_ssa(0); got != 0 { - fmt.Printf("div_int64 0/1 = %d, wanted 0\n", got) + if got := mul_4294967296_uint64_ssa(4294967296); got != 0 { + fmt.Printf("mul_uint64 4294967296*4294967296 = %d, wanted 0\n", got) failed = true } - if got := div_1_int64_ssa(1); got != 1 { - fmt.Printf("div_int64 1/1 = %d, wanted 1\n", got) + if got := mul_uint64_4294967296_ssa(4294967296); got != 0 { + fmt.Printf("mul_uint64 4294967296*4294967296 = %d, wanted 0\n", got) failed = true } - if got := div_int64_1_ssa(1); got != 1 { - fmt.Printf("div_int64 1/1 = %d, wanted 1\n", got) + if got := mul_4294967296_uint64_ssa(18446744073709551615); got != 18446744069414584320 { + fmt.Printf("mul_uint64 4294967296*18446744073709551615 = %d, wanted 18446744069414584320\n", got) failed = true } - if got := div_1_int64_ssa(4294967296); got != 0 { - fmt.Printf("div_int64 1/4294967296 = %d, wanted 0\n", got) + if got := mul_uint64_4294967296_ssa(18446744073709551615); got != 18446744069414584320 { + fmt.Printf("mul_uint64 18446744073709551615*4294967296 = %d, wanted 18446744069414584320\n", got) failed = true } - if got := div_int64_1_ssa(4294967296); got != 4294967296 { - fmt.Printf("div_int64 4294967296/1 = %d, wanted 4294967296\n", got) + if got := mul_18446744073709551615_uint64_ssa(0); got != 0 { + fmt.Printf("mul_uint64 18446744073709551615*0 = %d, wanted 0\n", got) failed = true } - if got := div_1_int64_ssa(9223372036854775806); got != 0 { - fmt.Printf("div_int64 1/9223372036854775806 = %d, wanted 0\n", got) + if got := mul_uint64_18446744073709551615_ssa(0); got != 0 { + fmt.Printf("mul_uint64 0*18446744073709551615 = %d, wanted 0\n", got) failed = true } - if got := div_int64_1_ssa(9223372036854775806); got != 9223372036854775806 { - fmt.Printf("div_int64 9223372036854775806/1 = %d, wanted 9223372036854775806\n", got) + if got := mul_18446744073709551615_uint64_ssa(1); got != 18446744073709551615 { + fmt.Printf("mul_uint64 18446744073709551615*1 = %d, wanted 18446744073709551615\n", got) failed = true } - if got := div_1_int64_ssa(9223372036854775807); got != 0 { - fmt.Printf("div_int64 1/9223372036854775807 = %d, wanted 0\n", got) + if got := mul_uint64_18446744073709551615_ssa(1); got != 18446744073709551615 { + fmt.Printf("mul_uint64 1*18446744073709551615 = %d, wanted 18446744073709551615\n", got) failed = true } - if got := div_int64_1_ssa(9223372036854775807); got != 9223372036854775807 { - fmt.Printf("div_int64 9223372036854775807/1 = %d, wanted 9223372036854775807\n", got) + if got := mul_18446744073709551615_uint64_ssa(4294967296); got != 18446744069414584320 { + fmt.Printf("mul_uint64 18446744073709551615*4294967296 = %d, wanted 18446744069414584320\n", got) failed = true } - if got := div_4294967296_int64_ssa(-9223372036854775808); got != 0 { - fmt.Printf("div_int64 4294967296/-9223372036854775808 = %d, wanted 0\n", got) + if got := mul_uint64_18446744073709551615_ssa(4294967296); got != 18446744069414584320 { + fmt.Printf("mul_uint64 4294967296*18446744073709551615 = %d, wanted 18446744069414584320\n", got) failed = true } - if got := div_int64_4294967296_ssa(-9223372036854775808); got != -2147483648 { - fmt.Printf("div_int64 -9223372036854775808/4294967296 = %d, wanted -2147483648\n", got) + if got := mul_18446744073709551615_uint64_ssa(18446744073709551615); got != 1 { + fmt.Printf("mul_uint64 18446744073709551615*18446744073709551615 = %d, wanted 1\n", got) failed = true } - if got := div_4294967296_int64_ssa(-9223372036854775807); got != 0 { - fmt.Printf("div_int64 4294967296/-9223372036854775807 = %d, wanted 0\n", got) + if got := mul_uint64_18446744073709551615_ssa(18446744073709551615); got != 1 { + fmt.Printf("mul_uint64 18446744073709551615*18446744073709551615 = %d, wanted 1\n", got) failed = true } - if got := div_int64_4294967296_ssa(-9223372036854775807); got != -2147483647 { - fmt.Printf("div_int64 -9223372036854775807/4294967296 = %d, wanted -2147483647\n", got) + if got := lsh_0_uint64_ssa(0); got != 0 { + fmt.Printf("lsh_uint64 0<<0 = %d, wanted 0\n", got) failed = true } - if got := div_4294967296_int64_ssa(-4294967296); got != -1 { - fmt.Printf("div_int64 4294967296/-4294967296 = %d, wanted -1\n", got) + if got := lsh_uint64_0_ssa(0); got != 0 { + fmt.Printf("lsh_uint64 0<<0 = %d, wanted 0\n", got) failed = true } - if got := div_int64_4294967296_ssa(-4294967296); got != -1 { - fmt.Printf("div_int64 -4294967296/4294967296 = %d, wanted -1\n", got) + if got := lsh_0_uint64_ssa(1); got != 0 { + fmt.Printf("lsh_uint64 0<<1 = %d, wanted 0\n", got) failed = true } - if got := div_4294967296_int64_ssa(-1); got != -4294967296 { - fmt.Printf("div_int64 4294967296/-1 = %d, wanted -4294967296\n", got) + if got := lsh_uint64_0_ssa(1); got != 1 { + fmt.Printf("lsh_uint64 1<<0 = %d, wanted 1\n", got) failed = true } - if got := div_int64_4294967296_ssa(-1); got != 0 { - fmt.Printf("div_int64 -1/4294967296 = %d, wanted 0\n", got) + if got := lsh_0_uint64_ssa(4294967296); got != 0 { + fmt.Printf("lsh_uint64 0<<4294967296 = %d, wanted 0\n", got) failed = true } - if got := div_int64_4294967296_ssa(0); got != 0 { - fmt.Printf("div_int64 0/4294967296 = %d, wanted 0\n", got) + if got := lsh_uint64_0_ssa(4294967296); got != 4294967296 { + fmt.Printf("lsh_uint64 4294967296<<0 = %d, wanted 4294967296\n", got) failed = true } - if got := div_4294967296_int64_ssa(1); got != 4294967296 { - fmt.Printf("div_int64 4294967296/1 = %d, wanted 4294967296\n", got) + if got := lsh_0_uint64_ssa(18446744073709551615); got != 0 { + fmt.Printf("lsh_uint64 0<<18446744073709551615 = %d, wanted 0\n", got) failed = true } - if got := div_int64_4294967296_ssa(1); got != 0 { - fmt.Printf("div_int64 1/4294967296 = %d, wanted 0\n", got) + if got := lsh_uint64_0_ssa(18446744073709551615); got != 18446744073709551615 { + fmt.Printf("lsh_uint64 18446744073709551615<<0 = %d, wanted 18446744073709551615\n", got) failed = true } - if got := div_4294967296_int64_ssa(4294967296); got != 1 { - fmt.Printf("div_int64 4294967296/4294967296 = %d, wanted 1\n", got) + if got := lsh_1_uint64_ssa(0); got != 1 { + fmt.Printf("lsh_uint64 1<<0 = %d, wanted 1\n", got) failed = true } - if got := div_int64_4294967296_ssa(4294967296); got != 1 { - fmt.Printf("div_int64 4294967296/4294967296 = %d, wanted 1\n", got) + if got := lsh_uint64_1_ssa(0); got != 0 { + fmt.Printf("lsh_uint64 0<<1 = %d, wanted 0\n", got) failed = true } - if got := div_4294967296_int64_ssa(9223372036854775806); got != 0 { - fmt.Printf("div_int64 4294967296/9223372036854775806 = %d, wanted 0\n", got) + if got := lsh_1_uint64_ssa(1); got != 2 { + fmt.Printf("lsh_uint64 1<<1 = %d, wanted 2\n", got) failed = true } - if got := div_int64_4294967296_ssa(9223372036854775806); got != 2147483647 { - fmt.Printf("div_int64 9223372036854775806/4294967296 = %d, wanted 2147483647\n", got) + if got := lsh_uint64_1_ssa(1); got != 2 { + fmt.Printf("lsh_uint64 1<<1 = %d, wanted 2\n", got) failed = true } - if got := div_4294967296_int64_ssa(9223372036854775807); got != 0 { - fmt.Printf("div_int64 4294967296/9223372036854775807 = %d, wanted 0\n", got) + if got := lsh_1_uint64_ssa(4294967296); got != 0 { + fmt.Printf("lsh_uint64 1<<4294967296 = %d, wanted 0\n", got) failed = true } - if got := div_int64_4294967296_ssa(9223372036854775807); got != 2147483647 { - fmt.Printf("div_int64 9223372036854775807/4294967296 = %d, wanted 2147483647\n", got) + if got := lsh_uint64_1_ssa(4294967296); got != 8589934592 { + fmt.Printf("lsh_uint64 4294967296<<1 = %d, wanted 8589934592\n", got) failed = true } - if got := div_9223372036854775806_int64_ssa(-9223372036854775808); got != 0 { - fmt.Printf("div_int64 9223372036854775806/-9223372036854775808 = %d, wanted 0\n", got) + if got := lsh_1_uint64_ssa(18446744073709551615); got != 0 { + fmt.Printf("lsh_uint64 1<<18446744073709551615 = %d, wanted 0\n", got) failed = true } - if got := div_int64_9223372036854775806_ssa(-9223372036854775808); got != -1 { - fmt.Printf("div_int64 -9223372036854775808/9223372036854775806 = %d, wanted -1\n", got) + if got := lsh_uint64_1_ssa(18446744073709551615); got != 18446744073709551614 { + fmt.Printf("lsh_uint64 18446744073709551615<<1 = %d, wanted 18446744073709551614\n", got) failed = true } - if got := div_9223372036854775806_int64_ssa(-9223372036854775807); got != 0 { - fmt.Printf("div_int64 9223372036854775806/-9223372036854775807 = %d, wanted 0\n", got) + if got := lsh_4294967296_uint64_ssa(0); got != 4294967296 { + fmt.Printf("lsh_uint64 4294967296<<0 = %d, wanted 4294967296\n", got) failed = true } - if got := div_int64_9223372036854775806_ssa(-9223372036854775807); got != -1 { - fmt.Printf("div_int64 -9223372036854775807/9223372036854775806 = %d, wanted -1\n", got) + if got := lsh_uint64_4294967296_ssa(0); got != 0 { + fmt.Printf("lsh_uint64 0<<4294967296 = %d, wanted 0\n", got) failed = true } - if got := div_9223372036854775806_int64_ssa(-4294967296); got != -2147483647 { - fmt.Printf("div_int64 9223372036854775806/-4294967296 = %d, wanted -2147483647\n", got) + if got := lsh_4294967296_uint64_ssa(1); got != 8589934592 { + fmt.Printf("lsh_uint64 4294967296<<1 = %d, wanted 8589934592\n", got) failed = true } - if got := div_int64_9223372036854775806_ssa(-4294967296); got != 0 { - fmt.Printf("div_int64 -4294967296/9223372036854775806 = %d, wanted 0\n", got) + if got := lsh_uint64_4294967296_ssa(1); got != 0 { + fmt.Printf("lsh_uint64 1<<4294967296 = %d, wanted 0\n", got) failed = true } - if got := div_9223372036854775806_int64_ssa(-1); got != -9223372036854775806 { - fmt.Printf("div_int64 9223372036854775806/-1 = %d, wanted -9223372036854775806\n", got) + if got := lsh_4294967296_uint64_ssa(4294967296); got != 0 { + fmt.Printf("lsh_uint64 4294967296<<4294967296 = %d, wanted 0\n", got) failed = true } - if got := div_int64_9223372036854775806_ssa(-1); got != 0 { - fmt.Printf("div_int64 -1/9223372036854775806 = %d, wanted 0\n", got) + if got := lsh_uint64_4294967296_ssa(4294967296); got != 0 { + fmt.Printf("lsh_uint64 4294967296<<4294967296 = %d, wanted 0\n", got) failed = true } - if got := div_int64_9223372036854775806_ssa(0); got != 0 { - fmt.Printf("div_int64 0/9223372036854775806 = %d, wanted 0\n", got) + if got := lsh_4294967296_uint64_ssa(18446744073709551615); got != 0 { + fmt.Printf("lsh_uint64 4294967296<<18446744073709551615 = %d, wanted 0\n", got) failed = true } - if got := div_9223372036854775806_int64_ssa(1); got != 9223372036854775806 { - fmt.Printf("div_int64 9223372036854775806/1 = %d, wanted 9223372036854775806\n", got) + if got := lsh_uint64_4294967296_ssa(18446744073709551615); got != 0 { + fmt.Printf("lsh_uint64 18446744073709551615<<4294967296 = %d, wanted 0\n", got) failed = true } - if got := div_int64_9223372036854775806_ssa(1); got != 0 { - fmt.Printf("div_int64 1/9223372036854775806 = %d, wanted 0\n", got) + if got := lsh_18446744073709551615_uint64_ssa(0); got != 18446744073709551615 { + fmt.Printf("lsh_uint64 18446744073709551615<<0 = %d, wanted 18446744073709551615\n", got) failed = true } - if got := div_9223372036854775806_int64_ssa(4294967296); got != 2147483647 { - fmt.Printf("div_int64 9223372036854775806/4294967296 = %d, wanted 2147483647\n", got) + if got := lsh_uint64_18446744073709551615_ssa(0); got != 0 { + fmt.Printf("lsh_uint64 0<<18446744073709551615 = %d, wanted 0\n", got) failed = true } - if got := div_int64_9223372036854775806_ssa(4294967296); got != 0 { - fmt.Printf("div_int64 4294967296/9223372036854775806 = %d, wanted 0\n", got) + if got := lsh_18446744073709551615_uint64_ssa(1); got != 18446744073709551614 { + fmt.Printf("lsh_uint64 18446744073709551615<<1 = %d, wanted 18446744073709551614\n", got) failed = true } - if got := div_9223372036854775806_int64_ssa(9223372036854775806); got != 1 { - fmt.Printf("div_int64 9223372036854775806/9223372036854775806 = %d, wanted 1\n", got) + if got := lsh_uint64_18446744073709551615_ssa(1); got != 0 { + fmt.Printf("lsh_uint64 1<<18446744073709551615 = %d, wanted 0\n", got) failed = true } - if got := div_int64_9223372036854775806_ssa(9223372036854775806); got != 1 { - fmt.Printf("div_int64 9223372036854775806/9223372036854775806 = %d, wanted 1\n", got) + if got := lsh_18446744073709551615_uint64_ssa(4294967296); got != 0 { + fmt.Printf("lsh_uint64 18446744073709551615<<4294967296 = %d, wanted 0\n", got) failed = true } - if got := div_9223372036854775806_int64_ssa(9223372036854775807); got != 0 { - fmt.Printf("div_int64 9223372036854775806/9223372036854775807 = %d, wanted 0\n", got) + if got := lsh_uint64_18446744073709551615_ssa(4294967296); got != 0 { + fmt.Printf("lsh_uint64 4294967296<<18446744073709551615 = %d, wanted 0\n", got) failed = true } - if got := div_int64_9223372036854775806_ssa(9223372036854775807); got != 1 { - fmt.Printf("div_int64 9223372036854775807/9223372036854775806 = %d, wanted 1\n", got) + if got := lsh_18446744073709551615_uint64_ssa(18446744073709551615); got != 0 { + fmt.Printf("lsh_uint64 18446744073709551615<<18446744073709551615 = %d, wanted 0\n", got) failed = true } - if got := div_9223372036854775807_int64_ssa(-9223372036854775808); got != 0 { - fmt.Printf("div_int64 9223372036854775807/-9223372036854775808 = %d, wanted 0\n", got) + if got := lsh_uint64_18446744073709551615_ssa(18446744073709551615); got != 0 { + fmt.Printf("lsh_uint64 18446744073709551615<<18446744073709551615 = %d, wanted 0\n", got) failed = true } - if got := div_int64_9223372036854775807_ssa(-9223372036854775808); got != -1 { - fmt.Printf("div_int64 -9223372036854775808/9223372036854775807 = %d, wanted -1\n", got) + if got := rsh_0_uint64_ssa(0); got != 0 { + fmt.Printf("rsh_uint64 0>>0 = %d, wanted 0\n", got) failed = true } - if got := div_9223372036854775807_int64_ssa(-9223372036854775807); got != -1 { - fmt.Printf("div_int64 9223372036854775807/-9223372036854775807 = %d, wanted -1\n", got) + if got := rsh_uint64_0_ssa(0); got != 0 { + fmt.Printf("rsh_uint64 0>>0 = %d, wanted 0\n", got) failed = true } - if got := div_int64_9223372036854775807_ssa(-9223372036854775807); got != -1 { - fmt.Printf("div_int64 -9223372036854775807/9223372036854775807 = %d, wanted -1\n", got) + if got := rsh_0_uint64_ssa(1); got != 0 { + fmt.Printf("rsh_uint64 0>>1 = %d, wanted 0\n", got) failed = true } - if got := div_9223372036854775807_int64_ssa(-4294967296); got != -2147483647 { - fmt.Printf("div_int64 9223372036854775807/-4294967296 = %d, wanted -2147483647\n", got) + if got := rsh_uint64_0_ssa(1); got != 1 { + fmt.Printf("rsh_uint64 1>>0 = %d, wanted 1\n", got) failed = true } - if got := div_int64_9223372036854775807_ssa(-4294967296); got != 0 { - fmt.Printf("div_int64 -4294967296/9223372036854775807 = %d, wanted 0\n", got) + if got := rsh_0_uint64_ssa(4294967296); got != 0 { + fmt.Printf("rsh_uint64 0>>4294967296 = %d, wanted 0\n", got) failed = true } - if got := div_9223372036854775807_int64_ssa(-1); got != -9223372036854775807 { - fmt.Printf("div_int64 9223372036854775807/-1 = %d, wanted -9223372036854775807\n", got) + if got := rsh_uint64_0_ssa(4294967296); got != 4294967296 { + fmt.Printf("rsh_uint64 4294967296>>0 = %d, wanted 4294967296\n", got) failed = true } - if got := div_int64_9223372036854775807_ssa(-1); got != 0 { - fmt.Printf("div_int64 -1/9223372036854775807 = %d, wanted 0\n", got) + if got := rsh_0_uint64_ssa(18446744073709551615); got != 0 { + fmt.Printf("rsh_uint64 0>>18446744073709551615 = %d, wanted 0\n", got) failed = true } - if got := div_int64_9223372036854775807_ssa(0); got != 0 { - fmt.Printf("div_int64 0/9223372036854775807 = %d, wanted 0\n", got) + if got := rsh_uint64_0_ssa(18446744073709551615); got != 18446744073709551615 { + fmt.Printf("rsh_uint64 18446744073709551615>>0 = %d, wanted 18446744073709551615\n", got) failed = true } - if got := div_9223372036854775807_int64_ssa(1); got != 9223372036854775807 { - fmt.Printf("div_int64 9223372036854775807/1 = %d, wanted 9223372036854775807\n", got) + if got := rsh_1_uint64_ssa(0); got != 1 { + fmt.Printf("rsh_uint64 1>>0 = %d, wanted 1\n", got) failed = true } - if got := div_int64_9223372036854775807_ssa(1); got != 0 { - fmt.Printf("div_int64 1/9223372036854775807 = %d, wanted 0\n", got) + if got := rsh_uint64_1_ssa(0); got != 0 { + fmt.Printf("rsh_uint64 0>>1 = %d, wanted 0\n", got) failed = true } - if got := div_9223372036854775807_int64_ssa(4294967296); got != 2147483647 { - fmt.Printf("div_int64 9223372036854775807/4294967296 = %d, wanted 2147483647\n", got) + if got := rsh_1_uint64_ssa(1); got != 0 { + fmt.Printf("rsh_uint64 1>>1 = %d, wanted 0\n", got) failed = true } - if got := div_int64_9223372036854775807_ssa(4294967296); got != 0 { - fmt.Printf("div_int64 4294967296/9223372036854775807 = %d, wanted 0\n", got) + if got := rsh_uint64_1_ssa(1); got != 0 { + fmt.Printf("rsh_uint64 1>>1 = %d, wanted 0\n", got) failed = true } - if got := div_9223372036854775807_int64_ssa(9223372036854775806); got != 1 { - fmt.Printf("div_int64 9223372036854775807/9223372036854775806 = %d, wanted 1\n", got) + if got := rsh_1_uint64_ssa(4294967296); got != 0 { + fmt.Printf("rsh_uint64 1>>4294967296 = %d, wanted 0\n", got) failed = true } - if got := div_int64_9223372036854775807_ssa(9223372036854775806); got != 0 { - fmt.Printf("div_int64 9223372036854775806/9223372036854775807 = %d, wanted 0\n", got) + if got := rsh_uint64_1_ssa(4294967296); got != 2147483648 { + fmt.Printf("rsh_uint64 4294967296>>1 = %d, wanted 2147483648\n", got) failed = true } - if got := div_9223372036854775807_int64_ssa(9223372036854775807); got != 1 { - fmt.Printf("div_int64 9223372036854775807/9223372036854775807 = %d, wanted 1\n", got) + if got := rsh_1_uint64_ssa(18446744073709551615); got != 0 { + fmt.Printf("rsh_uint64 1>>18446744073709551615 = %d, wanted 0\n", got) failed = true } - if got := div_int64_9223372036854775807_ssa(9223372036854775807); got != 1 { - fmt.Printf("div_int64 9223372036854775807/9223372036854775807 = %d, wanted 1\n", got) + if got := rsh_uint64_1_ssa(18446744073709551615); got != 9223372036854775807 { + fmt.Printf("rsh_uint64 18446744073709551615>>1 = %d, wanted 9223372036854775807\n", got) failed = true } - if got := div_0_uint32_ssa(1); got != 0 { - fmt.Printf("div_uint32 0/1 = %d, wanted 0\n", got) + if got := rsh_4294967296_uint64_ssa(0); got != 4294967296 { + fmt.Printf("rsh_uint64 4294967296>>0 = %d, wanted 4294967296\n", got) failed = true } - if got := div_0_uint32_ssa(4294967295); got != 0 { - fmt.Printf("div_uint32 0/4294967295 = %d, wanted 0\n", got) + if got := rsh_uint64_4294967296_ssa(0); got != 0 { + fmt.Printf("rsh_uint64 0>>4294967296 = %d, wanted 0\n", got) failed = true } - if got := div_uint32_1_ssa(0); got != 0 { - fmt.Printf("div_uint32 0/1 = %d, wanted 0\n", got) + if got := rsh_4294967296_uint64_ssa(1); got != 2147483648 { + fmt.Printf("rsh_uint64 4294967296>>1 = %d, wanted 2147483648\n", got) failed = true } - if got := div_1_uint32_ssa(1); got != 1 { - fmt.Printf("div_uint32 1/1 = %d, wanted 1\n", got) + if got := rsh_uint64_4294967296_ssa(1); got != 0 { + fmt.Printf("rsh_uint64 1>>4294967296 = %d, wanted 0\n", got) failed = true } - if got := div_uint32_1_ssa(1); got != 1 { - fmt.Printf("div_uint32 1/1 = %d, wanted 1\n", got) + if got := rsh_4294967296_uint64_ssa(4294967296); got != 0 { + fmt.Printf("rsh_uint64 4294967296>>4294967296 = %d, wanted 0\n", got) failed = true } - if got := div_1_uint32_ssa(4294967295); got != 0 { - fmt.Printf("div_uint32 1/4294967295 = %d, wanted 0\n", got) + if got := rsh_uint64_4294967296_ssa(4294967296); got != 0 { + fmt.Printf("rsh_uint64 4294967296>>4294967296 = %d, wanted 0\n", got) failed = true } - if got := div_uint32_1_ssa(4294967295); got != 4294967295 { - fmt.Printf("div_uint32 4294967295/1 = %d, wanted 4294967295\n", got) + if got := rsh_4294967296_uint64_ssa(18446744073709551615); got != 0 { + fmt.Printf("rsh_uint64 4294967296>>18446744073709551615 = %d, wanted 0\n", got) failed = true } - if got := div_uint32_4294967295_ssa(0); got != 0 { - fmt.Printf("div_uint32 0/4294967295 = %d, wanted 0\n", got) + if got := rsh_uint64_4294967296_ssa(18446744073709551615); got != 0 { + fmt.Printf("rsh_uint64 18446744073709551615>>4294967296 = %d, wanted 0\n", got) failed = true } - if got := div_4294967295_uint32_ssa(1); got != 4294967295 { - fmt.Printf("div_uint32 4294967295/1 = %d, wanted 4294967295\n", got) + if got := rsh_18446744073709551615_uint64_ssa(0); got != 18446744073709551615 { + fmt.Printf("rsh_uint64 18446744073709551615>>0 = %d, wanted 18446744073709551615\n", got) failed = true } - if got := div_uint32_4294967295_ssa(1); got != 0 { - fmt.Printf("div_uint32 1/4294967295 = %d, wanted 0\n", got) + if got := rsh_uint64_18446744073709551615_ssa(0); got != 0 { + fmt.Printf("rsh_uint64 0>>18446744073709551615 = %d, wanted 0\n", got) failed = true } - if got := div_4294967295_uint32_ssa(4294967295); got != 1 { - fmt.Printf("div_uint32 4294967295/4294967295 = %d, wanted 1\n", got) + if got := rsh_18446744073709551615_uint64_ssa(1); got != 9223372036854775807 { + fmt.Printf("rsh_uint64 18446744073709551615>>1 = %d, wanted 9223372036854775807\n", got) failed = true } - if got := div_uint32_4294967295_ssa(4294967295); got != 1 { - fmt.Printf("div_uint32 4294967295/4294967295 = %d, wanted 1\n", got) + if got := rsh_uint64_18446744073709551615_ssa(1); got != 0 { + fmt.Printf("rsh_uint64 1>>18446744073709551615 = %d, wanted 0\n", got) failed = true } - if got := div_Neg2147483648_int32_ssa(-2147483648); got != 1 { - fmt.Printf("div_int32 -2147483648/-2147483648 = %d, wanted 1\n", got) + if got := rsh_18446744073709551615_uint64_ssa(4294967296); got != 0 { + fmt.Printf("rsh_uint64 18446744073709551615>>4294967296 = %d, wanted 0\n", got) failed = true } - if got := div_int32_Neg2147483648_ssa(-2147483648); got != 1 { - fmt.Printf("div_int32 -2147483648/-2147483648 = %d, wanted 1\n", got) + if got := rsh_uint64_18446744073709551615_ssa(4294967296); got != 0 { + fmt.Printf("rsh_uint64 4294967296>>18446744073709551615 = %d, wanted 0\n", got) failed = true } - if got := div_Neg2147483648_int32_ssa(-2147483647); got != 1 { - fmt.Printf("div_int32 -2147483648/-2147483647 = %d, wanted 1\n", got) + if got := rsh_18446744073709551615_uint64_ssa(18446744073709551615); got != 0 { + fmt.Printf("rsh_uint64 18446744073709551615>>18446744073709551615 = %d, wanted 0\n", got) failed = true } - if got := div_int32_Neg2147483648_ssa(-2147483647); got != 0 { - fmt.Printf("div_int32 -2147483647/-2147483648 = %d, wanted 0\n", got) + if got := rsh_uint64_18446744073709551615_ssa(18446744073709551615); got != 0 { + fmt.Printf("rsh_uint64 18446744073709551615>>18446744073709551615 = %d, wanted 0\n", got) failed = true } - if got := div_Neg2147483648_int32_ssa(-1); got != -2147483648 { - fmt.Printf("div_int32 -2147483648/-1 = %d, wanted -2147483648\n", got) + if got := add_Neg9223372036854775808_int64_ssa(-9223372036854775808); got != 0 { + fmt.Printf("add_int64 -9223372036854775808+-9223372036854775808 = %d, wanted 0\n", got) failed = true } - if got := div_int32_Neg2147483648_ssa(-1); got != 0 { - fmt.Printf("div_int32 -1/-2147483648 = %d, wanted 0\n", got) + if got := add_int64_Neg9223372036854775808_ssa(-9223372036854775808); got != 0 { + fmt.Printf("add_int64 -9223372036854775808+-9223372036854775808 = %d, wanted 0\n", got) failed = true } - if got := div_int32_Neg2147483648_ssa(0); got != 0 { - fmt.Printf("div_int32 0/-2147483648 = %d, wanted 0\n", got) + if got := add_Neg9223372036854775808_int64_ssa(-9223372036854775807); got != 1 { + fmt.Printf("add_int64 -9223372036854775808+-9223372036854775807 = %d, wanted 1\n", got) failed = true } - if got := div_Neg2147483648_int32_ssa(1); got != -2147483648 { - fmt.Printf("div_int32 -2147483648/1 = %d, wanted -2147483648\n", got) + if got := add_int64_Neg9223372036854775808_ssa(-9223372036854775807); got != 1 { + fmt.Printf("add_int64 -9223372036854775807+-9223372036854775808 = %d, wanted 1\n", got) failed = true } - if got := div_int32_Neg2147483648_ssa(1); got != 0 { - fmt.Printf("div_int32 1/-2147483648 = %d, wanted 0\n", got) + if got := add_Neg9223372036854775808_int64_ssa(-4294967296); got != 9223372032559808512 { + fmt.Printf("add_int64 -9223372036854775808+-4294967296 = %d, wanted 9223372032559808512\n", got) failed = true } - if got := div_Neg2147483648_int32_ssa(2147483647); got != -1 { - fmt.Printf("div_int32 -2147483648/2147483647 = %d, wanted -1\n", got) + if got := add_int64_Neg9223372036854775808_ssa(-4294967296); got != 9223372032559808512 { + fmt.Printf("add_int64 -4294967296+-9223372036854775808 = %d, wanted 9223372032559808512\n", got) failed = true } - if got := div_int32_Neg2147483648_ssa(2147483647); got != 0 { - fmt.Printf("div_int32 2147483647/-2147483648 = %d, wanted 0\n", got) + if got := add_Neg9223372036854775808_int64_ssa(-1); got != 9223372036854775807 { + fmt.Printf("add_int64 -9223372036854775808+-1 = %d, wanted 9223372036854775807\n", got) failed = true } - if got := div_Neg2147483647_int32_ssa(-2147483648); got != 0 { - fmt.Printf("div_int32 -2147483647/-2147483648 = %d, wanted 0\n", got) + if got := add_int64_Neg9223372036854775808_ssa(-1); got != 9223372036854775807 { + fmt.Printf("add_int64 -1+-9223372036854775808 = %d, wanted 9223372036854775807\n", got) failed = true } - if got := div_int32_Neg2147483647_ssa(-2147483648); got != 1 { - fmt.Printf("div_int32 -2147483648/-2147483647 = %d, wanted 1\n", got) + if got := add_Neg9223372036854775808_int64_ssa(0); got != -9223372036854775808 { + fmt.Printf("add_int64 -9223372036854775808+0 = %d, wanted -9223372036854775808\n", got) failed = true } - if got := div_Neg2147483647_int32_ssa(-2147483647); got != 1 { - fmt.Printf("div_int32 -2147483647/-2147483647 = %d, wanted 1\n", got) + if got := add_int64_Neg9223372036854775808_ssa(0); got != -9223372036854775808 { + fmt.Printf("add_int64 0+-9223372036854775808 = %d, wanted -9223372036854775808\n", got) failed = true } - if got := div_int32_Neg2147483647_ssa(-2147483647); got != 1 { - fmt.Printf("div_int32 -2147483647/-2147483647 = %d, wanted 1\n", got) + if got := add_Neg9223372036854775808_int64_ssa(1); got != -9223372036854775807 { + fmt.Printf("add_int64 -9223372036854775808+1 = %d, wanted -9223372036854775807\n", got) failed = true } - if got := div_Neg2147483647_int32_ssa(-1); got != 2147483647 { - fmt.Printf("div_int32 -2147483647/-1 = %d, wanted 2147483647\n", got) + if got := add_int64_Neg9223372036854775808_ssa(1); got != -9223372036854775807 { + fmt.Printf("add_int64 1+-9223372036854775808 = %d, wanted -9223372036854775807\n", got) failed = true } - if got := div_int32_Neg2147483647_ssa(-1); got != 0 { - fmt.Printf("div_int32 -1/-2147483647 = %d, wanted 0\n", got) + if got := add_Neg9223372036854775808_int64_ssa(4294967296); got != -9223372032559808512 { + fmt.Printf("add_int64 -9223372036854775808+4294967296 = %d, wanted -9223372032559808512\n", got) failed = true } - if got := div_int32_Neg2147483647_ssa(0); got != 0 { - fmt.Printf("div_int32 0/-2147483647 = %d, wanted 0\n", got) + if got := add_int64_Neg9223372036854775808_ssa(4294967296); got != -9223372032559808512 { + fmt.Printf("add_int64 4294967296+-9223372036854775808 = %d, wanted -9223372032559808512\n", got) failed = true } - if got := div_Neg2147483647_int32_ssa(1); got != -2147483647 { - fmt.Printf("div_int32 -2147483647/1 = %d, wanted -2147483647\n", got) + if got := add_Neg9223372036854775808_int64_ssa(9223372036854775806); got != -2 { + fmt.Printf("add_int64 -9223372036854775808+9223372036854775806 = %d, wanted -2\n", got) failed = true } - if got := div_int32_Neg2147483647_ssa(1); got != 0 { - fmt.Printf("div_int32 1/-2147483647 = %d, wanted 0\n", got) + if got := add_int64_Neg9223372036854775808_ssa(9223372036854775806); got != -2 { + fmt.Printf("add_int64 9223372036854775806+-9223372036854775808 = %d, wanted -2\n", got) failed = true } - if got := div_Neg2147483647_int32_ssa(2147483647); got != -1 { - fmt.Printf("div_int32 -2147483647/2147483647 = %d, wanted -1\n", got) + if got := add_Neg9223372036854775808_int64_ssa(9223372036854775807); got != -1 { + fmt.Printf("add_int64 -9223372036854775808+9223372036854775807 = %d, wanted -1\n", got) failed = true } - if got := div_int32_Neg2147483647_ssa(2147483647); got != -1 { - fmt.Printf("div_int32 2147483647/-2147483647 = %d, wanted -1\n", got) + if got := add_int64_Neg9223372036854775808_ssa(9223372036854775807); got != -1 { + fmt.Printf("add_int64 9223372036854775807+-9223372036854775808 = %d, wanted -1\n", got) failed = true } - if got := div_Neg1_int32_ssa(-2147483648); got != 0 { - fmt.Printf("div_int32 -1/-2147483648 = %d, wanted 0\n", got) + if got := add_Neg9223372036854775807_int64_ssa(-9223372036854775808); got != 1 { + fmt.Printf("add_int64 -9223372036854775807+-9223372036854775808 = %d, wanted 1\n", got) failed = true } - if got := div_int32_Neg1_ssa(-2147483648); got != -2147483648 { - fmt.Printf("div_int32 -2147483648/-1 = %d, wanted -2147483648\n", got) + if got := add_int64_Neg9223372036854775807_ssa(-9223372036854775808); got != 1 { + fmt.Printf("add_int64 -9223372036854775808+-9223372036854775807 = %d, wanted 1\n", got) failed = true } - if got := div_Neg1_int32_ssa(-2147483647); got != 0 { - fmt.Printf("div_int32 -1/-2147483647 = %d, wanted 0\n", got) + if got := add_Neg9223372036854775807_int64_ssa(-9223372036854775807); got != 2 { + fmt.Printf("add_int64 -9223372036854775807+-9223372036854775807 = %d, wanted 2\n", got) failed = true } - if got := div_int32_Neg1_ssa(-2147483647); got != 2147483647 { - fmt.Printf("div_int32 -2147483647/-1 = %d, wanted 2147483647\n", got) + if got := add_int64_Neg9223372036854775807_ssa(-9223372036854775807); got != 2 { + fmt.Printf("add_int64 -9223372036854775807+-9223372036854775807 = %d, wanted 2\n", got) failed = true } - if got := div_Neg1_int32_ssa(-1); got != 1 { - fmt.Printf("div_int32 -1/-1 = %d, wanted 1\n", got) + if got := add_Neg9223372036854775807_int64_ssa(-4294967296); got != 9223372032559808513 { + fmt.Printf("add_int64 -9223372036854775807+-4294967296 = %d, wanted 9223372032559808513\n", got) failed = true } - if got := div_int32_Neg1_ssa(-1); got != 1 { - fmt.Printf("div_int32 -1/-1 = %d, wanted 1\n", got) + if got := add_int64_Neg9223372036854775807_ssa(-4294967296); got != 9223372032559808513 { + fmt.Printf("add_int64 -4294967296+-9223372036854775807 = %d, wanted 9223372032559808513\n", got) failed = true } - if got := div_int32_Neg1_ssa(0); got != 0 { - fmt.Printf("div_int32 0/-1 = %d, wanted 0\n", got) + if got := add_Neg9223372036854775807_int64_ssa(-1); got != -9223372036854775808 { + fmt.Printf("add_int64 -9223372036854775807+-1 = %d, wanted -9223372036854775808\n", got) failed = true } - if got := div_Neg1_int32_ssa(1); got != -1 { - fmt.Printf("div_int32 -1/1 = %d, wanted -1\n", got) + if got := add_int64_Neg9223372036854775807_ssa(-1); got != -9223372036854775808 { + fmt.Printf("add_int64 -1+-9223372036854775807 = %d, wanted -9223372036854775808\n", got) failed = true } - if got := div_int32_Neg1_ssa(1); got != -1 { - fmt.Printf("div_int32 1/-1 = %d, wanted -1\n", got) + if got := add_Neg9223372036854775807_int64_ssa(0); got != -9223372036854775807 { + fmt.Printf("add_int64 -9223372036854775807+0 = %d, wanted -9223372036854775807\n", got) failed = true } - if got := div_Neg1_int32_ssa(2147483647); got != 0 { - fmt.Printf("div_int32 -1/2147483647 = %d, wanted 0\n", got) + if got := add_int64_Neg9223372036854775807_ssa(0); got != -9223372036854775807 { + fmt.Printf("add_int64 0+-9223372036854775807 = %d, wanted -9223372036854775807\n", got) failed = true } - if got := div_int32_Neg1_ssa(2147483647); got != -2147483647 { - fmt.Printf("div_int32 2147483647/-1 = %d, wanted -2147483647\n", got) + if got := add_Neg9223372036854775807_int64_ssa(1); got != -9223372036854775806 { + fmt.Printf("add_int64 -9223372036854775807+1 = %d, wanted -9223372036854775806\n", got) failed = true } - if got := div_0_int32_ssa(-2147483648); got != 0 { - fmt.Printf("div_int32 0/-2147483648 = %d, wanted 0\n", got) + if got := add_int64_Neg9223372036854775807_ssa(1); got != -9223372036854775806 { + fmt.Printf("add_int64 1+-9223372036854775807 = %d, wanted -9223372036854775806\n", got) failed = true } - if got := div_0_int32_ssa(-2147483647); got != 0 { - fmt.Printf("div_int32 0/-2147483647 = %d, wanted 0\n", got) + if got := add_Neg9223372036854775807_int64_ssa(4294967296); got != -9223372032559808511 { + fmt.Printf("add_int64 -9223372036854775807+4294967296 = %d, wanted -9223372032559808511\n", got) failed = true } - if got := div_0_int32_ssa(-1); got != 0 { - fmt.Printf("div_int32 0/-1 = %d, wanted 0\n", got) + if got := add_int64_Neg9223372036854775807_ssa(4294967296); got != -9223372032559808511 { + fmt.Printf("add_int64 4294967296+-9223372036854775807 = %d, wanted -9223372032559808511\n", got) failed = true } - if got := div_0_int32_ssa(1); got != 0 { - fmt.Printf("div_int32 0/1 = %d, wanted 0\n", got) + if got := add_Neg9223372036854775807_int64_ssa(9223372036854775806); got != -1 { + fmt.Printf("add_int64 -9223372036854775807+9223372036854775806 = %d, wanted -1\n", got) failed = true } - if got := div_0_int32_ssa(2147483647); got != 0 { - fmt.Printf("div_int32 0/2147483647 = %d, wanted 0\n", got) + if got := add_int64_Neg9223372036854775807_ssa(9223372036854775806); got != -1 { + fmt.Printf("add_int64 9223372036854775806+-9223372036854775807 = %d, wanted -1\n", got) failed = true } - if got := div_1_int32_ssa(-2147483648); got != 0 { - fmt.Printf("div_int32 1/-2147483648 = %d, wanted 0\n", got) + if got := add_Neg9223372036854775807_int64_ssa(9223372036854775807); got != 0 { + fmt.Printf("add_int64 -9223372036854775807+9223372036854775807 = %d, wanted 0\n", got) failed = true } - if got := div_int32_1_ssa(-2147483648); got != -2147483648 { - fmt.Printf("div_int32 -2147483648/1 = %d, wanted -2147483648\n", got) + if got := add_int64_Neg9223372036854775807_ssa(9223372036854775807); got != 0 { + fmt.Printf("add_int64 9223372036854775807+-9223372036854775807 = %d, wanted 0\n", got) failed = true } - if got := div_1_int32_ssa(-2147483647); got != 0 { - fmt.Printf("div_int32 1/-2147483647 = %d, wanted 0\n", got) + if got := add_Neg4294967296_int64_ssa(-9223372036854775808); got != 9223372032559808512 { + fmt.Printf("add_int64 -4294967296+-9223372036854775808 = %d, wanted 9223372032559808512\n", got) failed = true } - if got := div_int32_1_ssa(-2147483647); got != -2147483647 { - fmt.Printf("div_int32 -2147483647/1 = %d, wanted -2147483647\n", got) + if got := add_int64_Neg4294967296_ssa(-9223372036854775808); got != 9223372032559808512 { + fmt.Printf("add_int64 -9223372036854775808+-4294967296 = %d, wanted 9223372032559808512\n", got) failed = true } - if got := div_1_int32_ssa(-1); got != -1 { - fmt.Printf("div_int32 1/-1 = %d, wanted -1\n", got) + if got := add_Neg4294967296_int64_ssa(-9223372036854775807); got != 9223372032559808513 { + fmt.Printf("add_int64 -4294967296+-9223372036854775807 = %d, wanted 9223372032559808513\n", got) failed = true } - if got := div_int32_1_ssa(-1); got != -1 { - fmt.Printf("div_int32 -1/1 = %d, wanted -1\n", got) + if got := add_int64_Neg4294967296_ssa(-9223372036854775807); got != 9223372032559808513 { + fmt.Printf("add_int64 -9223372036854775807+-4294967296 = %d, wanted 9223372032559808513\n", got) failed = true } - if got := div_int32_1_ssa(0); got != 0 { - fmt.Printf("div_int32 0/1 = %d, wanted 0\n", got) + if got := add_Neg4294967296_int64_ssa(-4294967296); got != -8589934592 { + fmt.Printf("add_int64 -4294967296+-4294967296 = %d, wanted -8589934592\n", got) failed = true } - if got := div_1_int32_ssa(1); got != 1 { - fmt.Printf("div_int32 1/1 = %d, wanted 1\n", got) + if got := add_int64_Neg4294967296_ssa(-4294967296); got != -8589934592 { + fmt.Printf("add_int64 -4294967296+-4294967296 = %d, wanted -8589934592\n", got) failed = true } - if got := div_int32_1_ssa(1); got != 1 { - fmt.Printf("div_int32 1/1 = %d, wanted 1\n", got) + if got := add_Neg4294967296_int64_ssa(-1); got != -4294967297 { + fmt.Printf("add_int64 -4294967296+-1 = %d, wanted -4294967297\n", got) failed = true } - if got := div_1_int32_ssa(2147483647); got != 0 { - fmt.Printf("div_int32 1/2147483647 = %d, wanted 0\n", got) + if got := add_int64_Neg4294967296_ssa(-1); got != -4294967297 { + fmt.Printf("add_int64 -1+-4294967296 = %d, wanted -4294967297\n", got) failed = true } - if got := div_int32_1_ssa(2147483647); got != 2147483647 { - fmt.Printf("div_int32 2147483647/1 = %d, wanted 2147483647\n", got) + if got := add_Neg4294967296_int64_ssa(0); got != -4294967296 { + fmt.Printf("add_int64 -4294967296+0 = %d, wanted -4294967296\n", got) failed = true } - if got := div_2147483647_int32_ssa(-2147483648); got != 0 { - fmt.Printf("div_int32 2147483647/-2147483648 = %d, wanted 0\n", got) + if got := add_int64_Neg4294967296_ssa(0); got != -4294967296 { + fmt.Printf("add_int64 0+-4294967296 = %d, wanted -4294967296\n", got) failed = true } - if got := div_int32_2147483647_ssa(-2147483648); got != -1 { - fmt.Printf("div_int32 -2147483648/2147483647 = %d, wanted -1\n", got) + if got := add_Neg4294967296_int64_ssa(1); got != -4294967295 { + fmt.Printf("add_int64 -4294967296+1 = %d, wanted -4294967295\n", got) failed = true } - if got := div_2147483647_int32_ssa(-2147483647); got != -1 { - fmt.Printf("div_int32 2147483647/-2147483647 = %d, wanted -1\n", got) + if got := add_int64_Neg4294967296_ssa(1); got != -4294967295 { + fmt.Printf("add_int64 1+-4294967296 = %d, wanted -4294967295\n", got) failed = true } - if got := div_int32_2147483647_ssa(-2147483647); got != -1 { - fmt.Printf("div_int32 -2147483647/2147483647 = %d, wanted -1\n", got) + if got := add_Neg4294967296_int64_ssa(4294967296); got != 0 { + fmt.Printf("add_int64 -4294967296+4294967296 = %d, wanted 0\n", got) failed = true } - if got := div_2147483647_int32_ssa(-1); got != -2147483647 { - fmt.Printf("div_int32 2147483647/-1 = %d, wanted -2147483647\n", got) + if got := add_int64_Neg4294967296_ssa(4294967296); got != 0 { + fmt.Printf("add_int64 4294967296+-4294967296 = %d, wanted 0\n", got) failed = true } - if got := div_int32_2147483647_ssa(-1); got != 0 { - fmt.Printf("div_int32 -1/2147483647 = %d, wanted 0\n", got) + if got := add_Neg4294967296_int64_ssa(9223372036854775806); got != 9223372032559808510 { + fmt.Printf("add_int64 -4294967296+9223372036854775806 = %d, wanted 9223372032559808510\n", got) failed = true } - if got := div_int32_2147483647_ssa(0); got != 0 { - fmt.Printf("div_int32 0/2147483647 = %d, wanted 0\n", got) + if got := add_int64_Neg4294967296_ssa(9223372036854775806); got != 9223372032559808510 { + fmt.Printf("add_int64 9223372036854775806+-4294967296 = %d, wanted 9223372032559808510\n", got) failed = true } - if got := div_2147483647_int32_ssa(1); got != 2147483647 { - fmt.Printf("div_int32 2147483647/1 = %d, wanted 2147483647\n", got) + if got := add_Neg4294967296_int64_ssa(9223372036854775807); got != 9223372032559808511 { + fmt.Printf("add_int64 -4294967296+9223372036854775807 = %d, wanted 9223372032559808511\n", got) failed = true } - if got := div_int32_2147483647_ssa(1); got != 0 { - fmt.Printf("div_int32 1/2147483647 = %d, wanted 0\n", got) + if got := add_int64_Neg4294967296_ssa(9223372036854775807); got != 9223372032559808511 { + fmt.Printf("add_int64 9223372036854775807+-4294967296 = %d, wanted 9223372032559808511\n", got) failed = true } - if got := div_2147483647_int32_ssa(2147483647); got != 1 { - fmt.Printf("div_int32 2147483647/2147483647 = %d, wanted 1\n", got) + if got := add_Neg1_int64_ssa(-9223372036854775808); got != 9223372036854775807 { + fmt.Printf("add_int64 -1+-9223372036854775808 = %d, wanted 9223372036854775807\n", got) failed = true } - if got := div_int32_2147483647_ssa(2147483647); got != 1 { - fmt.Printf("div_int32 2147483647/2147483647 = %d, wanted 1\n", got) + if got := add_int64_Neg1_ssa(-9223372036854775808); got != 9223372036854775807 { + fmt.Printf("add_int64 -9223372036854775808+-1 = %d, wanted 9223372036854775807\n", got) failed = true } - if got := div_0_uint16_ssa(1); got != 0 { - fmt.Printf("div_uint16 0/1 = %d, wanted 0\n", got) + if got := add_Neg1_int64_ssa(-9223372036854775807); got != -9223372036854775808 { + fmt.Printf("add_int64 -1+-9223372036854775807 = %d, wanted -9223372036854775808\n", got) failed = true } - if got := div_0_uint16_ssa(65535); got != 0 { - fmt.Printf("div_uint16 0/65535 = %d, wanted 0\n", got) + if got := add_int64_Neg1_ssa(-9223372036854775807); got != -9223372036854775808 { + fmt.Printf("add_int64 -9223372036854775807+-1 = %d, wanted -9223372036854775808\n", got) failed = true } - if got := div_uint16_1_ssa(0); got != 0 { - fmt.Printf("div_uint16 0/1 = %d, wanted 0\n", got) + if got := add_Neg1_int64_ssa(-4294967296); got != -4294967297 { + fmt.Printf("add_int64 -1+-4294967296 = %d, wanted -4294967297\n", got) failed = true } - if got := div_1_uint16_ssa(1); got != 1 { - fmt.Printf("div_uint16 1/1 = %d, wanted 1\n", got) + if got := add_int64_Neg1_ssa(-4294967296); got != -4294967297 { + fmt.Printf("add_int64 -4294967296+-1 = %d, wanted -4294967297\n", got) failed = true } - if got := div_uint16_1_ssa(1); got != 1 { - fmt.Printf("div_uint16 1/1 = %d, wanted 1\n", got) + if got := add_Neg1_int64_ssa(-1); got != -2 { + fmt.Printf("add_int64 -1+-1 = %d, wanted -2\n", got) failed = true } - if got := div_1_uint16_ssa(65535); got != 0 { - fmt.Printf("div_uint16 1/65535 = %d, wanted 0\n", got) + if got := add_int64_Neg1_ssa(-1); got != -2 { + fmt.Printf("add_int64 -1+-1 = %d, wanted -2\n", got) failed = true } - if got := div_uint16_1_ssa(65535); got != 65535 { - fmt.Printf("div_uint16 65535/1 = %d, wanted 65535\n", got) + if got := add_Neg1_int64_ssa(0); got != -1 { + fmt.Printf("add_int64 -1+0 = %d, wanted -1\n", got) failed = true } - if got := div_uint16_65535_ssa(0); got != 0 { - fmt.Printf("div_uint16 0/65535 = %d, wanted 0\n", got) + if got := add_int64_Neg1_ssa(0); got != -1 { + fmt.Printf("add_int64 0+-1 = %d, wanted -1\n", got) failed = true } - if got := div_65535_uint16_ssa(1); got != 65535 { - fmt.Printf("div_uint16 65535/1 = %d, wanted 65535\n", got) + if got := add_Neg1_int64_ssa(1); got != 0 { + fmt.Printf("add_int64 -1+1 = %d, wanted 0\n", got) failed = true } - if got := div_uint16_65535_ssa(1); got != 0 { - fmt.Printf("div_uint16 1/65535 = %d, wanted 0\n", got) + if got := add_int64_Neg1_ssa(1); got != 0 { + fmt.Printf("add_int64 1+-1 = %d, wanted 0\n", got) failed = true } - if got := div_65535_uint16_ssa(65535); got != 1 { - fmt.Printf("div_uint16 65535/65535 = %d, wanted 1\n", got) + if got := add_Neg1_int64_ssa(4294967296); got != 4294967295 { + fmt.Printf("add_int64 -1+4294967296 = %d, wanted 4294967295\n", got) failed = true } - if got := div_uint16_65535_ssa(65535); got != 1 { - fmt.Printf("div_uint16 65535/65535 = %d, wanted 1\n", got) + if got := add_int64_Neg1_ssa(4294967296); got != 4294967295 { + fmt.Printf("add_int64 4294967296+-1 = %d, wanted 4294967295\n", got) failed = true } - if got := div_Neg32768_int16_ssa(-32768); got != 1 { - fmt.Printf("div_int16 -32768/-32768 = %d, wanted 1\n", got) + if got := add_Neg1_int64_ssa(9223372036854775806); got != 9223372036854775805 { + fmt.Printf("add_int64 -1+9223372036854775806 = %d, wanted 9223372036854775805\n", got) failed = true } - if got := div_int16_Neg32768_ssa(-32768); got != 1 { - fmt.Printf("div_int16 -32768/-32768 = %d, wanted 1\n", got) + if got := add_int64_Neg1_ssa(9223372036854775806); got != 9223372036854775805 { + fmt.Printf("add_int64 9223372036854775806+-1 = %d, wanted 9223372036854775805\n", got) failed = true } - if got := div_Neg32768_int16_ssa(-32767); got != 1 { - fmt.Printf("div_int16 -32768/-32767 = %d, wanted 1\n", got) + if got := add_Neg1_int64_ssa(9223372036854775807); got != 9223372036854775806 { + fmt.Printf("add_int64 -1+9223372036854775807 = %d, wanted 9223372036854775806\n", got) failed = true } - if got := div_int16_Neg32768_ssa(-32767); got != 0 { - fmt.Printf("div_int16 -32767/-32768 = %d, wanted 0\n", got) + if got := add_int64_Neg1_ssa(9223372036854775807); got != 9223372036854775806 { + fmt.Printf("add_int64 9223372036854775807+-1 = %d, wanted 9223372036854775806\n", got) failed = true } - if got := div_Neg32768_int16_ssa(-1); got != -32768 { - fmt.Printf("div_int16 -32768/-1 = %d, wanted -32768\n", got) + if got := add_0_int64_ssa(-9223372036854775808); got != -9223372036854775808 { + fmt.Printf("add_int64 0+-9223372036854775808 = %d, wanted -9223372036854775808\n", got) failed = true } - if got := div_int16_Neg32768_ssa(-1); got != 0 { - fmt.Printf("div_int16 -1/-32768 = %d, wanted 0\n", got) + if got := add_int64_0_ssa(-9223372036854775808); got != -9223372036854775808 { + fmt.Printf("add_int64 -9223372036854775808+0 = %d, wanted -9223372036854775808\n", got) failed = true } - if got := div_int16_Neg32768_ssa(0); got != 0 { - fmt.Printf("div_int16 0/-32768 = %d, wanted 0\n", got) + if got := add_0_int64_ssa(-9223372036854775807); got != -9223372036854775807 { + fmt.Printf("add_int64 0+-9223372036854775807 = %d, wanted -9223372036854775807\n", got) failed = true } - if got := div_Neg32768_int16_ssa(1); got != -32768 { - fmt.Printf("div_int16 -32768/1 = %d, wanted -32768\n", got) + if got := add_int64_0_ssa(-9223372036854775807); got != -9223372036854775807 { + fmt.Printf("add_int64 -9223372036854775807+0 = %d, wanted -9223372036854775807\n", got) failed = true } - if got := div_int16_Neg32768_ssa(1); got != 0 { - fmt.Printf("div_int16 1/-32768 = %d, wanted 0\n", got) + if got := add_0_int64_ssa(-4294967296); got != -4294967296 { + fmt.Printf("add_int64 0+-4294967296 = %d, wanted -4294967296\n", got) failed = true } - if got := div_Neg32768_int16_ssa(32766); got != -1 { - fmt.Printf("div_int16 -32768/32766 = %d, wanted -1\n", got) + if got := add_int64_0_ssa(-4294967296); got != -4294967296 { + fmt.Printf("add_int64 -4294967296+0 = %d, wanted -4294967296\n", got) failed = true } - if got := div_int16_Neg32768_ssa(32766); got != 0 { - fmt.Printf("div_int16 32766/-32768 = %d, wanted 0\n", got) + if got := add_0_int64_ssa(-1); got != -1 { + fmt.Printf("add_int64 0+-1 = %d, wanted -1\n", got) failed = true } - if got := div_Neg32768_int16_ssa(32767); got != -1 { - fmt.Printf("div_int16 -32768/32767 = %d, wanted -1\n", got) + if got := add_int64_0_ssa(-1); got != -1 { + fmt.Printf("add_int64 -1+0 = %d, wanted -1\n", got) failed = true } - if got := div_int16_Neg32768_ssa(32767); got != 0 { - fmt.Printf("div_int16 32767/-32768 = %d, wanted 0\n", got) + if got := add_0_int64_ssa(0); got != 0 { + fmt.Printf("add_int64 0+0 = %d, wanted 0\n", got) failed = true } - if got := div_Neg32767_int16_ssa(-32768); got != 0 { - fmt.Printf("div_int16 -32767/-32768 = %d, wanted 0\n", got) + if got := add_int64_0_ssa(0); got != 0 { + fmt.Printf("add_int64 0+0 = %d, wanted 0\n", got) failed = true } - if got := div_int16_Neg32767_ssa(-32768); got != 1 { - fmt.Printf("div_int16 -32768/-32767 = %d, wanted 1\n", got) + if got := add_0_int64_ssa(1); got != 1 { + fmt.Printf("add_int64 0+1 = %d, wanted 1\n", got) failed = true } - if got := div_Neg32767_int16_ssa(-32767); got != 1 { - fmt.Printf("div_int16 -32767/-32767 = %d, wanted 1\n", got) + if got := add_int64_0_ssa(1); got != 1 { + fmt.Printf("add_int64 1+0 = %d, wanted 1\n", got) failed = true } - if got := div_int16_Neg32767_ssa(-32767); got != 1 { - fmt.Printf("div_int16 -32767/-32767 = %d, wanted 1\n", got) + if got := add_0_int64_ssa(4294967296); got != 4294967296 { + fmt.Printf("add_int64 0+4294967296 = %d, wanted 4294967296\n", got) failed = true } - if got := div_Neg32767_int16_ssa(-1); got != 32767 { - fmt.Printf("div_int16 -32767/-1 = %d, wanted 32767\n", got) + if got := add_int64_0_ssa(4294967296); got != 4294967296 { + fmt.Printf("add_int64 4294967296+0 = %d, wanted 4294967296\n", got) failed = true } - if got := div_int16_Neg32767_ssa(-1); got != 0 { - fmt.Printf("div_int16 -1/-32767 = %d, wanted 0\n", got) + if got := add_0_int64_ssa(9223372036854775806); got != 9223372036854775806 { + fmt.Printf("add_int64 0+9223372036854775806 = %d, wanted 9223372036854775806\n", got) failed = true } - if got := div_int16_Neg32767_ssa(0); got != 0 { - fmt.Printf("div_int16 0/-32767 = %d, wanted 0\n", got) + if got := add_int64_0_ssa(9223372036854775806); got != 9223372036854775806 { + fmt.Printf("add_int64 9223372036854775806+0 = %d, wanted 9223372036854775806\n", got) failed = true } - if got := div_Neg32767_int16_ssa(1); got != -32767 { - fmt.Printf("div_int16 -32767/1 = %d, wanted -32767\n", got) + if got := add_0_int64_ssa(9223372036854775807); got != 9223372036854775807 { + fmt.Printf("add_int64 0+9223372036854775807 = %d, wanted 9223372036854775807\n", got) failed = true } - if got := div_int16_Neg32767_ssa(1); got != 0 { - fmt.Printf("div_int16 1/-32767 = %d, wanted 0\n", got) + if got := add_int64_0_ssa(9223372036854775807); got != 9223372036854775807 { + fmt.Printf("add_int64 9223372036854775807+0 = %d, wanted 9223372036854775807\n", got) failed = true } - if got := div_Neg32767_int16_ssa(32766); got != -1 { - fmt.Printf("div_int16 -32767/32766 = %d, wanted -1\n", got) + if got := add_1_int64_ssa(-9223372036854775808); got != -9223372036854775807 { + fmt.Printf("add_int64 1+-9223372036854775808 = %d, wanted -9223372036854775807\n", got) failed = true } - if got := div_int16_Neg32767_ssa(32766); got != 0 { - fmt.Printf("div_int16 32766/-32767 = %d, wanted 0\n", got) + if got := add_int64_1_ssa(-9223372036854775808); got != -9223372036854775807 { + fmt.Printf("add_int64 -9223372036854775808+1 = %d, wanted -9223372036854775807\n", got) failed = true } - if got := div_Neg32767_int16_ssa(32767); got != -1 { - fmt.Printf("div_int16 -32767/32767 = %d, wanted -1\n", got) + if got := add_1_int64_ssa(-9223372036854775807); got != -9223372036854775806 { + fmt.Printf("add_int64 1+-9223372036854775807 = %d, wanted -9223372036854775806\n", got) failed = true } - if got := div_int16_Neg32767_ssa(32767); got != -1 { - fmt.Printf("div_int16 32767/-32767 = %d, wanted -1\n", got) + if got := add_int64_1_ssa(-9223372036854775807); got != -9223372036854775806 { + fmt.Printf("add_int64 -9223372036854775807+1 = %d, wanted -9223372036854775806\n", got) failed = true } - if got := div_Neg1_int16_ssa(-32768); got != 0 { - fmt.Printf("div_int16 -1/-32768 = %d, wanted 0\n", got) + if got := add_1_int64_ssa(-4294967296); got != -4294967295 { + fmt.Printf("add_int64 1+-4294967296 = %d, wanted -4294967295\n", got) failed = true } - if got := div_int16_Neg1_ssa(-32768); got != -32768 { - fmt.Printf("div_int16 -32768/-1 = %d, wanted -32768\n", got) + if got := add_int64_1_ssa(-4294967296); got != -4294967295 { + fmt.Printf("add_int64 -4294967296+1 = %d, wanted -4294967295\n", got) failed = true } - if got := div_Neg1_int16_ssa(-32767); got != 0 { - fmt.Printf("div_int16 -1/-32767 = %d, wanted 0\n", got) + if got := add_1_int64_ssa(-1); got != 0 { + fmt.Printf("add_int64 1+-1 = %d, wanted 0\n", got) failed = true } - if got := div_int16_Neg1_ssa(-32767); got != 32767 { - fmt.Printf("div_int16 -32767/-1 = %d, wanted 32767\n", got) + if got := add_int64_1_ssa(-1); got != 0 { + fmt.Printf("add_int64 -1+1 = %d, wanted 0\n", got) failed = true } - if got := div_Neg1_int16_ssa(-1); got != 1 { - fmt.Printf("div_int16 -1/-1 = %d, wanted 1\n", got) + if got := add_1_int64_ssa(0); got != 1 { + fmt.Printf("add_int64 1+0 = %d, wanted 1\n", got) failed = true } - if got := div_int16_Neg1_ssa(-1); got != 1 { - fmt.Printf("div_int16 -1/-1 = %d, wanted 1\n", got) + if got := add_int64_1_ssa(0); got != 1 { + fmt.Printf("add_int64 0+1 = %d, wanted 1\n", got) failed = true } - if got := div_int16_Neg1_ssa(0); got != 0 { - fmt.Printf("div_int16 0/-1 = %d, wanted 0\n", got) + if got := add_1_int64_ssa(1); got != 2 { + fmt.Printf("add_int64 1+1 = %d, wanted 2\n", got) failed = true } - if got := div_Neg1_int16_ssa(1); got != -1 { - fmt.Printf("div_int16 -1/1 = %d, wanted -1\n", got) + if got := add_int64_1_ssa(1); got != 2 { + fmt.Printf("add_int64 1+1 = %d, wanted 2\n", got) failed = true } - if got := div_int16_Neg1_ssa(1); got != -1 { - fmt.Printf("div_int16 1/-1 = %d, wanted -1\n", got) + if got := add_1_int64_ssa(4294967296); got != 4294967297 { + fmt.Printf("add_int64 1+4294967296 = %d, wanted 4294967297\n", got) failed = true } - if got := div_Neg1_int16_ssa(32766); got != 0 { - fmt.Printf("div_int16 -1/32766 = %d, wanted 0\n", got) + if got := add_int64_1_ssa(4294967296); got != 4294967297 { + fmt.Printf("add_int64 4294967296+1 = %d, wanted 4294967297\n", got) failed = true } - if got := div_int16_Neg1_ssa(32766); got != -32766 { - fmt.Printf("div_int16 32766/-1 = %d, wanted -32766\n", got) + if got := add_1_int64_ssa(9223372036854775806); got != 9223372036854775807 { + fmt.Printf("add_int64 1+9223372036854775806 = %d, wanted 9223372036854775807\n", got) failed = true } - if got := div_Neg1_int16_ssa(32767); got != 0 { - fmt.Printf("div_int16 -1/32767 = %d, wanted 0\n", got) + if got := add_int64_1_ssa(9223372036854775806); got != 9223372036854775807 { + fmt.Printf("add_int64 9223372036854775806+1 = %d, wanted 9223372036854775807\n", got) failed = true } - if got := div_int16_Neg1_ssa(32767); got != -32767 { - fmt.Printf("div_int16 32767/-1 = %d, wanted -32767\n", got) + if got := add_1_int64_ssa(9223372036854775807); got != -9223372036854775808 { + fmt.Printf("add_int64 1+9223372036854775807 = %d, wanted -9223372036854775808\n", got) failed = true } - if got := div_0_int16_ssa(-32768); got != 0 { - fmt.Printf("div_int16 0/-32768 = %d, wanted 0\n", got) + if got := add_int64_1_ssa(9223372036854775807); got != -9223372036854775808 { + fmt.Printf("add_int64 9223372036854775807+1 = %d, wanted -9223372036854775808\n", got) failed = true } - if got := div_0_int16_ssa(-32767); got != 0 { - fmt.Printf("div_int16 0/-32767 = %d, wanted 0\n", got) + if got := add_4294967296_int64_ssa(-9223372036854775808); got != -9223372032559808512 { + fmt.Printf("add_int64 4294967296+-9223372036854775808 = %d, wanted -9223372032559808512\n", got) failed = true } - if got := div_0_int16_ssa(-1); got != 0 { - fmt.Printf("div_int16 0/-1 = %d, wanted 0\n", got) + if got := add_int64_4294967296_ssa(-9223372036854775808); got != -9223372032559808512 { + fmt.Printf("add_int64 -9223372036854775808+4294967296 = %d, wanted -9223372032559808512\n", got) failed = true } - if got := div_0_int16_ssa(1); got != 0 { - fmt.Printf("div_int16 0/1 = %d, wanted 0\n", got) + if got := add_4294967296_int64_ssa(-9223372036854775807); got != -9223372032559808511 { + fmt.Printf("add_int64 4294967296+-9223372036854775807 = %d, wanted -9223372032559808511\n", got) failed = true } - if got := div_0_int16_ssa(32766); got != 0 { - fmt.Printf("div_int16 0/32766 = %d, wanted 0\n", got) + if got := add_int64_4294967296_ssa(-9223372036854775807); got != -9223372032559808511 { + fmt.Printf("add_int64 -9223372036854775807+4294967296 = %d, wanted -9223372032559808511\n", got) failed = true } - if got := div_0_int16_ssa(32767); got != 0 { - fmt.Printf("div_int16 0/32767 = %d, wanted 0\n", got) + if got := add_4294967296_int64_ssa(-4294967296); got != 0 { + fmt.Printf("add_int64 4294967296+-4294967296 = %d, wanted 0\n", got) failed = true } - if got := div_1_int16_ssa(-32768); got != 0 { - fmt.Printf("div_int16 1/-32768 = %d, wanted 0\n", got) + if got := add_int64_4294967296_ssa(-4294967296); got != 0 { + fmt.Printf("add_int64 -4294967296+4294967296 = %d, wanted 0\n", got) failed = true } - if got := div_int16_1_ssa(-32768); got != -32768 { - fmt.Printf("div_int16 -32768/1 = %d, wanted -32768\n", got) + if got := add_4294967296_int64_ssa(-1); got != 4294967295 { + fmt.Printf("add_int64 4294967296+-1 = %d, wanted 4294967295\n", got) failed = true } - if got := div_1_int16_ssa(-32767); got != 0 { - fmt.Printf("div_int16 1/-32767 = %d, wanted 0\n", got) + if got := add_int64_4294967296_ssa(-1); got != 4294967295 { + fmt.Printf("add_int64 -1+4294967296 = %d, wanted 4294967295\n", got) failed = true } - if got := div_int16_1_ssa(-32767); got != -32767 { - fmt.Printf("div_int16 -32767/1 = %d, wanted -32767\n", got) + if got := add_4294967296_int64_ssa(0); got != 4294967296 { + fmt.Printf("add_int64 4294967296+0 = %d, wanted 4294967296\n", got) failed = true } - if got := div_1_int16_ssa(-1); got != -1 { - fmt.Printf("div_int16 1/-1 = %d, wanted -1\n", got) + if got := add_int64_4294967296_ssa(0); got != 4294967296 { + fmt.Printf("add_int64 0+4294967296 = %d, wanted 4294967296\n", got) failed = true } - if got := div_int16_1_ssa(-1); got != -1 { - fmt.Printf("div_int16 -1/1 = %d, wanted -1\n", got) + if got := add_4294967296_int64_ssa(1); got != 4294967297 { + fmt.Printf("add_int64 4294967296+1 = %d, wanted 4294967297\n", got) failed = true } - if got := div_int16_1_ssa(0); got != 0 { - fmt.Printf("div_int16 0/1 = %d, wanted 0\n", got) + if got := add_int64_4294967296_ssa(1); got != 4294967297 { + fmt.Printf("add_int64 1+4294967296 = %d, wanted 4294967297\n", got) failed = true } - if got := div_1_int16_ssa(1); got != 1 { - fmt.Printf("div_int16 1/1 = %d, wanted 1\n", got) + if got := add_4294967296_int64_ssa(4294967296); got != 8589934592 { + fmt.Printf("add_int64 4294967296+4294967296 = %d, wanted 8589934592\n", got) + failed = true + } + + if got := add_int64_4294967296_ssa(4294967296); got != 8589934592 { + fmt.Printf("add_int64 4294967296+4294967296 = %d, wanted 8589934592\n", got) + failed = true + } + + if got := add_4294967296_int64_ssa(9223372036854775806); got != -9223372032559808514 { + fmt.Printf("add_int64 4294967296+9223372036854775806 = %d, wanted -9223372032559808514\n", got) + failed = true + } + + if got := add_int64_4294967296_ssa(9223372036854775806); got != -9223372032559808514 { + fmt.Printf("add_int64 9223372036854775806+4294967296 = %d, wanted -9223372032559808514\n", got) + failed = true + } + + if got := add_4294967296_int64_ssa(9223372036854775807); got != -9223372032559808513 { + fmt.Printf("add_int64 4294967296+9223372036854775807 = %d, wanted -9223372032559808513\n", got) + failed = true + } + + if got := add_int64_4294967296_ssa(9223372036854775807); got != -9223372032559808513 { + fmt.Printf("add_int64 9223372036854775807+4294967296 = %d, wanted -9223372032559808513\n", got) + failed = true + } + + if got := add_9223372036854775806_int64_ssa(-9223372036854775808); got != -2 { + fmt.Printf("add_int64 9223372036854775806+-9223372036854775808 = %d, wanted -2\n", got) + failed = true + } + + if got := add_int64_9223372036854775806_ssa(-9223372036854775808); got != -2 { + fmt.Printf("add_int64 -9223372036854775808+9223372036854775806 = %d, wanted -2\n", got) + failed = true + } + + if got := add_9223372036854775806_int64_ssa(-9223372036854775807); got != -1 { + fmt.Printf("add_int64 9223372036854775806+-9223372036854775807 = %d, wanted -1\n", got) + failed = true + } + + if got := add_int64_9223372036854775806_ssa(-9223372036854775807); got != -1 { + fmt.Printf("add_int64 -9223372036854775807+9223372036854775806 = %d, wanted -1\n", got) + failed = true + } + + if got := add_9223372036854775806_int64_ssa(-4294967296); got != 9223372032559808510 { + fmt.Printf("add_int64 9223372036854775806+-4294967296 = %d, wanted 9223372032559808510\n", got) + failed = true + } + + if got := add_int64_9223372036854775806_ssa(-4294967296); got != 9223372032559808510 { + fmt.Printf("add_int64 -4294967296+9223372036854775806 = %d, wanted 9223372032559808510\n", got) + failed = true + } + + if got := add_9223372036854775806_int64_ssa(-1); got != 9223372036854775805 { + fmt.Printf("add_int64 9223372036854775806+-1 = %d, wanted 9223372036854775805\n", got) + failed = true + } + + if got := add_int64_9223372036854775806_ssa(-1); got != 9223372036854775805 { + fmt.Printf("add_int64 -1+9223372036854775806 = %d, wanted 9223372036854775805\n", got) + failed = true + } + + if got := add_9223372036854775806_int64_ssa(0); got != 9223372036854775806 { + fmt.Printf("add_int64 9223372036854775806+0 = %d, wanted 9223372036854775806\n", got) + failed = true + } + + if got := add_int64_9223372036854775806_ssa(0); got != 9223372036854775806 { + fmt.Printf("add_int64 0+9223372036854775806 = %d, wanted 9223372036854775806\n", got) + failed = true + } + + if got := add_9223372036854775806_int64_ssa(1); got != 9223372036854775807 { + fmt.Printf("add_int64 9223372036854775806+1 = %d, wanted 9223372036854775807\n", got) + failed = true + } + + if got := add_int64_9223372036854775806_ssa(1); got != 9223372036854775807 { + fmt.Printf("add_int64 1+9223372036854775806 = %d, wanted 9223372036854775807\n", got) + failed = true + } + + if got := add_9223372036854775806_int64_ssa(4294967296); got != -9223372032559808514 { + fmt.Printf("add_int64 9223372036854775806+4294967296 = %d, wanted -9223372032559808514\n", got) + failed = true + } + + if got := add_int64_9223372036854775806_ssa(4294967296); got != -9223372032559808514 { + fmt.Printf("add_int64 4294967296+9223372036854775806 = %d, wanted -9223372032559808514\n", got) + failed = true + } + + if got := add_9223372036854775806_int64_ssa(9223372036854775806); got != -4 { + fmt.Printf("add_int64 9223372036854775806+9223372036854775806 = %d, wanted -4\n", got) + failed = true + } + + if got := add_int64_9223372036854775806_ssa(9223372036854775806); got != -4 { + fmt.Printf("add_int64 9223372036854775806+9223372036854775806 = %d, wanted -4\n", got) + failed = true + } + + if got := add_9223372036854775806_int64_ssa(9223372036854775807); got != -3 { + fmt.Printf("add_int64 9223372036854775806+9223372036854775807 = %d, wanted -3\n", got) + failed = true + } + + if got := add_int64_9223372036854775806_ssa(9223372036854775807); got != -3 { + fmt.Printf("add_int64 9223372036854775807+9223372036854775806 = %d, wanted -3\n", got) + failed = true + } + + if got := add_9223372036854775807_int64_ssa(-9223372036854775808); got != -1 { + fmt.Printf("add_int64 9223372036854775807+-9223372036854775808 = %d, wanted -1\n", got) + failed = true + } + + if got := add_int64_9223372036854775807_ssa(-9223372036854775808); got != -1 { + fmt.Printf("add_int64 -9223372036854775808+9223372036854775807 = %d, wanted -1\n", got) + failed = true + } + + if got := add_9223372036854775807_int64_ssa(-9223372036854775807); got != 0 { + fmt.Printf("add_int64 9223372036854775807+-9223372036854775807 = %d, wanted 0\n", got) + failed = true + } + + if got := add_int64_9223372036854775807_ssa(-9223372036854775807); got != 0 { + fmt.Printf("add_int64 -9223372036854775807+9223372036854775807 = %d, wanted 0\n", got) + failed = true + } + + if got := add_9223372036854775807_int64_ssa(-4294967296); got != 9223372032559808511 { + fmt.Printf("add_int64 9223372036854775807+-4294967296 = %d, wanted 9223372032559808511\n", got) + failed = true + } + + if got := add_int64_9223372036854775807_ssa(-4294967296); got != 9223372032559808511 { + fmt.Printf("add_int64 -4294967296+9223372036854775807 = %d, wanted 9223372032559808511\n", got) + failed = true + } + + if got := add_9223372036854775807_int64_ssa(-1); got != 9223372036854775806 { + fmt.Printf("add_int64 9223372036854775807+-1 = %d, wanted 9223372036854775806\n", got) + failed = true + } + + if got := add_int64_9223372036854775807_ssa(-1); got != 9223372036854775806 { + fmt.Printf("add_int64 -1+9223372036854775807 = %d, wanted 9223372036854775806\n", got) + failed = true + } + + if got := add_9223372036854775807_int64_ssa(0); got != 9223372036854775807 { + fmt.Printf("add_int64 9223372036854775807+0 = %d, wanted 9223372036854775807\n", got) + failed = true + } + + if got := add_int64_9223372036854775807_ssa(0); got != 9223372036854775807 { + fmt.Printf("add_int64 0+9223372036854775807 = %d, wanted 9223372036854775807\n", got) + failed = true + } + + if got := add_9223372036854775807_int64_ssa(1); got != -9223372036854775808 { + fmt.Printf("add_int64 9223372036854775807+1 = %d, wanted -9223372036854775808\n", got) + failed = true + } + + if got := add_int64_9223372036854775807_ssa(1); got != -9223372036854775808 { + fmt.Printf("add_int64 1+9223372036854775807 = %d, wanted -9223372036854775808\n", got) + failed = true + } + + if got := add_9223372036854775807_int64_ssa(4294967296); got != -9223372032559808513 { + fmt.Printf("add_int64 9223372036854775807+4294967296 = %d, wanted -9223372032559808513\n", got) + failed = true + } + + if got := add_int64_9223372036854775807_ssa(4294967296); got != -9223372032559808513 { + fmt.Printf("add_int64 4294967296+9223372036854775807 = %d, wanted -9223372032559808513\n", got) + failed = true + } + + if got := add_9223372036854775807_int64_ssa(9223372036854775806); got != -3 { + fmt.Printf("add_int64 9223372036854775807+9223372036854775806 = %d, wanted -3\n", got) + failed = true + } + + if got := add_int64_9223372036854775807_ssa(9223372036854775806); got != -3 { + fmt.Printf("add_int64 9223372036854775806+9223372036854775807 = %d, wanted -3\n", got) + failed = true + } + + if got := add_9223372036854775807_int64_ssa(9223372036854775807); got != -2 { + fmt.Printf("add_int64 9223372036854775807+9223372036854775807 = %d, wanted -2\n", got) + failed = true + } + + if got := add_int64_9223372036854775807_ssa(9223372036854775807); got != -2 { + fmt.Printf("add_int64 9223372036854775807+9223372036854775807 = %d, wanted -2\n", got) + failed = true + } + + if got := sub_Neg9223372036854775808_int64_ssa(-9223372036854775808); got != 0 { + fmt.Printf("sub_int64 -9223372036854775808--9223372036854775808 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_int64_Neg9223372036854775808_ssa(-9223372036854775808); got != 0 { + fmt.Printf("sub_int64 -9223372036854775808--9223372036854775808 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_Neg9223372036854775808_int64_ssa(-9223372036854775807); got != -1 { + fmt.Printf("sub_int64 -9223372036854775808--9223372036854775807 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_int64_Neg9223372036854775808_ssa(-9223372036854775807); got != 1 { + fmt.Printf("sub_int64 -9223372036854775807--9223372036854775808 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_Neg9223372036854775808_int64_ssa(-4294967296); got != -9223372032559808512 { + fmt.Printf("sub_int64 -9223372036854775808--4294967296 = %d, wanted -9223372032559808512\n", got) + failed = true + } + + if got := sub_int64_Neg9223372036854775808_ssa(-4294967296); got != 9223372032559808512 { + fmt.Printf("sub_int64 -4294967296--9223372036854775808 = %d, wanted 9223372032559808512\n", got) + failed = true + } + + if got := sub_Neg9223372036854775808_int64_ssa(-1); got != -9223372036854775807 { + fmt.Printf("sub_int64 -9223372036854775808--1 = %d, wanted -9223372036854775807\n", got) + failed = true + } + + if got := sub_int64_Neg9223372036854775808_ssa(-1); got != 9223372036854775807 { + fmt.Printf("sub_int64 -1--9223372036854775808 = %d, wanted 9223372036854775807\n", got) + failed = true + } + + if got := sub_Neg9223372036854775808_int64_ssa(0); got != -9223372036854775808 { + fmt.Printf("sub_int64 -9223372036854775808-0 = %d, wanted -9223372036854775808\n", got) + failed = true + } + + if got := sub_int64_Neg9223372036854775808_ssa(0); got != -9223372036854775808 { + fmt.Printf("sub_int64 0--9223372036854775808 = %d, wanted -9223372036854775808\n", got) + failed = true + } + + if got := sub_Neg9223372036854775808_int64_ssa(1); got != 9223372036854775807 { + fmt.Printf("sub_int64 -9223372036854775808-1 = %d, wanted 9223372036854775807\n", got) + failed = true + } + + if got := sub_int64_Neg9223372036854775808_ssa(1); got != -9223372036854775807 { + fmt.Printf("sub_int64 1--9223372036854775808 = %d, wanted -9223372036854775807\n", got) + failed = true + } + + if got := sub_Neg9223372036854775808_int64_ssa(4294967296); got != 9223372032559808512 { + fmt.Printf("sub_int64 -9223372036854775808-4294967296 = %d, wanted 9223372032559808512\n", got) + failed = true + } + + if got := sub_int64_Neg9223372036854775808_ssa(4294967296); got != -9223372032559808512 { + fmt.Printf("sub_int64 4294967296--9223372036854775808 = %d, wanted -9223372032559808512\n", got) + failed = true + } + + if got := sub_Neg9223372036854775808_int64_ssa(9223372036854775806); got != 2 { + fmt.Printf("sub_int64 -9223372036854775808-9223372036854775806 = %d, wanted 2\n", got) + failed = true + } + + if got := sub_int64_Neg9223372036854775808_ssa(9223372036854775806); got != -2 { + fmt.Printf("sub_int64 9223372036854775806--9223372036854775808 = %d, wanted -2\n", got) + failed = true + } + + if got := sub_Neg9223372036854775808_int64_ssa(9223372036854775807); got != 1 { + fmt.Printf("sub_int64 -9223372036854775808-9223372036854775807 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_int64_Neg9223372036854775808_ssa(9223372036854775807); got != -1 { + fmt.Printf("sub_int64 9223372036854775807--9223372036854775808 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_Neg9223372036854775807_int64_ssa(-9223372036854775808); got != 1 { + fmt.Printf("sub_int64 -9223372036854775807--9223372036854775808 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_int64_Neg9223372036854775807_ssa(-9223372036854775808); got != -1 { + fmt.Printf("sub_int64 -9223372036854775808--9223372036854775807 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_Neg9223372036854775807_int64_ssa(-9223372036854775807); got != 0 { + fmt.Printf("sub_int64 -9223372036854775807--9223372036854775807 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_int64_Neg9223372036854775807_ssa(-9223372036854775807); got != 0 { + fmt.Printf("sub_int64 -9223372036854775807--9223372036854775807 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_Neg9223372036854775807_int64_ssa(-4294967296); got != -9223372032559808511 { + fmt.Printf("sub_int64 -9223372036854775807--4294967296 = %d, wanted -9223372032559808511\n", got) + failed = true + } + + if got := sub_int64_Neg9223372036854775807_ssa(-4294967296); got != 9223372032559808511 { + fmt.Printf("sub_int64 -4294967296--9223372036854775807 = %d, wanted 9223372032559808511\n", got) + failed = true + } + + if got := sub_Neg9223372036854775807_int64_ssa(-1); got != -9223372036854775806 { + fmt.Printf("sub_int64 -9223372036854775807--1 = %d, wanted -9223372036854775806\n", got) + failed = true + } + + if got := sub_int64_Neg9223372036854775807_ssa(-1); got != 9223372036854775806 { + fmt.Printf("sub_int64 -1--9223372036854775807 = %d, wanted 9223372036854775806\n", got) + failed = true + } + + if got := sub_Neg9223372036854775807_int64_ssa(0); got != -9223372036854775807 { + fmt.Printf("sub_int64 -9223372036854775807-0 = %d, wanted -9223372036854775807\n", got) + failed = true + } + + if got := sub_int64_Neg9223372036854775807_ssa(0); got != 9223372036854775807 { + fmt.Printf("sub_int64 0--9223372036854775807 = %d, wanted 9223372036854775807\n", got) + failed = true + } + + if got := sub_Neg9223372036854775807_int64_ssa(1); got != -9223372036854775808 { + fmt.Printf("sub_int64 -9223372036854775807-1 = %d, wanted -9223372036854775808\n", got) + failed = true + } + + if got := sub_int64_Neg9223372036854775807_ssa(1); got != -9223372036854775808 { + fmt.Printf("sub_int64 1--9223372036854775807 = %d, wanted -9223372036854775808\n", got) + failed = true + } + + if got := sub_Neg9223372036854775807_int64_ssa(4294967296); got != 9223372032559808513 { + fmt.Printf("sub_int64 -9223372036854775807-4294967296 = %d, wanted 9223372032559808513\n", got) + failed = true + } + + if got := sub_int64_Neg9223372036854775807_ssa(4294967296); got != -9223372032559808513 { + fmt.Printf("sub_int64 4294967296--9223372036854775807 = %d, wanted -9223372032559808513\n", got) + failed = true + } + + if got := sub_Neg9223372036854775807_int64_ssa(9223372036854775806); got != 3 { + fmt.Printf("sub_int64 -9223372036854775807-9223372036854775806 = %d, wanted 3\n", got) + failed = true + } + + if got := sub_int64_Neg9223372036854775807_ssa(9223372036854775806); got != -3 { + fmt.Printf("sub_int64 9223372036854775806--9223372036854775807 = %d, wanted -3\n", got) + failed = true + } + + if got := sub_Neg9223372036854775807_int64_ssa(9223372036854775807); got != 2 { + fmt.Printf("sub_int64 -9223372036854775807-9223372036854775807 = %d, wanted 2\n", got) + failed = true + } + + if got := sub_int64_Neg9223372036854775807_ssa(9223372036854775807); got != -2 { + fmt.Printf("sub_int64 9223372036854775807--9223372036854775807 = %d, wanted -2\n", got) + failed = true + } + + if got := sub_Neg4294967296_int64_ssa(-9223372036854775808); got != 9223372032559808512 { + fmt.Printf("sub_int64 -4294967296--9223372036854775808 = %d, wanted 9223372032559808512\n", got) + failed = true + } + + if got := sub_int64_Neg4294967296_ssa(-9223372036854775808); got != -9223372032559808512 { + fmt.Printf("sub_int64 -9223372036854775808--4294967296 = %d, wanted -9223372032559808512\n", got) + failed = true + } + + if got := sub_Neg4294967296_int64_ssa(-9223372036854775807); got != 9223372032559808511 { + fmt.Printf("sub_int64 -4294967296--9223372036854775807 = %d, wanted 9223372032559808511\n", got) + failed = true + } + + if got := sub_int64_Neg4294967296_ssa(-9223372036854775807); got != -9223372032559808511 { + fmt.Printf("sub_int64 -9223372036854775807--4294967296 = %d, wanted -9223372032559808511\n", got) + failed = true + } + + if got := sub_Neg4294967296_int64_ssa(-4294967296); got != 0 { + fmt.Printf("sub_int64 -4294967296--4294967296 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_int64_Neg4294967296_ssa(-4294967296); got != 0 { + fmt.Printf("sub_int64 -4294967296--4294967296 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_Neg4294967296_int64_ssa(-1); got != -4294967295 { + fmt.Printf("sub_int64 -4294967296--1 = %d, wanted -4294967295\n", got) + failed = true + } + + if got := sub_int64_Neg4294967296_ssa(-1); got != 4294967295 { + fmt.Printf("sub_int64 -1--4294967296 = %d, wanted 4294967295\n", got) + failed = true + } + + if got := sub_Neg4294967296_int64_ssa(0); got != -4294967296 { + fmt.Printf("sub_int64 -4294967296-0 = %d, wanted -4294967296\n", got) + failed = true + } + + if got := sub_int64_Neg4294967296_ssa(0); got != 4294967296 { + fmt.Printf("sub_int64 0--4294967296 = %d, wanted 4294967296\n", got) + failed = true + } + + if got := sub_Neg4294967296_int64_ssa(1); got != -4294967297 { + fmt.Printf("sub_int64 -4294967296-1 = %d, wanted -4294967297\n", got) + failed = true + } + + if got := sub_int64_Neg4294967296_ssa(1); got != 4294967297 { + fmt.Printf("sub_int64 1--4294967296 = %d, wanted 4294967297\n", got) + failed = true + } + + if got := sub_Neg4294967296_int64_ssa(4294967296); got != -8589934592 { + fmt.Printf("sub_int64 -4294967296-4294967296 = %d, wanted -8589934592\n", got) + failed = true + } + + if got := sub_int64_Neg4294967296_ssa(4294967296); got != 8589934592 { + fmt.Printf("sub_int64 4294967296--4294967296 = %d, wanted 8589934592\n", got) + failed = true + } + + if got := sub_Neg4294967296_int64_ssa(9223372036854775806); got != 9223372032559808514 { + fmt.Printf("sub_int64 -4294967296-9223372036854775806 = %d, wanted 9223372032559808514\n", got) + failed = true + } + + if got := sub_int64_Neg4294967296_ssa(9223372036854775806); got != -9223372032559808514 { + fmt.Printf("sub_int64 9223372036854775806--4294967296 = %d, wanted -9223372032559808514\n", got) + failed = true + } + + if got := sub_Neg4294967296_int64_ssa(9223372036854775807); got != 9223372032559808513 { + fmt.Printf("sub_int64 -4294967296-9223372036854775807 = %d, wanted 9223372032559808513\n", got) + failed = true + } + + if got := sub_int64_Neg4294967296_ssa(9223372036854775807); got != -9223372032559808513 { + fmt.Printf("sub_int64 9223372036854775807--4294967296 = %d, wanted -9223372032559808513\n", got) + failed = true + } + + if got := sub_Neg1_int64_ssa(-9223372036854775808); got != 9223372036854775807 { + fmt.Printf("sub_int64 -1--9223372036854775808 = %d, wanted 9223372036854775807\n", got) + failed = true + } + + if got := sub_int64_Neg1_ssa(-9223372036854775808); got != -9223372036854775807 { + fmt.Printf("sub_int64 -9223372036854775808--1 = %d, wanted -9223372036854775807\n", got) + failed = true + } + + if got := sub_Neg1_int64_ssa(-9223372036854775807); got != 9223372036854775806 { + fmt.Printf("sub_int64 -1--9223372036854775807 = %d, wanted 9223372036854775806\n", got) + failed = true + } + + if got := sub_int64_Neg1_ssa(-9223372036854775807); got != -9223372036854775806 { + fmt.Printf("sub_int64 -9223372036854775807--1 = %d, wanted -9223372036854775806\n", got) + failed = true + } + + if got := sub_Neg1_int64_ssa(-4294967296); got != 4294967295 { + fmt.Printf("sub_int64 -1--4294967296 = %d, wanted 4294967295\n", got) + failed = true + } + + if got := sub_int64_Neg1_ssa(-4294967296); got != -4294967295 { + fmt.Printf("sub_int64 -4294967296--1 = %d, wanted -4294967295\n", got) + failed = true + } + + if got := sub_Neg1_int64_ssa(-1); got != 0 { + fmt.Printf("sub_int64 -1--1 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_int64_Neg1_ssa(-1); got != 0 { + fmt.Printf("sub_int64 -1--1 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_Neg1_int64_ssa(0); got != -1 { + fmt.Printf("sub_int64 -1-0 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_int64_Neg1_ssa(0); got != 1 { + fmt.Printf("sub_int64 0--1 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_Neg1_int64_ssa(1); got != -2 { + fmt.Printf("sub_int64 -1-1 = %d, wanted -2\n", got) + failed = true + } + + if got := sub_int64_Neg1_ssa(1); got != 2 { + fmt.Printf("sub_int64 1--1 = %d, wanted 2\n", got) + failed = true + } + + if got := sub_Neg1_int64_ssa(4294967296); got != -4294967297 { + fmt.Printf("sub_int64 -1-4294967296 = %d, wanted -4294967297\n", got) + failed = true + } + + if got := sub_int64_Neg1_ssa(4294967296); got != 4294967297 { + fmt.Printf("sub_int64 4294967296--1 = %d, wanted 4294967297\n", got) + failed = true + } + + if got := sub_Neg1_int64_ssa(9223372036854775806); got != -9223372036854775807 { + fmt.Printf("sub_int64 -1-9223372036854775806 = %d, wanted -9223372036854775807\n", got) + failed = true + } + + if got := sub_int64_Neg1_ssa(9223372036854775806); got != 9223372036854775807 { + fmt.Printf("sub_int64 9223372036854775806--1 = %d, wanted 9223372036854775807\n", got) + failed = true + } + + if got := sub_Neg1_int64_ssa(9223372036854775807); got != -9223372036854775808 { + fmt.Printf("sub_int64 -1-9223372036854775807 = %d, wanted -9223372036854775808\n", got) + failed = true + } + + if got := sub_int64_Neg1_ssa(9223372036854775807); got != -9223372036854775808 { + fmt.Printf("sub_int64 9223372036854775807--1 = %d, wanted -9223372036854775808\n", got) + failed = true + } + + if got := sub_0_int64_ssa(-9223372036854775808); got != -9223372036854775808 { + fmt.Printf("sub_int64 0--9223372036854775808 = %d, wanted -9223372036854775808\n", got) + failed = true + } + + if got := sub_int64_0_ssa(-9223372036854775808); got != -9223372036854775808 { + fmt.Printf("sub_int64 -9223372036854775808-0 = %d, wanted -9223372036854775808\n", got) + failed = true + } + + if got := sub_0_int64_ssa(-9223372036854775807); got != 9223372036854775807 { + fmt.Printf("sub_int64 0--9223372036854775807 = %d, wanted 9223372036854775807\n", got) + failed = true + } + + if got := sub_int64_0_ssa(-9223372036854775807); got != -9223372036854775807 { + fmt.Printf("sub_int64 -9223372036854775807-0 = %d, wanted -9223372036854775807\n", got) + failed = true + } + + if got := sub_0_int64_ssa(-4294967296); got != 4294967296 { + fmt.Printf("sub_int64 0--4294967296 = %d, wanted 4294967296\n", got) + failed = true + } + + if got := sub_int64_0_ssa(-4294967296); got != -4294967296 { + fmt.Printf("sub_int64 -4294967296-0 = %d, wanted -4294967296\n", got) + failed = true + } + + if got := sub_0_int64_ssa(-1); got != 1 { + fmt.Printf("sub_int64 0--1 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_int64_0_ssa(-1); got != -1 { + fmt.Printf("sub_int64 -1-0 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_0_int64_ssa(0); got != 0 { + fmt.Printf("sub_int64 0-0 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_int64_0_ssa(0); got != 0 { + fmt.Printf("sub_int64 0-0 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_0_int64_ssa(1); got != -1 { + fmt.Printf("sub_int64 0-1 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_int64_0_ssa(1); got != 1 { + fmt.Printf("sub_int64 1-0 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_0_int64_ssa(4294967296); got != -4294967296 { + fmt.Printf("sub_int64 0-4294967296 = %d, wanted -4294967296\n", got) + failed = true + } + + if got := sub_int64_0_ssa(4294967296); got != 4294967296 { + fmt.Printf("sub_int64 4294967296-0 = %d, wanted 4294967296\n", got) + failed = true + } + + if got := sub_0_int64_ssa(9223372036854775806); got != -9223372036854775806 { + fmt.Printf("sub_int64 0-9223372036854775806 = %d, wanted -9223372036854775806\n", got) + failed = true + } + + if got := sub_int64_0_ssa(9223372036854775806); got != 9223372036854775806 { + fmt.Printf("sub_int64 9223372036854775806-0 = %d, wanted 9223372036854775806\n", got) + failed = true + } + + if got := sub_0_int64_ssa(9223372036854775807); got != -9223372036854775807 { + fmt.Printf("sub_int64 0-9223372036854775807 = %d, wanted -9223372036854775807\n", got) + failed = true + } + + if got := sub_int64_0_ssa(9223372036854775807); got != 9223372036854775807 { + fmt.Printf("sub_int64 9223372036854775807-0 = %d, wanted 9223372036854775807\n", got) + failed = true + } + + if got := sub_1_int64_ssa(-9223372036854775808); got != -9223372036854775807 { + fmt.Printf("sub_int64 1--9223372036854775808 = %d, wanted -9223372036854775807\n", got) + failed = true + } + + if got := sub_int64_1_ssa(-9223372036854775808); got != 9223372036854775807 { + fmt.Printf("sub_int64 -9223372036854775808-1 = %d, wanted 9223372036854775807\n", got) + failed = true + } + + if got := sub_1_int64_ssa(-9223372036854775807); got != -9223372036854775808 { + fmt.Printf("sub_int64 1--9223372036854775807 = %d, wanted -9223372036854775808\n", got) + failed = true + } + + if got := sub_int64_1_ssa(-9223372036854775807); got != -9223372036854775808 { + fmt.Printf("sub_int64 -9223372036854775807-1 = %d, wanted -9223372036854775808\n", got) + failed = true + } + + if got := sub_1_int64_ssa(-4294967296); got != 4294967297 { + fmt.Printf("sub_int64 1--4294967296 = %d, wanted 4294967297\n", got) + failed = true + } + + if got := sub_int64_1_ssa(-4294967296); got != -4294967297 { + fmt.Printf("sub_int64 -4294967296-1 = %d, wanted -4294967297\n", got) + failed = true + } + + if got := sub_1_int64_ssa(-1); got != 2 { + fmt.Printf("sub_int64 1--1 = %d, wanted 2\n", got) + failed = true + } + + if got := sub_int64_1_ssa(-1); got != -2 { + fmt.Printf("sub_int64 -1-1 = %d, wanted -2\n", got) + failed = true + } + + if got := sub_1_int64_ssa(0); got != 1 { + fmt.Printf("sub_int64 1-0 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_int64_1_ssa(0); got != -1 { + fmt.Printf("sub_int64 0-1 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_1_int64_ssa(1); got != 0 { + fmt.Printf("sub_int64 1-1 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_int64_1_ssa(1); got != 0 { + fmt.Printf("sub_int64 1-1 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_1_int64_ssa(4294967296); got != -4294967295 { + fmt.Printf("sub_int64 1-4294967296 = %d, wanted -4294967295\n", got) + failed = true + } + + if got := sub_int64_1_ssa(4294967296); got != 4294967295 { + fmt.Printf("sub_int64 4294967296-1 = %d, wanted 4294967295\n", got) + failed = true + } + + if got := sub_1_int64_ssa(9223372036854775806); got != -9223372036854775805 { + fmt.Printf("sub_int64 1-9223372036854775806 = %d, wanted -9223372036854775805\n", got) + failed = true + } + + if got := sub_int64_1_ssa(9223372036854775806); got != 9223372036854775805 { + fmt.Printf("sub_int64 9223372036854775806-1 = %d, wanted 9223372036854775805\n", got) + failed = true + } + + if got := sub_1_int64_ssa(9223372036854775807); got != -9223372036854775806 { + fmt.Printf("sub_int64 1-9223372036854775807 = %d, wanted -9223372036854775806\n", got) + failed = true + } + + if got := sub_int64_1_ssa(9223372036854775807); got != 9223372036854775806 { + fmt.Printf("sub_int64 9223372036854775807-1 = %d, wanted 9223372036854775806\n", got) + failed = true + } + + if got := sub_4294967296_int64_ssa(-9223372036854775808); got != -9223372032559808512 { + fmt.Printf("sub_int64 4294967296--9223372036854775808 = %d, wanted -9223372032559808512\n", got) + failed = true + } + + if got := sub_int64_4294967296_ssa(-9223372036854775808); got != 9223372032559808512 { + fmt.Printf("sub_int64 -9223372036854775808-4294967296 = %d, wanted 9223372032559808512\n", got) + failed = true + } + + if got := sub_4294967296_int64_ssa(-9223372036854775807); got != -9223372032559808513 { + fmt.Printf("sub_int64 4294967296--9223372036854775807 = %d, wanted -9223372032559808513\n", got) + failed = true + } + + if got := sub_int64_4294967296_ssa(-9223372036854775807); got != 9223372032559808513 { + fmt.Printf("sub_int64 -9223372036854775807-4294967296 = %d, wanted 9223372032559808513\n", got) + failed = true + } + + if got := sub_4294967296_int64_ssa(-4294967296); got != 8589934592 { + fmt.Printf("sub_int64 4294967296--4294967296 = %d, wanted 8589934592\n", got) + failed = true + } + + if got := sub_int64_4294967296_ssa(-4294967296); got != -8589934592 { + fmt.Printf("sub_int64 -4294967296-4294967296 = %d, wanted -8589934592\n", got) + failed = true + } + + if got := sub_4294967296_int64_ssa(-1); got != 4294967297 { + fmt.Printf("sub_int64 4294967296--1 = %d, wanted 4294967297\n", got) + failed = true + } + + if got := sub_int64_4294967296_ssa(-1); got != -4294967297 { + fmt.Printf("sub_int64 -1-4294967296 = %d, wanted -4294967297\n", got) + failed = true + } + + if got := sub_4294967296_int64_ssa(0); got != 4294967296 { + fmt.Printf("sub_int64 4294967296-0 = %d, wanted 4294967296\n", got) + failed = true + } + + if got := sub_int64_4294967296_ssa(0); got != -4294967296 { + fmt.Printf("sub_int64 0-4294967296 = %d, wanted -4294967296\n", got) + failed = true + } + + if got := sub_4294967296_int64_ssa(1); got != 4294967295 { + fmt.Printf("sub_int64 4294967296-1 = %d, wanted 4294967295\n", got) + failed = true + } + + if got := sub_int64_4294967296_ssa(1); got != -4294967295 { + fmt.Printf("sub_int64 1-4294967296 = %d, wanted -4294967295\n", got) + failed = true + } + + if got := sub_4294967296_int64_ssa(4294967296); got != 0 { + fmt.Printf("sub_int64 4294967296-4294967296 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_int64_4294967296_ssa(4294967296); got != 0 { + fmt.Printf("sub_int64 4294967296-4294967296 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_4294967296_int64_ssa(9223372036854775806); got != -9223372032559808510 { + fmt.Printf("sub_int64 4294967296-9223372036854775806 = %d, wanted -9223372032559808510\n", got) + failed = true + } + + if got := sub_int64_4294967296_ssa(9223372036854775806); got != 9223372032559808510 { + fmt.Printf("sub_int64 9223372036854775806-4294967296 = %d, wanted 9223372032559808510\n", got) + failed = true + } + + if got := sub_4294967296_int64_ssa(9223372036854775807); got != -9223372032559808511 { + fmt.Printf("sub_int64 4294967296-9223372036854775807 = %d, wanted -9223372032559808511\n", got) + failed = true + } + + if got := sub_int64_4294967296_ssa(9223372036854775807); got != 9223372032559808511 { + fmt.Printf("sub_int64 9223372036854775807-4294967296 = %d, wanted 9223372032559808511\n", got) + failed = true + } + + if got := sub_9223372036854775806_int64_ssa(-9223372036854775808); got != -2 { + fmt.Printf("sub_int64 9223372036854775806--9223372036854775808 = %d, wanted -2\n", got) + failed = true + } + + if got := sub_int64_9223372036854775806_ssa(-9223372036854775808); got != 2 { + fmt.Printf("sub_int64 -9223372036854775808-9223372036854775806 = %d, wanted 2\n", got) + failed = true + } + + if got := sub_9223372036854775806_int64_ssa(-9223372036854775807); got != -3 { + fmt.Printf("sub_int64 9223372036854775806--9223372036854775807 = %d, wanted -3\n", got) + failed = true + } + + if got := sub_int64_9223372036854775806_ssa(-9223372036854775807); got != 3 { + fmt.Printf("sub_int64 -9223372036854775807-9223372036854775806 = %d, wanted 3\n", got) + failed = true + } + + if got := sub_9223372036854775806_int64_ssa(-4294967296); got != -9223372032559808514 { + fmt.Printf("sub_int64 9223372036854775806--4294967296 = %d, wanted -9223372032559808514\n", got) + failed = true + } + + if got := sub_int64_9223372036854775806_ssa(-4294967296); got != 9223372032559808514 { + fmt.Printf("sub_int64 -4294967296-9223372036854775806 = %d, wanted 9223372032559808514\n", got) + failed = true + } + + if got := sub_9223372036854775806_int64_ssa(-1); got != 9223372036854775807 { + fmt.Printf("sub_int64 9223372036854775806--1 = %d, wanted 9223372036854775807\n", got) + failed = true + } + + if got := sub_int64_9223372036854775806_ssa(-1); got != -9223372036854775807 { + fmt.Printf("sub_int64 -1-9223372036854775806 = %d, wanted -9223372036854775807\n", got) + failed = true + } + + if got := sub_9223372036854775806_int64_ssa(0); got != 9223372036854775806 { + fmt.Printf("sub_int64 9223372036854775806-0 = %d, wanted 9223372036854775806\n", got) + failed = true + } + + if got := sub_int64_9223372036854775806_ssa(0); got != -9223372036854775806 { + fmt.Printf("sub_int64 0-9223372036854775806 = %d, wanted -9223372036854775806\n", got) + failed = true + } + + if got := sub_9223372036854775806_int64_ssa(1); got != 9223372036854775805 { + fmt.Printf("sub_int64 9223372036854775806-1 = %d, wanted 9223372036854775805\n", got) + failed = true + } + + if got := sub_int64_9223372036854775806_ssa(1); got != -9223372036854775805 { + fmt.Printf("sub_int64 1-9223372036854775806 = %d, wanted -9223372036854775805\n", got) + failed = true + } + + if got := sub_9223372036854775806_int64_ssa(4294967296); got != 9223372032559808510 { + fmt.Printf("sub_int64 9223372036854775806-4294967296 = %d, wanted 9223372032559808510\n", got) + failed = true + } + + if got := sub_int64_9223372036854775806_ssa(4294967296); got != -9223372032559808510 { + fmt.Printf("sub_int64 4294967296-9223372036854775806 = %d, wanted -9223372032559808510\n", got) + failed = true + } + + if got := sub_9223372036854775806_int64_ssa(9223372036854775806); got != 0 { + fmt.Printf("sub_int64 9223372036854775806-9223372036854775806 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_int64_9223372036854775806_ssa(9223372036854775806); got != 0 { + fmt.Printf("sub_int64 9223372036854775806-9223372036854775806 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_9223372036854775806_int64_ssa(9223372036854775807); got != -1 { + fmt.Printf("sub_int64 9223372036854775806-9223372036854775807 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_int64_9223372036854775806_ssa(9223372036854775807); got != 1 { + fmt.Printf("sub_int64 9223372036854775807-9223372036854775806 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_9223372036854775807_int64_ssa(-9223372036854775808); got != -1 { + fmt.Printf("sub_int64 9223372036854775807--9223372036854775808 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_int64_9223372036854775807_ssa(-9223372036854775808); got != 1 { + fmt.Printf("sub_int64 -9223372036854775808-9223372036854775807 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_9223372036854775807_int64_ssa(-9223372036854775807); got != -2 { + fmt.Printf("sub_int64 9223372036854775807--9223372036854775807 = %d, wanted -2\n", got) + failed = true + } + + if got := sub_int64_9223372036854775807_ssa(-9223372036854775807); got != 2 { + fmt.Printf("sub_int64 -9223372036854775807-9223372036854775807 = %d, wanted 2\n", got) + failed = true + } + + if got := sub_9223372036854775807_int64_ssa(-4294967296); got != -9223372032559808513 { + fmt.Printf("sub_int64 9223372036854775807--4294967296 = %d, wanted -9223372032559808513\n", got) + failed = true + } + + if got := sub_int64_9223372036854775807_ssa(-4294967296); got != 9223372032559808513 { + fmt.Printf("sub_int64 -4294967296-9223372036854775807 = %d, wanted 9223372032559808513\n", got) + failed = true + } + + if got := sub_9223372036854775807_int64_ssa(-1); got != -9223372036854775808 { + fmt.Printf("sub_int64 9223372036854775807--1 = %d, wanted -9223372036854775808\n", got) + failed = true + } + + if got := sub_int64_9223372036854775807_ssa(-1); got != -9223372036854775808 { + fmt.Printf("sub_int64 -1-9223372036854775807 = %d, wanted -9223372036854775808\n", got) + failed = true + } + + if got := sub_9223372036854775807_int64_ssa(0); got != 9223372036854775807 { + fmt.Printf("sub_int64 9223372036854775807-0 = %d, wanted 9223372036854775807\n", got) + failed = true + } + + if got := sub_int64_9223372036854775807_ssa(0); got != -9223372036854775807 { + fmt.Printf("sub_int64 0-9223372036854775807 = %d, wanted -9223372036854775807\n", got) + failed = true + } + + if got := sub_9223372036854775807_int64_ssa(1); got != 9223372036854775806 { + fmt.Printf("sub_int64 9223372036854775807-1 = %d, wanted 9223372036854775806\n", got) + failed = true + } + + if got := sub_int64_9223372036854775807_ssa(1); got != -9223372036854775806 { + fmt.Printf("sub_int64 1-9223372036854775807 = %d, wanted -9223372036854775806\n", got) + failed = true + } + + if got := sub_9223372036854775807_int64_ssa(4294967296); got != 9223372032559808511 { + fmt.Printf("sub_int64 9223372036854775807-4294967296 = %d, wanted 9223372032559808511\n", got) + failed = true + } + + if got := sub_int64_9223372036854775807_ssa(4294967296); got != -9223372032559808511 { + fmt.Printf("sub_int64 4294967296-9223372036854775807 = %d, wanted -9223372032559808511\n", got) + failed = true + } + + if got := sub_9223372036854775807_int64_ssa(9223372036854775806); got != 1 { + fmt.Printf("sub_int64 9223372036854775807-9223372036854775806 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_int64_9223372036854775807_ssa(9223372036854775806); got != -1 { + fmt.Printf("sub_int64 9223372036854775806-9223372036854775807 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_9223372036854775807_int64_ssa(9223372036854775807); got != 0 { + fmt.Printf("sub_int64 9223372036854775807-9223372036854775807 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_int64_9223372036854775807_ssa(9223372036854775807); got != 0 { + fmt.Printf("sub_int64 9223372036854775807-9223372036854775807 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg9223372036854775808_int64_ssa(-9223372036854775808); got != 1 { + fmt.Printf("div_int64 -9223372036854775808/-9223372036854775808 = %d, wanted 1\n", got) + failed = true + } + + if got := div_int64_Neg9223372036854775808_ssa(-9223372036854775808); got != 1 { + fmt.Printf("div_int64 -9223372036854775808/-9223372036854775808 = %d, wanted 1\n", got) + failed = true + } + + if got := div_Neg9223372036854775808_int64_ssa(-9223372036854775807); got != 1 { + fmt.Printf("div_int64 -9223372036854775808/-9223372036854775807 = %d, wanted 1\n", got) + failed = true + } + + if got := div_int64_Neg9223372036854775808_ssa(-9223372036854775807); got != 0 { + fmt.Printf("div_int64 -9223372036854775807/-9223372036854775808 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg9223372036854775808_int64_ssa(-4294967296); got != 2147483648 { + fmt.Printf("div_int64 -9223372036854775808/-4294967296 = %d, wanted 2147483648\n", got) + failed = true + } + + if got := div_int64_Neg9223372036854775808_ssa(-4294967296); got != 0 { + fmt.Printf("div_int64 -4294967296/-9223372036854775808 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg9223372036854775808_int64_ssa(-1); got != -9223372036854775808 { + fmt.Printf("div_int64 -9223372036854775808/-1 = %d, wanted -9223372036854775808\n", got) + failed = true + } + + if got := div_int64_Neg9223372036854775808_ssa(-1); got != 0 { + fmt.Printf("div_int64 -1/-9223372036854775808 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int64_Neg9223372036854775808_ssa(0); got != 0 { + fmt.Printf("div_int64 0/-9223372036854775808 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg9223372036854775808_int64_ssa(1); got != -9223372036854775808 { + fmt.Printf("div_int64 -9223372036854775808/1 = %d, wanted -9223372036854775808\n", got) + failed = true + } + + if got := div_int64_Neg9223372036854775808_ssa(1); got != 0 { + fmt.Printf("div_int64 1/-9223372036854775808 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg9223372036854775808_int64_ssa(4294967296); got != -2147483648 { + fmt.Printf("div_int64 -9223372036854775808/4294967296 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := div_int64_Neg9223372036854775808_ssa(4294967296); got != 0 { + fmt.Printf("div_int64 4294967296/-9223372036854775808 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg9223372036854775808_int64_ssa(9223372036854775806); got != -1 { + fmt.Printf("div_int64 -9223372036854775808/9223372036854775806 = %d, wanted -1\n", got) + failed = true + } + + if got := div_int64_Neg9223372036854775808_ssa(9223372036854775806); got != 0 { + fmt.Printf("div_int64 9223372036854775806/-9223372036854775808 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg9223372036854775808_int64_ssa(9223372036854775807); got != -1 { + fmt.Printf("div_int64 -9223372036854775808/9223372036854775807 = %d, wanted -1\n", got) + failed = true + } + + if got := div_int64_Neg9223372036854775808_ssa(9223372036854775807); got != 0 { + fmt.Printf("div_int64 9223372036854775807/-9223372036854775808 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg9223372036854775807_int64_ssa(-9223372036854775808); got != 0 { + fmt.Printf("div_int64 -9223372036854775807/-9223372036854775808 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int64_Neg9223372036854775807_ssa(-9223372036854775808); got != 1 { + fmt.Printf("div_int64 -9223372036854775808/-9223372036854775807 = %d, wanted 1\n", got) + failed = true + } + + if got := div_Neg9223372036854775807_int64_ssa(-9223372036854775807); got != 1 { + fmt.Printf("div_int64 -9223372036854775807/-9223372036854775807 = %d, wanted 1\n", got) + failed = true + } + + if got := div_int64_Neg9223372036854775807_ssa(-9223372036854775807); got != 1 { + fmt.Printf("div_int64 -9223372036854775807/-9223372036854775807 = %d, wanted 1\n", got) + failed = true + } + + if got := div_Neg9223372036854775807_int64_ssa(-4294967296); got != 2147483647 { + fmt.Printf("div_int64 -9223372036854775807/-4294967296 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := div_int64_Neg9223372036854775807_ssa(-4294967296); got != 0 { + fmt.Printf("div_int64 -4294967296/-9223372036854775807 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg9223372036854775807_int64_ssa(-1); got != 9223372036854775807 { + fmt.Printf("div_int64 -9223372036854775807/-1 = %d, wanted 9223372036854775807\n", got) + failed = true + } + + if got := div_int64_Neg9223372036854775807_ssa(-1); got != 0 { + fmt.Printf("div_int64 -1/-9223372036854775807 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int64_Neg9223372036854775807_ssa(0); got != 0 { + fmt.Printf("div_int64 0/-9223372036854775807 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg9223372036854775807_int64_ssa(1); got != -9223372036854775807 { + fmt.Printf("div_int64 -9223372036854775807/1 = %d, wanted -9223372036854775807\n", got) + failed = true + } + + if got := div_int64_Neg9223372036854775807_ssa(1); got != 0 { + fmt.Printf("div_int64 1/-9223372036854775807 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg9223372036854775807_int64_ssa(4294967296); got != -2147483647 { + fmt.Printf("div_int64 -9223372036854775807/4294967296 = %d, wanted -2147483647\n", got) + failed = true + } + + if got := div_int64_Neg9223372036854775807_ssa(4294967296); got != 0 { + fmt.Printf("div_int64 4294967296/-9223372036854775807 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg9223372036854775807_int64_ssa(9223372036854775806); got != -1 { + fmt.Printf("div_int64 -9223372036854775807/9223372036854775806 = %d, wanted -1\n", got) + failed = true + } + + if got := div_int64_Neg9223372036854775807_ssa(9223372036854775806); got != 0 { + fmt.Printf("div_int64 9223372036854775806/-9223372036854775807 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg9223372036854775807_int64_ssa(9223372036854775807); got != -1 { + fmt.Printf("div_int64 -9223372036854775807/9223372036854775807 = %d, wanted -1\n", got) + failed = true + } + + if got := div_int64_Neg9223372036854775807_ssa(9223372036854775807); got != -1 { + fmt.Printf("div_int64 9223372036854775807/-9223372036854775807 = %d, wanted -1\n", got) + failed = true + } + + if got := div_Neg4294967296_int64_ssa(-9223372036854775808); got != 0 { + fmt.Printf("div_int64 -4294967296/-9223372036854775808 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int64_Neg4294967296_ssa(-9223372036854775808); got != 2147483648 { + fmt.Printf("div_int64 -9223372036854775808/-4294967296 = %d, wanted 2147483648\n", got) + failed = true + } + + if got := div_Neg4294967296_int64_ssa(-9223372036854775807); got != 0 { + fmt.Printf("div_int64 -4294967296/-9223372036854775807 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int64_Neg4294967296_ssa(-9223372036854775807); got != 2147483647 { + fmt.Printf("div_int64 -9223372036854775807/-4294967296 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := div_Neg4294967296_int64_ssa(-4294967296); got != 1 { + fmt.Printf("div_int64 -4294967296/-4294967296 = %d, wanted 1\n", got) + failed = true + } + + if got := div_int64_Neg4294967296_ssa(-4294967296); got != 1 { + fmt.Printf("div_int64 -4294967296/-4294967296 = %d, wanted 1\n", got) + failed = true + } + + if got := div_Neg4294967296_int64_ssa(-1); got != 4294967296 { + fmt.Printf("div_int64 -4294967296/-1 = %d, wanted 4294967296\n", got) + failed = true + } + + if got := div_int64_Neg4294967296_ssa(-1); got != 0 { + fmt.Printf("div_int64 -1/-4294967296 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int64_Neg4294967296_ssa(0); got != 0 { + fmt.Printf("div_int64 0/-4294967296 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg4294967296_int64_ssa(1); got != -4294967296 { + fmt.Printf("div_int64 -4294967296/1 = %d, wanted -4294967296\n", got) + failed = true + } + + if got := div_int64_Neg4294967296_ssa(1); got != 0 { + fmt.Printf("div_int64 1/-4294967296 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg4294967296_int64_ssa(4294967296); got != -1 { + fmt.Printf("div_int64 -4294967296/4294967296 = %d, wanted -1\n", got) + failed = true + } + + if got := div_int64_Neg4294967296_ssa(4294967296); got != -1 { + fmt.Printf("div_int64 4294967296/-4294967296 = %d, wanted -1\n", got) + failed = true + } + + if got := div_Neg4294967296_int64_ssa(9223372036854775806); got != 0 { + fmt.Printf("div_int64 -4294967296/9223372036854775806 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int64_Neg4294967296_ssa(9223372036854775806); got != -2147483647 { + fmt.Printf("div_int64 9223372036854775806/-4294967296 = %d, wanted -2147483647\n", got) + failed = true + } + + if got := div_Neg4294967296_int64_ssa(9223372036854775807); got != 0 { + fmt.Printf("div_int64 -4294967296/9223372036854775807 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int64_Neg4294967296_ssa(9223372036854775807); got != -2147483647 { + fmt.Printf("div_int64 9223372036854775807/-4294967296 = %d, wanted -2147483647\n", got) + failed = true + } + + if got := div_Neg1_int64_ssa(-9223372036854775808); got != 0 { + fmt.Printf("div_int64 -1/-9223372036854775808 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int64_Neg1_ssa(-9223372036854775808); got != -9223372036854775808 { + fmt.Printf("div_int64 -9223372036854775808/-1 = %d, wanted -9223372036854775808\n", got) + failed = true + } + + if got := div_Neg1_int64_ssa(-9223372036854775807); got != 0 { + fmt.Printf("div_int64 -1/-9223372036854775807 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int64_Neg1_ssa(-9223372036854775807); got != 9223372036854775807 { + fmt.Printf("div_int64 -9223372036854775807/-1 = %d, wanted 9223372036854775807\n", got) + failed = true + } + + if got := div_Neg1_int64_ssa(-4294967296); got != 0 { + fmt.Printf("div_int64 -1/-4294967296 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int64_Neg1_ssa(-4294967296); got != 4294967296 { + fmt.Printf("div_int64 -4294967296/-1 = %d, wanted 4294967296\n", got) + failed = true + } + + if got := div_Neg1_int64_ssa(-1); got != 1 { + fmt.Printf("div_int64 -1/-1 = %d, wanted 1\n", got) + failed = true + } + + if got := div_int64_Neg1_ssa(-1); got != 1 { + fmt.Printf("div_int64 -1/-1 = %d, wanted 1\n", got) + failed = true + } + + if got := div_int64_Neg1_ssa(0); got != 0 { + fmt.Printf("div_int64 0/-1 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg1_int64_ssa(1); got != -1 { + fmt.Printf("div_int64 -1/1 = %d, wanted -1\n", got) + failed = true + } + + if got := div_int64_Neg1_ssa(1); got != -1 { + fmt.Printf("div_int64 1/-1 = %d, wanted -1\n", got) + failed = true + } + + if got := div_Neg1_int64_ssa(4294967296); got != 0 { + fmt.Printf("div_int64 -1/4294967296 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int64_Neg1_ssa(4294967296); got != -4294967296 { + fmt.Printf("div_int64 4294967296/-1 = %d, wanted -4294967296\n", got) + failed = true + } + + if got := div_Neg1_int64_ssa(9223372036854775806); got != 0 { + fmt.Printf("div_int64 -1/9223372036854775806 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int64_Neg1_ssa(9223372036854775806); got != -9223372036854775806 { + fmt.Printf("div_int64 9223372036854775806/-1 = %d, wanted -9223372036854775806\n", got) + failed = true + } + + if got := div_Neg1_int64_ssa(9223372036854775807); got != 0 { + fmt.Printf("div_int64 -1/9223372036854775807 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int64_Neg1_ssa(9223372036854775807); got != -9223372036854775807 { + fmt.Printf("div_int64 9223372036854775807/-1 = %d, wanted -9223372036854775807\n", got) + failed = true + } + + if got := div_0_int64_ssa(-9223372036854775808); got != 0 { + fmt.Printf("div_int64 0/-9223372036854775808 = %d, wanted 0\n", got) + failed = true + } + + if got := div_0_int64_ssa(-9223372036854775807); got != 0 { + fmt.Printf("div_int64 0/-9223372036854775807 = %d, wanted 0\n", got) + failed = true + } + + if got := div_0_int64_ssa(-4294967296); got != 0 { + fmt.Printf("div_int64 0/-4294967296 = %d, wanted 0\n", got) + failed = true + } + + if got := div_0_int64_ssa(-1); got != 0 { + fmt.Printf("div_int64 0/-1 = %d, wanted 0\n", got) + failed = true + } + + if got := div_0_int64_ssa(1); got != 0 { + fmt.Printf("div_int64 0/1 = %d, wanted 0\n", got) + failed = true + } + + if got := div_0_int64_ssa(4294967296); got != 0 { + fmt.Printf("div_int64 0/4294967296 = %d, wanted 0\n", got) + failed = true + } + + if got := div_0_int64_ssa(9223372036854775806); got != 0 { + fmt.Printf("div_int64 0/9223372036854775806 = %d, wanted 0\n", got) + failed = true + } + + if got := div_0_int64_ssa(9223372036854775807); got != 0 { + fmt.Printf("div_int64 0/9223372036854775807 = %d, wanted 0\n", got) + failed = true + } + + if got := div_1_int64_ssa(-9223372036854775808); got != 0 { + fmt.Printf("div_int64 1/-9223372036854775808 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int64_1_ssa(-9223372036854775808); got != -9223372036854775808 { + fmt.Printf("div_int64 -9223372036854775808/1 = %d, wanted -9223372036854775808\n", got) + failed = true + } + + if got := div_1_int64_ssa(-9223372036854775807); got != 0 { + fmt.Printf("div_int64 1/-9223372036854775807 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int64_1_ssa(-9223372036854775807); got != -9223372036854775807 { + fmt.Printf("div_int64 -9223372036854775807/1 = %d, wanted -9223372036854775807\n", got) + failed = true + } + + if got := div_1_int64_ssa(-4294967296); got != 0 { + fmt.Printf("div_int64 1/-4294967296 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int64_1_ssa(-4294967296); got != -4294967296 { + fmt.Printf("div_int64 -4294967296/1 = %d, wanted -4294967296\n", got) + failed = true + } + + if got := div_1_int64_ssa(-1); got != -1 { + fmt.Printf("div_int64 1/-1 = %d, wanted -1\n", got) + failed = true + } + + if got := div_int64_1_ssa(-1); got != -1 { + fmt.Printf("div_int64 -1/1 = %d, wanted -1\n", got) + failed = true + } + + if got := div_int64_1_ssa(0); got != 0 { + fmt.Printf("div_int64 0/1 = %d, wanted 0\n", got) + failed = true + } + + if got := div_1_int64_ssa(1); got != 1 { + fmt.Printf("div_int64 1/1 = %d, wanted 1\n", got) + failed = true + } + + if got := div_int64_1_ssa(1); got != 1 { + fmt.Printf("div_int64 1/1 = %d, wanted 1\n", got) + failed = true + } + + if got := div_1_int64_ssa(4294967296); got != 0 { + fmt.Printf("div_int64 1/4294967296 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int64_1_ssa(4294967296); got != 4294967296 { + fmt.Printf("div_int64 4294967296/1 = %d, wanted 4294967296\n", got) + failed = true + } + + if got := div_1_int64_ssa(9223372036854775806); got != 0 { + fmt.Printf("div_int64 1/9223372036854775806 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int64_1_ssa(9223372036854775806); got != 9223372036854775806 { + fmt.Printf("div_int64 9223372036854775806/1 = %d, wanted 9223372036854775806\n", got) + failed = true + } + + if got := div_1_int64_ssa(9223372036854775807); got != 0 { + fmt.Printf("div_int64 1/9223372036854775807 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int64_1_ssa(9223372036854775807); got != 9223372036854775807 { + fmt.Printf("div_int64 9223372036854775807/1 = %d, wanted 9223372036854775807\n", got) + failed = true + } + + if got := div_4294967296_int64_ssa(-9223372036854775808); got != 0 { + fmt.Printf("div_int64 4294967296/-9223372036854775808 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int64_4294967296_ssa(-9223372036854775808); got != -2147483648 { + fmt.Printf("div_int64 -9223372036854775808/4294967296 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := div_4294967296_int64_ssa(-9223372036854775807); got != 0 { + fmt.Printf("div_int64 4294967296/-9223372036854775807 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int64_4294967296_ssa(-9223372036854775807); got != -2147483647 { + fmt.Printf("div_int64 -9223372036854775807/4294967296 = %d, wanted -2147483647\n", got) + failed = true + } + + if got := div_4294967296_int64_ssa(-4294967296); got != -1 { + fmt.Printf("div_int64 4294967296/-4294967296 = %d, wanted -1\n", got) + failed = true + } + + if got := div_int64_4294967296_ssa(-4294967296); got != -1 { + fmt.Printf("div_int64 -4294967296/4294967296 = %d, wanted -1\n", got) + failed = true + } + + if got := div_4294967296_int64_ssa(-1); got != -4294967296 { + fmt.Printf("div_int64 4294967296/-1 = %d, wanted -4294967296\n", got) + failed = true + } + + if got := div_int64_4294967296_ssa(-1); got != 0 { + fmt.Printf("div_int64 -1/4294967296 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int64_4294967296_ssa(0); got != 0 { + fmt.Printf("div_int64 0/4294967296 = %d, wanted 0\n", got) + failed = true + } + + if got := div_4294967296_int64_ssa(1); got != 4294967296 { + fmt.Printf("div_int64 4294967296/1 = %d, wanted 4294967296\n", got) + failed = true + } + + if got := div_int64_4294967296_ssa(1); got != 0 { + fmt.Printf("div_int64 1/4294967296 = %d, wanted 0\n", got) + failed = true + } + + if got := div_4294967296_int64_ssa(4294967296); got != 1 { + fmt.Printf("div_int64 4294967296/4294967296 = %d, wanted 1\n", got) + failed = true + } + + if got := div_int64_4294967296_ssa(4294967296); got != 1 { + fmt.Printf("div_int64 4294967296/4294967296 = %d, wanted 1\n", got) + failed = true + } + + if got := div_4294967296_int64_ssa(9223372036854775806); got != 0 { + fmt.Printf("div_int64 4294967296/9223372036854775806 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int64_4294967296_ssa(9223372036854775806); got != 2147483647 { + fmt.Printf("div_int64 9223372036854775806/4294967296 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := div_4294967296_int64_ssa(9223372036854775807); got != 0 { + fmt.Printf("div_int64 4294967296/9223372036854775807 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int64_4294967296_ssa(9223372036854775807); got != 2147483647 { + fmt.Printf("div_int64 9223372036854775807/4294967296 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := div_9223372036854775806_int64_ssa(-9223372036854775808); got != 0 { + fmt.Printf("div_int64 9223372036854775806/-9223372036854775808 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int64_9223372036854775806_ssa(-9223372036854775808); got != -1 { + fmt.Printf("div_int64 -9223372036854775808/9223372036854775806 = %d, wanted -1\n", got) + failed = true + } + + if got := div_9223372036854775806_int64_ssa(-9223372036854775807); got != 0 { + fmt.Printf("div_int64 9223372036854775806/-9223372036854775807 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int64_9223372036854775806_ssa(-9223372036854775807); got != -1 { + fmt.Printf("div_int64 -9223372036854775807/9223372036854775806 = %d, wanted -1\n", got) + failed = true + } + + if got := div_9223372036854775806_int64_ssa(-4294967296); got != -2147483647 { + fmt.Printf("div_int64 9223372036854775806/-4294967296 = %d, wanted -2147483647\n", got) + failed = true + } + + if got := div_int64_9223372036854775806_ssa(-4294967296); got != 0 { + fmt.Printf("div_int64 -4294967296/9223372036854775806 = %d, wanted 0\n", got) + failed = true + } + + if got := div_9223372036854775806_int64_ssa(-1); got != -9223372036854775806 { + fmt.Printf("div_int64 9223372036854775806/-1 = %d, wanted -9223372036854775806\n", got) + failed = true + } + + if got := div_int64_9223372036854775806_ssa(-1); got != 0 { + fmt.Printf("div_int64 -1/9223372036854775806 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int64_9223372036854775806_ssa(0); got != 0 { + fmt.Printf("div_int64 0/9223372036854775806 = %d, wanted 0\n", got) + failed = true + } + + if got := div_9223372036854775806_int64_ssa(1); got != 9223372036854775806 { + fmt.Printf("div_int64 9223372036854775806/1 = %d, wanted 9223372036854775806\n", got) + failed = true + } + + if got := div_int64_9223372036854775806_ssa(1); got != 0 { + fmt.Printf("div_int64 1/9223372036854775806 = %d, wanted 0\n", got) + failed = true + } + + if got := div_9223372036854775806_int64_ssa(4294967296); got != 2147483647 { + fmt.Printf("div_int64 9223372036854775806/4294967296 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := div_int64_9223372036854775806_ssa(4294967296); got != 0 { + fmt.Printf("div_int64 4294967296/9223372036854775806 = %d, wanted 0\n", got) + failed = true + } + + if got := div_9223372036854775806_int64_ssa(9223372036854775806); got != 1 { + fmt.Printf("div_int64 9223372036854775806/9223372036854775806 = %d, wanted 1\n", got) + failed = true + } + + if got := div_int64_9223372036854775806_ssa(9223372036854775806); got != 1 { + fmt.Printf("div_int64 9223372036854775806/9223372036854775806 = %d, wanted 1\n", got) + failed = true + } + + if got := div_9223372036854775806_int64_ssa(9223372036854775807); got != 0 { + fmt.Printf("div_int64 9223372036854775806/9223372036854775807 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int64_9223372036854775806_ssa(9223372036854775807); got != 1 { + fmt.Printf("div_int64 9223372036854775807/9223372036854775806 = %d, wanted 1\n", got) + failed = true + } + + if got := div_9223372036854775807_int64_ssa(-9223372036854775808); got != 0 { + fmt.Printf("div_int64 9223372036854775807/-9223372036854775808 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int64_9223372036854775807_ssa(-9223372036854775808); got != -1 { + fmt.Printf("div_int64 -9223372036854775808/9223372036854775807 = %d, wanted -1\n", got) + failed = true + } + + if got := div_9223372036854775807_int64_ssa(-9223372036854775807); got != -1 { + fmt.Printf("div_int64 9223372036854775807/-9223372036854775807 = %d, wanted -1\n", got) + failed = true + } + + if got := div_int64_9223372036854775807_ssa(-9223372036854775807); got != -1 { + fmt.Printf("div_int64 -9223372036854775807/9223372036854775807 = %d, wanted -1\n", got) + failed = true + } + + if got := div_9223372036854775807_int64_ssa(-4294967296); got != -2147483647 { + fmt.Printf("div_int64 9223372036854775807/-4294967296 = %d, wanted -2147483647\n", got) + failed = true + } + + if got := div_int64_9223372036854775807_ssa(-4294967296); got != 0 { + fmt.Printf("div_int64 -4294967296/9223372036854775807 = %d, wanted 0\n", got) + failed = true + } + + if got := div_9223372036854775807_int64_ssa(-1); got != -9223372036854775807 { + fmt.Printf("div_int64 9223372036854775807/-1 = %d, wanted -9223372036854775807\n", got) + failed = true + } + + if got := div_int64_9223372036854775807_ssa(-1); got != 0 { + fmt.Printf("div_int64 -1/9223372036854775807 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int64_9223372036854775807_ssa(0); got != 0 { + fmt.Printf("div_int64 0/9223372036854775807 = %d, wanted 0\n", got) + failed = true + } + + if got := div_9223372036854775807_int64_ssa(1); got != 9223372036854775807 { + fmt.Printf("div_int64 9223372036854775807/1 = %d, wanted 9223372036854775807\n", got) + failed = true + } + + if got := div_int64_9223372036854775807_ssa(1); got != 0 { + fmt.Printf("div_int64 1/9223372036854775807 = %d, wanted 0\n", got) + failed = true + } + + if got := div_9223372036854775807_int64_ssa(4294967296); got != 2147483647 { + fmt.Printf("div_int64 9223372036854775807/4294967296 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := div_int64_9223372036854775807_ssa(4294967296); got != 0 { + fmt.Printf("div_int64 4294967296/9223372036854775807 = %d, wanted 0\n", got) + failed = true + } + + if got := div_9223372036854775807_int64_ssa(9223372036854775806); got != 1 { + fmt.Printf("div_int64 9223372036854775807/9223372036854775806 = %d, wanted 1\n", got) + failed = true + } + + if got := div_int64_9223372036854775807_ssa(9223372036854775806); got != 0 { + fmt.Printf("div_int64 9223372036854775806/9223372036854775807 = %d, wanted 0\n", got) + failed = true + } + + if got := div_9223372036854775807_int64_ssa(9223372036854775807); got != 1 { + fmt.Printf("div_int64 9223372036854775807/9223372036854775807 = %d, wanted 1\n", got) + failed = true + } + + if got := div_int64_9223372036854775807_ssa(9223372036854775807); got != 1 { + fmt.Printf("div_int64 9223372036854775807/9223372036854775807 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_Neg9223372036854775808_int64_ssa(-9223372036854775808); got != 0 { + fmt.Printf("mul_int64 -9223372036854775808*-9223372036854775808 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int64_Neg9223372036854775808_ssa(-9223372036854775808); got != 0 { + fmt.Printf("mul_int64 -9223372036854775808*-9223372036854775808 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_Neg9223372036854775808_int64_ssa(-9223372036854775807); got != -9223372036854775808 { + fmt.Printf("mul_int64 -9223372036854775808*-9223372036854775807 = %d, wanted -9223372036854775808\n", got) + failed = true + } + + if got := mul_int64_Neg9223372036854775808_ssa(-9223372036854775807); got != -9223372036854775808 { + fmt.Printf("mul_int64 -9223372036854775807*-9223372036854775808 = %d, wanted -9223372036854775808\n", got) + failed = true + } + + if got := mul_Neg9223372036854775808_int64_ssa(-4294967296); got != 0 { + fmt.Printf("mul_int64 -9223372036854775808*-4294967296 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int64_Neg9223372036854775808_ssa(-4294967296); got != 0 { + fmt.Printf("mul_int64 -4294967296*-9223372036854775808 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_Neg9223372036854775808_int64_ssa(-1); got != -9223372036854775808 { + fmt.Printf("mul_int64 -9223372036854775808*-1 = %d, wanted -9223372036854775808\n", got) + failed = true + } + + if got := mul_int64_Neg9223372036854775808_ssa(-1); got != -9223372036854775808 { + fmt.Printf("mul_int64 -1*-9223372036854775808 = %d, wanted -9223372036854775808\n", got) + failed = true + } + + if got := mul_Neg9223372036854775808_int64_ssa(0); got != 0 { + fmt.Printf("mul_int64 -9223372036854775808*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int64_Neg9223372036854775808_ssa(0); got != 0 { + fmt.Printf("mul_int64 0*-9223372036854775808 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_Neg9223372036854775808_int64_ssa(1); got != -9223372036854775808 { + fmt.Printf("mul_int64 -9223372036854775808*1 = %d, wanted -9223372036854775808\n", got) + failed = true + } + + if got := mul_int64_Neg9223372036854775808_ssa(1); got != -9223372036854775808 { + fmt.Printf("mul_int64 1*-9223372036854775808 = %d, wanted -9223372036854775808\n", got) + failed = true + } + + if got := mul_Neg9223372036854775808_int64_ssa(4294967296); got != 0 { + fmt.Printf("mul_int64 -9223372036854775808*4294967296 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int64_Neg9223372036854775808_ssa(4294967296); got != 0 { + fmt.Printf("mul_int64 4294967296*-9223372036854775808 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_Neg9223372036854775808_int64_ssa(9223372036854775806); got != 0 { + fmt.Printf("mul_int64 -9223372036854775808*9223372036854775806 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int64_Neg9223372036854775808_ssa(9223372036854775806); got != 0 { + fmt.Printf("mul_int64 9223372036854775806*-9223372036854775808 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_Neg9223372036854775808_int64_ssa(9223372036854775807); got != -9223372036854775808 { + fmt.Printf("mul_int64 -9223372036854775808*9223372036854775807 = %d, wanted -9223372036854775808\n", got) + failed = true + } + + if got := mul_int64_Neg9223372036854775808_ssa(9223372036854775807); got != -9223372036854775808 { + fmt.Printf("mul_int64 9223372036854775807*-9223372036854775808 = %d, wanted -9223372036854775808\n", got) + failed = true + } + + if got := mul_Neg9223372036854775807_int64_ssa(-9223372036854775808); got != -9223372036854775808 { + fmt.Printf("mul_int64 -9223372036854775807*-9223372036854775808 = %d, wanted -9223372036854775808\n", got) + failed = true + } + + if got := mul_int64_Neg9223372036854775807_ssa(-9223372036854775808); got != -9223372036854775808 { + fmt.Printf("mul_int64 -9223372036854775808*-9223372036854775807 = %d, wanted -9223372036854775808\n", got) + failed = true + } + + if got := mul_Neg9223372036854775807_int64_ssa(-9223372036854775807); got != 1 { + fmt.Printf("mul_int64 -9223372036854775807*-9223372036854775807 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_int64_Neg9223372036854775807_ssa(-9223372036854775807); got != 1 { + fmt.Printf("mul_int64 -9223372036854775807*-9223372036854775807 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_Neg9223372036854775807_int64_ssa(-4294967296); got != -4294967296 { + fmt.Printf("mul_int64 -9223372036854775807*-4294967296 = %d, wanted -4294967296\n", got) + failed = true + } + + if got := mul_int64_Neg9223372036854775807_ssa(-4294967296); got != -4294967296 { + fmt.Printf("mul_int64 -4294967296*-9223372036854775807 = %d, wanted -4294967296\n", got) + failed = true + } + + if got := mul_Neg9223372036854775807_int64_ssa(-1); got != 9223372036854775807 { + fmt.Printf("mul_int64 -9223372036854775807*-1 = %d, wanted 9223372036854775807\n", got) + failed = true + } + + if got := mul_int64_Neg9223372036854775807_ssa(-1); got != 9223372036854775807 { + fmt.Printf("mul_int64 -1*-9223372036854775807 = %d, wanted 9223372036854775807\n", got) + failed = true + } + + if got := mul_Neg9223372036854775807_int64_ssa(0); got != 0 { + fmt.Printf("mul_int64 -9223372036854775807*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int64_Neg9223372036854775807_ssa(0); got != 0 { + fmt.Printf("mul_int64 0*-9223372036854775807 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_Neg9223372036854775807_int64_ssa(1); got != -9223372036854775807 { + fmt.Printf("mul_int64 -9223372036854775807*1 = %d, wanted -9223372036854775807\n", got) + failed = true + } + + if got := mul_int64_Neg9223372036854775807_ssa(1); got != -9223372036854775807 { + fmt.Printf("mul_int64 1*-9223372036854775807 = %d, wanted -9223372036854775807\n", got) + failed = true + } + + if got := mul_Neg9223372036854775807_int64_ssa(4294967296); got != 4294967296 { + fmt.Printf("mul_int64 -9223372036854775807*4294967296 = %d, wanted 4294967296\n", got) + failed = true + } + + if got := mul_int64_Neg9223372036854775807_ssa(4294967296); got != 4294967296 { + fmt.Printf("mul_int64 4294967296*-9223372036854775807 = %d, wanted 4294967296\n", got) + failed = true + } + + if got := mul_Neg9223372036854775807_int64_ssa(9223372036854775806); got != 9223372036854775806 { + fmt.Printf("mul_int64 -9223372036854775807*9223372036854775806 = %d, wanted 9223372036854775806\n", got) + failed = true + } + + if got := mul_int64_Neg9223372036854775807_ssa(9223372036854775806); got != 9223372036854775806 { + fmt.Printf("mul_int64 9223372036854775806*-9223372036854775807 = %d, wanted 9223372036854775806\n", got) + failed = true + } + + if got := mul_Neg9223372036854775807_int64_ssa(9223372036854775807); got != -1 { + fmt.Printf("mul_int64 -9223372036854775807*9223372036854775807 = %d, wanted -1\n", got) + failed = true + } + + if got := mul_int64_Neg9223372036854775807_ssa(9223372036854775807); got != -1 { + fmt.Printf("mul_int64 9223372036854775807*-9223372036854775807 = %d, wanted -1\n", got) + failed = true + } + + if got := mul_Neg4294967296_int64_ssa(-9223372036854775808); got != 0 { + fmt.Printf("mul_int64 -4294967296*-9223372036854775808 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int64_Neg4294967296_ssa(-9223372036854775808); got != 0 { + fmt.Printf("mul_int64 -9223372036854775808*-4294967296 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_Neg4294967296_int64_ssa(-9223372036854775807); got != -4294967296 { + fmt.Printf("mul_int64 -4294967296*-9223372036854775807 = %d, wanted -4294967296\n", got) + failed = true + } + + if got := mul_int64_Neg4294967296_ssa(-9223372036854775807); got != -4294967296 { + fmt.Printf("mul_int64 -9223372036854775807*-4294967296 = %d, wanted -4294967296\n", got) + failed = true + } + + if got := mul_Neg4294967296_int64_ssa(-4294967296); got != 0 { + fmt.Printf("mul_int64 -4294967296*-4294967296 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int64_Neg4294967296_ssa(-4294967296); got != 0 { + fmt.Printf("mul_int64 -4294967296*-4294967296 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_Neg4294967296_int64_ssa(-1); got != 4294967296 { + fmt.Printf("mul_int64 -4294967296*-1 = %d, wanted 4294967296\n", got) + failed = true + } + + if got := mul_int64_Neg4294967296_ssa(-1); got != 4294967296 { + fmt.Printf("mul_int64 -1*-4294967296 = %d, wanted 4294967296\n", got) + failed = true + } + + if got := mul_Neg4294967296_int64_ssa(0); got != 0 { + fmt.Printf("mul_int64 -4294967296*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int64_Neg4294967296_ssa(0); got != 0 { + fmt.Printf("mul_int64 0*-4294967296 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_Neg4294967296_int64_ssa(1); got != -4294967296 { + fmt.Printf("mul_int64 -4294967296*1 = %d, wanted -4294967296\n", got) + failed = true + } + + if got := mul_int64_Neg4294967296_ssa(1); got != -4294967296 { + fmt.Printf("mul_int64 1*-4294967296 = %d, wanted -4294967296\n", got) + failed = true + } + + if got := mul_Neg4294967296_int64_ssa(4294967296); got != 0 { + fmt.Printf("mul_int64 -4294967296*4294967296 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int64_Neg4294967296_ssa(4294967296); got != 0 { + fmt.Printf("mul_int64 4294967296*-4294967296 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_Neg4294967296_int64_ssa(9223372036854775806); got != 8589934592 { + fmt.Printf("mul_int64 -4294967296*9223372036854775806 = %d, wanted 8589934592\n", got) + failed = true + } + + if got := mul_int64_Neg4294967296_ssa(9223372036854775806); got != 8589934592 { + fmt.Printf("mul_int64 9223372036854775806*-4294967296 = %d, wanted 8589934592\n", got) + failed = true + } + + if got := mul_Neg4294967296_int64_ssa(9223372036854775807); got != 4294967296 { + fmt.Printf("mul_int64 -4294967296*9223372036854775807 = %d, wanted 4294967296\n", got) + failed = true + } + + if got := mul_int64_Neg4294967296_ssa(9223372036854775807); got != 4294967296 { + fmt.Printf("mul_int64 9223372036854775807*-4294967296 = %d, wanted 4294967296\n", got) + failed = true + } + + if got := mul_Neg1_int64_ssa(-9223372036854775808); got != -9223372036854775808 { + fmt.Printf("mul_int64 -1*-9223372036854775808 = %d, wanted -9223372036854775808\n", got) + failed = true + } + + if got := mul_int64_Neg1_ssa(-9223372036854775808); got != -9223372036854775808 { + fmt.Printf("mul_int64 -9223372036854775808*-1 = %d, wanted -9223372036854775808\n", got) + failed = true + } + + if got := mul_Neg1_int64_ssa(-9223372036854775807); got != 9223372036854775807 { + fmt.Printf("mul_int64 -1*-9223372036854775807 = %d, wanted 9223372036854775807\n", got) + failed = true + } + + if got := mul_int64_Neg1_ssa(-9223372036854775807); got != 9223372036854775807 { + fmt.Printf("mul_int64 -9223372036854775807*-1 = %d, wanted 9223372036854775807\n", got) + failed = true + } + + if got := mul_Neg1_int64_ssa(-4294967296); got != 4294967296 { + fmt.Printf("mul_int64 -1*-4294967296 = %d, wanted 4294967296\n", got) + failed = true + } + + if got := mul_int64_Neg1_ssa(-4294967296); got != 4294967296 { + fmt.Printf("mul_int64 -4294967296*-1 = %d, wanted 4294967296\n", got) + failed = true + } + + if got := mul_Neg1_int64_ssa(-1); got != 1 { + fmt.Printf("mul_int64 -1*-1 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_int64_Neg1_ssa(-1); got != 1 { + fmt.Printf("mul_int64 -1*-1 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_Neg1_int64_ssa(0); got != 0 { + fmt.Printf("mul_int64 -1*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int64_Neg1_ssa(0); got != 0 { + fmt.Printf("mul_int64 0*-1 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_Neg1_int64_ssa(1); got != -1 { + fmt.Printf("mul_int64 -1*1 = %d, wanted -1\n", got) + failed = true + } + + if got := mul_int64_Neg1_ssa(1); got != -1 { + fmt.Printf("mul_int64 1*-1 = %d, wanted -1\n", got) + failed = true + } + + if got := mul_Neg1_int64_ssa(4294967296); got != -4294967296 { + fmt.Printf("mul_int64 -1*4294967296 = %d, wanted -4294967296\n", got) + failed = true + } + + if got := mul_int64_Neg1_ssa(4294967296); got != -4294967296 { + fmt.Printf("mul_int64 4294967296*-1 = %d, wanted -4294967296\n", got) + failed = true + } + + if got := mul_Neg1_int64_ssa(9223372036854775806); got != -9223372036854775806 { + fmt.Printf("mul_int64 -1*9223372036854775806 = %d, wanted -9223372036854775806\n", got) + failed = true + } + + if got := mul_int64_Neg1_ssa(9223372036854775806); got != -9223372036854775806 { + fmt.Printf("mul_int64 9223372036854775806*-1 = %d, wanted -9223372036854775806\n", got) + failed = true + } + + if got := mul_Neg1_int64_ssa(9223372036854775807); got != -9223372036854775807 { + fmt.Printf("mul_int64 -1*9223372036854775807 = %d, wanted -9223372036854775807\n", got) + failed = true + } + + if got := mul_int64_Neg1_ssa(9223372036854775807); got != -9223372036854775807 { + fmt.Printf("mul_int64 9223372036854775807*-1 = %d, wanted -9223372036854775807\n", got) + failed = true + } + + if got := mul_0_int64_ssa(-9223372036854775808); got != 0 { + fmt.Printf("mul_int64 0*-9223372036854775808 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int64_0_ssa(-9223372036854775808); got != 0 { + fmt.Printf("mul_int64 -9223372036854775808*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_0_int64_ssa(-9223372036854775807); got != 0 { + fmt.Printf("mul_int64 0*-9223372036854775807 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int64_0_ssa(-9223372036854775807); got != 0 { + fmt.Printf("mul_int64 -9223372036854775807*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_0_int64_ssa(-4294967296); got != 0 { + fmt.Printf("mul_int64 0*-4294967296 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int64_0_ssa(-4294967296); got != 0 { + fmt.Printf("mul_int64 -4294967296*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_0_int64_ssa(-1); got != 0 { + fmt.Printf("mul_int64 0*-1 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int64_0_ssa(-1); got != 0 { + fmt.Printf("mul_int64 -1*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_0_int64_ssa(0); got != 0 { + fmt.Printf("mul_int64 0*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int64_0_ssa(0); got != 0 { + fmt.Printf("mul_int64 0*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_0_int64_ssa(1); got != 0 { + fmt.Printf("mul_int64 0*1 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int64_0_ssa(1); got != 0 { + fmt.Printf("mul_int64 1*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_0_int64_ssa(4294967296); got != 0 { + fmt.Printf("mul_int64 0*4294967296 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int64_0_ssa(4294967296); got != 0 { + fmt.Printf("mul_int64 4294967296*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_0_int64_ssa(9223372036854775806); got != 0 { + fmt.Printf("mul_int64 0*9223372036854775806 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int64_0_ssa(9223372036854775806); got != 0 { + fmt.Printf("mul_int64 9223372036854775806*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_0_int64_ssa(9223372036854775807); got != 0 { + fmt.Printf("mul_int64 0*9223372036854775807 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int64_0_ssa(9223372036854775807); got != 0 { + fmt.Printf("mul_int64 9223372036854775807*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_1_int64_ssa(-9223372036854775808); got != -9223372036854775808 { + fmt.Printf("mul_int64 1*-9223372036854775808 = %d, wanted -9223372036854775808\n", got) + failed = true + } + + if got := mul_int64_1_ssa(-9223372036854775808); got != -9223372036854775808 { + fmt.Printf("mul_int64 -9223372036854775808*1 = %d, wanted -9223372036854775808\n", got) + failed = true + } + + if got := mul_1_int64_ssa(-9223372036854775807); got != -9223372036854775807 { + fmt.Printf("mul_int64 1*-9223372036854775807 = %d, wanted -9223372036854775807\n", got) + failed = true + } + + if got := mul_int64_1_ssa(-9223372036854775807); got != -9223372036854775807 { + fmt.Printf("mul_int64 -9223372036854775807*1 = %d, wanted -9223372036854775807\n", got) + failed = true + } + + if got := mul_1_int64_ssa(-4294967296); got != -4294967296 { + fmt.Printf("mul_int64 1*-4294967296 = %d, wanted -4294967296\n", got) + failed = true + } + + if got := mul_int64_1_ssa(-4294967296); got != -4294967296 { + fmt.Printf("mul_int64 -4294967296*1 = %d, wanted -4294967296\n", got) + failed = true + } + + if got := mul_1_int64_ssa(-1); got != -1 { + fmt.Printf("mul_int64 1*-1 = %d, wanted -1\n", got) + failed = true + } + + if got := mul_int64_1_ssa(-1); got != -1 { + fmt.Printf("mul_int64 -1*1 = %d, wanted -1\n", got) + failed = true + } + + if got := mul_1_int64_ssa(0); got != 0 { + fmt.Printf("mul_int64 1*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int64_1_ssa(0); got != 0 { + fmt.Printf("mul_int64 0*1 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_1_int64_ssa(1); got != 1 { + fmt.Printf("mul_int64 1*1 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_int64_1_ssa(1); got != 1 { + fmt.Printf("mul_int64 1*1 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_1_int64_ssa(4294967296); got != 4294967296 { + fmt.Printf("mul_int64 1*4294967296 = %d, wanted 4294967296\n", got) + failed = true + } + + if got := mul_int64_1_ssa(4294967296); got != 4294967296 { + fmt.Printf("mul_int64 4294967296*1 = %d, wanted 4294967296\n", got) + failed = true + } + + if got := mul_1_int64_ssa(9223372036854775806); got != 9223372036854775806 { + fmt.Printf("mul_int64 1*9223372036854775806 = %d, wanted 9223372036854775806\n", got) + failed = true + } + + if got := mul_int64_1_ssa(9223372036854775806); got != 9223372036854775806 { + fmt.Printf("mul_int64 9223372036854775806*1 = %d, wanted 9223372036854775806\n", got) + failed = true + } + + if got := mul_1_int64_ssa(9223372036854775807); got != 9223372036854775807 { + fmt.Printf("mul_int64 1*9223372036854775807 = %d, wanted 9223372036854775807\n", got) + failed = true + } + + if got := mul_int64_1_ssa(9223372036854775807); got != 9223372036854775807 { + fmt.Printf("mul_int64 9223372036854775807*1 = %d, wanted 9223372036854775807\n", got) + failed = true + } + + if got := mul_4294967296_int64_ssa(-9223372036854775808); got != 0 { + fmt.Printf("mul_int64 4294967296*-9223372036854775808 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int64_4294967296_ssa(-9223372036854775808); got != 0 { + fmt.Printf("mul_int64 -9223372036854775808*4294967296 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_4294967296_int64_ssa(-9223372036854775807); got != 4294967296 { + fmt.Printf("mul_int64 4294967296*-9223372036854775807 = %d, wanted 4294967296\n", got) + failed = true + } + + if got := mul_int64_4294967296_ssa(-9223372036854775807); got != 4294967296 { + fmt.Printf("mul_int64 -9223372036854775807*4294967296 = %d, wanted 4294967296\n", got) + failed = true + } + + if got := mul_4294967296_int64_ssa(-4294967296); got != 0 { + fmt.Printf("mul_int64 4294967296*-4294967296 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int64_4294967296_ssa(-4294967296); got != 0 { + fmt.Printf("mul_int64 -4294967296*4294967296 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_4294967296_int64_ssa(-1); got != -4294967296 { + fmt.Printf("mul_int64 4294967296*-1 = %d, wanted -4294967296\n", got) + failed = true + } + + if got := mul_int64_4294967296_ssa(-1); got != -4294967296 { + fmt.Printf("mul_int64 -1*4294967296 = %d, wanted -4294967296\n", got) + failed = true + } + + if got := mul_4294967296_int64_ssa(0); got != 0 { + fmt.Printf("mul_int64 4294967296*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int64_4294967296_ssa(0); got != 0 { + fmt.Printf("mul_int64 0*4294967296 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_4294967296_int64_ssa(1); got != 4294967296 { + fmt.Printf("mul_int64 4294967296*1 = %d, wanted 4294967296\n", got) + failed = true + } + + if got := mul_int64_4294967296_ssa(1); got != 4294967296 { + fmt.Printf("mul_int64 1*4294967296 = %d, wanted 4294967296\n", got) + failed = true + } + + if got := mul_4294967296_int64_ssa(4294967296); got != 0 { + fmt.Printf("mul_int64 4294967296*4294967296 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int64_4294967296_ssa(4294967296); got != 0 { + fmt.Printf("mul_int64 4294967296*4294967296 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_4294967296_int64_ssa(9223372036854775806); got != -8589934592 { + fmt.Printf("mul_int64 4294967296*9223372036854775806 = %d, wanted -8589934592\n", got) + failed = true + } + + if got := mul_int64_4294967296_ssa(9223372036854775806); got != -8589934592 { + fmt.Printf("mul_int64 9223372036854775806*4294967296 = %d, wanted -8589934592\n", got) + failed = true + } + + if got := mul_4294967296_int64_ssa(9223372036854775807); got != -4294967296 { + fmt.Printf("mul_int64 4294967296*9223372036854775807 = %d, wanted -4294967296\n", got) + failed = true + } + + if got := mul_int64_4294967296_ssa(9223372036854775807); got != -4294967296 { + fmt.Printf("mul_int64 9223372036854775807*4294967296 = %d, wanted -4294967296\n", got) + failed = true + } + + if got := mul_9223372036854775806_int64_ssa(-9223372036854775808); got != 0 { + fmt.Printf("mul_int64 9223372036854775806*-9223372036854775808 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int64_9223372036854775806_ssa(-9223372036854775808); got != 0 { + fmt.Printf("mul_int64 -9223372036854775808*9223372036854775806 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_9223372036854775806_int64_ssa(-9223372036854775807); got != 9223372036854775806 { + fmt.Printf("mul_int64 9223372036854775806*-9223372036854775807 = %d, wanted 9223372036854775806\n", got) + failed = true + } + + if got := mul_int64_9223372036854775806_ssa(-9223372036854775807); got != 9223372036854775806 { + fmt.Printf("mul_int64 -9223372036854775807*9223372036854775806 = %d, wanted 9223372036854775806\n", got) + failed = true + } + + if got := mul_9223372036854775806_int64_ssa(-4294967296); got != 8589934592 { + fmt.Printf("mul_int64 9223372036854775806*-4294967296 = %d, wanted 8589934592\n", got) + failed = true + } + + if got := mul_int64_9223372036854775806_ssa(-4294967296); got != 8589934592 { + fmt.Printf("mul_int64 -4294967296*9223372036854775806 = %d, wanted 8589934592\n", got) + failed = true + } + + if got := mul_9223372036854775806_int64_ssa(-1); got != -9223372036854775806 { + fmt.Printf("mul_int64 9223372036854775806*-1 = %d, wanted -9223372036854775806\n", got) + failed = true + } + + if got := mul_int64_9223372036854775806_ssa(-1); got != -9223372036854775806 { + fmt.Printf("mul_int64 -1*9223372036854775806 = %d, wanted -9223372036854775806\n", got) + failed = true + } + + if got := mul_9223372036854775806_int64_ssa(0); got != 0 { + fmt.Printf("mul_int64 9223372036854775806*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int64_9223372036854775806_ssa(0); got != 0 { + fmt.Printf("mul_int64 0*9223372036854775806 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_9223372036854775806_int64_ssa(1); got != 9223372036854775806 { + fmt.Printf("mul_int64 9223372036854775806*1 = %d, wanted 9223372036854775806\n", got) + failed = true + } + + if got := mul_int64_9223372036854775806_ssa(1); got != 9223372036854775806 { + fmt.Printf("mul_int64 1*9223372036854775806 = %d, wanted 9223372036854775806\n", got) + failed = true + } + + if got := mul_9223372036854775806_int64_ssa(4294967296); got != -8589934592 { + fmt.Printf("mul_int64 9223372036854775806*4294967296 = %d, wanted -8589934592\n", got) + failed = true + } + + if got := mul_int64_9223372036854775806_ssa(4294967296); got != -8589934592 { + fmt.Printf("mul_int64 4294967296*9223372036854775806 = %d, wanted -8589934592\n", got) + failed = true + } + + if got := mul_9223372036854775806_int64_ssa(9223372036854775806); got != 4 { + fmt.Printf("mul_int64 9223372036854775806*9223372036854775806 = %d, wanted 4\n", got) + failed = true + } + + if got := mul_int64_9223372036854775806_ssa(9223372036854775806); got != 4 { + fmt.Printf("mul_int64 9223372036854775806*9223372036854775806 = %d, wanted 4\n", got) + failed = true + } + + if got := mul_9223372036854775806_int64_ssa(9223372036854775807); got != -9223372036854775806 { + fmt.Printf("mul_int64 9223372036854775806*9223372036854775807 = %d, wanted -9223372036854775806\n", got) + failed = true + } + + if got := mul_int64_9223372036854775806_ssa(9223372036854775807); got != -9223372036854775806 { + fmt.Printf("mul_int64 9223372036854775807*9223372036854775806 = %d, wanted -9223372036854775806\n", got) + failed = true + } + + if got := mul_9223372036854775807_int64_ssa(-9223372036854775808); got != -9223372036854775808 { + fmt.Printf("mul_int64 9223372036854775807*-9223372036854775808 = %d, wanted -9223372036854775808\n", got) + failed = true + } + + if got := mul_int64_9223372036854775807_ssa(-9223372036854775808); got != -9223372036854775808 { + fmt.Printf("mul_int64 -9223372036854775808*9223372036854775807 = %d, wanted -9223372036854775808\n", got) + failed = true + } + + if got := mul_9223372036854775807_int64_ssa(-9223372036854775807); got != -1 { + fmt.Printf("mul_int64 9223372036854775807*-9223372036854775807 = %d, wanted -1\n", got) + failed = true + } + + if got := mul_int64_9223372036854775807_ssa(-9223372036854775807); got != -1 { + fmt.Printf("mul_int64 -9223372036854775807*9223372036854775807 = %d, wanted -1\n", got) + failed = true + } + + if got := mul_9223372036854775807_int64_ssa(-4294967296); got != 4294967296 { + fmt.Printf("mul_int64 9223372036854775807*-4294967296 = %d, wanted 4294967296\n", got) + failed = true + } + + if got := mul_int64_9223372036854775807_ssa(-4294967296); got != 4294967296 { + fmt.Printf("mul_int64 -4294967296*9223372036854775807 = %d, wanted 4294967296\n", got) + failed = true + } + + if got := mul_9223372036854775807_int64_ssa(-1); got != -9223372036854775807 { + fmt.Printf("mul_int64 9223372036854775807*-1 = %d, wanted -9223372036854775807\n", got) + failed = true + } + + if got := mul_int64_9223372036854775807_ssa(-1); got != -9223372036854775807 { + fmt.Printf("mul_int64 -1*9223372036854775807 = %d, wanted -9223372036854775807\n", got) + failed = true + } + + if got := mul_9223372036854775807_int64_ssa(0); got != 0 { + fmt.Printf("mul_int64 9223372036854775807*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int64_9223372036854775807_ssa(0); got != 0 { + fmt.Printf("mul_int64 0*9223372036854775807 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_9223372036854775807_int64_ssa(1); got != 9223372036854775807 { + fmt.Printf("mul_int64 9223372036854775807*1 = %d, wanted 9223372036854775807\n", got) + failed = true + } + + if got := mul_int64_9223372036854775807_ssa(1); got != 9223372036854775807 { + fmt.Printf("mul_int64 1*9223372036854775807 = %d, wanted 9223372036854775807\n", got) + failed = true + } + + if got := mul_9223372036854775807_int64_ssa(4294967296); got != -4294967296 { + fmt.Printf("mul_int64 9223372036854775807*4294967296 = %d, wanted -4294967296\n", got) + failed = true + } + + if got := mul_int64_9223372036854775807_ssa(4294967296); got != -4294967296 { + fmt.Printf("mul_int64 4294967296*9223372036854775807 = %d, wanted -4294967296\n", got) + failed = true + } + + if got := mul_9223372036854775807_int64_ssa(9223372036854775806); got != -9223372036854775806 { + fmt.Printf("mul_int64 9223372036854775807*9223372036854775806 = %d, wanted -9223372036854775806\n", got) + failed = true + } + + if got := mul_int64_9223372036854775807_ssa(9223372036854775806); got != -9223372036854775806 { + fmt.Printf("mul_int64 9223372036854775806*9223372036854775807 = %d, wanted -9223372036854775806\n", got) + failed = true + } + + if got := mul_9223372036854775807_int64_ssa(9223372036854775807); got != 1 { + fmt.Printf("mul_int64 9223372036854775807*9223372036854775807 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_int64_9223372036854775807_ssa(9223372036854775807); got != 1 { + fmt.Printf("mul_int64 9223372036854775807*9223372036854775807 = %d, wanted 1\n", got) + failed = true + } + + if got := add_0_uint32_ssa(0); got != 0 { + fmt.Printf("add_uint32 0+0 = %d, wanted 0\n", got) + failed = true + } + + if got := add_uint32_0_ssa(0); got != 0 { + fmt.Printf("add_uint32 0+0 = %d, wanted 0\n", got) + failed = true + } + + if got := add_0_uint32_ssa(1); got != 1 { + fmt.Printf("add_uint32 0+1 = %d, wanted 1\n", got) + failed = true + } + + if got := add_uint32_0_ssa(1); got != 1 { + fmt.Printf("add_uint32 1+0 = %d, wanted 1\n", got) + failed = true + } + + if got := add_0_uint32_ssa(4294967295); got != 4294967295 { + fmt.Printf("add_uint32 0+4294967295 = %d, wanted 4294967295\n", got) + failed = true + } + + if got := add_uint32_0_ssa(4294967295); got != 4294967295 { + fmt.Printf("add_uint32 4294967295+0 = %d, wanted 4294967295\n", got) + failed = true + } + + if got := add_1_uint32_ssa(0); got != 1 { + fmt.Printf("add_uint32 1+0 = %d, wanted 1\n", got) + failed = true + } + + if got := add_uint32_1_ssa(0); got != 1 { + fmt.Printf("add_uint32 0+1 = %d, wanted 1\n", got) + failed = true + } + + if got := add_1_uint32_ssa(1); got != 2 { + fmt.Printf("add_uint32 1+1 = %d, wanted 2\n", got) + failed = true + } + + if got := add_uint32_1_ssa(1); got != 2 { + fmt.Printf("add_uint32 1+1 = %d, wanted 2\n", got) + failed = true + } + + if got := add_1_uint32_ssa(4294967295); got != 0 { + fmt.Printf("add_uint32 1+4294967295 = %d, wanted 0\n", got) + failed = true + } + + if got := add_uint32_1_ssa(4294967295); got != 0 { + fmt.Printf("add_uint32 4294967295+1 = %d, wanted 0\n", got) + failed = true + } + + if got := add_4294967295_uint32_ssa(0); got != 4294967295 { + fmt.Printf("add_uint32 4294967295+0 = %d, wanted 4294967295\n", got) + failed = true + } + + if got := add_uint32_4294967295_ssa(0); got != 4294967295 { + fmt.Printf("add_uint32 0+4294967295 = %d, wanted 4294967295\n", got) + failed = true + } + + if got := add_4294967295_uint32_ssa(1); got != 0 { + fmt.Printf("add_uint32 4294967295+1 = %d, wanted 0\n", got) + failed = true + } + + if got := add_uint32_4294967295_ssa(1); got != 0 { + fmt.Printf("add_uint32 1+4294967295 = %d, wanted 0\n", got) + failed = true + } + + if got := add_4294967295_uint32_ssa(4294967295); got != 4294967294 { + fmt.Printf("add_uint32 4294967295+4294967295 = %d, wanted 4294967294\n", got) + failed = true + } + + if got := add_uint32_4294967295_ssa(4294967295); got != 4294967294 { + fmt.Printf("add_uint32 4294967295+4294967295 = %d, wanted 4294967294\n", got) + failed = true + } + + if got := sub_0_uint32_ssa(0); got != 0 { + fmt.Printf("sub_uint32 0-0 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_uint32_0_ssa(0); got != 0 { + fmt.Printf("sub_uint32 0-0 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_0_uint32_ssa(1); got != 4294967295 { + fmt.Printf("sub_uint32 0-1 = %d, wanted 4294967295\n", got) + failed = true + } + + if got := sub_uint32_0_ssa(1); got != 1 { + fmt.Printf("sub_uint32 1-0 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_0_uint32_ssa(4294967295); got != 1 { + fmt.Printf("sub_uint32 0-4294967295 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_uint32_0_ssa(4294967295); got != 4294967295 { + fmt.Printf("sub_uint32 4294967295-0 = %d, wanted 4294967295\n", got) + failed = true + } + + if got := sub_1_uint32_ssa(0); got != 1 { + fmt.Printf("sub_uint32 1-0 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_uint32_1_ssa(0); got != 4294967295 { + fmt.Printf("sub_uint32 0-1 = %d, wanted 4294967295\n", got) + failed = true + } + + if got := sub_1_uint32_ssa(1); got != 0 { + fmt.Printf("sub_uint32 1-1 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_uint32_1_ssa(1); got != 0 { + fmt.Printf("sub_uint32 1-1 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_1_uint32_ssa(4294967295); got != 2 { + fmt.Printf("sub_uint32 1-4294967295 = %d, wanted 2\n", got) + failed = true + } + + if got := sub_uint32_1_ssa(4294967295); got != 4294967294 { + fmt.Printf("sub_uint32 4294967295-1 = %d, wanted 4294967294\n", got) + failed = true + } + + if got := sub_4294967295_uint32_ssa(0); got != 4294967295 { + fmt.Printf("sub_uint32 4294967295-0 = %d, wanted 4294967295\n", got) + failed = true + } + + if got := sub_uint32_4294967295_ssa(0); got != 1 { + fmt.Printf("sub_uint32 0-4294967295 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_4294967295_uint32_ssa(1); got != 4294967294 { + fmt.Printf("sub_uint32 4294967295-1 = %d, wanted 4294967294\n", got) + failed = true + } + + if got := sub_uint32_4294967295_ssa(1); got != 2 { + fmt.Printf("sub_uint32 1-4294967295 = %d, wanted 2\n", got) + failed = true + } + + if got := sub_4294967295_uint32_ssa(4294967295); got != 0 { + fmt.Printf("sub_uint32 4294967295-4294967295 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_uint32_4294967295_ssa(4294967295); got != 0 { + fmt.Printf("sub_uint32 4294967295-4294967295 = %d, wanted 0\n", got) + failed = true + } + + if got := div_0_uint32_ssa(1); got != 0 { + fmt.Printf("div_uint32 0/1 = %d, wanted 0\n", got) + failed = true + } + + if got := div_0_uint32_ssa(4294967295); got != 0 { + fmt.Printf("div_uint32 0/4294967295 = %d, wanted 0\n", got) + failed = true + } + + if got := div_uint32_1_ssa(0); got != 0 { + fmt.Printf("div_uint32 0/1 = %d, wanted 0\n", got) + failed = true + } + + if got := div_1_uint32_ssa(1); got != 1 { + fmt.Printf("div_uint32 1/1 = %d, wanted 1\n", got) + failed = true + } + + if got := div_uint32_1_ssa(1); got != 1 { + fmt.Printf("div_uint32 1/1 = %d, wanted 1\n", got) + failed = true + } + + if got := div_1_uint32_ssa(4294967295); got != 0 { + fmt.Printf("div_uint32 1/4294967295 = %d, wanted 0\n", got) + failed = true + } + + if got := div_uint32_1_ssa(4294967295); got != 4294967295 { + fmt.Printf("div_uint32 4294967295/1 = %d, wanted 4294967295\n", got) + failed = true + } + + if got := div_uint32_4294967295_ssa(0); got != 0 { + fmt.Printf("div_uint32 0/4294967295 = %d, wanted 0\n", got) + failed = true + } + + if got := div_4294967295_uint32_ssa(1); got != 4294967295 { + fmt.Printf("div_uint32 4294967295/1 = %d, wanted 4294967295\n", got) + failed = true + } + + if got := div_uint32_4294967295_ssa(1); got != 0 { + fmt.Printf("div_uint32 1/4294967295 = %d, wanted 0\n", got) + failed = true + } + + if got := div_4294967295_uint32_ssa(4294967295); got != 1 { + fmt.Printf("div_uint32 4294967295/4294967295 = %d, wanted 1\n", got) + failed = true + } + + if got := div_uint32_4294967295_ssa(4294967295); got != 1 { + fmt.Printf("div_uint32 4294967295/4294967295 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_0_uint32_ssa(0); got != 0 { + fmt.Printf("mul_uint32 0*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_uint32_0_ssa(0); got != 0 { + fmt.Printf("mul_uint32 0*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_0_uint32_ssa(1); got != 0 { + fmt.Printf("mul_uint32 0*1 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_uint32_0_ssa(1); got != 0 { + fmt.Printf("mul_uint32 1*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_0_uint32_ssa(4294967295); got != 0 { + fmt.Printf("mul_uint32 0*4294967295 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_uint32_0_ssa(4294967295); got != 0 { + fmt.Printf("mul_uint32 4294967295*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_1_uint32_ssa(0); got != 0 { + fmt.Printf("mul_uint32 1*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_uint32_1_ssa(0); got != 0 { + fmt.Printf("mul_uint32 0*1 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_1_uint32_ssa(1); got != 1 { + fmt.Printf("mul_uint32 1*1 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_uint32_1_ssa(1); got != 1 { + fmt.Printf("mul_uint32 1*1 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_1_uint32_ssa(4294967295); got != 4294967295 { + fmt.Printf("mul_uint32 1*4294967295 = %d, wanted 4294967295\n", got) + failed = true + } + + if got := mul_uint32_1_ssa(4294967295); got != 4294967295 { + fmt.Printf("mul_uint32 4294967295*1 = %d, wanted 4294967295\n", got) + failed = true + } + + if got := mul_4294967295_uint32_ssa(0); got != 0 { + fmt.Printf("mul_uint32 4294967295*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_uint32_4294967295_ssa(0); got != 0 { + fmt.Printf("mul_uint32 0*4294967295 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_4294967295_uint32_ssa(1); got != 4294967295 { + fmt.Printf("mul_uint32 4294967295*1 = %d, wanted 4294967295\n", got) + failed = true + } + + if got := mul_uint32_4294967295_ssa(1); got != 4294967295 { + fmt.Printf("mul_uint32 1*4294967295 = %d, wanted 4294967295\n", got) + failed = true + } + + if got := mul_4294967295_uint32_ssa(4294967295); got != 1 { + fmt.Printf("mul_uint32 4294967295*4294967295 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_uint32_4294967295_ssa(4294967295); got != 1 { + fmt.Printf("mul_uint32 4294967295*4294967295 = %d, wanted 1\n", got) + failed = true + } + + if got := lsh_0_uint32_ssa(0); got != 0 { + fmt.Printf("lsh_uint32 0<<0 = %d, wanted 0\n", got) + failed = true + } + + if got := lsh_uint32_0_ssa(0); got != 0 { + fmt.Printf("lsh_uint32 0<<0 = %d, wanted 0\n", got) + failed = true + } + + if got := lsh_0_uint32_ssa(1); got != 0 { + fmt.Printf("lsh_uint32 0<<1 = %d, wanted 0\n", got) + failed = true + } + + if got := lsh_uint32_0_ssa(1); got != 1 { + fmt.Printf("lsh_uint32 1<<0 = %d, wanted 1\n", got) + failed = true + } + + if got := lsh_0_uint32_ssa(4294967295); got != 0 { + fmt.Printf("lsh_uint32 0<<4294967295 = %d, wanted 0\n", got) + failed = true + } + + if got := lsh_uint32_0_ssa(4294967295); got != 4294967295 { + fmt.Printf("lsh_uint32 4294967295<<0 = %d, wanted 4294967295\n", got) + failed = true + } + + if got := lsh_1_uint32_ssa(0); got != 1 { + fmt.Printf("lsh_uint32 1<<0 = %d, wanted 1\n", got) + failed = true + } + + if got := lsh_uint32_1_ssa(0); got != 0 { + fmt.Printf("lsh_uint32 0<<1 = %d, wanted 0\n", got) + failed = true + } + + if got := lsh_1_uint32_ssa(1); got != 2 { + fmt.Printf("lsh_uint32 1<<1 = %d, wanted 2\n", got) + failed = true + } + + if got := lsh_uint32_1_ssa(1); got != 2 { + fmt.Printf("lsh_uint32 1<<1 = %d, wanted 2\n", got) + failed = true + } + + if got := lsh_1_uint32_ssa(4294967295); got != 0 { + fmt.Printf("lsh_uint32 1<<4294967295 = %d, wanted 0\n", got) + failed = true + } + + if got := lsh_uint32_1_ssa(4294967295); got != 4294967294 { + fmt.Printf("lsh_uint32 4294967295<<1 = %d, wanted 4294967294\n", got) + failed = true + } + + if got := lsh_4294967295_uint32_ssa(0); got != 4294967295 { + fmt.Printf("lsh_uint32 4294967295<<0 = %d, wanted 4294967295\n", got) + failed = true + } + + if got := lsh_uint32_4294967295_ssa(0); got != 0 { + fmt.Printf("lsh_uint32 0<<4294967295 = %d, wanted 0\n", got) + failed = true + } + + if got := lsh_4294967295_uint32_ssa(1); got != 4294967294 { + fmt.Printf("lsh_uint32 4294967295<<1 = %d, wanted 4294967294\n", got) + failed = true + } + + if got := lsh_uint32_4294967295_ssa(1); got != 0 { + fmt.Printf("lsh_uint32 1<<4294967295 = %d, wanted 0\n", got) + failed = true + } + + if got := lsh_4294967295_uint32_ssa(4294967295); got != 0 { + fmt.Printf("lsh_uint32 4294967295<<4294967295 = %d, wanted 0\n", got) + failed = true + } + + if got := lsh_uint32_4294967295_ssa(4294967295); got != 0 { + fmt.Printf("lsh_uint32 4294967295<<4294967295 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_0_uint32_ssa(0); got != 0 { + fmt.Printf("rsh_uint32 0>>0 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_uint32_0_ssa(0); got != 0 { + fmt.Printf("rsh_uint32 0>>0 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_0_uint32_ssa(1); got != 0 { + fmt.Printf("rsh_uint32 0>>1 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_uint32_0_ssa(1); got != 1 { + fmt.Printf("rsh_uint32 1>>0 = %d, wanted 1\n", got) + failed = true + } + + if got := rsh_0_uint32_ssa(4294967295); got != 0 { + fmt.Printf("rsh_uint32 0>>4294967295 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_uint32_0_ssa(4294967295); got != 4294967295 { + fmt.Printf("rsh_uint32 4294967295>>0 = %d, wanted 4294967295\n", got) + failed = true + } + + if got := rsh_1_uint32_ssa(0); got != 1 { + fmt.Printf("rsh_uint32 1>>0 = %d, wanted 1\n", got) + failed = true + } + + if got := rsh_uint32_1_ssa(0); got != 0 { + fmt.Printf("rsh_uint32 0>>1 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_1_uint32_ssa(1); got != 0 { + fmt.Printf("rsh_uint32 1>>1 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_uint32_1_ssa(1); got != 0 { + fmt.Printf("rsh_uint32 1>>1 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_1_uint32_ssa(4294967295); got != 0 { + fmt.Printf("rsh_uint32 1>>4294967295 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_uint32_1_ssa(4294967295); got != 2147483647 { + fmt.Printf("rsh_uint32 4294967295>>1 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := rsh_4294967295_uint32_ssa(0); got != 4294967295 { + fmt.Printf("rsh_uint32 4294967295>>0 = %d, wanted 4294967295\n", got) + failed = true + } + + if got := rsh_uint32_4294967295_ssa(0); got != 0 { + fmt.Printf("rsh_uint32 0>>4294967295 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_4294967295_uint32_ssa(1); got != 2147483647 { + fmt.Printf("rsh_uint32 4294967295>>1 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := rsh_uint32_4294967295_ssa(1); got != 0 { + fmt.Printf("rsh_uint32 1>>4294967295 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_4294967295_uint32_ssa(4294967295); got != 0 { + fmt.Printf("rsh_uint32 4294967295>>4294967295 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_uint32_4294967295_ssa(4294967295); got != 0 { + fmt.Printf("rsh_uint32 4294967295>>4294967295 = %d, wanted 0\n", got) + failed = true + } + + if got := add_Neg2147483648_int32_ssa(-2147483648); got != 0 { + fmt.Printf("add_int32 -2147483648+-2147483648 = %d, wanted 0\n", got) + failed = true + } + + if got := add_int32_Neg2147483648_ssa(-2147483648); got != 0 { + fmt.Printf("add_int32 -2147483648+-2147483648 = %d, wanted 0\n", got) + failed = true + } + + if got := add_Neg2147483648_int32_ssa(-2147483647); got != 1 { + fmt.Printf("add_int32 -2147483648+-2147483647 = %d, wanted 1\n", got) + failed = true + } + + if got := add_int32_Neg2147483648_ssa(-2147483647); got != 1 { + fmt.Printf("add_int32 -2147483647+-2147483648 = %d, wanted 1\n", got) + failed = true + } + + if got := add_Neg2147483648_int32_ssa(-1); got != 2147483647 { + fmt.Printf("add_int32 -2147483648+-1 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := add_int32_Neg2147483648_ssa(-1); got != 2147483647 { + fmt.Printf("add_int32 -1+-2147483648 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := add_Neg2147483648_int32_ssa(0); got != -2147483648 { + fmt.Printf("add_int32 -2147483648+0 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := add_int32_Neg2147483648_ssa(0); got != -2147483648 { + fmt.Printf("add_int32 0+-2147483648 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := add_Neg2147483648_int32_ssa(1); got != -2147483647 { + fmt.Printf("add_int32 -2147483648+1 = %d, wanted -2147483647\n", got) + failed = true + } + + if got := add_int32_Neg2147483648_ssa(1); got != -2147483647 { + fmt.Printf("add_int32 1+-2147483648 = %d, wanted -2147483647\n", got) + failed = true + } + + if got := add_Neg2147483648_int32_ssa(2147483647); got != -1 { + fmt.Printf("add_int32 -2147483648+2147483647 = %d, wanted -1\n", got) + failed = true + } + + if got := add_int32_Neg2147483648_ssa(2147483647); got != -1 { + fmt.Printf("add_int32 2147483647+-2147483648 = %d, wanted -1\n", got) + failed = true + } + + if got := add_Neg2147483647_int32_ssa(-2147483648); got != 1 { + fmt.Printf("add_int32 -2147483647+-2147483648 = %d, wanted 1\n", got) + failed = true + } + + if got := add_int32_Neg2147483647_ssa(-2147483648); got != 1 { + fmt.Printf("add_int32 -2147483648+-2147483647 = %d, wanted 1\n", got) + failed = true + } + + if got := add_Neg2147483647_int32_ssa(-2147483647); got != 2 { + fmt.Printf("add_int32 -2147483647+-2147483647 = %d, wanted 2\n", got) + failed = true + } + + if got := add_int32_Neg2147483647_ssa(-2147483647); got != 2 { + fmt.Printf("add_int32 -2147483647+-2147483647 = %d, wanted 2\n", got) + failed = true + } + + if got := add_Neg2147483647_int32_ssa(-1); got != -2147483648 { + fmt.Printf("add_int32 -2147483647+-1 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := add_int32_Neg2147483647_ssa(-1); got != -2147483648 { + fmt.Printf("add_int32 -1+-2147483647 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := add_Neg2147483647_int32_ssa(0); got != -2147483647 { + fmt.Printf("add_int32 -2147483647+0 = %d, wanted -2147483647\n", got) + failed = true + } + + if got := add_int32_Neg2147483647_ssa(0); got != -2147483647 { + fmt.Printf("add_int32 0+-2147483647 = %d, wanted -2147483647\n", got) + failed = true + } + + if got := add_Neg2147483647_int32_ssa(1); got != -2147483646 { + fmt.Printf("add_int32 -2147483647+1 = %d, wanted -2147483646\n", got) + failed = true + } + + if got := add_int32_Neg2147483647_ssa(1); got != -2147483646 { + fmt.Printf("add_int32 1+-2147483647 = %d, wanted -2147483646\n", got) + failed = true + } + + if got := add_Neg2147483647_int32_ssa(2147483647); got != 0 { + fmt.Printf("add_int32 -2147483647+2147483647 = %d, wanted 0\n", got) + failed = true + } + + if got := add_int32_Neg2147483647_ssa(2147483647); got != 0 { + fmt.Printf("add_int32 2147483647+-2147483647 = %d, wanted 0\n", got) + failed = true + } + + if got := add_Neg1_int32_ssa(-2147483648); got != 2147483647 { + fmt.Printf("add_int32 -1+-2147483648 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := add_int32_Neg1_ssa(-2147483648); got != 2147483647 { + fmt.Printf("add_int32 -2147483648+-1 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := add_Neg1_int32_ssa(-2147483647); got != -2147483648 { + fmt.Printf("add_int32 -1+-2147483647 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := add_int32_Neg1_ssa(-2147483647); got != -2147483648 { + fmt.Printf("add_int32 -2147483647+-1 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := add_Neg1_int32_ssa(-1); got != -2 { + fmt.Printf("add_int32 -1+-1 = %d, wanted -2\n", got) + failed = true + } + + if got := add_int32_Neg1_ssa(-1); got != -2 { + fmt.Printf("add_int32 -1+-1 = %d, wanted -2\n", got) + failed = true + } + + if got := add_Neg1_int32_ssa(0); got != -1 { + fmt.Printf("add_int32 -1+0 = %d, wanted -1\n", got) + failed = true + } + + if got := add_int32_Neg1_ssa(0); got != -1 { + fmt.Printf("add_int32 0+-1 = %d, wanted -1\n", got) + failed = true + } + + if got := add_Neg1_int32_ssa(1); got != 0 { + fmt.Printf("add_int32 -1+1 = %d, wanted 0\n", got) + failed = true + } + + if got := add_int32_Neg1_ssa(1); got != 0 { + fmt.Printf("add_int32 1+-1 = %d, wanted 0\n", got) + failed = true + } + + if got := add_Neg1_int32_ssa(2147483647); got != 2147483646 { + fmt.Printf("add_int32 -1+2147483647 = %d, wanted 2147483646\n", got) + failed = true + } + + if got := add_int32_Neg1_ssa(2147483647); got != 2147483646 { + fmt.Printf("add_int32 2147483647+-1 = %d, wanted 2147483646\n", got) + failed = true + } + + if got := add_0_int32_ssa(-2147483648); got != -2147483648 { + fmt.Printf("add_int32 0+-2147483648 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := add_int32_0_ssa(-2147483648); got != -2147483648 { + fmt.Printf("add_int32 -2147483648+0 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := add_0_int32_ssa(-2147483647); got != -2147483647 { + fmt.Printf("add_int32 0+-2147483647 = %d, wanted -2147483647\n", got) + failed = true + } + + if got := add_int32_0_ssa(-2147483647); got != -2147483647 { + fmt.Printf("add_int32 -2147483647+0 = %d, wanted -2147483647\n", got) + failed = true + } + + if got := add_0_int32_ssa(-1); got != -1 { + fmt.Printf("add_int32 0+-1 = %d, wanted -1\n", got) + failed = true + } + + if got := add_int32_0_ssa(-1); got != -1 { + fmt.Printf("add_int32 -1+0 = %d, wanted -1\n", got) + failed = true + } + + if got := add_0_int32_ssa(0); got != 0 { + fmt.Printf("add_int32 0+0 = %d, wanted 0\n", got) + failed = true + } + + if got := add_int32_0_ssa(0); got != 0 { + fmt.Printf("add_int32 0+0 = %d, wanted 0\n", got) + failed = true + } + + if got := add_0_int32_ssa(1); got != 1 { + fmt.Printf("add_int32 0+1 = %d, wanted 1\n", got) + failed = true + } + + if got := add_int32_0_ssa(1); got != 1 { + fmt.Printf("add_int32 1+0 = %d, wanted 1\n", got) + failed = true + } + + if got := add_0_int32_ssa(2147483647); got != 2147483647 { + fmt.Printf("add_int32 0+2147483647 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := add_int32_0_ssa(2147483647); got != 2147483647 { + fmt.Printf("add_int32 2147483647+0 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := add_1_int32_ssa(-2147483648); got != -2147483647 { + fmt.Printf("add_int32 1+-2147483648 = %d, wanted -2147483647\n", got) + failed = true + } + + if got := add_int32_1_ssa(-2147483648); got != -2147483647 { + fmt.Printf("add_int32 -2147483648+1 = %d, wanted -2147483647\n", got) + failed = true + } + + if got := add_1_int32_ssa(-2147483647); got != -2147483646 { + fmt.Printf("add_int32 1+-2147483647 = %d, wanted -2147483646\n", got) + failed = true + } + + if got := add_int32_1_ssa(-2147483647); got != -2147483646 { + fmt.Printf("add_int32 -2147483647+1 = %d, wanted -2147483646\n", got) + failed = true + } + + if got := add_1_int32_ssa(-1); got != 0 { + fmt.Printf("add_int32 1+-1 = %d, wanted 0\n", got) + failed = true + } + + if got := add_int32_1_ssa(-1); got != 0 { + fmt.Printf("add_int32 -1+1 = %d, wanted 0\n", got) + failed = true + } + + if got := add_1_int32_ssa(0); got != 1 { + fmt.Printf("add_int32 1+0 = %d, wanted 1\n", got) + failed = true + } + + if got := add_int32_1_ssa(0); got != 1 { + fmt.Printf("add_int32 0+1 = %d, wanted 1\n", got) + failed = true + } + + if got := add_1_int32_ssa(1); got != 2 { + fmt.Printf("add_int32 1+1 = %d, wanted 2\n", got) + failed = true + } + + if got := add_int32_1_ssa(1); got != 2 { + fmt.Printf("add_int32 1+1 = %d, wanted 2\n", got) + failed = true + } + + if got := add_1_int32_ssa(2147483647); got != -2147483648 { + fmt.Printf("add_int32 1+2147483647 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := add_int32_1_ssa(2147483647); got != -2147483648 { + fmt.Printf("add_int32 2147483647+1 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := add_2147483647_int32_ssa(-2147483648); got != -1 { + fmt.Printf("add_int32 2147483647+-2147483648 = %d, wanted -1\n", got) + failed = true + } + + if got := add_int32_2147483647_ssa(-2147483648); got != -1 { + fmt.Printf("add_int32 -2147483648+2147483647 = %d, wanted -1\n", got) + failed = true + } + + if got := add_2147483647_int32_ssa(-2147483647); got != 0 { + fmt.Printf("add_int32 2147483647+-2147483647 = %d, wanted 0\n", got) + failed = true + } + + if got := add_int32_2147483647_ssa(-2147483647); got != 0 { + fmt.Printf("add_int32 -2147483647+2147483647 = %d, wanted 0\n", got) + failed = true + } + + if got := add_2147483647_int32_ssa(-1); got != 2147483646 { + fmt.Printf("add_int32 2147483647+-1 = %d, wanted 2147483646\n", got) + failed = true + } + + if got := add_int32_2147483647_ssa(-1); got != 2147483646 { + fmt.Printf("add_int32 -1+2147483647 = %d, wanted 2147483646\n", got) + failed = true + } + + if got := add_2147483647_int32_ssa(0); got != 2147483647 { + fmt.Printf("add_int32 2147483647+0 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := add_int32_2147483647_ssa(0); got != 2147483647 { + fmt.Printf("add_int32 0+2147483647 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := add_2147483647_int32_ssa(1); got != -2147483648 { + fmt.Printf("add_int32 2147483647+1 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := add_int32_2147483647_ssa(1); got != -2147483648 { + fmt.Printf("add_int32 1+2147483647 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := add_2147483647_int32_ssa(2147483647); got != -2 { + fmt.Printf("add_int32 2147483647+2147483647 = %d, wanted -2\n", got) + failed = true + } + + if got := add_int32_2147483647_ssa(2147483647); got != -2 { + fmt.Printf("add_int32 2147483647+2147483647 = %d, wanted -2\n", got) + failed = true + } + + if got := sub_Neg2147483648_int32_ssa(-2147483648); got != 0 { + fmt.Printf("sub_int32 -2147483648--2147483648 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_int32_Neg2147483648_ssa(-2147483648); got != 0 { + fmt.Printf("sub_int32 -2147483648--2147483648 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_Neg2147483648_int32_ssa(-2147483647); got != -1 { + fmt.Printf("sub_int32 -2147483648--2147483647 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_int32_Neg2147483648_ssa(-2147483647); got != 1 { + fmt.Printf("sub_int32 -2147483647--2147483648 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_Neg2147483648_int32_ssa(-1); got != -2147483647 { + fmt.Printf("sub_int32 -2147483648--1 = %d, wanted -2147483647\n", got) + failed = true + } + + if got := sub_int32_Neg2147483648_ssa(-1); got != 2147483647 { + fmt.Printf("sub_int32 -1--2147483648 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := sub_Neg2147483648_int32_ssa(0); got != -2147483648 { + fmt.Printf("sub_int32 -2147483648-0 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := sub_int32_Neg2147483648_ssa(0); got != -2147483648 { + fmt.Printf("sub_int32 0--2147483648 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := sub_Neg2147483648_int32_ssa(1); got != 2147483647 { + fmt.Printf("sub_int32 -2147483648-1 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := sub_int32_Neg2147483648_ssa(1); got != -2147483647 { + fmt.Printf("sub_int32 1--2147483648 = %d, wanted -2147483647\n", got) + failed = true + } + + if got := sub_Neg2147483648_int32_ssa(2147483647); got != 1 { + fmt.Printf("sub_int32 -2147483648-2147483647 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_int32_Neg2147483648_ssa(2147483647); got != -1 { + fmt.Printf("sub_int32 2147483647--2147483648 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_Neg2147483647_int32_ssa(-2147483648); got != 1 { + fmt.Printf("sub_int32 -2147483647--2147483648 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_int32_Neg2147483647_ssa(-2147483648); got != -1 { + fmt.Printf("sub_int32 -2147483648--2147483647 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_Neg2147483647_int32_ssa(-2147483647); got != 0 { + fmt.Printf("sub_int32 -2147483647--2147483647 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_int32_Neg2147483647_ssa(-2147483647); got != 0 { + fmt.Printf("sub_int32 -2147483647--2147483647 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_Neg2147483647_int32_ssa(-1); got != -2147483646 { + fmt.Printf("sub_int32 -2147483647--1 = %d, wanted -2147483646\n", got) + failed = true + } + + if got := sub_int32_Neg2147483647_ssa(-1); got != 2147483646 { + fmt.Printf("sub_int32 -1--2147483647 = %d, wanted 2147483646\n", got) + failed = true + } + + if got := sub_Neg2147483647_int32_ssa(0); got != -2147483647 { + fmt.Printf("sub_int32 -2147483647-0 = %d, wanted -2147483647\n", got) + failed = true + } + + if got := sub_int32_Neg2147483647_ssa(0); got != 2147483647 { + fmt.Printf("sub_int32 0--2147483647 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := sub_Neg2147483647_int32_ssa(1); got != -2147483648 { + fmt.Printf("sub_int32 -2147483647-1 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := sub_int32_Neg2147483647_ssa(1); got != -2147483648 { + fmt.Printf("sub_int32 1--2147483647 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := sub_Neg2147483647_int32_ssa(2147483647); got != 2 { + fmt.Printf("sub_int32 -2147483647-2147483647 = %d, wanted 2\n", got) + failed = true + } + + if got := sub_int32_Neg2147483647_ssa(2147483647); got != -2 { + fmt.Printf("sub_int32 2147483647--2147483647 = %d, wanted -2\n", got) + failed = true + } + + if got := sub_Neg1_int32_ssa(-2147483648); got != 2147483647 { + fmt.Printf("sub_int32 -1--2147483648 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := sub_int32_Neg1_ssa(-2147483648); got != -2147483647 { + fmt.Printf("sub_int32 -2147483648--1 = %d, wanted -2147483647\n", got) + failed = true + } + + if got := sub_Neg1_int32_ssa(-2147483647); got != 2147483646 { + fmt.Printf("sub_int32 -1--2147483647 = %d, wanted 2147483646\n", got) + failed = true + } + + if got := sub_int32_Neg1_ssa(-2147483647); got != -2147483646 { + fmt.Printf("sub_int32 -2147483647--1 = %d, wanted -2147483646\n", got) + failed = true + } + + if got := sub_Neg1_int32_ssa(-1); got != 0 { + fmt.Printf("sub_int32 -1--1 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_int32_Neg1_ssa(-1); got != 0 { + fmt.Printf("sub_int32 -1--1 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_Neg1_int32_ssa(0); got != -1 { + fmt.Printf("sub_int32 -1-0 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_int32_Neg1_ssa(0); got != 1 { + fmt.Printf("sub_int32 0--1 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_Neg1_int32_ssa(1); got != -2 { + fmt.Printf("sub_int32 -1-1 = %d, wanted -2\n", got) + failed = true + } + + if got := sub_int32_Neg1_ssa(1); got != 2 { + fmt.Printf("sub_int32 1--1 = %d, wanted 2\n", got) + failed = true + } + + if got := sub_Neg1_int32_ssa(2147483647); got != -2147483648 { + fmt.Printf("sub_int32 -1-2147483647 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := sub_int32_Neg1_ssa(2147483647); got != -2147483648 { + fmt.Printf("sub_int32 2147483647--1 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := sub_0_int32_ssa(-2147483648); got != -2147483648 { + fmt.Printf("sub_int32 0--2147483648 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := sub_int32_0_ssa(-2147483648); got != -2147483648 { + fmt.Printf("sub_int32 -2147483648-0 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := sub_0_int32_ssa(-2147483647); got != 2147483647 { + fmt.Printf("sub_int32 0--2147483647 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := sub_int32_0_ssa(-2147483647); got != -2147483647 { + fmt.Printf("sub_int32 -2147483647-0 = %d, wanted -2147483647\n", got) + failed = true + } + + if got := sub_0_int32_ssa(-1); got != 1 { + fmt.Printf("sub_int32 0--1 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_int32_0_ssa(-1); got != -1 { + fmt.Printf("sub_int32 -1-0 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_0_int32_ssa(0); got != 0 { + fmt.Printf("sub_int32 0-0 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_int32_0_ssa(0); got != 0 { + fmt.Printf("sub_int32 0-0 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_0_int32_ssa(1); got != -1 { + fmt.Printf("sub_int32 0-1 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_int32_0_ssa(1); got != 1 { + fmt.Printf("sub_int32 1-0 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_0_int32_ssa(2147483647); got != -2147483647 { + fmt.Printf("sub_int32 0-2147483647 = %d, wanted -2147483647\n", got) + failed = true + } + + if got := sub_int32_0_ssa(2147483647); got != 2147483647 { + fmt.Printf("sub_int32 2147483647-0 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := sub_1_int32_ssa(-2147483648); got != -2147483647 { + fmt.Printf("sub_int32 1--2147483648 = %d, wanted -2147483647\n", got) + failed = true + } + + if got := sub_int32_1_ssa(-2147483648); got != 2147483647 { + fmt.Printf("sub_int32 -2147483648-1 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := sub_1_int32_ssa(-2147483647); got != -2147483648 { + fmt.Printf("sub_int32 1--2147483647 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := sub_int32_1_ssa(-2147483647); got != -2147483648 { + fmt.Printf("sub_int32 -2147483647-1 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := sub_1_int32_ssa(-1); got != 2 { + fmt.Printf("sub_int32 1--1 = %d, wanted 2\n", got) + failed = true + } + + if got := sub_int32_1_ssa(-1); got != -2 { + fmt.Printf("sub_int32 -1-1 = %d, wanted -2\n", got) + failed = true + } + + if got := sub_1_int32_ssa(0); got != 1 { + fmt.Printf("sub_int32 1-0 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_int32_1_ssa(0); got != -1 { + fmt.Printf("sub_int32 0-1 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_1_int32_ssa(1); got != 0 { + fmt.Printf("sub_int32 1-1 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_int32_1_ssa(1); got != 0 { + fmt.Printf("sub_int32 1-1 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_1_int32_ssa(2147483647); got != -2147483646 { + fmt.Printf("sub_int32 1-2147483647 = %d, wanted -2147483646\n", got) + failed = true + } + + if got := sub_int32_1_ssa(2147483647); got != 2147483646 { + fmt.Printf("sub_int32 2147483647-1 = %d, wanted 2147483646\n", got) + failed = true + } + + if got := sub_2147483647_int32_ssa(-2147483648); got != -1 { + fmt.Printf("sub_int32 2147483647--2147483648 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_int32_2147483647_ssa(-2147483648); got != 1 { + fmt.Printf("sub_int32 -2147483648-2147483647 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_2147483647_int32_ssa(-2147483647); got != -2 { + fmt.Printf("sub_int32 2147483647--2147483647 = %d, wanted -2\n", got) + failed = true + } + + if got := sub_int32_2147483647_ssa(-2147483647); got != 2 { + fmt.Printf("sub_int32 -2147483647-2147483647 = %d, wanted 2\n", got) + failed = true + } + + if got := sub_2147483647_int32_ssa(-1); got != -2147483648 { + fmt.Printf("sub_int32 2147483647--1 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := sub_int32_2147483647_ssa(-1); got != -2147483648 { + fmt.Printf("sub_int32 -1-2147483647 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := sub_2147483647_int32_ssa(0); got != 2147483647 { + fmt.Printf("sub_int32 2147483647-0 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := sub_int32_2147483647_ssa(0); got != -2147483647 { + fmt.Printf("sub_int32 0-2147483647 = %d, wanted -2147483647\n", got) + failed = true + } + + if got := sub_2147483647_int32_ssa(1); got != 2147483646 { + fmt.Printf("sub_int32 2147483647-1 = %d, wanted 2147483646\n", got) + failed = true + } + + if got := sub_int32_2147483647_ssa(1); got != -2147483646 { + fmt.Printf("sub_int32 1-2147483647 = %d, wanted -2147483646\n", got) + failed = true + } + + if got := sub_2147483647_int32_ssa(2147483647); got != 0 { + fmt.Printf("sub_int32 2147483647-2147483647 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_int32_2147483647_ssa(2147483647); got != 0 { + fmt.Printf("sub_int32 2147483647-2147483647 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg2147483648_int32_ssa(-2147483648); got != 1 { + fmt.Printf("div_int32 -2147483648/-2147483648 = %d, wanted 1\n", got) + failed = true + } + + if got := div_int32_Neg2147483648_ssa(-2147483648); got != 1 { + fmt.Printf("div_int32 -2147483648/-2147483648 = %d, wanted 1\n", got) + failed = true + } + + if got := div_Neg2147483648_int32_ssa(-2147483647); got != 1 { + fmt.Printf("div_int32 -2147483648/-2147483647 = %d, wanted 1\n", got) + failed = true + } + + if got := div_int32_Neg2147483648_ssa(-2147483647); got != 0 { + fmt.Printf("div_int32 -2147483647/-2147483648 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg2147483648_int32_ssa(-1); got != -2147483648 { + fmt.Printf("div_int32 -2147483648/-1 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := div_int32_Neg2147483648_ssa(-1); got != 0 { + fmt.Printf("div_int32 -1/-2147483648 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int32_Neg2147483648_ssa(0); got != 0 { + fmt.Printf("div_int32 0/-2147483648 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg2147483648_int32_ssa(1); got != -2147483648 { + fmt.Printf("div_int32 -2147483648/1 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := div_int32_Neg2147483648_ssa(1); got != 0 { + fmt.Printf("div_int32 1/-2147483648 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg2147483648_int32_ssa(2147483647); got != -1 { + fmt.Printf("div_int32 -2147483648/2147483647 = %d, wanted -1\n", got) + failed = true + } + + if got := div_int32_Neg2147483648_ssa(2147483647); got != 0 { + fmt.Printf("div_int32 2147483647/-2147483648 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg2147483647_int32_ssa(-2147483648); got != 0 { + fmt.Printf("div_int32 -2147483647/-2147483648 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int32_Neg2147483647_ssa(-2147483648); got != 1 { + fmt.Printf("div_int32 -2147483648/-2147483647 = %d, wanted 1\n", got) + failed = true + } + + if got := div_Neg2147483647_int32_ssa(-2147483647); got != 1 { + fmt.Printf("div_int32 -2147483647/-2147483647 = %d, wanted 1\n", got) + failed = true + } + + if got := div_int32_Neg2147483647_ssa(-2147483647); got != 1 { + fmt.Printf("div_int32 -2147483647/-2147483647 = %d, wanted 1\n", got) + failed = true + } + + if got := div_Neg2147483647_int32_ssa(-1); got != 2147483647 { + fmt.Printf("div_int32 -2147483647/-1 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := div_int32_Neg2147483647_ssa(-1); got != 0 { + fmt.Printf("div_int32 -1/-2147483647 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int32_Neg2147483647_ssa(0); got != 0 { + fmt.Printf("div_int32 0/-2147483647 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg2147483647_int32_ssa(1); got != -2147483647 { + fmt.Printf("div_int32 -2147483647/1 = %d, wanted -2147483647\n", got) + failed = true + } + + if got := div_int32_Neg2147483647_ssa(1); got != 0 { + fmt.Printf("div_int32 1/-2147483647 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg2147483647_int32_ssa(2147483647); got != -1 { + fmt.Printf("div_int32 -2147483647/2147483647 = %d, wanted -1\n", got) + failed = true + } + + if got := div_int32_Neg2147483647_ssa(2147483647); got != -1 { + fmt.Printf("div_int32 2147483647/-2147483647 = %d, wanted -1\n", got) + failed = true + } + + if got := div_Neg1_int32_ssa(-2147483648); got != 0 { + fmt.Printf("div_int32 -1/-2147483648 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int32_Neg1_ssa(-2147483648); got != -2147483648 { + fmt.Printf("div_int32 -2147483648/-1 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := div_Neg1_int32_ssa(-2147483647); got != 0 { + fmt.Printf("div_int32 -1/-2147483647 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int32_Neg1_ssa(-2147483647); got != 2147483647 { + fmt.Printf("div_int32 -2147483647/-1 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := div_Neg1_int32_ssa(-1); got != 1 { + fmt.Printf("div_int32 -1/-1 = %d, wanted 1\n", got) + failed = true + } + + if got := div_int32_Neg1_ssa(-1); got != 1 { + fmt.Printf("div_int32 -1/-1 = %d, wanted 1\n", got) + failed = true + } + + if got := div_int32_Neg1_ssa(0); got != 0 { + fmt.Printf("div_int32 0/-1 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg1_int32_ssa(1); got != -1 { + fmt.Printf("div_int32 -1/1 = %d, wanted -1\n", got) + failed = true + } + + if got := div_int32_Neg1_ssa(1); got != -1 { + fmt.Printf("div_int32 1/-1 = %d, wanted -1\n", got) + failed = true + } + + if got := div_Neg1_int32_ssa(2147483647); got != 0 { + fmt.Printf("div_int32 -1/2147483647 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int32_Neg1_ssa(2147483647); got != -2147483647 { + fmt.Printf("div_int32 2147483647/-1 = %d, wanted -2147483647\n", got) + failed = true + } + + if got := div_0_int32_ssa(-2147483648); got != 0 { + fmt.Printf("div_int32 0/-2147483648 = %d, wanted 0\n", got) + failed = true + } + + if got := div_0_int32_ssa(-2147483647); got != 0 { + fmt.Printf("div_int32 0/-2147483647 = %d, wanted 0\n", got) + failed = true + } + + if got := div_0_int32_ssa(-1); got != 0 { + fmt.Printf("div_int32 0/-1 = %d, wanted 0\n", got) + failed = true + } + + if got := div_0_int32_ssa(1); got != 0 { + fmt.Printf("div_int32 0/1 = %d, wanted 0\n", got) + failed = true + } + + if got := div_0_int32_ssa(2147483647); got != 0 { + fmt.Printf("div_int32 0/2147483647 = %d, wanted 0\n", got) + failed = true + } + + if got := div_1_int32_ssa(-2147483648); got != 0 { + fmt.Printf("div_int32 1/-2147483648 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int32_1_ssa(-2147483648); got != -2147483648 { + fmt.Printf("div_int32 -2147483648/1 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := div_1_int32_ssa(-2147483647); got != 0 { + fmt.Printf("div_int32 1/-2147483647 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int32_1_ssa(-2147483647); got != -2147483647 { + fmt.Printf("div_int32 -2147483647/1 = %d, wanted -2147483647\n", got) + failed = true + } + + if got := div_1_int32_ssa(-1); got != -1 { + fmt.Printf("div_int32 1/-1 = %d, wanted -1\n", got) + failed = true + } + + if got := div_int32_1_ssa(-1); got != -1 { + fmt.Printf("div_int32 -1/1 = %d, wanted -1\n", got) + failed = true + } + + if got := div_int32_1_ssa(0); got != 0 { + fmt.Printf("div_int32 0/1 = %d, wanted 0\n", got) + failed = true + } + + if got := div_1_int32_ssa(1); got != 1 { + fmt.Printf("div_int32 1/1 = %d, wanted 1\n", got) + failed = true + } + + if got := div_int32_1_ssa(1); got != 1 { + fmt.Printf("div_int32 1/1 = %d, wanted 1\n", got) + failed = true + } + + if got := div_1_int32_ssa(2147483647); got != 0 { + fmt.Printf("div_int32 1/2147483647 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int32_1_ssa(2147483647); got != 2147483647 { + fmt.Printf("div_int32 2147483647/1 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := div_2147483647_int32_ssa(-2147483648); got != 0 { + fmt.Printf("div_int32 2147483647/-2147483648 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int32_2147483647_ssa(-2147483648); got != -1 { + fmt.Printf("div_int32 -2147483648/2147483647 = %d, wanted -1\n", got) + failed = true + } + + if got := div_2147483647_int32_ssa(-2147483647); got != -1 { + fmt.Printf("div_int32 2147483647/-2147483647 = %d, wanted -1\n", got) + failed = true + } + + if got := div_int32_2147483647_ssa(-2147483647); got != -1 { + fmt.Printf("div_int32 -2147483647/2147483647 = %d, wanted -1\n", got) + failed = true + } + + if got := div_2147483647_int32_ssa(-1); got != -2147483647 { + fmt.Printf("div_int32 2147483647/-1 = %d, wanted -2147483647\n", got) + failed = true + } + + if got := div_int32_2147483647_ssa(-1); got != 0 { + fmt.Printf("div_int32 -1/2147483647 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int32_2147483647_ssa(0); got != 0 { + fmt.Printf("div_int32 0/2147483647 = %d, wanted 0\n", got) + failed = true + } + + if got := div_2147483647_int32_ssa(1); got != 2147483647 { + fmt.Printf("div_int32 2147483647/1 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := div_int32_2147483647_ssa(1); got != 0 { + fmt.Printf("div_int32 1/2147483647 = %d, wanted 0\n", got) + failed = true + } + + if got := div_2147483647_int32_ssa(2147483647); got != 1 { + fmt.Printf("div_int32 2147483647/2147483647 = %d, wanted 1\n", got) + failed = true + } + + if got := div_int32_2147483647_ssa(2147483647); got != 1 { + fmt.Printf("div_int32 2147483647/2147483647 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_Neg2147483648_int32_ssa(-2147483648); got != 0 { + fmt.Printf("mul_int32 -2147483648*-2147483648 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int32_Neg2147483648_ssa(-2147483648); got != 0 { + fmt.Printf("mul_int32 -2147483648*-2147483648 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_Neg2147483648_int32_ssa(-2147483647); got != -2147483648 { + fmt.Printf("mul_int32 -2147483648*-2147483647 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := mul_int32_Neg2147483648_ssa(-2147483647); got != -2147483648 { + fmt.Printf("mul_int32 -2147483647*-2147483648 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := mul_Neg2147483648_int32_ssa(-1); got != -2147483648 { + fmt.Printf("mul_int32 -2147483648*-1 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := mul_int32_Neg2147483648_ssa(-1); got != -2147483648 { + fmt.Printf("mul_int32 -1*-2147483648 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := mul_Neg2147483648_int32_ssa(0); got != 0 { + fmt.Printf("mul_int32 -2147483648*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int32_Neg2147483648_ssa(0); got != 0 { + fmt.Printf("mul_int32 0*-2147483648 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_Neg2147483648_int32_ssa(1); got != -2147483648 { + fmt.Printf("mul_int32 -2147483648*1 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := mul_int32_Neg2147483648_ssa(1); got != -2147483648 { + fmt.Printf("mul_int32 1*-2147483648 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := mul_Neg2147483648_int32_ssa(2147483647); got != -2147483648 { + fmt.Printf("mul_int32 -2147483648*2147483647 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := mul_int32_Neg2147483648_ssa(2147483647); got != -2147483648 { + fmt.Printf("mul_int32 2147483647*-2147483648 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := mul_Neg2147483647_int32_ssa(-2147483648); got != -2147483648 { + fmt.Printf("mul_int32 -2147483647*-2147483648 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := mul_int32_Neg2147483647_ssa(-2147483648); got != -2147483648 { + fmt.Printf("mul_int32 -2147483648*-2147483647 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := mul_Neg2147483647_int32_ssa(-2147483647); got != 1 { + fmt.Printf("mul_int32 -2147483647*-2147483647 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_int32_Neg2147483647_ssa(-2147483647); got != 1 { + fmt.Printf("mul_int32 -2147483647*-2147483647 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_Neg2147483647_int32_ssa(-1); got != 2147483647 { + fmt.Printf("mul_int32 -2147483647*-1 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := mul_int32_Neg2147483647_ssa(-1); got != 2147483647 { + fmt.Printf("mul_int32 -1*-2147483647 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := mul_Neg2147483647_int32_ssa(0); got != 0 { + fmt.Printf("mul_int32 -2147483647*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int32_Neg2147483647_ssa(0); got != 0 { + fmt.Printf("mul_int32 0*-2147483647 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_Neg2147483647_int32_ssa(1); got != -2147483647 { + fmt.Printf("mul_int32 -2147483647*1 = %d, wanted -2147483647\n", got) + failed = true + } + + if got := mul_int32_Neg2147483647_ssa(1); got != -2147483647 { + fmt.Printf("mul_int32 1*-2147483647 = %d, wanted -2147483647\n", got) + failed = true + } + + if got := mul_Neg2147483647_int32_ssa(2147483647); got != -1 { + fmt.Printf("mul_int32 -2147483647*2147483647 = %d, wanted -1\n", got) + failed = true + } + + if got := mul_int32_Neg2147483647_ssa(2147483647); got != -1 { + fmt.Printf("mul_int32 2147483647*-2147483647 = %d, wanted -1\n", got) + failed = true + } + + if got := mul_Neg1_int32_ssa(-2147483648); got != -2147483648 { + fmt.Printf("mul_int32 -1*-2147483648 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := mul_int32_Neg1_ssa(-2147483648); got != -2147483648 { + fmt.Printf("mul_int32 -2147483648*-1 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := mul_Neg1_int32_ssa(-2147483647); got != 2147483647 { + fmt.Printf("mul_int32 -1*-2147483647 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := mul_int32_Neg1_ssa(-2147483647); got != 2147483647 { + fmt.Printf("mul_int32 -2147483647*-1 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := mul_Neg1_int32_ssa(-1); got != 1 { + fmt.Printf("mul_int32 -1*-1 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_int32_Neg1_ssa(-1); got != 1 { + fmt.Printf("mul_int32 -1*-1 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_Neg1_int32_ssa(0); got != 0 { + fmt.Printf("mul_int32 -1*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int32_Neg1_ssa(0); got != 0 { + fmt.Printf("mul_int32 0*-1 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_Neg1_int32_ssa(1); got != -1 { + fmt.Printf("mul_int32 -1*1 = %d, wanted -1\n", got) + failed = true + } + + if got := mul_int32_Neg1_ssa(1); got != -1 { + fmt.Printf("mul_int32 1*-1 = %d, wanted -1\n", got) + failed = true + } + + if got := mul_Neg1_int32_ssa(2147483647); got != -2147483647 { + fmt.Printf("mul_int32 -1*2147483647 = %d, wanted -2147483647\n", got) + failed = true + } + + if got := mul_int32_Neg1_ssa(2147483647); got != -2147483647 { + fmt.Printf("mul_int32 2147483647*-1 = %d, wanted -2147483647\n", got) + failed = true + } + + if got := mul_0_int32_ssa(-2147483648); got != 0 { + fmt.Printf("mul_int32 0*-2147483648 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int32_0_ssa(-2147483648); got != 0 { + fmt.Printf("mul_int32 -2147483648*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_0_int32_ssa(-2147483647); got != 0 { + fmt.Printf("mul_int32 0*-2147483647 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int32_0_ssa(-2147483647); got != 0 { + fmt.Printf("mul_int32 -2147483647*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_0_int32_ssa(-1); got != 0 { + fmt.Printf("mul_int32 0*-1 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int32_0_ssa(-1); got != 0 { + fmt.Printf("mul_int32 -1*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_0_int32_ssa(0); got != 0 { + fmt.Printf("mul_int32 0*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int32_0_ssa(0); got != 0 { + fmt.Printf("mul_int32 0*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_0_int32_ssa(1); got != 0 { + fmt.Printf("mul_int32 0*1 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int32_0_ssa(1); got != 0 { + fmt.Printf("mul_int32 1*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_0_int32_ssa(2147483647); got != 0 { + fmt.Printf("mul_int32 0*2147483647 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int32_0_ssa(2147483647); got != 0 { + fmt.Printf("mul_int32 2147483647*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_1_int32_ssa(-2147483648); got != -2147483648 { + fmt.Printf("mul_int32 1*-2147483648 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := mul_int32_1_ssa(-2147483648); got != -2147483648 { + fmt.Printf("mul_int32 -2147483648*1 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := mul_1_int32_ssa(-2147483647); got != -2147483647 { + fmt.Printf("mul_int32 1*-2147483647 = %d, wanted -2147483647\n", got) + failed = true + } + + if got := mul_int32_1_ssa(-2147483647); got != -2147483647 { + fmt.Printf("mul_int32 -2147483647*1 = %d, wanted -2147483647\n", got) + failed = true + } + + if got := mul_1_int32_ssa(-1); got != -1 { + fmt.Printf("mul_int32 1*-1 = %d, wanted -1\n", got) + failed = true + } + + if got := mul_int32_1_ssa(-1); got != -1 { + fmt.Printf("mul_int32 -1*1 = %d, wanted -1\n", got) + failed = true + } + + if got := mul_1_int32_ssa(0); got != 0 { + fmt.Printf("mul_int32 1*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int32_1_ssa(0); got != 0 { + fmt.Printf("mul_int32 0*1 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_1_int32_ssa(1); got != 1 { + fmt.Printf("mul_int32 1*1 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_int32_1_ssa(1); got != 1 { + fmt.Printf("mul_int32 1*1 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_1_int32_ssa(2147483647); got != 2147483647 { + fmt.Printf("mul_int32 1*2147483647 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := mul_int32_1_ssa(2147483647); got != 2147483647 { + fmt.Printf("mul_int32 2147483647*1 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := mul_2147483647_int32_ssa(-2147483648); got != -2147483648 { + fmt.Printf("mul_int32 2147483647*-2147483648 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := mul_int32_2147483647_ssa(-2147483648); got != -2147483648 { + fmt.Printf("mul_int32 -2147483648*2147483647 = %d, wanted -2147483648\n", got) + failed = true + } + + if got := mul_2147483647_int32_ssa(-2147483647); got != -1 { + fmt.Printf("mul_int32 2147483647*-2147483647 = %d, wanted -1\n", got) + failed = true + } + + if got := mul_int32_2147483647_ssa(-2147483647); got != -1 { + fmt.Printf("mul_int32 -2147483647*2147483647 = %d, wanted -1\n", got) + failed = true + } + + if got := mul_2147483647_int32_ssa(-1); got != -2147483647 { + fmt.Printf("mul_int32 2147483647*-1 = %d, wanted -2147483647\n", got) + failed = true + } + + if got := mul_int32_2147483647_ssa(-1); got != -2147483647 { + fmt.Printf("mul_int32 -1*2147483647 = %d, wanted -2147483647\n", got) + failed = true + } + + if got := mul_2147483647_int32_ssa(0); got != 0 { + fmt.Printf("mul_int32 2147483647*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int32_2147483647_ssa(0); got != 0 { + fmt.Printf("mul_int32 0*2147483647 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_2147483647_int32_ssa(1); got != 2147483647 { + fmt.Printf("mul_int32 2147483647*1 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := mul_int32_2147483647_ssa(1); got != 2147483647 { + fmt.Printf("mul_int32 1*2147483647 = %d, wanted 2147483647\n", got) + failed = true + } + + if got := mul_2147483647_int32_ssa(2147483647); got != 1 { + fmt.Printf("mul_int32 2147483647*2147483647 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_int32_2147483647_ssa(2147483647); got != 1 { + fmt.Printf("mul_int32 2147483647*2147483647 = %d, wanted 1\n", got) + failed = true + } + + if got := add_0_uint16_ssa(0); got != 0 { + fmt.Printf("add_uint16 0+0 = %d, wanted 0\n", got) + failed = true + } + + if got := add_uint16_0_ssa(0); got != 0 { + fmt.Printf("add_uint16 0+0 = %d, wanted 0\n", got) + failed = true + } + + if got := add_0_uint16_ssa(1); got != 1 { + fmt.Printf("add_uint16 0+1 = %d, wanted 1\n", got) + failed = true + } + + if got := add_uint16_0_ssa(1); got != 1 { + fmt.Printf("add_uint16 1+0 = %d, wanted 1\n", got) + failed = true + } + + if got := add_0_uint16_ssa(65535); got != 65535 { + fmt.Printf("add_uint16 0+65535 = %d, wanted 65535\n", got) + failed = true + } + + if got := add_uint16_0_ssa(65535); got != 65535 { + fmt.Printf("add_uint16 65535+0 = %d, wanted 65535\n", got) + failed = true + } + + if got := add_1_uint16_ssa(0); got != 1 { + fmt.Printf("add_uint16 1+0 = %d, wanted 1\n", got) + failed = true + } + + if got := add_uint16_1_ssa(0); got != 1 { + fmt.Printf("add_uint16 0+1 = %d, wanted 1\n", got) + failed = true + } + + if got := add_1_uint16_ssa(1); got != 2 { + fmt.Printf("add_uint16 1+1 = %d, wanted 2\n", got) + failed = true + } + + if got := add_uint16_1_ssa(1); got != 2 { + fmt.Printf("add_uint16 1+1 = %d, wanted 2\n", got) + failed = true + } + + if got := add_1_uint16_ssa(65535); got != 0 { + fmt.Printf("add_uint16 1+65535 = %d, wanted 0\n", got) + failed = true + } + + if got := add_uint16_1_ssa(65535); got != 0 { + fmt.Printf("add_uint16 65535+1 = %d, wanted 0\n", got) + failed = true + } + + if got := add_65535_uint16_ssa(0); got != 65535 { + fmt.Printf("add_uint16 65535+0 = %d, wanted 65535\n", got) + failed = true + } + + if got := add_uint16_65535_ssa(0); got != 65535 { + fmt.Printf("add_uint16 0+65535 = %d, wanted 65535\n", got) + failed = true + } + + if got := add_65535_uint16_ssa(1); got != 0 { + fmt.Printf("add_uint16 65535+1 = %d, wanted 0\n", got) + failed = true + } + + if got := add_uint16_65535_ssa(1); got != 0 { + fmt.Printf("add_uint16 1+65535 = %d, wanted 0\n", got) + failed = true + } + + if got := add_65535_uint16_ssa(65535); got != 65534 { + fmt.Printf("add_uint16 65535+65535 = %d, wanted 65534\n", got) + failed = true + } + + if got := add_uint16_65535_ssa(65535); got != 65534 { + fmt.Printf("add_uint16 65535+65535 = %d, wanted 65534\n", got) + failed = true + } + + if got := sub_0_uint16_ssa(0); got != 0 { + fmt.Printf("sub_uint16 0-0 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_uint16_0_ssa(0); got != 0 { + fmt.Printf("sub_uint16 0-0 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_0_uint16_ssa(1); got != 65535 { + fmt.Printf("sub_uint16 0-1 = %d, wanted 65535\n", got) + failed = true + } + + if got := sub_uint16_0_ssa(1); got != 1 { + fmt.Printf("sub_uint16 1-0 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_0_uint16_ssa(65535); got != 1 { + fmt.Printf("sub_uint16 0-65535 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_uint16_0_ssa(65535); got != 65535 { + fmt.Printf("sub_uint16 65535-0 = %d, wanted 65535\n", got) + failed = true + } + + if got := sub_1_uint16_ssa(0); got != 1 { + fmt.Printf("sub_uint16 1-0 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_uint16_1_ssa(0); got != 65535 { + fmt.Printf("sub_uint16 0-1 = %d, wanted 65535\n", got) + failed = true + } + + if got := sub_1_uint16_ssa(1); got != 0 { + fmt.Printf("sub_uint16 1-1 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_uint16_1_ssa(1); got != 0 { + fmt.Printf("sub_uint16 1-1 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_1_uint16_ssa(65535); got != 2 { + fmt.Printf("sub_uint16 1-65535 = %d, wanted 2\n", got) + failed = true + } + + if got := sub_uint16_1_ssa(65535); got != 65534 { + fmt.Printf("sub_uint16 65535-1 = %d, wanted 65534\n", got) + failed = true + } + + if got := sub_65535_uint16_ssa(0); got != 65535 { + fmt.Printf("sub_uint16 65535-0 = %d, wanted 65535\n", got) + failed = true + } + + if got := sub_uint16_65535_ssa(0); got != 1 { + fmt.Printf("sub_uint16 0-65535 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_65535_uint16_ssa(1); got != 65534 { + fmt.Printf("sub_uint16 65535-1 = %d, wanted 65534\n", got) + failed = true + } + + if got := sub_uint16_65535_ssa(1); got != 2 { + fmt.Printf("sub_uint16 1-65535 = %d, wanted 2\n", got) + failed = true + } + + if got := sub_65535_uint16_ssa(65535); got != 0 { + fmt.Printf("sub_uint16 65535-65535 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_uint16_65535_ssa(65535); got != 0 { + fmt.Printf("sub_uint16 65535-65535 = %d, wanted 0\n", got) + failed = true + } + + if got := div_0_uint16_ssa(1); got != 0 { + fmt.Printf("div_uint16 0/1 = %d, wanted 0\n", got) + failed = true + } + + if got := div_0_uint16_ssa(65535); got != 0 { + fmt.Printf("div_uint16 0/65535 = %d, wanted 0\n", got) + failed = true + } + + if got := div_uint16_1_ssa(0); got != 0 { + fmt.Printf("div_uint16 0/1 = %d, wanted 0\n", got) + failed = true + } + + if got := div_1_uint16_ssa(1); got != 1 { + fmt.Printf("div_uint16 1/1 = %d, wanted 1\n", got) + failed = true + } + + if got := div_uint16_1_ssa(1); got != 1 { + fmt.Printf("div_uint16 1/1 = %d, wanted 1\n", got) + failed = true + } + + if got := div_1_uint16_ssa(65535); got != 0 { + fmt.Printf("div_uint16 1/65535 = %d, wanted 0\n", got) + failed = true + } + + if got := div_uint16_1_ssa(65535); got != 65535 { + fmt.Printf("div_uint16 65535/1 = %d, wanted 65535\n", got) + failed = true + } + + if got := div_uint16_65535_ssa(0); got != 0 { + fmt.Printf("div_uint16 0/65535 = %d, wanted 0\n", got) + failed = true + } + + if got := div_65535_uint16_ssa(1); got != 65535 { + fmt.Printf("div_uint16 65535/1 = %d, wanted 65535\n", got) + failed = true + } + + if got := div_uint16_65535_ssa(1); got != 0 { + fmt.Printf("div_uint16 1/65535 = %d, wanted 0\n", got) + failed = true + } + + if got := div_65535_uint16_ssa(65535); got != 1 { + fmt.Printf("div_uint16 65535/65535 = %d, wanted 1\n", got) + failed = true + } + + if got := div_uint16_65535_ssa(65535); got != 1 { + fmt.Printf("div_uint16 65535/65535 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_0_uint16_ssa(0); got != 0 { + fmt.Printf("mul_uint16 0*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_uint16_0_ssa(0); got != 0 { + fmt.Printf("mul_uint16 0*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_0_uint16_ssa(1); got != 0 { + fmt.Printf("mul_uint16 0*1 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_uint16_0_ssa(1); got != 0 { + fmt.Printf("mul_uint16 1*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_0_uint16_ssa(65535); got != 0 { + fmt.Printf("mul_uint16 0*65535 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_uint16_0_ssa(65535); got != 0 { + fmt.Printf("mul_uint16 65535*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_1_uint16_ssa(0); got != 0 { + fmt.Printf("mul_uint16 1*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_uint16_1_ssa(0); got != 0 { + fmt.Printf("mul_uint16 0*1 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_1_uint16_ssa(1); got != 1 { + fmt.Printf("mul_uint16 1*1 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_uint16_1_ssa(1); got != 1 { + fmt.Printf("mul_uint16 1*1 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_1_uint16_ssa(65535); got != 65535 { + fmt.Printf("mul_uint16 1*65535 = %d, wanted 65535\n", got) + failed = true + } + + if got := mul_uint16_1_ssa(65535); got != 65535 { + fmt.Printf("mul_uint16 65535*1 = %d, wanted 65535\n", got) + failed = true + } + + if got := mul_65535_uint16_ssa(0); got != 0 { + fmt.Printf("mul_uint16 65535*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_uint16_65535_ssa(0); got != 0 { + fmt.Printf("mul_uint16 0*65535 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_65535_uint16_ssa(1); got != 65535 { + fmt.Printf("mul_uint16 65535*1 = %d, wanted 65535\n", got) + failed = true + } + + if got := mul_uint16_65535_ssa(1); got != 65535 { + fmt.Printf("mul_uint16 1*65535 = %d, wanted 65535\n", got) + failed = true + } + + if got := mul_65535_uint16_ssa(65535); got != 1 { + fmt.Printf("mul_uint16 65535*65535 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_uint16_65535_ssa(65535); got != 1 { + fmt.Printf("mul_uint16 65535*65535 = %d, wanted 1\n", got) + failed = true + } + + if got := lsh_0_uint16_ssa(0); got != 0 { + fmt.Printf("lsh_uint16 0<<0 = %d, wanted 0\n", got) + failed = true + } + + if got := lsh_uint16_0_ssa(0); got != 0 { + fmt.Printf("lsh_uint16 0<<0 = %d, wanted 0\n", got) + failed = true + } + + if got := lsh_0_uint16_ssa(1); got != 0 { + fmt.Printf("lsh_uint16 0<<1 = %d, wanted 0\n", got) + failed = true + } + + if got := lsh_uint16_0_ssa(1); got != 1 { + fmt.Printf("lsh_uint16 1<<0 = %d, wanted 1\n", got) + failed = true + } + + if got := lsh_0_uint16_ssa(65535); got != 0 { + fmt.Printf("lsh_uint16 0<<65535 = %d, wanted 0\n", got) + failed = true + } + + if got := lsh_uint16_0_ssa(65535); got != 65535 { + fmt.Printf("lsh_uint16 65535<<0 = %d, wanted 65535\n", got) + failed = true + } + + if got := lsh_1_uint16_ssa(0); got != 1 { + fmt.Printf("lsh_uint16 1<<0 = %d, wanted 1\n", got) + failed = true + } + + if got := lsh_uint16_1_ssa(0); got != 0 { + fmt.Printf("lsh_uint16 0<<1 = %d, wanted 0\n", got) + failed = true + } + + if got := lsh_1_uint16_ssa(1); got != 2 { + fmt.Printf("lsh_uint16 1<<1 = %d, wanted 2\n", got) + failed = true + } + + if got := lsh_uint16_1_ssa(1); got != 2 { + fmt.Printf("lsh_uint16 1<<1 = %d, wanted 2\n", got) + failed = true + } + + if got := lsh_1_uint16_ssa(65535); got != 0 { + fmt.Printf("lsh_uint16 1<<65535 = %d, wanted 0\n", got) + failed = true + } + + if got := lsh_uint16_1_ssa(65535); got != 65534 { + fmt.Printf("lsh_uint16 65535<<1 = %d, wanted 65534\n", got) + failed = true + } + + if got := lsh_65535_uint16_ssa(0); got != 65535 { + fmt.Printf("lsh_uint16 65535<<0 = %d, wanted 65535\n", got) + failed = true + } + + if got := lsh_uint16_65535_ssa(0); got != 0 { + fmt.Printf("lsh_uint16 0<<65535 = %d, wanted 0\n", got) + failed = true + } + + if got := lsh_65535_uint16_ssa(1); got != 65534 { + fmt.Printf("lsh_uint16 65535<<1 = %d, wanted 65534\n", got) + failed = true + } + + if got := lsh_uint16_65535_ssa(1); got != 0 { + fmt.Printf("lsh_uint16 1<<65535 = %d, wanted 0\n", got) + failed = true + } + + if got := lsh_65535_uint16_ssa(65535); got != 0 { + fmt.Printf("lsh_uint16 65535<<65535 = %d, wanted 0\n", got) + failed = true + } + + if got := lsh_uint16_65535_ssa(65535); got != 0 { + fmt.Printf("lsh_uint16 65535<<65535 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_0_uint16_ssa(0); got != 0 { + fmt.Printf("rsh_uint16 0>>0 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_uint16_0_ssa(0); got != 0 { + fmt.Printf("rsh_uint16 0>>0 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_0_uint16_ssa(1); got != 0 { + fmt.Printf("rsh_uint16 0>>1 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_uint16_0_ssa(1); got != 1 { + fmt.Printf("rsh_uint16 1>>0 = %d, wanted 1\n", got) + failed = true + } + + if got := rsh_0_uint16_ssa(65535); got != 0 { + fmt.Printf("rsh_uint16 0>>65535 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_uint16_0_ssa(65535); got != 65535 { + fmt.Printf("rsh_uint16 65535>>0 = %d, wanted 65535\n", got) + failed = true + } + + if got := rsh_1_uint16_ssa(0); got != 1 { + fmt.Printf("rsh_uint16 1>>0 = %d, wanted 1\n", got) + failed = true + } + + if got := rsh_uint16_1_ssa(0); got != 0 { + fmt.Printf("rsh_uint16 0>>1 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_1_uint16_ssa(1); got != 0 { + fmt.Printf("rsh_uint16 1>>1 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_uint16_1_ssa(1); got != 0 { + fmt.Printf("rsh_uint16 1>>1 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_1_uint16_ssa(65535); got != 0 { + fmt.Printf("rsh_uint16 1>>65535 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_uint16_1_ssa(65535); got != 32767 { + fmt.Printf("rsh_uint16 65535>>1 = %d, wanted 32767\n", got) + failed = true + } + + if got := rsh_65535_uint16_ssa(0); got != 65535 { + fmt.Printf("rsh_uint16 65535>>0 = %d, wanted 65535\n", got) + failed = true + } + + if got := rsh_uint16_65535_ssa(0); got != 0 { + fmt.Printf("rsh_uint16 0>>65535 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_65535_uint16_ssa(1); got != 32767 { + fmt.Printf("rsh_uint16 65535>>1 = %d, wanted 32767\n", got) + failed = true + } + + if got := rsh_uint16_65535_ssa(1); got != 0 { + fmt.Printf("rsh_uint16 1>>65535 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_65535_uint16_ssa(65535); got != 0 { + fmt.Printf("rsh_uint16 65535>>65535 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_uint16_65535_ssa(65535); got != 0 { + fmt.Printf("rsh_uint16 65535>>65535 = %d, wanted 0\n", got) + failed = true + } + + if got := add_Neg32768_int16_ssa(-32768); got != 0 { + fmt.Printf("add_int16 -32768+-32768 = %d, wanted 0\n", got) + failed = true + } + + if got := add_int16_Neg32768_ssa(-32768); got != 0 { + fmt.Printf("add_int16 -32768+-32768 = %d, wanted 0\n", got) + failed = true + } + + if got := add_Neg32768_int16_ssa(-32767); got != 1 { + fmt.Printf("add_int16 -32768+-32767 = %d, wanted 1\n", got) + failed = true + } + + if got := add_int16_Neg32768_ssa(-32767); got != 1 { + fmt.Printf("add_int16 -32767+-32768 = %d, wanted 1\n", got) + failed = true + } + + if got := add_Neg32768_int16_ssa(-1); got != 32767 { + fmt.Printf("add_int16 -32768+-1 = %d, wanted 32767\n", got) + failed = true + } + + if got := add_int16_Neg32768_ssa(-1); got != 32767 { + fmt.Printf("add_int16 -1+-32768 = %d, wanted 32767\n", got) + failed = true + } + + if got := add_Neg32768_int16_ssa(0); got != -32768 { + fmt.Printf("add_int16 -32768+0 = %d, wanted -32768\n", got) + failed = true + } + + if got := add_int16_Neg32768_ssa(0); got != -32768 { + fmt.Printf("add_int16 0+-32768 = %d, wanted -32768\n", got) + failed = true + } + + if got := add_Neg32768_int16_ssa(1); got != -32767 { + fmt.Printf("add_int16 -32768+1 = %d, wanted -32767\n", got) + failed = true + } + + if got := add_int16_Neg32768_ssa(1); got != -32767 { + fmt.Printf("add_int16 1+-32768 = %d, wanted -32767\n", got) + failed = true + } + + if got := add_Neg32768_int16_ssa(32766); got != -2 { + fmt.Printf("add_int16 -32768+32766 = %d, wanted -2\n", got) + failed = true + } + + if got := add_int16_Neg32768_ssa(32766); got != -2 { + fmt.Printf("add_int16 32766+-32768 = %d, wanted -2\n", got) + failed = true + } + + if got := add_Neg32768_int16_ssa(32767); got != -1 { + fmt.Printf("add_int16 -32768+32767 = %d, wanted -1\n", got) + failed = true + } + + if got := add_int16_Neg32768_ssa(32767); got != -1 { + fmt.Printf("add_int16 32767+-32768 = %d, wanted -1\n", got) + failed = true + } + + if got := add_Neg32767_int16_ssa(-32768); got != 1 { + fmt.Printf("add_int16 -32767+-32768 = %d, wanted 1\n", got) + failed = true + } + + if got := add_int16_Neg32767_ssa(-32768); got != 1 { + fmt.Printf("add_int16 -32768+-32767 = %d, wanted 1\n", got) + failed = true + } + + if got := add_Neg32767_int16_ssa(-32767); got != 2 { + fmt.Printf("add_int16 -32767+-32767 = %d, wanted 2\n", got) + failed = true + } + + if got := add_int16_Neg32767_ssa(-32767); got != 2 { + fmt.Printf("add_int16 -32767+-32767 = %d, wanted 2\n", got) + failed = true + } + + if got := add_Neg32767_int16_ssa(-1); got != -32768 { + fmt.Printf("add_int16 -32767+-1 = %d, wanted -32768\n", got) + failed = true + } + + if got := add_int16_Neg32767_ssa(-1); got != -32768 { + fmt.Printf("add_int16 -1+-32767 = %d, wanted -32768\n", got) + failed = true + } + + if got := add_Neg32767_int16_ssa(0); got != -32767 { + fmt.Printf("add_int16 -32767+0 = %d, wanted -32767\n", got) + failed = true + } + + if got := add_int16_Neg32767_ssa(0); got != -32767 { + fmt.Printf("add_int16 0+-32767 = %d, wanted -32767\n", got) + failed = true + } + + if got := add_Neg32767_int16_ssa(1); got != -32766 { + fmt.Printf("add_int16 -32767+1 = %d, wanted -32766\n", got) + failed = true + } + + if got := add_int16_Neg32767_ssa(1); got != -32766 { + fmt.Printf("add_int16 1+-32767 = %d, wanted -32766\n", got) + failed = true + } + + if got := add_Neg32767_int16_ssa(32766); got != -1 { + fmt.Printf("add_int16 -32767+32766 = %d, wanted -1\n", got) + failed = true + } + + if got := add_int16_Neg32767_ssa(32766); got != -1 { + fmt.Printf("add_int16 32766+-32767 = %d, wanted -1\n", got) + failed = true + } + + if got := add_Neg32767_int16_ssa(32767); got != 0 { + fmt.Printf("add_int16 -32767+32767 = %d, wanted 0\n", got) + failed = true + } + + if got := add_int16_Neg32767_ssa(32767); got != 0 { + fmt.Printf("add_int16 32767+-32767 = %d, wanted 0\n", got) + failed = true + } + + if got := add_Neg1_int16_ssa(-32768); got != 32767 { + fmt.Printf("add_int16 -1+-32768 = %d, wanted 32767\n", got) + failed = true + } + + if got := add_int16_Neg1_ssa(-32768); got != 32767 { + fmt.Printf("add_int16 -32768+-1 = %d, wanted 32767\n", got) + failed = true + } + + if got := add_Neg1_int16_ssa(-32767); got != -32768 { + fmt.Printf("add_int16 -1+-32767 = %d, wanted -32768\n", got) + failed = true + } + + if got := add_int16_Neg1_ssa(-32767); got != -32768 { + fmt.Printf("add_int16 -32767+-1 = %d, wanted -32768\n", got) + failed = true + } + + if got := add_Neg1_int16_ssa(-1); got != -2 { + fmt.Printf("add_int16 -1+-1 = %d, wanted -2\n", got) + failed = true + } + + if got := add_int16_Neg1_ssa(-1); got != -2 { + fmt.Printf("add_int16 -1+-1 = %d, wanted -2\n", got) + failed = true + } + + if got := add_Neg1_int16_ssa(0); got != -1 { + fmt.Printf("add_int16 -1+0 = %d, wanted -1\n", got) + failed = true + } + + if got := add_int16_Neg1_ssa(0); got != -1 { + fmt.Printf("add_int16 0+-1 = %d, wanted -1\n", got) + failed = true + } + + if got := add_Neg1_int16_ssa(1); got != 0 { + fmt.Printf("add_int16 -1+1 = %d, wanted 0\n", got) + failed = true + } + + if got := add_int16_Neg1_ssa(1); got != 0 { + fmt.Printf("add_int16 1+-1 = %d, wanted 0\n", got) + failed = true + } + + if got := add_Neg1_int16_ssa(32766); got != 32765 { + fmt.Printf("add_int16 -1+32766 = %d, wanted 32765\n", got) + failed = true + } + + if got := add_int16_Neg1_ssa(32766); got != 32765 { + fmt.Printf("add_int16 32766+-1 = %d, wanted 32765\n", got) + failed = true + } + + if got := add_Neg1_int16_ssa(32767); got != 32766 { + fmt.Printf("add_int16 -1+32767 = %d, wanted 32766\n", got) + failed = true + } + + if got := add_int16_Neg1_ssa(32767); got != 32766 { + fmt.Printf("add_int16 32767+-1 = %d, wanted 32766\n", got) + failed = true + } + + if got := add_0_int16_ssa(-32768); got != -32768 { + fmt.Printf("add_int16 0+-32768 = %d, wanted -32768\n", got) + failed = true + } + + if got := add_int16_0_ssa(-32768); got != -32768 { + fmt.Printf("add_int16 -32768+0 = %d, wanted -32768\n", got) + failed = true + } + + if got := add_0_int16_ssa(-32767); got != -32767 { + fmt.Printf("add_int16 0+-32767 = %d, wanted -32767\n", got) + failed = true + } + + if got := add_int16_0_ssa(-32767); got != -32767 { + fmt.Printf("add_int16 -32767+0 = %d, wanted -32767\n", got) + failed = true + } + + if got := add_0_int16_ssa(-1); got != -1 { + fmt.Printf("add_int16 0+-1 = %d, wanted -1\n", got) + failed = true + } + + if got := add_int16_0_ssa(-1); got != -1 { + fmt.Printf("add_int16 -1+0 = %d, wanted -1\n", got) + failed = true + } + + if got := add_0_int16_ssa(0); got != 0 { + fmt.Printf("add_int16 0+0 = %d, wanted 0\n", got) + failed = true + } + + if got := add_int16_0_ssa(0); got != 0 { + fmt.Printf("add_int16 0+0 = %d, wanted 0\n", got) + failed = true + } + + if got := add_0_int16_ssa(1); got != 1 { + fmt.Printf("add_int16 0+1 = %d, wanted 1\n", got) + failed = true + } + + if got := add_int16_0_ssa(1); got != 1 { + fmt.Printf("add_int16 1+0 = %d, wanted 1\n", got) + failed = true + } + + if got := add_0_int16_ssa(32766); got != 32766 { + fmt.Printf("add_int16 0+32766 = %d, wanted 32766\n", got) + failed = true + } + + if got := add_int16_0_ssa(32766); got != 32766 { + fmt.Printf("add_int16 32766+0 = %d, wanted 32766\n", got) + failed = true + } + + if got := add_0_int16_ssa(32767); got != 32767 { + fmt.Printf("add_int16 0+32767 = %d, wanted 32767\n", got) + failed = true + } + + if got := add_int16_0_ssa(32767); got != 32767 { + fmt.Printf("add_int16 32767+0 = %d, wanted 32767\n", got) + failed = true + } + + if got := add_1_int16_ssa(-32768); got != -32767 { + fmt.Printf("add_int16 1+-32768 = %d, wanted -32767\n", got) + failed = true + } + + if got := add_int16_1_ssa(-32768); got != -32767 { + fmt.Printf("add_int16 -32768+1 = %d, wanted -32767\n", got) + failed = true + } + + if got := add_1_int16_ssa(-32767); got != -32766 { + fmt.Printf("add_int16 1+-32767 = %d, wanted -32766\n", got) + failed = true + } + + if got := add_int16_1_ssa(-32767); got != -32766 { + fmt.Printf("add_int16 -32767+1 = %d, wanted -32766\n", got) + failed = true + } + + if got := add_1_int16_ssa(-1); got != 0 { + fmt.Printf("add_int16 1+-1 = %d, wanted 0\n", got) + failed = true + } + + if got := add_int16_1_ssa(-1); got != 0 { + fmt.Printf("add_int16 -1+1 = %d, wanted 0\n", got) + failed = true + } + + if got := add_1_int16_ssa(0); got != 1 { + fmt.Printf("add_int16 1+0 = %d, wanted 1\n", got) + failed = true + } + + if got := add_int16_1_ssa(0); got != 1 { + fmt.Printf("add_int16 0+1 = %d, wanted 1\n", got) + failed = true + } + + if got := add_1_int16_ssa(1); got != 2 { + fmt.Printf("add_int16 1+1 = %d, wanted 2\n", got) + failed = true + } + + if got := add_int16_1_ssa(1); got != 2 { + fmt.Printf("add_int16 1+1 = %d, wanted 2\n", got) + failed = true + } + + if got := add_1_int16_ssa(32766); got != 32767 { + fmt.Printf("add_int16 1+32766 = %d, wanted 32767\n", got) + failed = true + } + + if got := add_int16_1_ssa(32766); got != 32767 { + fmt.Printf("add_int16 32766+1 = %d, wanted 32767\n", got) + failed = true + } + + if got := add_1_int16_ssa(32767); got != -32768 { + fmt.Printf("add_int16 1+32767 = %d, wanted -32768\n", got) + failed = true + } + + if got := add_int16_1_ssa(32767); got != -32768 { + fmt.Printf("add_int16 32767+1 = %d, wanted -32768\n", got) + failed = true + } + + if got := add_32766_int16_ssa(-32768); got != -2 { + fmt.Printf("add_int16 32766+-32768 = %d, wanted -2\n", got) + failed = true + } + + if got := add_int16_32766_ssa(-32768); got != -2 { + fmt.Printf("add_int16 -32768+32766 = %d, wanted -2\n", got) + failed = true + } + + if got := add_32766_int16_ssa(-32767); got != -1 { + fmt.Printf("add_int16 32766+-32767 = %d, wanted -1\n", got) + failed = true + } + + if got := add_int16_32766_ssa(-32767); got != -1 { + fmt.Printf("add_int16 -32767+32766 = %d, wanted -1\n", got) + failed = true + } + + if got := add_32766_int16_ssa(-1); got != 32765 { + fmt.Printf("add_int16 32766+-1 = %d, wanted 32765\n", got) + failed = true + } + + if got := add_int16_32766_ssa(-1); got != 32765 { + fmt.Printf("add_int16 -1+32766 = %d, wanted 32765\n", got) + failed = true + } + + if got := add_32766_int16_ssa(0); got != 32766 { + fmt.Printf("add_int16 32766+0 = %d, wanted 32766\n", got) + failed = true + } + + if got := add_int16_32766_ssa(0); got != 32766 { + fmt.Printf("add_int16 0+32766 = %d, wanted 32766\n", got) + failed = true + } + + if got := add_32766_int16_ssa(1); got != 32767 { + fmt.Printf("add_int16 32766+1 = %d, wanted 32767\n", got) + failed = true + } + + if got := add_int16_32766_ssa(1); got != 32767 { + fmt.Printf("add_int16 1+32766 = %d, wanted 32767\n", got) + failed = true + } + + if got := add_32766_int16_ssa(32766); got != -4 { + fmt.Printf("add_int16 32766+32766 = %d, wanted -4\n", got) + failed = true + } + + if got := add_int16_32766_ssa(32766); got != -4 { + fmt.Printf("add_int16 32766+32766 = %d, wanted -4\n", got) + failed = true + } + + if got := add_32766_int16_ssa(32767); got != -3 { + fmt.Printf("add_int16 32766+32767 = %d, wanted -3\n", got) + failed = true + } + + if got := add_int16_32766_ssa(32767); got != -3 { + fmt.Printf("add_int16 32767+32766 = %d, wanted -3\n", got) + failed = true + } + + if got := add_32767_int16_ssa(-32768); got != -1 { + fmt.Printf("add_int16 32767+-32768 = %d, wanted -1\n", got) + failed = true + } + + if got := add_int16_32767_ssa(-32768); got != -1 { + fmt.Printf("add_int16 -32768+32767 = %d, wanted -1\n", got) + failed = true + } + + if got := add_32767_int16_ssa(-32767); got != 0 { + fmt.Printf("add_int16 32767+-32767 = %d, wanted 0\n", got) + failed = true + } + + if got := add_int16_32767_ssa(-32767); got != 0 { + fmt.Printf("add_int16 -32767+32767 = %d, wanted 0\n", got) + failed = true + } + + if got := add_32767_int16_ssa(-1); got != 32766 { + fmt.Printf("add_int16 32767+-1 = %d, wanted 32766\n", got) + failed = true + } + + if got := add_int16_32767_ssa(-1); got != 32766 { + fmt.Printf("add_int16 -1+32767 = %d, wanted 32766\n", got) + failed = true + } + + if got := add_32767_int16_ssa(0); got != 32767 { + fmt.Printf("add_int16 32767+0 = %d, wanted 32767\n", got) + failed = true + } + + if got := add_int16_32767_ssa(0); got != 32767 { + fmt.Printf("add_int16 0+32767 = %d, wanted 32767\n", got) + failed = true + } + + if got := add_32767_int16_ssa(1); got != -32768 { + fmt.Printf("add_int16 32767+1 = %d, wanted -32768\n", got) + failed = true + } + + if got := add_int16_32767_ssa(1); got != -32768 { + fmt.Printf("add_int16 1+32767 = %d, wanted -32768\n", got) + failed = true + } + + if got := add_32767_int16_ssa(32766); got != -3 { + fmt.Printf("add_int16 32767+32766 = %d, wanted -3\n", got) + failed = true + } + + if got := add_int16_32767_ssa(32766); got != -3 { + fmt.Printf("add_int16 32766+32767 = %d, wanted -3\n", got) + failed = true + } + + if got := add_32767_int16_ssa(32767); got != -2 { + fmt.Printf("add_int16 32767+32767 = %d, wanted -2\n", got) + failed = true + } + + if got := add_int16_32767_ssa(32767); got != -2 { + fmt.Printf("add_int16 32767+32767 = %d, wanted -2\n", got) + failed = true + } + + if got := sub_Neg32768_int16_ssa(-32768); got != 0 { + fmt.Printf("sub_int16 -32768--32768 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_int16_Neg32768_ssa(-32768); got != 0 { + fmt.Printf("sub_int16 -32768--32768 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_Neg32768_int16_ssa(-32767); got != -1 { + fmt.Printf("sub_int16 -32768--32767 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_int16_Neg32768_ssa(-32767); got != 1 { + fmt.Printf("sub_int16 -32767--32768 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_Neg32768_int16_ssa(-1); got != -32767 { + fmt.Printf("sub_int16 -32768--1 = %d, wanted -32767\n", got) + failed = true + } + + if got := sub_int16_Neg32768_ssa(-1); got != 32767 { + fmt.Printf("sub_int16 -1--32768 = %d, wanted 32767\n", got) + failed = true + } + + if got := sub_Neg32768_int16_ssa(0); got != -32768 { + fmt.Printf("sub_int16 -32768-0 = %d, wanted -32768\n", got) + failed = true + } + + if got := sub_int16_Neg32768_ssa(0); got != -32768 { + fmt.Printf("sub_int16 0--32768 = %d, wanted -32768\n", got) + failed = true + } + + if got := sub_Neg32768_int16_ssa(1); got != 32767 { + fmt.Printf("sub_int16 -32768-1 = %d, wanted 32767\n", got) + failed = true + } + + if got := sub_int16_Neg32768_ssa(1); got != -32767 { + fmt.Printf("sub_int16 1--32768 = %d, wanted -32767\n", got) + failed = true + } + + if got := sub_Neg32768_int16_ssa(32766); got != 2 { + fmt.Printf("sub_int16 -32768-32766 = %d, wanted 2\n", got) + failed = true + } + + if got := sub_int16_Neg32768_ssa(32766); got != -2 { + fmt.Printf("sub_int16 32766--32768 = %d, wanted -2\n", got) + failed = true + } + + if got := sub_Neg32768_int16_ssa(32767); got != 1 { + fmt.Printf("sub_int16 -32768-32767 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_int16_Neg32768_ssa(32767); got != -1 { + fmt.Printf("sub_int16 32767--32768 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_Neg32767_int16_ssa(-32768); got != 1 { + fmt.Printf("sub_int16 -32767--32768 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_int16_Neg32767_ssa(-32768); got != -1 { + fmt.Printf("sub_int16 -32768--32767 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_Neg32767_int16_ssa(-32767); got != 0 { + fmt.Printf("sub_int16 -32767--32767 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_int16_Neg32767_ssa(-32767); got != 0 { + fmt.Printf("sub_int16 -32767--32767 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_Neg32767_int16_ssa(-1); got != -32766 { + fmt.Printf("sub_int16 -32767--1 = %d, wanted -32766\n", got) + failed = true + } + + if got := sub_int16_Neg32767_ssa(-1); got != 32766 { + fmt.Printf("sub_int16 -1--32767 = %d, wanted 32766\n", got) + failed = true + } + + if got := sub_Neg32767_int16_ssa(0); got != -32767 { + fmt.Printf("sub_int16 -32767-0 = %d, wanted -32767\n", got) + failed = true + } + + if got := sub_int16_Neg32767_ssa(0); got != 32767 { + fmt.Printf("sub_int16 0--32767 = %d, wanted 32767\n", got) + failed = true + } + + if got := sub_Neg32767_int16_ssa(1); got != -32768 { + fmt.Printf("sub_int16 -32767-1 = %d, wanted -32768\n", got) + failed = true + } + + if got := sub_int16_Neg32767_ssa(1); got != -32768 { + fmt.Printf("sub_int16 1--32767 = %d, wanted -32768\n", got) + failed = true + } + + if got := sub_Neg32767_int16_ssa(32766); got != 3 { + fmt.Printf("sub_int16 -32767-32766 = %d, wanted 3\n", got) + failed = true + } + + if got := sub_int16_Neg32767_ssa(32766); got != -3 { + fmt.Printf("sub_int16 32766--32767 = %d, wanted -3\n", got) + failed = true + } + + if got := sub_Neg32767_int16_ssa(32767); got != 2 { + fmt.Printf("sub_int16 -32767-32767 = %d, wanted 2\n", got) + failed = true + } + + if got := sub_int16_Neg32767_ssa(32767); got != -2 { + fmt.Printf("sub_int16 32767--32767 = %d, wanted -2\n", got) + failed = true + } + + if got := sub_Neg1_int16_ssa(-32768); got != 32767 { + fmt.Printf("sub_int16 -1--32768 = %d, wanted 32767\n", got) + failed = true + } + + if got := sub_int16_Neg1_ssa(-32768); got != -32767 { + fmt.Printf("sub_int16 -32768--1 = %d, wanted -32767\n", got) + failed = true + } + + if got := sub_Neg1_int16_ssa(-32767); got != 32766 { + fmt.Printf("sub_int16 -1--32767 = %d, wanted 32766\n", got) + failed = true + } + + if got := sub_int16_Neg1_ssa(-32767); got != -32766 { + fmt.Printf("sub_int16 -32767--1 = %d, wanted -32766\n", got) + failed = true + } + + if got := sub_Neg1_int16_ssa(-1); got != 0 { + fmt.Printf("sub_int16 -1--1 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_int16_Neg1_ssa(-1); got != 0 { + fmt.Printf("sub_int16 -1--1 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_Neg1_int16_ssa(0); got != -1 { + fmt.Printf("sub_int16 -1-0 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_int16_Neg1_ssa(0); got != 1 { + fmt.Printf("sub_int16 0--1 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_Neg1_int16_ssa(1); got != -2 { + fmt.Printf("sub_int16 -1-1 = %d, wanted -2\n", got) + failed = true + } + + if got := sub_int16_Neg1_ssa(1); got != 2 { + fmt.Printf("sub_int16 1--1 = %d, wanted 2\n", got) + failed = true + } + + if got := sub_Neg1_int16_ssa(32766); got != -32767 { + fmt.Printf("sub_int16 -1-32766 = %d, wanted -32767\n", got) + failed = true + } + + if got := sub_int16_Neg1_ssa(32766); got != 32767 { + fmt.Printf("sub_int16 32766--1 = %d, wanted 32767\n", got) + failed = true + } + + if got := sub_Neg1_int16_ssa(32767); got != -32768 { + fmt.Printf("sub_int16 -1-32767 = %d, wanted -32768\n", got) + failed = true + } + + if got := sub_int16_Neg1_ssa(32767); got != -32768 { + fmt.Printf("sub_int16 32767--1 = %d, wanted -32768\n", got) + failed = true + } + + if got := sub_0_int16_ssa(-32768); got != -32768 { + fmt.Printf("sub_int16 0--32768 = %d, wanted -32768\n", got) + failed = true + } + + if got := sub_int16_0_ssa(-32768); got != -32768 { + fmt.Printf("sub_int16 -32768-0 = %d, wanted -32768\n", got) + failed = true + } + + if got := sub_0_int16_ssa(-32767); got != 32767 { + fmt.Printf("sub_int16 0--32767 = %d, wanted 32767\n", got) + failed = true + } + + if got := sub_int16_0_ssa(-32767); got != -32767 { + fmt.Printf("sub_int16 -32767-0 = %d, wanted -32767\n", got) + failed = true + } + + if got := sub_0_int16_ssa(-1); got != 1 { + fmt.Printf("sub_int16 0--1 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_int16_0_ssa(-1); got != -1 { + fmt.Printf("sub_int16 -1-0 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_0_int16_ssa(0); got != 0 { + fmt.Printf("sub_int16 0-0 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_int16_0_ssa(0); got != 0 { + fmt.Printf("sub_int16 0-0 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_0_int16_ssa(1); got != -1 { + fmt.Printf("sub_int16 0-1 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_int16_0_ssa(1); got != 1 { + fmt.Printf("sub_int16 1-0 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_0_int16_ssa(32766); got != -32766 { + fmt.Printf("sub_int16 0-32766 = %d, wanted -32766\n", got) + failed = true + } + + if got := sub_int16_0_ssa(32766); got != 32766 { + fmt.Printf("sub_int16 32766-0 = %d, wanted 32766\n", got) + failed = true + } + + if got := sub_0_int16_ssa(32767); got != -32767 { + fmt.Printf("sub_int16 0-32767 = %d, wanted -32767\n", got) + failed = true + } + + if got := sub_int16_0_ssa(32767); got != 32767 { + fmt.Printf("sub_int16 32767-0 = %d, wanted 32767\n", got) + failed = true + } + + if got := sub_1_int16_ssa(-32768); got != -32767 { + fmt.Printf("sub_int16 1--32768 = %d, wanted -32767\n", got) + failed = true + } + + if got := sub_int16_1_ssa(-32768); got != 32767 { + fmt.Printf("sub_int16 -32768-1 = %d, wanted 32767\n", got) + failed = true + } + + if got := sub_1_int16_ssa(-32767); got != -32768 { + fmt.Printf("sub_int16 1--32767 = %d, wanted -32768\n", got) + failed = true + } + + if got := sub_int16_1_ssa(-32767); got != -32768 { + fmt.Printf("sub_int16 -32767-1 = %d, wanted -32768\n", got) + failed = true + } + + if got := sub_1_int16_ssa(-1); got != 2 { + fmt.Printf("sub_int16 1--1 = %d, wanted 2\n", got) + failed = true + } + + if got := sub_int16_1_ssa(-1); got != -2 { + fmt.Printf("sub_int16 -1-1 = %d, wanted -2\n", got) + failed = true + } + + if got := sub_1_int16_ssa(0); got != 1 { + fmt.Printf("sub_int16 1-0 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_int16_1_ssa(0); got != -1 { + fmt.Printf("sub_int16 0-1 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_1_int16_ssa(1); got != 0 { + fmt.Printf("sub_int16 1-1 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_int16_1_ssa(1); got != 0 { + fmt.Printf("sub_int16 1-1 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_1_int16_ssa(32766); got != -32765 { + fmt.Printf("sub_int16 1-32766 = %d, wanted -32765\n", got) + failed = true + } + + if got := sub_int16_1_ssa(32766); got != 32765 { + fmt.Printf("sub_int16 32766-1 = %d, wanted 32765\n", got) + failed = true + } + + if got := sub_1_int16_ssa(32767); got != -32766 { + fmt.Printf("sub_int16 1-32767 = %d, wanted -32766\n", got) + failed = true + } + + if got := sub_int16_1_ssa(32767); got != 32766 { + fmt.Printf("sub_int16 32767-1 = %d, wanted 32766\n", got) + failed = true + } + + if got := sub_32766_int16_ssa(-32768); got != -2 { + fmt.Printf("sub_int16 32766--32768 = %d, wanted -2\n", got) + failed = true + } + + if got := sub_int16_32766_ssa(-32768); got != 2 { + fmt.Printf("sub_int16 -32768-32766 = %d, wanted 2\n", got) + failed = true + } + + if got := sub_32766_int16_ssa(-32767); got != -3 { + fmt.Printf("sub_int16 32766--32767 = %d, wanted -3\n", got) + failed = true + } + + if got := sub_int16_32766_ssa(-32767); got != 3 { + fmt.Printf("sub_int16 -32767-32766 = %d, wanted 3\n", got) + failed = true + } + + if got := sub_32766_int16_ssa(-1); got != 32767 { + fmt.Printf("sub_int16 32766--1 = %d, wanted 32767\n", got) + failed = true + } + + if got := sub_int16_32766_ssa(-1); got != -32767 { + fmt.Printf("sub_int16 -1-32766 = %d, wanted -32767\n", got) + failed = true + } + + if got := sub_32766_int16_ssa(0); got != 32766 { + fmt.Printf("sub_int16 32766-0 = %d, wanted 32766\n", got) + failed = true + } + + if got := sub_int16_32766_ssa(0); got != -32766 { + fmt.Printf("sub_int16 0-32766 = %d, wanted -32766\n", got) + failed = true + } + + if got := sub_32766_int16_ssa(1); got != 32765 { + fmt.Printf("sub_int16 32766-1 = %d, wanted 32765\n", got) + failed = true + } + + if got := sub_int16_32766_ssa(1); got != -32765 { + fmt.Printf("sub_int16 1-32766 = %d, wanted -32765\n", got) + failed = true + } + + if got := sub_32766_int16_ssa(32766); got != 0 { + fmt.Printf("sub_int16 32766-32766 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_int16_32766_ssa(32766); got != 0 { + fmt.Printf("sub_int16 32766-32766 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_32766_int16_ssa(32767); got != -1 { + fmt.Printf("sub_int16 32766-32767 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_int16_32766_ssa(32767); got != 1 { + fmt.Printf("sub_int16 32767-32766 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_32767_int16_ssa(-32768); got != -1 { + fmt.Printf("sub_int16 32767--32768 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_int16_32767_ssa(-32768); got != 1 { + fmt.Printf("sub_int16 -32768-32767 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_32767_int16_ssa(-32767); got != -2 { + fmt.Printf("sub_int16 32767--32767 = %d, wanted -2\n", got) + failed = true + } + + if got := sub_int16_32767_ssa(-32767); got != 2 { + fmt.Printf("sub_int16 -32767-32767 = %d, wanted 2\n", got) + failed = true + } + + if got := sub_32767_int16_ssa(-1); got != -32768 { + fmt.Printf("sub_int16 32767--1 = %d, wanted -32768\n", got) + failed = true + } + + if got := sub_int16_32767_ssa(-1); got != -32768 { + fmt.Printf("sub_int16 -1-32767 = %d, wanted -32768\n", got) + failed = true + } + + if got := sub_32767_int16_ssa(0); got != 32767 { + fmt.Printf("sub_int16 32767-0 = %d, wanted 32767\n", got) + failed = true + } + + if got := sub_int16_32767_ssa(0); got != -32767 { + fmt.Printf("sub_int16 0-32767 = %d, wanted -32767\n", got) + failed = true + } + + if got := sub_32767_int16_ssa(1); got != 32766 { + fmt.Printf("sub_int16 32767-1 = %d, wanted 32766\n", got) + failed = true + } + + if got := sub_int16_32767_ssa(1); got != -32766 { + fmt.Printf("sub_int16 1-32767 = %d, wanted -32766\n", got) + failed = true + } + + if got := sub_32767_int16_ssa(32766); got != 1 { + fmt.Printf("sub_int16 32767-32766 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_int16_32767_ssa(32766); got != -1 { + fmt.Printf("sub_int16 32766-32767 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_32767_int16_ssa(32767); got != 0 { + fmt.Printf("sub_int16 32767-32767 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_int16_32767_ssa(32767); got != 0 { + fmt.Printf("sub_int16 32767-32767 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg32768_int16_ssa(-32768); got != 1 { + fmt.Printf("div_int16 -32768/-32768 = %d, wanted 1\n", got) + failed = true + } + + if got := div_int16_Neg32768_ssa(-32768); got != 1 { + fmt.Printf("div_int16 -32768/-32768 = %d, wanted 1\n", got) + failed = true + } + + if got := div_Neg32768_int16_ssa(-32767); got != 1 { + fmt.Printf("div_int16 -32768/-32767 = %d, wanted 1\n", got) + failed = true + } + + if got := div_int16_Neg32768_ssa(-32767); got != 0 { + fmt.Printf("div_int16 -32767/-32768 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg32768_int16_ssa(-1); got != -32768 { + fmt.Printf("div_int16 -32768/-1 = %d, wanted -32768\n", got) + failed = true + } + + if got := div_int16_Neg32768_ssa(-1); got != 0 { + fmt.Printf("div_int16 -1/-32768 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int16_Neg32768_ssa(0); got != 0 { + fmt.Printf("div_int16 0/-32768 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg32768_int16_ssa(1); got != -32768 { + fmt.Printf("div_int16 -32768/1 = %d, wanted -32768\n", got) + failed = true + } + + if got := div_int16_Neg32768_ssa(1); got != 0 { + fmt.Printf("div_int16 1/-32768 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg32768_int16_ssa(32766); got != -1 { + fmt.Printf("div_int16 -32768/32766 = %d, wanted -1\n", got) + failed = true + } + + if got := div_int16_Neg32768_ssa(32766); got != 0 { + fmt.Printf("div_int16 32766/-32768 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg32768_int16_ssa(32767); got != -1 { + fmt.Printf("div_int16 -32768/32767 = %d, wanted -1\n", got) + failed = true + } + + if got := div_int16_Neg32768_ssa(32767); got != 0 { + fmt.Printf("div_int16 32767/-32768 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg32767_int16_ssa(-32768); got != 0 { + fmt.Printf("div_int16 -32767/-32768 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int16_Neg32767_ssa(-32768); got != 1 { + fmt.Printf("div_int16 -32768/-32767 = %d, wanted 1\n", got) + failed = true + } + + if got := div_Neg32767_int16_ssa(-32767); got != 1 { + fmt.Printf("div_int16 -32767/-32767 = %d, wanted 1\n", got) + failed = true + } + + if got := div_int16_Neg32767_ssa(-32767); got != 1 { + fmt.Printf("div_int16 -32767/-32767 = %d, wanted 1\n", got) + failed = true + } + + if got := div_Neg32767_int16_ssa(-1); got != 32767 { + fmt.Printf("div_int16 -32767/-1 = %d, wanted 32767\n", got) + failed = true + } + + if got := div_int16_Neg32767_ssa(-1); got != 0 { + fmt.Printf("div_int16 -1/-32767 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int16_Neg32767_ssa(0); got != 0 { + fmt.Printf("div_int16 0/-32767 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg32767_int16_ssa(1); got != -32767 { + fmt.Printf("div_int16 -32767/1 = %d, wanted -32767\n", got) + failed = true + } + + if got := div_int16_Neg32767_ssa(1); got != 0 { + fmt.Printf("div_int16 1/-32767 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg32767_int16_ssa(32766); got != -1 { + fmt.Printf("div_int16 -32767/32766 = %d, wanted -1\n", got) + failed = true + } + + if got := div_int16_Neg32767_ssa(32766); got != 0 { + fmt.Printf("div_int16 32766/-32767 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg32767_int16_ssa(32767); got != -1 { + fmt.Printf("div_int16 -32767/32767 = %d, wanted -1\n", got) + failed = true + } + + if got := div_int16_Neg32767_ssa(32767); got != -1 { + fmt.Printf("div_int16 32767/-32767 = %d, wanted -1\n", got) + failed = true + } + + if got := div_Neg1_int16_ssa(-32768); got != 0 { + fmt.Printf("div_int16 -1/-32768 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int16_Neg1_ssa(-32768); got != -32768 { + fmt.Printf("div_int16 -32768/-1 = %d, wanted -32768\n", got) + failed = true + } + + if got := div_Neg1_int16_ssa(-32767); got != 0 { + fmt.Printf("div_int16 -1/-32767 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int16_Neg1_ssa(-32767); got != 32767 { + fmt.Printf("div_int16 -32767/-1 = %d, wanted 32767\n", got) + failed = true + } + + if got := div_Neg1_int16_ssa(-1); got != 1 { + fmt.Printf("div_int16 -1/-1 = %d, wanted 1\n", got) + failed = true + } + + if got := div_int16_Neg1_ssa(-1); got != 1 { + fmt.Printf("div_int16 -1/-1 = %d, wanted 1\n", got) + failed = true + } + + if got := div_int16_Neg1_ssa(0); got != 0 { + fmt.Printf("div_int16 0/-1 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg1_int16_ssa(1); got != -1 { + fmt.Printf("div_int16 -1/1 = %d, wanted -1\n", got) + failed = true + } + + if got := div_int16_Neg1_ssa(1); got != -1 { + fmt.Printf("div_int16 1/-1 = %d, wanted -1\n", got) + failed = true + } + + if got := div_Neg1_int16_ssa(32766); got != 0 { + fmt.Printf("div_int16 -1/32766 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int16_Neg1_ssa(32766); got != -32766 { + fmt.Printf("div_int16 32766/-1 = %d, wanted -32766\n", got) + failed = true + } + + if got := div_Neg1_int16_ssa(32767); got != 0 { + fmt.Printf("div_int16 -1/32767 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int16_Neg1_ssa(32767); got != -32767 { + fmt.Printf("div_int16 32767/-1 = %d, wanted -32767\n", got) + failed = true + } + + if got := div_0_int16_ssa(-32768); got != 0 { + fmt.Printf("div_int16 0/-32768 = %d, wanted 0\n", got) + failed = true + } + + if got := div_0_int16_ssa(-32767); got != 0 { + fmt.Printf("div_int16 0/-32767 = %d, wanted 0\n", got) + failed = true + } + + if got := div_0_int16_ssa(-1); got != 0 { + fmt.Printf("div_int16 0/-1 = %d, wanted 0\n", got) + failed = true + } + + if got := div_0_int16_ssa(1); got != 0 { + fmt.Printf("div_int16 0/1 = %d, wanted 0\n", got) + failed = true + } + + if got := div_0_int16_ssa(32766); got != 0 { + fmt.Printf("div_int16 0/32766 = %d, wanted 0\n", got) + failed = true + } + + if got := div_0_int16_ssa(32767); got != 0 { + fmt.Printf("div_int16 0/32767 = %d, wanted 0\n", got) + failed = true + } + + if got := div_1_int16_ssa(-32768); got != 0 { + fmt.Printf("div_int16 1/-32768 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int16_1_ssa(-32768); got != -32768 { + fmt.Printf("div_int16 -32768/1 = %d, wanted -32768\n", got) + failed = true + } + + if got := div_1_int16_ssa(-32767); got != 0 { + fmt.Printf("div_int16 1/-32767 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int16_1_ssa(-32767); got != -32767 { + fmt.Printf("div_int16 -32767/1 = %d, wanted -32767\n", got) + failed = true + } + + if got := div_1_int16_ssa(-1); got != -1 { + fmt.Printf("div_int16 1/-1 = %d, wanted -1\n", got) + failed = true + } + + if got := div_int16_1_ssa(-1); got != -1 { + fmt.Printf("div_int16 -1/1 = %d, wanted -1\n", got) + failed = true + } + + if got := div_int16_1_ssa(0); got != 0 { + fmt.Printf("div_int16 0/1 = %d, wanted 0\n", got) + failed = true + } + + if got := div_1_int16_ssa(1); got != 1 { + fmt.Printf("div_int16 1/1 = %d, wanted 1\n", got) failed = true } @@ -3344,633 +9626,3043 @@ func main() { failed = true } - if got := div_1_int16_ssa(32766); got != 0 { - fmt.Printf("div_int16 1/32766 = %d, wanted 0\n", got) + if got := div_1_int16_ssa(32766); got != 0 { + fmt.Printf("div_int16 1/32766 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int16_1_ssa(32766); got != 32766 { + fmt.Printf("div_int16 32766/1 = %d, wanted 32766\n", got) + failed = true + } + + if got := div_1_int16_ssa(32767); got != 0 { + fmt.Printf("div_int16 1/32767 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int16_1_ssa(32767); got != 32767 { + fmt.Printf("div_int16 32767/1 = %d, wanted 32767\n", got) + failed = true + } + + if got := div_32766_int16_ssa(-32768); got != 0 { + fmt.Printf("div_int16 32766/-32768 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int16_32766_ssa(-32768); got != -1 { + fmt.Printf("div_int16 -32768/32766 = %d, wanted -1\n", got) + failed = true + } + + if got := div_32766_int16_ssa(-32767); got != 0 { + fmt.Printf("div_int16 32766/-32767 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int16_32766_ssa(-32767); got != -1 { + fmt.Printf("div_int16 -32767/32766 = %d, wanted -1\n", got) + failed = true + } + + if got := div_32766_int16_ssa(-1); got != -32766 { + fmt.Printf("div_int16 32766/-1 = %d, wanted -32766\n", got) + failed = true + } + + if got := div_int16_32766_ssa(-1); got != 0 { + fmt.Printf("div_int16 -1/32766 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int16_32766_ssa(0); got != 0 { + fmt.Printf("div_int16 0/32766 = %d, wanted 0\n", got) + failed = true + } + + if got := div_32766_int16_ssa(1); got != 32766 { + fmt.Printf("div_int16 32766/1 = %d, wanted 32766\n", got) + failed = true + } + + if got := div_int16_32766_ssa(1); got != 0 { + fmt.Printf("div_int16 1/32766 = %d, wanted 0\n", got) + failed = true + } + + if got := div_32766_int16_ssa(32766); got != 1 { + fmt.Printf("div_int16 32766/32766 = %d, wanted 1\n", got) + failed = true + } + + if got := div_int16_32766_ssa(32766); got != 1 { + fmt.Printf("div_int16 32766/32766 = %d, wanted 1\n", got) + failed = true + } + + if got := div_32766_int16_ssa(32767); got != 0 { + fmt.Printf("div_int16 32766/32767 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int16_32766_ssa(32767); got != 1 { + fmt.Printf("div_int16 32767/32766 = %d, wanted 1\n", got) + failed = true + } + + if got := div_32767_int16_ssa(-32768); got != 0 { + fmt.Printf("div_int16 32767/-32768 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int16_32767_ssa(-32768); got != -1 { + fmt.Printf("div_int16 -32768/32767 = %d, wanted -1\n", got) + failed = true + } + + if got := div_32767_int16_ssa(-32767); got != -1 { + fmt.Printf("div_int16 32767/-32767 = %d, wanted -1\n", got) + failed = true + } + + if got := div_int16_32767_ssa(-32767); got != -1 { + fmt.Printf("div_int16 -32767/32767 = %d, wanted -1\n", got) + failed = true + } + + if got := div_32767_int16_ssa(-1); got != -32767 { + fmt.Printf("div_int16 32767/-1 = %d, wanted -32767\n", got) + failed = true + } + + if got := div_int16_32767_ssa(-1); got != 0 { + fmt.Printf("div_int16 -1/32767 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int16_32767_ssa(0); got != 0 { + fmt.Printf("div_int16 0/32767 = %d, wanted 0\n", got) + failed = true + } + + if got := div_32767_int16_ssa(1); got != 32767 { + fmt.Printf("div_int16 32767/1 = %d, wanted 32767\n", got) + failed = true + } + + if got := div_int16_32767_ssa(1); got != 0 { + fmt.Printf("div_int16 1/32767 = %d, wanted 0\n", got) + failed = true + } + + if got := div_32767_int16_ssa(32766); got != 1 { + fmt.Printf("div_int16 32767/32766 = %d, wanted 1\n", got) + failed = true + } + + if got := div_int16_32767_ssa(32766); got != 0 { + fmt.Printf("div_int16 32766/32767 = %d, wanted 0\n", got) + failed = true + } + + if got := div_32767_int16_ssa(32767); got != 1 { + fmt.Printf("div_int16 32767/32767 = %d, wanted 1\n", got) + failed = true + } + + if got := div_int16_32767_ssa(32767); got != 1 { + fmt.Printf("div_int16 32767/32767 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_Neg32768_int16_ssa(-32768); got != 0 { + fmt.Printf("mul_int16 -32768*-32768 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int16_Neg32768_ssa(-32768); got != 0 { + fmt.Printf("mul_int16 -32768*-32768 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_Neg32768_int16_ssa(-32767); got != -32768 { + fmt.Printf("mul_int16 -32768*-32767 = %d, wanted -32768\n", got) + failed = true + } + + if got := mul_int16_Neg32768_ssa(-32767); got != -32768 { + fmt.Printf("mul_int16 -32767*-32768 = %d, wanted -32768\n", got) + failed = true + } + + if got := mul_Neg32768_int16_ssa(-1); got != -32768 { + fmt.Printf("mul_int16 -32768*-1 = %d, wanted -32768\n", got) + failed = true + } + + if got := mul_int16_Neg32768_ssa(-1); got != -32768 { + fmt.Printf("mul_int16 -1*-32768 = %d, wanted -32768\n", got) + failed = true + } + + if got := mul_Neg32768_int16_ssa(0); got != 0 { + fmt.Printf("mul_int16 -32768*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int16_Neg32768_ssa(0); got != 0 { + fmt.Printf("mul_int16 0*-32768 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_Neg32768_int16_ssa(1); got != -32768 { + fmt.Printf("mul_int16 -32768*1 = %d, wanted -32768\n", got) + failed = true + } + + if got := mul_int16_Neg32768_ssa(1); got != -32768 { + fmt.Printf("mul_int16 1*-32768 = %d, wanted -32768\n", got) + failed = true + } + + if got := mul_Neg32768_int16_ssa(32766); got != 0 { + fmt.Printf("mul_int16 -32768*32766 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int16_Neg32768_ssa(32766); got != 0 { + fmt.Printf("mul_int16 32766*-32768 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_Neg32768_int16_ssa(32767); got != -32768 { + fmt.Printf("mul_int16 -32768*32767 = %d, wanted -32768\n", got) + failed = true + } + + if got := mul_int16_Neg32768_ssa(32767); got != -32768 { + fmt.Printf("mul_int16 32767*-32768 = %d, wanted -32768\n", got) + failed = true + } + + if got := mul_Neg32767_int16_ssa(-32768); got != -32768 { + fmt.Printf("mul_int16 -32767*-32768 = %d, wanted -32768\n", got) + failed = true + } + + if got := mul_int16_Neg32767_ssa(-32768); got != -32768 { + fmt.Printf("mul_int16 -32768*-32767 = %d, wanted -32768\n", got) + failed = true + } + + if got := mul_Neg32767_int16_ssa(-32767); got != 1 { + fmt.Printf("mul_int16 -32767*-32767 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_int16_Neg32767_ssa(-32767); got != 1 { + fmt.Printf("mul_int16 -32767*-32767 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_Neg32767_int16_ssa(-1); got != 32767 { + fmt.Printf("mul_int16 -32767*-1 = %d, wanted 32767\n", got) + failed = true + } + + if got := mul_int16_Neg32767_ssa(-1); got != 32767 { + fmt.Printf("mul_int16 -1*-32767 = %d, wanted 32767\n", got) + failed = true + } + + if got := mul_Neg32767_int16_ssa(0); got != 0 { + fmt.Printf("mul_int16 -32767*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int16_Neg32767_ssa(0); got != 0 { + fmt.Printf("mul_int16 0*-32767 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_Neg32767_int16_ssa(1); got != -32767 { + fmt.Printf("mul_int16 -32767*1 = %d, wanted -32767\n", got) + failed = true + } + + if got := mul_int16_Neg32767_ssa(1); got != -32767 { + fmt.Printf("mul_int16 1*-32767 = %d, wanted -32767\n", got) + failed = true + } + + if got := mul_Neg32767_int16_ssa(32766); got != 32766 { + fmt.Printf("mul_int16 -32767*32766 = %d, wanted 32766\n", got) + failed = true + } + + if got := mul_int16_Neg32767_ssa(32766); got != 32766 { + fmt.Printf("mul_int16 32766*-32767 = %d, wanted 32766\n", got) + failed = true + } + + if got := mul_Neg32767_int16_ssa(32767); got != -1 { + fmt.Printf("mul_int16 -32767*32767 = %d, wanted -1\n", got) + failed = true + } + + if got := mul_int16_Neg32767_ssa(32767); got != -1 { + fmt.Printf("mul_int16 32767*-32767 = %d, wanted -1\n", got) + failed = true + } + + if got := mul_Neg1_int16_ssa(-32768); got != -32768 { + fmt.Printf("mul_int16 -1*-32768 = %d, wanted -32768\n", got) + failed = true + } + + if got := mul_int16_Neg1_ssa(-32768); got != -32768 { + fmt.Printf("mul_int16 -32768*-1 = %d, wanted -32768\n", got) + failed = true + } + + if got := mul_Neg1_int16_ssa(-32767); got != 32767 { + fmt.Printf("mul_int16 -1*-32767 = %d, wanted 32767\n", got) + failed = true + } + + if got := mul_int16_Neg1_ssa(-32767); got != 32767 { + fmt.Printf("mul_int16 -32767*-1 = %d, wanted 32767\n", got) + failed = true + } + + if got := mul_Neg1_int16_ssa(-1); got != 1 { + fmt.Printf("mul_int16 -1*-1 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_int16_Neg1_ssa(-1); got != 1 { + fmt.Printf("mul_int16 -1*-1 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_Neg1_int16_ssa(0); got != 0 { + fmt.Printf("mul_int16 -1*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int16_Neg1_ssa(0); got != 0 { + fmt.Printf("mul_int16 0*-1 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_Neg1_int16_ssa(1); got != -1 { + fmt.Printf("mul_int16 -1*1 = %d, wanted -1\n", got) + failed = true + } + + if got := mul_int16_Neg1_ssa(1); got != -1 { + fmt.Printf("mul_int16 1*-1 = %d, wanted -1\n", got) + failed = true + } + + if got := mul_Neg1_int16_ssa(32766); got != -32766 { + fmt.Printf("mul_int16 -1*32766 = %d, wanted -32766\n", got) + failed = true + } + + if got := mul_int16_Neg1_ssa(32766); got != -32766 { + fmt.Printf("mul_int16 32766*-1 = %d, wanted -32766\n", got) + failed = true + } + + if got := mul_Neg1_int16_ssa(32767); got != -32767 { + fmt.Printf("mul_int16 -1*32767 = %d, wanted -32767\n", got) + failed = true + } + + if got := mul_int16_Neg1_ssa(32767); got != -32767 { + fmt.Printf("mul_int16 32767*-1 = %d, wanted -32767\n", got) + failed = true + } + + if got := mul_0_int16_ssa(-32768); got != 0 { + fmt.Printf("mul_int16 0*-32768 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int16_0_ssa(-32768); got != 0 { + fmt.Printf("mul_int16 -32768*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_0_int16_ssa(-32767); got != 0 { + fmt.Printf("mul_int16 0*-32767 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int16_0_ssa(-32767); got != 0 { + fmt.Printf("mul_int16 -32767*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_0_int16_ssa(-1); got != 0 { + fmt.Printf("mul_int16 0*-1 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int16_0_ssa(-1); got != 0 { + fmt.Printf("mul_int16 -1*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_0_int16_ssa(0); got != 0 { + fmt.Printf("mul_int16 0*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int16_0_ssa(0); got != 0 { + fmt.Printf("mul_int16 0*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_0_int16_ssa(1); got != 0 { + fmt.Printf("mul_int16 0*1 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int16_0_ssa(1); got != 0 { + fmt.Printf("mul_int16 1*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_0_int16_ssa(32766); got != 0 { + fmt.Printf("mul_int16 0*32766 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int16_0_ssa(32766); got != 0 { + fmt.Printf("mul_int16 32766*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_0_int16_ssa(32767); got != 0 { + fmt.Printf("mul_int16 0*32767 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int16_0_ssa(32767); got != 0 { + fmt.Printf("mul_int16 32767*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_1_int16_ssa(-32768); got != -32768 { + fmt.Printf("mul_int16 1*-32768 = %d, wanted -32768\n", got) + failed = true + } + + if got := mul_int16_1_ssa(-32768); got != -32768 { + fmt.Printf("mul_int16 -32768*1 = %d, wanted -32768\n", got) + failed = true + } + + if got := mul_1_int16_ssa(-32767); got != -32767 { + fmt.Printf("mul_int16 1*-32767 = %d, wanted -32767\n", got) + failed = true + } + + if got := mul_int16_1_ssa(-32767); got != -32767 { + fmt.Printf("mul_int16 -32767*1 = %d, wanted -32767\n", got) + failed = true + } + + if got := mul_1_int16_ssa(-1); got != -1 { + fmt.Printf("mul_int16 1*-1 = %d, wanted -1\n", got) + failed = true + } + + if got := mul_int16_1_ssa(-1); got != -1 { + fmt.Printf("mul_int16 -1*1 = %d, wanted -1\n", got) + failed = true + } + + if got := mul_1_int16_ssa(0); got != 0 { + fmt.Printf("mul_int16 1*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int16_1_ssa(0); got != 0 { + fmt.Printf("mul_int16 0*1 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_1_int16_ssa(1); got != 1 { + fmt.Printf("mul_int16 1*1 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_int16_1_ssa(1); got != 1 { + fmt.Printf("mul_int16 1*1 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_1_int16_ssa(32766); got != 32766 { + fmt.Printf("mul_int16 1*32766 = %d, wanted 32766\n", got) + failed = true + } + + if got := mul_int16_1_ssa(32766); got != 32766 { + fmt.Printf("mul_int16 32766*1 = %d, wanted 32766\n", got) + failed = true + } + + if got := mul_1_int16_ssa(32767); got != 32767 { + fmt.Printf("mul_int16 1*32767 = %d, wanted 32767\n", got) + failed = true + } + + if got := mul_int16_1_ssa(32767); got != 32767 { + fmt.Printf("mul_int16 32767*1 = %d, wanted 32767\n", got) + failed = true + } + + if got := mul_32766_int16_ssa(-32768); got != 0 { + fmt.Printf("mul_int16 32766*-32768 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int16_32766_ssa(-32768); got != 0 { + fmt.Printf("mul_int16 -32768*32766 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_32766_int16_ssa(-32767); got != 32766 { + fmt.Printf("mul_int16 32766*-32767 = %d, wanted 32766\n", got) + failed = true + } + + if got := mul_int16_32766_ssa(-32767); got != 32766 { + fmt.Printf("mul_int16 -32767*32766 = %d, wanted 32766\n", got) + failed = true + } + + if got := mul_32766_int16_ssa(-1); got != -32766 { + fmt.Printf("mul_int16 32766*-1 = %d, wanted -32766\n", got) + failed = true + } + + if got := mul_int16_32766_ssa(-1); got != -32766 { + fmt.Printf("mul_int16 -1*32766 = %d, wanted -32766\n", got) + failed = true + } + + if got := mul_32766_int16_ssa(0); got != 0 { + fmt.Printf("mul_int16 32766*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int16_32766_ssa(0); got != 0 { + fmt.Printf("mul_int16 0*32766 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_32766_int16_ssa(1); got != 32766 { + fmt.Printf("mul_int16 32766*1 = %d, wanted 32766\n", got) + failed = true + } + + if got := mul_int16_32766_ssa(1); got != 32766 { + fmt.Printf("mul_int16 1*32766 = %d, wanted 32766\n", got) + failed = true + } + + if got := mul_32766_int16_ssa(32766); got != 4 { + fmt.Printf("mul_int16 32766*32766 = %d, wanted 4\n", got) + failed = true + } + + if got := mul_int16_32766_ssa(32766); got != 4 { + fmt.Printf("mul_int16 32766*32766 = %d, wanted 4\n", got) + failed = true + } + + if got := mul_32766_int16_ssa(32767); got != -32766 { + fmt.Printf("mul_int16 32766*32767 = %d, wanted -32766\n", got) + failed = true + } + + if got := mul_int16_32766_ssa(32767); got != -32766 { + fmt.Printf("mul_int16 32767*32766 = %d, wanted -32766\n", got) + failed = true + } + + if got := mul_32767_int16_ssa(-32768); got != -32768 { + fmt.Printf("mul_int16 32767*-32768 = %d, wanted -32768\n", got) + failed = true + } + + if got := mul_int16_32767_ssa(-32768); got != -32768 { + fmt.Printf("mul_int16 -32768*32767 = %d, wanted -32768\n", got) + failed = true + } + + if got := mul_32767_int16_ssa(-32767); got != -1 { + fmt.Printf("mul_int16 32767*-32767 = %d, wanted -1\n", got) + failed = true + } + + if got := mul_int16_32767_ssa(-32767); got != -1 { + fmt.Printf("mul_int16 -32767*32767 = %d, wanted -1\n", got) + failed = true + } + + if got := mul_32767_int16_ssa(-1); got != -32767 { + fmt.Printf("mul_int16 32767*-1 = %d, wanted -32767\n", got) + failed = true + } + + if got := mul_int16_32767_ssa(-1); got != -32767 { + fmt.Printf("mul_int16 -1*32767 = %d, wanted -32767\n", got) + failed = true + } + + if got := mul_32767_int16_ssa(0); got != 0 { + fmt.Printf("mul_int16 32767*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_int16_32767_ssa(0); got != 0 { + fmt.Printf("mul_int16 0*32767 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_32767_int16_ssa(1); got != 32767 { + fmt.Printf("mul_int16 32767*1 = %d, wanted 32767\n", got) + failed = true + } + + if got := mul_int16_32767_ssa(1); got != 32767 { + fmt.Printf("mul_int16 1*32767 = %d, wanted 32767\n", got) + failed = true + } + + if got := mul_32767_int16_ssa(32766); got != -32766 { + fmt.Printf("mul_int16 32767*32766 = %d, wanted -32766\n", got) + failed = true + } + + if got := mul_int16_32767_ssa(32766); got != -32766 { + fmt.Printf("mul_int16 32766*32767 = %d, wanted -32766\n", got) + failed = true + } + + if got := mul_32767_int16_ssa(32767); got != 1 { + fmt.Printf("mul_int16 32767*32767 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_int16_32767_ssa(32767); got != 1 { + fmt.Printf("mul_int16 32767*32767 = %d, wanted 1\n", got) + failed = true + } + + if got := add_0_uint8_ssa(0); got != 0 { + fmt.Printf("add_uint8 0+0 = %d, wanted 0\n", got) + failed = true + } + + if got := add_uint8_0_ssa(0); got != 0 { + fmt.Printf("add_uint8 0+0 = %d, wanted 0\n", got) + failed = true + } + + if got := add_0_uint8_ssa(1); got != 1 { + fmt.Printf("add_uint8 0+1 = %d, wanted 1\n", got) + failed = true + } + + if got := add_uint8_0_ssa(1); got != 1 { + fmt.Printf("add_uint8 1+0 = %d, wanted 1\n", got) + failed = true + } + + if got := add_0_uint8_ssa(255); got != 255 { + fmt.Printf("add_uint8 0+255 = %d, wanted 255\n", got) + failed = true + } + + if got := add_uint8_0_ssa(255); got != 255 { + fmt.Printf("add_uint8 255+0 = %d, wanted 255\n", got) + failed = true + } + + if got := add_1_uint8_ssa(0); got != 1 { + fmt.Printf("add_uint8 1+0 = %d, wanted 1\n", got) + failed = true + } + + if got := add_uint8_1_ssa(0); got != 1 { + fmt.Printf("add_uint8 0+1 = %d, wanted 1\n", got) + failed = true + } + + if got := add_1_uint8_ssa(1); got != 2 { + fmt.Printf("add_uint8 1+1 = %d, wanted 2\n", got) + failed = true + } + + if got := add_uint8_1_ssa(1); got != 2 { + fmt.Printf("add_uint8 1+1 = %d, wanted 2\n", got) + failed = true + } + + if got := add_1_uint8_ssa(255); got != 0 { + fmt.Printf("add_uint8 1+255 = %d, wanted 0\n", got) + failed = true + } + + if got := add_uint8_1_ssa(255); got != 0 { + fmt.Printf("add_uint8 255+1 = %d, wanted 0\n", got) + failed = true + } + + if got := add_255_uint8_ssa(0); got != 255 { + fmt.Printf("add_uint8 255+0 = %d, wanted 255\n", got) + failed = true + } + + if got := add_uint8_255_ssa(0); got != 255 { + fmt.Printf("add_uint8 0+255 = %d, wanted 255\n", got) + failed = true + } + + if got := add_255_uint8_ssa(1); got != 0 { + fmt.Printf("add_uint8 255+1 = %d, wanted 0\n", got) + failed = true + } + + if got := add_uint8_255_ssa(1); got != 0 { + fmt.Printf("add_uint8 1+255 = %d, wanted 0\n", got) + failed = true + } + + if got := add_255_uint8_ssa(255); got != 254 { + fmt.Printf("add_uint8 255+255 = %d, wanted 254\n", got) + failed = true + } + + if got := add_uint8_255_ssa(255); got != 254 { + fmt.Printf("add_uint8 255+255 = %d, wanted 254\n", got) + failed = true + } + + if got := sub_0_uint8_ssa(0); got != 0 { + fmt.Printf("sub_uint8 0-0 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_uint8_0_ssa(0); got != 0 { + fmt.Printf("sub_uint8 0-0 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_0_uint8_ssa(1); got != 255 { + fmt.Printf("sub_uint8 0-1 = %d, wanted 255\n", got) + failed = true + } + + if got := sub_uint8_0_ssa(1); got != 1 { + fmt.Printf("sub_uint8 1-0 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_0_uint8_ssa(255); got != 1 { + fmt.Printf("sub_uint8 0-255 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_uint8_0_ssa(255); got != 255 { + fmt.Printf("sub_uint8 255-0 = %d, wanted 255\n", got) + failed = true + } + + if got := sub_1_uint8_ssa(0); got != 1 { + fmt.Printf("sub_uint8 1-0 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_uint8_1_ssa(0); got != 255 { + fmt.Printf("sub_uint8 0-1 = %d, wanted 255\n", got) + failed = true + } + + if got := sub_1_uint8_ssa(1); got != 0 { + fmt.Printf("sub_uint8 1-1 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_uint8_1_ssa(1); got != 0 { + fmt.Printf("sub_uint8 1-1 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_1_uint8_ssa(255); got != 2 { + fmt.Printf("sub_uint8 1-255 = %d, wanted 2\n", got) + failed = true + } + + if got := sub_uint8_1_ssa(255); got != 254 { + fmt.Printf("sub_uint8 255-1 = %d, wanted 254\n", got) + failed = true + } + + if got := sub_255_uint8_ssa(0); got != 255 { + fmt.Printf("sub_uint8 255-0 = %d, wanted 255\n", got) + failed = true + } + + if got := sub_uint8_255_ssa(0); got != 1 { + fmt.Printf("sub_uint8 0-255 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_255_uint8_ssa(1); got != 254 { + fmt.Printf("sub_uint8 255-1 = %d, wanted 254\n", got) + failed = true + } + + if got := sub_uint8_255_ssa(1); got != 2 { + fmt.Printf("sub_uint8 1-255 = %d, wanted 2\n", got) + failed = true + } + + if got := sub_255_uint8_ssa(255); got != 0 { + fmt.Printf("sub_uint8 255-255 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_uint8_255_ssa(255); got != 0 { + fmt.Printf("sub_uint8 255-255 = %d, wanted 0\n", got) + failed = true + } + + if got := div_0_uint8_ssa(1); got != 0 { + fmt.Printf("div_uint8 0/1 = %d, wanted 0\n", got) + failed = true + } + + if got := div_0_uint8_ssa(255); got != 0 { + fmt.Printf("div_uint8 0/255 = %d, wanted 0\n", got) + failed = true + } + + if got := div_uint8_1_ssa(0); got != 0 { + fmt.Printf("div_uint8 0/1 = %d, wanted 0\n", got) + failed = true + } + + if got := div_1_uint8_ssa(1); got != 1 { + fmt.Printf("div_uint8 1/1 = %d, wanted 1\n", got) + failed = true + } + + if got := div_uint8_1_ssa(1); got != 1 { + fmt.Printf("div_uint8 1/1 = %d, wanted 1\n", got) + failed = true + } + + if got := div_1_uint8_ssa(255); got != 0 { + fmt.Printf("div_uint8 1/255 = %d, wanted 0\n", got) + failed = true + } + + if got := div_uint8_1_ssa(255); got != 255 { + fmt.Printf("div_uint8 255/1 = %d, wanted 255\n", got) + failed = true + } + + if got := div_uint8_255_ssa(0); got != 0 { + fmt.Printf("div_uint8 0/255 = %d, wanted 0\n", got) + failed = true + } + + if got := div_255_uint8_ssa(1); got != 255 { + fmt.Printf("div_uint8 255/1 = %d, wanted 255\n", got) + failed = true + } + + if got := div_uint8_255_ssa(1); got != 0 { + fmt.Printf("div_uint8 1/255 = %d, wanted 0\n", got) + failed = true + } + + if got := div_255_uint8_ssa(255); got != 1 { + fmt.Printf("div_uint8 255/255 = %d, wanted 1\n", got) + failed = true + } + + if got := div_uint8_255_ssa(255); got != 1 { + fmt.Printf("div_uint8 255/255 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_0_uint8_ssa(0); got != 0 { + fmt.Printf("mul_uint8 0*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_uint8_0_ssa(0); got != 0 { + fmt.Printf("mul_uint8 0*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_0_uint8_ssa(1); got != 0 { + fmt.Printf("mul_uint8 0*1 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_uint8_0_ssa(1); got != 0 { + fmt.Printf("mul_uint8 1*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_0_uint8_ssa(255); got != 0 { + fmt.Printf("mul_uint8 0*255 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_uint8_0_ssa(255); got != 0 { + fmt.Printf("mul_uint8 255*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_1_uint8_ssa(0); got != 0 { + fmt.Printf("mul_uint8 1*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_uint8_1_ssa(0); got != 0 { + fmt.Printf("mul_uint8 0*1 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_1_uint8_ssa(1); got != 1 { + fmt.Printf("mul_uint8 1*1 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_uint8_1_ssa(1); got != 1 { + fmt.Printf("mul_uint8 1*1 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_1_uint8_ssa(255); got != 255 { + fmt.Printf("mul_uint8 1*255 = %d, wanted 255\n", got) + failed = true + } + + if got := mul_uint8_1_ssa(255); got != 255 { + fmt.Printf("mul_uint8 255*1 = %d, wanted 255\n", got) + failed = true + } + + if got := mul_255_uint8_ssa(0); got != 0 { + fmt.Printf("mul_uint8 255*0 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_uint8_255_ssa(0); got != 0 { + fmt.Printf("mul_uint8 0*255 = %d, wanted 0\n", got) + failed = true + } + + if got := mul_255_uint8_ssa(1); got != 255 { + fmt.Printf("mul_uint8 255*1 = %d, wanted 255\n", got) + failed = true + } + + if got := mul_uint8_255_ssa(1); got != 255 { + fmt.Printf("mul_uint8 1*255 = %d, wanted 255\n", got) + failed = true + } + + if got := mul_255_uint8_ssa(255); got != 1 { + fmt.Printf("mul_uint8 255*255 = %d, wanted 1\n", got) + failed = true + } + + if got := mul_uint8_255_ssa(255); got != 1 { + fmt.Printf("mul_uint8 255*255 = %d, wanted 1\n", got) + failed = true + } + + if got := lsh_0_uint8_ssa(0); got != 0 { + fmt.Printf("lsh_uint8 0<<0 = %d, wanted 0\n", got) + failed = true + } + + if got := lsh_uint8_0_ssa(0); got != 0 { + fmt.Printf("lsh_uint8 0<<0 = %d, wanted 0\n", got) + failed = true + } + + if got := lsh_0_uint8_ssa(1); got != 0 { + fmt.Printf("lsh_uint8 0<<1 = %d, wanted 0\n", got) + failed = true + } + + if got := lsh_uint8_0_ssa(1); got != 1 { + fmt.Printf("lsh_uint8 1<<0 = %d, wanted 1\n", got) + failed = true + } + + if got := lsh_0_uint8_ssa(255); got != 0 { + fmt.Printf("lsh_uint8 0<<255 = %d, wanted 0\n", got) + failed = true + } + + if got := lsh_uint8_0_ssa(255); got != 255 { + fmt.Printf("lsh_uint8 255<<0 = %d, wanted 255\n", got) + failed = true + } + + if got := lsh_1_uint8_ssa(0); got != 1 { + fmt.Printf("lsh_uint8 1<<0 = %d, wanted 1\n", got) + failed = true + } + + if got := lsh_uint8_1_ssa(0); got != 0 { + fmt.Printf("lsh_uint8 0<<1 = %d, wanted 0\n", got) + failed = true + } + + if got := lsh_1_uint8_ssa(1); got != 2 { + fmt.Printf("lsh_uint8 1<<1 = %d, wanted 2\n", got) + failed = true + } + + if got := lsh_uint8_1_ssa(1); got != 2 { + fmt.Printf("lsh_uint8 1<<1 = %d, wanted 2\n", got) + failed = true + } + + if got := lsh_1_uint8_ssa(255); got != 0 { + fmt.Printf("lsh_uint8 1<<255 = %d, wanted 0\n", got) + failed = true + } + + if got := lsh_uint8_1_ssa(255); got != 254 { + fmt.Printf("lsh_uint8 255<<1 = %d, wanted 254\n", got) + failed = true + } + + if got := lsh_255_uint8_ssa(0); got != 255 { + fmt.Printf("lsh_uint8 255<<0 = %d, wanted 255\n", got) + failed = true + } + + if got := lsh_uint8_255_ssa(0); got != 0 { + fmt.Printf("lsh_uint8 0<<255 = %d, wanted 0\n", got) + failed = true + } + + if got := lsh_255_uint8_ssa(1); got != 254 { + fmt.Printf("lsh_uint8 255<<1 = %d, wanted 254\n", got) + failed = true + } + + if got := lsh_uint8_255_ssa(1); got != 0 { + fmt.Printf("lsh_uint8 1<<255 = %d, wanted 0\n", got) + failed = true + } + + if got := lsh_255_uint8_ssa(255); got != 0 { + fmt.Printf("lsh_uint8 255<<255 = %d, wanted 0\n", got) + failed = true + } + + if got := lsh_uint8_255_ssa(255); got != 0 { + fmt.Printf("lsh_uint8 255<<255 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_0_uint8_ssa(0); got != 0 { + fmt.Printf("rsh_uint8 0>>0 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_uint8_0_ssa(0); got != 0 { + fmt.Printf("rsh_uint8 0>>0 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_0_uint8_ssa(1); got != 0 { + fmt.Printf("rsh_uint8 0>>1 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_uint8_0_ssa(1); got != 1 { + fmt.Printf("rsh_uint8 1>>0 = %d, wanted 1\n", got) + failed = true + } + + if got := rsh_0_uint8_ssa(255); got != 0 { + fmt.Printf("rsh_uint8 0>>255 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_uint8_0_ssa(255); got != 255 { + fmt.Printf("rsh_uint8 255>>0 = %d, wanted 255\n", got) + failed = true + } + + if got := rsh_1_uint8_ssa(0); got != 1 { + fmt.Printf("rsh_uint8 1>>0 = %d, wanted 1\n", got) + failed = true + } + + if got := rsh_uint8_1_ssa(0); got != 0 { + fmt.Printf("rsh_uint8 0>>1 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_1_uint8_ssa(1); got != 0 { + fmt.Printf("rsh_uint8 1>>1 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_uint8_1_ssa(1); got != 0 { + fmt.Printf("rsh_uint8 1>>1 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_1_uint8_ssa(255); got != 0 { + fmt.Printf("rsh_uint8 1>>255 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_uint8_1_ssa(255); got != 127 { + fmt.Printf("rsh_uint8 255>>1 = %d, wanted 127\n", got) + failed = true + } + + if got := rsh_255_uint8_ssa(0); got != 255 { + fmt.Printf("rsh_uint8 255>>0 = %d, wanted 255\n", got) + failed = true + } + + if got := rsh_uint8_255_ssa(0); got != 0 { + fmt.Printf("rsh_uint8 0>>255 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_255_uint8_ssa(1); got != 127 { + fmt.Printf("rsh_uint8 255>>1 = %d, wanted 127\n", got) + failed = true + } + + if got := rsh_uint8_255_ssa(1); got != 0 { + fmt.Printf("rsh_uint8 1>>255 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_255_uint8_ssa(255); got != 0 { + fmt.Printf("rsh_uint8 255>>255 = %d, wanted 0\n", got) + failed = true + } + + if got := rsh_uint8_255_ssa(255); got != 0 { + fmt.Printf("rsh_uint8 255>>255 = %d, wanted 0\n", got) + failed = true + } + + if got := add_Neg128_int8_ssa(-128); got != 0 { + fmt.Printf("add_int8 -128+-128 = %d, wanted 0\n", got) + failed = true + } + + if got := add_int8_Neg128_ssa(-128); got != 0 { + fmt.Printf("add_int8 -128+-128 = %d, wanted 0\n", got) + failed = true + } + + if got := add_Neg128_int8_ssa(-127); got != 1 { + fmt.Printf("add_int8 -128+-127 = %d, wanted 1\n", got) + failed = true + } + + if got := add_int8_Neg128_ssa(-127); got != 1 { + fmt.Printf("add_int8 -127+-128 = %d, wanted 1\n", got) + failed = true + } + + if got := add_Neg128_int8_ssa(-1); got != 127 { + fmt.Printf("add_int8 -128+-1 = %d, wanted 127\n", got) + failed = true + } + + if got := add_int8_Neg128_ssa(-1); got != 127 { + fmt.Printf("add_int8 -1+-128 = %d, wanted 127\n", got) + failed = true + } + + if got := add_Neg128_int8_ssa(0); got != -128 { + fmt.Printf("add_int8 -128+0 = %d, wanted -128\n", got) + failed = true + } + + if got := add_int8_Neg128_ssa(0); got != -128 { + fmt.Printf("add_int8 0+-128 = %d, wanted -128\n", got) + failed = true + } + + if got := add_Neg128_int8_ssa(1); got != -127 { + fmt.Printf("add_int8 -128+1 = %d, wanted -127\n", got) + failed = true + } + + if got := add_int8_Neg128_ssa(1); got != -127 { + fmt.Printf("add_int8 1+-128 = %d, wanted -127\n", got) + failed = true + } + + if got := add_Neg128_int8_ssa(126); got != -2 { + fmt.Printf("add_int8 -128+126 = %d, wanted -2\n", got) + failed = true + } + + if got := add_int8_Neg128_ssa(126); got != -2 { + fmt.Printf("add_int8 126+-128 = %d, wanted -2\n", got) + failed = true + } + + if got := add_Neg128_int8_ssa(127); got != -1 { + fmt.Printf("add_int8 -128+127 = %d, wanted -1\n", got) + failed = true + } + + if got := add_int8_Neg128_ssa(127); got != -1 { + fmt.Printf("add_int8 127+-128 = %d, wanted -1\n", got) + failed = true + } + + if got := add_Neg127_int8_ssa(-128); got != 1 { + fmt.Printf("add_int8 -127+-128 = %d, wanted 1\n", got) + failed = true + } + + if got := add_int8_Neg127_ssa(-128); got != 1 { + fmt.Printf("add_int8 -128+-127 = %d, wanted 1\n", got) + failed = true + } + + if got := add_Neg127_int8_ssa(-127); got != 2 { + fmt.Printf("add_int8 -127+-127 = %d, wanted 2\n", got) + failed = true + } + + if got := add_int8_Neg127_ssa(-127); got != 2 { + fmt.Printf("add_int8 -127+-127 = %d, wanted 2\n", got) + failed = true + } + + if got := add_Neg127_int8_ssa(-1); got != -128 { + fmt.Printf("add_int8 -127+-1 = %d, wanted -128\n", got) + failed = true + } + + if got := add_int8_Neg127_ssa(-1); got != -128 { + fmt.Printf("add_int8 -1+-127 = %d, wanted -128\n", got) + failed = true + } + + if got := add_Neg127_int8_ssa(0); got != -127 { + fmt.Printf("add_int8 -127+0 = %d, wanted -127\n", got) + failed = true + } + + if got := add_int8_Neg127_ssa(0); got != -127 { + fmt.Printf("add_int8 0+-127 = %d, wanted -127\n", got) + failed = true + } + + if got := add_Neg127_int8_ssa(1); got != -126 { + fmt.Printf("add_int8 -127+1 = %d, wanted -126\n", got) + failed = true + } + + if got := add_int8_Neg127_ssa(1); got != -126 { + fmt.Printf("add_int8 1+-127 = %d, wanted -126\n", got) + failed = true + } + + if got := add_Neg127_int8_ssa(126); got != -1 { + fmt.Printf("add_int8 -127+126 = %d, wanted -1\n", got) + failed = true + } + + if got := add_int8_Neg127_ssa(126); got != -1 { + fmt.Printf("add_int8 126+-127 = %d, wanted -1\n", got) + failed = true + } + + if got := add_Neg127_int8_ssa(127); got != 0 { + fmt.Printf("add_int8 -127+127 = %d, wanted 0\n", got) + failed = true + } + + if got := add_int8_Neg127_ssa(127); got != 0 { + fmt.Printf("add_int8 127+-127 = %d, wanted 0\n", got) + failed = true + } + + if got := add_Neg1_int8_ssa(-128); got != 127 { + fmt.Printf("add_int8 -1+-128 = %d, wanted 127\n", got) + failed = true + } + + if got := add_int8_Neg1_ssa(-128); got != 127 { + fmt.Printf("add_int8 -128+-1 = %d, wanted 127\n", got) + failed = true + } + + if got := add_Neg1_int8_ssa(-127); got != -128 { + fmt.Printf("add_int8 -1+-127 = %d, wanted -128\n", got) + failed = true + } + + if got := add_int8_Neg1_ssa(-127); got != -128 { + fmt.Printf("add_int8 -127+-1 = %d, wanted -128\n", got) + failed = true + } + + if got := add_Neg1_int8_ssa(-1); got != -2 { + fmt.Printf("add_int8 -1+-1 = %d, wanted -2\n", got) + failed = true + } + + if got := add_int8_Neg1_ssa(-1); got != -2 { + fmt.Printf("add_int8 -1+-1 = %d, wanted -2\n", got) + failed = true + } + + if got := add_Neg1_int8_ssa(0); got != -1 { + fmt.Printf("add_int8 -1+0 = %d, wanted -1\n", got) + failed = true + } + + if got := add_int8_Neg1_ssa(0); got != -1 { + fmt.Printf("add_int8 0+-1 = %d, wanted -1\n", got) + failed = true + } + + if got := add_Neg1_int8_ssa(1); got != 0 { + fmt.Printf("add_int8 -1+1 = %d, wanted 0\n", got) + failed = true + } + + if got := add_int8_Neg1_ssa(1); got != 0 { + fmt.Printf("add_int8 1+-1 = %d, wanted 0\n", got) + failed = true + } + + if got := add_Neg1_int8_ssa(126); got != 125 { + fmt.Printf("add_int8 -1+126 = %d, wanted 125\n", got) + failed = true + } + + if got := add_int8_Neg1_ssa(126); got != 125 { + fmt.Printf("add_int8 126+-1 = %d, wanted 125\n", got) + failed = true + } + + if got := add_Neg1_int8_ssa(127); got != 126 { + fmt.Printf("add_int8 -1+127 = %d, wanted 126\n", got) + failed = true + } + + if got := add_int8_Neg1_ssa(127); got != 126 { + fmt.Printf("add_int8 127+-1 = %d, wanted 126\n", got) + failed = true + } + + if got := add_0_int8_ssa(-128); got != -128 { + fmt.Printf("add_int8 0+-128 = %d, wanted -128\n", got) + failed = true + } + + if got := add_int8_0_ssa(-128); got != -128 { + fmt.Printf("add_int8 -128+0 = %d, wanted -128\n", got) + failed = true + } + + if got := add_0_int8_ssa(-127); got != -127 { + fmt.Printf("add_int8 0+-127 = %d, wanted -127\n", got) + failed = true + } + + if got := add_int8_0_ssa(-127); got != -127 { + fmt.Printf("add_int8 -127+0 = %d, wanted -127\n", got) + failed = true + } + + if got := add_0_int8_ssa(-1); got != -1 { + fmt.Printf("add_int8 0+-1 = %d, wanted -1\n", got) + failed = true + } + + if got := add_int8_0_ssa(-1); got != -1 { + fmt.Printf("add_int8 -1+0 = %d, wanted -1\n", got) + failed = true + } + + if got := add_0_int8_ssa(0); got != 0 { + fmt.Printf("add_int8 0+0 = %d, wanted 0\n", got) + failed = true + } + + if got := add_int8_0_ssa(0); got != 0 { + fmt.Printf("add_int8 0+0 = %d, wanted 0\n", got) + failed = true + } + + if got := add_0_int8_ssa(1); got != 1 { + fmt.Printf("add_int8 0+1 = %d, wanted 1\n", got) + failed = true + } + + if got := add_int8_0_ssa(1); got != 1 { + fmt.Printf("add_int8 1+0 = %d, wanted 1\n", got) + failed = true + } + + if got := add_0_int8_ssa(126); got != 126 { + fmt.Printf("add_int8 0+126 = %d, wanted 126\n", got) + failed = true + } + + if got := add_int8_0_ssa(126); got != 126 { + fmt.Printf("add_int8 126+0 = %d, wanted 126\n", got) + failed = true + } + + if got := add_0_int8_ssa(127); got != 127 { + fmt.Printf("add_int8 0+127 = %d, wanted 127\n", got) + failed = true + } + + if got := add_int8_0_ssa(127); got != 127 { + fmt.Printf("add_int8 127+0 = %d, wanted 127\n", got) + failed = true + } + + if got := add_1_int8_ssa(-128); got != -127 { + fmt.Printf("add_int8 1+-128 = %d, wanted -127\n", got) + failed = true + } + + if got := add_int8_1_ssa(-128); got != -127 { + fmt.Printf("add_int8 -128+1 = %d, wanted -127\n", got) + failed = true + } + + if got := add_1_int8_ssa(-127); got != -126 { + fmt.Printf("add_int8 1+-127 = %d, wanted -126\n", got) + failed = true + } + + if got := add_int8_1_ssa(-127); got != -126 { + fmt.Printf("add_int8 -127+1 = %d, wanted -126\n", got) + failed = true + } + + if got := add_1_int8_ssa(-1); got != 0 { + fmt.Printf("add_int8 1+-1 = %d, wanted 0\n", got) + failed = true + } + + if got := add_int8_1_ssa(-1); got != 0 { + fmt.Printf("add_int8 -1+1 = %d, wanted 0\n", got) + failed = true + } + + if got := add_1_int8_ssa(0); got != 1 { + fmt.Printf("add_int8 1+0 = %d, wanted 1\n", got) + failed = true + } + + if got := add_int8_1_ssa(0); got != 1 { + fmt.Printf("add_int8 0+1 = %d, wanted 1\n", got) + failed = true + } + + if got := add_1_int8_ssa(1); got != 2 { + fmt.Printf("add_int8 1+1 = %d, wanted 2\n", got) + failed = true + } + + if got := add_int8_1_ssa(1); got != 2 { + fmt.Printf("add_int8 1+1 = %d, wanted 2\n", got) + failed = true + } + + if got := add_1_int8_ssa(126); got != 127 { + fmt.Printf("add_int8 1+126 = %d, wanted 127\n", got) + failed = true + } + + if got := add_int8_1_ssa(126); got != 127 { + fmt.Printf("add_int8 126+1 = %d, wanted 127\n", got) + failed = true + } + + if got := add_1_int8_ssa(127); got != -128 { + fmt.Printf("add_int8 1+127 = %d, wanted -128\n", got) + failed = true + } + + if got := add_int8_1_ssa(127); got != -128 { + fmt.Printf("add_int8 127+1 = %d, wanted -128\n", got) + failed = true + } + + if got := add_126_int8_ssa(-128); got != -2 { + fmt.Printf("add_int8 126+-128 = %d, wanted -2\n", got) + failed = true + } + + if got := add_int8_126_ssa(-128); got != -2 { + fmt.Printf("add_int8 -128+126 = %d, wanted -2\n", got) + failed = true + } + + if got := add_126_int8_ssa(-127); got != -1 { + fmt.Printf("add_int8 126+-127 = %d, wanted -1\n", got) + failed = true + } + + if got := add_int8_126_ssa(-127); got != -1 { + fmt.Printf("add_int8 -127+126 = %d, wanted -1\n", got) + failed = true + } + + if got := add_126_int8_ssa(-1); got != 125 { + fmt.Printf("add_int8 126+-1 = %d, wanted 125\n", got) + failed = true + } + + if got := add_int8_126_ssa(-1); got != 125 { + fmt.Printf("add_int8 -1+126 = %d, wanted 125\n", got) + failed = true + } + + if got := add_126_int8_ssa(0); got != 126 { + fmt.Printf("add_int8 126+0 = %d, wanted 126\n", got) + failed = true + } + + if got := add_int8_126_ssa(0); got != 126 { + fmt.Printf("add_int8 0+126 = %d, wanted 126\n", got) + failed = true + } + + if got := add_126_int8_ssa(1); got != 127 { + fmt.Printf("add_int8 126+1 = %d, wanted 127\n", got) + failed = true + } + + if got := add_int8_126_ssa(1); got != 127 { + fmt.Printf("add_int8 1+126 = %d, wanted 127\n", got) + failed = true + } + + if got := add_126_int8_ssa(126); got != -4 { + fmt.Printf("add_int8 126+126 = %d, wanted -4\n", got) + failed = true + } + + if got := add_int8_126_ssa(126); got != -4 { + fmt.Printf("add_int8 126+126 = %d, wanted -4\n", got) + failed = true + } + + if got := add_126_int8_ssa(127); got != -3 { + fmt.Printf("add_int8 126+127 = %d, wanted -3\n", got) + failed = true + } + + if got := add_int8_126_ssa(127); got != -3 { + fmt.Printf("add_int8 127+126 = %d, wanted -3\n", got) + failed = true + } + + if got := add_127_int8_ssa(-128); got != -1 { + fmt.Printf("add_int8 127+-128 = %d, wanted -1\n", got) + failed = true + } + + if got := add_int8_127_ssa(-128); got != -1 { + fmt.Printf("add_int8 -128+127 = %d, wanted -1\n", got) + failed = true + } + + if got := add_127_int8_ssa(-127); got != 0 { + fmt.Printf("add_int8 127+-127 = %d, wanted 0\n", got) + failed = true + } + + if got := add_int8_127_ssa(-127); got != 0 { + fmt.Printf("add_int8 -127+127 = %d, wanted 0\n", got) + failed = true + } + + if got := add_127_int8_ssa(-1); got != 126 { + fmt.Printf("add_int8 127+-1 = %d, wanted 126\n", got) + failed = true + } + + if got := add_int8_127_ssa(-1); got != 126 { + fmt.Printf("add_int8 -1+127 = %d, wanted 126\n", got) + failed = true + } + + if got := add_127_int8_ssa(0); got != 127 { + fmt.Printf("add_int8 127+0 = %d, wanted 127\n", got) + failed = true + } + + if got := add_int8_127_ssa(0); got != 127 { + fmt.Printf("add_int8 0+127 = %d, wanted 127\n", got) + failed = true + } + + if got := add_127_int8_ssa(1); got != -128 { + fmt.Printf("add_int8 127+1 = %d, wanted -128\n", got) + failed = true + } + + if got := add_int8_127_ssa(1); got != -128 { + fmt.Printf("add_int8 1+127 = %d, wanted -128\n", got) + failed = true + } + + if got := add_127_int8_ssa(126); got != -3 { + fmt.Printf("add_int8 127+126 = %d, wanted -3\n", got) + failed = true + } + + if got := add_int8_127_ssa(126); got != -3 { + fmt.Printf("add_int8 126+127 = %d, wanted -3\n", got) + failed = true + } + + if got := add_127_int8_ssa(127); got != -2 { + fmt.Printf("add_int8 127+127 = %d, wanted -2\n", got) + failed = true + } + + if got := add_int8_127_ssa(127); got != -2 { + fmt.Printf("add_int8 127+127 = %d, wanted -2\n", got) + failed = true + } + + if got := sub_Neg128_int8_ssa(-128); got != 0 { + fmt.Printf("sub_int8 -128--128 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_int8_Neg128_ssa(-128); got != 0 { + fmt.Printf("sub_int8 -128--128 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_Neg128_int8_ssa(-127); got != -1 { + fmt.Printf("sub_int8 -128--127 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_int8_Neg128_ssa(-127); got != 1 { + fmt.Printf("sub_int8 -127--128 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_Neg128_int8_ssa(-1); got != -127 { + fmt.Printf("sub_int8 -128--1 = %d, wanted -127\n", got) + failed = true + } + + if got := sub_int8_Neg128_ssa(-1); got != 127 { + fmt.Printf("sub_int8 -1--128 = %d, wanted 127\n", got) + failed = true + } + + if got := sub_Neg128_int8_ssa(0); got != -128 { + fmt.Printf("sub_int8 -128-0 = %d, wanted -128\n", got) + failed = true + } + + if got := sub_int8_Neg128_ssa(0); got != -128 { + fmt.Printf("sub_int8 0--128 = %d, wanted -128\n", got) + failed = true + } + + if got := sub_Neg128_int8_ssa(1); got != 127 { + fmt.Printf("sub_int8 -128-1 = %d, wanted 127\n", got) + failed = true + } + + if got := sub_int8_Neg128_ssa(1); got != -127 { + fmt.Printf("sub_int8 1--128 = %d, wanted -127\n", got) + failed = true + } + + if got := sub_Neg128_int8_ssa(126); got != 2 { + fmt.Printf("sub_int8 -128-126 = %d, wanted 2\n", got) + failed = true + } + + if got := sub_int8_Neg128_ssa(126); got != -2 { + fmt.Printf("sub_int8 126--128 = %d, wanted -2\n", got) + failed = true + } + + if got := sub_Neg128_int8_ssa(127); got != 1 { + fmt.Printf("sub_int8 -128-127 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_int8_Neg128_ssa(127); got != -1 { + fmt.Printf("sub_int8 127--128 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_Neg127_int8_ssa(-128); got != 1 { + fmt.Printf("sub_int8 -127--128 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_int8_Neg127_ssa(-128); got != -1 { + fmt.Printf("sub_int8 -128--127 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_Neg127_int8_ssa(-127); got != 0 { + fmt.Printf("sub_int8 -127--127 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_int8_Neg127_ssa(-127); got != 0 { + fmt.Printf("sub_int8 -127--127 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_Neg127_int8_ssa(-1); got != -126 { + fmt.Printf("sub_int8 -127--1 = %d, wanted -126\n", got) + failed = true + } + + if got := sub_int8_Neg127_ssa(-1); got != 126 { + fmt.Printf("sub_int8 -1--127 = %d, wanted 126\n", got) + failed = true + } + + if got := sub_Neg127_int8_ssa(0); got != -127 { + fmt.Printf("sub_int8 -127-0 = %d, wanted -127\n", got) + failed = true + } + + if got := sub_int8_Neg127_ssa(0); got != 127 { + fmt.Printf("sub_int8 0--127 = %d, wanted 127\n", got) + failed = true + } + + if got := sub_Neg127_int8_ssa(1); got != -128 { + fmt.Printf("sub_int8 -127-1 = %d, wanted -128\n", got) + failed = true + } + + if got := sub_int8_Neg127_ssa(1); got != -128 { + fmt.Printf("sub_int8 1--127 = %d, wanted -128\n", got) + failed = true + } + + if got := sub_Neg127_int8_ssa(126); got != 3 { + fmt.Printf("sub_int8 -127-126 = %d, wanted 3\n", got) + failed = true + } + + if got := sub_int8_Neg127_ssa(126); got != -3 { + fmt.Printf("sub_int8 126--127 = %d, wanted -3\n", got) + failed = true + } + + if got := sub_Neg127_int8_ssa(127); got != 2 { + fmt.Printf("sub_int8 -127-127 = %d, wanted 2\n", got) + failed = true + } + + if got := sub_int8_Neg127_ssa(127); got != -2 { + fmt.Printf("sub_int8 127--127 = %d, wanted -2\n", got) + failed = true + } + + if got := sub_Neg1_int8_ssa(-128); got != 127 { + fmt.Printf("sub_int8 -1--128 = %d, wanted 127\n", got) + failed = true + } + + if got := sub_int8_Neg1_ssa(-128); got != -127 { + fmt.Printf("sub_int8 -128--1 = %d, wanted -127\n", got) + failed = true + } + + if got := sub_Neg1_int8_ssa(-127); got != 126 { + fmt.Printf("sub_int8 -1--127 = %d, wanted 126\n", got) + failed = true + } + + if got := sub_int8_Neg1_ssa(-127); got != -126 { + fmt.Printf("sub_int8 -127--1 = %d, wanted -126\n", got) + failed = true + } + + if got := sub_Neg1_int8_ssa(-1); got != 0 { + fmt.Printf("sub_int8 -1--1 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_int8_Neg1_ssa(-1); got != 0 { + fmt.Printf("sub_int8 -1--1 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_Neg1_int8_ssa(0); got != -1 { + fmt.Printf("sub_int8 -1-0 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_int8_Neg1_ssa(0); got != 1 { + fmt.Printf("sub_int8 0--1 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_Neg1_int8_ssa(1); got != -2 { + fmt.Printf("sub_int8 -1-1 = %d, wanted -2\n", got) + failed = true + } + + if got := sub_int8_Neg1_ssa(1); got != 2 { + fmt.Printf("sub_int8 1--1 = %d, wanted 2\n", got) + failed = true + } + + if got := sub_Neg1_int8_ssa(126); got != -127 { + fmt.Printf("sub_int8 -1-126 = %d, wanted -127\n", got) + failed = true + } + + if got := sub_int8_Neg1_ssa(126); got != 127 { + fmt.Printf("sub_int8 126--1 = %d, wanted 127\n", got) + failed = true + } + + if got := sub_Neg1_int8_ssa(127); got != -128 { + fmt.Printf("sub_int8 -1-127 = %d, wanted -128\n", got) + failed = true + } + + if got := sub_int8_Neg1_ssa(127); got != -128 { + fmt.Printf("sub_int8 127--1 = %d, wanted -128\n", got) + failed = true + } + + if got := sub_0_int8_ssa(-128); got != -128 { + fmt.Printf("sub_int8 0--128 = %d, wanted -128\n", got) + failed = true + } + + if got := sub_int8_0_ssa(-128); got != -128 { + fmt.Printf("sub_int8 -128-0 = %d, wanted -128\n", got) + failed = true + } + + if got := sub_0_int8_ssa(-127); got != 127 { + fmt.Printf("sub_int8 0--127 = %d, wanted 127\n", got) + failed = true + } + + if got := sub_int8_0_ssa(-127); got != -127 { + fmt.Printf("sub_int8 -127-0 = %d, wanted -127\n", got) + failed = true + } + + if got := sub_0_int8_ssa(-1); got != 1 { + fmt.Printf("sub_int8 0--1 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_int8_0_ssa(-1); got != -1 { + fmt.Printf("sub_int8 -1-0 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_0_int8_ssa(0); got != 0 { + fmt.Printf("sub_int8 0-0 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_int8_0_ssa(0); got != 0 { + fmt.Printf("sub_int8 0-0 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_0_int8_ssa(1); got != -1 { + fmt.Printf("sub_int8 0-1 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_int8_0_ssa(1); got != 1 { + fmt.Printf("sub_int8 1-0 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_0_int8_ssa(126); got != -126 { + fmt.Printf("sub_int8 0-126 = %d, wanted -126\n", got) + failed = true + } + + if got := sub_int8_0_ssa(126); got != 126 { + fmt.Printf("sub_int8 126-0 = %d, wanted 126\n", got) + failed = true + } + + if got := sub_0_int8_ssa(127); got != -127 { + fmt.Printf("sub_int8 0-127 = %d, wanted -127\n", got) + failed = true + } + + if got := sub_int8_0_ssa(127); got != 127 { + fmt.Printf("sub_int8 127-0 = %d, wanted 127\n", got) + failed = true + } + + if got := sub_1_int8_ssa(-128); got != -127 { + fmt.Printf("sub_int8 1--128 = %d, wanted -127\n", got) + failed = true + } + + if got := sub_int8_1_ssa(-128); got != 127 { + fmt.Printf("sub_int8 -128-1 = %d, wanted 127\n", got) + failed = true + } + + if got := sub_1_int8_ssa(-127); got != -128 { + fmt.Printf("sub_int8 1--127 = %d, wanted -128\n", got) + failed = true + } + + if got := sub_int8_1_ssa(-127); got != -128 { + fmt.Printf("sub_int8 -127-1 = %d, wanted -128\n", got) + failed = true + } + + if got := sub_1_int8_ssa(-1); got != 2 { + fmt.Printf("sub_int8 1--1 = %d, wanted 2\n", got) + failed = true + } + + if got := sub_int8_1_ssa(-1); got != -2 { + fmt.Printf("sub_int8 -1-1 = %d, wanted -2\n", got) + failed = true + } + + if got := sub_1_int8_ssa(0); got != 1 { + fmt.Printf("sub_int8 1-0 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_int8_1_ssa(0); got != -1 { + fmt.Printf("sub_int8 0-1 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_1_int8_ssa(1); got != 0 { + fmt.Printf("sub_int8 1-1 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_int8_1_ssa(1); got != 0 { + fmt.Printf("sub_int8 1-1 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_1_int8_ssa(126); got != -125 { + fmt.Printf("sub_int8 1-126 = %d, wanted -125\n", got) + failed = true + } + + if got := sub_int8_1_ssa(126); got != 125 { + fmt.Printf("sub_int8 126-1 = %d, wanted 125\n", got) + failed = true + } + + if got := sub_1_int8_ssa(127); got != -126 { + fmt.Printf("sub_int8 1-127 = %d, wanted -126\n", got) + failed = true + } + + if got := sub_int8_1_ssa(127); got != 126 { + fmt.Printf("sub_int8 127-1 = %d, wanted 126\n", got) + failed = true + } + + if got := sub_126_int8_ssa(-128); got != -2 { + fmt.Printf("sub_int8 126--128 = %d, wanted -2\n", got) + failed = true + } + + if got := sub_int8_126_ssa(-128); got != 2 { + fmt.Printf("sub_int8 -128-126 = %d, wanted 2\n", got) + failed = true + } + + if got := sub_126_int8_ssa(-127); got != -3 { + fmt.Printf("sub_int8 126--127 = %d, wanted -3\n", got) + failed = true + } + + if got := sub_int8_126_ssa(-127); got != 3 { + fmt.Printf("sub_int8 -127-126 = %d, wanted 3\n", got) + failed = true + } + + if got := sub_126_int8_ssa(-1); got != 127 { + fmt.Printf("sub_int8 126--1 = %d, wanted 127\n", got) + failed = true + } + + if got := sub_int8_126_ssa(-1); got != -127 { + fmt.Printf("sub_int8 -1-126 = %d, wanted -127\n", got) + failed = true + } + + if got := sub_126_int8_ssa(0); got != 126 { + fmt.Printf("sub_int8 126-0 = %d, wanted 126\n", got) + failed = true + } + + if got := sub_int8_126_ssa(0); got != -126 { + fmt.Printf("sub_int8 0-126 = %d, wanted -126\n", got) + failed = true + } + + if got := sub_126_int8_ssa(1); got != 125 { + fmt.Printf("sub_int8 126-1 = %d, wanted 125\n", got) + failed = true + } + + if got := sub_int8_126_ssa(1); got != -125 { + fmt.Printf("sub_int8 1-126 = %d, wanted -125\n", got) + failed = true + } + + if got := sub_126_int8_ssa(126); got != 0 { + fmt.Printf("sub_int8 126-126 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_int8_126_ssa(126); got != 0 { + fmt.Printf("sub_int8 126-126 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_126_int8_ssa(127); got != -1 { + fmt.Printf("sub_int8 126-127 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_int8_126_ssa(127); got != 1 { + fmt.Printf("sub_int8 127-126 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_127_int8_ssa(-128); got != -1 { + fmt.Printf("sub_int8 127--128 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_int8_127_ssa(-128); got != 1 { + fmt.Printf("sub_int8 -128-127 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_127_int8_ssa(-127); got != -2 { + fmt.Printf("sub_int8 127--127 = %d, wanted -2\n", got) + failed = true + } + + if got := sub_int8_127_ssa(-127); got != 2 { + fmt.Printf("sub_int8 -127-127 = %d, wanted 2\n", got) + failed = true + } + + if got := sub_127_int8_ssa(-1); got != -128 { + fmt.Printf("sub_int8 127--1 = %d, wanted -128\n", got) + failed = true + } + + if got := sub_int8_127_ssa(-1); got != -128 { + fmt.Printf("sub_int8 -1-127 = %d, wanted -128\n", got) + failed = true + } + + if got := sub_127_int8_ssa(0); got != 127 { + fmt.Printf("sub_int8 127-0 = %d, wanted 127\n", got) + failed = true + } + + if got := sub_int8_127_ssa(0); got != -127 { + fmt.Printf("sub_int8 0-127 = %d, wanted -127\n", got) + failed = true + } + + if got := sub_127_int8_ssa(1); got != 126 { + fmt.Printf("sub_int8 127-1 = %d, wanted 126\n", got) + failed = true + } + + if got := sub_int8_127_ssa(1); got != -126 { + fmt.Printf("sub_int8 1-127 = %d, wanted -126\n", got) + failed = true + } + + if got := sub_127_int8_ssa(126); got != 1 { + fmt.Printf("sub_int8 127-126 = %d, wanted 1\n", got) + failed = true + } + + if got := sub_int8_127_ssa(126); got != -1 { + fmt.Printf("sub_int8 126-127 = %d, wanted -1\n", got) + failed = true + } + + if got := sub_127_int8_ssa(127); got != 0 { + fmt.Printf("sub_int8 127-127 = %d, wanted 0\n", got) + failed = true + } + + if got := sub_int8_127_ssa(127); got != 0 { + fmt.Printf("sub_int8 127-127 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg128_int8_ssa(-128); got != 1 { + fmt.Printf("div_int8 -128/-128 = %d, wanted 1\n", got) + failed = true + } + + if got := div_int8_Neg128_ssa(-128); got != 1 { + fmt.Printf("div_int8 -128/-128 = %d, wanted 1\n", got) + failed = true + } + + if got := div_Neg128_int8_ssa(-127); got != 1 { + fmt.Printf("div_int8 -128/-127 = %d, wanted 1\n", got) + failed = true + } + + if got := div_int8_Neg128_ssa(-127); got != 0 { + fmt.Printf("div_int8 -127/-128 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg128_int8_ssa(-1); got != -128 { + fmt.Printf("div_int8 -128/-1 = %d, wanted -128\n", got) + failed = true + } + + if got := div_int8_Neg128_ssa(-1); got != 0 { + fmt.Printf("div_int8 -1/-128 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int8_Neg128_ssa(0); got != 0 { + fmt.Printf("div_int8 0/-128 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg128_int8_ssa(1); got != -128 { + fmt.Printf("div_int8 -128/1 = %d, wanted -128\n", got) + failed = true + } + + if got := div_int8_Neg128_ssa(1); got != 0 { + fmt.Printf("div_int8 1/-128 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg128_int8_ssa(126); got != -1 { + fmt.Printf("div_int8 -128/126 = %d, wanted -1\n", got) + failed = true + } + + if got := div_int8_Neg128_ssa(126); got != 0 { + fmt.Printf("div_int8 126/-128 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg128_int8_ssa(127); got != -1 { + fmt.Printf("div_int8 -128/127 = %d, wanted -1\n", got) + failed = true + } + + if got := div_int8_Neg128_ssa(127); got != 0 { + fmt.Printf("div_int8 127/-128 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg127_int8_ssa(-128); got != 0 { + fmt.Printf("div_int8 -127/-128 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int8_Neg127_ssa(-128); got != 1 { + fmt.Printf("div_int8 -128/-127 = %d, wanted 1\n", got) + failed = true + } + + if got := div_Neg127_int8_ssa(-127); got != 1 { + fmt.Printf("div_int8 -127/-127 = %d, wanted 1\n", got) failed = true } - if got := div_int16_1_ssa(32766); got != 32766 { - fmt.Printf("div_int16 32766/1 = %d, wanted 32766\n", got) + if got := div_int8_Neg127_ssa(-127); got != 1 { + fmt.Printf("div_int8 -127/-127 = %d, wanted 1\n", got) failed = true } - if got := div_1_int16_ssa(32767); got != 0 { - fmt.Printf("div_int16 1/32767 = %d, wanted 0\n", got) + if got := div_Neg127_int8_ssa(-1); got != 127 { + fmt.Printf("div_int8 -127/-1 = %d, wanted 127\n", got) failed = true } - if got := div_int16_1_ssa(32767); got != 32767 { - fmt.Printf("div_int16 32767/1 = %d, wanted 32767\n", got) + if got := div_int8_Neg127_ssa(-1); got != 0 { + fmt.Printf("div_int8 -1/-127 = %d, wanted 0\n", got) failed = true } - if got := div_32766_int16_ssa(-32768); got != 0 { - fmt.Printf("div_int16 32766/-32768 = %d, wanted 0\n", got) + if got := div_int8_Neg127_ssa(0); got != 0 { + fmt.Printf("div_int8 0/-127 = %d, wanted 0\n", got) failed = true } - if got := div_int16_32766_ssa(-32768); got != -1 { - fmt.Printf("div_int16 -32768/32766 = %d, wanted -1\n", got) + if got := div_Neg127_int8_ssa(1); got != -127 { + fmt.Printf("div_int8 -127/1 = %d, wanted -127\n", got) failed = true } - if got := div_32766_int16_ssa(-32767); got != 0 { - fmt.Printf("div_int16 32766/-32767 = %d, wanted 0\n", got) + if got := div_int8_Neg127_ssa(1); got != 0 { + fmt.Printf("div_int8 1/-127 = %d, wanted 0\n", got) failed = true } - if got := div_int16_32766_ssa(-32767); got != -1 { - fmt.Printf("div_int16 -32767/32766 = %d, wanted -1\n", got) + if got := div_Neg127_int8_ssa(126); got != -1 { + fmt.Printf("div_int8 -127/126 = %d, wanted -1\n", got) failed = true } - if got := div_32766_int16_ssa(-1); got != -32766 { - fmt.Printf("div_int16 32766/-1 = %d, wanted -32766\n", got) + if got := div_int8_Neg127_ssa(126); got != 0 { + fmt.Printf("div_int8 126/-127 = %d, wanted 0\n", got) failed = true } - if got := div_int16_32766_ssa(-1); got != 0 { - fmt.Printf("div_int16 -1/32766 = %d, wanted 0\n", got) + if got := div_Neg127_int8_ssa(127); got != -1 { + fmt.Printf("div_int8 -127/127 = %d, wanted -1\n", got) failed = true } - if got := div_int16_32766_ssa(0); got != 0 { - fmt.Printf("div_int16 0/32766 = %d, wanted 0\n", got) + if got := div_int8_Neg127_ssa(127); got != -1 { + fmt.Printf("div_int8 127/-127 = %d, wanted -1\n", got) failed = true } - if got := div_32766_int16_ssa(1); got != 32766 { - fmt.Printf("div_int16 32766/1 = %d, wanted 32766\n", got) + if got := div_Neg1_int8_ssa(-128); got != 0 { + fmt.Printf("div_int8 -1/-128 = %d, wanted 0\n", got) failed = true } - if got := div_int16_32766_ssa(1); got != 0 { - fmt.Printf("div_int16 1/32766 = %d, wanted 0\n", got) + if got := div_int8_Neg1_ssa(-128); got != -128 { + fmt.Printf("div_int8 -128/-1 = %d, wanted -128\n", got) + failed = true + } + + if got := div_Neg1_int8_ssa(-127); got != 0 { + fmt.Printf("div_int8 -1/-127 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int8_Neg1_ssa(-127); got != 127 { + fmt.Printf("div_int8 -127/-1 = %d, wanted 127\n", got) + failed = true + } + + if got := div_Neg1_int8_ssa(-1); got != 1 { + fmt.Printf("div_int8 -1/-1 = %d, wanted 1\n", got) + failed = true + } + + if got := div_int8_Neg1_ssa(-1); got != 1 { + fmt.Printf("div_int8 -1/-1 = %d, wanted 1\n", got) + failed = true + } + + if got := div_int8_Neg1_ssa(0); got != 0 { + fmt.Printf("div_int8 0/-1 = %d, wanted 0\n", got) + failed = true + } + + if got := div_Neg1_int8_ssa(1); got != -1 { + fmt.Printf("div_int8 -1/1 = %d, wanted -1\n", got) + failed = true + } + + if got := div_int8_Neg1_ssa(1); got != -1 { + fmt.Printf("div_int8 1/-1 = %d, wanted -1\n", got) + failed = true + } + + if got := div_Neg1_int8_ssa(126); got != 0 { + fmt.Printf("div_int8 -1/126 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int8_Neg1_ssa(126); got != -126 { + fmt.Printf("div_int8 126/-1 = %d, wanted -126\n", got) + failed = true + } + + if got := div_Neg1_int8_ssa(127); got != 0 { + fmt.Printf("div_int8 -1/127 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int8_Neg1_ssa(127); got != -127 { + fmt.Printf("div_int8 127/-1 = %d, wanted -127\n", got) + failed = true + } + + if got := div_0_int8_ssa(-128); got != 0 { + fmt.Printf("div_int8 0/-128 = %d, wanted 0\n", got) + failed = true + } + + if got := div_0_int8_ssa(-127); got != 0 { + fmt.Printf("div_int8 0/-127 = %d, wanted 0\n", got) + failed = true + } + + if got := div_0_int8_ssa(-1); got != 0 { + fmt.Printf("div_int8 0/-1 = %d, wanted 0\n", got) + failed = true + } + + if got := div_0_int8_ssa(1); got != 0 { + fmt.Printf("div_int8 0/1 = %d, wanted 0\n", got) + failed = true + } + + if got := div_0_int8_ssa(126); got != 0 { + fmt.Printf("div_int8 0/126 = %d, wanted 0\n", got) + failed = true + } + + if got := div_0_int8_ssa(127); got != 0 { + fmt.Printf("div_int8 0/127 = %d, wanted 0\n", got) + failed = true + } + + if got := div_1_int8_ssa(-128); got != 0 { + fmt.Printf("div_int8 1/-128 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int8_1_ssa(-128); got != -128 { + fmt.Printf("div_int8 -128/1 = %d, wanted -128\n", got) + failed = true + } + + if got := div_1_int8_ssa(-127); got != 0 { + fmt.Printf("div_int8 1/-127 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int8_1_ssa(-127); got != -127 { + fmt.Printf("div_int8 -127/1 = %d, wanted -127\n", got) + failed = true + } + + if got := div_1_int8_ssa(-1); got != -1 { + fmt.Printf("div_int8 1/-1 = %d, wanted -1\n", got) + failed = true + } + + if got := div_int8_1_ssa(-1); got != -1 { + fmt.Printf("div_int8 -1/1 = %d, wanted -1\n", got) + failed = true + } + + if got := div_int8_1_ssa(0); got != 0 { + fmt.Printf("div_int8 0/1 = %d, wanted 0\n", got) + failed = true + } + + if got := div_1_int8_ssa(1); got != 1 { + fmt.Printf("div_int8 1/1 = %d, wanted 1\n", got) + failed = true + } + + if got := div_int8_1_ssa(1); got != 1 { + fmt.Printf("div_int8 1/1 = %d, wanted 1\n", got) + failed = true + } + + if got := div_1_int8_ssa(126); got != 0 { + fmt.Printf("div_int8 1/126 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int8_1_ssa(126); got != 126 { + fmt.Printf("div_int8 126/1 = %d, wanted 126\n", got) + failed = true + } + + if got := div_1_int8_ssa(127); got != 0 { + fmt.Printf("div_int8 1/127 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int8_1_ssa(127); got != 127 { + fmt.Printf("div_int8 127/1 = %d, wanted 127\n", got) + failed = true + } + + if got := div_126_int8_ssa(-128); got != 0 { + fmt.Printf("div_int8 126/-128 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int8_126_ssa(-128); got != -1 { + fmt.Printf("div_int8 -128/126 = %d, wanted -1\n", got) + failed = true + } + + if got := div_126_int8_ssa(-127); got != 0 { + fmt.Printf("div_int8 126/-127 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int8_126_ssa(-127); got != -1 { + fmt.Printf("div_int8 -127/126 = %d, wanted -1\n", got) + failed = true + } + + if got := div_126_int8_ssa(-1); got != -126 { + fmt.Printf("div_int8 126/-1 = %d, wanted -126\n", got) + failed = true + } + + if got := div_int8_126_ssa(-1); got != 0 { + fmt.Printf("div_int8 -1/126 = %d, wanted 0\n", got) + failed = true + } + + if got := div_int8_126_ssa(0); got != 0 { + fmt.Printf("div_int8 0/126 = %d, wanted 0\n", got) + failed = true + } + + if got := div_126_int8_ssa(1); got != 126 { + fmt.Printf("div_int8 126/1 = %d, wanted 126\n", got) + failed = true + } + + if got := div_int8_126_ssa(1); got != 0 { + fmt.Printf("div_int8 1/126 = %d, wanted 0\n", got) + failed = true + } + + if got := div_126_int8_ssa(126); got != 1 { + fmt.Printf("div_int8 126/126 = %d, wanted 1\n", got) + failed = true + } + + if got := div_int8_126_ssa(126); got != 1 { + fmt.Printf("div_int8 126/126 = %d, wanted 1\n", got) failed = true } - if got := div_32766_int16_ssa(32766); got != 1 { - fmt.Printf("div_int16 32766/32766 = %d, wanted 1\n", got) + if got := div_126_int8_ssa(127); got != 0 { + fmt.Printf("div_int8 126/127 = %d, wanted 0\n", got) failed = true } - if got := div_int16_32766_ssa(32766); got != 1 { - fmt.Printf("div_int16 32766/32766 = %d, wanted 1\n", got) + if got := div_int8_126_ssa(127); got != 1 { + fmt.Printf("div_int8 127/126 = %d, wanted 1\n", got) failed = true } - if got := div_32766_int16_ssa(32767); got != 0 { - fmt.Printf("div_int16 32766/32767 = %d, wanted 0\n", got) + if got := div_127_int8_ssa(-128); got != 0 { + fmt.Printf("div_int8 127/-128 = %d, wanted 0\n", got) failed = true } - if got := div_int16_32766_ssa(32767); got != 1 { - fmt.Printf("div_int16 32767/32766 = %d, wanted 1\n", got) + if got := div_int8_127_ssa(-128); got != -1 { + fmt.Printf("div_int8 -128/127 = %d, wanted -1\n", got) failed = true } - if got := div_32767_int16_ssa(-32768); got != 0 { - fmt.Printf("div_int16 32767/-32768 = %d, wanted 0\n", got) + if got := div_127_int8_ssa(-127); got != -1 { + fmt.Printf("div_int8 127/-127 = %d, wanted -1\n", got) failed = true } - if got := div_int16_32767_ssa(-32768); got != -1 { - fmt.Printf("div_int16 -32768/32767 = %d, wanted -1\n", got) + if got := div_int8_127_ssa(-127); got != -1 { + fmt.Printf("div_int8 -127/127 = %d, wanted -1\n", got) failed = true } - if got := div_32767_int16_ssa(-32767); got != -1 { - fmt.Printf("div_int16 32767/-32767 = %d, wanted -1\n", got) + if got := div_127_int8_ssa(-1); got != -127 { + fmt.Printf("div_int8 127/-1 = %d, wanted -127\n", got) failed = true } - if got := div_int16_32767_ssa(-32767); got != -1 { - fmt.Printf("div_int16 -32767/32767 = %d, wanted -1\n", got) + if got := div_int8_127_ssa(-1); got != 0 { + fmt.Printf("div_int8 -1/127 = %d, wanted 0\n", got) failed = true } - if got := div_32767_int16_ssa(-1); got != -32767 { - fmt.Printf("div_int16 32767/-1 = %d, wanted -32767\n", got) + if got := div_int8_127_ssa(0); got != 0 { + fmt.Printf("div_int8 0/127 = %d, wanted 0\n", got) failed = true } - if got := div_int16_32767_ssa(-1); got != 0 { - fmt.Printf("div_int16 -1/32767 = %d, wanted 0\n", got) + if got := div_127_int8_ssa(1); got != 127 { + fmt.Printf("div_int8 127/1 = %d, wanted 127\n", got) failed = true } - if got := div_int16_32767_ssa(0); got != 0 { - fmt.Printf("div_int16 0/32767 = %d, wanted 0\n", got) + if got := div_int8_127_ssa(1); got != 0 { + fmt.Printf("div_int8 1/127 = %d, wanted 0\n", got) failed = true } - if got := div_32767_int16_ssa(1); got != 32767 { - fmt.Printf("div_int16 32767/1 = %d, wanted 32767\n", got) + if got := div_127_int8_ssa(126); got != 1 { + fmt.Printf("div_int8 127/126 = %d, wanted 1\n", got) failed = true } - if got := div_int16_32767_ssa(1); got != 0 { - fmt.Printf("div_int16 1/32767 = %d, wanted 0\n", got) + if got := div_int8_127_ssa(126); got != 0 { + fmt.Printf("div_int8 126/127 = %d, wanted 0\n", got) failed = true } - if got := div_32767_int16_ssa(32766); got != 1 { - fmt.Printf("div_int16 32767/32766 = %d, wanted 1\n", got) + if got := div_127_int8_ssa(127); got != 1 { + fmt.Printf("div_int8 127/127 = %d, wanted 1\n", got) failed = true } - if got := div_int16_32767_ssa(32766); got != 0 { - fmt.Printf("div_int16 32766/32767 = %d, wanted 0\n", got) + if got := div_int8_127_ssa(127); got != 1 { + fmt.Printf("div_int8 127/127 = %d, wanted 1\n", got) failed = true } - if got := div_32767_int16_ssa(32767); got != 1 { - fmt.Printf("div_int16 32767/32767 = %d, wanted 1\n", got) + if got := mul_Neg128_int8_ssa(-128); got != 0 { + fmt.Printf("mul_int8 -128*-128 = %d, wanted 0\n", got) failed = true } - if got := div_int16_32767_ssa(32767); got != 1 { - fmt.Printf("div_int16 32767/32767 = %d, wanted 1\n", got) + if got := mul_int8_Neg128_ssa(-128); got != 0 { + fmt.Printf("mul_int8 -128*-128 = %d, wanted 0\n", got) failed = true } - if got := div_0_uint8_ssa(1); got != 0 { - fmt.Printf("div_uint8 0/1 = %d, wanted 0\n", got) + if got := mul_Neg128_int8_ssa(-127); got != -128 { + fmt.Printf("mul_int8 -128*-127 = %d, wanted -128\n", got) failed = true } - if got := div_0_uint8_ssa(255); got != 0 { - fmt.Printf("div_uint8 0/255 = %d, wanted 0\n", got) + if got := mul_int8_Neg128_ssa(-127); got != -128 { + fmt.Printf("mul_int8 -127*-128 = %d, wanted -128\n", got) failed = true } - if got := div_uint8_1_ssa(0); got != 0 { - fmt.Printf("div_uint8 0/1 = %d, wanted 0\n", got) + if got := mul_Neg128_int8_ssa(-1); got != -128 { + fmt.Printf("mul_int8 -128*-1 = %d, wanted -128\n", got) failed = true } - if got := div_1_uint8_ssa(1); got != 1 { - fmt.Printf("div_uint8 1/1 = %d, wanted 1\n", got) + if got := mul_int8_Neg128_ssa(-1); got != -128 { + fmt.Printf("mul_int8 -1*-128 = %d, wanted -128\n", got) failed = true } - if got := div_uint8_1_ssa(1); got != 1 { - fmt.Printf("div_uint8 1/1 = %d, wanted 1\n", got) + if got := mul_Neg128_int8_ssa(0); got != 0 { + fmt.Printf("mul_int8 -128*0 = %d, wanted 0\n", got) failed = true } - if got := div_1_uint8_ssa(255); got != 0 { - fmt.Printf("adiv_uint8 1/255 = %d, wanted 0\n", got) + if got := mul_int8_Neg128_ssa(0); got != 0 { + fmt.Printf("mul_int8 0*-128 = %d, wanted 0\n", got) failed = true } - if got := div_uint8_1_ssa(255); got != 255 { - fmt.Printf("div_uint8 255/1 = %d, wanted 255\n", got) + if got := mul_Neg128_int8_ssa(1); got != -128 { + fmt.Printf("mul_int8 -128*1 = %d, wanted -128\n", got) failed = true } - if got := div_uint8_255_ssa(0); got != 0 { - fmt.Printf("div_uint8 0/255 = %d, wanted 0\n", got) + if got := mul_int8_Neg128_ssa(1); got != -128 { + fmt.Printf("mul_int8 1*-128 = %d, wanted -128\n", got) failed = true } - if got := div_255_uint8_ssa(1); got != 255 { - fmt.Printf("div_uint8 255/1 = %d, wanted 255\n", got) + if got := mul_Neg128_int8_ssa(126); got != 0 { + fmt.Printf("mul_int8 -128*126 = %d, wanted 0\n", got) failed = true } - if got := div_uint8_255_ssa(1); got != 0 { - fmt.Printf("bdiv_uint8 1/255 = %d, wanted 0\n", got) + if got := mul_int8_Neg128_ssa(126); got != 0 { + fmt.Printf("mul_int8 126*-128 = %d, wanted 0\n", got) failed = true } - if got := div_255_uint8_ssa(255); got != 1 { - fmt.Printf("div_uint8 255/255 = %d, wanted 1\n", got) + if got := mul_Neg128_int8_ssa(127); got != -128 { + fmt.Printf("mul_int8 -128*127 = %d, wanted -128\n", got) failed = true } - if got := div_uint8_255_ssa(255); got != 1 { - fmt.Printf("div_uint8 255/255 = %d, wanted 1\n", got) + if got := mul_int8_Neg128_ssa(127); got != -128 { + fmt.Printf("mul_int8 127*-128 = %d, wanted -128\n", got) failed = true } - if got := div_Neg128_int8_ssa(-128); got != 1 { - fmt.Printf("div_int8 -128/-128 = %d, wanted 1\n", got) + if got := mul_Neg127_int8_ssa(-128); got != -128 { + fmt.Printf("mul_int8 -127*-128 = %d, wanted -128\n", got) failed = true } - if got := div_int8_Neg128_ssa(-128); got != 1 { - fmt.Printf("div_int8 -128/-128 = %d, wanted 1\n", got) + if got := mul_int8_Neg127_ssa(-128); got != -128 { + fmt.Printf("mul_int8 -128*-127 = %d, wanted -128\n", got) failed = true } - if got := div_Neg128_int8_ssa(-127); got != 1 { - fmt.Printf("div_int8 -128/-127 = %d, wanted 1\n", got) + if got := mul_Neg127_int8_ssa(-127); got != 1 { + fmt.Printf("mul_int8 -127*-127 = %d, wanted 1\n", got) failed = true } - if got := div_int8_Neg128_ssa(-127); got != 0 { - fmt.Printf("div_int8 -127/-128 = %d, wanted 0\n", got) + if got := mul_int8_Neg127_ssa(-127); got != 1 { + fmt.Printf("mul_int8 -127*-127 = %d, wanted 1\n", got) failed = true } - if got := div_Neg128_int8_ssa(-1); got != -128 { - fmt.Printf("div_int8 -128/-1 = %d, wanted -128\n", got) + if got := mul_Neg127_int8_ssa(-1); got != 127 { + fmt.Printf("mul_int8 -127*-1 = %d, wanted 127\n", got) failed = true } - if got := div_int8_Neg128_ssa(-1); got != 0 { - fmt.Printf("div_int8 -1/-128 = %d, wanted 0\n", got) + if got := mul_int8_Neg127_ssa(-1); got != 127 { + fmt.Printf("mul_int8 -1*-127 = %d, wanted 127\n", got) failed = true } - if got := div_int8_Neg128_ssa(0); got != 0 { - fmt.Printf("div_int8 0/-128 = %d, wanted 0\n", got) + if got := mul_Neg127_int8_ssa(0); got != 0 { + fmt.Printf("mul_int8 -127*0 = %d, wanted 0\n", got) failed = true } - if got := div_Neg128_int8_ssa(1); got != -128 { - fmt.Printf("div_int8 -128/1 = %d, wanted -128\n", got) + if got := mul_int8_Neg127_ssa(0); got != 0 { + fmt.Printf("mul_int8 0*-127 = %d, wanted 0\n", got) failed = true } - if got := div_int8_Neg128_ssa(1); got != 0 { - fmt.Printf("div_int8 1/-128 = %d, wanted 0\n", got) + if got := mul_Neg127_int8_ssa(1); got != -127 { + fmt.Printf("mul_int8 -127*1 = %d, wanted -127\n", got) failed = true } - if got := div_Neg128_int8_ssa(126); got != -1 { - fmt.Printf("div_int8 -128/126 = %d, wanted -1\n", got) + if got := mul_int8_Neg127_ssa(1); got != -127 { + fmt.Printf("mul_int8 1*-127 = %d, wanted -127\n", got) failed = true } - if got := div_int8_Neg128_ssa(126); got != 0 { - fmt.Printf("div_int8 126/-128 = %d, wanted 0\n", got) + if got := mul_Neg127_int8_ssa(126); got != 126 { + fmt.Printf("mul_int8 -127*126 = %d, wanted 126\n", got) failed = true } - if got := div_Neg128_int8_ssa(127); got != -1 { - fmt.Printf("div_int8 -128/127 = %d, wanted -1\n", got) + if got := mul_int8_Neg127_ssa(126); got != 126 { + fmt.Printf("mul_int8 126*-127 = %d, wanted 126\n", got) failed = true } - if got := div_int8_Neg128_ssa(127); got != 0 { - fmt.Printf("div_int8 127/-128 = %d, wanted 0\n", got) + if got := mul_Neg127_int8_ssa(127); got != -1 { + fmt.Printf("mul_int8 -127*127 = %d, wanted -1\n", got) failed = true } - if got := div_Neg127_int8_ssa(-128); got != 0 { - fmt.Printf("div_int8 -127/-128 = %d, wanted 0\n", got) + if got := mul_int8_Neg127_ssa(127); got != -1 { + fmt.Printf("mul_int8 127*-127 = %d, wanted -1\n", got) failed = true } - if got := div_int8_Neg127_ssa(-128); got != 1 { - fmt.Printf("div_int8 -128/-127 = %d, wanted 1\n", got) + if got := mul_Neg1_int8_ssa(-128); got != -128 { + fmt.Printf("mul_int8 -1*-128 = %d, wanted -128\n", got) failed = true } - if got := div_Neg127_int8_ssa(-127); got != 1 { - fmt.Printf("div_int8 -127/-127 = %d, wanted 1\n", got) + if got := mul_int8_Neg1_ssa(-128); got != -128 { + fmt.Printf("mul_int8 -128*-1 = %d, wanted -128\n", got) failed = true } - if got := div_int8_Neg127_ssa(-127); got != 1 { - fmt.Printf("div_int8 -127/-127 = %d, wanted 1\n", got) + if got := mul_Neg1_int8_ssa(-127); got != 127 { + fmt.Printf("mul_int8 -1*-127 = %d, wanted 127\n", got) failed = true } - if got := div_Neg127_int8_ssa(-1); got != 127 { - fmt.Printf("div_int8 -127/-1 = %d, wanted 127\n", got) + if got := mul_int8_Neg1_ssa(-127); got != 127 { + fmt.Printf("mul_int8 -127*-1 = %d, wanted 127\n", got) failed = true } - if got := div_int8_Neg127_ssa(-1); got != 0 { - fmt.Printf("div_int8 -1/-127 = %d, wanted 0\n", got) + if got := mul_Neg1_int8_ssa(-1); got != 1 { + fmt.Printf("mul_int8 -1*-1 = %d, wanted 1\n", got) failed = true } - if got := div_int8_Neg127_ssa(0); got != 0 { - fmt.Printf("div_int8 0/-127 = %d, wanted 0\n", got) + if got := mul_int8_Neg1_ssa(-1); got != 1 { + fmt.Printf("mul_int8 -1*-1 = %d, wanted 1\n", got) failed = true } - if got := div_Neg127_int8_ssa(1); got != -127 { - fmt.Printf("div_int8 -127/1 = %d, wanted -127\n", got) + if got := mul_Neg1_int8_ssa(0); got != 0 { + fmt.Printf("mul_int8 -1*0 = %d, wanted 0\n", got) failed = true } - if got := div_int8_Neg127_ssa(1); got != 0 { - fmt.Printf("div_int8 1/-127 = %d, wanted 0\n", got) + if got := mul_int8_Neg1_ssa(0); got != 0 { + fmt.Printf("mul_int8 0*-1 = %d, wanted 0\n", got) failed = true } - if got := div_Neg127_int8_ssa(126); got != -1 { - fmt.Printf("div_int8 -127/126 = %d, wanted -1\n", got) + if got := mul_Neg1_int8_ssa(1); got != -1 { + fmt.Printf("mul_int8 -1*1 = %d, wanted -1\n", got) failed = true } - if got := div_int8_Neg127_ssa(126); got != 0 { - fmt.Printf("div_int8 126/-127 = %d, wanted 0\n", got) + if got := mul_int8_Neg1_ssa(1); got != -1 { + fmt.Printf("mul_int8 1*-1 = %d, wanted -1\n", got) failed = true } - if got := div_Neg127_int8_ssa(127); got != -1 { - fmt.Printf("div_int8 -127/127 = %d, wanted -1\n", got) + if got := mul_Neg1_int8_ssa(126); got != -126 { + fmt.Printf("mul_int8 -1*126 = %d, wanted -126\n", got) failed = true } - if got := div_int8_Neg127_ssa(127); got != -1 { - fmt.Printf("div_int8 127/-127 = %d, wanted -1\n", got) + if got := mul_int8_Neg1_ssa(126); got != -126 { + fmt.Printf("mul_int8 126*-1 = %d, wanted -126\n", got) failed = true } - if got := div_Neg1_int8_ssa(-128); got != 0 { - fmt.Printf("div_int8 -1/-128 = %d, wanted 0\n", got) + if got := mul_Neg1_int8_ssa(127); got != -127 { + fmt.Printf("mul_int8 -1*127 = %d, wanted -127\n", got) failed = true } - if got := div_int8_Neg1_ssa(-128); got != -128 { - fmt.Printf("div_int8 -128/-1 = %d, wanted -128\n", got) + if got := mul_int8_Neg1_ssa(127); got != -127 { + fmt.Printf("mul_int8 127*-1 = %d, wanted -127\n", got) failed = true } - if got := div_Neg1_int8_ssa(-127); got != 0 { - fmt.Printf("div_int8 -1/-127 = %d, wanted 0\n", got) + if got := mul_0_int8_ssa(-128); got != 0 { + fmt.Printf("mul_int8 0*-128 = %d, wanted 0\n", got) failed = true } - if got := div_int8_Neg1_ssa(-127); got != 127 { - fmt.Printf("div_int8 -127/-1 = %d, wanted 127\n", got) + if got := mul_int8_0_ssa(-128); got != 0 { + fmt.Printf("mul_int8 -128*0 = %d, wanted 0\n", got) failed = true } - if got := div_Neg1_int8_ssa(-1); got != 1 { - fmt.Printf("div_int8 -1/-1 = %d, wanted 1\n", got) + if got := mul_0_int8_ssa(-127); got != 0 { + fmt.Printf("mul_int8 0*-127 = %d, wanted 0\n", got) failed = true } - if got := div_int8_Neg1_ssa(-1); got != 1 { - fmt.Printf("div_int8 -1/-1 = %d, wanted 1\n", got) + if got := mul_int8_0_ssa(-127); got != 0 { + fmt.Printf("mul_int8 -127*0 = %d, wanted 0\n", got) failed = true } - if got := div_int8_Neg1_ssa(0); got != 0 { - fmt.Printf("div_int8 0/-1 = %d, wanted 0\n", got) + if got := mul_0_int8_ssa(-1); got != 0 { + fmt.Printf("mul_int8 0*-1 = %d, wanted 0\n", got) failed = true } - if got := div_Neg1_int8_ssa(1); got != -1 { - fmt.Printf("div_int8 -1/1 = %d, wanted -1\n", got) + if got := mul_int8_0_ssa(-1); got != 0 { + fmt.Printf("mul_int8 -1*0 = %d, wanted 0\n", got) failed = true } - if got := div_int8_Neg1_ssa(1); got != -1 { - fmt.Printf("div_int8 1/-1 = %d, wanted -1\n", got) + if got := mul_0_int8_ssa(0); got != 0 { + fmt.Printf("mul_int8 0*0 = %d, wanted 0\n", got) failed = true } - if got := div_Neg1_int8_ssa(126); got != 0 { - fmt.Printf("div_int8 -1/126 = %d, wanted 0\n", got) + if got := mul_int8_0_ssa(0); got != 0 { + fmt.Printf("mul_int8 0*0 = %d, wanted 0\n", got) failed = true } - if got := div_int8_Neg1_ssa(126); got != -126 { - fmt.Printf("div_int8 126/-1 = %d, wanted -126\n", got) + if got := mul_0_int8_ssa(1); got != 0 { + fmt.Printf("mul_int8 0*1 = %d, wanted 0\n", got) failed = true } - if got := div_Neg1_int8_ssa(127); got != 0 { - fmt.Printf("div_int8 -1/127 = %d, wanted 0\n", got) + if got := mul_int8_0_ssa(1); got != 0 { + fmt.Printf("mul_int8 1*0 = %d, wanted 0\n", got) failed = true } - if got := div_int8_Neg1_ssa(127); got != -127 { - fmt.Printf("div_int8 127/-1 = %d, wanted -127\n", got) + if got := mul_0_int8_ssa(126); got != 0 { + fmt.Printf("mul_int8 0*126 = %d, wanted 0\n", got) failed = true } - if got := div_0_int8_ssa(-128); got != 0 { - fmt.Printf("div_int8 0/-128 = %d, wanted 0\n", got) + if got := mul_int8_0_ssa(126); got != 0 { + fmt.Printf("mul_int8 126*0 = %d, wanted 0\n", got) failed = true } - if got := div_0_int8_ssa(-127); got != 0 { - fmt.Printf("div_int8 0/-127 = %d, wanted 0\n", got) + if got := mul_0_int8_ssa(127); got != 0 { + fmt.Printf("mul_int8 0*127 = %d, wanted 0\n", got) failed = true } - if got := div_0_int8_ssa(-1); got != 0 { - fmt.Printf("div_int8 0/-1 = %d, wanted 0\n", got) + if got := mul_int8_0_ssa(127); got != 0 { + fmt.Printf("mul_int8 127*0 = %d, wanted 0\n", got) failed = true } - if got := div_0_int8_ssa(1); got != 0 { - fmt.Printf("div_int8 0/1 = %d, wanted 0\n", got) + if got := mul_1_int8_ssa(-128); got != -128 { + fmt.Printf("mul_int8 1*-128 = %d, wanted -128\n", got) failed = true } - if got := div_0_int8_ssa(126); got != 0 { - fmt.Printf("div_int8 0/126 = %d, wanted 0\n", got) + if got := mul_int8_1_ssa(-128); got != -128 { + fmt.Printf("mul_int8 -128*1 = %d, wanted -128\n", got) failed = true } - if got := div_0_int8_ssa(127); got != 0 { - fmt.Printf("div_int8 0/127 = %d, wanted 0\n", got) + if got := mul_1_int8_ssa(-127); got != -127 { + fmt.Printf("mul_int8 1*-127 = %d, wanted -127\n", got) failed = true } - if got := div_1_int8_ssa(-128); got != 0 { - fmt.Printf("div_int8 1/-128 = %d, wanted 0\n", got) + if got := mul_int8_1_ssa(-127); got != -127 { + fmt.Printf("mul_int8 -127*1 = %d, wanted -127\n", got) failed = true } - if got := div_int8_1_ssa(-128); got != -128 { - fmt.Printf("div_int8 -128/1 = %d, wanted -128\n", got) + if got := mul_1_int8_ssa(-1); got != -1 { + fmt.Printf("mul_int8 1*-1 = %d, wanted -1\n", got) failed = true } - if got := div_1_int8_ssa(-127); got != 0 { - fmt.Printf("div_int8 1/-127 = %d, wanted 0\n", got) + if got := mul_int8_1_ssa(-1); got != -1 { + fmt.Printf("mul_int8 -1*1 = %d, wanted -1\n", got) failed = true } - if got := div_int8_1_ssa(-127); got != -127 { - fmt.Printf("div_int8 -127/1 = %d, wanted -127\n", got) + if got := mul_1_int8_ssa(0); got != 0 { + fmt.Printf("mul_int8 1*0 = %d, wanted 0\n", got) failed = true } - if got := div_1_int8_ssa(-1); got != -1 { - fmt.Printf("div_int8 1/-1 = %d, wanted -1\n", got) + if got := mul_int8_1_ssa(0); got != 0 { + fmt.Printf("mul_int8 0*1 = %d, wanted 0\n", got) failed = true } - if got := div_int8_1_ssa(-1); got != -1 { - fmt.Printf("div_int8 -1/1 = %d, wanted -1\n", got) + if got := mul_1_int8_ssa(1); got != 1 { + fmt.Printf("mul_int8 1*1 = %d, wanted 1\n", got) failed = true } - if got := div_int8_1_ssa(0); got != 0 { - fmt.Printf("div_int8 0/1 = %d, wanted 0\n", got) + if got := mul_int8_1_ssa(1); got != 1 { + fmt.Printf("mul_int8 1*1 = %d, wanted 1\n", got) failed = true } - if got := div_1_int8_ssa(1); got != 1 { - fmt.Printf("div_int8 1/1 = %d, wanted 1\n", got) + if got := mul_1_int8_ssa(126); got != 126 { + fmt.Printf("mul_int8 1*126 = %d, wanted 126\n", got) failed = true } - if got := div_int8_1_ssa(1); got != 1 { - fmt.Printf("div_int8 1/1 = %d, wanted 1\n", got) + if got := mul_int8_1_ssa(126); got != 126 { + fmt.Printf("mul_int8 126*1 = %d, wanted 126\n", got) failed = true } - if got := div_1_int8_ssa(126); got != 0 { - fmt.Printf("div_int8 1/126 = %d, wanted 0\n", got) + if got := mul_1_int8_ssa(127); got != 127 { + fmt.Printf("mul_int8 1*127 = %d, wanted 127\n", got) failed = true } - if got := div_int8_1_ssa(126); got != 126 { - fmt.Printf("div_int8 126/1 = %d, wanted 126\n", got) + if got := mul_int8_1_ssa(127); got != 127 { + fmt.Printf("mul_int8 127*1 = %d, wanted 127\n", got) failed = true } - if got := div_1_int8_ssa(127); got != 0 { - fmt.Printf("div_int8 1/127 = %d, wanted 0\n", got) + if got := mul_126_int8_ssa(-128); got != 0 { + fmt.Printf("mul_int8 126*-128 = %d, wanted 0\n", got) failed = true } - if got := div_int8_1_ssa(127); got != 127 { - fmt.Printf("div_int8 127/1 = %d, wanted 127\n", got) + if got := mul_int8_126_ssa(-128); got != 0 { + fmt.Printf("mul_int8 -128*126 = %d, wanted 0\n", got) failed = true } - if got := div_126_int8_ssa(-128); got != 0 { - fmt.Printf("div_int8 126/-128 = %d, wanted 0\n", got) + if got := mul_126_int8_ssa(-127); got != 126 { + fmt.Printf("mul_int8 126*-127 = %d, wanted 126\n", got) failed = true } - if got := div_int8_126_ssa(-128); got != -1 { - fmt.Printf("div_int8 -128/126 = %d, wanted -1\n", got) + if got := mul_int8_126_ssa(-127); got != 126 { + fmt.Printf("mul_int8 -127*126 = %d, wanted 126\n", got) failed = true } - if got := div_126_int8_ssa(-127); got != 0 { - fmt.Printf("div_int8 126/-127 = %d, wanted 0\n", got) + if got := mul_126_int8_ssa(-1); got != -126 { + fmt.Printf("mul_int8 126*-1 = %d, wanted -126\n", got) failed = true } - if got := div_int8_126_ssa(-127); got != -1 { - fmt.Printf("div_int8 -127/126 = %d, wanted -1\n", got) + if got := mul_int8_126_ssa(-1); got != -126 { + fmt.Printf("mul_int8 -1*126 = %d, wanted -126\n", got) failed = true } - if got := div_126_int8_ssa(-1); got != -126 { - fmt.Printf("div_int8 126/-1 = %d, wanted -126\n", got) + if got := mul_126_int8_ssa(0); got != 0 { + fmt.Printf("mul_int8 126*0 = %d, wanted 0\n", got) failed = true } - if got := div_int8_126_ssa(-1); got != 0 { - fmt.Printf("div_int8 -1/126 = %d, wanted 0\n", got) + if got := mul_int8_126_ssa(0); got != 0 { + fmt.Printf("mul_int8 0*126 = %d, wanted 0\n", got) failed = true } - if got := div_int8_126_ssa(0); got != 0 { - fmt.Printf("div_int8 0/126 = %d, wanted 0\n", got) + if got := mul_126_int8_ssa(1); got != 126 { + fmt.Printf("mul_int8 126*1 = %d, wanted 126\n", got) failed = true } - if got := div_126_int8_ssa(1); got != 126 { - fmt.Printf("div_int8 126/1 = %d, wanted 126\n", got) + if got := mul_int8_126_ssa(1); got != 126 { + fmt.Printf("mul_int8 1*126 = %d, wanted 126\n", got) failed = true } - if got := div_int8_126_ssa(1); got != 0 { - fmt.Printf("div_int8 1/126 = %d, wanted 0\n", got) + if got := mul_126_int8_ssa(126); got != 4 { + fmt.Printf("mul_int8 126*126 = %d, wanted 4\n", got) failed = true } - if got := div_126_int8_ssa(126); got != 1 { - fmt.Printf("div_int8 126/126 = %d, wanted 1\n", got) + if got := mul_int8_126_ssa(126); got != 4 { + fmt.Printf("mul_int8 126*126 = %d, wanted 4\n", got) failed = true } - if got := div_int8_126_ssa(126); got != 1 { - fmt.Printf("div_int8 126/126 = %d, wanted 1\n", got) + if got := mul_126_int8_ssa(127); got != -126 { + fmt.Printf("mul_int8 126*127 = %d, wanted -126\n", got) failed = true } - if got := div_126_int8_ssa(127); got != 0 { - fmt.Printf("div_int8 126/127 = %d, wanted 0\n", got) + if got := mul_int8_126_ssa(127); got != -126 { + fmt.Printf("mul_int8 127*126 = %d, wanted -126\n", got) failed = true } - if got := div_int8_126_ssa(127); got != 1 { - fmt.Printf("div_int8 127/126 = %d, wanted 1\n", got) + if got := mul_127_int8_ssa(-128); got != -128 { + fmt.Printf("mul_int8 127*-128 = %d, wanted -128\n", got) failed = true } - if got := div_127_int8_ssa(-128); got != 0 { - fmt.Printf("div_int8 127/-128 = %d, wanted 0\n", got) + if got := mul_int8_127_ssa(-128); got != -128 { + fmt.Printf("mul_int8 -128*127 = %d, wanted -128\n", got) failed = true } - if got := div_int8_127_ssa(-128); got != -1 { - fmt.Printf("div_int8 -128/127 = %d, wanted -1\n", got) + if got := mul_127_int8_ssa(-127); got != -1 { + fmt.Printf("mul_int8 127*-127 = %d, wanted -1\n", got) failed = true } - if got := div_127_int8_ssa(-127); got != -1 { - fmt.Printf("div_int8 127/-127 = %d, wanted -1\n", got) + if got := mul_int8_127_ssa(-127); got != -1 { + fmt.Printf("mul_int8 -127*127 = %d, wanted -1\n", got) failed = true } - if got := div_int8_127_ssa(-127); got != -1 { - fmt.Printf("div_int8 -127/127 = %d, wanted -1\n", got) + if got := mul_127_int8_ssa(-1); got != -127 { + fmt.Printf("mul_int8 127*-1 = %d, wanted -127\n", got) failed = true } - if got := div_127_int8_ssa(-1); got != -127 { - fmt.Printf("div_int8 127/-1 = %d, wanted -127\n", got) + if got := mul_int8_127_ssa(-1); got != -127 { + fmt.Printf("mul_int8 -1*127 = %d, wanted -127\n", got) failed = true } - if got := div_int8_127_ssa(-1); got != 0 { - fmt.Printf("div_int8 -1/127 = %d, wanted 0\n", got) + if got := mul_127_int8_ssa(0); got != 0 { + fmt.Printf("mul_int8 127*0 = %d, wanted 0\n", got) failed = true } - if got := div_int8_127_ssa(0); got != 0 { - fmt.Printf("div_int8 0/127 = %d, wanted 0\n", got) + if got := mul_int8_127_ssa(0); got != 0 { + fmt.Printf("mul_int8 0*127 = %d, wanted 0\n", got) failed = true } - if got := div_127_int8_ssa(1); got != 127 { - fmt.Printf("div_int8 127/1 = %d, wanted 127\n", got) + if got := mul_127_int8_ssa(1); got != 127 { + fmt.Printf("mul_int8 127*1 = %d, wanted 127\n", got) failed = true } - if got := div_int8_127_ssa(1); got != 0 { - fmt.Printf("div_int8 1/127 = %d, wanted 0\n", got) + if got := mul_int8_127_ssa(1); got != 127 { + fmt.Printf("mul_int8 1*127 = %d, wanted 127\n", got) failed = true } - if got := div_127_int8_ssa(126); got != 1 { - fmt.Printf("div_int8 127/126 = %d, wanted 1\n", got) + if got := mul_127_int8_ssa(126); got != -126 { + fmt.Printf("mul_int8 127*126 = %d, wanted -126\n", got) failed = true } - if got := div_int8_127_ssa(126); got != 0 { - fmt.Printf("div_int8 126/127 = %d, wanted 0\n", got) + if got := mul_int8_127_ssa(126); got != -126 { + fmt.Printf("mul_int8 126*127 = %d, wanted -126\n", got) failed = true } - if got := div_127_int8_ssa(127); got != 1 { - fmt.Printf("div_int8 127/127 = %d, wanted 1\n", got) + if got := mul_127_int8_ssa(127); got != 1 { + fmt.Printf("mul_int8 127*127 = %d, wanted 1\n", got) failed = true } - if got := div_int8_127_ssa(127); got != 1 { - fmt.Printf("div_int8 127/127 = %d, wanted 1\n", got) + if got := mul_int8_127_ssa(127); got != 1 { + fmt.Printf("mul_int8 127*127 = %d, wanted 1\n", got) failed = true } if failed { diff --git a/src/cmd/compile/internal/gc/testdata/arith_ssa.go b/src/cmd/compile/internal/gc/testdata/arith_ssa.go index af31245505..22a78105e0 100644 --- a/src/cmd/compile/internal/gc/testdata/arith_ssa.go +++ b/src/cmd/compile/internal/gc/testdata/arith_ssa.go @@ -8,6 +8,102 @@ package main +import "fmt" + +// testArithRshConst ensures that "const >> const" right shifts correctly perform +// sign extension on the lhs constant +func testArithRshConst() { + wantu := uint64(0x4000000000000000) + if got := arithRshuConst_ssa(); got != wantu { + println("arithRshuConst failed, wanted", wantu, "got", got) + failed = true + } + + wants := int64(-0x4000000000000000) + if got := arithRshConst_ssa(); got != wants { + println("arithRshuConst failed, wanted", wants, "got", got) + failed = true + } +} + +//go:noinline +func arithRshuConst_ssa() uint64 { + y := uint64(0x8000000000000001) + z := uint64(1) + return uint64(y >> z) +} + +//go:noinline +func arithRshConst_ssa() int64 { + y := int64(-0x8000000000000000) + z := uint64(1) + return int64(y >> z) +} + +//go:noinline +func arithConstShift_ssa(x int64) int64 { + return x >> 100 +} + +// testArithConstShift tests that right shift by large constants preserve +// the sign of the input. +func testArithConstShift() { + want := int64(-1) + if got := arithConstShift_ssa(-1); want != got { + println("arithConstShift_ssa(-1) failed, wanted", want, "got", got) + failed = true + } + want = 0 + if got := arithConstShift_ssa(1); want != got { + println("arithConstShift_ssa(1) failed, wanted", want, "got", got) + failed = true + } +} + +// overflowConstShift_ssa verifes that constant folding for shift +// doesn't wrap (i.e. x << MAX_INT << 1 doesn't get folded to x << 0). +//go:noinline +func overflowConstShift64_ssa(x int64) int64 { + return x << uint64(0xffffffffffffffff) << uint64(1) +} + +//go:noinline +func overflowConstShift32_ssa(x int64) int32 { + return int32(x) << uint32(0xffffffff) << uint32(1) +} + +//go:noinline +func overflowConstShift16_ssa(x int64) int16 { + return int16(x) << uint16(0xffff) << uint16(1) +} + +//go:noinline +func overflowConstShift8_ssa(x int64) int8 { + return int8(x) << uint8(0xff) << uint8(1) +} + +func testOverflowConstShift() { + want := int64(0) + for x := int64(-127); x < int64(127); x++ { + got := overflowConstShift64_ssa(x) + if want != got { + fmt.Printf("overflowShift64 failed, wanted %d got %d\n", want, got) + } + got = int64(overflowConstShift32_ssa(x)) + if want != got { + fmt.Printf("overflowShift32 failed, wanted %d got %d\n", want, got) + } + got = int64(overflowConstShift16_ssa(x)) + if want != got { + fmt.Printf("overflowShift16 failed, wanted %d got %d\n", want, got) + } + got = int64(overflowConstShift8_ssa(x)) + if want != got { + fmt.Printf("overflowShift8 failed, wanted %d got %d\n", want, got) + } + } +} + // test64BitConstMult tests that rewrite rules don't fold 64 bit constants // into multiply instructions. func test64BitConstMult() { @@ -275,6 +371,9 @@ func main() { testLrot() testShiftCX() testSubConst() + testOverflowConstShift() + testArithConstShift() + testArithRshConst() if failed { panic("failed") diff --git a/src/cmd/compile/internal/gc/testdata/gen/arithConstGen.go b/src/cmd/compile/internal/gc/testdata/gen/arithConstGen.go new file mode 100644 index 0000000000..34e54ad08a --- /dev/null +++ b/src/cmd/compile/internal/gc/testdata/gen/arithConstGen.go @@ -0,0 +1,294 @@ +// Copyright 2016 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +// This program generates a test to verify that the standard arithmetic +// operators properly handle const cases. The test file should be +// generated with a known working version of go. +// launch with `go run arithConstGen.go` a file called arithConst_ssa.go +// will be written into the parent directory containing the tests + +package main + +import ( + "bytes" + "fmt" + "go/format" + "io/ioutil" + "log" + "strings" + "text/template" +) + +type op struct { + name, symbol string +} +type szD struct { + name string + sn string + u []uint64 + i []int64 +} + +var szs []szD = []szD{ + szD{name: "uint64", sn: "64", u: []uint64{0, 1, 4294967296, 0xffffFFFFffffFFFF}}, + szD{name: "int64", sn: "64", i: []int64{-0x8000000000000000, -0x7FFFFFFFFFFFFFFF, + -4294967296, -1, 0, 1, 4294967296, 0x7FFFFFFFFFFFFFFE, 0x7FFFFFFFFFFFFFFF}}, + + szD{name: "uint32", sn: "32", u: []uint64{0, 1, 4294967295}}, + szD{name: "int32", sn: "32", i: []int64{-0x80000000, -0x7FFFFFFF, -1, 0, + 1, 0x7FFFFFFF}}, + + szD{name: "uint16", sn: "16", u: []uint64{0, 1, 65535}}, + szD{name: "int16", sn: "16", i: []int64{-32768, -32767, -1, 0, 1, 32766, 32767}}, + + szD{name: "uint8", sn: "8", u: []uint64{0, 1, 255}}, + szD{name: "int8", sn: "8", i: []int64{-128, -127, -1, 0, 1, 126, 127}}, +} + +var ops []op = []op{op{"add", "+"}, op{"sub", "-"}, op{"div", "/"}, op{"mul", "*"}, + op{"lsh", "<<"}, op{"rsh", ">>"}} + +// compute the result of i op j, cast as type t. +func ansU(i, j uint64, t, op string) string { + var ans uint64 + switch op { + case "+": + ans = i + j + case "-": + ans = i - j + case "*": + ans = i * j + case "/": + if j != 0 { + ans = i / j + } + case "<<": + ans = i << j + case ">>": + ans = i >> j + } + switch t { + case "uint32": + ans = uint64(uint32(ans)) + case "uint16": + ans = uint64(uint16(ans)) + case "uint8": + ans = uint64(uint8(ans)) + } + return fmt.Sprintf("%d", ans) +} + +// compute the result of i op j, cast as type t. +func ansS(i, j int64, t, op string) string { + var ans int64 + switch op { + case "+": + ans = i + j + case "-": + ans = i - j + case "*": + ans = i * j + case "/": + if j != 0 { + ans = i / j + } + case "<<": + ans = i << uint64(j) + case ">>": + ans = i >> uint64(j) + } + switch t { + case "int32": + ans = int64(int32(ans)) + case "int16": + ans = int64(int16(ans)) + case "int8": + ans = int64(int8(ans)) + } + return fmt.Sprintf("%d", ans) +} + +func main() { + + w := new(bytes.Buffer) + + fmt.Fprintf(w, "package main;\n") + fmt.Fprintf(w, "import \"fmt\"\n") + + fncCnst1, err := template.New("fnc").Parse( + `//go:noinline + func {{.Name}}_{{.Type_}}_{{.FNumber}}_ssa(a {{.Type_}}) {{.Type_}} { + return a {{.Symbol}} {{.Number}} +} +`) + if err != nil { + panic(err) + } + fncCnst2, err := template.New("fnc").Parse( + `//go:noinline + func {{.Name}}_{{.FNumber}}_{{.Type_}}_ssa(a {{.Type_}}) {{.Type_}} { + return {{.Number}} {{.Symbol}} a +} + +`) + if err != nil { + panic(err) + } + + type fncData struct { + Name, Type_, Symbol, FNumber, Number string + } + + for _, s := range szs { + for _, o := range ops { + fd := fncData{o.name, s.name, o.symbol, "", ""} + + // unsigned test cases + if len(s.u) > 0 { + for _, i := range s.u { + fd.Number = fmt.Sprintf("%d", i) + fd.FNumber = strings.Replace(fd.Number, "-", "Neg", -1) + + // avoid division by zero + if o.name != "div" || i != 0 { + fncCnst1.Execute(w, fd) + } + + fncCnst2.Execute(w, fd) + } + } + + // signed test cases + if len(s.i) > 0 { + // don't generate tests for shifts by signed integers + if o.name == "lsh" || o.name == "rsh" { + continue + } + for _, i := range s.i { + fd.Number = fmt.Sprintf("%d", i) + fd.FNumber = strings.Replace(fd.Number, "-", "Neg", -1) + + // avoid division by zero + if o.name != "div" || i != 0 { + fncCnst1.Execute(w, fd) + } + fncCnst2.Execute(w, fd) + } + } + } + } + + fmt.Fprintf(w, "var failed bool\n\n") + fmt.Fprintf(w, "func main() {\n\n") + + vrf1, _ := template.New("vrf1").Parse(` + if got := {{.Name}}_{{.FNumber}}_{{.Type_}}_ssa({{.Input}}); got != {{.Ans}} { + fmt.Printf("{{.Name}}_{{.Type_}} {{.Number}}{{.Symbol}}{{.Input}} = %d, wanted {{.Ans}}\n",got) + failed = true + } +`) + + vrf2, _ := template.New("vrf2").Parse(` + if got := {{.Name}}_{{.Type_}}_{{.FNumber}}_ssa({{.Input}}); got != {{.Ans}} { + fmt.Printf("{{.Name}}_{{.Type_}} {{.Input}}{{.Symbol}}{{.Number}} = %d, wanted {{.Ans}}\n",got) + failed = true + } +`) + + type cfncData struct { + Name, Type_, Symbol, FNumber, Number string + Ans, Input string + } + for _, s := range szs { + if len(s.u) > 0 { + for _, o := range ops { + fd := cfncData{o.name, s.name, o.symbol, "", "", "", ""} + for _, i := range s.u { + fd.Number = fmt.Sprintf("%d", i) + fd.FNumber = strings.Replace(fd.Number, "-", "Neg", -1) + + // unsigned + for _, j := range s.u { + + if o.name != "div" || j != 0 { + fd.Ans = ansU(i, j, s.name, o.symbol) + fd.Input = fmt.Sprintf("%d", j) + err = vrf1.Execute(w, fd) + if err != nil { + panic(err) + } + } + + if o.name != "div" || i != 0 { + fd.Ans = ansU(j, i, s.name, o.symbol) + fd.Input = fmt.Sprintf("%d", j) + err = vrf2.Execute(w, fd) + if err != nil { + panic(err) + } + } + + } + } + + } + } + + // signed + if len(s.i) > 0 { + for _, o := range ops { + // don't generate tests for shifts by signed integers + if o.name == "lsh" || o.name == "rsh" { + continue + } + fd := cfncData{o.name, s.name, o.symbol, "", "", "", ""} + for _, i := range s.i { + fd.Number = fmt.Sprintf("%d", i) + fd.FNumber = strings.Replace(fd.Number, "-", "Neg", -1) + for _, j := range s.i { + if o.name != "div" || j != 0 { + fd.Ans = ansS(i, j, s.name, o.symbol) + fd.Input = fmt.Sprintf("%d", j) + err = vrf1.Execute(w, fd) + if err != nil { + panic(err) + } + } + + if o.name != "div" || i != 0 { + fd.Ans = ansS(j, i, s.name, o.symbol) + fd.Input = fmt.Sprintf("%d", j) + err = vrf2.Execute(w, fd) + if err != nil { + panic(err) + } + } + + } + } + + } + } + } + + fmt.Fprintf(w, `if failed { + panic("tests failed") + } +`) + fmt.Fprintf(w, "}\n") + + // gofmt result + b := w.Bytes() + src, err := format.Source(b) + if err != nil { + fmt.Printf("%s\n", b) + panic(err) + } + + // write to file + err = ioutil.WriteFile("../arithConst_ssa.go", src, 0666) + if err != nil { + log.Fatalf("can't write output: %v\n", err) + } +} diff --git a/src/cmd/compile/internal/ssa/gen/generic.rules b/src/cmd/compile/internal/ssa/gen/generic.rules index 658d78ca32..28fe9ff878 100644 --- a/src/cmd/compile/internal/ssa/gen/generic.rules +++ b/src/cmd/compile/internal/ssa/gen/generic.rules @@ -35,6 +35,19 @@ (Mul32 (Const32 [c]) (Const32 [d])) -> (Const32 [c*d]) (Mul64 (Const64 [c]) (Const64 [d])) -> (Const64 [c*d]) +(Lsh64x64 (Const64 [c]) (Const64 [d])) -> (Const64 [c << uint64(d)]) +(Rsh64x64 (Const64 [c]) (Const64 [d])) -> (Const64 [c >> uint64(d)]) +(Rsh64Ux64 (Const64 [c]) (Const64 [d])) -> (Const64 [int64(uint64(c) >> uint64(d))]) +(Lsh32x64 (Const32 [c]) (Const64 [d])) -> (Const32 [int64(int32(c) << uint64(d))]) +(Rsh32x64 (Const32 [c]) (Const64 [d])) -> (Const32 [int64(int32(c) >> uint64(d))]) +(Rsh32Ux64 (Const32 [c]) (Const64 [d])) -> (Const32 [int64(uint32(c) >> uint64(d))]) +(Lsh16x64 (Const16 [c]) (Const64 [d])) -> (Const16 [int64(int16(c) << uint64(d))]) +(Rsh16x64 (Const16 [c]) (Const64 [d])) -> (Const16 [int64(int16(c) >> uint64(d))]) +(Rsh16Ux64 (Const16 [c]) (Const64 [d])) -> (Const16 [int64(uint16(c) >> uint64(d))]) +(Lsh8x64 (Const8 [c]) (Const64 [d])) -> (Const8 [int64(int8(c) << uint64(d))]) +(Rsh8x64 (Const8 [c]) (Const64 [d])) -> (Const8 [int64(int8(c) >> uint64(d))]) +(Rsh8Ux64 (Const8 [c]) (Const64 [d])) -> (Const8 [int64(uint8(c) >> uint64(d))]) + (IsInBounds (Const32 [c]) (Const32 [d])) -> (ConstBool [b2i(inBounds32(c,d))]) (IsInBounds (Const64 [c]) (Const64 [d])) -> (ConstBool [b2i(inBounds64(c,d))]) (IsSliceInBounds (Const32 [c]) (Const32 [d])) -> (ConstBool [b2i(sliceInBounds32(c,d))]) @@ -79,6 +92,89 @@ (Sub16 x (Const16 [c])) && x.Op != OpConst16 -> (Add16 (Const16 [-c]) x) (Sub8 x (Const8 [c])) && x.Op != OpConst8 -> (Add8 (Const8 [-c]) x) +// rewrite shifts of 8/16/32 bit consts into 64 bit consts to reduce +// the number of the other rewrite rules for const shifts +(Lsh64x32 x (Const32 [c])) -> (Lsh64x64 x (Const64 [int64(uint32(c))])) +(Lsh64x16 x (Const16 [c])) -> (Lsh64x64 x (Const64 [int64(uint16(c))])) +(Lsh64x8 x (Const8 [c])) -> (Lsh64x64 x (Const64 [int64(uint8(c))])) +(Rsh64x32 x (Const32 [c])) -> (Rsh64x64 x (Const64 [int64(uint32(c))])) +(Rsh64x16 x (Const16 [c])) -> (Rsh64x64 x (Const64 [int64(uint16(c))])) +(Rsh64x8 x (Const8 [c])) -> (Rsh64x64 x (Const64 [int64(uint8(c))])) +(Rsh64Ux32 x (Const32 [c])) -> (Rsh64Ux64 x (Const64 [int64(uint32(c))])) +(Rsh64Ux16 x (Const16 [c])) -> (Rsh64Ux64 x (Const64 [int64(uint16(c))])) +(Rsh64Ux8 x (Const8 [c])) -> (Rsh64Ux64 x (Const64 [int64(uint8(c))])) + +(Lsh32x32 x (Const32 [c])) -> (Lsh32x64 x (Const64 [int64(uint32(c))])) +(Lsh32x16 x (Const16 [c])) -> (Lsh32x64 x (Const64 [int64(uint16(c))])) +(Lsh32x8 x (Const8 [c])) -> (Lsh32x64 x (Const64 [int64(uint8(c))])) +(Rsh32x32 x (Const32 [c])) -> (Rsh32x64 x (Const64 [int64(uint32(c))])) +(Rsh32x16 x (Const16 [c])) -> (Rsh32x64 x (Const64 [int64(uint16(c))])) +(Rsh32x8 x (Const8 [c])) -> (Rsh32x64 x (Const64 [int64(uint8(c))])) +(Rsh32Ux32 x (Const32 [c])) -> (Rsh32Ux64 x (Const64 [int64(uint32(c))])) +(Rsh32Ux16 x (Const16 [c])) -> (Rsh32Ux64 x (Const64 [int64(uint16(c))])) +(Rsh32Ux8 x (Const8 [c])) -> (Rsh32Ux64 x (Const64 [int64(uint8(c))])) + +(Lsh16x32 x (Const32 [c])) -> (Lsh16x64 x (Const64 [int64(uint32(c))])) +(Lsh16x16 x (Const16 [c])) -> (Lsh16x64 x (Const64 [int64(uint16(c))])) +(Lsh16x8 x (Const8 [c])) -> (Lsh16x64 x (Const64 [int64(uint8(c))])) +(Rsh16x32 x (Const32 [c])) -> (Rsh16x64 x (Const64 [int64(uint32(c))])) +(Rsh16x16 x (Const16 [c])) -> (Rsh16x64 x (Const64 [int64(uint16(c))])) +(Rsh16x8 x (Const8 [c])) -> (Rsh16x64 x (Const64 [int64(uint8(c))])) +(Rsh16Ux32 x (Const32 [c])) -> (Rsh16Ux64 x (Const64 [int64(uint32(c))])) +(Rsh16Ux16 x (Const16 [c])) -> (Rsh16Ux64 x (Const64 [int64(uint16(c))])) +(Rsh16Ux8 x (Const8 [c])) -> (Rsh16Ux64 x (Const64 [int64(uint8(c))])) + +(Lsh8x32 x (Const32 [c])) -> (Lsh8x64 x (Const64 [int64(uint32(c))])) +(Lsh8x16 x (Const16 [c])) -> (Lsh8x64 x (Const64 [int64(uint16(c))])) +(Lsh8x8 x (Const8 [c])) -> (Lsh8x64 x (Const64 [int64(uint8(c))])) +(Rsh8x32 x (Const32 [c])) -> (Rsh8x64 x (Const64 [int64(uint32(c))])) +(Rsh8x16 x (Const16 [c])) -> (Rsh8x64 x (Const64 [int64(uint16(c))])) +(Rsh8x8 x (Const8 [c])) -> (Rsh8x64 x (Const64 [int64(uint8(c))])) +(Rsh8Ux32 x (Const32 [c])) -> (Rsh8Ux64 x (Const64 [int64(uint32(c))])) +(Rsh8Ux16 x (Const16 [c])) -> (Rsh8Ux64 x (Const64 [int64(uint16(c))])) +(Rsh8Ux8 x (Const8 [c])) -> (Rsh8Ux64 x (Const64 [int64(uint8(c))])) + +// shifts by zero +(Lsh64x64 x (Const64 [0])) -> x +(Rsh64x64 x (Const64 [0])) -> x +(Rsh64Ux64 x (Const64 [0])) -> x +(Lsh32x64 x (Const64 [0])) -> x +(Rsh32x64 x (Const64 [0])) -> x +(Rsh32Ux64 x (Const64 [0])) -> x +(Lsh16x64 x (Const64 [0])) -> x +(Rsh16x64 x (Const64 [0])) -> x +(Rsh16Ux64 x (Const64 [0])) -> x +(Lsh8x64 x (Const64 [0])) -> x +(Rsh8x64 x (Const64 [0])) -> x +(Rsh8Ux64 x (Const64 [0])) -> x + +// large left shifts of all values, and right shifts of unsigned values +(Lsh64x64 _ (Const64 [c])) && uint64(c) >= 64 -> (Const64 [0]) +(Rsh64Ux64 _ (Const64 [c])) && uint64(c) >= 64 -> (Const64 [0]) +(Lsh32x64 _ (Const64 [c])) && uint64(c) >= 32 -> (Const64 [0]) +(Rsh32Ux64 _ (Const64 [c])) && uint64(c) >= 32 -> (Const64 [0]) +(Lsh16x64 _ (Const64 [c])) && uint64(c) >= 16 -> (Const64 [0]) +(Rsh16Ux64 _ (Const64 [c])) && uint64(c) >= 16 -> (Const64 [0]) +(Lsh8x64 _ (Const64 [c])) && uint64(c) >= 8 -> (Const64 [0]) +(Rsh8Ux64 _ (Const64 [c])) && uint64(c) >= 8 -> (Const64 [0]) + + +// combine const shifts +(Lsh64x64 (Lsh64x64 x (Const64 [c])) (Const64 [d])) && !uaddOvf(c,d) -> (Lsh64x64 x (Const64 [c+d])) +(Lsh32x64 (Lsh32x64 x (Const64 [c])) (Const64 [d])) && !uaddOvf(c,d) -> (Lsh32x64 x (Const64 [c+d])) +(Lsh16x64 (Lsh16x64 x (Const64 [c])) (Const64 [d])) && !uaddOvf(c,d) -> (Lsh16x64 x (Const64 [c+d])) +(Lsh8x64 (Lsh8x64 x (Const64 [c])) (Const64 [d])) && !uaddOvf(c,d) -> (Lsh8x64 x (Const64 [c+d])) + +(Rsh64x64 (Rsh64x64 x (Const64 [c])) (Const64 [d])) && !uaddOvf(c,d) -> (Rsh64x64 x (Const64 [c+d])) +(Rsh32x64 (Rsh32x64 x (Const64 [c])) (Const64 [d])) && !uaddOvf(c,d) -> (Rsh32x64 x (Const64 [c+d])) +(Rsh16x64 (Rsh16x64 x (Const64 [c])) (Const64 [d])) && !uaddOvf(c,d) -> (Rsh16x64 x (Const64 [c+d])) +(Rsh8x64 (Rsh8x64 x (Const64 [c])) (Const64 [d])) && !uaddOvf(c,d) -> (Rsh8x64 x (Const64 [c+d])) + +(Rsh64Ux64 (Rsh64Ux64 x (Const64 [c])) (Const64 [d])) && !uaddOvf(c,d) -> (Rsh64Ux64 x (Const64 [c+d])) +(Rsh32Ux64 (Rsh32Ux64 x (Const64 [c])) (Const64 [d])) && !uaddOvf(c,d) -> (Rsh32Ux64 x (Const64 [c+d])) +(Rsh16Ux64 (Rsh16Ux64 x (Const64 [c])) (Const64 [d])) && !uaddOvf(c,d) -> (Rsh16Ux64 x (Const64 [c+d])) +(Rsh8Ux64 (Rsh8Ux64 x (Const64 [c])) (Const64 [d])) && !uaddOvf(c,d) -> (Rsh8Ux64 x (Const64 [c+d])) + // constant comparisons (Eq64 (Const64 [c]) (Const64 [d])) -> (ConstBool [b2i(int64(c) == int64(d))]) (Eq32 (Const32 [c]) (Const32 [d])) -> (ConstBool [b2i(int32(c) == int32(d))]) diff --git a/src/cmd/compile/internal/ssa/rewrite.go b/src/cmd/compile/internal/ssa/rewrite.go index f7da347263..7dd0d2e5d5 100644 --- a/src/cmd/compile/internal/ssa/rewrite.go +++ b/src/cmd/compile/internal/ssa/rewrite.go @@ -181,6 +181,11 @@ func f2i(f float64) int64 { return int64(math.Float64bits(f)) } +// uaddOvf returns true if unsigned a+b would overflow. +func uaddOvf(a, b int64) bool { + return uint64(a)+uint64(b) < uint64(a) +} + // DUFFZERO consists of repeated blocks of 4 MOVUPSs + ADD, // See runtime/mkduff.go. const ( diff --git a/src/cmd/compile/internal/ssa/rewritegeneric.go b/src/cmd/compile/internal/ssa/rewritegeneric.go index b9e4d186e9..67f07e65dc 100644 --- a/src/cmd/compile/internal/ssa/rewritegeneric.go +++ b/src/cmd/compile/internal/ssa/rewritegeneric.go @@ -135,6 +135,38 @@ func rewriteValuegeneric(v *Value, config *Config) bool { return rewriteValuegeneric_OpLess8U(v, config) case OpLoad: return rewriteValuegeneric_OpLoad(v, config) + case OpLsh16x16: + return rewriteValuegeneric_OpLsh16x16(v, config) + case OpLsh16x32: + return rewriteValuegeneric_OpLsh16x32(v, config) + case OpLsh16x64: + return rewriteValuegeneric_OpLsh16x64(v, config) + case OpLsh16x8: + return rewriteValuegeneric_OpLsh16x8(v, config) + case OpLsh32x16: + return rewriteValuegeneric_OpLsh32x16(v, config) + case OpLsh32x32: + return rewriteValuegeneric_OpLsh32x32(v, config) + case OpLsh32x64: + return rewriteValuegeneric_OpLsh32x64(v, config) + case OpLsh32x8: + return rewriteValuegeneric_OpLsh32x8(v, config) + case OpLsh64x16: + return rewriteValuegeneric_OpLsh64x16(v, config) + case OpLsh64x32: + return rewriteValuegeneric_OpLsh64x32(v, config) + case OpLsh64x64: + return rewriteValuegeneric_OpLsh64x64(v, config) + case OpLsh64x8: + return rewriteValuegeneric_OpLsh64x8(v, config) + case OpLsh8x16: + return rewriteValuegeneric_OpLsh8x16(v, config) + case OpLsh8x32: + return rewriteValuegeneric_OpLsh8x32(v, config) + case OpLsh8x64: + return rewriteValuegeneric_OpLsh8x64(v, config) + case OpLsh8x8: + return rewriteValuegeneric_OpLsh8x8(v, config) case OpMul16: return rewriteValuegeneric_OpMul16(v, config) case OpMul32: @@ -167,6 +199,70 @@ func rewriteValuegeneric(v *Value, config *Config) bool { return rewriteValuegeneric_OpOr8(v, config) case OpPtrIndex: return rewriteValuegeneric_OpPtrIndex(v, config) + case OpRsh16Ux16: + return rewriteValuegeneric_OpRsh16Ux16(v, config) + case OpRsh16Ux32: + return rewriteValuegeneric_OpRsh16Ux32(v, config) + case OpRsh16Ux64: + return rewriteValuegeneric_OpRsh16Ux64(v, config) + case OpRsh16Ux8: + return rewriteValuegeneric_OpRsh16Ux8(v, config) + case OpRsh16x16: + return rewriteValuegeneric_OpRsh16x16(v, config) + case OpRsh16x32: + return rewriteValuegeneric_OpRsh16x32(v, config) + case OpRsh16x64: + return rewriteValuegeneric_OpRsh16x64(v, config) + case OpRsh16x8: + return rewriteValuegeneric_OpRsh16x8(v, config) + case OpRsh32Ux16: + return rewriteValuegeneric_OpRsh32Ux16(v, config) + case OpRsh32Ux32: + return rewriteValuegeneric_OpRsh32Ux32(v, config) + case OpRsh32Ux64: + return rewriteValuegeneric_OpRsh32Ux64(v, config) + case OpRsh32Ux8: + return rewriteValuegeneric_OpRsh32Ux8(v, config) + case OpRsh32x16: + return rewriteValuegeneric_OpRsh32x16(v, config) + case OpRsh32x32: + return rewriteValuegeneric_OpRsh32x32(v, config) + case OpRsh32x64: + return rewriteValuegeneric_OpRsh32x64(v, config) + case OpRsh32x8: + return rewriteValuegeneric_OpRsh32x8(v, config) + case OpRsh64Ux16: + return rewriteValuegeneric_OpRsh64Ux16(v, config) + case OpRsh64Ux32: + return rewriteValuegeneric_OpRsh64Ux32(v, config) + case OpRsh64Ux64: + return rewriteValuegeneric_OpRsh64Ux64(v, config) + case OpRsh64Ux8: + return rewriteValuegeneric_OpRsh64Ux8(v, config) + case OpRsh64x16: + return rewriteValuegeneric_OpRsh64x16(v, config) + case OpRsh64x32: + return rewriteValuegeneric_OpRsh64x32(v, config) + case OpRsh64x64: + return rewriteValuegeneric_OpRsh64x64(v, config) + case OpRsh64x8: + return rewriteValuegeneric_OpRsh64x8(v, config) + case OpRsh8Ux16: + return rewriteValuegeneric_OpRsh8Ux16(v, config) + case OpRsh8Ux32: + return rewriteValuegeneric_OpRsh8Ux32(v, config) + case OpRsh8Ux64: + return rewriteValuegeneric_OpRsh8Ux64(v, config) + case OpRsh8Ux8: + return rewriteValuegeneric_OpRsh8Ux8(v, config) + case OpRsh8x16: + return rewriteValuegeneric_OpRsh8x16(v, config) + case OpRsh8x32: + return rewriteValuegeneric_OpRsh8x32(v, config) + case OpRsh8x64: + return rewriteValuegeneric_OpRsh8x64(v, config) + case OpRsh8x8: + return rewriteValuegeneric_OpRsh8x8(v, config) case OpSliceCap: return rewriteValuegeneric_OpSliceCap(v, config) case OpSliceLen: @@ -242,8 +338,7 @@ end359c546ef662b7990116329cb30d6892: v.AuxInt = 0 v.Aux = nil v.resetArgs() - v0 := b.NewValue0(v.Line, OpConst16, TypeInvalid) - v0.Type = t + v0 := b.NewValue0(v.Line, OpConst16, t) v0.AuxInt = c v.AddArg(v0) v.AddArg(x) @@ -296,8 +391,7 @@ enda3edaa9a512bd1d7a95f002c890bfb88: v.AuxInt = 0 v.Aux = nil v.resetArgs() - v0 := b.NewValue0(v.Line, OpConst32, TypeInvalid) - v0.Type = t + v0 := b.NewValue0(v.Line, OpConst32, t) v0.AuxInt = c v.AddArg(v0) v.AddArg(x) @@ -350,8 +444,7 @@ end8c46df6f85a11cb1d594076b0e467908: v.AuxInt = 0 v.Aux = nil v.resetArgs() - v0 := b.NewValue0(v.Line, OpConst64, TypeInvalid) - v0.Type = t + v0 := b.NewValue0(v.Line, OpConst64, t) v0.AuxInt = c v.AddArg(v0) v.AddArg(x) @@ -404,8 +497,7 @@ end60c66721511a442aade8e4da2fb326bd: v.AuxInt = 0 v.Aux = nil v.resetArgs() - v0 := b.NewValue0(v.Line, OpConst8, TypeInvalid) - v0.Type = t + v0 := b.NewValue0(v.Line, OpConst8, t) v0.AuxInt = c v.AddArg(v0) v.AddArg(x) @@ -1234,8 +1326,7 @@ end0c0fe5fdfba3821add3448fd3f1fc6b7: v.AuxInt = 0 v.Aux = nil v.resetArgs() - v0 := b.NewValue0(v.Line, OpConst16, TypeInvalid) - v0.Type = t + v0 := b.NewValue0(v.Line, OpConst16, t) v0.AuxInt = c - d v.AddArg(v0) v.AddArg(x) @@ -1261,8 +1352,7 @@ end79c830afa265161fc0f0532c4c4e7f50: v.AuxInt = 0 v.Aux = nil v.resetArgs() - v0 := b.NewValue0(v.Line, OpConst16, TypeInvalid) - v0.Type = t + v0 := b.NewValue0(v.Line, OpConst16, t) v0.AuxInt = c v.AddArg(v0) v.AddArg(x) @@ -1340,8 +1430,7 @@ end6da547ec4ee93d787434f3bda873e4a0: v.AuxInt = 0 v.Aux = nil v.resetArgs() - v0 := b.NewValue0(v.Line, OpConst32, TypeInvalid) - v0.Type = t + v0 := b.NewValue0(v.Line, OpConst32, t) v0.AuxInt = c - d v.AddArg(v0) v.AddArg(x) @@ -1367,8 +1456,7 @@ end1a69730a32c6e432784dcdf643320ecd: v.AuxInt = 0 v.Aux = nil v.resetArgs() - v0 := b.NewValue0(v.Line, OpConst32, TypeInvalid) - v0.Type = t + v0 := b.NewValue0(v.Line, OpConst32, t) v0.AuxInt = c v.AddArg(v0) v.AddArg(x) @@ -1446,8 +1534,7 @@ endb1d471cc503ba8bb05440f01dbf33d81: v.AuxInt = 0 v.Aux = nil v.resetArgs() - v0 := b.NewValue0(v.Line, OpConst64, TypeInvalid) - v0.Type = t + v0 := b.NewValue0(v.Line, OpConst64, t) v0.AuxInt = c - d v.AddArg(v0) v.AddArg(x) @@ -1473,8 +1560,7 @@ endffd67f3b83f6972cd459153d318f714d: v.AuxInt = 0 v.Aux = nil v.resetArgs() - v0 := b.NewValue0(v.Line, OpConst64, TypeInvalid) - v0.Type = t + v0 := b.NewValue0(v.Line, OpConst64, t) v0.AuxInt = c v.AddArg(v0) v.AddArg(x) @@ -1552,8 +1638,7 @@ enda66da0d3e7e51624ee46527727c48a9a: v.AuxInt = 0 v.Aux = nil v.resetArgs() - v0 := b.NewValue0(v.Line, OpConst8, TypeInvalid) - v0.Type = t + v0 := b.NewValue0(v.Line, OpConst8, t) v0.AuxInt = c - d v.AddArg(v0) v.AddArg(x) @@ -1579,8 +1664,7 @@ end6912961350bb485f56ef176522aa683b: v.AuxInt = 0 v.Aux = nil v.resetArgs() - v0 := b.NewValue0(v.Line, OpConst8, TypeInvalid) - v0.Type = t + v0 := b.NewValue0(v.Line, OpConst8, t) v0.AuxInt = c v.AddArg(v0) v.AddArg(x) @@ -3033,713 +3117,2861 @@ end12671c83ebe3ccbc8e53383765ee7675: ; return false } -func rewriteValuegeneric_OpMul16(v *Value, config *Config) bool { +func rewriteValuegeneric_OpLsh16x16(v *Value, config *Config) bool { b := v.Block _ = b - // match: (Mul16 (Const16 [c]) (Const16 [d])) + // match: (Lsh16x16 x (Const16 [c])) // cond: - // result: (Const16 [c*d]) + // result: (Lsh16x64 x (Const64 [int64(uint16(c))])) { - if v.Args[0].Op != OpConst16 { - goto ende8dd468add3015aea24531cf3c89ccb7 - } - c := v.Args[0].AuxInt + t := v.Type + x := v.Args[0] if v.Args[1].Op != OpConst16 { - goto ende8dd468add3015aea24531cf3c89ccb7 + goto end2f5aa78b30ebd2471e8d03a307923b06 } - d := v.Args[1].AuxInt - v.Op = OpConst16 + c := v.Args[1].AuxInt + v.Op = OpLsh16x64 v.AuxInt = 0 v.Aux = nil v.resetArgs() - v.AuxInt = c * d + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint16(c)) + v.AddArg(v0) return true } - goto ende8dd468add3015aea24531cf3c89ccb7 -ende8dd468add3015aea24531cf3c89ccb7: + goto end2f5aa78b30ebd2471e8d03a307923b06 +end2f5aa78b30ebd2471e8d03a307923b06: ; return false } -func rewriteValuegeneric_OpMul32(v *Value, config *Config) bool { +func rewriteValuegeneric_OpLsh16x32(v *Value, config *Config) bool { b := v.Block _ = b - // match: (Mul32 (Const32 [c]) (Const32 [d])) + // match: (Lsh16x32 x (Const32 [c])) // cond: - // result: (Const32 [c*d]) + // result: (Lsh16x64 x (Const64 [int64(uint32(c))])) { - if v.Args[0].Op != OpConst32 { - goto end60b4523099fa7b55e2e872e05bd497a7 - } - c := v.Args[0].AuxInt + t := v.Type + x := v.Args[0] if v.Args[1].Op != OpConst32 { - goto end60b4523099fa7b55e2e872e05bd497a7 + goto endedeb000c8c97090261a47f08a2ff17e4 } - d := v.Args[1].AuxInt - v.Op = OpConst32 + c := v.Args[1].AuxInt + v.Op = OpLsh16x64 v.AuxInt = 0 v.Aux = nil v.resetArgs() - v.AuxInt = c * d + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint32(c)) + v.AddArg(v0) return true } - goto end60b4523099fa7b55e2e872e05bd497a7 -end60b4523099fa7b55e2e872e05bd497a7: + goto endedeb000c8c97090261a47f08a2ff17e4 +endedeb000c8c97090261a47f08a2ff17e4: ; return false } -func rewriteValuegeneric_OpMul64(v *Value, config *Config) bool { +func rewriteValuegeneric_OpLsh16x64(v *Value, config *Config) bool { b := v.Block _ = b - // match: (Mul64 (Const64 [c]) (Const64 [d])) + // match: (Lsh16x64 (Const16 [c]) (Const64 [d])) // cond: - // result: (Const64 [c*d]) + // result: (Const16 [int64(int16(c) << uint64(d))]) { - if v.Args[0].Op != OpConst64 { - goto end7aea1048b5d1230974b97f17238380ae + if v.Args[0].Op != OpConst16 { + goto endc9f0d91f3da4bdd46a634a62549810e0 } c := v.Args[0].AuxInt if v.Args[1].Op != OpConst64 { - goto end7aea1048b5d1230974b97f17238380ae + goto endc9f0d91f3da4bdd46a634a62549810e0 } d := v.Args[1].AuxInt - v.Op = OpConst64 + v.Op = OpConst16 v.AuxInt = 0 v.Aux = nil v.resetArgs() - v.AuxInt = c * d + v.AuxInt = int64(int16(c) << uint64(d)) return true } - goto end7aea1048b5d1230974b97f17238380ae -end7aea1048b5d1230974b97f17238380ae: + goto endc9f0d91f3da4bdd46a634a62549810e0 +endc9f0d91f3da4bdd46a634a62549810e0: ; - return false -} -func rewriteValuegeneric_OpMul8(v *Value, config *Config) bool { - b := v.Block - _ = b - // match: (Mul8 (Const8 [c]) (Const8 [d])) + // match: (Lsh16x64 x (Const64 [0])) // cond: - // result: (Const8 [c*d]) + // result: x { - if v.Args[0].Op != OpConst8 { - goto end2f1952fd654c4a62ff00511041728809 + x := v.Args[0] + if v.Args[1].Op != OpConst64 { + goto end7ecc343739fab9b50a0bdff6e9d121e6 } - c := v.Args[0].AuxInt - if v.Args[1].Op != OpConst8 { - goto end2f1952fd654c4a62ff00511041728809 + if v.Args[1].AuxInt != 0 { + goto end7ecc343739fab9b50a0bdff6e9d121e6 } - d := v.Args[1].AuxInt - v.Op = OpConst8 + v.Op = OpCopy v.AuxInt = 0 v.Aux = nil v.resetArgs() - v.AuxInt = c * d + v.Type = x.Type + v.AddArg(x) return true } - goto end2f1952fd654c4a62ff00511041728809 -end2f1952fd654c4a62ff00511041728809: + goto end7ecc343739fab9b50a0bdff6e9d121e6 +end7ecc343739fab9b50a0bdff6e9d121e6: ; - return false -} -func rewriteValuegeneric_OpNeq16(v *Value, config *Config) bool { - b := v.Block - _ = b - // match: (Neq16 x x) - // cond: - // result: (ConstBool [0]) + // match: (Lsh16x64 _ (Const64 [c])) + // cond: uint64(c) >= 16 + // result: (Const64 [0]) { - x := v.Args[0] - if v.Args[1] != x { - goto ende76a50b524aeb16c7aeccf5f5cc60c06 + if v.Args[1].Op != OpConst64 { + goto end1d2c74d359df9d89b16c4f658a231dfe } - v.Op = OpConstBool + c := v.Args[1].AuxInt + if !(uint64(c) >= 16) { + goto end1d2c74d359df9d89b16c4f658a231dfe + } + v.Op = OpConst64 v.AuxInt = 0 v.Aux = nil v.resetArgs() v.AuxInt = 0 return true } - goto ende76a50b524aeb16c7aeccf5f5cc60c06 -ende76a50b524aeb16c7aeccf5f5cc60c06: + goto end1d2c74d359df9d89b16c4f658a231dfe +end1d2c74d359df9d89b16c4f658a231dfe: ; - // match: (Neq16 (Const16 [c]) (Add16 (Const16 [d]) x)) - // cond: - // result: (Neq16 (Const16 [c-d]) x) + // match: (Lsh16x64 (Lsh16x64 x (Const64 [c])) (Const64 [d])) + // cond: !uaddOvf(c,d) + // result: (Lsh16x64 x (Const64 [c+d])) { - if v.Args[0].Op != OpConst16 { - goto end552011bd97e6f92ebc2672aa1843eadd + t := v.Type + if v.Args[0].Op != OpLsh16x64 { + goto end26a91e42735a02a30e94a998f54372dd } - t := v.Args[0].Type - c := v.Args[0].AuxInt - if v.Args[1].Op != OpAdd16 { - goto end552011bd97e6f92ebc2672aa1843eadd + x := v.Args[0].Args[0] + if v.Args[0].Args[1].Op != OpConst64 { + goto end26a91e42735a02a30e94a998f54372dd } - if v.Args[1].Args[0].Op != OpConst16 { - goto end552011bd97e6f92ebc2672aa1843eadd + c := v.Args[0].Args[1].AuxInt + if v.Args[1].Op != OpConst64 { + goto end26a91e42735a02a30e94a998f54372dd } - if v.Args[1].Args[0].Type != v.Args[0].Type { - goto end552011bd97e6f92ebc2672aa1843eadd + d := v.Args[1].AuxInt + if !(!uaddOvf(c, d)) { + goto end26a91e42735a02a30e94a998f54372dd } - d := v.Args[1].Args[0].AuxInt - x := v.Args[1].Args[1] - v.Op = OpNeq16 + v.Op = OpLsh16x64 v.AuxInt = 0 v.Aux = nil v.resetArgs() - v0 := b.NewValue0(v.Line, OpConst16, TypeInvalid) - v0.Type = t - v0.AuxInt = c - d - v.AddArg(v0) v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = c + d + v.AddArg(v0) return true } - goto end552011bd97e6f92ebc2672aa1843eadd -end552011bd97e6f92ebc2672aa1843eadd: + goto end26a91e42735a02a30e94a998f54372dd +end26a91e42735a02a30e94a998f54372dd: ; - // match: (Neq16 x (Const16 [c])) - // cond: x.Op != OpConst16 - // result: (Neq16 (Const16 [c]) x) + return false +} +func rewriteValuegeneric_OpLsh16x8(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Lsh16x8 x (Const8 [c])) + // cond: + // result: (Lsh16x64 x (Const64 [int64(uint8(c))])) { + t := v.Type x := v.Args[0] - if v.Args[1].Op != OpConst16 { - goto end0e45958f29e87997f632248aa9ee97e0 + if v.Args[1].Op != OpConst8 { + goto endce2401b8a6c6190fe81d77e2d562a10c } - t := v.Args[1].Type c := v.Args[1].AuxInt - if !(x.Op != OpConst16) { - goto end0e45958f29e87997f632248aa9ee97e0 - } - v.Op = OpNeq16 + v.Op = OpLsh16x64 v.AuxInt = 0 v.Aux = nil v.resetArgs() - v0 := b.NewValue0(v.Line, OpConst16, TypeInvalid) - v0.Type = t - v0.AuxInt = c - v.AddArg(v0) v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint8(c)) + v.AddArg(v0) return true } - goto end0e45958f29e87997f632248aa9ee97e0 -end0e45958f29e87997f632248aa9ee97e0: + goto endce2401b8a6c6190fe81d77e2d562a10c +endce2401b8a6c6190fe81d77e2d562a10c: ; - // match: (Neq16 (Const16 [c]) (Const16 [d])) + return false +} +func rewriteValuegeneric_OpLsh32x16(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Lsh32x16 x (Const16 [c])) // cond: - // result: (ConstBool [b2i(int16(c) != int16(d))]) + // result: (Lsh32x64 x (Const64 [int64(uint16(c))])) { - if v.Args[0].Op != OpConst16 { - goto end6302c9b645bb191982d28c2f846904d6 - } - c := v.Args[0].AuxInt + t := v.Type + x := v.Args[0] if v.Args[1].Op != OpConst16 { - goto end6302c9b645bb191982d28c2f846904d6 + goto end7205eb3e315971143ac5584d07045570 } - d := v.Args[1].AuxInt - v.Op = OpConstBool + c := v.Args[1].AuxInt + v.Op = OpLsh32x64 v.AuxInt = 0 v.Aux = nil v.resetArgs() - v.AuxInt = b2i(int16(c) != int16(d)) + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint16(c)) + v.AddArg(v0) return true } - goto end6302c9b645bb191982d28c2f846904d6 -end6302c9b645bb191982d28c2f846904d6: + goto end7205eb3e315971143ac5584d07045570 +end7205eb3e315971143ac5584d07045570: ; return false } -func rewriteValuegeneric_OpNeq32(v *Value, config *Config) bool { +func rewriteValuegeneric_OpLsh32x32(v *Value, config *Config) bool { b := v.Block _ = b - // match: (Neq32 x x) + // match: (Lsh32x32 x (Const32 [c])) // cond: - // result: (ConstBool [0]) + // result: (Lsh32x64 x (Const64 [int64(uint32(c))])) { + t := v.Type x := v.Args[0] - if v.Args[1] != x { - goto end3713a608cffd29b40ff7c3b3f2585cbb + if v.Args[1].Op != OpConst32 { + goto endc1a330b287199c80228e665a53881298 } - v.Op = OpConstBool + c := v.Args[1].AuxInt + v.Op = OpLsh32x64 v.AuxInt = 0 v.Aux = nil v.resetArgs() - v.AuxInt = 0 + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint32(c)) + v.AddArg(v0) return true } - goto end3713a608cffd29b40ff7c3b3f2585cbb -end3713a608cffd29b40ff7c3b3f2585cbb: + goto endc1a330b287199c80228e665a53881298 +endc1a330b287199c80228e665a53881298: ; - // match: (Neq32 (Const32 [c]) (Add32 (Const32 [d]) x)) + return false +} +func rewriteValuegeneric_OpLsh32x64(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Lsh32x64 (Const32 [c]) (Const64 [d])) // cond: - // result: (Neq32 (Const32 [c-d]) x) + // result: (Const32 [int64(int32(c) << uint64(d))]) { if v.Args[0].Op != OpConst32 { - goto end93fc3b4a3639b965b414891111b16245 + goto end5896bd9a3fe78f1e1712563642d33254 } - t := v.Args[0].Type c := v.Args[0].AuxInt - if v.Args[1].Op != OpAdd32 { - goto end93fc3b4a3639b965b414891111b16245 + if v.Args[1].Op != OpConst64 { + goto end5896bd9a3fe78f1e1712563642d33254 } - if v.Args[1].Args[0].Op != OpConst32 { - goto end93fc3b4a3639b965b414891111b16245 + d := v.Args[1].AuxInt + v.Op = OpConst32 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AuxInt = int64(int32(c) << uint64(d)) + return true + } + goto end5896bd9a3fe78f1e1712563642d33254 +end5896bd9a3fe78f1e1712563642d33254: + ; + // match: (Lsh32x64 x (Const64 [0])) + // cond: + // result: x + { + x := v.Args[0] + if v.Args[1].Op != OpConst64 { + goto endd9ce9639a91b11e601823be3d4d6c209 } - if v.Args[1].Args[0].Type != v.Args[0].Type { - goto end93fc3b4a3639b965b414891111b16245 + if v.Args[1].AuxInt != 0 { + goto endd9ce9639a91b11e601823be3d4d6c209 } - d := v.Args[1].Args[0].AuxInt - x := v.Args[1].Args[1] - v.Op = OpNeq32 + v.Op = OpCopy v.AuxInt = 0 v.Aux = nil v.resetArgs() - v0 := b.NewValue0(v.Line, OpConst32, TypeInvalid) - v0.Type = t - v0.AuxInt = c - d - v.AddArg(v0) + v.Type = x.Type v.AddArg(x) return true } - goto end93fc3b4a3639b965b414891111b16245 -end93fc3b4a3639b965b414891111b16245: + goto endd9ce9639a91b11e601823be3d4d6c209 +endd9ce9639a91b11e601823be3d4d6c209: ; - // match: (Neq32 x (Const32 [c])) - // cond: x.Op != OpConst32 - // result: (Neq32 (Const32 [c]) x) + // match: (Lsh32x64 _ (Const64 [c])) + // cond: uint64(c) >= 32 + // result: (Const64 [0]) { - x := v.Args[0] - if v.Args[1].Op != OpConst32 { - goto end5376f9ab90e282450f49011d0e0ce236 + if v.Args[1].Op != OpConst64 { + goto end81247a2423f489be15859d3930738fdf } - t := v.Args[1].Type c := v.Args[1].AuxInt - if !(x.Op != OpConst32) { - goto end5376f9ab90e282450f49011d0e0ce236 + if !(uint64(c) >= 32) { + goto end81247a2423f489be15859d3930738fdf } - v.Op = OpNeq32 + v.Op = OpConst64 v.AuxInt = 0 v.Aux = nil v.resetArgs() - v0 := b.NewValue0(v.Line, OpConst32, TypeInvalid) - v0.Type = t - v0.AuxInt = c - v.AddArg(v0) - v.AddArg(x) + v.AuxInt = 0 return true } - goto end5376f9ab90e282450f49011d0e0ce236 -end5376f9ab90e282450f49011d0e0ce236: + goto end81247a2423f489be15859d3930738fdf +end81247a2423f489be15859d3930738fdf: ; - // match: (Neq32 (Const32 [c]) (Const32 [d])) - // cond: - // result: (ConstBool [b2i(int32(c) != int32(d))]) + // match: (Lsh32x64 (Lsh32x64 x (Const64 [c])) (Const64 [d])) + // cond: !uaddOvf(c,d) + // result: (Lsh32x64 x (Const64 [c+d])) { - if v.Args[0].Op != OpConst32 { - goto endf9f3d0814854d2d0879d331e9bdfcae2 + t := v.Type + if v.Args[0].Op != OpLsh32x64 { + goto endf96a7c9571797fe61a5b63a4923d7e6e } - c := v.Args[0].AuxInt - if v.Args[1].Op != OpConst32 { - goto endf9f3d0814854d2d0879d331e9bdfcae2 + x := v.Args[0].Args[0] + if v.Args[0].Args[1].Op != OpConst64 { + goto endf96a7c9571797fe61a5b63a4923d7e6e + } + c := v.Args[0].Args[1].AuxInt + if v.Args[1].Op != OpConst64 { + goto endf96a7c9571797fe61a5b63a4923d7e6e } d := v.Args[1].AuxInt - v.Op = OpConstBool + if !(!uaddOvf(c, d)) { + goto endf96a7c9571797fe61a5b63a4923d7e6e + } + v.Op = OpLsh32x64 v.AuxInt = 0 v.Aux = nil v.resetArgs() - v.AuxInt = b2i(int32(c) != int32(d)) + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = c + d + v.AddArg(v0) return true } - goto endf9f3d0814854d2d0879d331e9bdfcae2 -endf9f3d0814854d2d0879d331e9bdfcae2: + goto endf96a7c9571797fe61a5b63a4923d7e6e +endf96a7c9571797fe61a5b63a4923d7e6e: ; return false } -func rewriteValuegeneric_OpNeq64(v *Value, config *Config) bool { +func rewriteValuegeneric_OpLsh32x8(v *Value, config *Config) bool { b := v.Block _ = b - // match: (Neq64 x x) + // match: (Lsh32x8 x (Const8 [c])) // cond: - // result: (ConstBool [0]) + // result: (Lsh32x64 x (Const64 [int64(uint8(c))])) { + t := v.Type x := v.Args[0] - if v.Args[1] != x { - goto end3601ad382705ea12b79d2008c1e5725c + if v.Args[1].Op != OpConst8 { + goto end1759d7c25a5bcda288e34d1d197c0b8f } - v.Op = OpConstBool + c := v.Args[1].AuxInt + v.Op = OpLsh32x64 v.AuxInt = 0 v.Aux = nil v.resetArgs() + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint8(c)) + v.AddArg(v0) + return true + } + goto end1759d7c25a5bcda288e34d1d197c0b8f +end1759d7c25a5bcda288e34d1d197c0b8f: + ; + return false +} +func rewriteValuegeneric_OpLsh64x16(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Lsh64x16 x (Const16 [c])) + // cond: + // result: (Lsh64x64 x (Const64 [int64(uint16(c))])) + { + t := v.Type + x := v.Args[0] + if v.Args[1].Op != OpConst16 { + goto enda649fbb5e14490c9eea9616550a76b5c + } + c := v.Args[1].AuxInt + v.Op = OpLsh64x64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint16(c)) + v.AddArg(v0) + return true + } + goto enda649fbb5e14490c9eea9616550a76b5c +enda649fbb5e14490c9eea9616550a76b5c: + ; + return false +} +func rewriteValuegeneric_OpLsh64x32(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Lsh64x32 x (Const32 [c])) + // cond: + // result: (Lsh64x64 x (Const64 [int64(uint32(c))])) + { + t := v.Type + x := v.Args[0] + if v.Args[1].Op != OpConst32 { + goto end40069675cde851a63cce81b1b02751f9 + } + c := v.Args[1].AuxInt + v.Op = OpLsh64x64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint32(c)) + v.AddArg(v0) + return true + } + goto end40069675cde851a63cce81b1b02751f9 +end40069675cde851a63cce81b1b02751f9: + ; + return false +} +func rewriteValuegeneric_OpLsh64x64(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Lsh64x64 (Const64 [c]) (Const64 [d])) + // cond: + // result: (Const64 [c << uint64(d)]) + { + if v.Args[0].Op != OpConst64 { + goto end9c157a23e021f659f1568566435ed57b + } + c := v.Args[0].AuxInt + if v.Args[1].Op != OpConst64 { + goto end9c157a23e021f659f1568566435ed57b + } + d := v.Args[1].AuxInt + v.Op = OpConst64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AuxInt = c << uint64(d) + return true + } + goto end9c157a23e021f659f1568566435ed57b +end9c157a23e021f659f1568566435ed57b: + ; + // match: (Lsh64x64 x (Const64 [0])) + // cond: + // result: x + { + x := v.Args[0] + if v.Args[1].Op != OpConst64 { + goto end9f18ca0556dbb4b50fe888273fab20ca + } + if v.Args[1].AuxInt != 0 { + goto end9f18ca0556dbb4b50fe888273fab20ca + } + v.Op = OpCopy + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.Type = x.Type + v.AddArg(x) + return true + } + goto end9f18ca0556dbb4b50fe888273fab20ca +end9f18ca0556dbb4b50fe888273fab20ca: + ; + // match: (Lsh64x64 _ (Const64 [c])) + // cond: uint64(c) >= 64 + // result: (Const64 [0]) + { + if v.Args[1].Op != OpConst64 { + goto end33da2e0ce5ca3e0554564477ef422402 + } + c := v.Args[1].AuxInt + if !(uint64(c) >= 64) { + goto end33da2e0ce5ca3e0554564477ef422402 + } + v.Op = OpConst64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AuxInt = 0 + return true + } + goto end33da2e0ce5ca3e0554564477ef422402 +end33da2e0ce5ca3e0554564477ef422402: + ; + // match: (Lsh64x64 (Lsh64x64 x (Const64 [c])) (Const64 [d])) + // cond: !uaddOvf(c,d) + // result: (Lsh64x64 x (Const64 [c+d])) + { + t := v.Type + if v.Args[0].Op != OpLsh64x64 { + goto end001c62ee580a700ec7b07ccaa3740ac2 + } + x := v.Args[0].Args[0] + if v.Args[0].Args[1].Op != OpConst64 { + goto end001c62ee580a700ec7b07ccaa3740ac2 + } + c := v.Args[0].Args[1].AuxInt + if v.Args[1].Op != OpConst64 { + goto end001c62ee580a700ec7b07ccaa3740ac2 + } + d := v.Args[1].AuxInt + if !(!uaddOvf(c, d)) { + goto end001c62ee580a700ec7b07ccaa3740ac2 + } + v.Op = OpLsh64x64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = c + d + v.AddArg(v0) + return true + } + goto end001c62ee580a700ec7b07ccaa3740ac2 +end001c62ee580a700ec7b07ccaa3740ac2: + ; + return false +} +func rewriteValuegeneric_OpLsh64x8(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Lsh64x8 x (Const8 [c])) + // cond: + // result: (Lsh64x64 x (Const64 [int64(uint8(c))])) + { + t := v.Type + x := v.Args[0] + if v.Args[1].Op != OpConst8 { + goto end4d9224069abdade8e405df343938d932 + } + c := v.Args[1].AuxInt + v.Op = OpLsh64x64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint8(c)) + v.AddArg(v0) + return true + } + goto end4d9224069abdade8e405df343938d932 +end4d9224069abdade8e405df343938d932: + ; + return false +} +func rewriteValuegeneric_OpLsh8x16(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Lsh8x16 x (Const16 [c])) + // cond: + // result: (Lsh8x64 x (Const64 [int64(uint16(c))])) + { + t := v.Type + x := v.Args[0] + if v.Args[1].Op != OpConst16 { + goto end0ad4a82e2eb4c7ca7407d79ec3aa5142 + } + c := v.Args[1].AuxInt + v.Op = OpLsh8x64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint16(c)) + v.AddArg(v0) + return true + } + goto end0ad4a82e2eb4c7ca7407d79ec3aa5142 +end0ad4a82e2eb4c7ca7407d79ec3aa5142: + ; + return false +} +func rewriteValuegeneric_OpLsh8x32(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Lsh8x32 x (Const32 [c])) + // cond: + // result: (Lsh8x64 x (Const64 [int64(uint32(c))])) + { + t := v.Type + x := v.Args[0] + if v.Args[1].Op != OpConst32 { + goto enddaacda113ecc79fe0621fd22ebc548dd + } + c := v.Args[1].AuxInt + v.Op = OpLsh8x64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint32(c)) + v.AddArg(v0) + return true + } + goto enddaacda113ecc79fe0621fd22ebc548dd +enddaacda113ecc79fe0621fd22ebc548dd: + ; + return false +} +func rewriteValuegeneric_OpLsh8x64(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Lsh8x64 (Const8 [c]) (Const64 [d])) + // cond: + // result: (Const8 [int64(int8(c) << uint64(d))]) + { + if v.Args[0].Op != OpConst8 { + goto endbc3297ea9642b97eb71f0a9735048d7b + } + c := v.Args[0].AuxInt + if v.Args[1].Op != OpConst64 { + goto endbc3297ea9642b97eb71f0a9735048d7b + } + d := v.Args[1].AuxInt + v.Op = OpConst8 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AuxInt = int64(int8(c) << uint64(d)) + return true + } + goto endbc3297ea9642b97eb71f0a9735048d7b +endbc3297ea9642b97eb71f0a9735048d7b: + ; + // match: (Lsh8x64 x (Const64 [0])) + // cond: + // result: x + { + x := v.Args[0] + if v.Args[1].Op != OpConst64 { + goto end715f3db41cccf963e25a20c33f618a04 + } + if v.Args[1].AuxInt != 0 { + goto end715f3db41cccf963e25a20c33f618a04 + } + v.Op = OpCopy + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.Type = x.Type + v.AddArg(x) + return true + } + goto end715f3db41cccf963e25a20c33f618a04 +end715f3db41cccf963e25a20c33f618a04: + ; + // match: (Lsh8x64 _ (Const64 [c])) + // cond: uint64(c) >= 8 + // result: (Const64 [0]) + { + if v.Args[1].Op != OpConst64 { + goto endb6749df4d0cdc0cd9acc627187d73488 + } + c := v.Args[1].AuxInt + if !(uint64(c) >= 8) { + goto endb6749df4d0cdc0cd9acc627187d73488 + } + v.Op = OpConst64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AuxInt = 0 + return true + } + goto endb6749df4d0cdc0cd9acc627187d73488 +endb6749df4d0cdc0cd9acc627187d73488: + ; + // match: (Lsh8x64 (Lsh8x64 x (Const64 [c])) (Const64 [d])) + // cond: !uaddOvf(c,d) + // result: (Lsh8x64 x (Const64 [c+d])) + { + t := v.Type + if v.Args[0].Op != OpLsh8x64 { + goto end73a4878b6bbd21c9e22fb99226ef947e + } + x := v.Args[0].Args[0] + if v.Args[0].Args[1].Op != OpConst64 { + goto end73a4878b6bbd21c9e22fb99226ef947e + } + c := v.Args[0].Args[1].AuxInt + if v.Args[1].Op != OpConst64 { + goto end73a4878b6bbd21c9e22fb99226ef947e + } + d := v.Args[1].AuxInt + if !(!uaddOvf(c, d)) { + goto end73a4878b6bbd21c9e22fb99226ef947e + } + v.Op = OpLsh8x64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = c + d + v.AddArg(v0) + return true + } + goto end73a4878b6bbd21c9e22fb99226ef947e +end73a4878b6bbd21c9e22fb99226ef947e: + ; + return false +} +func rewriteValuegeneric_OpLsh8x8(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Lsh8x8 x (Const8 [c])) + // cond: + // result: (Lsh8x64 x (Const64 [int64(uint8(c))])) + { + t := v.Type + x := v.Args[0] + if v.Args[1].Op != OpConst8 { + goto end8b770597435467b0c96014624d522b33 + } + c := v.Args[1].AuxInt + v.Op = OpLsh8x64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint8(c)) + v.AddArg(v0) + return true + } + goto end8b770597435467b0c96014624d522b33 +end8b770597435467b0c96014624d522b33: + ; + return false +} +func rewriteValuegeneric_OpMul16(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Mul16 (Const16 [c]) (Const16 [d])) + // cond: + // result: (Const16 [c*d]) + { + if v.Args[0].Op != OpConst16 { + goto ende8dd468add3015aea24531cf3c89ccb7 + } + c := v.Args[0].AuxInt + if v.Args[1].Op != OpConst16 { + goto ende8dd468add3015aea24531cf3c89ccb7 + } + d := v.Args[1].AuxInt + v.Op = OpConst16 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AuxInt = c * d + return true + } + goto ende8dd468add3015aea24531cf3c89ccb7 +ende8dd468add3015aea24531cf3c89ccb7: + ; + return false +} +func rewriteValuegeneric_OpMul32(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Mul32 (Const32 [c]) (Const32 [d])) + // cond: + // result: (Const32 [c*d]) + { + if v.Args[0].Op != OpConst32 { + goto end60b4523099fa7b55e2e872e05bd497a7 + } + c := v.Args[0].AuxInt + if v.Args[1].Op != OpConst32 { + goto end60b4523099fa7b55e2e872e05bd497a7 + } + d := v.Args[1].AuxInt + v.Op = OpConst32 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AuxInt = c * d + return true + } + goto end60b4523099fa7b55e2e872e05bd497a7 +end60b4523099fa7b55e2e872e05bd497a7: + ; + return false +} +func rewriteValuegeneric_OpMul64(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Mul64 (Const64 [c]) (Const64 [d])) + // cond: + // result: (Const64 [c*d]) + { + if v.Args[0].Op != OpConst64 { + goto end7aea1048b5d1230974b97f17238380ae + } + c := v.Args[0].AuxInt + if v.Args[1].Op != OpConst64 { + goto end7aea1048b5d1230974b97f17238380ae + } + d := v.Args[1].AuxInt + v.Op = OpConst64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AuxInt = c * d + return true + } + goto end7aea1048b5d1230974b97f17238380ae +end7aea1048b5d1230974b97f17238380ae: + ; + return false +} +func rewriteValuegeneric_OpMul8(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Mul8 (Const8 [c]) (Const8 [d])) + // cond: + // result: (Const8 [c*d]) + { + if v.Args[0].Op != OpConst8 { + goto end2f1952fd654c4a62ff00511041728809 + } + c := v.Args[0].AuxInt + if v.Args[1].Op != OpConst8 { + goto end2f1952fd654c4a62ff00511041728809 + } + d := v.Args[1].AuxInt + v.Op = OpConst8 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AuxInt = c * d + return true + } + goto end2f1952fd654c4a62ff00511041728809 +end2f1952fd654c4a62ff00511041728809: + ; + return false +} +func rewriteValuegeneric_OpNeq16(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Neq16 x x) + // cond: + // result: (ConstBool [0]) + { + x := v.Args[0] + if v.Args[1] != x { + goto ende76a50b524aeb16c7aeccf5f5cc60c06 + } + v.Op = OpConstBool + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AuxInt = 0 + return true + } + goto ende76a50b524aeb16c7aeccf5f5cc60c06 +ende76a50b524aeb16c7aeccf5f5cc60c06: + ; + // match: (Neq16 (Const16 [c]) (Add16 (Const16 [d]) x)) + // cond: + // result: (Neq16 (Const16 [c-d]) x) + { + if v.Args[0].Op != OpConst16 { + goto end552011bd97e6f92ebc2672aa1843eadd + } + t := v.Args[0].Type + c := v.Args[0].AuxInt + if v.Args[1].Op != OpAdd16 { + goto end552011bd97e6f92ebc2672aa1843eadd + } + if v.Args[1].Args[0].Op != OpConst16 { + goto end552011bd97e6f92ebc2672aa1843eadd + } + if v.Args[1].Args[0].Type != v.Args[0].Type { + goto end552011bd97e6f92ebc2672aa1843eadd + } + d := v.Args[1].Args[0].AuxInt + x := v.Args[1].Args[1] + v.Op = OpNeq16 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v0 := b.NewValue0(v.Line, OpConst16, t) + v0.AuxInt = c - d + v.AddArg(v0) + v.AddArg(x) + return true + } + goto end552011bd97e6f92ebc2672aa1843eadd +end552011bd97e6f92ebc2672aa1843eadd: + ; + // match: (Neq16 x (Const16 [c])) + // cond: x.Op != OpConst16 + // result: (Neq16 (Const16 [c]) x) + { + x := v.Args[0] + if v.Args[1].Op != OpConst16 { + goto end0e45958f29e87997f632248aa9ee97e0 + } + t := v.Args[1].Type + c := v.Args[1].AuxInt + if !(x.Op != OpConst16) { + goto end0e45958f29e87997f632248aa9ee97e0 + } + v.Op = OpNeq16 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v0 := b.NewValue0(v.Line, OpConst16, t) + v0.AuxInt = c + v.AddArg(v0) + v.AddArg(x) + return true + } + goto end0e45958f29e87997f632248aa9ee97e0 +end0e45958f29e87997f632248aa9ee97e0: + ; + // match: (Neq16 (Const16 [c]) (Const16 [d])) + // cond: + // result: (ConstBool [b2i(int16(c) != int16(d))]) + { + if v.Args[0].Op != OpConst16 { + goto end6302c9b645bb191982d28c2f846904d6 + } + c := v.Args[0].AuxInt + if v.Args[1].Op != OpConst16 { + goto end6302c9b645bb191982d28c2f846904d6 + } + d := v.Args[1].AuxInt + v.Op = OpConstBool + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AuxInt = b2i(int16(c) != int16(d)) + return true + } + goto end6302c9b645bb191982d28c2f846904d6 +end6302c9b645bb191982d28c2f846904d6: + ; + return false +} +func rewriteValuegeneric_OpNeq32(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Neq32 x x) + // cond: + // result: (ConstBool [0]) + { + x := v.Args[0] + if v.Args[1] != x { + goto end3713a608cffd29b40ff7c3b3f2585cbb + } + v.Op = OpConstBool + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AuxInt = 0 + return true + } + goto end3713a608cffd29b40ff7c3b3f2585cbb +end3713a608cffd29b40ff7c3b3f2585cbb: + ; + // match: (Neq32 (Const32 [c]) (Add32 (Const32 [d]) x)) + // cond: + // result: (Neq32 (Const32 [c-d]) x) + { + if v.Args[0].Op != OpConst32 { + goto end93fc3b4a3639b965b414891111b16245 + } + t := v.Args[0].Type + c := v.Args[0].AuxInt + if v.Args[1].Op != OpAdd32 { + goto end93fc3b4a3639b965b414891111b16245 + } + if v.Args[1].Args[0].Op != OpConst32 { + goto end93fc3b4a3639b965b414891111b16245 + } + if v.Args[1].Args[0].Type != v.Args[0].Type { + goto end93fc3b4a3639b965b414891111b16245 + } + d := v.Args[1].Args[0].AuxInt + x := v.Args[1].Args[1] + v.Op = OpNeq32 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v0 := b.NewValue0(v.Line, OpConst32, t) + v0.AuxInt = c - d + v.AddArg(v0) + v.AddArg(x) + return true + } + goto end93fc3b4a3639b965b414891111b16245 +end93fc3b4a3639b965b414891111b16245: + ; + // match: (Neq32 x (Const32 [c])) + // cond: x.Op != OpConst32 + // result: (Neq32 (Const32 [c]) x) + { + x := v.Args[0] + if v.Args[1].Op != OpConst32 { + goto end5376f9ab90e282450f49011d0e0ce236 + } + t := v.Args[1].Type + c := v.Args[1].AuxInt + if !(x.Op != OpConst32) { + goto end5376f9ab90e282450f49011d0e0ce236 + } + v.Op = OpNeq32 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v0 := b.NewValue0(v.Line, OpConst32, t) + v0.AuxInt = c + v.AddArg(v0) + v.AddArg(x) + return true + } + goto end5376f9ab90e282450f49011d0e0ce236 +end5376f9ab90e282450f49011d0e0ce236: + ; + // match: (Neq32 (Const32 [c]) (Const32 [d])) + // cond: + // result: (ConstBool [b2i(int32(c) != int32(d))]) + { + if v.Args[0].Op != OpConst32 { + goto endf9f3d0814854d2d0879d331e9bdfcae2 + } + c := v.Args[0].AuxInt + if v.Args[1].Op != OpConst32 { + goto endf9f3d0814854d2d0879d331e9bdfcae2 + } + d := v.Args[1].AuxInt + v.Op = OpConstBool + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AuxInt = b2i(int32(c) != int32(d)) + return true + } + goto endf9f3d0814854d2d0879d331e9bdfcae2 +endf9f3d0814854d2d0879d331e9bdfcae2: + ; + return false +} +func rewriteValuegeneric_OpNeq64(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Neq64 x x) + // cond: + // result: (ConstBool [0]) + { + x := v.Args[0] + if v.Args[1] != x { + goto end3601ad382705ea12b79d2008c1e5725c + } + v.Op = OpConstBool + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AuxInt = 0 + return true + } + goto end3601ad382705ea12b79d2008c1e5725c +end3601ad382705ea12b79d2008c1e5725c: + ; + // match: (Neq64 (Const64 [c]) (Add64 (Const64 [d]) x)) + // cond: + // result: (Neq64 (Const64 [c-d]) x) + { + if v.Args[0].Op != OpConst64 { + goto enda3d39cad13a557a2aa6d086f43596c1b + } + t := v.Args[0].Type + c := v.Args[0].AuxInt + if v.Args[1].Op != OpAdd64 { + goto enda3d39cad13a557a2aa6d086f43596c1b + } + if v.Args[1].Args[0].Op != OpConst64 { + goto enda3d39cad13a557a2aa6d086f43596c1b + } + if v.Args[1].Args[0].Type != v.Args[0].Type { + goto enda3d39cad13a557a2aa6d086f43596c1b + } + d := v.Args[1].Args[0].AuxInt + x := v.Args[1].Args[1] + v.Op = OpNeq64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = c - d + v.AddArg(v0) + v.AddArg(x) + return true + } + goto enda3d39cad13a557a2aa6d086f43596c1b +enda3d39cad13a557a2aa6d086f43596c1b: + ; + // match: (Neq64 x (Const64 [c])) + // cond: x.Op != OpConst64 + // result: (Neq64 (Const64 [c]) x) + { + x := v.Args[0] + if v.Args[1].Op != OpConst64 { + goto end0936a57de20373ca6cacb9506ddde708 + } + t := v.Args[1].Type + c := v.Args[1].AuxInt + if !(x.Op != OpConst64) { + goto end0936a57de20373ca6cacb9506ddde708 + } + v.Op = OpNeq64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = c + v.AddArg(v0) + v.AddArg(x) + return true + } + goto end0936a57de20373ca6cacb9506ddde708 +end0936a57de20373ca6cacb9506ddde708: + ; + // match: (Neq64 (Const64 [c]) (Const64 [d])) + // cond: + // result: (ConstBool [b2i(int64(c) != int64(d))]) + { + if v.Args[0].Op != OpConst64 { + goto endf07433ecd3c150b1b75e943aa44a7203 + } + c := v.Args[0].AuxInt + if v.Args[1].Op != OpConst64 { + goto endf07433ecd3c150b1b75e943aa44a7203 + } + d := v.Args[1].AuxInt + v.Op = OpConstBool + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AuxInt = b2i(int64(c) != int64(d)) + return true + } + goto endf07433ecd3c150b1b75e943aa44a7203 +endf07433ecd3c150b1b75e943aa44a7203: + ; + return false +} +func rewriteValuegeneric_OpNeq8(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Neq8 x x) + // cond: + // result: (ConstBool [0]) + { + x := v.Args[0] + if v.Args[1] != x { + goto end09a0deaf3c42627d0d2d3efa96e30745 + } + v.Op = OpConstBool + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AuxInt = 0 + return true + } + goto end09a0deaf3c42627d0d2d3efa96e30745 +end09a0deaf3c42627d0d2d3efa96e30745: + ; + // match: (Neq8 (Const8 [c]) (Add8 (Const8 [d]) x)) + // cond: + // result: (Neq8 (Const8 [c-d]) x) + { + if v.Args[0].Op != OpConst8 { + goto endc8f853c610c460c887cbfdca958e3691 + } + t := v.Args[0].Type + c := v.Args[0].AuxInt + if v.Args[1].Op != OpAdd8 { + goto endc8f853c610c460c887cbfdca958e3691 + } + if v.Args[1].Args[0].Op != OpConst8 { + goto endc8f853c610c460c887cbfdca958e3691 + } + if v.Args[1].Args[0].Type != v.Args[0].Type { + goto endc8f853c610c460c887cbfdca958e3691 + } + d := v.Args[1].Args[0].AuxInt + x := v.Args[1].Args[1] + v.Op = OpNeq8 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v0 := b.NewValue0(v.Line, OpConst8, t) + v0.AuxInt = c - d + v.AddArg(v0) + v.AddArg(x) + return true + } + goto endc8f853c610c460c887cbfdca958e3691 +endc8f853c610c460c887cbfdca958e3691: + ; + // match: (Neq8 x (Const8 [c])) + // cond: x.Op != OpConst8 + // result: (Neq8 (Const8 [c]) x) + { + x := v.Args[0] + if v.Args[1].Op != OpConst8 { + goto end04dc0ae2b08cf0447b50e5b8ef469252 + } + t := v.Args[1].Type + c := v.Args[1].AuxInt + if !(x.Op != OpConst8) { + goto end04dc0ae2b08cf0447b50e5b8ef469252 + } + v.Op = OpNeq8 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v0 := b.NewValue0(v.Line, OpConst8, t) + v0.AuxInt = c + v.AddArg(v0) + v.AddArg(x) + return true + } + goto end04dc0ae2b08cf0447b50e5b8ef469252 +end04dc0ae2b08cf0447b50e5b8ef469252: + ; + // match: (Neq8 (Const8 [c]) (Const8 [d])) + // cond: + // result: (ConstBool [b2i(int8(c) != int8(d))]) + { + if v.Args[0].Op != OpConst8 { + goto end72ebdaf2de9b3aa57cf0cb8e068b5f9c + } + c := v.Args[0].AuxInt + if v.Args[1].Op != OpConst8 { + goto end72ebdaf2de9b3aa57cf0cb8e068b5f9c + } + d := v.Args[1].AuxInt + v.Op = OpConstBool + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AuxInt = b2i(int8(c) != int8(d)) + return true + } + goto end72ebdaf2de9b3aa57cf0cb8e068b5f9c +end72ebdaf2de9b3aa57cf0cb8e068b5f9c: + ; + return false +} +func rewriteValuegeneric_OpNeqInter(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (NeqInter x y) + // cond: + // result: (NeqPtr (ITab x) (ITab y)) + { + x := v.Args[0] + y := v.Args[1] + v.Op = OpNeqPtr + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v0 := b.NewValue0(v.Line, OpITab, config.fe.TypeBytePtr()) + v0.AddArg(x) + v.AddArg(v0) + v1 := b.NewValue0(v.Line, OpITab, config.fe.TypeBytePtr()) + v1.AddArg(y) + v.AddArg(v1) + return true + } + goto end17b2333bf57e9fe81a671be02f9c4c14 +end17b2333bf57e9fe81a671be02f9c4c14: + ; + return false +} +func rewriteValuegeneric_OpNeqPtr(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (NeqPtr p (ConstNil)) + // cond: + // result: (IsNonNil p) + { + p := v.Args[0] + if v.Args[1].Op != OpConstNil { + goto endba798520b4d41172b110347158c44791 + } + v.Op = OpIsNonNil + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AddArg(p) + return true + } + goto endba798520b4d41172b110347158c44791 +endba798520b4d41172b110347158c44791: + ; + // match: (NeqPtr (ConstNil) p) + // cond: + // result: (IsNonNil p) + { + if v.Args[0].Op != OpConstNil { + goto enddd95e9c3606d9fd48034f1a703561e45 + } + p := v.Args[1] + v.Op = OpIsNonNil + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AddArg(p) + return true + } + goto enddd95e9c3606d9fd48034f1a703561e45 +enddd95e9c3606d9fd48034f1a703561e45: + ; + return false +} +func rewriteValuegeneric_OpNeqSlice(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (NeqSlice x y) + // cond: + // result: (NeqPtr (SlicePtr x) (SlicePtr y)) + { + x := v.Args[0] + y := v.Args[1] + v.Op = OpNeqPtr + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v0 := b.NewValue0(v.Line, OpSlicePtr, config.fe.TypeBytePtr()) + v0.AddArg(x) + v.AddArg(v0) + v1 := b.NewValue0(v.Line, OpSlicePtr, config.fe.TypeBytePtr()) + v1.AddArg(y) + v.AddArg(v1) + return true + } + goto endc6bc83c506e491236ca66ea1081231a2 +endc6bc83c506e491236ca66ea1081231a2: + ; + return false +} +func rewriteValuegeneric_OpOr16(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Or16 x x) + // cond: + // result: x + { + x := v.Args[0] + if v.Args[1] != x { + goto end47a2f25fd31a76807aced3e2b126acdc + } + v.Op = OpCopy + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.Type = x.Type + v.AddArg(x) + return true + } + goto end47a2f25fd31a76807aced3e2b126acdc +end47a2f25fd31a76807aced3e2b126acdc: + ; + return false +} +func rewriteValuegeneric_OpOr32(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Or32 x x) + // cond: + // result: x + { + x := v.Args[0] + if v.Args[1] != x { + goto end231e283e568e90bd9a3e6a4fa328c8a4 + } + v.Op = OpCopy + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.Type = x.Type + v.AddArg(x) + return true + } + goto end231e283e568e90bd9a3e6a4fa328c8a4 +end231e283e568e90bd9a3e6a4fa328c8a4: + ; + return false +} +func rewriteValuegeneric_OpOr64(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Or64 x x) + // cond: + // result: x + { + x := v.Args[0] + if v.Args[1] != x { + goto end6b0efc212016dc97d0e3939db04c81d9 + } + v.Op = OpCopy + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.Type = x.Type + v.AddArg(x) + return true + } + goto end6b0efc212016dc97d0e3939db04c81d9 +end6b0efc212016dc97d0e3939db04c81d9: + ; + return false +} +func rewriteValuegeneric_OpOr8(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Or8 x x) + // cond: + // result: x + { + x := v.Args[0] + if v.Args[1] != x { + goto end05295dbfafd6869af79b4daee9fda000 + } + v.Op = OpCopy + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.Type = x.Type + v.AddArg(x) + return true + } + goto end05295dbfafd6869af79b4daee9fda000 +end05295dbfafd6869af79b4daee9fda000: + ; + return false +} +func rewriteValuegeneric_OpPtrIndex(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (PtrIndex ptr idx) + // cond: config.PtrSize == 4 + // result: (AddPtr ptr (Mul32 idx (Const32 [t.Elem().Size()]))) + { + t := v.Type + ptr := v.Args[0] + idx := v.Args[1] + if !(config.PtrSize == 4) { + goto endd902622aaa1e7545b5a2a0c08b47d287 + } + v.Op = OpAddPtr + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AddArg(ptr) + v0 := b.NewValue0(v.Line, OpMul32, config.fe.TypeInt()) + v0.AddArg(idx) + v1 := b.NewValue0(v.Line, OpConst32, config.fe.TypeInt()) + v1.AuxInt = t.Elem().Size() + v0.AddArg(v1) + v.AddArg(v0) + return true + } + goto endd902622aaa1e7545b5a2a0c08b47d287 +endd902622aaa1e7545b5a2a0c08b47d287: + ; + // match: (PtrIndex ptr idx) + // cond: config.PtrSize == 8 + // result: (AddPtr ptr (Mul64 idx (Const64 [t.Elem().Size()]))) + { + t := v.Type + ptr := v.Args[0] + idx := v.Args[1] + if !(config.PtrSize == 8) { + goto end47a5f1d1b158914fa383de024bbe3b08 + } + v.Op = OpAddPtr + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AddArg(ptr) + v0 := b.NewValue0(v.Line, OpMul64, config.fe.TypeInt()) + v0.AddArg(idx) + v1 := b.NewValue0(v.Line, OpConst64, config.fe.TypeInt()) + v1.AuxInt = t.Elem().Size() + v0.AddArg(v1) + v.AddArg(v0) + return true + } + goto end47a5f1d1b158914fa383de024bbe3b08 +end47a5f1d1b158914fa383de024bbe3b08: + ; + return false +} +func rewriteValuegeneric_OpRsh16Ux16(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Rsh16Ux16 x (Const16 [c])) + // cond: + // result: (Rsh16Ux64 x (Const64 [int64(uint16(c))])) + { + t := v.Type + x := v.Args[0] + if v.Args[1].Op != OpConst16 { + goto endd981df40f353104ef828d13ad4ccdf02 + } + c := v.Args[1].AuxInt + v.Op = OpRsh16Ux64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint16(c)) + v.AddArg(v0) + return true + } + goto endd981df40f353104ef828d13ad4ccdf02 +endd981df40f353104ef828d13ad4ccdf02: + ; + return false +} +func rewriteValuegeneric_OpRsh16Ux32(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Rsh16Ux32 x (Const32 [c])) + // cond: + // result: (Rsh16Ux64 x (Const64 [int64(uint32(c))])) + { + t := v.Type + x := v.Args[0] + if v.Args[1].Op != OpConst32 { + goto ende0be9ee562725206dcf96d3e5750b5ea + } + c := v.Args[1].AuxInt + v.Op = OpRsh16Ux64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint32(c)) + v.AddArg(v0) + return true + } + goto ende0be9ee562725206dcf96d3e5750b5ea +ende0be9ee562725206dcf96d3e5750b5ea: + ; + return false +} +func rewriteValuegeneric_OpRsh16Ux64(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Rsh16Ux64 (Const16 [c]) (Const64 [d])) + // cond: + // result: (Const16 [int64(uint16(c) >> uint64(d))]) + { + if v.Args[0].Op != OpConst16 { + goto ended17f40375fb44bcbaf2d87161c5ed3c + } + c := v.Args[0].AuxInt + if v.Args[1].Op != OpConst64 { + goto ended17f40375fb44bcbaf2d87161c5ed3c + } + d := v.Args[1].AuxInt + v.Op = OpConst16 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AuxInt = int64(uint16(c) >> uint64(d)) + return true + } + goto ended17f40375fb44bcbaf2d87161c5ed3c +ended17f40375fb44bcbaf2d87161c5ed3c: + ; + // match: (Rsh16Ux64 x (Const64 [0])) + // cond: + // result: x + { + x := v.Args[0] + if v.Args[1].Op != OpConst64 { + goto end752d1b5a60f87afa7e40febbf1bce309 + } + if v.Args[1].AuxInt != 0 { + goto end752d1b5a60f87afa7e40febbf1bce309 + } + v.Op = OpCopy + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.Type = x.Type + v.AddArg(x) + return true + } + goto end752d1b5a60f87afa7e40febbf1bce309 +end752d1b5a60f87afa7e40febbf1bce309: + ; + // match: (Rsh16Ux64 _ (Const64 [c])) + // cond: uint64(c) >= 16 + // result: (Const64 [0]) + { + if v.Args[1].Op != OpConst64 { + goto endca5c7ae2e51f2ae32486c2b1a3033b77 + } + c := v.Args[1].AuxInt + if !(uint64(c) >= 16) { + goto endca5c7ae2e51f2ae32486c2b1a3033b77 + } + v.Op = OpConst64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AuxInt = 0 + return true + } + goto endca5c7ae2e51f2ae32486c2b1a3033b77 +endca5c7ae2e51f2ae32486c2b1a3033b77: + ; + // match: (Rsh16Ux64 (Rsh16Ux64 x (Const64 [c])) (Const64 [d])) + // cond: !uaddOvf(c,d) + // result: (Rsh16Ux64 x (Const64 [c+d])) + { + t := v.Type + if v.Args[0].Op != OpRsh16Ux64 { + goto end56f2c0034c9fbe651abb36fb640af465 + } + x := v.Args[0].Args[0] + if v.Args[0].Args[1].Op != OpConst64 { + goto end56f2c0034c9fbe651abb36fb640af465 + } + c := v.Args[0].Args[1].AuxInt + if v.Args[1].Op != OpConst64 { + goto end56f2c0034c9fbe651abb36fb640af465 + } + d := v.Args[1].AuxInt + if !(!uaddOvf(c, d)) { + goto end56f2c0034c9fbe651abb36fb640af465 + } + v.Op = OpRsh16Ux64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = c + d + v.AddArg(v0) + return true + } + goto end56f2c0034c9fbe651abb36fb640af465 +end56f2c0034c9fbe651abb36fb640af465: + ; + return false +} +func rewriteValuegeneric_OpRsh16Ux8(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Rsh16Ux8 x (Const8 [c])) + // cond: + // result: (Rsh16Ux64 x (Const64 [int64(uint8(c))])) + { + t := v.Type + x := v.Args[0] + if v.Args[1].Op != OpConst8 { + goto end20d4667094c32c71bac4e0805dab85c9 + } + c := v.Args[1].AuxInt + v.Op = OpRsh16Ux64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint8(c)) + v.AddArg(v0) + return true + } + goto end20d4667094c32c71bac4e0805dab85c9 +end20d4667094c32c71bac4e0805dab85c9: + ; + return false +} +func rewriteValuegeneric_OpRsh16x16(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Rsh16x16 x (Const16 [c])) + // cond: + // result: (Rsh16x64 x (Const64 [int64(uint16(c))])) + { + t := v.Type + x := v.Args[0] + if v.Args[1].Op != OpConst16 { + goto end1b501c7ae2fe58ad3a88b467f2d95389 + } + c := v.Args[1].AuxInt + v.Op = OpRsh16x64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint16(c)) + v.AddArg(v0) + return true + } + goto end1b501c7ae2fe58ad3a88b467f2d95389 +end1b501c7ae2fe58ad3a88b467f2d95389: + ; + return false +} +func rewriteValuegeneric_OpRsh16x32(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Rsh16x32 x (Const32 [c])) + // cond: + // result: (Rsh16x64 x (Const64 [int64(uint32(c))])) + { + t := v.Type + x := v.Args[0] + if v.Args[1].Op != OpConst32 { + goto end4d3a41113d2d0b09924bf5759ca49cab + } + c := v.Args[1].AuxInt + v.Op = OpRsh16x64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint32(c)) + v.AddArg(v0) + return true + } + goto end4d3a41113d2d0b09924bf5759ca49cab +end4d3a41113d2d0b09924bf5759ca49cab: + ; + return false +} +func rewriteValuegeneric_OpRsh16x64(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Rsh16x64 (Const16 [c]) (Const64 [d])) + // cond: + // result: (Const16 [int64(int16(c) >> uint64(d))]) + { + if v.Args[0].Op != OpConst16 { + goto end8f05fede35a3d2f687fcd4a5829a25ad + } + c := v.Args[0].AuxInt + if v.Args[1].Op != OpConst64 { + goto end8f05fede35a3d2f687fcd4a5829a25ad + } + d := v.Args[1].AuxInt + v.Op = OpConst16 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AuxInt = int64(int16(c) >> uint64(d)) + return true + } + goto end8f05fede35a3d2f687fcd4a5829a25ad +end8f05fede35a3d2f687fcd4a5829a25ad: + ; + // match: (Rsh16x64 x (Const64 [0])) + // cond: + // result: x + { + x := v.Args[0] + if v.Args[1].Op != OpConst64 { + goto end750fafe01fcc689d953101d53efc19ab + } + if v.Args[1].AuxInt != 0 { + goto end750fafe01fcc689d953101d53efc19ab + } + v.Op = OpCopy + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.Type = x.Type + v.AddArg(x) + return true + } + goto end750fafe01fcc689d953101d53efc19ab +end750fafe01fcc689d953101d53efc19ab: + ; + // match: (Rsh16x64 (Rsh16x64 x (Const64 [c])) (Const64 [d])) + // cond: !uaddOvf(c,d) + // result: (Rsh16x64 x (Const64 [c+d])) + { + t := v.Type + if v.Args[0].Op != OpRsh16x64 { + goto endf425eff9e05aad27194af957e3383c76 + } + x := v.Args[0].Args[0] + if v.Args[0].Args[1].Op != OpConst64 { + goto endf425eff9e05aad27194af957e3383c76 + } + c := v.Args[0].Args[1].AuxInt + if v.Args[1].Op != OpConst64 { + goto endf425eff9e05aad27194af957e3383c76 + } + d := v.Args[1].AuxInt + if !(!uaddOvf(c, d)) { + goto endf425eff9e05aad27194af957e3383c76 + } + v.Op = OpRsh16x64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = c + d + v.AddArg(v0) + return true + } + goto endf425eff9e05aad27194af957e3383c76 +endf425eff9e05aad27194af957e3383c76: + ; + return false +} +func rewriteValuegeneric_OpRsh16x8(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Rsh16x8 x (Const8 [c])) + // cond: + // result: (Rsh16x64 x (Const64 [int64(uint8(c))])) + { + t := v.Type + x := v.Args[0] + if v.Args[1].Op != OpConst8 { + goto end0b5e274d62a3ae8df9f4089756c6a9d4 + } + c := v.Args[1].AuxInt + v.Op = OpRsh16x64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint8(c)) + v.AddArg(v0) + return true + } + goto end0b5e274d62a3ae8df9f4089756c6a9d4 +end0b5e274d62a3ae8df9f4089756c6a9d4: + ; + return false +} +func rewriteValuegeneric_OpRsh32Ux16(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Rsh32Ux16 x (Const16 [c])) + // cond: + // result: (Rsh32Ux64 x (Const64 [int64(uint16(c))])) + { + t := v.Type + x := v.Args[0] + if v.Args[1].Op != OpConst16 { + goto end8d8f9f3e2e1f7a5e9a186fb792fc40a8 + } + c := v.Args[1].AuxInt + v.Op = OpRsh32Ux64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint16(c)) + v.AddArg(v0) + return true + } + goto end8d8f9f3e2e1f7a5e9a186fb792fc40a8 +end8d8f9f3e2e1f7a5e9a186fb792fc40a8: + ; + return false +} +func rewriteValuegeneric_OpRsh32Ux32(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Rsh32Ux32 x (Const32 [c])) + // cond: + // result: (Rsh32Ux64 x (Const64 [int64(uint32(c))])) + { + t := v.Type + x := v.Args[0] + if v.Args[1].Op != OpConst32 { + goto endd23d060f74e00f34cc967b6fb9a4d320 + } + c := v.Args[1].AuxInt + v.Op = OpRsh32Ux64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint32(c)) + v.AddArg(v0) + return true + } + goto endd23d060f74e00f34cc967b6fb9a4d320 +endd23d060f74e00f34cc967b6fb9a4d320: + ; + return false +} +func rewriteValuegeneric_OpRsh32Ux64(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Rsh32Ux64 (Const32 [c]) (Const64 [d])) + // cond: + // result: (Const32 [int64(uint32(c) >> uint64(d))]) + { + if v.Args[0].Op != OpConst32 { + goto enda101e6b765d7ecffd9b7410c9dc3be82 + } + c := v.Args[0].AuxInt + if v.Args[1].Op != OpConst64 { + goto enda101e6b765d7ecffd9b7410c9dc3be82 + } + d := v.Args[1].AuxInt + v.Op = OpConst32 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AuxInt = int64(uint32(c) >> uint64(d)) + return true + } + goto enda101e6b765d7ecffd9b7410c9dc3be82 +enda101e6b765d7ecffd9b7410c9dc3be82: + ; + // match: (Rsh32Ux64 x (Const64 [0])) + // cond: + // result: x + { + x := v.Args[0] + if v.Args[1].Op != OpConst64 { + goto end162e4e182a665d4e6f0d85fe131e7288 + } + if v.Args[1].AuxInt != 0 { + goto end162e4e182a665d4e6f0d85fe131e7288 + } + v.Op = OpCopy + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.Type = x.Type + v.AddArg(x) + return true + } + goto end162e4e182a665d4e6f0d85fe131e7288 +end162e4e182a665d4e6f0d85fe131e7288: + ; + // match: (Rsh32Ux64 _ (Const64 [c])) + // cond: uint64(c) >= 32 + // result: (Const64 [0]) + { + if v.Args[1].Op != OpConst64 { + goto endca322c370839b4264b219ee042a6ab33 + } + c := v.Args[1].AuxInt + if !(uint64(c) >= 32) { + goto endca322c370839b4264b219ee042a6ab33 + } + v.Op = OpConst64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AuxInt = 0 + return true + } + goto endca322c370839b4264b219ee042a6ab33 +endca322c370839b4264b219ee042a6ab33: + ; + // match: (Rsh32Ux64 (Rsh32Ux64 x (Const64 [c])) (Const64 [d])) + // cond: !uaddOvf(c,d) + // result: (Rsh32Ux64 x (Const64 [c+d])) + { + t := v.Type + if v.Args[0].Op != OpRsh32Ux64 { + goto end2e502d68a32663142684194adbe6c297 + } + x := v.Args[0].Args[0] + if v.Args[0].Args[1].Op != OpConst64 { + goto end2e502d68a32663142684194adbe6c297 + } + c := v.Args[0].Args[1].AuxInt + if v.Args[1].Op != OpConst64 { + goto end2e502d68a32663142684194adbe6c297 + } + d := v.Args[1].AuxInt + if !(!uaddOvf(c, d)) { + goto end2e502d68a32663142684194adbe6c297 + } + v.Op = OpRsh32Ux64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = c + d + v.AddArg(v0) + return true + } + goto end2e502d68a32663142684194adbe6c297 +end2e502d68a32663142684194adbe6c297: + ; + return false +} +func rewriteValuegeneric_OpRsh32Ux8(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Rsh32Ux8 x (Const8 [c])) + // cond: + // result: (Rsh32Ux64 x (Const64 [int64(uint8(c))])) + { + t := v.Type + x := v.Args[0] + if v.Args[1].Op != OpConst8 { + goto end967cea80158afaffb783f6da7aa898ca + } + c := v.Args[1].AuxInt + v.Op = OpRsh32Ux64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint8(c)) + v.AddArg(v0) + return true + } + goto end967cea80158afaffb783f6da7aa898ca +end967cea80158afaffb783f6da7aa898ca: + ; + return false +} +func rewriteValuegeneric_OpRsh32x16(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Rsh32x16 x (Const16 [c])) + // cond: + // result: (Rsh32x64 x (Const64 [int64(uint16(c))])) + { + t := v.Type + x := v.Args[0] + if v.Args[1].Op != OpConst16 { + goto end6a62ebdcc98ea2e3214559214708d26a + } + c := v.Args[1].AuxInt + v.Op = OpRsh32x64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint16(c)) + v.AddArg(v0) + return true + } + goto end6a62ebdcc98ea2e3214559214708d26a +end6a62ebdcc98ea2e3214559214708d26a: + ; + return false +} +func rewriteValuegeneric_OpRsh32x32(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Rsh32x32 x (Const32 [c])) + // cond: + // result: (Rsh32x64 x (Const64 [int64(uint32(c))])) + { + t := v.Type + x := v.Args[0] + if v.Args[1].Op != OpConst32 { + goto end6e3b467acdca74f58e9177fb42a1968b + } + c := v.Args[1].AuxInt + v.Op = OpRsh32x64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint32(c)) + v.AddArg(v0) + return true + } + goto end6e3b467acdca74f58e9177fb42a1968b +end6e3b467acdca74f58e9177fb42a1968b: + ; + return false +} +func rewriteValuegeneric_OpRsh32x64(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Rsh32x64 (Const32 [c]) (Const64 [d])) + // cond: + // result: (Const32 [int64(int32(c) >> uint64(d))]) + { + if v.Args[0].Op != OpConst32 { + goto end7e4b8c499cffe1fef73a16e6be54d4d2 + } + c := v.Args[0].AuxInt + if v.Args[1].Op != OpConst64 { + goto end7e4b8c499cffe1fef73a16e6be54d4d2 + } + d := v.Args[1].AuxInt + v.Op = OpConst32 v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AuxInt = int64(int32(c) >> uint64(d)) return true } - goto end3601ad382705ea12b79d2008c1e5725c -end3601ad382705ea12b79d2008c1e5725c: + goto end7e4b8c499cffe1fef73a16e6be54d4d2 +end7e4b8c499cffe1fef73a16e6be54d4d2: ; - // match: (Neq64 (Const64 [c]) (Add64 (Const64 [d]) x)) + // match: (Rsh32x64 x (Const64 [0])) // cond: - // result: (Neq64 (Const64 [c-d]) x) + // result: x { - if v.Args[0].Op != OpConst64 { - goto enda3d39cad13a557a2aa6d086f43596c1b + x := v.Args[0] + if v.Args[1].Op != OpConst64 { + goto end72da2611eaaffe407efa1cc45c23ade3 } - t := v.Args[0].Type - c := v.Args[0].AuxInt - if v.Args[1].Op != OpAdd64 { - goto enda3d39cad13a557a2aa6d086f43596c1b + if v.Args[1].AuxInt != 0 { + goto end72da2611eaaffe407efa1cc45c23ade3 } - if v.Args[1].Args[0].Op != OpConst64 { - goto enda3d39cad13a557a2aa6d086f43596c1b + v.Op = OpCopy + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.Type = x.Type + v.AddArg(x) + return true + } + goto end72da2611eaaffe407efa1cc45c23ade3 +end72da2611eaaffe407efa1cc45c23ade3: + ; + // match: (Rsh32x64 (Rsh32x64 x (Const64 [c])) (Const64 [d])) + // cond: !uaddOvf(c,d) + // result: (Rsh32x64 x (Const64 [c+d])) + { + t := v.Type + if v.Args[0].Op != OpRsh32x64 { + goto endadb415be78ee46a8a4135ec50df772b0 } - if v.Args[1].Args[0].Type != v.Args[0].Type { - goto enda3d39cad13a557a2aa6d086f43596c1b + x := v.Args[0].Args[0] + if v.Args[0].Args[1].Op != OpConst64 { + goto endadb415be78ee46a8a4135ec50df772b0 } - d := v.Args[1].Args[0].AuxInt - x := v.Args[1].Args[1] - v.Op = OpNeq64 + c := v.Args[0].Args[1].AuxInt + if v.Args[1].Op != OpConst64 { + goto endadb415be78ee46a8a4135ec50df772b0 + } + d := v.Args[1].AuxInt + if !(!uaddOvf(c, d)) { + goto endadb415be78ee46a8a4135ec50df772b0 + } + v.Op = OpRsh32x64 v.AuxInt = 0 v.Aux = nil v.resetArgs() - v0 := b.NewValue0(v.Line, OpConst64, TypeInvalid) - v0.Type = t - v0.AuxInt = c - d - v.AddArg(v0) v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = c + d + v.AddArg(v0) return true } - goto enda3d39cad13a557a2aa6d086f43596c1b -enda3d39cad13a557a2aa6d086f43596c1b: + goto endadb415be78ee46a8a4135ec50df772b0 +endadb415be78ee46a8a4135ec50df772b0: ; - // match: (Neq64 x (Const64 [c])) - // cond: x.Op != OpConst64 - // result: (Neq64 (Const64 [c]) x) + return false +} +func rewriteValuegeneric_OpRsh32x8(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Rsh32x8 x (Const8 [c])) + // cond: + // result: (Rsh32x64 x (Const64 [int64(uint8(c))])) { + t := v.Type x := v.Args[0] - if v.Args[1].Op != OpConst64 { - goto end0936a57de20373ca6cacb9506ddde708 + if v.Args[1].Op != OpConst8 { + goto end7b59b42c5c68a2d55be469a0c086dd8b } - t := v.Args[1].Type c := v.Args[1].AuxInt - if !(x.Op != OpConst64) { - goto end0936a57de20373ca6cacb9506ddde708 + v.Op = OpRsh32x64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint8(c)) + v.AddArg(v0) + return true + } + goto end7b59b42c5c68a2d55be469a0c086dd8b +end7b59b42c5c68a2d55be469a0c086dd8b: + ; + return false +} +func rewriteValuegeneric_OpRsh64Ux16(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Rsh64Ux16 x (Const16 [c])) + // cond: + // result: (Rsh64Ux64 x (Const64 [int64(uint16(c))])) + { + t := v.Type + x := v.Args[0] + if v.Args[1].Op != OpConst16 { + goto end733d85a7b599bcba969ca1cb4bdb9e48 } - v.Op = OpNeq64 + c := v.Args[1].AuxInt + v.Op = OpRsh64Ux64 v.AuxInt = 0 v.Aux = nil v.resetArgs() - v0 := b.NewValue0(v.Line, OpConst64, TypeInvalid) - v0.Type = t - v0.AuxInt = c + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint16(c)) v.AddArg(v0) + return true + } + goto end733d85a7b599bcba969ca1cb4bdb9e48 +end733d85a7b599bcba969ca1cb4bdb9e48: + ; + return false +} +func rewriteValuegeneric_OpRsh64Ux32(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Rsh64Ux32 x (Const32 [c])) + // cond: + // result: (Rsh64Ux64 x (Const64 [int64(uint32(c))])) + { + t := v.Type + x := v.Args[0] + if v.Args[1].Op != OpConst32 { + goto endeac7b34169de1fb0393b833e65b9bb19 + } + c := v.Args[1].AuxInt + v.Op = OpRsh64Ux64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint32(c)) + v.AddArg(v0) return true } - goto end0936a57de20373ca6cacb9506ddde708 -end0936a57de20373ca6cacb9506ddde708: + goto endeac7b34169de1fb0393b833e65b9bb19 +endeac7b34169de1fb0393b833e65b9bb19: ; - // match: (Neq64 (Const64 [c]) (Const64 [d])) + return false +} +func rewriteValuegeneric_OpRsh64Ux64(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Rsh64Ux64 (Const64 [c]) (Const64 [d])) // cond: - // result: (ConstBool [b2i(int64(c) != int64(d))]) + // result: (Const64 [int64(uint64(c) >> uint64(d))]) { if v.Args[0].Op != OpConst64 { - goto endf07433ecd3c150b1b75e943aa44a7203 + goto end102f4cfd7979a2aa222d52c34ac6802d } c := v.Args[0].AuxInt if v.Args[1].Op != OpConst64 { - goto endf07433ecd3c150b1b75e943aa44a7203 + goto end102f4cfd7979a2aa222d52c34ac6802d } d := v.Args[1].AuxInt - v.Op = OpConstBool + v.Op = OpConst64 v.AuxInt = 0 v.Aux = nil v.resetArgs() - v.AuxInt = b2i(int64(c) != int64(d)) + v.AuxInt = int64(uint64(c) >> uint64(d)) return true } - goto endf07433ecd3c150b1b75e943aa44a7203 -endf07433ecd3c150b1b75e943aa44a7203: + goto end102f4cfd7979a2aa222d52c34ac6802d +end102f4cfd7979a2aa222d52c34ac6802d: + ; + // match: (Rsh64Ux64 x (Const64 [0])) + // cond: + // result: x + { + x := v.Args[0] + if v.Args[1].Op != OpConst64 { + goto end5ad037b910698f2847df90177c23a6ac + } + if v.Args[1].AuxInt != 0 { + goto end5ad037b910698f2847df90177c23a6ac + } + v.Op = OpCopy + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.Type = x.Type + v.AddArg(x) + return true + } + goto end5ad037b910698f2847df90177c23a6ac +end5ad037b910698f2847df90177c23a6ac: + ; + // match: (Rsh64Ux64 _ (Const64 [c])) + // cond: uint64(c) >= 64 + // result: (Const64 [0]) + { + if v.Args[1].Op != OpConst64 { + goto end16ea16aa61862207ea64e514369d608b + } + c := v.Args[1].AuxInt + if !(uint64(c) >= 64) { + goto end16ea16aa61862207ea64e514369d608b + } + v.Op = OpConst64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AuxInt = 0 + return true + } + goto end16ea16aa61862207ea64e514369d608b +end16ea16aa61862207ea64e514369d608b: + ; + // match: (Rsh64Ux64 (Rsh64Ux64 x (Const64 [c])) (Const64 [d])) + // cond: !uaddOvf(c,d) + // result: (Rsh64Ux64 x (Const64 [c+d])) + { + t := v.Type + if v.Args[0].Op != OpRsh64Ux64 { + goto end32bfdb1b4ccc23a5cd62fc0348ebd877 + } + x := v.Args[0].Args[0] + if v.Args[0].Args[1].Op != OpConst64 { + goto end32bfdb1b4ccc23a5cd62fc0348ebd877 + } + c := v.Args[0].Args[1].AuxInt + if v.Args[1].Op != OpConst64 { + goto end32bfdb1b4ccc23a5cd62fc0348ebd877 + } + d := v.Args[1].AuxInt + if !(!uaddOvf(c, d)) { + goto end32bfdb1b4ccc23a5cd62fc0348ebd877 + } + v.Op = OpRsh64Ux64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = c + d + v.AddArg(v0) + return true + } + goto end32bfdb1b4ccc23a5cd62fc0348ebd877 +end32bfdb1b4ccc23a5cd62fc0348ebd877: ; return false } -func rewriteValuegeneric_OpNeq8(v *Value, config *Config) bool { +func rewriteValuegeneric_OpRsh64Ux8(v *Value, config *Config) bool { b := v.Block _ = b - // match: (Neq8 x x) + // match: (Rsh64Ux8 x (Const8 [c])) // cond: - // result: (ConstBool [0]) + // result: (Rsh64Ux64 x (Const64 [int64(uint8(c))])) { + t := v.Type x := v.Args[0] - if v.Args[1] != x { - goto end09a0deaf3c42627d0d2d3efa96e30745 + if v.Args[1].Op != OpConst8 { + goto ende3d8090a67a52dbcd24b52ee32c9d7f0 } - v.Op = OpConstBool + c := v.Args[1].AuxInt + v.Op = OpRsh64Ux64 v.AuxInt = 0 v.Aux = nil v.resetArgs() + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint8(c)) + v.AddArg(v0) + return true + } + goto ende3d8090a67a52dbcd24b52ee32c9d7f0 +ende3d8090a67a52dbcd24b52ee32c9d7f0: + ; + return false +} +func rewriteValuegeneric_OpRsh64x16(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Rsh64x16 x (Const16 [c])) + // cond: + // result: (Rsh64x64 x (Const64 [int64(uint16(c))])) + { + t := v.Type + x := v.Args[0] + if v.Args[1].Op != OpConst16 { + goto endd5151d0bfc38c55ae6ae6836014df3bc + } + c := v.Args[1].AuxInt + v.Op = OpRsh64x64 v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint16(c)) + v.AddArg(v0) return true } - goto end09a0deaf3c42627d0d2d3efa96e30745 -end09a0deaf3c42627d0d2d3efa96e30745: + goto endd5151d0bfc38c55ae6ae6836014df3bc +endd5151d0bfc38c55ae6ae6836014df3bc: ; - // match: (Neq8 (Const8 [c]) (Add8 (Const8 [d]) x)) + return false +} +func rewriteValuegeneric_OpRsh64x32(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Rsh64x32 x (Const32 [c])) // cond: - // result: (Neq8 (Const8 [c-d]) x) + // result: (Rsh64x64 x (Const64 [int64(uint32(c))])) { - if v.Args[0].Op != OpConst8 { - goto endc8f853c610c460c887cbfdca958e3691 + t := v.Type + x := v.Args[0] + if v.Args[1].Op != OpConst32 { + goto end0f2dbca5c7d6b100890c94a97bf0de7c + } + c := v.Args[1].AuxInt + v.Op = OpRsh64x64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint32(c)) + v.AddArg(v0) + return true + } + goto end0f2dbca5c7d6b100890c94a97bf0de7c +end0f2dbca5c7d6b100890c94a97bf0de7c: + ; + return false +} +func rewriteValuegeneric_OpRsh64x64(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Rsh64x64 (Const64 [c]) (Const64 [d])) + // cond: + // result: (Const64 [c >> uint64(d)]) + { + if v.Args[0].Op != OpConst64 { + goto endfa4609d6bea8a3e3d3a777b1968c97d9 } - t := v.Args[0].Type c := v.Args[0].AuxInt - if v.Args[1].Op != OpAdd8 { - goto endc8f853c610c460c887cbfdca958e3691 + if v.Args[1].Op != OpConst64 { + goto endfa4609d6bea8a3e3d3a777b1968c97d9 } - if v.Args[1].Args[0].Op != OpConst8 { - goto endc8f853c610c460c887cbfdca958e3691 + d := v.Args[1].AuxInt + v.Op = OpConst64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AuxInt = c >> uint64(d) + return true + } + goto endfa4609d6bea8a3e3d3a777b1968c97d9 +endfa4609d6bea8a3e3d3a777b1968c97d9: + ; + // match: (Rsh64x64 x (Const64 [0])) + // cond: + // result: x + { + x := v.Args[0] + if v.Args[1].Op != OpConst64 { + goto ende62e0c67d3f04eb221646371a2a91d05 } - if v.Args[1].Args[0].Type != v.Args[0].Type { - goto endc8f853c610c460c887cbfdca958e3691 + if v.Args[1].AuxInt != 0 { + goto ende62e0c67d3f04eb221646371a2a91d05 + } + v.Op = OpCopy + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.Type = x.Type + v.AddArg(x) + return true + } + goto ende62e0c67d3f04eb221646371a2a91d05 +ende62e0c67d3f04eb221646371a2a91d05: + ; + // match: (Rsh64x64 (Rsh64x64 x (Const64 [c])) (Const64 [d])) + // cond: !uaddOvf(c,d) + // result: (Rsh64x64 x (Const64 [c+d])) + { + t := v.Type + if v.Args[0].Op != OpRsh64x64 { + goto endd3e8ea66dc3ad0bc393001d6babb7160 + } + x := v.Args[0].Args[0] + if v.Args[0].Args[1].Op != OpConst64 { + goto endd3e8ea66dc3ad0bc393001d6babb7160 + } + c := v.Args[0].Args[1].AuxInt + if v.Args[1].Op != OpConst64 { + goto endd3e8ea66dc3ad0bc393001d6babb7160 + } + d := v.Args[1].AuxInt + if !(!uaddOvf(c, d)) { + goto endd3e8ea66dc3ad0bc393001d6babb7160 } - d := v.Args[1].Args[0].AuxInt - x := v.Args[1].Args[1] - v.Op = OpNeq8 + v.Op = OpRsh64x64 v.AuxInt = 0 v.Aux = nil v.resetArgs() - v0 := b.NewValue0(v.Line, OpConst8, TypeInvalid) - v0.Type = t - v0.AuxInt = c - d - v.AddArg(v0) v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = c + d + v.AddArg(v0) return true } - goto endc8f853c610c460c887cbfdca958e3691 -endc8f853c610c460c887cbfdca958e3691: + goto endd3e8ea66dc3ad0bc393001d6babb7160 +endd3e8ea66dc3ad0bc393001d6babb7160: ; - // match: (Neq8 x (Const8 [c])) - // cond: x.Op != OpConst8 - // result: (Neq8 (Const8 [c]) x) + return false +} +func rewriteValuegeneric_OpRsh64x8(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Rsh64x8 x (Const8 [c])) + // cond: + // result: (Rsh64x64 x (Const64 [int64(uint8(c))])) { + t := v.Type x := v.Args[0] if v.Args[1].Op != OpConst8 { - goto end04dc0ae2b08cf0447b50e5b8ef469252 + goto end1a9e5a89849344396210da7c7ec810be } - t := v.Args[1].Type c := v.Args[1].AuxInt - if !(x.Op != OpConst8) { - goto end04dc0ae2b08cf0447b50e5b8ef469252 - } - v.Op = OpNeq8 + v.Op = OpRsh64x64 v.AuxInt = 0 v.Aux = nil v.resetArgs() - v0 := b.NewValue0(v.Line, OpConst8, TypeInvalid) - v0.Type = t - v0.AuxInt = c - v.AddArg(v0) v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint8(c)) + v.AddArg(v0) return true } - goto end04dc0ae2b08cf0447b50e5b8ef469252 -end04dc0ae2b08cf0447b50e5b8ef469252: + goto end1a9e5a89849344396210da7c7ec810be +end1a9e5a89849344396210da7c7ec810be: ; - // match: (Neq8 (Const8 [c]) (Const8 [d])) + return false +} +func rewriteValuegeneric_OpRsh8Ux16(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Rsh8Ux16 x (Const16 [c])) // cond: - // result: (ConstBool [b2i(int8(c) != int8(d))]) + // result: (Rsh8Ux64 x (Const64 [int64(uint16(c))])) { - if v.Args[0].Op != OpConst8 { - goto end72ebdaf2de9b3aa57cf0cb8e068b5f9c - } - c := v.Args[0].AuxInt - if v.Args[1].Op != OpConst8 { - goto end72ebdaf2de9b3aa57cf0cb8e068b5f9c + t := v.Type + x := v.Args[0] + if v.Args[1].Op != OpConst16 { + goto end7acc015610273092e9efcce2949ee0f9 } - d := v.Args[1].AuxInt - v.Op = OpConstBool + c := v.Args[1].AuxInt + v.Op = OpRsh8Ux64 v.AuxInt = 0 v.Aux = nil v.resetArgs() - v.AuxInt = b2i(int8(c) != int8(d)) + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint16(c)) + v.AddArg(v0) return true } - goto end72ebdaf2de9b3aa57cf0cb8e068b5f9c -end72ebdaf2de9b3aa57cf0cb8e068b5f9c: + goto end7acc015610273092e9efcce2949ee0f9 +end7acc015610273092e9efcce2949ee0f9: ; return false } -func rewriteValuegeneric_OpNeqInter(v *Value, config *Config) bool { +func rewriteValuegeneric_OpRsh8Ux32(v *Value, config *Config) bool { b := v.Block _ = b - // match: (NeqInter x y) + // match: (Rsh8Ux32 x (Const32 [c])) // cond: - // result: (NeqPtr (ITab x) (ITab y)) + // result: (Rsh8Ux64 x (Const64 [int64(uint32(c))])) { + t := v.Type x := v.Args[0] - y := v.Args[1] - v.Op = OpNeqPtr + if v.Args[1].Op != OpConst32 { + goto end27e9b4472e085b653a105b1d67554ce8 + } + c := v.Args[1].AuxInt + v.Op = OpRsh8Ux64 v.AuxInt = 0 v.Aux = nil v.resetArgs() - v0 := b.NewValue0(v.Line, OpITab, config.fe.TypeBytePtr()) - v0.AddArg(x) + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint32(c)) v.AddArg(v0) - v1 := b.NewValue0(v.Line, OpITab, config.fe.TypeBytePtr()) - v1.AddArg(y) - v.AddArg(v1) return true } - goto end17b2333bf57e9fe81a671be02f9c4c14 -end17b2333bf57e9fe81a671be02f9c4c14: + goto end27e9b4472e085b653a105b1d67554ce8 +end27e9b4472e085b653a105b1d67554ce8: ; return false } -func rewriteValuegeneric_OpNeqPtr(v *Value, config *Config) bool { +func rewriteValuegeneric_OpRsh8Ux64(v *Value, config *Config) bool { b := v.Block _ = b - // match: (NeqPtr p (ConstNil)) + // match: (Rsh8Ux64 (Const8 [c]) (Const64 [d])) // cond: - // result: (IsNonNil p) + // result: (Const8 [int64(uint8(c) >> uint64(d))]) { - p := v.Args[0] - if v.Args[1].Op != OpConstNil { - goto endba798520b4d41172b110347158c44791 + if v.Args[0].Op != OpConst8 { + goto enddd166e450d81ba7b466d61d2fbec178c } - v.Op = OpIsNonNil + c := v.Args[0].AuxInt + if v.Args[1].Op != OpConst64 { + goto enddd166e450d81ba7b466d61d2fbec178c + } + d := v.Args[1].AuxInt + v.Op = OpConst8 v.AuxInt = 0 v.Aux = nil v.resetArgs() - v.AddArg(p) + v.AuxInt = int64(uint8(c) >> uint64(d)) return true } - goto endba798520b4d41172b110347158c44791 -endba798520b4d41172b110347158c44791: + goto enddd166e450d81ba7b466d61d2fbec178c +enddd166e450d81ba7b466d61d2fbec178c: ; - // match: (NeqPtr (ConstNil) p) + // match: (Rsh8Ux64 x (Const64 [0])) // cond: - // result: (IsNonNil p) + // result: x { - if v.Args[0].Op != OpConstNil { - goto enddd95e9c3606d9fd48034f1a703561e45 + x := v.Args[0] + if v.Args[1].Op != OpConst64 { + goto end570cb1d9db3c7bebd85e485eeb2c0969 } - p := v.Args[1] - v.Op = OpIsNonNil + if v.Args[1].AuxInt != 0 { + goto end570cb1d9db3c7bebd85e485eeb2c0969 + } + v.Op = OpCopy v.AuxInt = 0 v.Aux = nil v.resetArgs() - v.AddArg(p) + v.Type = x.Type + v.AddArg(x) return true } - goto enddd95e9c3606d9fd48034f1a703561e45 -enddd95e9c3606d9fd48034f1a703561e45: + goto end570cb1d9db3c7bebd85e485eeb2c0969 +end570cb1d9db3c7bebd85e485eeb2c0969: ; - return false -} -func rewriteValuegeneric_OpNeqSlice(v *Value, config *Config) bool { - b := v.Block - _ = b - // match: (NeqSlice x y) - // cond: - // result: (NeqPtr (SlicePtr x) (SlicePtr y)) + // match: (Rsh8Ux64 _ (Const64 [c])) + // cond: uint64(c) >= 8 + // result: (Const64 [0]) { - x := v.Args[0] - y := v.Args[1] - v.Op = OpNeqPtr + if v.Args[1].Op != OpConst64 { + goto endb63e1a7d1d91716ca0d9d74215361323 + } + c := v.Args[1].AuxInt + if !(uint64(c) >= 8) { + goto endb63e1a7d1d91716ca0d9d74215361323 + } + v.Op = OpConst64 v.AuxInt = 0 v.Aux = nil v.resetArgs() - v0 := b.NewValue0(v.Line, OpSlicePtr, config.fe.TypeBytePtr()) - v0.AddArg(x) + v.AuxInt = 0 + return true + } + goto endb63e1a7d1d91716ca0d9d74215361323 +endb63e1a7d1d91716ca0d9d74215361323: + ; + // match: (Rsh8Ux64 (Rsh8Ux64 x (Const64 [c])) (Const64 [d])) + // cond: !uaddOvf(c,d) + // result: (Rsh8Ux64 x (Const64 [c+d])) + { + t := v.Type + if v.Args[0].Op != OpRsh8Ux64 { + goto endee8824b7071ed1a6dba4fcbaab98229e + } + x := v.Args[0].Args[0] + if v.Args[0].Args[1].Op != OpConst64 { + goto endee8824b7071ed1a6dba4fcbaab98229e + } + c := v.Args[0].Args[1].AuxInt + if v.Args[1].Op != OpConst64 { + goto endee8824b7071ed1a6dba4fcbaab98229e + } + d := v.Args[1].AuxInt + if !(!uaddOvf(c, d)) { + goto endee8824b7071ed1a6dba4fcbaab98229e + } + v.Op = OpRsh8Ux64 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = c + d v.AddArg(v0) - v1 := b.NewValue0(v.Line, OpSlicePtr, config.fe.TypeBytePtr()) - v1.AddArg(y) - v.AddArg(v1) return true } - goto endc6bc83c506e491236ca66ea1081231a2 -endc6bc83c506e491236ca66ea1081231a2: + goto endee8824b7071ed1a6dba4fcbaab98229e +endee8824b7071ed1a6dba4fcbaab98229e: ; return false } -func rewriteValuegeneric_OpOr16(v *Value, config *Config) bool { +func rewriteValuegeneric_OpRsh8Ux8(v *Value, config *Config) bool { b := v.Block _ = b - // match: (Or16 x x) + // match: (Rsh8Ux8 x (Const8 [c])) // cond: - // result: x + // result: (Rsh8Ux64 x (Const64 [int64(uint8(c))])) { + t := v.Type x := v.Args[0] - if v.Args[1] != x { - goto end47a2f25fd31a76807aced3e2b126acdc + if v.Args[1].Op != OpConst8 { + goto ended7e4f4d9ab89dc26e6649d466577930 } - v.Op = OpCopy + c := v.Args[1].AuxInt + v.Op = OpRsh8Ux64 v.AuxInt = 0 v.Aux = nil v.resetArgs() - v.Type = x.Type v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint8(c)) + v.AddArg(v0) return true } - goto end47a2f25fd31a76807aced3e2b126acdc -end47a2f25fd31a76807aced3e2b126acdc: + goto ended7e4f4d9ab89dc26e6649d466577930 +ended7e4f4d9ab89dc26e6649d466577930: ; return false } -func rewriteValuegeneric_OpOr32(v *Value, config *Config) bool { +func rewriteValuegeneric_OpRsh8x16(v *Value, config *Config) bool { b := v.Block _ = b - // match: (Or32 x x) + // match: (Rsh8x16 x (Const16 [c])) // cond: - // result: x + // result: (Rsh8x64 x (Const64 [int64(uint16(c))])) { + t := v.Type x := v.Args[0] - if v.Args[1] != x { - goto end231e283e568e90bd9a3e6a4fa328c8a4 + if v.Args[1].Op != OpConst16 { + goto end136bef6f60180bc8b4befbfc370af7ef } - v.Op = OpCopy + c := v.Args[1].AuxInt + v.Op = OpRsh8x64 v.AuxInt = 0 v.Aux = nil v.resetArgs() - v.Type = x.Type v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint16(c)) + v.AddArg(v0) return true } - goto end231e283e568e90bd9a3e6a4fa328c8a4 -end231e283e568e90bd9a3e6a4fa328c8a4: + goto end136bef6f60180bc8b4befbfc370af7ef +end136bef6f60180bc8b4befbfc370af7ef: ; return false } -func rewriteValuegeneric_OpOr64(v *Value, config *Config) bool { +func rewriteValuegeneric_OpRsh8x32(v *Value, config *Config) bool { b := v.Block _ = b - // match: (Or64 x x) + // match: (Rsh8x32 x (Const32 [c])) // cond: - // result: x + // result: (Rsh8x64 x (Const64 [int64(uint32(c))])) { + t := v.Type x := v.Args[0] - if v.Args[1] != x { - goto end6b0efc212016dc97d0e3939db04c81d9 + if v.Args[1].Op != OpConst32 { + goto end2ef95c222a7c552fa9cc86e36196644e } - v.Op = OpCopy + c := v.Args[1].AuxInt + v.Op = OpRsh8x64 v.AuxInt = 0 v.Aux = nil v.resetArgs() - v.Type = x.Type v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint32(c)) + v.AddArg(v0) return true } - goto end6b0efc212016dc97d0e3939db04c81d9 -end6b0efc212016dc97d0e3939db04c81d9: + goto end2ef95c222a7c552fa9cc86e36196644e +end2ef95c222a7c552fa9cc86e36196644e: ; return false } -func rewriteValuegeneric_OpOr8(v *Value, config *Config) bool { +func rewriteValuegeneric_OpRsh8x64(v *Value, config *Config) bool { b := v.Block _ = b - // match: (Or8 x x) + // match: (Rsh8x64 (Const8 [c]) (Const64 [d])) + // cond: + // result: (Const8 [int64(int8(c) >> uint64(d))]) + { + if v.Args[0].Op != OpConst8 { + goto end3b90206d75365466dfd1368e5b69db35 + } + c := v.Args[0].AuxInt + if v.Args[1].Op != OpConst64 { + goto end3b90206d75365466dfd1368e5b69db35 + } + d := v.Args[1].AuxInt + v.Op = OpConst8 + v.AuxInt = 0 + v.Aux = nil + v.resetArgs() + v.AuxInt = int64(int8(c) >> uint64(d)) + return true + } + goto end3b90206d75365466dfd1368e5b69db35 +end3b90206d75365466dfd1368e5b69db35: + ; + // match: (Rsh8x64 x (Const64 [0])) // cond: // result: x { x := v.Args[0] - if v.Args[1] != x { - goto end05295dbfafd6869af79b4daee9fda000 + if v.Args[1].Op != OpConst64 { + goto end1e664cc720a11d1c769de8081cfa1de4 + } + if v.Args[1].AuxInt != 0 { + goto end1e664cc720a11d1c769de8081cfa1de4 } v.Op = OpCopy v.AuxInt = 0 @@ -3749,65 +5981,69 @@ func rewriteValuegeneric_OpOr8(v *Value, config *Config) bool { v.AddArg(x) return true } - goto end05295dbfafd6869af79b4daee9fda000 -end05295dbfafd6869af79b4daee9fda000: + goto end1e664cc720a11d1c769de8081cfa1de4 +end1e664cc720a11d1c769de8081cfa1de4: ; - return false -} -func rewriteValuegeneric_OpPtrIndex(v *Value, config *Config) bool { - b := v.Block - _ = b - // match: (PtrIndex ptr idx) - // cond: config.PtrSize == 4 - // result: (AddPtr ptr (Mul32 idx (Const32 [t.Elem().Size()]))) + // match: (Rsh8x64 (Rsh8x64 x (Const64 [c])) (Const64 [d])) + // cond: !uaddOvf(c,d) + // result: (Rsh8x64 x (Const64 [c+d])) { t := v.Type - ptr := v.Args[0] - idx := v.Args[1] - if !(config.PtrSize == 4) { - goto endd902622aaa1e7545b5a2a0c08b47d287 + if v.Args[0].Op != OpRsh8x64 { + goto end6408685a7276af7e76ec086f359c942c } - v.Op = OpAddPtr + x := v.Args[0].Args[0] + if v.Args[0].Args[1].Op != OpConst64 { + goto end6408685a7276af7e76ec086f359c942c + } + c := v.Args[0].Args[1].AuxInt + if v.Args[1].Op != OpConst64 { + goto end6408685a7276af7e76ec086f359c942c + } + d := v.Args[1].AuxInt + if !(!uaddOvf(c, d)) { + goto end6408685a7276af7e76ec086f359c942c + } + v.Op = OpRsh8x64 v.AuxInt = 0 v.Aux = nil v.resetArgs() - v.AddArg(ptr) - v0 := b.NewValue0(v.Line, OpMul32, config.fe.TypeInt()) - v0.AddArg(idx) - v1 := b.NewValue0(v.Line, OpConst32, config.fe.TypeInt()) - v1.AuxInt = t.Elem().Size() - v0.AddArg(v1) + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = c + d v.AddArg(v0) return true } - goto endd902622aaa1e7545b5a2a0c08b47d287 -endd902622aaa1e7545b5a2a0c08b47d287: + goto end6408685a7276af7e76ec086f359c942c +end6408685a7276af7e76ec086f359c942c: ; - // match: (PtrIndex ptr idx) - // cond: config.PtrSize == 8 - // result: (AddPtr ptr (Mul64 idx (Const64 [t.Elem().Size()]))) + return false +} +func rewriteValuegeneric_OpRsh8x8(v *Value, config *Config) bool { + b := v.Block + _ = b + // match: (Rsh8x8 x (Const8 [c])) + // cond: + // result: (Rsh8x64 x (Const64 [int64(uint8(c))])) { t := v.Type - ptr := v.Args[0] - idx := v.Args[1] - if !(config.PtrSize == 8) { - goto end47a5f1d1b158914fa383de024bbe3b08 + x := v.Args[0] + if v.Args[1].Op != OpConst8 { + goto endae44f60f364cddd8903763dd921a007e } - v.Op = OpAddPtr + c := v.Args[1].AuxInt + v.Op = OpRsh8x64 v.AuxInt = 0 v.Aux = nil v.resetArgs() - v.AddArg(ptr) - v0 := b.NewValue0(v.Line, OpMul64, config.fe.TypeInt()) - v0.AddArg(idx) - v1 := b.NewValue0(v.Line, OpConst64, config.fe.TypeInt()) - v1.AuxInt = t.Elem().Size() - v0.AddArg(v1) + v.AddArg(x) + v0 := b.NewValue0(v.Line, OpConst64, t) + v0.AuxInt = int64(uint8(c)) v.AddArg(v0) return true } - goto end47a5f1d1b158914fa383de024bbe3b08 -end47a5f1d1b158914fa383de024bbe3b08: + goto endae44f60f364cddd8903763dd921a007e +endae44f60f364cddd8903763dd921a007e: ; return false } @@ -4652,8 +6888,7 @@ end5c6fab95c9dbeff5973119096bfd4e78: v.AuxInt = 0 v.Aux = nil v.resetArgs() - v0 := b.NewValue0(v.Line, OpConst16, TypeInvalid) - v0.Type = t + v0 := b.NewValue0(v.Line, OpConst16, t) v0.AuxInt = -c v.AddArg(v0) v.AddArg(x) @@ -4770,8 +7005,7 @@ end7623799db780e1bcc42c6ea0df9c49d3: v.AuxInt = 0 v.Aux = nil v.resetArgs() - v0 := b.NewValue0(v.Line, OpConst32, TypeInvalid) - v0.Type = t + v0 := b.NewValue0(v.Line, OpConst32, t) v0.AuxInt = -c v.AddArg(v0) v.AddArg(x) @@ -4888,8 +7122,7 @@ end5a84a285ff0ff48b8ad3c64b15e3459f: v.AuxInt = 0 v.Aux = nil v.resetArgs() - v0 := b.NewValue0(v.Line, OpConst64, TypeInvalid) - v0.Type = t + v0 := b.NewValue0(v.Line, OpConst64, t) v0.AuxInt = -c v.AddArg(v0) v.AddArg(x) @@ -5006,8 +7239,7 @@ endc00ea11c7535529e211710574f5cff24: v.AuxInt = 0 v.Aux = nil v.resetArgs() - v0 := b.NewValue0(v.Line, OpConst8, TypeInvalid) - v0.Type = t + v0 := b.NewValue0(v.Line, OpConst8, t) v0.AuxInt = -c v.AddArg(v0) v.AddArg(x)