[llvm] r235266 - Remove the CFIType TargetOption as it is unused.
Eric Christopher
echristo at gmail.com
Sat Apr 18 20:20:55 PDT 2015
Author: echristo
Date: Sat Apr 18 22:20:55 2015
New Revision: 235266
URL: http://llvm.org/viewvc/llvm-project?rev=235266&view=rev
Log:
Remove the CFIType TargetOption as it is unused.
Modified:
llvm/trunk/include/llvm/CodeGen/CommandFlags.h
llvm/trunk/include/llvm/Target/TargetOptions.h
Modified: llvm/trunk/include/llvm/CodeGen/CommandFlags.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/CodeGen/CommandFlags.h?rev=235266&r1=235265&r2=235266&view=diff
==============================================================================
--- llvm/trunk/include/llvm/CodeGen/CommandFlags.h (original)
+++ llvm/trunk/include/llvm/CodeGen/CommandFlags.h Sat Apr 18 22:20:55 2015
@@ -231,19 +231,6 @@ FCFI("fcfi",
cl::desc("Apply forward-edge control-flow integrity"),
cl::init(false));
-cl::opt<llvm::CFIntegrity>
-CFIType("cfi-type",
- cl::desc("Choose the type of Control-Flow Integrity check to add"),
- cl::init(CFIntegrity::Sub),
- cl::values(
- clEnumValN(CFIntegrity::Sub, "sub",
- "Subtract the pointer from the table base, then mask."),
- clEnumValN(CFIntegrity::Ror, "ror",
- "Use rotate to check the offset from a table base."),
- clEnumValN(CFIntegrity::Add, "add",
- "Mask out the high bits and add to an aligned base."),
- clEnumValEnd));
-
cl::opt<bool>
CFIEnforcing("cfi-enforcing",
cl::desc("Enforce CFI or pass the violation to a function."),
@@ -293,7 +280,6 @@ static inline TargetOptions InitTargetOp
Options.MCOptions = InitMCTargetOptionsFromFlags();
Options.JTType = JTableType;
Options.FCFI = FCFI;
- Options.CFIType = CFIType;
Options.CFIEnforcing = CFIEnforcing;
Options.CFIFuncName = CFIFuncName;
Modified: llvm/trunk/include/llvm/Target/TargetOptions.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Target/TargetOptions.h?rev=235266&r1=235265&r2=235266&view=diff
==============================================================================
--- llvm/trunk/include/llvm/Target/TargetOptions.h (original)
+++ llvm/trunk/include/llvm/Target/TargetOptions.h Sat Apr 18 22:20:55 2015
@@ -57,14 +57,6 @@ namespace llvm {
};
}
- enum class CFIntegrity {
- Sub, // Use subtraction-based checks.
- Ror, // Use rotation-based checks.
- Add // Use addition-based checks. This depends on having
- // sufficient alignment in the code and is usually not
- // feasible.
- };
-
class TargetOptions {
public:
TargetOptions()
@@ -82,7 +74,7 @@ namespace llvm {
TrapFuncName(), FloatABIType(FloatABI::Default),
AllowFPOpFusion(FPOpFusion::Standard), JTType(JumpTable::Single),
FCFI(false), ThreadModel(ThreadModel::POSIX),
- CFIType(CFIntegrity::Sub), CFIEnforcing(false), CFIFuncName() {}
+ CFIEnforcing(false), CFIFuncName() {}
/// PrintMachineCode - This flag is enabled when the -print-machineinstrs
/// option is specified on the command line, and should enable debugging
@@ -238,10 +230,6 @@ namespace llvm {
/// for things like atomics
ThreadModel::Model ThreadModel;
- /// CFIType - This flag specifies the type of control-flow integrity check
- /// to add as a preamble to indirect calls.
- CFIntegrity CFIType;
-
/// CFIEnforcing - This flags controls whether or not CFI violations cause
/// the program to halt.
bool CFIEnforcing;
@@ -282,7 +270,6 @@ inline bool operator==(const TargetOptio
ARE_EQUAL(JTType) &&
ARE_EQUAL(FCFI) &&
ARE_EQUAL(ThreadModel) &&
- ARE_EQUAL(CFIType) &&
ARE_EQUAL(CFIEnforcing) &&
ARE_EQUAL(CFIFuncName) &&
ARE_EQUAL(MCOptions);
More information about the llvm-commits
mailing list