Skip to content

Commit

Permalink
test/codegen: match 387 ops too for GOARCH=386
Browse files Browse the repository at this point in the history
Change-Id: I99407e27e340689009af798989b33cef7cb92070
Reviewed-on: https://go-review.googlesource.com/103376
Run-TryBot: Alberto Donizetti <[email protected]>
Reviewed-by: Josh Bleecher Snyder <[email protected]>
TryBot-Result: Gobot Gobot <[email protected]>
  • Loading branch information
ALTree committed Mar 29, 2018
1 parent aacf7a1 commit 56eaf57
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions test/codegen/floats.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,27 +15,27 @@ package codegen
// --------------------- //

func Mul2(f float64) float64 {
// 386:"ADDSD",-"MULSD"
// 386:"ADDSD|FADDDP",-"MULSD",-"FMULDP"
// amd64:"ADDSD",-"MULSD"
// arm:"ADDD",-"MULD"
// arm64:"FADDD",-"FMULD"
return f * 2.0
}

func DivPow2(f1, f2, f3 float64) (float64, float64, float64) {
// 386:"MULSD",-"DIVSD"
// 386:"MULSD|FMULDP",-"DIVSD",-"FDIVDP"
// amd64:"MULSD",-"DIVSD"
// arm:"MULD",-"DIVD"
// arm64:"FMULD",-"FDIVD"
x := f1 / 16.0

// 386:"MULSD",-"DIVSD"
// 386:"MULSD|FMULDP",-"DIVSD",-"FDIVDP"
// amd64:"MULSD",-"DIVSD"
// arm:"MULD",-"DIVD"
// arm64:"FMULD",-"FDIVD"
y := f2 / 0.125

// 386:"ADDSD",-"DIVSD",-"MULSD"
// 386:"ADDSD|FADDDP",-"DIVSD",-"MULSD",-"FDIVDP",-"FMULDP"
// amd64:"ADDSD",-"DIVSD",-"MULSD"
// arm:"ADDD",-"MULD",-"DIVD"
// arm64:"FADDD",-"FMULD",-"FDIVD"
Expand Down

0 comments on commit 56eaf57

Please sign in to comment.