summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTobias Grosser <grosser@fim.uni-passau.de>2012-02-15 09:58:50 +0000
committerTobias Grosser <grosser@fim.uni-passau.de>2012-02-15 09:58:50 +0000
commitcb47dfeb96ff7d2ed5097c535fcdbe4939634fad (patch)
tree12d2bfc561e72fd3f9c23c3fda901c66390cd18f
parentb61e6318acf2cb27bfd57668bd40d3285e454c9c (diff)
downloadbcm5719-llvm-cb47dfeb96ff7d2ed5097c535fcdbe4939634fad.tar.gz
bcm5719-llvm-cb47dfeb96ff7d2ed5097c535fcdbe4939634fad.zip
CodeGen: Retain the old BB names within the original SCoP
llvm-svn: 150576
-rw-r--r--polly/lib/CodeGeneration.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/polly/lib/CodeGeneration.cpp b/polly/lib/CodeGeneration.cpp
index 17613cbfbda..3b6aa191a41 100644
--- a/polly/lib/CodeGeneration.cpp
+++ b/polly/lib/CodeGeneration.cpp
@@ -1608,6 +1608,9 @@ class CodeGeneration : public ScopPass {
newBlock = SplitEdge(region->getEnteringBlock(), region->getEntry(), this);
if (DT->dominates(region->getEntry(), newBlock)) {
+ BasicBlock *OldBlock = region->getEntry();
+ std::string OldName = OldBlock->getName();
+
// Update ScopInfo.
for (Scop::iterator SI = S->begin(), SE = S->end(); SI != SE; ++SI)
if ((*SI)->getBasicBlock() == newBlock) {
@@ -1616,7 +1619,9 @@ class CodeGeneration : public ScopPass {
}
// Update RegionInfo.
- splitBlock = region->getEntry();
+ splitBlock = OldBlock;
+ OldBlock->setName("polly.split");
+ newBlock->setName(OldName);
region->replaceEntry(newBlock);
RI->setRegionFor(newBlock, region);
} else {
OpenPOWER on IntegriCloud