[LLVMdev] Function calls only being JIT'd once by Kaleidoscope with MCJIT?

David Blaikie dblaikie at gmail.com
Tue Apr 21 15:11:56 PDT 2015


On Tue, Apr 21, 2015 at 3:07 PM, Lang Hames <lhames at gmail.com> wrote:
> No progress since Charlie last looked at it.

Sorry, I meant to refer to the issue Per Mildner mentioned regarding
the tutorials not building due to RTTI - which I recall discussing
with you & Eric, but don't know what came of it.

> As Per suggested, it may be
> worth adding an explicit #error, or at least a comment, noting that the
> later examples are broken.
>
> Going forward, I see three options:
>
> (1) Remove the old tutorials entirely, and encourage people to check out the
> MCJIT and Orc versions.
> (2) Build an Orc-based stack that approximates the behavior of the Old JIT
> (which the old tutorials assume).
> (3) Rewrite the old tutorial to natively use the new APIs.
>
> I much prefer the third option. The first option misses out on a lot of
> language/API discussion that's contained in the later chapters of the old
> tutorials. The second option replicates a JIT stack that wouldn't be useful
> for most clients.
>
> If we were going to pursue option three, the simple JIT from the Orc/initial
> tutorial seems like a good starting point to re-write the old tutorials.
> Then we'd have an interesting bifurcation part way through the tutorial
> series: Go one way and add new language features on top of the simple JIT,
> or go another and add features to the JIT while keeping the language steady.
> Cross-polination of the two branches (new JIT features + new language
> features) could be handled in future tutorials, or left as an exercise for
> the reader.
>
> The tricky part, as usual, is finding the time to do this.
> Volunteers/patches welcome. :)
>
> Cheers,
> Lang.
>
>
> On Tue, Apr 21, 2015 at 9:16 AM, David Blaikie <dblaikie at gmail.com> wrote:
>>
>>
>>
>> On Tue, Apr 21, 2015 at 7:26 AM, Per Mildner <Per.Mildner at sics.se> wrote:
>>>
>>> Charlie Turner <charlesturner7c5 <at> gmail.com> writes:
>>>
>>> > I was planning on committing these changes with the corresponding
>>> > changes to the Kaleidoscope tutorial walk-through. Might be a bit of a
>>> > surprise to have no explanation of what MCJITHelper and friends is
>>> > doing.
>>> >
>>> > I'll try and make time to prepare some patches along these lines, as
>>> > well as updating future chapters with the same fix.
>>> >
>>> > Thanks for taking a look :)
>>>
>>>
>>> Any progress on fixing the tutorial?
>>>
>>> I am about to dive into LLVM and after some hair-pulling found that the
>>> Kaleidoscope tutorials (from part 5 onwards), are broken.
>>>
>>> Obviously this is not a good first impression.
>>>
>>> (even a note in the source code, #error "currently does not work", would
>>> be
>>> a huge improvement, since it would avoid a lot of wasted time for the
>>> beginner.)
>>>
>>> PS. On OS X 10.8.5, the compile command for part 4 of the tutorial needs
>>> -fno-rtti, presumably because the code now inherits from a LLVM class.
>>
>>
>> Lang - recall what the state is here?
>>
>>>
>>>
>>> Regards,
>>>
>>> Per Mildner
>>>
>>>
>>> _______________________________________________
>>> LLVM Developers mailing list
>>> LLVMdev at cs.uiuc.edu         http://llvm.cs.uiuc.edu
>>> http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev
>>
>>
>



More information about the llvm-dev mailing list