5 So I made my own grep script which uses a web interface request to get every
6 single artifact that exists. Then for every artifact that is a file it will
7 cat its contents and then search within it to see what it contains. This will
8 be handy right now because I need to find some old code. Normally I would
9 use the file list, but with so many revisions it is near impossible to find.
10 There is a slow initial start because the request needs to be generated but
11 so far in tests it has worked well.
15 The stack map parser is a bit ugly, but it works. Now to continue into the
16 interpreter. Basically I will need to have some basic state verification but
17 have the code able to be ran in a way where it can be used by the verifier,
18 the JIT for code transformation, and as an actual interpreter.
22 Technically though that is not the case, the interpreter will not be using it
23 to execute the code directly at all. The interpreter as I have planned will
24 be generating a ROM from the verified byte code, which is then executed. So
25 pretty much since the later stages will use the interpreted code a bit the
26 same way, I could just spit out some optimized code. So basically just end up
27 writing the HIL in a way, but a primitive HIL. But, with everything verified
28 and the entire state of the program known for the most part, I could just
29 write the HIL to begin with and just interpret that code. I can do basic
30 handling of stack caching and such in the HIL representation, along with
31 handling of constants and such. I can handle in this case, the instructions
32 for some optimizations. Some things will be known at run-time while other
33 things will be known at compile time. Basically I will need a flag to indicate
34 if the JIT is being used. If a JIT is not enabled, then it can make those
35 special optimizations and such.
39 But for the most part, the verifier and the basic virtual machine will be
40 doing the same exact thing. Also the output of the code could generate a
41 simple HIL program that has stack caching and some optimizations. So it would
42 probably be best if `VerifiedMethod` were to contain a reference to a program
43 which could then be sent through an interpreter or other such thing. So this
44 bunch of split code and reusage would end up doing the same thing anyway. The
45 basic virtual machine would need to optimize things anyway. So basically the
46 HIL will end up being the BVM. But for the BVM I can have a rather simplisitic
47 goal. I do have the representation I want and the verification of structure
48 that I like. It would also be faster and would be better if the JIT were
49 available in the first version, since that would make it even more popular.
53 It might be best if the verifier were to infact generate some kind of program
54 and perform the byte operations only one just to get rid of them as soon as
55 possible. It would be simplest to be done this way and the instruction parser
56 would only need to be written once. It would also remove the potential
57 uglyness of the byte code due to its representation.