Check-in [29f98c01b8]

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Minor work.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1:29f98c01b8b7c1105f49eff7bcd16692bbc2e4e1
User & Date: stephanie.gawroriski 2019-02-05 20:57:19
Context
2019-02-06
00:28
Minor work on cleanup. check-in: ae01fc3475 user: stephanie.gawroriski tags: trunk
2019-02-05
20:57
Minor work. check-in: 29f98c01b8 user: stephanie.gawroriski tags: trunk
20:39
Corrections to compilation. check-in: a8dff38e8b user: stephanie.gawroriski tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to runt/libs/tool-classfile-scrf-compiler/net/multiphasicapps/scrf/compiler/PrimitiveByteCodeProcessor.java.

89
90
91
92
93
94
95

96
97
98
99
100
101
102
103
104
...
143
144
145
146
147
148
149





150
151
152
153
154
155
156
	public RegisterCode process()
		throws ClassProcessException
	{
		ByteCode input = this.input;
		StackMapTable smt = this.smt;
		RegisterSet registers = this.registers;
		RegisterCodeBuilder cb = this.codebuilder;

		
		// If this is synchronized, we enter the monitor explicitely here
		boolean issync = this.methodprocessor.input.flags().isSynchronized();
		if (issync)
			throw new todo.TODO();
		
		// Process byte codes
		for (int vi = 0, vin = input.instructionCount(); vi < vin; vi++)
		{
................................................................................
					
					// Load static field
				case InstructionIndex.GETSTATIC:
					FieldReference sfr = inst.<FieldReference>argument(0,
						FieldReference.class);
					if (true)
						throw new todo.TODO();





					break;
				
					// Nop
				case InstructionIndex.NOP:
					cb.addNop();
					break;
					







>

|







 







>
>
>
>
>







89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
...
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
	public RegisterCode process()
		throws ClassProcessException
	{
		ByteCode input = this.input;
		StackMapTable smt = this.smt;
		RegisterSet registers = this.registers;
		RegisterCodeBuilder cb = this.codebuilder;
		VTableBuilder vtable = this.vtable;
		
		// If this is synchronized, we enter the monitor explicitly here
		boolean issync = this.methodprocessor.input.flags().isSynchronized();
		if (issync)
			throw new todo.TODO();
		
		// Process byte codes
		for (int vi = 0, vin = input.instructionCount(); vi < vin; vi++)
		{
................................................................................
					
					// Load static field
				case InstructionIndex.GETSTATIC:
					FieldReference sfr = inst.<FieldReference>argument(0,
						FieldReference.class);
					if (true)
						throw new todo.TODO();
					/*
					cb.addLoad(???, vtable., registers.virtualPush());
					MemoryType __t, MemorySource __from, int __to)
					if (true)
						throw new todo.TODO();*/
					break;
				
					// Nop
				case InstructionIndex.NOP:
					cb.addNop();
					break;
					

Changes to runt/libs/tool-classfile-scrf-compiler/net/multiphasicapps/scrf/compiler/RegisterSet.java.

89
90
91
92
93
94
95





















96
97
98
99
100
101
102
	 * @return The index of the entry that was pushed to the stack.
	 * @throws IllegalStateException If the stack overflows.
	 * @since 2019/01/23
	 */
	public final int virtualPush()
		throws IllegalStateException
	{





















		// The old top is 
		int vstackptr = this._vstackptr;
		
		// {@squirreljme.error AT03 Stack overflow.}
		int next = vstackptr + 1;
		if (next >= this.vstacklimit)
			throw new IllegalStateException("AT03");







>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>







89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
	 * @return The index of the entry that was pushed to the stack.
	 * @throws IllegalStateException If the stack overflows.
	 * @since 2019/01/23
	 */
	public final int virtualPush()
		throws IllegalStateException
	{
		return this.virtualPush(1);
	}
	
	/**
	 * Virtual push to the stack, multiple values can be pushed at once.
	 *
	 * @param __n The number of entries to push.
	 * @return The index of the first entry which was pushed.
	 * @throws IllegalArgumentException If the count to push is zero or
	 * negative.
	 * @throws IllegalStateException If the stack overflows.
	 * @since 2019/02/05
	 */
	public final int virtualPush(int __n)
		throws IllegalArgumentException, IllegalStateException
	{
		// {@squirreljme.error AT04 Cannot push a negative number of
		// registers.}
		if (__n <= 0)
			throw new IllegalArgumentException("AT04");
		
		// The old top is 
		int vstackptr = this._vstackptr;
		
		// {@squirreljme.error AT03 Stack overflow.}
		int next = vstackptr + 1;
		if (next >= this.vstacklimit)
			throw new IllegalStateException("AT03");