ObjCARC.h 2.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980
  1. #pragma once
  2. #ifdef __GNUC__
  3. #pragma GCC diagnostic push
  4. #pragma GCC diagnostic ignored "-Wunused-parameter"
  5. #endif
  6. //===-- ObjCARC.h - ObjCARC Scalar Transformations --------------*- C++ -*-===//
  7. //
  8. // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
  9. // See https://llvm.org/LICENSE.txt for license information.
  10. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
  11. //
  12. //===----------------------------------------------------------------------===//
  13. //
  14. // This header file defines prototypes for accessor functions that expose passes
  15. // in the ObjCARC Scalar Transformations library.
  16. //
  17. //===----------------------------------------------------------------------===//
  18. #ifndef LLVM_TRANSFORMS_OBJCARC_H
  19. #define LLVM_TRANSFORMS_OBJCARC_H
  20. #include "llvm/IR/PassManager.h"
  21. namespace llvm {
  22. class Pass;
  23. //===----------------------------------------------------------------------===//
  24. //
  25. // ObjCARCAPElim - ObjC ARC autorelease pool elimination.
  26. //
  27. Pass *createObjCARCAPElimPass();
  28. //===----------------------------------------------------------------------===//
  29. //
  30. // ObjCARCExpand - ObjC ARC preliminary simplifications.
  31. //
  32. Pass *createObjCARCExpandPass();
  33. //===----------------------------------------------------------------------===//
  34. //
  35. // ObjCARCContract - Late ObjC ARC cleanups.
  36. //
  37. Pass *createObjCARCContractPass();
  38. //===----------------------------------------------------------------------===//
  39. //
  40. // ObjCARCOpt - ObjC ARC optimization.
  41. //
  42. Pass *createObjCARCOptPass();
  43. struct ObjCARCOptPass : public PassInfoMixin<ObjCARCOptPass> {
  44. PreservedAnalyses run(Function &F, FunctionAnalysisManager &AM);
  45. };
  46. struct ObjCARCContractPass : public PassInfoMixin<ObjCARCContractPass> {
  47. PreservedAnalyses run(Function &F, FunctionAnalysisManager &AM);
  48. };
  49. struct ObjCARCAPElimPass : public PassInfoMixin<ObjCARCAPElimPass> {
  50. PreservedAnalyses run(Module &M, ModuleAnalysisManager &AM);
  51. };
  52. struct ObjCARCExpandPass : public PassInfoMixin<ObjCARCExpandPass> {
  53. PreservedAnalyses run(Function &M, FunctionAnalysisManager &AM);
  54. };
  55. struct PAEvalPass : public PassInfoMixin<PAEvalPass> {
  56. PreservedAnalyses run(Function &F, FunctionAnalysisManager &AM);
  57. };
  58. } // End llvm namespace
  59. #endif
  60. #ifdef __GNUC__
  61. #pragma GCC diagnostic pop
  62. #endif