Displaying 20 results from an estimated 20000 matches similar to: "[LLVMdev] On-Stack Replacement & Code Patching"
2010 Mar 10
0
[LLVMdev] On-Stack Replacement & Code Patching
On Wed, Mar 10, 2010 at 21:11, Nyx <mcheva at cs.mcgill.ca> wrote:
>
> I am interested in writing a JIT that makes use of on-stack replacement. This
> essentially means that the JIT must be able to compile new versions of
> already compiled functions (eg: more optimized versions) and ensure that the
> code for the new functions is executed. I was wondering if LLVM offers any
2010 Mar 10
0
[LLVMdev] On-Stack Replacement & Code Patching
On Wed, Mar 10, 2010 at 3:11 PM, Nyx <mcheva at cs.mcgill.ca> wrote:
>
> I am interested in writing a JIT that makes use of on-stack replacement. This
> essentially means that the JIT must be able to compile new versions of
> already compiled functions (eg: more optimized versions) and ensure that the
> code for the new functions is executed. I was wondering if LLVM offers any
2009 Jun 18
2
[LLVMdev] Explicitly Freeing Allocas
That sounds rather cumbersome, is there no simpler way to get the actual size
of a struct?
John Criswell wrote:
>
> Nyx wrote:
>> Hello,
>>
>> I would just like to ask if it's possible to explicitly free allocas.
>> This
>> is because I need to call functions that take structs of different sizes
>> as
>> input, (possibly inside of loops) and I
2010 Apr 05
3
[LLVMdev] Linking with C Library
>> You need to figure out how to pass -rdynamic to the linker, like I
said before. http://llvm.org/docs/tutorial/OCamlLangImpl7.html
mentions it, but I don't know enough about the ocaml build process to
say whether that'll work.
I believe I'm already doing that, properly by passing -ccopt -rdynamic to
ocamlopt:
ocamlopt -cc g++ -ccopt -rdynamic -linkall $(LIBFILES) -o alpha
2010 Apr 04
2
[LLVMdev] Linking with C Library
I'm coding a JIT compiler for C source in OCaml, using LLVM. I'm pretty much
done with the LLVM code generation. The problem is that I can't seem to call
C library functions. I was told that all I needed to do to be able to link
with libc functions was to declare them in my module and give them external
linkage, but this does not seem to work. Please note that this is a JIT
compiler. I
2009 Jun 29
2
[LLVMdev] Instruction Combining Pass *Breaking* Struct Reads?
I'm in a situation where I have code that works fine if I don't run the
instruction combining optimization pass, but breaks when I do. The code in
question is meant to allocate space for two structs on the stack using
alloca, and then pass pointers to these to a callee function. One struct
serves to store the input to the function, the other serves for the callee
function to write its
2009 Jun 29
0
[LLVMdev] Instruction Combining Pass *Breaking* Struct Reads?
On Mon, Jun 29, 2009 at 5:54 AM, Nyx<mcheva at cs.mcgill.ca> wrote:
> As you can see, I allocate two structs, one taking 16 bytes (containing two
> i64 values), and one taking 12 bytes (containing a pointer and an i64 value,
> this is on a 32-bit machine)
Are you sure that's right? If the target data specifies that a
pointer is 64 bits or that i64 has an alignment of 64 bits,
2009 Jun 18
0
[LLVMdev] Explicitly Freeing Allocas
In the TargetData class (available from you ExecutionEngine), you have some
informations available (such as StructLayout...).
On Thu, Jun 18, 2009 at 5:08 PM, Nyx <mcheva at cs.mcgill.ca> wrote:
>
> That sounds rather cumbersome, is there no simpler way to get the actual
> size
> of a struct?
>
>
> John Criswell wrote:
> >
> > Nyx wrote:
> >>
2010 Apr 05
2
[LLVMdev] Linking with C Library
I tried running nm - D | grep "puts" on the binary compiled by the OCaml
compiler. It outputs the following:
08161b00 T camlRuntime__rt_fputs_208
08161a20 T camlRuntime__rt_puts_198
U fputs
I'm assuming this means that fputs is linked dynamically, and puts is
not. I tried modifying my code to use fputs instead of puts instead, but
had no success, however, I still get:
2010 Apr 06
0
[LLVMdev] Linking with C Library
On Mon, Apr 5, 2010 at 3:27 PM, Nyx <mcheva at cs.mcgill.ca> wrote:
>
>>> You need to figure out how to pass -rdynamic to the linker, like I
> said before. http://llvm.org/docs/tutorial/OCamlLangImpl7.html
> mentions it, but I don't know enough about the ocaml build process to
> say whether that'll work.
>
> I believe I'm already doing that, properly by
2010 Apr 04
0
[LLVMdev] Linking with C Library
In C, on Linux, you would have to link your JIT compiler with
-rdynamic or -Wl,-export-dynamic (they're synonyms). I'm not sure what
the equivalent linker flag is for OCaml.
You can see what symbols are available to the JIT with `nm -D`.
On Sun, Apr 4, 2010 at 8:41 AM, Nyx <mcheva at cs.mcgill.ca> wrote:
>
> I'm coding a JIT compiler for C source in OCaml, using LLVM.
2010 Feb 24
5
[LLVMdev] C Compiler written in OCaml, Pointers Wanted
Hello,
For a course project, I am required to write a compiler for some language of
my choice, and this compiler has to be implemented in a functional language.
I have chosen create a *JIT* compiler for C source, and to implement my
compiler in OCaml using LLVM for the back-end. I have experience using LLVM
in C++ (I wrote a MATLAB JIT compiler not long ago), however, I am a bit
puzzled as to how
2009 Jul 24
1
[LLVMdev] setOnlyReadsMemory / setDoesNotAccessMemory
But, which optimization pass will take advantage of those flags?
As for nounwind, that means "can't throw an exception"?
- Maxime
John McCall-2 wrote:
>
> Nyx wrote:
>> Hello,
>>
>> I'm in a situation where my code is calling many native functions.
>> Sometimes, these calls are simply calls to static "accessor" methods that
>>
2009 Jun 05
2
[LLVMdev] Int1 to Double Type Conversion
Hello,
I would like to know if there is an instruction to convert values from the
Int1 type to the Double type in LLVM. I would like to achieve the equivalent
of casting a bool value to a double value in C++. Doing the simple
CreateSIToFP or CreateUIToFP does not work, it throws an assertion ("invalid
cast"). I simply want to avoid branching it's not necessary. What's the
2009 Jun 12
1
[LLVMdev] Defining/Accessing Structs Dynamically
I have most of the code working but I'm running into two issues:
1. I'm not sure exactly how to return a structure on the stack. Right now,
I'm allocating one with alloca, but it seems I can only return a pointer to
it, not the structure itself. Is there any way to dereference the pointer?
2. On the calling side, I get a structure as a return value. However, it
seems GEP is
2009 Jun 10
1
[LLVMdev] Phi Node Question
I'm designing a JIT compiler and I have a potentially problematic situation.
The functions I compile may need to create/access an object during their
execution. In the case where this object won't be needed, I'd rather avoid
generating code to creating the object, as this is a slight performance
waste. Unfortunately, it's rather difficult to know whether this will be the
case
2009 Jun 10
2
[LLVMdev] Defining/Accessing Structs Dynamically
Sorry for the high number of questions I've been posting lately!
I'm currently facing a design problem. I'm making a JIT for a subset of the
MATLAB language and in that language, functions can return many parameters.
The issue is that they will not necessarily return *all* the parameters they
could return. The actual number of returned parameters is defined at
run-time.
For speed, I
2017 Dec 30
24
[Bug 104421] New: System freeze on wayland with nouveau on NV137 (GP107)
https://bugs.freedesktop.org/show_bug.cgi?id=104421
Bug ID: 104421
Summary: System freeze on wayland with nouveau on NV137 (GP107)
Product: xorg
Version: unspecified
Hardware: Other
OS: All
Status: NEW
Severity: normal
Priority: medium
Component: Driver/nouveau
Assignee:
2009 Jun 18
1
[LLVMdev] Explicitly Freeing Allocas
I went ahead and implemented the allocation based on the maximum size of all
structs seen so far... The problem is, the TargetData object from
ExecutionEngine gives me a size of 12 for a struct containing a pointer and
an i64 (on a 32-bit machine). However, the generated code seems to assume an
alignment of 8, and tries to read the i64 value at offset 8, which obviously
reads an invalid value.
2001 Aug 14
7
Pitch shift with RC2
I've just installed RC2 and I'm very excited about the quality. It's so
much better than MP3. This is the first version I've used since I just
found out about Ogg Vorbis.
I did notice that very high frequencies seem to be missing but since not
many people can hear much above 18 KHz it's not much of an issue. I suppose
this resolves the hiss problem so prevalent in MP3.