vsk marked an inline comment as done.
vsk added a comment.
I made the suggested test changes and updated the release notes: r309007
Repository:
rL LLVM
https://reviews.llvm.org/D35735
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http:/
This revision was automatically updated to reflect the committed changes.
Closed by commit rL309007: [ubsan] Null-check pointers in -fsanitize=vptr
(PR33881) (authored by vedantk).
Changed prior to commit:
https://reviews.llvm.org/D35735?vs=107741&id=108133#toc
Repository:
rL LLVM
https://r
arphaman added a comment.
You might also want to mention the fact that `-fsanitizer=vptr` requires `null`
in the release notes.
https://reviews.llvm.org/D35735
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/ma
arphaman accepted this revision.
arphaman added a comment.
This revision is now accepted and ready to land.
LGTM!
Comment at: test/CodeGenCXX/ubsan-devirtualized-calls.cpp:67
static_cast(badp)->f1(); //< No devirt, test 'badp isa Base1'.
+ // We were able to skip the null c
vsk updated this revision to Diff 107741.
vsk marked an inline comment as done.
vsk added a comment.
- Drop 'REQUIRES: asserts'.
https://reviews.llvm.org/D35735
Files:
docs/UndefinedBehaviorSanitizer.rst
include/clang/Basic/DiagnosticDriverKinds.td
include/clang/Basic/DiagnosticGroups.td
aprantl added inline comments.
Comment at: test/CodeGenCXX/ubsan-devirtualized-calls.cpp:1
-// RUN: %clang_cc1 -std=c++11 -triple %itanium_abi_triple -emit-llvm
-fsanitize=vptr %s -o - | FileCheck %s
+// REQUIRES: asserts
+// RUN: %clang_cc1 -std=c++11 -triple %itanium_abi_tripl
vsk created this revision.
The instrumentation generated by -fsanitize=vptr does not null check a
user pointer before loading from it. This causes crashes in the face of
UB member calls (this=nullptr), i.e it causes user programs to crash only
after UBSan is turned on.
The fix is to make run-time