diff options
| author | Fabrice Desclaux <fabrice.desclaux@cea.fr> | 2014-09-15 09:37:01 +0200 |
|---|---|---|
| committer | Fabrice Desclaux <fabrice.desclaux@cea.fr> | 2014-09-15 09:37:01 +0200 |
| commit | d3bffc301e74c5d85bf25426fc691a147373cbae (patch) | |
| tree | ed38343c5f9839b72d8b7540ea25c0a1708fcb7f | |
| parent | 508f4de6b55d731d72c0fed98d84413c365c9054 (diff) | |
| download | miasm-d3bffc301e74c5d85bf25426fc691a147373cbae.tar.gz miasm-d3bffc301e74c5d85bf25426fc691a147373cbae.zip | |
mips: add ei/ehb (dummy semantic)
| -rw-r--r-- | miasm2/arch/mips32/arch.py | 1 | ||||
| -rw-r--r-- | miasm2/arch/mips32/sem.py | 12 | ||||
| -rw-r--r-- | test/arch/mips32/arch.py | 2 |
3 files changed, 15 insertions, 0 deletions
diff --git a/miasm2/arch/mips32/arch.py b/miasm2/arch/mips32/arch.py index 19f8b26f..8a49c4f8 100644 --- a/miasm2/arch/mips32/arch.py +++ b/miasm2/arch/mips32/arch.py @@ -691,6 +691,7 @@ mips32op("seb", [bs('011111'), bs('00000'), rt, rd, bs('10000'), bs('100000' mips32op("wsbh", [bs('011111'), bs('00000'), rt, rd, bs('00010'), bs('100000')], [rd, rt]) mips32op("di", [bs('010000'), bs('01011'), rt, bs('01100'), bs('00000'), bs('0'), bs('00'), bs('000')]) +mips32op("ei", [bs('010000'), bs('01011'), rt, bs('01100'), bs('00000'), bs('1'), bs('00'), bs('000')]) mips32op("tlbp", [bs('010000'), bs('1'), bs('0'*19), bs('001000')]) diff --git a/miasm2/arch/mips32/sem.py b/miasm2/arch/mips32/sem.py index cc51d2af..f6445070 100644 --- a/miasm2/arch/mips32/sem.py +++ b/miasm2/arch/mips32/sem.py @@ -413,6 +413,14 @@ def mflo(ir, instr, a): e.append(ExprAff(a, R_LO)) return e, [] +def di(ir, instr, a): + return [], [] + +def ei(ir, instr, a): + return [], [] + +def ehb(ir, instr, a): + return [], [] mnemo_func = { "addiu": addiu, @@ -490,6 +498,10 @@ mnemo_func = { "mfhi" : mfhi, "mflo" : mflo, + "di" : di, + "ei" : ei, + "ehb" : ehb, + } def get_mnemo_expr(ir, instr, *args): diff --git a/test/arch/mips32/arch.py b/test/arch/mips32/arch.py index 2f1f5821..8ecb0a5a 100644 --- a/test/arch/mips32/arch.py +++ b/test/arch/mips32/arch.py @@ -194,6 +194,8 @@ reg_tests_mips32 = [ "7C02B420"), ("8BA0F468 DI ZERO", "41606000"), + ("XXXXXXXX EI ZERO", + "41606020"), ("8BA0F78C WSBH V1, V1", "7C0318A0"), ("8BA0F790 ROTR V1, V1, 0x10", |