@@ -1,3 +1,18 @@
+2012-10-25 Wei Mi <wmi@google.com>
+
+ * varasm.c (assemble_variable): Set asan_protected even
+ for decls that are already ASAN_RED_ZONE_SIZE or more
+ bytes aligned.
+
+2012-10-19 Diego Novillo <dnovillo@google.com>
+
+ Merge from trunk rev 192612.
+
+2012-10-18 Xinliang David Li <davidxl@google.com>
+
+ * asan.c (asan_init_shadow_ptr_types): change shadow type
+ to signed type.
+
2012-10-18 Jakub Jelinek <jakub@redhat.com>
* asan.c (build_check_stmt): Unshare base.
@@ -1991,11 +1991,11 @@ assemble_variable (tree decl, int top_level ATTRIBUTE_UNUSED,
align_variable (decl, dont_output_data);
if (flag_asan
- && asan_protect_global (decl)
- && DECL_ALIGN (decl) < ASAN_RED_ZONE_SIZE * BITS_PER_UNIT)
+ && asan_protect_global (decl))
{
asan_protected = true;
- DECL_ALIGN (decl) = ASAN_RED_ZONE_SIZE * BITS_PER_UNIT;
+ DECL_ALIGN (decl) = MAX (DECL_ALIGN (decl),
+ ASAN_RED_ZONE_SIZE * BITS_PER_UNIT);
}
set_mem_align (decl_rtl, DECL_ALIGN (decl));
From: wmi <wmi@138bc75d-0d04-0410-961f-82ee72b054a4> It appeared that we were forgetting to protect global variables that are already 32 bytes aligned. Fixed thus. * varasm.c (assemble_variable): Set asan_protected even for decls that are already ASAN_RED_ZONE_SIZE or more bytes aligned. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/branches/asan@192830 138bc75d-0d04-0410-961f-82ee72b054a4 --- gcc/ChangeLog.asan | 15 +++++++++++++++ gcc/varasm.c | 6 +++--- 2 files changed, 18 insertions(+), 3 deletions(-)