mirror of
https://github.com/c3lang/c3c.git
synced 2026-02-27 12:01:16 +00:00
Add wrapper methods, use LLVM-transforms directly.
This commit is contained in:
committed by
Christoffer Lerno
parent
8285720180
commit
9dfe7ddbde
@@ -8,6 +8,7 @@
|
||||
#include "llvm-c/TargetMachine.h"
|
||||
#include "llvm/Target/TargetMachine.h"
|
||||
#include "lld/Common/CommonLinkerContext.h"
|
||||
#include "llvm/IR/GlobalValue.h"
|
||||
|
||||
#define LINK_SIG \
|
||||
bool link(llvm::ArrayRef<const char *> args, llvm::raw_ostream &stdoutOS, \
|
||||
@@ -183,6 +184,10 @@ extern "C" {
|
||||
auto machine = reinterpret_cast<llvm::TargetMachine *>(ref);
|
||||
machine->Options.UseInitArray = use_init_array;
|
||||
}
|
||||
void LLVMSetDSOLocal(LLVMValueRef Global, bool value)
|
||||
{
|
||||
llvm::unwrap<llvm::GlobalValue>(Global)->setDSOLocal(value);
|
||||
}
|
||||
|
||||
void LLVMBuilderSetFastMathFlags(LLVMBuilderRef Builder, FastMathOption option)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user