|
|
|||
File indexing completed on 2026-05-10 08:43:00
0001 /*===-- llvm-c/BitWriter.h - BitWriter Library C Interface ------*- C++ -*-===*\ 0002 |* *| 0003 |* Part of the LLVM Project, under the Apache License v2.0 with LLVM *| 0004 |* Exceptions. *| 0005 |* See https://llvm.org/LICENSE.txt for license information. *| 0006 |* SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception *| 0007 |* *| 0008 |*===----------------------------------------------------------------------===*| 0009 |* *| 0010 |* This header declares the C interface to libLLVMBitWriter.a, which *| 0011 |* implements output of the LLVM bitcode format. *| 0012 |* *| 0013 |* Many exotic languages can interoperate with C code but have a harder time *| 0014 |* with C++ due to name mangling. So in addition to C, this interface enables *| 0015 |* tools written in such languages. *| 0016 |* *| 0017 \*===----------------------------------------------------------------------===*/ 0018 0019 #ifndef LLVM_C_BITWRITER_H 0020 #define LLVM_C_BITWRITER_H 0021 0022 #include "llvm-c/ExternC.h" 0023 #include "llvm-c/Types.h" 0024 0025 LLVM_C_EXTERN_C_BEGIN 0026 0027 /** 0028 * @defgroup LLVMCBitWriter Bit Writer 0029 * @ingroup LLVMC 0030 * 0031 * @{ 0032 */ 0033 0034 /*===-- Operations on modules ---------------------------------------------===*/ 0035 0036 /** Writes a module to the specified path. Returns 0 on success. */ 0037 int LLVMWriteBitcodeToFile(LLVMModuleRef M, const char *Path); 0038 0039 /** Writes a module to an open file descriptor. Returns 0 on success. */ 0040 int LLVMWriteBitcodeToFD(LLVMModuleRef M, int FD, int ShouldClose, 0041 int Unbuffered); 0042 0043 /** Deprecated for LLVMWriteBitcodeToFD. Writes a module to an open file 0044 descriptor. Returns 0 on success. Closes the Handle. */ 0045 int LLVMWriteBitcodeToFileHandle(LLVMModuleRef M, int Handle); 0046 0047 /** Writes a module to a new memory buffer and returns it. */ 0048 LLVMMemoryBufferRef LLVMWriteBitcodeToMemoryBuffer(LLVMModuleRef M); 0049 0050 /** 0051 * @} 0052 */ 0053 0054 LLVM_C_EXTERN_C_END 0055 0056 #endif
| [ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
|
This page was automatically generated by the 2.3.7 LXR engine. The LXR team |
|