summaryrefslogtreecommitdiff
path: root/include/gc/gc_typed.h
diff options
context:
space:
mode:
authorIvan Maidanski <ivmai@mail.ru>2023-04-26 08:31:36 +0300
committerIvan Maidanski <ivmai@mail.ru>2023-04-26 17:31:05 +0300
commit3e93d05a20d0da777765078836c69cc60472187d (patch)
tree664b505dddb55d778dc2046804172a0a8cb6e3c8 /include/gc/gc_typed.h
parent223ce4fdf375a59dc963dc57dd900cb7f37bc8d0 (diff)
downloadbdwgc-3e93d05a20d0da777765078836c69cc60472187d.tar.gz
Decouple descriptor compute from object alloc in calloc_explicitly_typed
(refactoring) This is a preparation for providing ability to the client to compute (and allocate) the internal descriptor of GC_calloc_explicitly_typed once (for the given object layout and elements count) and perform the typed allocation multiple times. * typd_mlc.c (GC_calloc_typed_descr_s): New struct type. * typd_mlc.c (GC_calloc_prepare_explicitly_typed, GC_calloc_do_explicitly_typed): New static function (move part of code from GC_calloc_explicitly_typed); use GC_calloc_typed_descr_s to pass leaf, simple_d, complex_d, alloc_lb, descr_type values between two functions; set and use alloc_lb instead of updating lb local variable. * typd_mlc.c (GC_calloc_explicitly_typed): Use GC_calloc_prepare_explicitly_typed and GC_calloc_do_explicitly_typed. * typd_mlc.c (GC_array_mark_proc): Update comment.
Diffstat (limited to 'include/gc/gc_typed.h')
0 files changed, 0 insertions, 0 deletions