Check-in [5dc108ae42]

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

Overview
Comment:Correct relative offset for constant pools and such being off.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 5dc108ae428658be51917e053fee10aa49bac24e
User & Date: stephanie.gawroriski 2019-04-17 01:55:17
Context
2019-04-17
07:02
Backup developer notes. check-in: 7d10eb6c2a user: squirreljme tags: trunk
01:55
Correct relative offset for constant pools and such being off. check-in: 5dc108ae42 user: stephanie.gawroriski tags: trunk
01:45
Corrections to pool writing. check-in: 8076e8f622 user: stephanie.gawroriski tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to runt/libs/tool-classfile/dev/shadowtail/classfile/mini/Minimizer.java.

144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
			__TempMethods__ tm = methods[i];
			
			__dos.writeShort(Minimizer.__checkUShort(tm._count));
		}
		
		// Relative offset where all the data will end up being, starts at
		// the constant pool address. Size is calculated as:
		// written + field headers + method headers + data areas, plus total
		// data area size and end address!
		int reloff = __dos.size() + 12 + 4 + (5 * 8) + 8,
			baserel = reloff;
		
		// Constant pool locator
		byte[] pooldata = pool.getBytes();
		__dos.writeInt(reloff);
		__dos.writeInt(pooldata.length);
		







|
<
|







144
145
146
147
148
149
150
151

152
153
154
155
156
157
158
159
			__TempMethods__ tm = methods[i];
			
			__dos.writeShort(Minimizer.__checkUShort(tm._count));
		}
		
		// Relative offset where all the data will end up being, starts at
		// the constant pool address. Size is calculated as:
		// written + pooloff/len + fieldoff/len + methodoff/len + fileoff/len

		int reloff = __dos.size() + 8 + 16 + 16 + 8,
			baserel = reloff;
		
		// Constant pool locator
		byte[] pooldata = pool.getBytes();
		__dos.writeInt(reloff);
		__dos.writeInt(pooldata.length);