]> Cypherpunks.ru repositories - gostls13.git/commit
cmd/compile: merge sign extension and shift into SBFIZ
authorfanzha02 <fannie.zhang@arm.com>
Mon, 6 Sep 2021 03:15:30 +0000 (11:15 +0800)
committerfannie zhang <Fannie.Zhang@arm.com>
Mon, 6 Sep 2021 03:31:53 +0000 (03:31 +0000)
commit7b69ddc171938b8321a535dd79b8ca2ba56ac72d
tree25a037893bb0068c3960cec1138fdf1874dd545f
parent43b05173a219e19697c2f9c6d98cf4d8667b7ca5
cmd/compile: merge sign extension and shift into SBFIZ

This patch adds some rules to rewrite "(LeftShift (SignExtend x) lc)"
expression as "SBFIZ".

Add the test cases.

Change-Id: I294c4ba09712eeb02c7a952447bb006780f1e60d
Reviewed-on: https://go-review.googlesource.com/c/go/+/267602
Trust: fannie zhang <Fannie.Zhang@arm.com>
Trust: Cherry Mui <cherryyz@google.com>
Run-TryBot: fannie zhang <Fannie.Zhang@arm.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Keith Randall <khr@golang.org>
src/cmd/compile/internal/ssa/gen/ARM64.rules
src/cmd/compile/internal/ssa/rewriteARM64.go
test/codegen/bitfield.go