Andrew Scull | 5e1ddfa | 2018-08-14 10:06:54 +0100 | [diff] [blame] | 1 | //===-- ObjCARC.h - ObjCARC Scalar Transformations --------------*- C++ -*-===// |
| 2 | // |
Andrew Walbran | 16937d0 | 2019-10-22 13:54:20 +0100 | [diff] [blame] | 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 |
Andrew Scull | 5e1ddfa | 2018-08-14 10:06:54 +0100 | [diff] [blame] | 6 | // |
| 7 | //===----------------------------------------------------------------------===// |
| 8 | // |
| 9 | // This header file defines prototypes for accessor functions that expose passes |
| 10 | // in the ObjCARC Scalar Transformations library. |
| 11 | // |
| 12 | //===----------------------------------------------------------------------===// |
| 13 | |
| 14 | #ifndef LLVM_TRANSFORMS_OBJCARC_H |
| 15 | #define LLVM_TRANSFORMS_OBJCARC_H |
| 16 | |
Olivier Deprez | f4ef2d0 | 2021-04-20 13:36:24 +0200 | [diff] [blame^] | 17 | #include "llvm/IR/PassManager.h" |
| 18 | |
Andrew Scull | 5e1ddfa | 2018-08-14 10:06:54 +0100 | [diff] [blame] | 19 | namespace llvm { |
| 20 | |
| 21 | class Pass; |
| 22 | |
| 23 | //===----------------------------------------------------------------------===// |
| 24 | // |
| 25 | // ObjCARCAPElim - ObjC ARC autorelease pool elimination. |
| 26 | // |
| 27 | Pass *createObjCARCAPElimPass(); |
| 28 | |
| 29 | //===----------------------------------------------------------------------===// |
| 30 | // |
| 31 | // ObjCARCExpand - ObjC ARC preliminary simplifications. |
| 32 | // |
| 33 | Pass *createObjCARCExpandPass(); |
| 34 | |
| 35 | //===----------------------------------------------------------------------===// |
| 36 | // |
| 37 | // ObjCARCContract - Late ObjC ARC cleanups. |
| 38 | // |
| 39 | Pass *createObjCARCContractPass(); |
| 40 | |
| 41 | //===----------------------------------------------------------------------===// |
| 42 | // |
| 43 | // ObjCARCOpt - ObjC ARC optimization. |
| 44 | // |
| 45 | Pass *createObjCARCOptPass(); |
| 46 | |
Olivier Deprez | f4ef2d0 | 2021-04-20 13:36:24 +0200 | [diff] [blame^] | 47 | struct ObjCARCOptPass : public PassInfoMixin<ObjCARCOptPass> { |
| 48 | PreservedAnalyses run(Function &F, FunctionAnalysisManager &AM); |
| 49 | }; |
| 50 | |
| 51 | struct ObjCARCContractPass : public PassInfoMixin<ObjCARCContractPass> { |
| 52 | PreservedAnalyses run(Function &F, FunctionAnalysisManager &AM); |
| 53 | }; |
| 54 | |
| 55 | struct ObjCARCAPElimPass : public PassInfoMixin<ObjCARCAPElimPass> { |
| 56 | PreservedAnalyses run(Module &M, ModuleAnalysisManager &AM); |
| 57 | }; |
| 58 | |
| 59 | struct ObjCARCExpandPass : public PassInfoMixin<ObjCARCExpandPass> { |
| 60 | PreservedAnalyses run(Function &M, FunctionAnalysisManager &AM); |
| 61 | }; |
| 62 | |
Andrew Scull | 5e1ddfa | 2018-08-14 10:06:54 +0100 | [diff] [blame] | 63 | } // End llvm namespace |
| 64 | |
| 65 | #endif |