Displaying 20 results from an estimated 22 matches for "llvminitializenativetarget".
2013 Feb 17
0
[LLVMdev] [llvm-c] LLVMInitializeNativeTarget not exported in shared library
Dear LLVM devs (and other subscribers),
when building llvm as a shared library (so or dll, tested with both) and
then performing objdump
on the resulting library will reveal that LLVMInitializeNativeTarget
does not get exported
("objdump -x libLLVM-3.3svn.so | grep LLVMInitializeNativeTarget" will
return without any output).
As far as I can tell this is because the function is marked as inline at
its definition in
http://llvm.org/docs/doxygen/html/TargetSelect_8h_source.html#l00116
whic...
2011 May 29
1
[LLVMdev] LLVMInitializeNativeTarget error
...veTarget line commented out like so:
<https://github.com/keithshep/llvm-fs/blob/b7050b841108dc703e58563a4cff8845603c950d/test/simpletest2.fs>
... but if I uncomment the initializeNativeTarget line I get the
following error from mono:
Unhandled Exception: System.EntryPointNotFoundException:
LLVMInitializeNativeTarget
at (wrapper managed-to-native)
LLVM.Generated.Target:initializeNativeTargetNative ()
at Simpletest2.main (System.String[] _arg5) [0x00000] in <filename unknown>:0
I'm using LLVM on OS X 10.5 and since enable-shared is needed for use
with mono it was configured as:
./configure --enabl...
2013 Feb 18
1
[LLVMdev] [llvm-c] Proposal: Make LLVMInitializeNativeTarget and co. non-inline
Hi,
when building llvm as a shared library LLVMInitializeNativeTarget and co.
(located in llvm/Support/TargetSelect) will not get
exported as symbol into the shared library, because they are static inline.
Since they are functions defined in the C API no one else inside LLVM
calls them,
which results in them not being exported.
This is, of course, no problem for C...
2009 Oct 07
2
[LLVMdev] InitializeNativeTarget
It seems that a client application needs to call
InitializeNativeTarget or LLVMInitializeNativeTarget before doing any
JITting. Unfortunately, LLVMInitializeNativeTarget is defined static
inline and does not appear in the .a files; thus a client not written
in C or C++ trying to JIT cannot link to the library and call
LLVMInitializeNativeTarget that way.
It can call a target-specific library func...
2009 Oct 07
0
[LLVMdev] InitializeNativeTarget
Kenneth Uildriks wrote:
> It seems that a client application needs to call
> InitializeNativeTarget or LLVMInitializeNativeTarget before doing any
> JITting. Unfortunately, LLVMInitializeNativeTarget is defined static
> inline and does not appear in the .a files; thus a client not written
> in C or C++ trying to JIT cannot link to the library and call
> LLVMInitializeNativeTarget that way.
Yes, so you'll nee...
2013 May 11
2
[LLVMdev] [llvm-c]
...seful
information out of it.
Despite the fact that the following code is written in Pascal, can you
please tell me if I have done something wrong here?
// initialize all targets / target information
LLVMInitializeAllTargets;
LLVMInitializeAllTargetInfos;
// initialize native target in particular
LLVMInitializeNativeTarget;
// get first target
Target := LLVMGetFirstTarget;
// loop until the target is NULL
while (Target <> nil) do
begin
// get target name & description
TargetName := LLVMGetTargetName(Target);
TargetDescription := LLVMGetTargetDescription(Target);
// do something with these informa...
2017 Mar 09
2
LLVMGetBitcodeModuleInContext2 problem
Oops, missed initializing some stuff. Added:
LLVMLinkInMCJIT();
LLVMInitializeNativeTarget();
LLVMInitializeNativeAsmPrinter();
LLVMInitializeNativeAsmParser();
Now it crashes in LLVMGetFunctionAddress().
Hmm.
On Wed, Mar 8, 2017 at 5:14 PM, Toshiyasu Morita <toshi at tensyr.com> wrote:
> Made it a bit further. Here's the current code:
>
> void llv...
2009 Oct 21
2
[LLVMdev] Problem initializing a JIT via C bindings
Hi all,
I have some code that uses the x86 JIT via the C bindings that I'm trying to migrate from targeting LLVM 2.5 to the top of tree, but I'm running into a linking problem I can't figure out.
Here's how I'm invoking the JIT in 2.5.
LLVMInitializeNativeTarget(); <-- for the updated version
LLVMCreateMemoryBufferWithContentsOfFile("code.bc", &buffer, &err);
LLVMGetBitcodeModuleProvider(buffer, &provider, &err);
LLVMCreateJITCompiler(&engine, provider, 1, &err);
After that LLVMFindFunction and RunFunction work wonderf...
2012 Mar 04
1
[LLVMdev] LLVM from .NET
...he performance is awful which (IIRC) is probably because the
native target has not been initialized correctly and LLVM is falling back to
the IR interpreter. Keith Sheppard used a hack to call
LLVMInitializeX86Target but that hasn't done the trick and I cannot figure
out how to call the correct LLVMInitializeNativeTarget function from .NET.
Does anyone know the solutions to these problems or, better yet, have a
pre-existing .NET binding to LLVM where everything just works effortlessly?
FWIW, I tried running Microsoft's PInvoke Interop Assistant on LLVM-3.0.dll
in an attempt to generate .NET bindings automatic...
2013 May 13
0
[LLVMdev] [llvm-c]
...e fact that the following code is written in Pascal, can you
> please tell me if I have done something wrong here?
>
> // initialize all targets / target information
> LLVMInitializeAllTargets;
> LLVMInitializeAllTargetInfos;
>
> // initialize native target in particular
> LLVMInitializeNativeTarget;
>
> // get first target
> Target := LLVMGetFirstTarget;
>
> // loop until the target is NULL
> while (Target <> nil) do
> begin
> // get target name & description
> TargetName := LLVMGetTargetName(Target);
> TargetDescription := LLVMGetTargetDescript...
2013 May 14
1
[LLVMdev] [llvm-c]
...is written in Pascal, can you
>> please tell me if I have done something wrong here?
>>
>> // initialize all targets / target information
>> LLVMInitializeAllTargets;
>> LLVMInitializeAllTargetInfos;
>>
>> // initialize native target in particular
>> LLVMInitializeNativeTarget;
>>
>> // get first target
>> Target := LLVMGetFirstTarget;
>>
>> // loop until the target is NULL
>> while (Target <> nil) do
>> begin
>> // get target name & description
>> TargetName := LLVMGetTargetName(Target);
>> Targ...
2012 Apr 25
2
[LLVMdev] Crash in JIT
...aram, "mx");
LLVMValueRef y;
y = LLVMBuildAdd(builder, mx, bParam, "y");
LLVMValueRef retInst;
retInst = LLVMBuildRet(builder, y);
(void) retInst;
LLVMDisposeBuilder(builder);
LLVMLinkInJIT();
LLVMLinkInInterpreter();
LLVMInitializeNativeTarget();
LLVMDumpModule(module);
/* Now run it! */
LLVMExecutionEngineRef jit = NULL;
char *err;
// LLVMBool result = LLVMCreateExecutionEngineForModule(&jit, module, &err);
LLVMBool result = LLVMCreateJITCompilerForModule(&jit, module, 0, &err);...
2009 Oct 22
0
[LLVMdev] Problem initializing a JIT via C bindings
...rote:
> Hi all,
>
> I have some code that uses the x86 JIT via the C bindings that I'm trying to migrate from targeting LLVM 2.5 to the top of tree, but I'm running into a linking problem I can't figure out.
>
> Here's how I'm invoking the JIT in 2.5.
>
> LLVMInitializeNativeTarget(); <-- for the updated version
> LLVMCreateMemoryBufferWithContentsOfFile("code.bc", &buffer, &err);
> LLVMGetBitcodeModuleProvider(buffer, &provider, &err);
> LLVMCreateJITCompiler(&engine, provider, 1, &err);
>
> After that LLVMFindFunction and...
2010 Aug 12
0
[LLVMdev] LLVM-C: Calling functions contained in other libraries
On Aug 12, 2010, at 10:43 AM, F van der Meeren wrote:
> Where am I going wrong here?
>
Did you link against the library that contains the function?
-eric
2011 Aug 02
0
[LLVMdev] llvm-fs 0.0.0
...to
others. Comments and bug reports are welcome.
BTW it was very useful to me that the C API was structured in a nice,
consistent way. It allowed me to autogen most of the bindings which
makes for a more complete binding coverage with hopefully fewer bugs.
One disappointment with the C API is that LLVMInitializeNativeTarget
is declared static so it can't be used by bindings like llvm-fs.
Best, Keith
--
keithsheppard.name
2012 Apr 25
0
[LLVMdev] Crash in JIT
...der, mParam, xParam, "mx");
LLVMValueRef y;
y = LLVMBuildAdd(builder, mx, bParam, "y");
LLVMValueRef retInst;
retInst = LLVMBuildRet(builder, y);
(void) retInst;
LLVMDisposeBuilder(builder);
LLVMLinkInJIT();
LLVMLinkInInterpreter();
LLVMInitializeNativeTarget();
LLVMDumpModule(module);
/* Now run it! */
LLVMExecutionEngineRef jit = NULL;
char *err;
// LLVMBool result = LLVMCreateExecutionEngineForModule(&jit, module, &err);
LLVMBool result = LLVMCreateJITCompilerForModule(&jit, module, 0, &err);
if (resul...
2009 Nov 19
1
[LLVMdev] llvm-c: LLVMCreateExecutionEngine returning empty error message
Hello, I'm using the llvm-c bindings for C, but I'm getting some problems,
the LLVMCreateExecutionEngine is returning 1 but the error message is an
empty string (it's !=NULL).
The steps I'm doing is to create the module, then I call LLVMVerifyModule to
verify and it works fine, later I call
LLVMCreateModuleProviderForExistingModule and it returns !=NULL MP, so it's
ok, but
2010 Aug 12
3
[LLVMdev] LLVM-C: Calling functions contained in other libraries
Hello,
I have a question concerning llvm-c.
I have set up a function that needs to invoke an external method, in a other library. It has the following signature: void* NSFullUserName(void);
The void* can be replaced with a i8*, that far I was able to get, but when my call is invoked, the engine gives me the following message:
LLVM ERROR: Tried to execute an unknown external function: i8* ()*
2012 Sep 27
0
[LLVMdev] Possible bug or misunderstanding of feature LLVMConstIntOfString
...rintf("\n[llvmPrintf# %s] Verifying Function:\n", moduleName);
LLVMVerifyFunction(vFnMain, LLVMPrintMessageAction);
printf("\n[llvmPrintf# %s] Dumping LLVM generated Code:\n", moduleName);
LLVMDumpModule(modCEx);
// Compile and JIT above generated function:
LLVMInitializeNativeTarget();
LLVMExecutionEngineRef engExe;
char * pErr = NULL;
LLVMCreateJITCompilerForModule(&engExe, modCEx, 4, &pErr);
if (pErr) {
printf("[Creating JIT Compiler] Error: %s\n", pErr);
LLVMDisposeMessage(pErr);
exit(0);
}
LLVMPassManagerRe...
2015 Aug 05
2
[BUG] Incorrect ASCII escape characters on Mac
On Wed, 2015-08-05 at 10:02 -0400, Ramkumar Ramachandra wrote:
>
> - at 5 = internal global [10 x i8] c"\22\D0\12\F4!\00\15\F9\EC\E1"
> - at 6 = internal global [10 x i8] c"\D0\19\FB+\FD\F8#\03\E2\11"
> + at 5 = internal global [10 x i8] c"\22Ð\12ô!\00\15ùìá"
> + at 6 = internal global [10 x i8] c"Ð\19û+ýø#\03â\11"
>
> The diff