[PATCH] D14005: Use the new 'InvariantInfo' property to eliminate redundant loads with --instcombine

Larisse Voufo via llvm-commits llvm-commits at lists.llvm.org
Thu Oct 22 21:12:56 PDT 2015


lvoufo created this revision.
lvoufo added reviewers: nlewycky, reames, dberlin.
lvoufo added a subscriber: llvm-commits.

Similar to GVN in D14004: While processing instructions in InstCombine, mark global variables and alloca instructions corresponding to each encountered invariant intrinsic call as indicating 'writeonce' memory locations that either have been written into or can be written into again (once). Then, while scanning instructions backwards looking for available loads for a given memory location, be sure to temporarily disable or reset the markings, as appropriate. 

This patch is a break-down of (corrected) D13606.


http://reviews.llvm.org/D14005

Files:
  lib/Analysis/Loads.cpp
  lib/Transforms/InstCombine/InstCombineCalls.cpp
  lib/Transforms/InstCombine/InstCombineInternal.h
  lib/Transforms/InstCombine/InstructionCombining.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D14005.38205.patch
Type: text/x-patch
Size: 6092 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20151023/e9129305/attachment.bin>


More information about the llvm-commits mailing list