[PATCH] D45810: [Sparc] Use synthetic instruction clr to zero register instead of sethi

Daniel Cederman via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Apr 19 05:14:04 PDT 2018


dcederman created this revision.
dcederman added reviewers: jyknight, venkatra.
Herald added subscribers: llvm-commits, jrtc27, fedor.sergeev, eraman.

Using `clr reg`/`mov %g0, reg`/`or %g0, %g0, reg` to zero a register looks much better than `sethi 0, reg`.


Repository:
  rL LLVM

https://reviews.llvm.org/D45810

Files:
  lib/Target/Sparc/SparcInstrInfo.td
  test/CodeGen/SPARC/atomics.ll
  test/CodeGen/SPARC/imm.ll
  test/CodeGen/SPARC/inlineasm.ll
  test/CodeGen/SPARC/vector-extract-elt.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D45810.143070.patch
Type: text/x-patch
Size: 3634 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20180419/8b689567/attachment.bin>


More information about the llvm-commits mailing list