Going to need some kind of operational logic that a program uses so that things are done for example. The interpreter and compiler could use those logical bits to perform actual actions and such.


Can do better with variable storage.


Actually when it comes to the interpreter, I will need the method code to actually perform the execution. I have to do this because for example during class initialization I will have to jump into the guest virtual machine to initialize objects as they appear in the guest. My current thread based stuff sort of works, but no quite as much. So basically what I have in the thread stuff now will be changed over. When a guest method goes to invoke another guest method it will just perform the same logic and such on the destination method.


A work around is needed for Class. I will need to note this in the future when native code is generated. Since every object references a class for the getClass() method, on initialization the Class object's initialized object would not exist at all. Thus a minor work around is needed so that it exists and can be used for example.


What I need now is to interpret the class constructor, which would be very important.


Going to need classes for the primitive types.


I suppose I can do the same thing as I did before, by using an interface and implementations of that so that logicals may be created and returned based on the instruction used. However, there are going to be logicals for instructions which are exactly the same. Right now, my logicals are planned to be sub-things based on the byte code. However that might not actually be needed at all. Well really my plan for logicals was for it to be stuff such as add, subtract, and other things with variables. What is really just needed is an abstract class of sorts which wraps operation handlers for input and output. I could also possibly have a kind of abstract computation machine so that when operations are called, the actual codes can be generated and such. So basically remove logicals and just have operation handlers that I had similarly before. However instead of a list of operations to perform, there is instead a logical machine of sorts which operates on something. I would need to pass an argument back and forth so that way I do not have to create a few thousand objects for each instruction to be executed. So basically it would look like this:

public interface CPComputeMachine<P>
	public abstract void add(P __pass, ? __dest, ? __a, ? __b);

CPOp.<P>compute(CPComputeMachine<P> __p, P __pass);

This compute machine would be able to be used by later operations to set the variable states without performing an actual work. The method I listed above would essentially just perform the actual operation work and handle calling into the compute machine with the given object. Then I just need one compute machine implemented for the inetrpreter. The compiler would also use the compute machine to perform any intermediary work between operations. I would support currently my compute machine would not be as optimizing (just not performing wasteful stack moving operations) as I intend it to be in the future currently. However, if the backend calling into the compute machine becomes optimized (such as compacting adds and removing useless operations) then the interpreter and compiler should remain untouched for the most part.


What I need however is a class which acts as an ideal type of variable reference. I suppose just integer variable references could do. At least to the interpreter it will have the feeling of being given the local variable IDs to do stuff on, while for the compiler this would be virtual registers. So yes, the integer would just be the register for the most part. It would not be precisely SSA at least as seen by the interpreter and compiler though. However, any optimizations would be done by the program layout itself which may use SSA or not. The only thing that is really needed is that the execution layer is called with the right logical code.


Accidently lost some of my notes. However they were just a few sentences on the my idea and a creation of an index for the blog. Actually the only thing I really lost was my idea of having an index.mkd for the blogs so they can be indexed and I can have that info there. Luckily though my paragraph before this I had an open web browser seeing what I wrote which is nice.


I can also setup a manual too which contains the needed operations and such for how to build and run the stuff.