1erts_alloc(3)                 C Library Functions                erts_alloc(3)
2
3
4

NAME

6       erts_alloc  -  An  Erlang  runtime system internal memory allocator li‐
7       brary.
8
9

DESCRIPTION

11       erts_alloc is an Erlang runtime system internal  memory  allocator  li‐
12       brary.  erts_alloc  provides the Erlang runtime system with a number of
13       memory allocators.
14

ALLOCATORS

16       The following allocators are present:
17
18         temp_alloc:
19           Allocator used for temporary allocations.
20
21         eheap_alloc:
22           Allocator used for Erlang heap data, such as Erlang process heaps.
23
24         binary_alloc:
25           Allocator used for Erlang binary data.
26
27         ets_alloc:
28           Allocator used for ets data.
29
30         driver_alloc:
31           Allocator used for driver data.
32
33         literal_alloc:
34           Allocator used for constant terms in Erlang code.
35
36         sl_alloc:
37           Allocator used for memory blocks that are  expected  to  be  short-
38           lived.
39
40         ll_alloc:
41           Allocator  used  for  memory  blocks  that are expected to be long-
42           lived, for example, Erlang code.
43
44         fix_alloc:
45           A fast allocator used for some  frequently  used  fixed  size  data
46           types.
47
48         exec_alloc:
49           Allocator used by the HiPE application for native executable code.
50
51         std_alloc:
52           Allocator  used for most memory blocks not allocated through any of
53           the other allocators described above.
54
55         sys_alloc:
56           This is normally the default malloc implementation used on the spe‐
57           cific OS.
58
59         mseg_alloc:
60           A  memory segment allocator. It is used by other allocators for al‐
61           locating memory segments and is only available on systems that have
62           the mmap system call. Memory segments that are deallocated are kept
63           for a while in a segment cache before they are destroyed. When seg‐
64           ments  are  allocated, cached segments are used if possible instead
65           of creating new segments. This to reduce the number of system calls
66           made.
67
68       sys_alloc,  literal_alloc  and temp_alloc are always enabled and cannot
69       be disabled. exec_alloc is only available if it is needed and cannot be
70       disabled.  mseg_alloc is always enabled if it is available and an allo‐
71       cator that uses it is enabled. All other allocators can be  enabled  or
72       disabled.  By  default all allocators are enabled. When an allocator is
73       disabled, sys_alloc is used instead of the disabled allocator.
74
75       The main idea with the erts_alloc library is to separate memory  blocks
76       that  are used differently into different memory areas, to achieve less
77       memory fragmentation. By putting less effort in finding a good fit  for
78       memory  blocks  that  are frequently allocated than for those less fre‐
79       quently allocated, a performance gain can be achieved.
80

THE ALLOC_UTIL FRAMEWORK

82       Internally a framework called alloc_util is used for implementing allo‐
83       cators. sys_alloc and mseg_alloc do not use this framework, so the fol‐
84       lowing does not apply to them.
85
86       An allocator manages multiple areas, called carriers, in  which  memory
87       blocks are placed. A carrier is either placed in a separate memory seg‐
88       ment (allocated through mseg_alloc), or in the heap segment  (allocated
89       through sys_alloc).
90
91         * Multiblock carriers are used for storage of several blocks.
92
93         * Singleblock carriers are used for storage of one block.
94
95         * Blocks  that  are  larger than the value of the singleblock carrier
96           threshold (sbct) parameter are placed in singleblock carriers.
97
98         * Blocks that are smaller than the value of parameter sbct are placed
99           in multiblock carriers.
100
101       Normally  an allocator creates a "main multiblock carrier". Main multi‐
102       block carriers are never deallocated. The size of the  main  multiblock
103       carrier is determined by the value of parameter mmbcs.
104
105       Sizes  of  multiblock carriers allocated through mseg_alloc are decided
106       based on the following parameters:
107
108         * The values of the largest multiblock carrier size (lmbcs)
109
110         * The smallest multiblock carrier size (smbcs)
111
112         * The multiblock carrier growth stages (mbcgs)
113
114       If nc is the current number of multiblock carriers (the main multiblock
115       carrier  excluded)  managed  by  an  allocator,  the  size  of the next
116       mseg_alloc multiblock carrier allocated by this  allocator  is  roughly
117       smbcs+nc*(lmbcs-smbcs)/mbcgs  when  nc  <=  mbcgs,  and lmbcs when nc >
118       mbcgs. If the value of parameter sbct is larger than the value  of  pa‐
119       rameter  lmbcs,  the  allocator  may have to create multiblock carriers
120       that are larger than the value of parameter lmbcs, though.  Singleblock
121       carriers allocated through mseg_alloc are sized to whole pages.
122
123       Sizes  of carriers allocated through sys_alloc are decided based on the
124       value of the sys_alloc carrier size (ycs) parameter. The size of a car‐
125       rier  is  the  least  number of multiples of the value of parameter ycs
126       satisfying the request.
127
128       Coalescing of free blocks are always  performed  immediately.  Boundary
129       tags  (headers  and  footers)  in free blocks are used, which makes the
130       time complexity for coalescing constant.
131
132       The memory allocation strategy used for multiblock carriers by an allo‐
133       cator  can  be  configured using parameter as. The following strategies
134       are available:
135
136         Best fit:
137           Strategy: Find the smallest block satisfying  the  requested  block
138           size.
139
140           Implementation:  A  balanced  binary  search tree is used. The time
141           complexity is proportional to log N, where N is the number of sizes
142           of free blocks.
143
144         Address order best fit:
145           Strategy:  Find  the  smallest block satisfying the requested block
146           size. If multiple blocks are found, choose the one with the  lowest
147           address.
148
149           Implementation:  A  balanced  binary  search tree is used. The time
150           complexity is proportional to log N, where N is the number of  free
151           blocks.
152
153         Address order first fit:
154           Strategy: Find the block with the lowest address satisfying the re‐
155           quested block size.
156
157           Implementation: A balanced binary search tree  is  used.  The  time
158           complexity  is proportional to log N, where N is the number of free
159           blocks.
160
161         Address order first fit carrier best fit:
162           Strategy: Find the carrier with the lowest address that can satisfy
163           the requested block size, then find a block within that carrier us‐
164           ing the "best fit" strategy.
165
166           Implementation: Balanced binary search trees  are  used.  The  time
167           complexity  is proportional to log N, where N is the number of free
168           blocks.
169
170         Address order first fit carrier address order best fit:
171           Strategy: Find the carrier with the lowest address that can satisfy
172           the requested block size, then find a block within that carrier us‐
173           ing the "address order best fit" strategy.
174
175           Implementation: Balanced binary search trees  are  used.  The  time
176           complexity  is proportional to log N, where N is the number of free
177           blocks.
178
179         Age order first fit carrier address order first fit:
180           Strategy: Find the oldest carrier that can  satisfy  the  requested
181           block  size,  then  find a block within that carrier using the "ad‐
182           dress order first fit" strategy.
183
184           Implementation: A balanced binary search tree  is  used.  The  time
185           complexity  is proportional to log N, where N is the number of free
186           blocks.
187
188         Age order first fit carrier best fit:
189           Strategy: Find the oldest carrier that can  satisfy  the  requested
190           block  size,  then find a block within that carrier using the "best
191           fit" strategy.
192
193           Implementation: Balanced binary search trees  are  used.  The  time
194           complexity  is proportional to log N, where N is the number of free
195           blocks.
196
197         Age order first fit carrier address order best fit:
198           Strategy: Find the oldest carrier that can  satisfy  the  requested
199           block  size,  then  find a block within that carrier using the "ad‐
200           dress order best fit" strategy.
201
202           Implementation: Balanced binary search trees  are  used.  The  time
203           complexity  is proportional to log N, where N is the number of free
204           blocks.
205
206         Good fit:
207           Strategy: Try to find the best fit, but settle  for  the  best  fit
208           found during a limited search.
209
210           Implementation:  The implementation uses segregated free lists with
211           a maximum block search depth (in each list)  to  find  a  good  fit
212           fast.  When the maximum block search depth is small (by default 3),
213           this implementation has a time complexity  that  is  constant.  The
214           maximum block search depth can be configured using parameter mbsd.
215
216         A fit:
217           Strategy:  Do  not search for a fit, inspect only one free block to
218           see if it satisfies the request. This strategy is only intended  to
219           be used for temporary allocations.
220
221           Implementation:  Inspect the first block in a free-list. If it sat‐
222           isfies the request, it is used, otherwise a new carrier is created.
223           The implementation has a time complexity that is constant.
224
225           As  from  ERTS  5.6.1  the emulator refuses to use this strategy on
226           other allocators than temp_alloc. This because it only causes prob‐
227           lems for other allocators.
228
229       Apart from the ordinary allocators described above, some pre-allocators
230       are used for some specific data types. These  pre-allocators  pre-allo‐
231       cate  a  fixed amount of memory for certain data types when the runtime
232       system starts. As long as pre-allocated  memory  is  available,  it  is
233       used. When no pre-allocated memory is available, memory is allocated in
234       ordinary allocators. These pre-allocators  are  typically  much  faster
235       than  the ordinary allocators, but can only satisfy a limited number of
236       requests.
237

SYSTEM FLAGS EFFECTING ERTS_ALLOC

239   Warning:
240       Only use these flags if you are sure what  you  are  doing.  Unsuitable
241       settings  can  cause  serious performance degradation and even a system
242       crash at any time during operation.
243
244
245       Memory allocator system flags have the following syntax: +M<S><P>  <V>,
246       where  <S> is a letter identifying a subsystem, <P> is a parameter, and
247       <V> is the value to use. The flags can be passed to the Erlang emulator
248       (erl(1)) as command-line arguments.
249
250       System  flags effecting specific allocators have an uppercase letter as
251       <S>. The following letters are used for the allocators:
252
253         * B: binary_alloc
254
255         * D: std_alloc
256
257         * E: ets_alloc
258
259         * F: fix_alloc
260
261         * H: eheap_alloc
262
263         * I: literal_alloc
264
265         * L: ll_alloc
266
267         * M: mseg_alloc
268
269         * R: driver_alloc
270
271         * S: sl_alloc
272
273         * T: temp_alloc
274
275         * X: exec_alloc
276
277         * Y: sys_alloc
278
279   Flags for Configuration of mseg_alloc
280         +MMamcbf <size>:
281           Absolute maximum cache bad fit (in kilobytes).  A  segment  in  the
282           memory  segment  cache  is  not  reused if its size exceeds the re‐
283           quested size with more than the value of this  parameter.  Defaults
284           to 4096.
285
286         +MMrmcbf <ratio>:
287           Relative  maximum cache bad fit (in percent). A segment in the mem‐
288           ory segment cache is not reused if its size exceeds  the  requested
289           size  with  more than relative maximum cache bad fit percent of the
290           requested size. Defaults to 20.
291
292         +MMsco true|false:
293           Sets super carrier only flag. Defaults to true. When a  super  car‐
294           rier  is used and this flag is true, mseg_alloc only creates carri‐
295           ers in the super carrier. Notice that the alloc_util framework  can
296           create  sys_alloc  carriers, so if you want all carriers to be cre‐
297           ated in the super carrier, you therefore want  to  disable  use  of
298           sys_alloc  carriers  by also passing +Musac false. When the flag is
299           false, mseg_alloc tries to create carriers  outside  of  the  super
300           carrier when the super carrier is full.
301
302     Note:
303         Setting  this flag to false is not supported on all systems. The flag
304         is then ignored.
305
306
307         +MMscrfsd <amount>:
308           Sets super carrier reserved free segment descriptors.  Defaults  to
309           65536.  This  parameter  determines the amount of memory to reserve
310           for free segment descriptors used by the super carrier. If the sys‐
311           tem runs out of reserved memory for free segment descriptors, other
312           memory is used. This can however cause fragmentation issues, so you
313           want  to ensure that this never happens. The maximum amount of free
314           segment descriptors used can be retrieved from the erts_mmap  tuple
315           part  of  the  result  from  calling erlang:system_info({allocator,
316           mseg_alloc}).
317
318         +MMscrpm true|false:
319           Sets super carrier reserve physical memory flag. Defaults to  true.
320           When  this  flag is true, physical memory is reserved for the whole
321           super carrier at once when it is created. The reservation is  after
322           that  left  unchanged. When this flag is set to false, only virtual
323           address space is reserved for the super carrier upon creation.  The
324           system  attempts  to reserve physical memory upon carrier creations
325           in the super carrier, and attempt to unreserve physical memory upon
326           carrier destructions in the super carrier.
327
328     Note:
329         What  reservation of physical memory means, highly depends on the op‐
330         erating system, and how it is configured. For example, different mem‐
331         ory overcommit settings on Linux drastically change the behavior.
332
333         Setting  this flag to false is possibly not supported on all systems.
334         The flag is then ignored.
335
336
337         +MMscs <size in MB>:
338           Sets super carrier size (in MB). Defaults to 0, that is, the  super
339           carrier  is  by default disabled. The super carrier is a large con‐
340           tinuous area in the virtual address space. mseg_alloc always  tries
341           to  create  new  carriers in the super carrier if it exists. Notice
342           that the alloc_util framework can create  sys_alloc  carriers.  For
343           more information, see +MMsco.
344
345         +MMmcs <amount>:
346           Maximum  cached  segments.  The  maximum  number of memory segments
347           stored in the memory segment cache. Valid range  is  [0,  30].  De‐
348           faults to 10.
349
350   Flags for Configuration of sys_alloc
351         +MYe true:
352           Enables sys_alloc.
353
354     Note:
355         sys_alloc cannot be disabled.
356
357
358         +MYm libc:
359           malloc  library  to  use.  Only libc is available. libc enables the
360           standard libc malloc implementation. By default libc is used.
361
362         +MYtt <size>:
363           Trim threshold size (in kilobytes). This is the maximum  amount  of
364           free memory at the top of the heap (allocated by sbrk) that is kept
365           by malloc (not released to the operating system). When  the  amount
366           of  free  memory at the top of the heap exceeds the trim threshold,
367           malloc releases it (by calling sbrk). Trim threshold  is  specified
368           in kilobytes. Defaults to 128.
369
370     Note:
371         This  flag has effect only when the emulator is linked with the GNU C
372         library, and uses its malloc implementation.
373
374
375         +MYtp <size>:
376           Top pad size (in kilobytes). This is the  amount  of  extra  memory
377           that  is allocated by malloc when sbrk is called to get more memory
378           from the operating system. Defaults to 0.
379
380     Note:
381         This flag has effect only when the emulator is linked with the GNU  C
382         library, and uses its malloc implementation.
383
384
385   Flags for Configuration of Allocators Based on alloc_util
386       If u is used as subsystem identifier (that is, <S> = u), all allocators
387       based on alloc_util are effected. If B, D, E, F, H, I, L, R, S, T, X is
388       used as subsystem identifier, only the specific allocator identifier is
389       effected.
390
391         +M<S>acul <utilization>|de:
392           Abandon carrier utilization limit. A valid <utilization> is an  in‐
393           teger  in  the  range [0, 100] representing utilization in percent.
394           When a utilization value > 0 is used, allocator instances  are  al‐
395           lowed  to  abandon  multiblock carriers. If de (default enabled) is
396           passed instead of a <utilization>, a recommended non-zero  utiliza‐
397           tion  value is used. The value chosen depends on the allocator type
398           and can be changed between ERTS versions. Defaults to de, but  this
399           can be changed in the future.
400
401           Carriers are abandoned when memory utilization in the allocator in‐
402           stance falls below the utilization value used. Once  a  carrier  is
403           abandoned, no new allocations are made in it. When an allocator in‐
404           stance gets an increased multiblock carrier need, it first tries to
405           fetch  an  abandoned carrier from another allocator instance. If no
406           abandoned carrier can be fetched, it creates a new  empty  carrier.
407           When  an abandoned carrier has been fetched, it will function as an
408           ordinary carrier. This feature has special requirements on the  al‐
409           location  strategy  used.  Only the strategies aoff, aoffcbf, aoff‐
410           caobf, ageffcaoffm, ageffcbf and ageffcaobf support abandoned  car‐
411           riers.
412
413           This feature also requires multiple thread specific instances to be
414           enabled. When enabling this feature, multiple  thread-specific  in‐
415           stances  are enabled if not already enabled, and the aoffcbf strat‐
416           egy is enabled if the current strategy does not  support  abandoned
417           carriers.  This  feature  can be enabled on all allocators based on
418           the alloc_util framework, except temp_alloc (which would be  point‐
419           less).
420
421         +M<S>acfml <bytes>:
422           Abandon carrier free block min limit. A valid <bytes> is a positive
423           integer representing a block size limit. The largest free block  in
424           a carrier must be at least bytes large, for the carrier to be aban‐
425           doned. The default is zero but can be changed in the future.
426
427           See also acul.
428
429         +M<S>acnl <amount>:
430           Abandon carrier number limit. A valid <amount> is a positive  inte‐
431           ger representing max number of abandoned carriers per allocator in‐
432           stance. Defaults to 1000 which will practically disable the  limit,
433           but this can be changed in the future.
434
435           See also acul.
436
437         +M<S>as     bf|aobf|aoff|aoffcbf|aoffcaobf|ageffcaoff|ageffcbf|ageff‐
438         caobf|gf|af:
439           Allocation strategy. The following strategies are valid:
440
441           * bf (best fit)
442
443           * aobf (address order best fit)
444
445           * aoff (address order first fit)
446
447           * aoffcbf (address order first fit carrier best fit)
448
449           * aoffcaobf (address order first fit  carrier  address  order  best
450             fit)
451
452           * ageffcaoff (age order first fit carrier address order first fit)
453
454           * ageffcbf (age order first fit carrier best fit)
455
456           * ageffcaobf (age order first fit carrier address order best fit)
457
458           * gf (good fit)
459
460           * af (a fit)
461
462           See  the  description  of  allocation strategies in section The al‐
463           loc_util Framework.
464
465         +M<S>asbcst <size>:
466           Absolute singleblock carrier shrink threshold (in kilobytes).  When
467           a block located in an mseg_alloc singleblock carrier is shrunk, the
468           carrier is left unchanged if the amount of unused  memory  is  less
469           than  this threshold, otherwise the carrier is shrunk. See also rs‐
470           bcst.
471
472         +M<S>atags true|false:
473           Adds a small tag to each allocated block that contains basic infor‐
474           mation  about  what  it is and who allocated it. Use the instrument
475           module to inspect this information.
476
477           The runtime overhead is one word per allocation when enabled.  This
478           may change at any time in the future.
479
480           The  default  is  true for binary_alloc and driver_alloc, and false
481           for the other allocator types.
482
483         +M<S>cg B|D|E|F|H||L|R|S|@|::
484           Set carrier pool to use for the  allocator.  Memory  carriers  will
485           only  migrate between allocator instances that use the same carrier
486           pool. The following carrier pool names exist:
487
488           B:
489             Carrier pool associated with binary_alloc.
490
491           D:
492             Carrier pool associated with std_alloc.
493
494           E:
495             Carrier pool associated with ets_alloc.
496
497           F:
498             Carrier pool associated with fix_alloc.
499
500           H:
501             Carrier pool associated with eheap_alloc.
502
503           L:
504             Carrier pool associated with ll_alloc.
505
506           R:
507             Carrier pool associated with driver_alloc.
508
509           S:
510             Carrier pool associated with sl_alloc.
511
512           @:
513             Carrier pool associated with the system as a whole.
514
515           Besides passing carrier pool name as value to  the  parameter,  you
516           can also pass :. By passing : instead of carrier pool name, the al‐
517           locator will use the carrier pool associated with itself. By  pass‐
518           ing  the  command line argument "+Mucg :", all allocators that have
519           an associated carrier pool will use  the  carrier  pool  associated
520           with themselves.
521
522           The  association  between carrier pool and allocator is very loose.
523           The associations are more or less only there to get names  for  the
524           amount  of carrier pools needed and names of carrier pools that can
525           be easily identified by the : value.
526
527           This flag is only valid for allocators that have an associated car‐
528           rier pool. Besides that, there are no restrictions on carrier pools
529           to use for an allocator.
530
531           Currently the @ carrier pool is used by default, but this will most
532           likely change.
533
534         +M<S>e true|false:
535           Enables allocator <S>.
536
537         +M<S>lmbcs <size>:
538           Largest  (mseg_alloc)  multiblock  carrier size (in kilobytes). See
539           the description on how sizes for mseg_alloc multiblock carriers are
540           decided  in section  The alloc_util Framework. On 32-bit Unix style
541           OS this limit cannot be set > 64 MB.
542
543         +M<S>mbcgs <ratio>:
544           (mseg_alloc) multiblock carrier growth stages. See the  description
545           on how sizes for mseg_alloc multiblock carriers are decided in sec‐
546           tion  The alloc_util Framework.
547
548         +M<S>mbsd <depth>:
549           Maximum block search depth. This flag has effect only if  the  good
550           fit  strategy  is  selected  for  allocator  <S>. When the good fit
551           strategy is used, free blocks are placed in segregated  free-lists.
552           Each  free-list  contains  blocks of sizes in a specific range. The
553           maxiumum block search depth sets a limit on the maximum  number  of
554           blocks to inspect in a free-list during a search for suitable block
555           satisfying the request.
556
557         +M<S>mmbcs <size>:
558           Main multiblock carrier size. Sets the size of the main  multiblock
559           carrier for allocator <S>. The main multiblock carrier is allocated
560           through sys_alloc and is never deallocated.
561
562         +M<S>mmmbc <amount>:
563           Maximum mseg_alloc multiblock carriers. Maximum  number  of  multi‐
564           block  carriers allocated through mseg_alloc by allocator <S>. When
565           this limit  is  reached,  new  multiblock  carriers  are  allocated
566           through sys_alloc.
567
568         +M<S>mmsbc <amount>:
569           Maximum  mseg_alloc singleblock carriers. Maximum number of single‐
570           block carriers allocated through mseg_alloc by allocator <S>.  When
571           this  limit  is  reached,  new  singleblock  carriers are allocated
572           through sys_alloc.
573
574         +M<S>ramv <bool>:
575           Realloc always moves. When enabled, reallocate operations are  more
576           or  less translated into an allocate, copy, free sequence. This of‐
577           ten reduces memory fragmentation, but costs performance.
578
579         +M<S>rmbcmt <ratio>:
580           Relative multiblock carrier move threshold  (in  percent).  When  a
581           block located in a multiblock carrier is shrunk, the block is moved
582           if the ratio of the size of the returned  memory  compared  to  the
583           previous  size  is more than this threshold, otherwise the block is
584           shrunk at the current location.
585
586         +M<S>rsbcmt <ratio>:
587           Relative singleblock carrier move threshold (in  percent).  When  a
588           block  located in a singleblock carrier is shrunk to a size smaller
589           than the value of parameter sbct, the block is  left  unchanged  in
590           the  singleblock carrier if the ratio of unused memory is less than
591           this threshold, otherwise it is moved into a multiblock carrier.
592
593         +M<S>rsbcst <ratio>:
594           Relative singleblock carrier shrink threshold (in percent). When  a
595           block  located  in an mseg_alloc singleblock carrier is shrunk, the
596           carrier is left unchanged if the ratio of  unused  memory  is  less
597           than  this threshold, otherwise the carrier is shrunk. See also as‐
598           bcst.
599
600         +M<S>sbct <size>:
601           Singleblock carrier threshold (in kilobytes).  Blocks  larger  than
602           this  threshold  are placed in singleblock carriers. Blocks smaller
603           than this threshold are placed in multiblock  carriers.  On  32-bit
604           Unix style OS this threshold cannot be set > 8 MB.
605
606         +M<S>smbcs <size>:
607           Smallest  (mseg_alloc)  multiblock carrier size (in kilobytes). See
608           the description on how sizes for mseg_alloc multiblock carriers are
609           decided in section  The alloc_util Framework.
610
611         +M<S>t true|false:
612           Multiple,  thread-specific  instances of the allocator. This option
613           has only effect on the runtime system with SMP support. Default be‐
614           havior on the runtime system with SMP support is NoSchedulers+1 in‐
615           stances. Each scheduler uses a lock-free instance of  its  own  and
616           other threads use a common instance.
617
618           Before  ERTS  5.9  it was possible to configure a smaller number of
619           thread-specific instances than schedulers. This  is,  however,  not
620           possible anymore.
621
622   Flags for Configuration of alloc_util
623       All allocators based on alloc_util are effected.
624
625         +Muycs <size>:
626           sys_alloc  carrier  size.  Carriers allocated through sys_alloc are
627           allocated in sizes that are  multiples  of  the  sys_alloc  carrier
628           size.  This  is  not true for main multiblock carriers and carriers
629           allocated during a memory shortage, though.
630
631         +Mummc <amount>:
632           Maximum mseg_alloc carriers. Maximum number of carriers  placed  in
633           separate  memory segments. When this limit is reached, new carriers
634           are placed in memory retrieved from sys_alloc.
635
636         +Musac <bool>:
637           Allow sys_alloc carriers.  Defaults  to  true.  If  set  to  false,
638           sys_alloc  carriers  are  never created by allocators using the al‐
639           loc_util framework.
640
641   Special Flag for literal_alloc
642         +MIscs <size in MB>:
643           literal_alloc super carrier size (in MB). The amount of virtual ad‐
644           dress space reserved for literal terms in Erlang code on 64-bit ar‐
645           chitectures. Defaults to 1024 (that is, 1  GB),  which  is  usually
646           sufficient. The flag is ignored on 32-bit architectures.
647
648   Instrumentation Flags
649         +M<S>atags:
650           Adds a small tag to each allocated block that contains basic infor‐
651           mation about what it is and who allocated it. See +M<S>atags for  a
652           more complete description.
653
654         +Mit X:
655           Reserved for future use. Do not use this flag.
656
657   Note:
658       When instrumentation of the emulator is enabled, the emulator uses more
659       memory and runs slower.
660
661
662   Other Flags
663         +Mea min|max|r9c|r10b|r11b|config:
664           Options:
665
666           min:
667             Disables all allocators that can be disabled.
668
669           max:
670             Enables all allocators (default).
671
672           r9c|r10b|r11b:
673             Configures all allocators as they were configured  in  respective
674             Erlang/OTP release. These will eventually be removed.
675
676           config:
677             Disables  features that cannot be enabled while creating an allo‐
678             cator configuration with erts_alloc_config(3).
679
680       Note:
681           This option is to be used only while running  erts_alloc_config(3),
682           not when using the created configuration.
683
684
685         +Mlpm all|no:
686           Lock  physical  memory. Defaults to no, that is, no physical memory
687           is locked. If set to all, all memory mappings made by  the  runtime
688           system  are locked into physical memory. If set to all, the runtime
689           system fails to start if this feature is not  supported,  the  user
690           has  not  got enough privileges, or the user is not allowed to lock
691           enough physical memory. The runtime system also fails with  an  out
692           of  memory condition if the user limit on the amount of locked mem‐
693           ory is reached.
694

NOTES

696       Only some default values have  been  presented  here.  For  information
697       about the currently used settings and the current status of the alloca‐
698       tors, see erlang:system_info(allocator) and erlang:system_info({alloca‐
699       tor, Alloc}).
700
701   Note:
702       Most  of  these  flags  are  highly implementation-dependent and can be
703       changed or removed without prior notice.
704
705       erts_alloc is not obliged to strictly use the settings that  have  been
706       passed to it (it can even ignore them).
707
708
709       The  erts_alloc_config(3)  tool  can  be  used  to  aid  creation of an
710       erts_alloc configuration that is suitable for a limited number of  run‐
711       time scenarios.
712

SEE ALSO

714       erl(1), erlang(3), erts_alloc_config(3), instrument(3)
715
716
717
718Ericsson AB                      erts 11.2.2.2                   erts_alloc(3)
Impressum