[PATCH] D15706: [Polly] Follow uses to create value MemoryAccesses

Michael Kruse via llvm-commits llvm-commits at lists.llvm.org
Mon Dec 21 17:25:00 PST 2015


Meinersbur created this revision.
Meinersbur added reviewers: grosser, jdoerfert.
Meinersbur added subscribers: llvm-commits, pollydev.
Meinersbur added a project: Polly.

The current approach is to follow value definitions and create write accesses ("push defs") while searching for uses. Because it does not catch all uses (e.g. those by PHIs), some code adds more scalar reads write on the fly, with relatively conditions and possible creation of MemoryAccesses that are not required.

We replace this by iterating over the uses in a SCoP ("pull in requirements"), and add writes only when at least one read has been added. It turns out to be simpler code because each use is only iterated over once and writes are added for the first access that reads it. A drawback is that we need another iteration to identify escaping values (uses not in the SCoP), but which also makes the difference between such accesses more obvious.

http://reviews.llvm.org/D15706

Files:
  include/polly/ScopInfo.h
  lib/Analysis/ScopInfo.cpp
  test/Isl/CodeGen/MemAccess/update_access_functions.ll
  test/Isl/CodeGen/phi_escaping_phi_incoming_user_1.ll
  test/ScopInfo/invariant-loads-leave-read-only-statements.ll
  test/ScopInfo/many-scalar-dependences.ll
  test/ScopInfo/non_affine_region_4.ll
  test/ScopInfo/phi_condition_modeling_2.ll
  test/ScopInfo/phi_loop_carried_float.ll
  test/ScopInfo/phi_scalar_simple_1.ll
  test/ScopInfo/phi_scalar_simple_2.ll
  test/ScopInfo/scalar.ll
  test/ScopInfo/tempscop-printing.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D15706.43422.patch
Type: text/x-patch
Size: 24586 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20151222/fbaa486f/attachment.bin>


More information about the llvm-commits mailing list