2017-10-11 Martin Liska <mliska@suse.cz>
PR sanitizer/82484
* sanopt.c (sanitize_rewrite_addressable_params): Do not handle
volatile arguments.
2017-10-11 Martin Liska <mliska@suse.cz>
PR sanitizer/82484
* gcc.dg/asan/pr82484.c: New test.
From-SVN: r253637
+2017-10-11 Martin Liska <mliska@suse.cz>
+
+ PR sanitizer/82484
+ * sanopt.c (sanitize_rewrite_addressable_params): Do not handle
+ volatile arguments.
+
2017-10-11 Adhemerval Zanella <adhemerval.zanella@linaro.org>
* config.gcc (default_gnu_indirect_function): Default to yes for
arg; arg = DECL_CHAIN (arg))
{
tree type = TREE_TYPE (arg);
- if (TREE_ADDRESSABLE (arg) && !TREE_ADDRESSABLE (type)
+ if (TREE_ADDRESSABLE (arg)
+ && !TREE_ADDRESSABLE (type)
+ && !TREE_THIS_VOLATILE (arg)
&& TREE_CODE (TYPE_SIZE (type)) == INTEGER_CST)
{
TREE_ADDRESSABLE (arg) = 0;
+2017-10-11 Martin Liska <mliska@suse.cz>
+
+ PR sanitizer/82484
+ * gcc.dg/asan/pr82484.c: New test.
+
2017-10-11 Martin Liska <mliska@suse.cz>
* c-c++-common/ubsan/ptr-overflow-sanitization-1.c: Scan
--- /dev/null
+/* PR sanitizer/82484 */
+/* { dg-do compile } */
+
+void foo(volatile int *ptr);
+void a (volatile int b) { foo(&b); }