Browse Source

m68k 'not' op fix

mntmn 8 years ago
parent
commit
0f34747d79
5 changed files with 11 additions and 5 deletions
  1. BIN
      build/interim.bin
  2. 3 0
      notes/m68k-ops.s
  3. 0 2
      sledge/alloc.c
  4. 5 0
      sledge/jit_m68k.c
  5. 3 3
      sledge/os/shell.l

BIN
build/interim.bin


+ 3 - 0
m68k-ops.s → notes/m68k-ops.s

@@ -40,6 +40,9 @@ add.l d0, d1
 add.l d2, d3
 and.l d0, d1
 or.l d0, d1
+not.l d0
+not.l d1
+not.l d2
 eor.l d0, d0
 eor.l d0, d1
 eor.l d0, d2

+ 0 - 2
sledge/alloc.c

@@ -1,6 +1,4 @@
 #include "alloc.h"
-#include <stdlib.h>
-#include <stdint.h>
 #include <string.h>
 #include "stream.h"
 

+ 5 - 0
sledge/jit_m68k.c

@@ -226,6 +226,11 @@ void jit_andr(int dreg, int sreg) {
   code[code_idx++] = 0x80|regi[sreg];
 }
 
+void jit_notr(int dreg) {
+  code[code_idx++] = 0x46;
+  code[code_idx++] = 0x80|regi[dreg];
+}
+
 void jit_orr(int dreg, int sreg) {
   code[code_idx++] = 0x80|regi[dreg]<<1;
   code[code_idx++] = 0x80|regi[sreg];

+ 3 - 3
sledge/os/shell.l

@@ -117,9 +117,9 @@
   (line (pt (+ ox 208) (- oy 102)) (pt (+ ox 272) (- oy 102)))
 )))
 
-(draw-logo (- (/ screen-width 2) 100) (/ screen-height 2))
-(draw-logo (- (/ screen-width 2) 99) (/ screen-height 2))
-(send scr 0)
+(draw-logo (- (/ screen-width 2) 140) (/ screen-height 2))
+(draw-logo (- (/ screen-width 2) 139) (/ screen-height 2))
+(draw-logo (- (/ screen-width 2) 140) (+ 1 (/ screen-height 2)))
 
 (def f (open "/sd/unifont.bin"))
 (def unifont (recv f))