func MergeMuls2(n int) int {
// amd64:"IMUL3Q\t[$]23","(ADDQ\t[$]29)|(LEAQ\t29)"
// 386:"IMUL3L\t[$]23","ADDL\t[$]29"
- // ppc64le/power9:"MADDLD",-"MULLD\t[$]23",-"ADD\t[$]29"
- // ppc64le/power8:"MULLD\t[$]23","ADD\t[$]29"
+ // ppc64x/power9:"MADDLD",-"MULLD\t[$]23",-"ADD\t[$]29"
+ // ppc64x/power8:"MULLD\t[$]23","ADD\t[$]29"
return 5*n + 7*(n+1) + 11*(n+2) // 23n + 29
}
func convertNeq0W(x uint16, c bool) bool {
// amd64:"ANDL\t[$]1",-"SETNE"
// ppc64x:"ANDCC",-"CMPW",-"ISEL"
- // ppc64le/power9:"ANDCC",-CMPW",-"ISEL"
b := x&1 != 0
return c && b
}
}
func convertNeqBool32(x uint32) bool {
- // ppc64x:"ANDCC",-"CMPW",-"ISEL"
- return x&1 != 0
+ // ppc64x:"ANDCC",-"CMPW",-"ISEL"
+ return x&1 != 0
}
func convertEqBool32(x uint32) bool {
- // ppc64x:"ANDCC",-"CMPW","XOR",-"ISEL"
- // ppc64le/power9:"ANDCC","XOR",-"CMPW",-"ISEL"
- return x&1 == 0
+ // ppc64x:"ANDCC",-"CMPW","XOR",-"ISEL"
+ return x&1 == 0
}
func convertNeqBool64(x uint64) bool {
- // ppc64x:"ANDCC",-"CMP",-"ISEL"
- return x&1 != 0
+ // ppc64x:"ANDCC",-"CMP",-"ISEL"
+ return x&1 != 0
}
func convertEqBool64(x uint64) bool {
- // ppc64x:"ANDCC","XOR",-"CMP",-"ISEL"
- return x&1 == 0
+ // ppc64x:"ANDCC","XOR",-"CMP",-"ISEL"
+ return x&1 == 0
}
func moveDisjointStack32() {
var s [32]byte
// ppc64x:-".*memmove"
- // ppc64le/power8:"LXVD2X",-"ADD",-"BC"
- // ppc64le/power9:"LXV",-"LXVD2X",-"ADD",-"BC"
+ // ppc64x/power8:"LXVD2X",-"ADD",-"BC"
+ // ppc64x/power9:"LXV",-"LXVD2X",-"ADD",-"BC"
copy(s[:], x[:32])
runtime.KeepAlive(&s)
}
func moveDisjointStack64() {
var s [96]byte
// ppc64x:-".*memmove"
- // ppc64le/power8:"LXVD2X","ADD","BC"
- // ppc64le/power9:"LXV",-"LXVD2X",-"ADD",-"BC"
+ // ppc64x/power8:"LXVD2X","ADD","BC"
+ // ppc64x/power9:"LXV",-"LXVD2X",-"ADD",-"BC"
copy(s[:], x[:96])
runtime.KeepAlive(&s)
}
// s390x:-".*memmove"
// amd64:-".*memmove"
// ppc64x:-".*memmove"
- // ppc64le/power8:"LXVD2X"
- // ppc64le/power9:"LXV",-"LXVD2X"
+ // ppc64x/power8:"LXVD2X"
+ // ppc64x/power9:"LXV",-"LXVD2X"
copy(s[:], x[:])
runtime.KeepAlive(&s)
}
// s390x:-".*memmove"
// amd64:-".*memmove"
// ppc64x:-".*memmove"
- // ppc64le/power8:"LXVD2X"
- // ppc64le/power9:"LXV",-"LXVD2X"
+ // ppc64x/power8:"LXVD2X"
+ // ppc64x/power9:"LXV",-"LXVD2X"
copy(s[:], b[:])
runtime.KeepAlive(&s)
}
// s390x:-".*memmove"
// amd64:-".*memmove"
// ppc64x:-".*memmove"
- // ppc64le/power8:"LXVD2X"
- // ppc64le/power9:"LXV",-"LXVD2X"
+ // ppc64x/power8:"LXVD2X"
+ // ppc64x/power9:"LXV",-"LXVD2X"
copy(a[:], a[128:])
}
}
func TrailingZeros64Subtract(n uint64) int {
- // ppc64le/power8:"NEG","SUBC","ANDN","POPCNTD"
- // ppc64le/power9:"SUBC","CNTTZD"
+ // ppc64x/power8:"NEG","SUBC","ANDN","POPCNTD"
+ // ppc64x/power9:"SUBC","CNTTZD"
return bits.TrailingZeros64(1 - n)
}
func rshMask64x64(v int64, s uint64) int64 {
// arm64:"ASR",-"AND",-"CSEL"
- // ppc64:"ANDCC",-"ORN",-"ISEL"
- // ppc64le:"ANDCC",-ORN",-"ISEL"
+ // ppc64x:"ANDCC",-"ORN",-"ISEL"
// riscv64:"SRA",-"OR",-"SLTIU"
// s390x:-"RISBGZ",-"AND",-"LOCGR"
return v >> (s & 63)
func checkWidenAfterShift(v int64, u uint64) (int64, uint64) {
- // ppc64le:-".*MOVW"
+ // ppc64x:-".*MOVW"
f := int32(v >> 32)
- // ppc64le:".*MOVW"
+ // ppc64x:".*MOVW"
f += int32(v >> 31)
- // ppc64le:-".*MOVH"
+ // ppc64x:-".*MOVH"
g := int16(v >> 48)
- // ppc64le:".*MOVH"
+ // ppc64x:".*MOVH"
g += int16(v >> 30)
- // ppc64le:-".*MOVH"
+ // ppc64x:-".*MOVH"
g += int16(f >> 16)
- // ppc64le:-".*MOVB"
+ // ppc64x:-".*MOVB"
h := int8(v >> 56)
- // ppc64le:".*MOVB"
+ // ppc64x:".*MOVB"
h += int8(v >> 28)
- // ppc64le:-".*MOVB"
+ // ppc64x:-".*MOVB"
h += int8(f >> 24)
- // ppc64le:".*MOVB"
+ // ppc64x:".*MOVB"
h += int8(f >> 16)
return int64(h), uint64(g)
}