summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/Hexagon/HexagonFrameLowering.cpp
diff options
context:
space:
mode:
authorKrzysztof Parzyszek <kparzysz@codeaurora.org>2016-02-13 14:06:01 +0000
committerKrzysztof Parzyszek <kparzysz@codeaurora.org>2016-02-13 14:06:01 +0000
commit280a50ebb9dd8c8147ac3f2d94ab0bfc9ab9ae8f (patch)
tree2c7cf404887e272996a26be3c4ef1907c7182df0 /llvm/lib/Target/Hexagon/HexagonFrameLowering.cpp
parent0772c42385c0d005db0ba75ecbcc54d353763282 (diff)
downloadbcm5719-llvm-280a50ebb9dd8c8147ac3f2d94ab0bfc9ab9ae8f.tar.gz
bcm5719-llvm-280a50ebb9dd8c8147ac3f2d94ab0bfc9ab9ae8f.zip
[Hexagon] Replace use of "std::map::emplace" with "insert"
Gcc 4.7.2-4 does not seem to have "emplace" in its implementation of map. This should fix the build failure on polly-amd64-linux. llvm-svn: 260816
Diffstat (limited to 'llvm/lib/Target/Hexagon/HexagonFrameLowering.cpp')
-rw-r--r--llvm/lib/Target/Hexagon/HexagonFrameLowering.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/llvm/lib/Target/Hexagon/HexagonFrameLowering.cpp b/llvm/lib/Target/Hexagon/HexagonFrameLowering.cpp
index 62877870395..42c94091b9e 100644
--- a/llvm/lib/Target/Hexagon/HexagonFrameLowering.cpp
+++ b/llvm/lib/Target/Hexagon/HexagonFrameLowering.cpp
@@ -1762,7 +1762,10 @@ void HexagonFrameLowering::optimizeSpillSlots(MachineFunction &MF,
// and collect relevant information.
for (auto &B : MF) {
std::map<int,IndexType> LastStore, LastLoad;
- auto P = BlockIndexes.emplace(&B, HexagonBlockRanges::InstrIndexMap(B));
+ // Emplace appears not to be supported in gcc 4.7.2-4.
+ //auto P = BlockIndexes.emplace(&B, HexagonBlockRanges::InstrIndexMap(B));
+ auto TmpP = std::make_pair(&B, HexagonBlockRanges::InstrIndexMap(B));
+ auto P = BlockIndexes.insert(TmpP);
auto &IndexMap = P.first->second;
DEBUG(dbgs() << "Index map for BB#" << B.getNumber() << "\n"
<< IndexMap << '\n');
OpenPOWER on IntegriCloud