xref: /freebsd/contrib/llvm-project/compiler-rt/lib/sanitizer_common/sanitizer_mallinfo.h (revision 5f757f3ff9144b609b3c433dfd370cc6bdc191ad)
106c3fb27SDimitry Andric //===-- sanitizer_mallinfo.h ----------------------------------------------===//
206c3fb27SDimitry Andric //
306c3fb27SDimitry Andric // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
406c3fb27SDimitry Andric // See https://llvm.org/LICENSE.txt for license information.
506c3fb27SDimitry Andric // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
606c3fb27SDimitry Andric //
706c3fb27SDimitry Andric //===----------------------------------------------------------------------===//
806c3fb27SDimitry Andric //
906c3fb27SDimitry Andric // This file is a part of Sanitizer common code.
1006c3fb27SDimitry Andric //
1106c3fb27SDimitry Andric // Definition for mallinfo on different platforms.
1206c3fb27SDimitry Andric //===----------------------------------------------------------------------===//
1306c3fb27SDimitry Andric 
1406c3fb27SDimitry Andric #ifndef SANITIZER_MALLINFO_H
1506c3fb27SDimitry Andric #define SANITIZER_MALLINFO_H
1606c3fb27SDimitry Andric 
1706c3fb27SDimitry Andric #include "sanitizer_internal_defs.h"
1806c3fb27SDimitry Andric #include "sanitizer_platform.h"
1906c3fb27SDimitry Andric 
2006c3fb27SDimitry Andric namespace __sanitizer {
2106c3fb27SDimitry Andric 
2206c3fb27SDimitry Andric #if SANITIZER_ANDROID
2306c3fb27SDimitry Andric 
2406c3fb27SDimitry Andric struct __sanitizer_struct_mallinfo {
2506c3fb27SDimitry Andric   uptr v[10];
2606c3fb27SDimitry Andric };
2706c3fb27SDimitry Andric 
2806c3fb27SDimitry Andric #elif SANITIZER_LINUX || SANITIZER_APPLE || SANITIZER_FUCHSIA
2906c3fb27SDimitry Andric 
3006c3fb27SDimitry Andric struct __sanitizer_struct_mallinfo {
3106c3fb27SDimitry Andric   int v[10];
3206c3fb27SDimitry Andric };
3306c3fb27SDimitry Andric 
34*5f757f3fSDimitry Andric struct __sanitizer_struct_mallinfo2 {
35*5f757f3fSDimitry Andric   uptr v[10];
36*5f757f3fSDimitry Andric };
37*5f757f3fSDimitry Andric 
3806c3fb27SDimitry Andric #endif
3906c3fb27SDimitry Andric 
4006c3fb27SDimitry Andric }  // namespace __sanitizer
4106c3fb27SDimitry Andric 
4206c3fb27SDimitry Andric #endif  // SANITIZER_MALLINFO_H
43