[PATCH] D67611: [LoopUnrollAnalyzer] Try to simplify address computation outside of loop.

Florian Hahn via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Sep 16 05:16:08 PDT 2019


fhahn created this revision.
fhahn added reviewers: efriedma, dmgreen, hfinkel.
Herald added subscribers: dkrupp, donat.nagy, Szelethus, a.sidorin, zzheng, baloghadamsoftware, hiraditya.
Herald added a project: LLVM.

The analyzer tries to simplify address computations inside the loop
body, but not outside the loop. This means we currently fail to
recognize some pointer compares as free.

This patch adds machinery to simplify address computations outside the
loop. We use it directly in visitCmpInst, because it do not visit the
instructions outside the loop currently.

This helps with cost modelling of loops like the on in PR43305.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D67611

Files:
  llvm/include/llvm/Analysis/LoopUnrollAnalyzer.h
  llvm/lib/Analysis/LoopUnrollAnalyzer.cpp
  llvm/lib/Transforms/Scalar/LoopUnrollPass.cpp
  llvm/test/Transforms/LoopUnroll/unrolled-inst-analyzer-pointers.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D67611.220313.patch
Type: text/x-patch
Size: 6603 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190916/70bcee0a/attachment.bin>


More information about the llvm-commits mailing list