Hi,
In order to allocate a struct
type, two DRuntime hooks are used: _d_newitemT
for uninitialised structs and _d_newitemiT
for initialised ones. Both hooks call _d_newitemU
, which allocates memory for the struct and writes the struct’s TypeInfo
at the end of the allocated chunk.
We now attempt to convert these hooks to templates, with the goal of not using TypeInfo
at all. However, the fact that the ABI of a struct contains its TypeInfo
prevents us from achieving this goal. Is this TypeInfo
object still necessary for anything, or are we free to remove it from the ABI altogether so that we have cleaner implementations for _d_newitem{U,iT,T}
?
Thanks,
Teodor