lundi 11 novembre 2019

Mips how to count unique numbers in an integer

Hello I need help translating this line of C code to MIPS. Below I used the "and" operator and "bne" but for some reason my output for MIPS does not match my output for the C code

C code:

    if(!(store& digit))

MIPS code:

    #$t7 = store& digit
    and $t7, $t7, $t8

    #!(store& digit)
    bne $t7, 0, ExitIf

Aucun commentaire:

Enregistrer un commentaire