obj2yaml: Use the correct relocation type for different machine types
[oota-llvm.git] / lib / ProfileData / InstrProfWriter.cpp
index 320860a4cb410b6bf9c5a23d95b270dfe1cc392b..3024f9676e329883c8c5f841ef98caadd1079a71 100644 (file)
@@ -23,7 +23,9 @@ error_code InstrProfWriter::addFunctionCounts(StringRef FunctionName,
   auto Where = FunctionData.find(FunctionName);
   if (Where == FunctionData.end()) {
     // If this is the first time we've seen this function, just add it.
-    FunctionData[FunctionName] = {FunctionHash, Counters};
+    auto &Data = FunctionData[FunctionName];
+    Data.Hash = FunctionHash;
+    Data.Counts = Counters;
     return instrprof_error::success;;
   }