The "no gc" crowd

Walter Bright newshound2 at digitalmars.com
Tue Oct 8 16:05:36 PDT 2013


On 10/8/2013 12:34 PM, Jonathan M Davis wrote:
> I think that it's clear that for some projects, it's critical to minimize the
> GC, and I think that it's clear that we need to do a better job of supporting
> the folks who want to minimize GC usage, but I also think that for the vast
> majority of cases, complaints about the GC are way overblown. It becomes an
> issue when you're doing a lot of heap allocations, but it's frequently easy to
> design D code so that heap allocations are relatively rare such that they
> aren't going to be a serious problem outside of code which is performance
> critical to the point that it would be worrying about the cost of malloc
> (which most code isn't). Personally, the only time that I've run into issues
> with the GC is when trying to do use RedBlackTree with a lot of items. That
> has a tendancy to tank performance.
>
> So, yes, it's problem. Yes, we need to improve the situaton. But for most
> situations, I think that the concern about the GC is way overblown.

+1

Some years ago, a colleague of mine moonlighted teaching remedial algebra at the 
UW. She'd write on the board:

    x + 2 = 5

and call on a student to "solve for x". The student would collapse in a 
stuttering heap of jelly, emitting sparks and smoke like a Star Trek computer. 
She discovered that if she wrote instead:

    _ + 2 = 5

and would ask the same student what goes in the blank spot, he'd say "3" without 
hesitation.

In other words, the student would only see the words "solve", "x", and "algebra" 
which were a shortcut in his brain to "I can't do this" and "gee math is hard." 
She found she was a far more effective teacher by avoiding using those words.

I realized the same thing was happening with the word "template". I talked 
Andrei into avoiding all use of that word in "The D Programming Language", 
figuring that we could get people who were terrified of "templates" to use them 
successfully without realizing it (and I think this was very successful).

We have a similar problem with "GC". People hear that word, and they are 
instantly turned off. No amount of education will change that. We simply have to 
find a better way to deal with this issue.


More information about the Digitalmars-d mailing list