1226584Sdim/*===-- llvm-c/Transform/PassManagerBuilder.h - PMB C Interface ---*- C -*-===*\ 2226584Sdim|* *| 3226584Sdim|* The LLVM Compiler Infrastructure *| 4226584Sdim|* *| 5226584Sdim|* This file is distributed under the University of Illinois Open Source *| 6226584Sdim|* License. See LICENSE.TXT for details. *| 7226584Sdim|* *| 8226584Sdim|*===----------------------------------------------------------------------===*| 9226584Sdim|* *| 10226584Sdim|* This header declares the C interface to the PassManagerBuilder class. *| 11226584Sdim|* *| 12226584Sdim\*===----------------------------------------------------------------------===*/ 13226584Sdim 14249423Sdim#ifndef LLVM_C_TRANSFORMS_PASSMANAGERBUILDER_H 15249423Sdim#define LLVM_C_TRANSFORMS_PASSMANAGERBUILDER_H 16226584Sdim 17296417Sdim#include "llvm-c/Types.h" 18226584Sdim 19226584Sdimtypedef struct LLVMOpaquePassManagerBuilder *LLVMPassManagerBuilderRef; 20226584Sdim 21226584Sdim#ifdef __cplusplus 22226584Sdimextern "C" { 23226584Sdim#endif 24226584Sdim 25234353Sdim/** 26234353Sdim * @defgroup LLVMCTransformsPassManagerBuilder Pass manager builder 27234353Sdim * @ingroup LLVMCTransforms 28234353Sdim * 29234353Sdim * @{ 30234353Sdim */ 31234353Sdim 32226584Sdim/** See llvm::PassManagerBuilder. */ 33226584SdimLLVMPassManagerBuilderRef LLVMPassManagerBuilderCreate(void); 34226584Sdimvoid LLVMPassManagerBuilderDispose(LLVMPassManagerBuilderRef PMB); 35226584Sdim 36226584Sdim/** See llvm::PassManagerBuilder::OptLevel. */ 37226584Sdimvoid 38226584SdimLLVMPassManagerBuilderSetOptLevel(LLVMPassManagerBuilderRef PMB, 39226584Sdim unsigned OptLevel); 40226584Sdim 41226584Sdim/** See llvm::PassManagerBuilder::SizeLevel. */ 42226584Sdimvoid 43226584SdimLLVMPassManagerBuilderSetSizeLevel(LLVMPassManagerBuilderRef PMB, 44226584Sdim unsigned SizeLevel); 45226584Sdim 46226584Sdim/** See llvm::PassManagerBuilder::DisableUnitAtATime. */ 47226584Sdimvoid 48226584SdimLLVMPassManagerBuilderSetDisableUnitAtATime(LLVMPassManagerBuilderRef PMB, 49226584Sdim LLVMBool Value); 50226584Sdim 51226584Sdim/** See llvm::PassManagerBuilder::DisableUnrollLoops. */ 52226584Sdimvoid 53226584SdimLLVMPassManagerBuilderSetDisableUnrollLoops(LLVMPassManagerBuilderRef PMB, 54226584Sdim LLVMBool Value); 55226584Sdim 56226584Sdim/** See llvm::PassManagerBuilder::DisableSimplifyLibCalls */ 57226584Sdimvoid 58226584SdimLLVMPassManagerBuilderSetDisableSimplifyLibCalls(LLVMPassManagerBuilderRef PMB, 59226584Sdim LLVMBool Value); 60226584Sdim 61226584Sdim/** See llvm::PassManagerBuilder::Inliner. */ 62226584Sdimvoid 63226584SdimLLVMPassManagerBuilderUseInlinerWithThreshold(LLVMPassManagerBuilderRef PMB, 64226584Sdim unsigned Threshold); 65226584Sdim 66226584Sdim/** See llvm::PassManagerBuilder::populateFunctionPassManager. */ 67226584Sdimvoid 68226584SdimLLVMPassManagerBuilderPopulateFunctionPassManager(LLVMPassManagerBuilderRef PMB, 69226584Sdim LLVMPassManagerRef PM); 70226584Sdim 71226584Sdim/** See llvm::PassManagerBuilder::populateModulePassManager. */ 72226584Sdimvoid 73226584SdimLLVMPassManagerBuilderPopulateModulePassManager(LLVMPassManagerBuilderRef PMB, 74226584Sdim LLVMPassManagerRef PM); 75226584Sdim 76226584Sdim/** See llvm::PassManagerBuilder::populateLTOPassManager. */ 77226584Sdimvoid LLVMPassManagerBuilderPopulateLTOPassManager(LLVMPassManagerBuilderRef PMB, 78226584Sdim LLVMPassManagerRef PM, 79249423Sdim LLVMBool Internalize, 80249423Sdim LLVMBool RunInliner); 81226584Sdim 82234353Sdim/** 83234353Sdim * @} 84234353Sdim */ 85234353Sdim 86226584Sdim#ifdef __cplusplus 87226584Sdim} 88226584Sdim#endif 89226584Sdim 90226584Sdim#endif 91