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

From John Regehr
Subject Re: BUG #5592: list of integer undefined behaviors
Date
Msg-id 4C5895F1.1030304@cs.utah.edu
Whole thread Raw
In response to Re: BUG #5592: list of integer undefined behaviors  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-bugs
On 8/3/2010 4:08 PM, Tom Lane wrote:
> 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?

This should work great.  I'll get my clang hacker to start working on it.

I see that pgsql has support already in place to def out attributes when
non-GCC ocmpilers are used.

Just to be clear we're talking about putting something like this in your
header files:

int
bms_first_member(Bitmapset *a)
__attribute__((no_integer_overflow_checks));

Pick whatever name you like for this attribute, it doesn't matter to us.

John

pgsql-bugs by date:

Previous
From: John Regehr
Date:
Subject: Re: BUG #5592: list of integer undefined behaviors
Next
From: Mark Kirkwood
Date:
Subject: Re: BUG #5595: Documentation is not installs from VPATH build.