Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2026-05-10 08:43:01

0001 /*===-- llvm-c/IRReader.h - IR Reader 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 file defines the C interface to the IR Reader.                        *|
0011 |*                                                                            *|
0012 \*===----------------------------------------------------------------------===*/
0013 
0014 #ifndef LLVM_C_IRREADER_H
0015 #define LLVM_C_IRREADER_H
0016 
0017 #include "llvm-c/ExternC.h"
0018 #include "llvm-c/Types.h"
0019 
0020 LLVM_C_EXTERN_C_BEGIN
0021 
0022 /**
0023  * @defgroup LLVMCCoreIRReader IR Reader
0024  * @ingroup LLVMCCore
0025  *
0026  * @{
0027  */
0028 
0029 /**
0030  * Read LLVM IR from a memory buffer and convert it into an in-memory Module
0031  * object. Returns 0 on success.
0032  * Optionally returns a human-readable description of any errors that
0033  * occurred during parsing IR. OutMessage must be disposed with
0034  * LLVMDisposeMessage.
0035  *
0036  * @see llvm::ParseIR()
0037  */
0038 LLVMBool LLVMParseIRInContext(LLVMContextRef ContextRef,
0039                               LLVMMemoryBufferRef MemBuf, LLVMModuleRef *OutM,
0040                               char **OutMessage);
0041 
0042 /**
0043  * @}
0044  */
0045 
0046 LLVM_C_EXTERN_C_END
0047 
0048 #endif