Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(8)

Issue 159670043: [dev.power64] code review 159670043: cmd/5a, cmd/6a, cmd/8a, cmd/9a: make labels function-scoped (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
10 years, 5 months ago by rsc
Modified:
10 years, 5 months ago
Reviewers:
r
CC:
r, austin, dave_cheney.net, golang-codereviews, minux
Visibility:
Public.

Description

cmd/5a, cmd/6a, cmd/8a, cmd/9a: make labels function-scoped I removed support for jumping between functions years ago, as part of doing the instruction layout for each function separately. Given that, it makes sense to treat labels as function-scoped. This lets each function have its own 'loop' label, for example. Makes the assembly much cleaner and removes the last reason anyone would reach for the 123(PC) form instead. Note that this is on the dev.power64 branch, but it changes all the assemblers. The change will ship in Go 1.5 (perhaps after being ported into the new assembler). Came up as part of CL 167730043.

Patch Set 1 #

Patch Set 2 : diff -r 7d1f343355e235ec8c7d0355b048e1fc1ff8f910 https://code.google.com/p/go/ #

Patch Set 3 : diff -r 7d1f343355e235ec8c7d0355b048e1fc1ff8f910 https://code.google.com/p/go/ #

Patch Set 4 : diff -r 7d1f343355e235ec8c7d0355b048e1fc1ff8f910 https://code.google.com/p/go/ #

Patch Set 5 : diff -r 1764402609fe548e804a45e63b5094f6c26e18e2 https://code.google.com/p/go/ #

Unified diffs Side-by-side diffs Delta from patch set Stats (+3610 lines, -4202 lines) Patch
M src/cmd/5a/a.h View 1 2 chunks +3 lines, -0 lines 0 comments Download
M src/cmd/5a/a.y View 1 3 chunks +10 lines, -16 lines 0 comments Download
M src/cmd/5a/y.tab.h View 1 3 chunks +22 lines, -46 lines 0 comments Download
M src/cmd/5a/y.tab.c View 1 80 chunks +968 lines, -1115 lines 0 comments Download
M src/cmd/6a/a.h View 1 2 chunks +3 lines, -0 lines 0 comments Download
M src/cmd/6a/a.y View 1 3 chunks +9 lines, -16 lines 0 comments Download
M src/cmd/6a/y.tab.c View 1 44 chunks +573 lines, -589 lines 0 comments Download
M src/cmd/8a/a.h View 1 2 chunks +3 lines, -0 lines 0 comments Download
M src/cmd/8a/a.y View 1 3 chunks +9 lines, -16 lines 0 comments Download
M src/cmd/8a/y.tab.c View 1 43 chunks +548 lines, -562 lines 0 comments Download
M src/cmd/9a/a.h View 1 2 chunks +3 lines, -0 lines 0 comments Download
M src/cmd/9a/a.y View 1 3 chunks +10 lines, -16 lines 0 comments Download
M src/cmd/9a/y.tab.h View 1 3 chunks +21 lines, -25 lines 0 comments Download
M src/cmd/9a/y.tab.c View 1 75 chunks +1170 lines, -1566 lines 0 comments Download
M src/cmd/cc/lexbody View 1 1 chunk +25 lines, -0 lines 0 comments Download
M src/runtime/asm_386.s View 1 5 chunks +29 lines, -29 lines 0 comments Download
M src/runtime/asm_amd64.s View 1 8 chunks +39 lines, -39 lines 0 comments Download
M src/runtime/asm_amd64p32.s View 1 6 chunks +29 lines, -29 lines 0 comments Download
M src/runtime/asm_arm.s View 1 5 chunks +12 lines, -12 lines 0 comments Download
M src/runtime/asm_power64x.s View 1 2 3 4 8 chunks +20 lines, -20 lines 0 comments Download
M src/runtime/memclr_386.s View 1 4 chunks +23 lines, -23 lines 0 comments Download
M src/runtime/memclr_amd64.s View 1 3 chunks +22 lines, -22 lines 0 comments Download
M src/runtime/memclr_plan9_386.s View 1 1 chunk +12 lines, -12 lines 0 comments Download
M src/runtime/race_amd64.s View 1 2 chunks +9 lines, -9 lines 0 comments Download
M src/runtime/sys_darwin_386.s View 1 2 chunks +2 lines, -2 lines 0 comments Download
M src/runtime/sys_darwin_amd64.s View 1 2 chunks +2 lines, -2 lines 0 comments Download
M src/runtime/sys_dragonfly_386.s View 1 2 chunks +2 lines, -2 lines 0 comments Download
M src/runtime/sys_freebsd_386.s View 1 2 chunks +2 lines, -2 lines 0 comments Download
M src/runtime/sys_linux_amd64.s View 1 4 chunks +4 lines, -4 lines 0 comments Download
M src/runtime/sys_linux_arm.s View 1 1 chunk +4 lines, -4 lines 0 comments Download
M src/runtime/sys_nacl_386.s View 1 2 chunks +2 lines, -2 lines 0 comments Download
M src/runtime/sys_nacl_amd64p32.s View 1 1 chunk +0 lines, -1 line 0 comments Download
M src/runtime/sys_nacl_arm.s View 1 1 chunk +0 lines, -1 line 0 comments Download
M src/runtime/sys_openbsd_386.s View 1 2 chunks +2 lines, -2 lines 0 comments Download
M src/runtime/sys_solaris_amd64.s View 1 2 chunks +6 lines, -6 lines 0 comments Download
M src/runtime/sys_windows_386.s View 1 4 chunks +6 lines, -6 lines 0 comments Download
M src/runtime/sys_windows_amd64.s View 1 4 chunks +6 lines, -6 lines 0 comments Download

Messages

Total messages: 3
rsc
Hello r, r@golang.org (cc: austin, dfc, golang-codereviews@googlegroups.com, minux), I'd like you to review this change ...
10 years, 5 months ago (2014-10-28 14:58:06 UTC) #1
r
LGTM
10 years, 5 months ago (2014-10-28 20:47:09 UTC) #2
rsc
10 years, 5 months ago (2014-10-29 01:50:24 UTC) #3
*** Submitted as https://code.google.com/p/go/source/detail?r=1eecc78cf304 ***

[dev.power64] cmd/5a, cmd/6a, cmd/8a, cmd/9a: make labels function-scoped

I removed support for jumping between functions years ago,
as part of doing the instruction layout for each function separately.

Given that, it makes sense to treat labels as function-scoped.
This lets each function have its own 'loop' label, for example.

Makes the assembly much cleaner and removes the last
reason anyone would reach for the 123(PC) form instead.

Note that this is on the dev.power64 branch, but it changes all
the assemblers. The change will ship in Go 1.5 (perhaps after
being ported into the new assembler).

Came up as part of CL 167730043.

LGTM=r
R=r
CC=austin, dave, golang-codereviews, minux
https://codereview.appspot.com/159670043
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b