J'ai besoin de créer une extension de MAL. Alors, tout d'abord j'avais essayé d'ajouter sur mic1sim.malComment créer un IUSHR4 sur IJVM?
MAR = SP = SP + 1; rd // read top of the stack
H = TOS // H will be a SP
MDR = H = H >> 1; wr // SHIFT 1 and write on MDR
MDR = H = H >> 1; wr // SHIFT 1 + 1 = 2
MDR = H = H >> 1; wr // SHIFT 1 + 1 + 1 = 3
MDR = H = H >> 1: wr // 4th shift
TOS = MDR; goto Main1 // TOS updated
Mais ne fonctionne pas! Quelqu'un peut-il m'expliquer où je me trompe? SP pointe vers le haut de la pile.