blob: 033ecd63d1e1e3b52c9535a927cd4d6599195d3d [file] [log] [blame]
Igor Kudrin11741ce2016-10-07 08:48:28 +00001//===------------------------- fallback_malloc.h --------------------------===//
2//
Chandler Carruth8ee27c32019-01-19 10:56:40 +00003// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4// See https://llvm.org/LICENSE.txt for license information.
5// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
Igor Kudrin11741ce2016-10-07 08:48:28 +00006//
7//===----------------------------------------------------------------------===//
8
9#ifndef _FALLBACK_MALLOC_H
10#define _FALLBACK_MALLOC_H
11
Shoaib Meenaia9921172017-03-01 03:55:57 +000012#include "__cxxabi_config.h"
Igor Kudrin11741ce2016-10-07 08:48:28 +000013#include <cstddef> // for size_t
14
15namespace __cxxabiv1 {
16
Igor Kudrin11741ce2016-10-07 08:48:28 +000017// Allocate some memory from _somewhere_
Eric Fiselierbe1d3492017-03-04 02:04:45 +000018_LIBCXXABI_HIDDEN void * __aligned_malloc_with_fallback(size_t size);
Igor Kudrin11741ce2016-10-07 08:48:28 +000019
20// Allocate and zero-initialize memory from _somewhere_
Shoaib Meenaia9921172017-03-01 03:55:57 +000021_LIBCXXABI_HIDDEN void * __calloc_with_fallback(size_t count, size_t size);
Igor Kudrin11741ce2016-10-07 08:48:28 +000022
Eric Fiselierbe1d3492017-03-04 02:04:45 +000023_LIBCXXABI_HIDDEN void __aligned_free_with_fallback(void *ptr);
Shoaib Meenaia9921172017-03-01 03:55:57 +000024_LIBCXXABI_HIDDEN void __free_with_fallback(void *ptr);
Igor Kudrin11741ce2016-10-07 08:48:28 +000025
26} // namespace __cxxabiv1
27
28#endif