search for: createfromargs

Displaying 11 results from an estimated 11 matches for "createfromargs".

2010 Aug 14
2
[LLVMdev] clang: compile c code from char array?
...ode; // the char array // fill array with code goes here... // Initialize a compiler invocation object from the clang (-cc1) arguments. const driver::ArgStringList &CCArgs = Cmd->getArguments(); llvm::OwningPtr<CompilerInvocation> CI(new CompilerInvocation); CompilerInvocation::CreateFromArgs(*CI, const_cast<const char **>(CCArgs.data()), const_cast<const char **>(CCArgs.data()) + CCArgs.size(), Diags); // Show the invocatio...
2010 Aug 15
2
[LLVMdev] clang: compile c code from char array?
.... >> >> >> // Initialize a compiler invocation object from the clang (-cc1) >> arguments. >> const driver::ArgStringList &CCArgs = Cmd->getArguments(); >> llvm::OwningPtr<CompilerInvocation> CI(new CompilerInvocation); >> CompilerInvocation::CreateFromArgs(*CI, >> const_cast<const char >> **>(CCArgs.data()), >> const_cast<const char >> **>(CCArgs.data()) + >> CCArgs.size(), >>...
2010 Aug 15
0
[LLVMdev] clang: compile c code from char array?
...fill array with code goes here... > > > // Initialize a compiler invocation object from the clang (-cc1) arguments. > const driver::ArgStringList &CCArgs = Cmd->getArguments(); > llvm::OwningPtr<CompilerInvocation> CI(new CompilerInvocation); > CompilerInvocation::CreateFromArgs(*CI, > const_cast<const char > **>(CCArgs.data()), > const_cast<const char > **>(CCArgs.data()) + > CCArgs.size(), > Diags)...
2010 Aug 15
0
[LLVMdev] clang: compile c code from char array?
...; >>> // Initialize a compiler invocation object from the clang (-cc1) >>> arguments. >>> const driver::ArgStringList &CCArgs = Cmd->getArguments(); >>> llvm::OwningPtr<CompilerInvocation> CI(new CompilerInvocation); >>> CompilerInvocation::CreateFromArgs(*CI, >>> const_cast<const char >>> **>(CCArgs.data()), >>> const_cast<const char >>> **>(CCArgs.data()) + >>> CCArgs.size(), >>&g...
2016 Sep 09
2
defaults for FP contraction [e.g. fused multiply-add]: suggestion and patch to be slightly more aggressive and to make Clang`s optimization settings closer to having the same meaning as when they are given to GCC [at least for "-O3"]
...------------------------- diff --git a/clang/lib/Frontend/CompilerInvocation.cpp b/clang/lib/Frontend/CompilerInvocation.cpp index 619ea9c..d02d873 100644 --- a/clang/lib/Frontend/CompilerInvocation.cpp +++ b/clang/lib/Frontend/CompilerInvocation.cpp @@ -2437,6 +2437,13 @@ bool CompilerInvocation::CreateFromArgs(CompilerInvocation &Res, if (Arch == llvm::Triple::spir || Arch == llvm::Triple::spir64) { Res.getDiagnosticOpts().Warnings.push_back("spir-compat"); } + + // If there will ever be e.g. "LangOpts.C", replace "LangOpts.C11 || LangOpts.C99" with &quot...
2010 Aug 18
1
[LLVMdev] clang: call extern function using JIT
...rt(diag::err_fe_expected_clang_command); return 1; } // Initialize a compiler invocation object from the clang (-cc1) arguments. const driver::ArgStringList &CCArgs = Cmd->getArguments(); llvm::OwningPtr<CompilerInvocation> CI(new CompilerInvocation); CompilerInvocation::CreateFromArgs(*CI, const_cast<const char **>(CCArgs.data()), const_cast<const char **>(CCArgs.data()) + CCArgs.size(), Diags); // Show the invocatio...
2010 Aug 18
0
[LLVMdev] clang: call extern function using JIT
I tried what you said, now I get: LLVM ERROR: Program used external function 'yipee' which could not be resolved! Stack dump: 0. Running pass 'X86 Machine Code Emitter' on function '@main' did not even get as far as a breakpoint. Óscar Fuentes wrote: > > gafferuk <gafferuk at gmail.com> writes: > >> Im confused. The function i wish to call is
2010 Aug 18
2
[LLVMdev] clang: call extern function using JIT
gafferuk <gafferuk at gmail.com> writes: > Im confused. The function i wish to call is a return type of int. > Im calling it with int dd = yipee(1); > > What's wrong? Declare the function: int yipee(int); int main() { int dd = yipee(1); return 0; } If that still crashes, put a breakpoint on `yipee' and see if the execution gets there, if the argument is
2013 Oct 03
0
[LLVMdev] libclang JIT frontend
...s.Report(diag::err_fe_expected_clang_command); return 1; } // Initialize a compiler invocation object from the clang (-cc1) arguments. const driver::ArgStringList &CCArgs = Cmd->getArguments(); OwningPtr<CompilerInvocation> CI(new CompilerInvocation); CompilerInvocation::CreateFromArgs(*CI, const_cast<const char **>(CCArgs.data()), const_cast<const char **>(CCArgs.data()) + CCArgs.size(), Diags); // Show the invocatio...
2016 Sep 11
3
defaults for FP contraction [e.g. fused multiply-add]: suggestion and patch to be slightly more aggressive and to make Clang`s optimization settings closer to having the same meaning as when they are given to GCC [at least for "-O3"]
On Sep 10, 2016, at 3:33 AM, Steve Canon <scanon at apple.com> wrote: >>> >>> Pretty much. In particular, imagine a user trying to debug an unexpected floating point result caused by conversion of a*b + c into fma(a, b, c). >> >> I think that’s unavoidable, because of the way the optimization levels work. Even fma contraction is on by default (something I’d
2016 Jul 05
2
Representing MIPS ABI information in the triple as ARM/X86 do for EABI/EABIHF/X32
Hi Eric, It's the unsolved problems on the pass-MCTargetOptions-everywhere path that are my main concern with that approach rather than the amount of work. The first problem is that the result of IRObjectFile::CollectAsmUndefinedRefs() depends on the ABI but IRObjectFile doesn't know it. How would you deliver the ABI to IRObjectFile? The second problem is that IRLinker will link