[PATCH] D101986: [InstSimplify] Remove redundant {insert,extract}_vector intrinsic chains

Joe Ellis via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu May 6 03:56:08 PDT 2021


joechrisellis created this revision.
joechrisellis added reviewers: bsmith, DavidTruby, peterwaller-arm.
Herald added a subscriber: hiraditya.
joechrisellis requested review of this revision.
Herald added projects: clang, LLVM.
Herald added subscribers: llvm-commits, cfe-commits.

This commit removes some redundant {insert,extract}_vector intrinsic
chains by implementing the following patterns as instsimplifies:

  (insert_vector _, (extract_vector X, 0), 0) -> X
  (extract_vector (insert_vector _, X, 0), 0) -> X


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D101986

Files:
  clang/test/CodeGen/attr-arm-sve-vector-bits-call.c
  clang/test/CodeGen/attr-arm-sve-vector-bits-cast.c
  llvm/lib/Analysis/InstructionSimplify.cpp
  llvm/test/Transforms/InstSimplify/extract-vector.ll
  llvm/test/Transforms/InstSimplify/insert-vector.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D101986.343350.patch
Type: text/x-patch
Size: 29585 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20210506/aed61a48/attachment-0001.bin>


More information about the cfe-commits mailing list