Commit Graph

173 Commits

Author SHA1 Message Date
Torsten Ruger
303b7eb1f8 putstring unfolds length
which means sys call doesn’t need to
and also interpreter sometimes gets a symbol length
2015-11-16 18:03:29 +02:00
Torsten Ruger
f50d7b57a4 fix the putstring sys call indexing
index 0 is the marker word , so like in some, all indexes 1 based
works :-)
2015-11-15 22:03:06 +02:00
Torsten Ruger
8e82da0b61 fix arm (assembled) indexing
by having a dummy 0 index in salaam. when assembled
2015-11-15 20:42:07 +02:00
Torsten Ruger
458610b970 implement string length 2015-11-15 11:28:16 +02:00
Torsten Ruger
b30cf21bbd fix arm indexes
needs rethought
fixed for static use, but what about dynamic
2015-11-15 00:35:12 +02:00
Torsten Ruger
6127d92ca9 implement arm branches
which backfired into interpreter as
plus actually means 0 or plus in arm
may still change back but for now
2015-11-14 00:20:03 +02:00
Torsten Ruger
6f0d6d831e update arm and implement most operators
multiplication wasn’t implemented
and division isn’t part if arm
neither is rotate by register
2015-11-12 20:02:14 +02:00
Torsten Ruger
c38775e933 add set_internal
and the set_slot with register
very much like the get_slot for get_internal
2015-11-08 17:10:36 +02:00
Torsten Ruger
484e2d19d4 allow for registers in get slot 2015-11-07 19:38:03 +02:00
Torsten Ruger
c15445a958 let labels be constants 2015-11-03 16:20:25 +02:00
Torsten Ruger
3774f8a5a2 use translator and remove passes
the only passes that were left were reg -> arm
those are almost completely one to one, so the idea of passes didn’t fit
2015-10-24 17:11:18 +03:00
Torsten Ruger
a871f96630 remove passes and achieve the same by translating 2015-10-24 11:42:36 +03:00
Torsten Ruger
f4f703975b removed arm and use as gem 2015-07-18 14:12:20 +03:00
Torsten Ruger
e1c19dee80 remove old to_asm
very strange that is was called in 1.9 but not 2.0
2.0 seems to delay interpolating strings
2015-07-18 12:15:07 +03:00
Torsten Ruger
f5136b6b68 minor formatting 2015-07-18 11:52:30 +03:00
Torsten Ruger
50da6a40f2 Move the Main instruction from register to virtual
also needs a branch in register.
This way the register level is self sufficient
(noticed while writing debugger)
2015-07-17 13:21:57 +03:00
Torsten Ruger
b670e058a9 fixes to get opal to work
opal has bug with << and |=, but changing syntax works
2015-07-12 10:01:45 +03:00
Torsten Ruger
b61c73acdd renamed info to MethodSource 2015-07-03 20:13:03 +03:00
Torsten Ruger
e959c5b0f5 fixed wrong exit code
no wonder it was set faulting, duh
2015-07-02 13:50:13 +03:00
Torsten Ruger
3195d800e9 fix putstring file descriptor 2015-07-02 09:49:52 +03:00
Torsten Ruger
1b791dc0d0 putstring was missing the steam id 2015-07-01 21:42:59 +03:00
Torsten Ruger
047c77e186 fixed that darn method address bug 2015-07-01 09:47:10 +03:00
Torsten Ruger
9541712af8 fixing all the indexes
with the type word and layout
but the list starting at 1, indexes still need 1 added
and for arm x 4.
Tried to get all that into one function, resolve_index
2015-06-30 18:38:56 +03:00
Torsten Ruger
88f45cbf15 weird 4 to add for call works 2015-06-30 18:36:57 +03:00
Torsten Ruger
553f30c874 more ripples from removing index constants 2015-06-29 20:58:06 +03:00
Torsten Ruger
31635d9747 fixing index issues 2015-06-28 22:01:13 +03:00
Torsten Ruger
99b59d920c constant fixes 2015-06-28 10:52:02 +03:00
Torsten Ruger
a00a49ecdb fix frame indexes 2015-06-28 10:50:47 +03:00
Torsten Ruger
ef42abe611 unifying register comstants
were in several files with different names
many files touched, but just renames
2015-06-27 21:16:46 +03:00
Torsten Ruger
97b4c469f8 fixing register order in some instructions
and their use
Arm is confusing as it has result as first arg
we use forward logic, i.e. from -> to
2015-06-27 20:09:21 +03:00
Torsten Ruger
294ea8de4f fix the move, correct for funny pipeline 2015-06-27 20:07:42 +03:00
Torsten Ruger
d0d857bbe0 fix object loading
by (ahem) copying the code from MoveInst.
2015-06-26 20:36:00 +03:00
Torsten Ruger
55b7ca83e1 fixing load constant
which needs to add to pc to get an object reference
2015-06-26 20:01:52 +03:00
Torsten Ruger
108cc8af45 minor cleanup 2015-06-26 20:00:50 +03:00
Torsten Ruger
37403f1139 fix misunderstood mov usage
When moving a reference (pointer) to a register
one needs to ADD to the pc
i.e. one needs an add, not mov instruction
2015-06-26 20:00:33 +03:00
Torsten Ruger
32e1903884 finished init routine
and better implemented sys calls
2015-06-25 16:31:09 +03:00
Torsten Ruger
cedc6e1b61 Fix parfait bug for word_length 2015-06-24 16:08:06 +03:00
Torsten Ruger
59188105ba finish syscall
works, even had to fix parfait bug to see
2015-06-24 16:07:27 +03:00
Torsten Ruger
1a82ebcd69 mor on sys call implementation 2015-06-23 19:55:54 +03:00
Torsten Ruger
d8fa266b5d fix method call addresses
was jumping to the method
but needs to jump to the code of the method
2015-06-10 11:10:46 +02:00
Torsten Ruger
6f111a5ae0 fix the initial jump 2015-06-10 10:43:50 +02:00
Torsten Ruger
1c29fcfd43 mem_length to word/byte length
be more specific, and don’t include padding
2015-06-05 09:20:43 +03:00
Torsten Ruger
5726d2c181 move machine to module level
makes for shorter, more concise, access
also remove one more bug possibility
(reinitiation)
2015-06-01 08:40:17 +03:00
Torsten Ruger
336e6c18de register reference creation got more complicated 2015-06-01 08:34:17 +03:00
Torsten Ruger
e651b57d08 homing in on line length 100 2015-05-30 12:20:39 +03:00
Torsten Ruger
33d464f032 minor 2015-05-30 11:56:47 +03:00
Torsten Ruger
3e9e650764 fix arm tests 2015-05-29 12:47:49 +03:00
Torsten Ruger
a46b2d5c56 update to use parfait not virtual
more ripples
reverting to integers (not virtual::integer)
2015-05-29 12:33:40 +03:00
Torsten Ruger
2ccbea04b9 fixing assembly
position code changed and linking too
passes not working
2015-05-24 18:05:20 +03:00
Torsten Ruger
422ec64105 all green
That fixes all existing tests. Operation successful

Off course there is tests missing :-(
2015-05-20 17:29:08 +03:00