diff options
author | R?my Oudompheng <oudomphe@phare.normalesup.org> | 2012-11-26 23:45:22 +0100 |
---|---|---|
committer | R?my Oudompheng <oudomphe@phare.normalesup.org> | 2012-11-26 23:45:22 +0100 |
commit | df73bc90ca665e4153ebb8a8948a4f2a89ca62bf (patch) | |
tree | 88767d7a4af6373468b011f6095ecdb3a69dbb3e /src/cmd/6g/gg.h | |
parent | 75a87a1dc5bad846245266941bb8ca747b70a04c (diff) | |
download | go-df73bc90ca665e4153ebb8a8948a4f2a89ca62bf.tar.gz |
cmd/gc: add division rewrite to walk pass.
This allows 5g and 8g to benefit from the rewrite as shifts
or magic multiplies. The 64-bit arithmetic is not handled there,
and left in 6g.
Update issue 2230.
R=golang-dev, dave, mtj, iant, rsc
CC=golang-dev
http://codereview.appspot.com/6819123
Diffstat (limited to 'src/cmd/6g/gg.h')
-rw-r--r-- | src/cmd/6g/gg.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/cmd/6g/gg.h b/src/cmd/6g/gg.h index 9f8e95ceb..2806fbc93 100644 --- a/src/cmd/6g/gg.h +++ b/src/cmd/6g/gg.h @@ -71,6 +71,7 @@ void cgen_proc(Node*, int); void cgen_callret(Node*, Node*); void cgen_div(int, Node*, Node*, Node*); void cgen_bmul(int, Node*, Node*, Node*); +void cgen_hmul(Node*, Node*, Node*); void cgen_shift(int, int, Node*, Node*, Node*); void cgen_dcl(Node*); int needconvert(Type*, Type*); @@ -86,6 +87,7 @@ void clearslim(Node*); */ void agen(Node*, Node*); void agenr(Node*, Node*, Node*); +void cgenr(Node*, Node*, Node*); void igen(Node*, Node*, Node*); vlong fieldoffset(Type*, Node*); void sgen(Node*, Node*, int64); |