[libc-commits] [PATCH] D79469: [libc] Fix warnings on release build.
Alex Brachet via Phabricator via libc-commits
libc-commits at lists.llvm.org
Tue May 5 23:57:35 PDT 2020
abrachet accepted this revision.
abrachet added inline comments.
================
Comment at: libc/utils/benchmarks/LibcMemoryBenchmarkTest.cpp:50-51
Conf.BufferSize = 8192;
- Conf.AddressAlignment = Align::None();
+ // Default constructor has no alignment.
+ Conf.AddressAlignment = Align();
Conf.Size.To = 1;
----------------
`AddressAlignment` is already defaulted in `StudyConfiguration`'s default ctor so we don't need this line.
================
Comment at: libc/utils/testutils/FDReaderUnix.cpp:19-20
FDReader::FDReader() {
int err = ::pipe(pipefd);
- assert(!err && "pipe(2) failed");
+ if (err)
+ llvm::report_fatal_error("pipe(2) failed");
----------------
Maybe `if (::pipe(pipefd))`?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D79469/new/
https://reviews.llvm.org/D79469
More information about the libc-commits
mailing list