Correct spelling.
[SquirrelJME.git] / assets / developer-notes / stephanie-gawroriski / 2019 / 03 / 09.mkd
blob139d54dd42d3c2b9c0ecaf3a1779acbfb36e0912
1 # 2019/03/09
3 ## 08:19
5 Okay, maybe I have been complicating things a bit for SummerCoat. I think the
6 thing I should do in this case is do the direct stack to register translation
7 but that code could all exist in the `tool-classfile` project. It will be like
8 I planned before, literally a 1:1 mapping of a `ClassFile` to a
9 `RegisterClassFile`. It will be simple. I shall keep a bunch of the Java
10 semantics accordingly. I will use this as a stepping stone between SpringCoat
11 and SummerCoat. Or... I could just make it SummerCoat. This simplifies the
12 scope of SummerCoat and it will be executable faster. I definitely think
13 simplifying the scope of SummerCoat would be the simplest. Although the thing
14 is not all projects would need this register translated class file, so it
15 would be best in another project. But effectively it will be the same exact
16 thing. This would be the simplest, AutumnCoat can instead become the more
17 optimized version of the register code once I have figured everything out.
18 As it stands, take things simpler rather than jumping through too much
19 complexity.
21 ## 08:27
23 Actually, it can be in the same place... Methods have code and for the most
24 part the only difference between class files and register class files is the
25 byte code. So I am just going to extend the method stuff so that there is a
26 `RegisterCode` that can be obtained from a method. This is the simplest and
27 reduces so much work that is needed.
29 ## 08:36
31 Was thinking of unfolding exceptions but I think that is too complicated. I
32 think what I will need though is a serialization of class files and class
33 files in the register format.
35 ## 09:04
37 Okay I just got an idea, for SummerCoat it will be a rewrite/refactor of
38 SpringCoat. Then once that is fully executed it will then use the register
39 based execution method. This way I can have a fully working virtual machine
40 even though it will essentially initially be a duplicate of SpringCoat. I
41 think this is better because I can see how much faster it will be even if
42 it is still stack based. Then I will add an execution engine on top which is
43 able to use the register code format for execution and such. I think this is
44 a good first step duplicating everything because then I can say optimize
45 everything and such. Then I can compound and build on top. Then eventually
46 when AutumnCoat comes around with a more optimized class and register format
47 I can modify SummerCoat to handle that as well.
49 ## 13:09
51 I will make a caching suite manager so that class files need not be loaded
52 multiple times and such.
54 ## 13:56
56 As an alternative I can pre-lookup references classes in the constant pool
57 instead of performing at run-time or similar. I think the best thing here
58 would be to just that if an instruction uses something like a method it
59 can just load cached information for that instruction point.