<div dir="ltr"><div dir="ltr"><br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Wed, Mar 20, 2019 at 9:22 AM Albin Stigö <<a href="mailto:albin.stigo@gmail.com">albin.stigo@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="auto">Hi,<div dir="auto"><br></div><div dir="auto">How does Nifs compare to Port drivers in OTP 21 and beyond..? It used to be that port drivers were more suited for threaded c libraries etc, but it seems to me now you can do anything with with either.</div><div dir="auto"><br></div><div dir="auto">Will port drivers be deprecated? </div></div></blockquote><div><br></div><div>No. </div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="auto"><div dir="auto"><br></div><div dir="auto">Which should I choose when starting a new hardware driver (assuming I have ruled out ports and c nodes, I'm aware of the implications)?</div></div></blockquote><div><br></div><div>I would do it in a NIF. NIFs have a larger API, work on dirty schedulers and are in most cases more performant than port drivers.</div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="auto"><div dir="auto"><br></div><div dir="auto"><br></div><div dir="auto">--Albin</div></div>_______________________________________________<br>erlang-questions mailing list<br>
<a href="mailto:erlang-questions@erlang.org" target="_blank">erlang-questions@erlang.org</a><br>
<a href="http://erlang.org/mailman/listinfo/erlang-questions" rel="noreferrer" target="_blank">http://erlang.org/mailman/listinfo/erlang-questions</a><br>
</blockquote></div></div>