aboutsummaryrefslogtreecommitdiff
path: root/gcc/tsan.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/tsan.c')
-rw-r--r--gcc/tsan.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/gcc/tsan.c b/gcc/tsan.c
index cc19474..317bf6d 100644
--- a/gcc/tsan.c
+++ b/gcc/tsan.c
@@ -128,9 +128,7 @@ instrument_expr (gimple_stmt_iterator gsi, tree expr, bool is_write)
return false;
}
- if (TREE_READONLY (base)
- || (TREE_CODE (base) == VAR_DECL
- && DECL_HARD_REGISTER (base)))
+ if (TREE_READONLY (base) || (VAR_P (base) && DECL_HARD_REGISTER (base)))
return false;
stmt = gsi_stmt (gsi);