|
Use uint index variables in some cases instead
of int to enable strength reduction; this makes
it possible for the compiler to reduce % into
masks.
Old code: 6g -S md4.go md4block.go | grep "md4block.go:44"
0471 (md4block.go:44) MOVL AX,BX
0472 (md4block.go:44) MOVL AX,BP
0473 (md4block.go:44) MOVL AX,R8
0474 (md4block.go:44) SARL $31,R8
0475 (md4block.go:44) SHRL $30,R8
0476 (md4block.go:44) ADDL R8,BP
0477 (md4block.go:44) SARL $2,BP
0478 (md4block.go:44) IMULL $4,BP
0479 (md4block.go:44) SUBL BP,BX
0480 (md4block.go:44) MOVLQSX BX,BX
0481 (md4block.go:44) LEAQ shift1+0(SB),BP
0482 (md4block.go:44) CMPL BX,8(BP)
0483 (md4block.go:44) JCS ,485
0484 (md4block.go:44) CALL ,runtime.throwindex+0(SB)
0485 (md4block.go:44) MOVQ (BP),BP
0486 (md4block.go:44) MOVL (BP)(BX*4),DI
New code: 6g -S md4.go md4block.go | grep "md4block.go:44"
0471 (md4block.go:44) MOVL AX,BX
0472 (md4block.go:44) ANDL $3,BX
0473 (md4block.go:44) MOVLQZX BX,BX
0474 (md4block.go:44) LEAQ shift1+0(SB),BP
0475 (md4block.go:44) CMPL BX,8(BP)
0476 (md4block.go:44) JCS ,478
0477 (md4block.go:44) CALL ,runtime.throwindex+0(SB)
0478 (md4block.go:44) MOVQ (BP),BP
0479 (md4block.go:44) MOVL (BP)(BX*4),DI
R=agl, agl1
CC=golang-dev
http://codereview.appspot.com/181086
|
|
parsing and printing to new syntax.
Use -oldparser to parse the old syntax,
use -oldprinter to print the old syntax.
2) Change default gofmt formatting settings
to use tabs for indentation only and to use
spaces for alignment. This will make the code
alignment insensitive to an editor's tabwidth.
Use -spaces=false to use tabs for alignment.
3) Manually changed src/exp/parser/parser_test.go
so that it doesn't try to parse the parser's
source files using the old syntax (they have
new syntax now).
4) gofmt -w src misc test/bench
1st set of files.
R=rsc
CC=agl, golang-dev, iant, ken2, r
http://codereview.appspot.com/180047
|