More PC Precision Stuff

2009-10-29 Thread dsimcha
I've gotten underway hacking the GC to add precise heap scanning, but I thought of one really annoying corner case that really would make things an order of magnitude more complicated if it were handled properly: Structs and classes that have large static arrays embedded. For example: class Foo

Re: More PC Precision Stuff

2009-10-29 Thread bearophile
dsimcha: Since this is such a rare case in practice, I don't think this is a so uncommon case, I use something similar for my memory pools. But if handling this makes your code too much complex, then it may be acceptable to ignore it anyway. Two persons have shown the need for D benchmarks

Re: More PC Precision Stuff

2009-10-29 Thread dsimcha
== Quote from bearophile (bearophileh...@lycos.com)'s article dsimcha: Since this is such a rare case in practice, I don't think this is a so uncommon case, I use something similar for my memory pools. Why not dynamic arrays? Wouldn't it make more sense to do: class MemoryPool { //

Re: More PC Precision Stuff

2009-10-29 Thread Michel Fortin
On 2009-10-29 09:42:58 -0400, dsimcha dsim...@yahoo.com said: I've gotten underway hacking the GC to add precise heap scanning, but I thought of one really annoying corner case that really would make things an order of magnitude more complicated if it were handled properly: Structs and classes

Re: More PC Precision Stuff

2009-10-29 Thread Lutger
dsimcha wrote: I've gotten underway hacking the GC to add precise heap scanning, but I thought of one really annoying corner case that really would make things an order of magnitude more complicated if it were handled properly: Structs and classes that have large static arrays embedded.

Re: More PC Precision Stuff

2009-10-29 Thread Denis Koroskin
On Thu, 29 Oct 2009 22:32:54 +0300, Lutger lutger.blijdest...@gmail.com wrote: dsimcha wrote: I've gotten underway hacking the GC to add precise heap scanning, but I thought of one really annoying corner case that really would make things an order of magnitude more complicated if it were

Re: More PC Precision Stuff

2009-10-29 Thread dsimcha
== Quote from Lutger (lutger.blijdest...@gmail.com)'s article dsimcha wrote: I've gotten underway hacking the GC to add precise heap scanning, but I thought of one really annoying corner case that really would make things an order of magnitude more complicated if it were handled properly:

Re: More PC Precision Stuff

2009-10-29 Thread bearophile
dsimcha: I personally find that I almost never use static arrays, either on the stack or inside heap-allocated objects because the fact that their size is fixed at compile time is just too restrictive. About my only use for them is to store compile-time constants in the static data