in reply to Re^4: Parrot, threads & fears for the future.
in thread Parrot, threads & fears for the future.
Of course, Perl sacrifices a lot of performance to the reference counting
I've seen this claim made by the people who refused to reimplement reference counting in Parrot. But the only reference I saw from them that they claimed supported this only said something more like garbage collection really isn't too much terribly slower than reference counting, as far as they noticed.
Just because you've heard something repeated many times, doesn't mean that there necessarily is any evidence to support it.
Incrementing and decrementing are two of the fastest things computers know how to do. Adding an increment to a call to malloc() is "in the noise" performance-wise. Certainly for Perl 5, the cost of reference counting to performance is insignificant. And I won't believe that ref counting has much of a performance cost even in a highly-efficient system, until I see some real evidence. Removing an increment assembly op is certainly micro-optimization and it is extremely hard to get micro-optimizations to have much impact on the performance of real code. Your code would have to be doing a ton of taking and removing references and little other real work for the inc/dec to add up to even a non-trivial fraction of the run-time.
- tye
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^6: Parrot, threads & fears for the future. (ref counting)
by chromatic (Archbishop) on Oct 23, 2006 at 15:51 UTC | |
by tye (Sage) on Oct 23, 2006 at 16:56 UTC | |
by chromatic (Archbishop) on Oct 23, 2006 at 17:02 UTC | |
by tye (Sage) on Oct 23, 2006 at 17:30 UTC | |
by chromatic (Archbishop) on Oct 23, 2006 at 17:44 UTC | |
|
Re^6: Parrot, threads & fears for the future. (ref counting)
by adrianh (Chancellor) on Oct 23, 2006 at 17:20 UTC | |
by tye (Sage) on Oct 23, 2006 at 18:25 UTC | |
by BigAl (Scribe) on Oct 31, 2006 at 06:36 UTC |