OSDN Git Service

Subzero: small cleanups
authorThomas Lively <tlively@google.com>
Thu, 21 Jul 2016 21:13:03 +0000 (14:13 -0700)
committerThomas Lively <tlively@google.com>
Thu, 21 Jul 2016 21:13:03 +0000 (14:13 -0700)
BUG=https://bugs.chromium.org/p/nativeclient/issues/detail?id=4374
R=kschimpf@google.com

Review URL: https://codereview.chromium.org/2165393002 .

runtime/szrt_asan.c
tests_lit/asan_tests/errors.ll
tests_lit/asan_tests/realloc_shrink.ll
tests_lit/asan_tests/wideloads.ll

index 25ce60e..dc43096 100644 (file)
@@ -196,7 +196,7 @@ void *__asan_realloc(char *ptr, size_t size) {
 
 void __asan_free(char *ptr) {
   DUMP("free() called on %p\n", ptr);
-  void *rz_left, *rz_right;
+  char *rz_left, *rz_right;
   __asan_get_redzones(ptr, &rz_left, &rz_right);
   size_t rz_right_size = *(size_t *)rz_right;
   __asan_unpoison(rz_left, RZ_SIZE);
index 05ec493..e00ed40 100644 (file)
@@ -4,32 +4,32 @@
 
 ; check with a one off the end local access
 ; RUN: llvm-as %s -o - | pnacl-freeze > %t.pexe && %S/../../pydir/szbuild.py \
-; RUN:     --fsanitize-address --sz="-allow-externally-defined-symbols" \
+; RUN:     --fsanitize-address --sz=-allow-externally-defined-symbols \
 ; RUN:     %t.pexe -o %t && %t 2>&1 | FileCheck %s
 
 ; check with a many off the end local access
 ; RUN: llvm-as %s -o - | pnacl-freeze > %t.pexe && %S/../../pydir/szbuild.py \
-; RUN:     --fsanitize-address --sz="-allow-externally-defined-symbols" \
+; RUN:     --fsanitize-address --sz=-allow-externally-defined-symbols \
 ; RUN:     %t.pexe -o %t && %t 1 2>&1 | FileCheck %s
 
 ; check with a one before the front local access
 ; RUN: llvm-as %s -o - | pnacl-freeze > %t.pexe && %S/../../pydir/szbuild.py \
-; RUN:     --fsanitize-address --sz="-allow-externally-defined-symbols" \
+; RUN:     --fsanitize-address --sz=-allow-externally-defined-symbols \
 ; RUN:     %t.pexe -o %t && %t 1 2 2>&1 | FileCheck %s
 
 ; check with a one off the end global access
 ; RUN: llvm-as %s -o - | pnacl-freeze > %t.pexe && %S/../../pydir/szbuild.py \
-; RUN:     --fsanitize-address --sz="-allow-externally-defined-symbols" \
+; RUN:     --fsanitize-address --sz=-allow-externally-defined-symbols \
 ; RUN:     %t.pexe -o %t && %t 1 2 3 2>&1 | FileCheck %s
 
 ; check with a many off the end global access
 ; RUN: llvm-as %s -o - | pnacl-freeze > %t.pexe && %S/../../pydir/szbuild.py \
-; RUN:     --fsanitize-address --sz="-allow-externally-defined-symbols" \
+; RUN:     --fsanitize-address --sz=-allow-externally-defined-symbols \
 ; RUN:     %t.pexe -o %t && %t 1 2 3 4 2>&1 | FileCheck %s
 
 ; check with a one before the front global access
 ; RUN: llvm-as %s -o - | pnacl-freeze > %t.pexe && %S/../../pydir/szbuild.py \
-; RUN:     --fsanitize-address --sz="-allow-externally-defined-symbols" \
+; RUN:     --fsanitize-address --sz=-allow-externally-defined-symbols \
 ; RUN:     %t.pexe -o %t && %t 1 2 3 4 5 2>&1 | FileCheck %s
 
 
index 599a6cf..c76ace1 100644 (file)
@@ -3,7 +3,7 @@
 ; REQUIRES: no_minimal_build
 
 ; RUN: llvm-as %s -o - | pnacl-freeze > %t.pexe && %S/../../pydir/szbuild.py \
-; RUN:     --fsanitize-address --sz="-allow-externally-defined-symbols" \
+; RUN:     --fsanitize-address --sz=-allow-externally-defined-symbols \
 ; RUN:     %t.pexe -o %t && %t 2>&1 | FileCheck %s
 
 
index 50a9975..fae1280 100644 (file)
@@ -4,12 +4,12 @@
 
 ; check for wide load exception
 ; RUN: llvm-as %s -o - | pnacl-freeze > %t.pexe && %S/../../pydir/szbuild.py \
-; RUN:     --fsanitize-address --sz="-allow-externally-defined-symbols" \
+; RUN:     --fsanitize-address --sz=-allow-externally-defined-symbols \
 ; RUN:     %t.pexe -o %t && %t | FileCheck %s --check-prefix=WIDE --allow-empty
 
 ; check for error reporting
 ; RUN: llvm-as %s -o - | pnacl-freeze > %t.pexe && %S/../../pydir/szbuild.py \
-; RUN:     --fsanitize-address --sz="-allow-externally-defined-symbols" \
+; RUN:     --fsanitize-address --sz=-allow-externally-defined-symbols \
 ; RUN:     %t.pexe -o %t && %t 1 2>&1 | FileCheck %s --check-prefix=NOWIDE