February 24, 2003 Min. memory consumption: object vs. dynamic int-array | ||||
---|---|---|---|---|
| ||||
Hi, is it true that in D the min. memory consumption of an object is equal to a dynamic int-array (8 byte)? H.C. |
February 24, 2003 Re: Min. memory consumption: object vs. dynamic int-array | ||||
---|---|---|---|---|
| ||||
Posted in reply to Hans Castorp | Hans Castorp wrote:
> is it true that in D the min. memory consumption of an object is equal to a
> dynamic int-array (8 byte)?
There's a correlation, but they have nothing to do with one another. The minimum size of a class instance is caused by the vtable pointer and a monitor used with the synchronized statement. struct values, however, have no hidden fields.
|
Copyright © 1999-2021 by the D Language Foundation