/usr/include/macdecls.h is in libglobalarrays-dev 5.4~beta~r10636+dfsg-5.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 | /** @file
* Public header file for a portable dynamic memory allocator.
*
* This file may be included by internal and external C files.
*/
#ifndef _macdecls_h
#define _macdecls_h
#ifdef __cplusplus
extern "C" {
#endif
#include "macommon.h"
#include "matypes.h"
/**
** constants
**/
/* datatypes */
#define MT_CHAR MT_C_CHAR /**< char */
#define MT_INT MT_C_INT /**< int */
#define MT_LONGINT MT_C_LONGINT /**< long int */
#define MT_LONGLONG MT_C_LONGLONG /**< long long */
#define MT_REAL MT_C_FLOAT /**< float */
#define MT_DBL MT_C_DBL /**< double */
#define MT_LDBL MT_C_LDBL /**< long double */
#define MT_SCPL MT_C_SCPL /**< single precision complex */
#define MT_DCPL MT_C_DCPL /**< double precision complex */
#define MT_LDCPL MT_C_LDCPL /**< long double precision complex */
#define MT_C_FIRST MT_CHAR /**< first type */
#define MT_C_LAST MT_LDCPL /**< last type */
/**
** function types
**/
extern Boolean MA_alloc_get(
Integer datatype, /**< of elements in this block */
Integer nelem, /**< # of elements in this block */
const char *name, /**< assigned to this block by client */
Integer *memhandle, /**< RETURN: handle for this block */
MA_AccessIndex *index /**< RETURN: index for this block */ );
extern Boolean MA_allocate_heap(
Integer datatype, /**< of elements in this block */
Integer nelem, /**< # of elements in this block */
const char *name, /**< assigned to this block by client */
Integer *memhandle /**< RETURN: handle for this block */ );
extern Boolean MA_chop_stack(Integer memhandle);
extern Boolean MA_free_heap(Integer memhandle);
extern Boolean MA_free_heap_piece(
Integer memhandle, /**< the block to deallocate a piece of */
Integer nelem /**< # of elements to deallocate */);
extern Boolean MA_get_index(
Integer memhandle, /**< block to get index for */
MA_AccessIndex *index /**< RETURN: base index */);
extern Pointer MA_get_mbase(Integer datatype); /**< to get base address of */
extern Boolean MA_get_next_memhandle(
Integer *ithandle, /**< handle for this iterator */
Integer *memhandle /**< RETURN: handle for the next block */);
extern Boolean MA_get_numalign(Integer *value);
extern Boolean MA_get_pointer(
Integer memhandle, /**< block to get pointer for */
void *pointer /**< JN: void** = void* */ );
extern Boolean MA_init(
Integer datatype, /**< for computing storage requirement */
Integer nominal_stack, /**< # of datatype elements desired for stack */
Integer nominal_heap /**< # of datatype elements desired for heap */);
extern Boolean MA_initialized();
extern Boolean MA_init_memhandle_iterator( Integer *ithandle);
extern Integer MA_inquire_avail(Integer datatype);
extern Integer MA_inquire_heap(Integer datatype);
extern Integer MA_inquire_heap_check_stack(Integer datatype);
extern Integer MA_inquire_heap_no_partition(Integer datatype);
extern Integer MA_inquire_stack(Integer datatype);
extern Integer MA_inquire_stack_check_heap(Integer datatype);
extern Integer MA_inquire_stack_no_partition(Integer datatype);
extern Boolean MA_pop_stack(Integer memhandle);
extern void MA_print_stats(Boolean printroutines);
extern Boolean MA_push_get(
Integer datatype, /**< of elements in this block */
Integer nelem, /**< # of elements in this block */
const char *name, /**< assigned to this block by client */
Integer *memhandle, /**< RETURN: handle for this block */
MA_AccessIndex *index /**< RETURN: index for this block */);
extern Boolean MA_push_stack(
Integer datatype, /**< of elements in this block */
Integer nelem, /**< # of elements in this block */
const char *name, /**< assigned to this block by client */
Integer *memhandle /**< RETURN: handle for this block */);
extern Boolean MA_set_auto_verify(Boolean value /* to set flag to */);
extern Boolean MA_set_error_print(Boolean value /* to set flag to */);
extern Boolean MA_set_hard_fail( Boolean value /* to set flag to */);
extern Boolean MA_set_numalign(Integer value);
extern Integer MA_sizeof(
Integer datatype1, /**< of source elements */
Integer nelem1, /**< # of source elements */
Integer datatype2 /**< of target elements */);
extern Integer MA_sizeof_overhead(Integer datatype);
extern void MA_summarize_allocated_blocks();
extern void MA_trace(Boolean value);
extern Boolean MA_verify_allocator_stuff();
extern void MA_set_error_callback(void(*func)());
extern void ma_set_error_callback();
/**
** variables
**/
/* base arrays for the C datatypes */
extern char ma_cb_char[]; /**< MT_C_CHAR */
extern int ma_cb_int[]; /**< MT_C_INT */
extern long ma_cb_long[]; /**< MT_C_LONGINT */
extern long long ma_cb_longlong[]; /**< MT_C_LONGLONG */
extern float ma_cb_float[]; /**< MT_C_FLOAT */
extern double ma_cb_dbl[]; /**< MT_C_DBL */
extern MA_LongDouble ma_cb_ldbl[]; /**< MT_C_LDBL */
extern MA_SingleComplex ma_cb_scpl[]; /**< MT_C_SCPL */
extern MA_DoubleComplex ma_cb_dcpl[]; /**< MT_C_DCPL */
extern MA_LongDoubleComplex ma_cb_ldcpl[]; /**< MT_C_LDCPL */
#ifdef __cplusplus
}
#endif
#endif /* _macdecls_h */
|