mirror of
https://github.com/golang/go.git
synced 2025-12-08 06:10:04 +00:00
test/codegen: port direct comparisons with memory tests
And remove them from asm_test. Change-Id: I1ca29b40546d6de06f20bfd550ed8ff87f495454 Reviewed-on: https://go-review.googlesource.com/102115 Run-TryBot: Alberto Donizetti <alb.donizetti@gmail.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Keith Randall <khr@golang.org>
This commit is contained in:
parent
6633bb2aa7
commit
fc6280d4b0
2 changed files with 39 additions and 49 deletions
|
|
@ -394,55 +394,6 @@ var linuxAMD64Tests = []*asmTest{
|
|||
`,
|
||||
pos: []string{"TEXT\t.*, [$]0-8"},
|
||||
},
|
||||
// int <-> fp moves
|
||||
{
|
||||
fn: `
|
||||
func $(x uint32) bool {
|
||||
return x > 4
|
||||
}
|
||||
`,
|
||||
pos: []string{"\tSETHI\t.*\\(SP\\)"},
|
||||
},
|
||||
{
|
||||
fn: `
|
||||
func $(p int, q *int) bool {
|
||||
return p < *q
|
||||
}
|
||||
`,
|
||||
pos: []string{"CMPQ\t\\(.*\\), [A-Z]"},
|
||||
},
|
||||
{
|
||||
fn: `
|
||||
func $(p *int, q int) bool {
|
||||
return *p < q
|
||||
}
|
||||
`,
|
||||
pos: []string{"CMPQ\t\\(.*\\), [A-Z]"},
|
||||
},
|
||||
{
|
||||
fn: `
|
||||
func $(p *int) bool {
|
||||
return *p < 7
|
||||
}
|
||||
`,
|
||||
pos: []string{"CMPQ\t\\(.*\\), [$]7"},
|
||||
},
|
||||
{
|
||||
fn: `
|
||||
func $(p *int) bool {
|
||||
return 7 < *p
|
||||
}
|
||||
`,
|
||||
pos: []string{"CMPQ\t\\(.*\\), [$]7"},
|
||||
},
|
||||
{
|
||||
fn: `
|
||||
func $(p **int) {
|
||||
*p = nil
|
||||
}
|
||||
`,
|
||||
pos: []string{"CMPL\truntime.writeBarrier\\(SB\\), [$]0"},
|
||||
},
|
||||
}
|
||||
|
||||
var linux386Tests = []*asmTest{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue