From 6a1b51282bc5728b77a80581a4aa38edcc9f95e5 Mon Sep 17 00:00:00 2001 From: Andrew Browne Date: Mon, 18 Nov 2019 15:04:56 -0800 Subject: Fix error message missed in commit dde589389fcb8b5098f7a47f1b781b27d29a0cac. Patch by Andrew Browne Reviewers: tejohnson, evgeny777 Reviewed By: tejohnson Subscribers: arphaman, hiraditya, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D70195 --- llvm/lib/Bitcode/Reader/BitcodeReader.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'llvm/lib/Bitcode/Reader/BitcodeReader.cpp') diff --git a/llvm/lib/Bitcode/Reader/BitcodeReader.cpp b/llvm/lib/Bitcode/Reader/BitcodeReader.cpp index b99ade6..3a56c1a 100644 --- a/llvm/lib/Bitcode/Reader/BitcodeReader.cpp +++ b/llvm/lib/Bitcode/Reader/BitcodeReader.cpp @@ -5778,9 +5778,11 @@ Error ModuleSummaryIndexBitcodeReader::parseEntireSummary(unsigned ID) { } const uint64_t Version = Record[0]; const bool IsOldProfileFormat = Version == 1; - if (Version < 1 || Version > 8) + if (Version < 1 || Version > ModuleSummaryIndex::BitcodeSummaryVersion) return error("Invalid summary version " + Twine(Version) + - ". Version should be in the range [1-7]."); + ". Version should be in the range [1-" + + Twine(ModuleSummaryIndex::BitcodeSummaryVersion) + + "]."); Record.clear(); // Keep around the last seen summary to be used when we see an optional -- cgit v1.1