Current state of "D as a better C" (Windows)?
Paulo Pinto
pjmlp at progtools.org
Sat Jan 25 23:00:36 PST 2014
Am 26.01.2014 03:03, schrieb Frank Bauer:
> On Saturday, 25 January 2014 at 23:02:44 UTC, anonymous wrote:
>> C doesn't have new/delete.
>
> Please read-before-write (non atomic operation): C has the *semantics*
> of new / delete with malloc and free. D has too, if you constrain
> yourself to memory allocation via std.c.stdlib.malloc and free, which
> means no object allocation with *new* anymore. We don't want to
> constrain ourselves to that, do we? What we want is malloc/free
> *semantics* throughout if we choose so.
Whose semantics are those?
Are you aware, that standard malloc/free vary a lot from compiler to
compiler?
Even generating cascading allocations or deallocations, as they tend to
use more low level APIs on from the operating system?
Anyone doing high performance computing or games with C ends up creating
their own allocators anyway.
So I wonder what is this magic performance semantics from malloc/free.
--
Paulo
More information about the Digitalmars-d
mailing list