summaryrefslogtreecommitdiff
path: root/polly/include
diff options
context:
space:
mode:
authorMichael Kruse <llvm-project@meinersbur.de>2021-09-25 01:03:36 -0500
committerMichael Kruse <llvm-project@meinersbur.de>2021-09-26 03:26:43 -0500
commitd5c87162db7763c89160dc66894bebf3bd1e90d7 (patch)
tree301340ff76b5580b6b425ec8d0e023323b445047 /polly/include
parent1cea25eec90e355c9b072edc1b6e1e9903d7bca4 (diff)
downloadllvm-d5c87162db7763c89160dc66894bebf3bd1e90d7.tar.gz
[Polly] Use VirtualUse to determine references.
VirtualUse ensures consistency over different source of values with Polly. In particular, this enables its use of instructions moved between Statement. Before the patch, the code wrongly assumed that the BB's instructions are also the ScopStmt's instructions. Reference are determined for OpenMP outlining and GPGPU kernel extraction. GPGPU CodeGen had some problems. For one, it generated GPU kernel parameters for constants. Second, it emitted GPU-side invariant loads which have already been loaded by the host. This has been partially fixed, it still generates a store for the invariant load result, but using the value that the host has already written. WARNING: I did not test the generated PollyACC code on an actual GPU. The improved consistency will be made use of in the next patch.
Diffstat (limited to 'polly/include')
-rw-r--r--polly/include/polly/CodeGen/IslNodeBuilder.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/polly/include/polly/CodeGen/IslNodeBuilder.h b/polly/include/polly/CodeGen/IslNodeBuilder.h
index ee0a1e58ae86..450d63c286e9 100644
--- a/polly/include/polly/CodeGen/IslNodeBuilder.h
+++ b/polly/include/polly/CodeGen/IslNodeBuilder.h
@@ -58,7 +58,7 @@ struct SubtreeReferences {
/// SubtreeReferences structure.
/// @param CreateScalarRefs Should the result include allocas of scalar
/// references?
-void addReferencesFromStmt(const ScopStmt *Stmt, void *UserPtr,
+void addReferencesFromStmt(ScopStmt *Stmt, void *UserPtr,
bool CreateScalarRefs = true);
class IslNodeBuilder {