diff options
author | Tobias Grosser <tobias@grosser.es> | 2014-07-02 16:26:47 +0000 |
---|---|---|
committer | Tobias Grosser <tobias@grosser.es> | 2014-07-02 16:26:47 +0000 |
commit | ce67a044e0338fc99e29a0a9c672783193552274 (patch) | |
tree | ea9ae9cd2bec05d1dc78808552d263a49430879e /llvm/lib/CodeGen/MachineScheduler.cpp | |
parent | 35af19ab1fe878b8e5545698e0939ef37b99b426 (diff) | |
download | llvm-ce67a044e0338fc99e29a0a9c672783193552274.zip llvm-ce67a044e0338fc99e29a0a9c672783193552274.tar.gz llvm-ce67a044e0338fc99e29a0a9c672783193552274.tar.bz2 |
Use arguments of user statements to perform induction variable substitution
To translate the old induction variables as they exist before Polly to new
new induction variables introduced during AST code generation we need to
generate code that computes the new values from the old ones. We can do this
by just looking at the arguments isl generates in each scheduled statement.
Example:
// Old
for i
S(i)
// New
for c0
for c1
S(c0 + c1)
To get the value of i, we need to compute 'c0 + c1'. This expression is readily
available in the user statements generated by isl and just needs to be
translated to LLVM-IR.
This replaces an old confusing construct that constructed during ast generation
an isl multi affine expression that described this relation and which was then
again ast generated for each statement and argument when translating the isl ast
to LLVM-IR. This approach was difficult to understand and the additional ast
generation calls where entirely redundant as isl provides the relevant
expressions as arguments of the generated user statements.
llvm-svn: 212186
Diffstat (limited to 'llvm/lib/CodeGen/MachineScheduler.cpp')
0 files changed, 0 insertions, 0 deletions