summaryrefslogtreecommitdiffstats
path: root/llvm/unittests/ProfileData/InstrProfTest.cpp
diff options
context:
space:
mode:
authorVedant Kumar <vsk@apple.com>2017-07-10 21:44:43 +0000
committerVedant Kumar <vsk@apple.com>2017-07-10 21:44:43 +0000
commit910d3d0541f0cada8308da43d81bff721cdbba99 (patch)
tree23b2634fd605d744c242b40af15902eb4b60090b /llvm/unittests/ProfileData/InstrProfTest.cpp
parentf7850fa8b64d56e688543414d02bca3b1f1c9364 (diff)
downloadbcm5719-llvm-910d3d0541f0cada8308da43d81bff721cdbba99.tar.gz
bcm5719-llvm-910d3d0541f0cada8308da43d81bff721cdbba99.zip
InstrProf: Fix unit test which accidentally used a duplicate name
This unit test constructed some profile records incorrectly. One of the records had a duplicate name: adding that record into the writer caused an error unrelated to what needed to be tested. Reported by David Blaikie! llvm-svn: 307596
Diffstat (limited to 'llvm/unittests/ProfileData/InstrProfTest.cpp')
-rw-r--r--llvm/unittests/ProfileData/InstrProfTest.cpp5
1 files changed, 1 insertions, 4 deletions
diff --git a/llvm/unittests/ProfileData/InstrProfTest.cpp b/llvm/unittests/ProfileData/InstrProfTest.cpp
index 71795b01ba8..79f880e475c 100644
--- a/llvm/unittests/ProfileData/InstrProfTest.cpp
+++ b/llvm/unittests/ProfileData/InstrProfTest.cpp
@@ -996,10 +996,7 @@ TEST_P(MaybeSparseInstrProfTest, instr_prof_symtab_compression_test) {
TEST_F(SparseInstrProfTest, preserve_no_records) {
Writer.addRecord({"foo", 0x1234, {0}}, Err);
Writer.addRecord({"bar", 0x4321, {0, 0}}, Err);
- // FIXME: I'm guessing this data should be different, but the original author
- // should check/update this test so it doesn't produce errors.
- Writer.addRecord({"bar", 0x4321, {0, 0, 0}},
- [](Error E) { consumeError(std::move(E)); });
+ Writer.addRecord({"baz", 0x4321, {0, 0, 0}}, Err);
auto Profile = Writer.writeBuffer();
readProfile(std::move(Profile));
OpenPOWER on IntegriCloud