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/link: use m to store div/mod denominator on arm #6699

Closed
rsc opened this issue Oct 31, 2013 · 7 comments
Closed

cmd/link: use m to store div/mod denominator on arm #6699

rsc opened this issue Oct 31, 2013 · 7 comments
Milestone

Comments

@rsc
Copy link
Contributor

rsc commented Oct 31, 2013

Bring back CL 19810043.
However, also:

1. Disallow use of DIV/MOD in NOSPLIT functions.
That will catch functions that are running without a valid m.

2. Rewrite the functions that are caught (usleep, various 64-bit atomics)
to use magic multiplies instead of constant division.
@davecheney
Copy link
Contributor

Comment 1:

This sounds like a great solution.

@rsc
Copy link
Contributor Author

rsc commented Dec 4, 2013

Comment 2:

Labels changed: added release-go1.3.

@rsc
Copy link
Contributor Author

rsc commented Dec 4, 2013

Comment 3:

Labels changed: removed go1.3.

@rsc
Copy link
Contributor Author

rsc commented Dec 4, 2013

Comment 4:

Labels changed: added repo-main.

@rsc
Copy link
Contributor Author

rsc commented Apr 3, 2014

Comment 5:

Too late.

Labels changed: added release-go1.4, removed release-go1.3.

@rsc
Copy link
Contributor Author

rsc commented Sep 15, 2014

Comment 6:

We did disallow div/mod in nosplit, because they are not nosplit. So at least that's
taken care of.

Labels changed: added release-none, removed release-go1.4.

@rsc rsc added this to the Unplanned milestone Apr 10, 2015
@rsc rsc changed the title cmd/5l: use m to store div/mod denominator cmd/link: use m to store div/mod denominator on arm Jun 8, 2015
rsc added a commit that referenced this issue Jul 30, 2015
We want to adjust the DIV calling convention to use m,
and usleep can be called without an m, so switch to a
multiplication by the reciprocal (and test).

Step toward a fix for #6699 and #10486.

Change-Id: Iccf76a18432d835e48ec64a2fa34a0e4d6d4b955
Reviewed-on: https://go-review.googlesource.com/12898
Reviewed-by: Ian Lance Taylor <iant@golang.org>
@gopherbot
Copy link

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

@rsc rsc closed this as completed in b2dfacf Jul 30, 2015
@mikioh mikioh modified the milestones: Go1.5, Unplanned Jul 31, 2015
@golang golang locked and limited conversation to collaborators Aug 5, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

4 participants