diff options
Diffstat (limited to 'gnu/llvm/lib/ProfileData/SampleProfReader.cpp')
| -rw-r--r-- | gnu/llvm/lib/ProfileData/SampleProfReader.cpp | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/gnu/llvm/lib/ProfileData/SampleProfReader.cpp b/gnu/llvm/lib/ProfileData/SampleProfReader.cpp index 234fe02ac8a..44547e3dffa 100644 --- a/gnu/llvm/lib/ProfileData/SampleProfReader.cpp +++ b/gnu/llvm/lib/ProfileData/SampleProfReader.cpp @@ -749,7 +749,7 @@ setupMemoryBuffer(const Twine &Filename) { auto Buffer = std::move(BufferOrErr.get()); // Sanity check the file. - if (Buffer->getBufferSize() > std::numeric_limits<uint32_t>::max()) + if (uint64_t(Buffer->getBufferSize()) > std::numeric_limits<uint32_t>::max()) return sampleprof_error::too_large; return std::move(Buffer); @@ -759,8 +759,6 @@ setupMemoryBuffer(const Twine &Filename) { /// /// \param Filename The file to open. /// -/// \param Reader The reader to instantiate according to \p Filename's format. -/// /// \param C The LLVM context to use to emit diagnostics. /// /// \returns an error code indicating the status of the created reader. @@ -776,8 +774,6 @@ SampleProfileReader::create(const Twine &Filename, LLVMContext &C) { /// /// \param B The memory buffer to create the reader from (assumes ownership). /// -/// \param Reader The reader to instantiate according to \p Filename's format. -/// /// \param C The LLVM context to use to emit diagnostics. /// /// \returns an error code indicating the status of the created reader. |
