2017-03-06 Martin Liska <mliska@suse.cz>
PR sanitize/79783
* asan.c (asan_expand_poison_ifn): Do not expand ASAN_POISON
when having a SSA NAME w/o VAR_DECL assigned to it.
2017-03-06 Martin Liska <mliska@suse.cz>
PR sanitize/79783
* g++.dg/asan/pr79783.C: New test.
From-SVN: r245912
+2017-03-06 Martin Liska <mliska@suse.cz>
+
+ PR sanitize/79783
+ * asan.c (asan_expand_poison_ifn): Do not expand ASAN_POISON
+ when having a SSA NAME w/o VAR_DECL assigned to it.
+
2017-03-06 Prachi Godbole <prachi.godbole@imgtec.com>
* config/mips/mips-msa.md (msa_dotp_<su>_d, msa_dpadd_<su>_d,
{
gimple *g = gsi_stmt (*iter);
tree poisoned_var = gimple_call_lhs (g);
- if (!poisoned_var)
+ if (!poisoned_var || has_zero_uses (poisoned_var))
{
gsi_remove (iter, true);
return true;
}
+ if (SSA_NAME_VAR (poisoned_var) == NULL_TREE)
+ SET_SSA_NAME_VAR_OR_IDENTIFIER (poisoned_var,
+ create_tmp_var (TREE_TYPE (poisoned_var)));
+
tree shadow_var = create_asan_shadow_var (SSA_NAME_VAR (poisoned_var),
shadow_vars_mapping);
+2017-03-06 Martin Liska <mliska@suse.cz>
+
+ PR sanitize/79783
+ * g++.dg/asan/pr79783.C: New test.
+
2017-03-06 Prachi Godbole <prachi.godbole@imgtec.com>
* gcc.target/mips/msa-dotp.c: New tests.
--- /dev/null
+// PR sanitizer/79783
+// { dg-options "-fno-tree-dce" }
+
+struct A
+{
+ static void foo(const char&) {}
+};
+
+struct B
+{
+ B() { A::foo(char()); }
+};
+
+struct C
+{
+ virtual void bar() const { B b; }
+};
+
+C c;