1 | //===-- KCFI.h - Generic KCFI operand bundle lowering -----------*- C++ -*-===// |
2 | // |
3 | // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. |
4 | // See https://llvm.org/LICENSE.txt for license information. |
5 | // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception |
6 | // |
7 | //===----------------------------------------------------------------------===// |
8 | // |
9 | // This pass emits generic KCFI indirect call checks for targets that don't |
10 | // support lowering KCFI operand bundles in the back-end. |
11 | // |
12 | //===----------------------------------------------------------------------===// |
13 | |
14 | #ifndef LLVM_TRANSFORMS_INSTRUMENTATION_KCFI_H |
15 | #define LLVM_TRANSFORMS_INSTRUMENTATION_KCFI_H |
16 | |
17 | #include "llvm/IR/PassManager.h" |
18 | |
19 | namespace llvm { |
20 | class KCFIPass : public PassInfoMixin<KCFIPass> { |
21 | public: |
22 | static bool isRequired() { return true; } |
23 | PreservedAnalyses run(Function &F, FunctionAnalysisManager &AM); |
24 | }; |
25 | } // namespace llvm |
26 | #endif // LLVM_TRANSFORMS_INSTRUMENTATION_KCFI_H |
27 | |