diff options
author | William Huang <williamjhuang@google.com> | 2022-12-28 21:26:16 +0000 |
---|---|---|
committer | William Huang <williamjhuang@google.com> | 2023-01-03 19:24:45 +0000 |
commit | 07107f339058ba10c44b64c85412578e5e68256e (patch) | |
tree | 2c55ffc19d6de166838e9f1e5b0222325b8b40be /llvm/lib/ProfileData/SampleProfReader.cpp | |
parent | 06c440f2dac2598308d777e704cc4866471af561 (diff) | |
download | llvm-07107f339058ba10c44b64c85412578e5e68256e.zip llvm-07107f339058ba10c44b64c85412578e5e68256e.tar.gz llvm-07107f339058ba10c44b64c85412578e5e68256e.tar.bz2 |
[llvm-profdata] Remove unnecessary file size check
Unsure why profile reader checks profile size to be less than 4 GB. This breaks builds using a very large profile.
The limit is not seen anywhere else, so I am not sure why is it there in the first place.
Reviewed By: davidxl
Differential Revision: https://reviews.llvm.org/D140741
Diffstat (limited to 'llvm/lib/ProfileData/SampleProfReader.cpp')
-rw-r--r-- | llvm/lib/ProfileData/SampleProfReader.cpp | 4 |
1 files changed, 0 insertions, 4 deletions
diff --git a/llvm/lib/ProfileData/SampleProfReader.cpp b/llvm/lib/ProfileData/SampleProfReader.cpp index 25b13e0..b2a38c6 100644 --- a/llvm/lib/ProfileData/SampleProfReader.cpp +++ b/llvm/lib/ProfileData/SampleProfReader.cpp @@ -1837,10 +1837,6 @@ setupMemoryBuffer(const Twine &Filename) { return EC; auto Buffer = std::move(BufferOrErr.get()); - // Check the file. - if (uint64_t(Buffer->getBufferSize()) > std::numeric_limits<uint32_t>::max()) - return sampleprof_error::too_large; - return std::move(Buffer); } |