[cfe-commits] [PATCH] -fcatch-undefined-behavior: catch misalignment, bad reference bindings, bad 'this' pointers in member calls
Richard Smith
reviews at llvm-reviews.chandlerc.com
Thu Aug 23 10:56:31 PDT 2012
This patch teaches -fcatch-undefined-behavior to catch cases where a reference is bound to a glvalue which doesn't point to storage of the right size and alignment, and likewise for 'this' pointers. It also adds the alignment check to the existing checks for loads and stores.
Clang and LLVM's tests are now clean under these new checks, except for TypeLoc alignment.
http://llvm-reviews.chandlerc.com/D24
Files:
test/CodeGenCXX/catch-undef-behavior.cpp
test/CodeGen/catch-undef-behavior.c
lib/CodeGen/CGExprScalar.cpp
lib/CodeGen/CGExpr.cpp
lib/CodeGen/CGExprAgg.cpp
lib/CodeGen/CGExprCXX.cpp
lib/CodeGen/CodeGenFunction.h
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D24.1.patch
Type: text/x-patch
Size: 14009 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20120823/bc4caa18/attachment.bin>
More information about the cfe-commits
mailing list