[Bug c++/104388] Request: A builtin to mark an object as invalid

2022-02-06 Thread rguenth at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104388

Richard Biener  changed:

   What|Removed |Added

 Ever confirmed|0   |1
 Status|UNCONFIRMED |WAITING
   Last reconfirmed||2022-02-07

--- Comment #1 from Richard Biener  ---
GCC internally places "clobbers" to mark object contents as invalid (as you
name it) and then can diagnose uses (but as "uninitialized") and can do
optimizations like remove dead stores into the now invalid object.

Those could be exposed as builtin.

Can you provide an example testcase how you'd use the builtin?

[Bug c++/104388] Request: A builtin to mark an object as invalid

2022-02-04 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104388

Andrew Pinski  changed:

   What|Removed |Added

   Severity|normal  |enhancement