Peter Zotov | 34ddbf1 | 2013-11-06 09:21:31 +0000 | [diff] [blame] | 1 | /*===-- llvm-c/Support.h - Support C Interface --------------------*- C -*-===*\ |
| 2 | |* *| |
| 3 | |* The LLVM Compiler Infrastructure *| |
| 4 | |* *| |
| 5 | |* This file is distributed under the University of Illinois Open Source *| |
| 6 | |* License. See LICENSE.TXT for details. *| |
| 7 | |* *| |
| 8 | |*===----------------------------------------------------------------------===*| |
| 9 | |* *| |
| 10 | |* This file defines the C interface to the LLVM support library. *| |
| 11 | |* *| |
| 12 | \*===----------------------------------------------------------------------===*/ |
| 13 | |
| 14 | #ifndef LLVM_C_SUPPORT_H |
| 15 | #define LLVM_C_SUPPORT_H |
| 16 | |
Chandler Carruth | 3c57aa4 | 2014-03-06 04:13:12 +0000 | [diff] [blame] | 17 | #include "llvm/Support/DataTypes.h" |
Peter Zotov | 34ddbf1 | 2013-11-06 09:21:31 +0000 | [diff] [blame] | 18 | |
| 19 | #ifdef __cplusplus |
| 20 | extern "C" { |
| 21 | #endif |
| 22 | |
| 23 | /** |
Chandler Carruth | 3c57aa4 | 2014-03-06 04:13:12 +0000 | [diff] [blame] | 24 | * @defgroup LLVMCSupportTypes Types and Enumerations |
| 25 | * |
| 26 | * @{ |
| 27 | */ |
| 28 | |
| 29 | typedef int LLVMBool; |
| 30 | |
| 31 | /** |
| 32 | * Used to pass regions of memory through LLVM interfaces. |
| 33 | * |
| 34 | * @see llvm::MemoryBuffer |
| 35 | */ |
| 36 | typedef struct LLVMOpaqueMemoryBuffer *LLVMMemoryBufferRef; |
| 37 | |
| 38 | /** |
| 39 | * @} |
| 40 | */ |
| 41 | |
| 42 | /** |
Peter Zotov | 34ddbf1 | 2013-11-06 09:21:31 +0000 | [diff] [blame] | 43 | * This function permanently loads the dynamic library at the given path. |
| 44 | * It is safe to call this function multiple times for the same library. |
| 45 | * |
| 46 | * @see sys::DynamicLibrary::LoadLibraryPermanently() |
| 47 | */ |
| 48 | LLVMBool LLVMLoadLibraryPermanently(const char* Filename); |
| 49 | |
Peter Collingbourne | e186319 | 2014-10-16 22:47:52 +0000 | [diff] [blame] | 50 | /** |
| 51 | * This function parses the given arguments using the LLVM command line parser. |
| 52 | * Note that the only stable thing about this function is its signature; you |
| 53 | * cannot rely on any particular set of command line arguments being interpreted |
| 54 | * the same way across LLVM versions. |
| 55 | * |
| 56 | * @see llvm::cl::ParseCommandLineOptions() |
| 57 | */ |
| 58 | void LLVMParseCommandLineOptions(int argc, const char *const *argv, |
| 59 | const char *Overview); |
| 60 | |
Peter Zotov | 34ddbf1 | 2013-11-06 09:21:31 +0000 | [diff] [blame] | 61 | #ifdef __cplusplus |
| 62 | } |
| 63 | #endif |
| 64 | |
NAKAMURA Takumi | 29c3b55 | 2013-11-07 13:54:24 +0000 | [diff] [blame] | 65 | #endif |