diff options
| author | Joel Sing <joel@sing.id.au> | 2025-02-18 18:23:27 +1100 |
|---|---|---|
| committer | Joel Sing <joel@sing.id.au> | 2025-03-21 17:40:34 -0700 |
| commit | af133d86e4de00e65581799c155659ce9c8c556c (patch) | |
| tree | 534fc283822a684c0dbc6932da5a46f97beb90ba /test/codegen | |
| parent | 574e836055f2b329824ae3646bf1cb563ca03d54 (diff) | |
| download | go-af133d86e4de00e65581799c155659ce9c8c556c.tar.xz | |
cmd/internal/obj/riscv: factor out shift constant code
Move the code that tests to see if a constant can be represented by a
32 bit signed integer and a logical left shift. This reduces duplication
and increases readability. Also add test coverage now that this is an
independent function.
Change-Id: Id25395b1380b00cf5b69ca201b7715ef84f7ade6
Reviewed-on: https://go-review.googlesource.com/c/go/+/652777
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Meng Zhuo <mengzhuo1203@gmail.com>
Reviewed-by: David Chase <drchase@google.com>
Reviewed-by: Cherry Mui <cherryyz@google.com>
Diffstat (limited to 'test/codegen')
0 files changed, 0 insertions, 0 deletions
