Performance gain by avoiding arguments check is very small (less then 1%).

Joseph Myers josmyers@redhat.com
Mon Sep 29 19:37:20 GMT 2025


On Mon, 29 Sep 2025, Amit wrote:

> """"It is so less that it is better to validate the arguments to avoid
> crashes, etc.""""

Actually, reliably crashing a program on a bug (such as passing a null 
pointer to a function whose interface specifies that's not valid) can be 
much safer than continuing execution after undefined behavior.

-- 
Joseph S. Myers
josmyers@redhat.com



More information about the Libc-alpha mailing list