~rdoering/ubuntu/karmic/erlang/fix-535090

« back to all changes in this revision

Viewing changes to erts/emulator/beam/erl_alloc_util.h

  • Committer: Bazaar Package Importer
  • Author(s): Sergei Golovan
  • Date: 2009-02-15 16:42:52 UTC
  • mfrom: (3.1.2 squeeze)
  • Revision ID: james.westby@ubuntu.com-20090215164252-q5x4rcf8a5pbesb1
Tags: 1:12.b.5-dfsg-2
Upload to unstable after lenny is released.

Show diffs side-by-side

added added

removed removed

Lines of Context:
41
41
    Uint asbcst;
42
42
    Uint rsbcst;
43
43
    Uint rsbcmt;
 
44
    Uint rmbcmt;
44
45
    Uint mmbcs;
45
46
    Uint mmsbc;
46
47
    Uint mmmbc;
49
50
    Uint mbcgs;
50
51
} AllctrInit_t;
51
52
 
 
53
typedef struct {
 
54
    Uint blocks;
 
55
    Uint carriers;
 
56
} AllctrSize_t;
 
57
 
52
58
#ifndef SMALL_MEMORY
53
59
 
54
60
#define ERTS_DEFAULT_ALCU_INIT {                                           \
67
73
    2*1024*2024,        /* (amount) asbcst: abs sbc shrink threshold     */\
68
74
    20,                 /* (%)      rsbcst: rel sbc shrink threshold     */\
69
75
    80,                 /* (%)      rsbcmt: rel sbc move threshold       */\
 
76
    50,                 /* (%)      rmbcmt: rel mbc move threshold       */\
70
77
    1024*1024,          /* (bytes)  mmbcs:  main multiblock carrier size */\
71
78
    256,                /* (amount) mmsbc:  max mseg sbcs                */\
72
79
    10,                 /* (amount) mmmbc:  max mseg mbcs                */\
126
133
Eterm   erts_alcu_sz_info(Allctr_t *, int, int *, void *, Uint **, Uint *);
127
134
Eterm   erts_alcu_info(Allctr_t *, int, int *, void *, Uint **, Uint *);
128
135
void    erts_alcu_init(AlcUInit_t *);
 
136
void    erts_alcu_current_size(Allctr_t *, AllctrSize_t *);
129
137
 
130
138
#endif
131
139
 
238
246
    int                 ramv;
239
247
    Uint                sbc_threshold;
240
248
    Uint                sbc_move_threshold;
 
249
    Uint                mbc_move_threshold;
241
250
    Uint                main_carrier_size;
242
251
    Uint                max_mseg_sbcs;
243
252
    Uint                max_mseg_mbcs;
263
272
    Carrier_t *         main_carrier;
264
273
 
265
274
    /* Callback functions (first 4 are mandatory) */
266
 
    Block_t *           (*get_free_block)       (Allctr_t *, Uint);
 
275
    Block_t *           (*get_free_block)       (Allctr_t *, Uint,
 
276
                                                 Block_t *, Uint);
267
277
    void                (*link_free_block)      (Allctr_t *, Block_t *);
268
278
    void                (*unlink_free_block)    (Allctr_t *, Block_t *);
269
279
    Eterm               (*info_options)         (Allctr_t *, char *, int *,