summaryrefslogtreecommitdiffstats
path: root/clang/test/Analysis/fields.c
diff options
context:
space:
mode:
authorTed Kremenek <kremenek@apple.com>2009-05-01 19:22:20 +0000
committerTed Kremenek <kremenek@apple.com>2009-05-01 19:22:20 +0000
commit9c21f1d174946300ae6008946f26f468c7488a6a (patch)
tree547a97a70bd76df93acf3a4c18cbe933bc89343e /clang/test/Analysis/fields.c
parenta11c60731265f29009f7cc30c6bfd4c40339b892 (diff)
downloadbcm5719-llvm-9c21f1d174946300ae6008946f26f468c7488a6a.tar.gz
bcm5719-llvm-9c21f1d174946300ae6008946f26f468c7488a6a.zip
StoreManager::CastRegion:
- Don't layer TypedViewRegions on top of any region except SymbolicRegions and AllocaRegions. This follows from my offline discussion within Zhongxing about how TypedViewRegions really only represent memory getting re-appropriated for a new purpose. Fallout from this change: - Move test case from xfail_rdar_6440393.m to misc-ps-64.m (it now passes). - test/Analysis/fields.c now fails for region store (crash). Marking XFAIL. - test/Analysis/rdar-6441136-region.c now fails (only runs with region store). Marking XFAIL. Diagnosis: The analyzer now correctly identifies an early out-of-bounds memory access then the one flagged: rdar-6541136-region.c:17:3: warning: Load or store into an out-of-bound memory position. *p = 1; ^~ Changing the line: char *p = (void*) &wonky[1]; to char *p = (void*) &wonky[0]; (which should delay the buffer overrun) causes region store to crash, probably because it expects a TypedViewRegion. - test/Analysis/casts.c (region store) now fails (crash). Marking XFAIL. llvm-svn: 70565
Diffstat (limited to 'clang/test/Analysis/fields.c')
-rw-r--r--clang/test/Analysis/fields.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/clang/test/Analysis/fields.c b/clang/test/Analysis/fields.c
index d6bf73f9af1..8b88578a0e9 100644
--- a/clang/test/Analysis/fields.c
+++ b/clang/test/Analysis/fields.c
@@ -1,6 +1,6 @@
// RUN: clang-cc -analyze -checker-cfref %s --analyzer-store=basic -verify &&
-// RUN: clang-cc -analyze -checker-cfref %s --analyzer-store=region -verify &&
-// RUN: clang-cc -analyze -checker-simple %s -verify
+// RUN: clang-cc -analyze -checker-cfref %s --analyzer-store=region -verify
+// XFAIL
unsigned foo();
typedef struct bf { unsigned x:2; } bf;
OpenPOWER on IntegriCloud