[Bug c/59856] Support sparse-style context checking, used to validate locking correctness

pageexec at gmail dot com gcc-bugzilla@gcc.gnu.org
Mon Dec 7 00:21:00 GMT 2015


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=59856

--- Comment #20 from PaX Team <pageexec at gmail dot com> ---
(In reply to Josh Triplett from comment #13)
> Note that in addition to complaining if *any* exit to the function doesn't
> have the correct "out" value, you also need to complain if calls to
> functions with the context attribute don't have the necessary "in" value. 

i implemented this now but it generates a warning on good_lock3, good_unlock2
and good_if3 (since there're paths where the same lock is taken twice before we
reach the end of the function where we'd know that the lock count imbalance is
fine). how should these cases be handled?


More information about the Gcc-bugs mailing list