Build domtree of new loops correctly

This fixes a bug introduced in r217525.

git-svn-id: https://llvm.org/svn/llvm-project/polly/trunk@218581 91177308-0d34-0410-b5e6-96231b3b80d8
Disable runtime alias checks when we ignore aliasing.

  This is just a optimization to save the compile time and execution time
  for runtime alias checks if the user guarantees no aliasing all together.


git-svn-id: https://llvm.org/svn/llvm-project/polly/trunk@218613 91177308-0d34-0410-b5e6-96231b3b80d8
[RTC] Split alias groups according to read only base addresses

  If there are multiple read only base addresses in an alias group
  we can split it into multiple alias groups each with only one
  read only access. This way we might reduce the number of
  comparisons significantly as it grows linear in the number of
  alias groups but exponential in their size.

Differential Revision: http://reviews.llvm.org/D5435



git-svn-id: https://llvm.org/svn/llvm-project/polly/trunk@218757 91177308-0d34-0410-b5e6-96231b3b80d8
[RTC] Use the domain to split alias groups.

  We use a parametric abstraction of the domain to split alias groups
  if accesses cannot be executed under the same parameter evaluation.

  The two test cases check that we can remove alias groups if the
  pointers which might alias are never accessed under the same parameter
  evaluation and that the minimal/maximal accesses are not global but
  with regards to the parameter evaluation.

Differential Revision: http://reviews.llvm.org/D5436



git-svn-id: https://llvm.org/svn/llvm-project/polly/trunk@218758 91177308-0d34-0410-b5e6-96231b3b80d8
Annotate LLVM-IR for all parallel loops

  This change allows to annotate all parallel loops with loop id metadata.
  Furthermore, it will annotate memory instructions with
  llvm.mem.parallel_loop_access metadata for all surrounding parallel loops.
  This is especially usefull if an external paralleliser is used.

  This also removes the PollyLoopInfo class and comments the
  LoopAnnotator.

  A test case for multiple parallel loops is attached.



git-svn-id: https://llvm.org/svn/llvm-project/polly/trunk@218793 91177308-0d34-0410-b5e6-96231b3b80d8
Update testcase to new intrinsic format

git-svn-id: https://llvm.org/svn/llvm-project/polly/trunk@218806 91177308-0d34-0410-b5e6-96231b3b80d8
Change the output of arc unit

  arc unit will now show the number of consecutive tests with the same
  result instead of printing a "." for each one. Due to the number of
  tests the "dots" didn't fit in one line any more. Furthermore the
  result list is shortened, only non passing tests or tests taking
  longer than a time threshold (50ms) will be reported (both to the user
  and to phabricator).


git-svn-id: https://llvm.org/svn/llvm-project/polly/trunk@218826 91177308-0d34-0410-b5e6-96231b3b80d8
Allow to annotate alias scopes in the new SCoP.

  The command line flag -polly-annotate-alias-scopes controls whether or not
  Polly annotates alias scopes in the new SCoP (default ON). This can improve
  later optimizations as the new SCoP is basically an alias free environment for
  them.



git-svn-id: https://llvm.org/svn/llvm-project/polly/trunk@218877 91177308-0d34-0410-b5e6-96231b3b80d8
[Refactor] Rename LoopAnnotator to ScopAnnotator

  The LoopAnnotator doesn't annotate only loops any more, thus it is
  called ScopAnnotator from now on.

  This also removes unnecessary polly:: namespace tags.



git-svn-id: https://llvm.org/svn/llvm-project/polly/trunk@218878 91177308-0d34-0410-b5e6-96231b3b80d8
Align copied load/store instructions as the original.

  This also forbids the json importer to access other memory locations
  than the original instruction as we to reuse the alignment of the
  original load/store.

Differential Revision: http://reviews.llvm.org/D5560



git-svn-id: https://llvm.org/svn/llvm-project/polly/trunk@218883 91177308-0d34-0410-b5e6-96231b3b80d8
[Refactor] Generalize parallel code generation

  + Generalized function names and comments
    + Removed OpenMP (omp) from the names and comments
    + Use common names (non OpenMP specific) for runtime library call creation
      methodes
  + Commented the parallel code generator and all its member functions
  + Refactored some values and methodes

Differential Revision: http://reviews.llvm.org/D4990



git-svn-id: https://llvm.org/svn/llvm-project/polly/trunk@219003 91177308-0d34-0410-b5e6-96231b3b80d8
Add option to limit the maximal number of parallel threads.

Differential Revision: http://reviews.llvm.org/D5581



git-svn-id: https://llvm.org/svn/llvm-project/polly/trunk@219004 91177308-0d34-0410-b5e6-96231b3b80d8
Put the parallel context alloca into the function entry block.

  We use lifetime markers to limit the actual life range (similar to clang).

Differential Revision: http://reviews.llvm.org/D5582



git-svn-id: https://llvm.org/svn/llvm-project/polly/trunk@219005 91177308-0d34-0410-b5e6-96231b3b80d8
[Fix] Accidently changed the type of a libgomp argument in r219003.

  Only subsequent patches introduced tests for the signature in the
  generated IR, thus the tests were wrong too and are adjusted now.



git-svn-id: https://llvm.org/svn/llvm-project/polly/trunk@219017 91177308-0d34-0410-b5e6-96231b3b80d8
DI: LLVM schema change: fold constants into string

Update debug info testcases for the LLVM metadata schema change in
r219010 to fold metadata constant operands into a single `MDString`.

Part of PR17891.

git-svn-id: https://llvm.org/svn/llvm-project/polly/trunk@219019 91177308-0d34-0410-b5e6-96231b3b80d8
Introduce the ScopArrayInfo class.

  This class allows to store information about the arrays in the SCoP.
  For each base pointer in the SCoP one object is created storing the
  type and dimension sizes of the array. The objects can be obtained via
  the SCoP, a MemoryAccess or the isl_id associated with the output
  dimension of a MemoryAccess (the description of what is accessed).

  So far we use the information in the IslExprBuilder to create the
  right base type before indexing into the base array. This fixes the
  bug http://llvm.org/bugs/show_bug.cgi?id=21113 (both test cases are
  included). On top of that we can now build runtime alias checks for
  delinearized arrays as the dimension sizes are also part of the
  ScopArrayInfo objects.

Differential Revision: http://reviews.llvm.org/D5613


git-svn-id: https://llvm.org/svn/llvm-project/polly/trunk@219077 91177308-0d34-0410-b5e6-96231b3b80d8
Allow multidimensional accesses in the IslExprBuilder.

  This resolved the issues with delinearized accesses that might alias,
  thus delinearization doesn't deactivate runtime alias checks anymore.

Differential Revision: http://reviews.llvm.org/D5614


git-svn-id: https://llvm.org/svn/llvm-project/polly/trunk@219078 91177308-0d34-0410-b5e6-96231b3b80d8
Try to unbreak the polly build.


git-svn-id: https://llvm.org/svn/llvm-project/polly/trunk@219080 91177308-0d34-0410-b5e6-96231b3b80d8
[Fix] Dead statements should not confuse the RTC generation

  This fixes http://llvm.org/bugs/show_bug.cgi?id=21166 .

Differential Revision: http://reviews.llvm.org/D5623


git-svn-id: https://llvm.org/svn/llvm-project/polly/trunk@219131 91177308-0d34-0410-b5e6-96231b3b80d8
[Refactor] Change the comment style to silence -Wcomment

  -Wcomment complained about a "multi-line comment" caused by the
  ascii art used in ScopHelper to describe the CFG.

Differential Revision: http://reviews.llvm.org/D5618


git-svn-id: https://llvm.org/svn/llvm-project/polly/trunk@219207 91177308-0d34-0410-b5e6-96231b3b80d8