Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cmd/compile: incorrect handling of uint64 function parameters(?) on s390x #19940

Closed
jcajka opened this issue Apr 12, 2017 · 8 comments

Comments

Projects
None yet
6 participants
@jcajka
Copy link
Contributor

commented Apr 12, 2017

What version of Go are you using (go version)?

go version devel +5a45a15 Fri Mar 31 05:02:02 2017 +0000 linux/s390x
also observed with go1.8+

What did you do?

Following reproducer fails on s390x, https://play.golang.org/p/ktGF0Uev_0

What did you expect to see?

PASSED

What did you see instead?

FAILED
0
1999999999999999999
>=
18446744073709551557
@josharian

This comment has been minimized.

Copy link
Contributor

commented Apr 12, 2017

@josharian josharian changed the title Incorrect handling of unit64 function parameters(?) on s390x cmd/compile: incorrect handling of uint64 function parameters(?) on s390x Apr 12, 2017

@josharian josharian added this to the Go1.8.2 milestone Apr 12, 2017

@mundaym

This comment has been minimized.

Copy link
Member

commented Apr 12, 2017

I think I've found the problem. @jcajka thanks a lot for the reproducer, can you see if CL 40433 fixes your original issue? In the meantime I'll work on a test.

You can apply the CL by executing the following command in your Go checkout:

git fetch https://go.googlesource.com/go refs/changes/33/40433/1 && git checkout FETCH_HEAD

@gopherbot

This comment has been minimized.

Copy link

commented Apr 12, 2017

CL https://golang.org/cl/40433 mentions this issue.

@jcajka

This comment has been minimized.

Copy link
Contributor Author

commented Apr 12, 2017

@mundaym seems to fix the issue, thanks for quick fix :)

@gopherbot gopherbot closed this in f75b5e9 Apr 13, 2017

@mundaym

This comment has been minimized.

Copy link
Member

commented Apr 13, 2017

I can't reopen this, can you @josharian? Based on the golang-dev discussion, I think we are supposed to reopen issues that have been fixed in master but not in the release branch for the milestone.

@josharian josharian reopened this Apr 13, 2017

@josharian

This comment has been minimized.

Copy link
Contributor

commented Apr 13, 2017

@mundaym you should request github access! See https://github.com/golang/go/wiki/GithubAccess.

@gopherbot

This comment has been minimized.

Copy link

commented Apr 17, 2017

CL https://golang.org/cl/40931 mentions this issue.

gopherbot pushed a commit that referenced this issue Apr 17, 2017

[release-branch.go1.8] cmd/compile: fix s390x unsigned comparison con…
…stant merging rules

On s390x unsigned integer comparisons with immediates require the immediate
to be an unsigned 32-bit integer. The rule was checking that the immediate
was a signed 32-bit integer.

This CL also adds a test for comparisons that could be turned into compare
with immediate or equivalent instructions (depending on architecture and
optimizations applied).

Cherry-pick of CL 40433 and CL 40873.

Fixes #19940.

Change-Id: I1331558a0ee0c4ac33bf8ea488f3ea190d06f110
Reviewed-on: https://go-review.googlesource.com/40931
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>

@mundaym mundaym closed this Apr 20, 2017

@bradfitz bradfitz modified the milestones: Go1.8.3, Go1.8.2 May 19, 2017

@bradfitz bradfitz reopened this May 19, 2017

@gopherbot

This comment has been minimized.

Copy link

commented May 23, 2017

CL https://golang.org/cl/43994 mentions this issue.

@broady broady closed this May 23, 2017

gopherbot pushed a commit that referenced this issue May 23, 2017

[release-branch.go1.8] cmd/compile: fix s390x unsigned comparison con…
…stant merging rules

On s390x unsigned integer comparisons with immediates require the immediate
to be an unsigned 32-bit integer. The rule was checking that the immediate
was a signed 32-bit integer.

This CL also adds a test for comparisons that could be turned into compare
with immediate or equivalent instructions (depending on architecture and
optimizations applied).

Cherry-pick of CL 40433 and CL 40873.

Fixes #19940.

Reviewed-on: https://go-review.googlesource.com/40931
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>

Change-Id: I3daaeaa40d7637bd4421e6b8d37ea4ffd74448ce
Reviewed-on: https://go-review.googlesource.com/43994
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>

@golang golang locked and limited conversation to collaborators May 23, 2018

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
You can’t perform that action at this time.