summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTobias Grosser <grosser@fim.uni-passau.de>2011-08-03 00:09:49 +0000
committerTobias Grosser <grosser@fim.uni-passau.de>2011-08-03 00:09:49 +0000
commit51e89bf87ffacc33f9c9bbc3705a2e6cee6e9cd9 (patch)
treeebcdb8465c9ea969b03c4db3976409ef448ce427
parentb3bfd84ebb6657be47c0294de459f1ff02d3a9c6 (diff)
downloadbcm5719-llvm-51e89bf87ffacc33f9c9bbc3705a2e6cee6e9cd9.tar.gz
bcm5719-llvm-51e89bf87ffacc33f9c9bbc3705a2e6cee6e9cd9.zip
Dependences: Fix memory corruption.
Signed-off-by: Tobias Grosser <tobias@grosser.es> llvm-svn: 136749
-rw-r--r--polly/lib/Analysis/Dependences.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/polly/lib/Analysis/Dependences.cpp b/polly/lib/Analysis/Dependences.cpp
index 4de38804c43..9bcab6e5485 100644
--- a/polly/lib/Analysis/Dependences.cpp
+++ b/polly/lib/Analysis/Dependences.cpp
@@ -102,12 +102,12 @@ bool Dependences::runOnScop(Scop &S) {
accdom = isl_map_intersect_domain(accdom, domcp);
if ((*MI)->isRead())
- isl_union_map_add_map(sink, accdom);
+ sink = isl_union_map_add_map(sink, accdom);
else
- isl_union_map_add_map(must_source, accdom);
+ must_source = isl_union_map_add_map(must_source, accdom);
}
isl_map *scattering = isl_map_copy(Stmt->getScattering());
- isl_union_map_add_map(schedule, scattering);
+ schedule = isl_union_map_add_map(schedule, scattering);
}
DEBUG(
@@ -167,7 +167,7 @@ bool Dependences::isValidScattering(StatementToIslMapTy *NewScattering) {
else
scattering = isl_map_copy((*NewScattering)[Stmt]);
- isl_union_map_add_map(schedule, scattering);
+ schedule = isl_union_map_add_map(schedule, scattering);
}
isl_union_map *temp_must_dep, *temp_may_dep;
@@ -240,7 +240,7 @@ isl_union_map* getCombinedScheduleForDim(Scop *scop, unsigned dimLevel) {
unsigned remainingDimensions = isl_map_n_out(scattering) - dimLevel;
scattering = isl_map_project_out(scattering, isl_dim_out, dimLevel,
remainingDimensions);
- isl_union_map_add_map(schedule, scattering);
+ schedule = isl_union_map_add_map(schedule, scattering);
}
return schedule;
OpenPOWER on IntegriCloud