[llvm-commits] [llvm] [PATCH] Mips JIT implementation

Bruno Cardoso Lopes bruno.cardoso at gmail.com
Thu Jul 21 09:31:27 PDT 2011


Hi Vladimir,
Sorry again for the late reply.

> thanks a lot for the review.
> Here's the modified version, with emitInstruction relying on TSFlags.

I commited the first chunk in r135678. We still need to improve the
TSFlags part before integrating. Here are a couple of things:

1) There's no need to add this amount of bits for the TSFlags. We
should heavily rely on auto-generated stuff. So, the first step is to
get automatic encoding from getBinaryCodeForInstr(MI). If you apply
the attached mips00.patch, you will make llvm autogenerate several
encoding functions, and to use it all you need is to include the .inc
file in the end of MipsCodeEmitter.cpp (see ARM for details). It's
important that we go this path because we want a really easy migration
to the MC JIT later, so is important that we handle as much as
possible of the encoding in the tablegen files. When you apply this
patch, it will break tblgen, so you need to find out what is going
wrong with the actual descriptions in the first place.

2) After doing that, you will need more bits in TSFlags to describe
additional stuff, to do that, follow the style and enum as in
mips01.patch, don't apply this patch, it's just an example of how to
do stuff.

3) After 1) let's work in small pieces, in the following patches, send
only the JIT handling for class FR for example, easier to review, and
will apply and get feedback to you faster. And then we move to the
next patch! Mips is simple enough that the implementation should be
easy to understand.

Thanks again for working on this,

-- 
Bruno Cardoso Lopes
http://www.brunocardoso.cc
-------------- next part --------------
A non-text attachment was scrubbed...
Name: mips00.patch
Type: application/octet-stream
Size: 811 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20110721/5dbb63ba/attachment.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: mips01.patch
Type: application/octet-stream
Size: 10653 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20110721/5dbb63ba/attachment-0001.obj>


More information about the llvm-commits mailing list