Re: BUG #5592: list of integer undefined behaviors - Mailing list pgsql-bugs

From Tom Lane
Subject Re: BUG #5592: list of integer undefined behaviors
Date
Msg-id 1840.1280873302@sss.pgh.pa.us
Whole thread Raw
In response to BUG #5592: list of integer undefined behaviors  ("John Regehr" <regehr@cs.utah.edu>)
Responses Re: BUG #5592: list of integer undefined behaviors
List pgsql-bugs
John Regehr <regehr@cs.utah.edu> writes:
> Tom, would you be willing to isolate these operations into functions
> that could be marked with a "no_overflow_check" attribute?  This would
> be easy for us to deal with, would survive preprocesing cleanly, and
> wouldn't have any performance cost since inliners do a fine job.

Uh, *some* inliners do a fine job.  I'm not really willing to depend on
that for performance.

However, most of the cases that seem of interest so far are in fairly
small, stable functions.  Would it be reasonable to attach a "checked
for overflow problems" label to these functions as a whole?

            regards, tom lane

pgsql-bugs by date:

Previous
From: Tom Lane
Date:
Subject: Re: BUG #5592: list of integer undefined behaviors
Next
From: John Regehr
Date:
Subject: Re: BUG #5592: list of integer undefined behaviors