]> granicus.if.org Git - clang/commitdiff
[Sanitizers] Remove duplication in sanitizer group definition. NFC.
authorAlexey Samsonov <vonosmas@gmail.com>
Tue, 3 Mar 2015 00:14:32 +0000 (00:14 +0000)
committerAlexey Samsonov <vonosmas@gmail.com>
Tue, 3 Mar 2015 00:14:32 +0000 (00:14 +0000)
There is no need to list sanitizers in both "UndefinedTrap" and
"Undefined" groups - it turns out using one group in a defintion
of another group "just works".

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@231040 91177308-0d34-0410-b5e6-96231b3b80d8

include/clang/Basic/Sanitizers.def

index a0acce967f403f8fdc2dfda600d09e14d96f2420..54058edfdc212cf3bdb3c88db219b06fa370710f 100644 (file)
@@ -80,18 +80,8 @@ SANITIZER("dataflow", DataFlow)
 SANITIZER("cfi-vptr", CFIVptr)
 SANITIZER_GROUP("cfi", CFI, CFIVptr)
 
-// -fsanitize=undefined includes all the sanitizers which have low overhead, no
-// ABI or address space layout implications, and only catch undefined behavior.
-SANITIZER_GROUP("undefined", Undefined,
-                Alignment | Bool | ArrayBounds | Enum | FloatCastOverflow |
-                    FloatDivideByZero | Function | IntegerDivideByZero |
-                    NonnullAttribute | Null | ObjectSize | Return |
-                    ReturnsNonnullAttribute | Shift | SignedIntegerOverflow |
-                    Unreachable | VLABound | Vptr)
-
-// -fsanitize=undefined-trap includes
-// all sanitizers included by -fsanitize=undefined, except those that require
-// runtime support.  This group is generally used in conjunction with the
+// -fsanitize=undefined-trap includes sanitizers from -fsanitize=undefined
+// that can be used without runtime support, generally by providing extra
 // -fsanitize-undefined-trap-on-error flag.
 SANITIZER_GROUP("undefined-trap", UndefinedTrap,
                 Alignment | Bool | ArrayBounds | Enum | FloatCastOverflow |
@@ -99,6 +89,10 @@ SANITIZER_GROUP("undefined-trap", UndefinedTrap,
                     Null | ObjectSize | Return | ReturnsNonnullAttribute |
                     Shift | SignedIntegerOverflow | Unreachable | VLABound)
 
+// -fsanitize=undefined includes all the sanitizers which have low overhead, no
+// ABI or address space layout implications, and only catch undefined behavior.
+SANITIZER_GROUP("undefined", Undefined, UndefinedTrap | Function | Vptr)
+
 SANITIZER_GROUP("integer", Integer,
                 SignedIntegerOverflow | UnsignedIntegerOverflow | Shift |
                 IntegerDivideByZero)