Need help to get OpenSSL 64 work on Windows x64 | I hate D's GC!
Ali Çehreli via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Sat Jul 15 21:12:31 PDT 2017
On 07/15/2017 03:05 PM, tetyys wrote:
> On Friday, 14 July 2017 at 17:24:05 UTC, Suliman wrote:
>> GC on 32-bit machine show a lot of bugs.
>
> such as..?
D's GC is conservative i.e. it cannot assume an integer is not a
pointer. There are ways around this such as marking the memory block as
not containing pointers but in general, if the language allows you to
cast a pointer to integer, it's possible that any integer may be the
only reference to a GC memory.
The problem with 32-bit is, it's very likely that an integer value may
happen to have a value that equals to an address into GC memory. This
happens when you allocate e.g. half gigabyte memory, read a file into
it. So far so good. Unfortunately, it's likely that there is some
integer in the program that points into this half a gig memory and the
GC will never release it.
Ali
More information about the Digitalmars-d-learn
mailing list