Fix UBSan static initializer sanitization
PR sanitizer/66190
* cp-gimplify.c (struct cp_genericize_data): Add no_sanitize_p.
(cp_genericize_r): Don't instrument static initializers.
(cp_genericize_tree): Initialize wtd.no_sanitize_p.
* g++.dg/ubsan/static-init-1.C: New test.
* g++.dg/ubsan/static-init-2.C: New test.
* g++.dg/ubsan/static-init-3.C: New test.
upstream hash:
d120fa25444c859c1c1d8104a72820bf6d0851c7
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@224096
138bc75d-0d04-0410-961f-
82ee72b054a4
Authored-by: mpolacek
Change-Id: I9306d036380140291faa2000fd08d9cf60120ee6
Signed-off-by: Slava Barinov <v.barinov@samsung.com>