[erlang-questions] Erlang and the learning curve

Morten Krogh <>
Tue Jan 4 19:35:32 CET 2011


On 1/4/11 4:37 PM, Steve Vinoski wrote:
> On Tue, Jan 4, 2011 at 6:31 AM, Morten Krogh<>  wrote:
>> Why are one fourth, or whatever, of the posts on this list about nif or c
>> nodes or ports?
> Even if we assume your percentage is accurate (which I don't), simply
> assuming these features are used only for performance reasons is a
> case of premature optimization. ;-)
>
> While some uses of these features involve performance concerns, C
> nodes, ports, drivers, and NIFs all serve as points for integrating
> Erlang with other environments. NIFs have already proven themselves
> particularly useful in this regard. Because of the continued growth in
> the popularity and application of Erlang, the number of developers
> interested in using these features to integrate with non-Erlang code
> is also growing.
>
> These are areas of Erlang involving languages other than Erlang, such
> as C, so it could be they're harder to understand than other parts of
> the language. It also could be that even with the aforementioned
> growing popularity of the language, the number of Erlang developers
> who've ever written C nodes and drivers used in production remains
> relatively small, and so finding good sources of detailed information
> about how best to write them is challenging.
>
> But still, I'd argue there really aren't that many questions posted
> here about these features.
>
> --steve

My percentage is probably wrong. I didn't count. I just wanted to stress 
that I see quite a lot of performance optimization in Erlang.
Why were NIFs introduced at all? Why new BIFs all the time? All of that 
could be done in Erlang.

Steve, I have never seen a NIF that was not performance motivated.
But you have seen many more NIFs than me.
Do you have any examples?

  Morten.


More information about the erlang-questions mailing list