As far as I can tell, malloc.h is only being used here to provide
a definition of mallinfo (malloc itself is declared in stdlib.h via
cstdlib). We already have a macro for whether mallinfo is available,
so switch to using that instead.
Details
Details
Diff Detail
Diff Detail
- Repository
- rL LLVM
Event Timeline
Comment Actions
Nice!
llvm/lib/Support/Unix/Process.inc | ||
---|---|---|
36 ↗ | (On Diff #185494) | This change kind of assumes that HAVE_MALLINFO is false on dragonfly and openbsd. But I suppose it's consistent with check_symbol_exists(mallinfo malloc.h HAVE_MALLINFO) in config-ix.cmake. |
llvm/lib/Support/Unix/Process.inc | ||
---|---|---|
36 ↗ | (On Diff #185494) | Yes and neither of those platforms have a mallinfo, or ever had it as far as I can tell, so this change should be fine on those platforms. |