1 | //===- RewriteStatepointsForGC.h - ------------------------------*- 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 file provides interface to "Rewrite Statepoints for GC" pass. |
10 | // |
11 | // This passe rewrites call/invoke instructions so as to make potential |
12 | // relocations performed by the garbage collector explicit in the IR. |
13 | // |
14 | //===----------------------------------------------------------------------===// |
15 | |
16 | #ifndef LLVM_TRANSFORMS_SCALAR_REWRITESTATEPOINTSFORGC_H |
17 | #define LLVM_TRANSFORMS_SCALAR_REWRITESTATEPOINTSFORGC_H |
18 | |
19 | #include "llvm/IR/PassManager.h" |
20 | |
21 | namespace llvm { |
22 | |
23 | class DominatorTree; |
24 | class Function; |
25 | class Module; |
26 | class TargetTransformInfo; |
27 | class TargetLibraryInfo; |
28 | |
29 | struct RewriteStatepointsForGC : public PassInfoMixin<RewriteStatepointsForGC> { |
30 | PreservedAnalyses run(Module &M, ModuleAnalysisManager &AM); |
31 | |
32 | bool runOnFunction(Function &F, DominatorTree &, TargetTransformInfo &, |
33 | const TargetLibraryInfo &); |
34 | }; |
35 | |
36 | } // namespace llvm |
37 | |
38 | #endif // LLVM_TRANSFORMS_SCALAR_REWRITESTATEPOINTSFORGC_H |
39 | |