Skip to content

Commit

Permalink
Fix: unsaved changes.
Browse files Browse the repository at this point in the history
  • Loading branch information
uxmal committed Nov 8, 2024
1 parent 0f3d16d commit ee5d257
Show file tree
Hide file tree
Showing 10 changed files with 871 additions and 888 deletions.
6 changes: 6 additions & 0 deletions src/Arch/M16C/M16CDisassembler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -668,6 +668,12 @@ private static Mutator<M16CDisassembler> op4(int bitPos)
return dsp8_sb(u, d);
case 11: // signed dsp8[fb]
return dsp8_fb(u, d);
case 12:
return dsp16_a0(u, d);
case 13:
return dsp16_a1(u, d);
case 14:
return dsp16_sb(u, d);
default:
return abs16(u, d);
}
Expand Down
26 changes: 12 additions & 14 deletions src/UnitTests/Arch/M16C/M16CDisassemblerTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@ public M16CDisassemblerTests()
{
this.arch = new M16CArchitecture(CreateServiceContainer(), "m16c", new());
this.addr = Address.Ptr16(0x100);
Reko.Core.Machine.Decoder.trace.Level = System.Diagnostics.TraceLevel.Verbose;
}

public override IProcessorArchitecture Architecture => arch;
Expand Down Expand Up @@ -105,16 +104,16 @@ public void M16cDis_add_b_s_imm()
}

[Test]
public void M16dasm_add_b_g()
public void M16cDasm_add_b_g()
{
AssertCode("add.b\t1234[a0],5678[a1]", "A0CD34127856");
AssertCode("add.b\t1234h[a0],5678h[a1]", "A0CD34127856");
}

[Test]
public void M16dasm_add_b_s_reg()
public void M16cDasm_add_b_s_reg()
{
AssertCode("add.b:s\t", "20");
AssertCode("add.b:s\t", "24");
AssertCode("add.b:s\tr0h,r0l", "20");
AssertCode("add.b:s\tr0l,r0h", "24");
}

[Test]
Expand Down Expand Up @@ -210,28 +209,27 @@ public void M16cDasm_bset()
}

[Test]
public void M16Dasm_cmp()
public void M16cDasm_cmp()
{
AssertCode("cmp.w\t#1h,r0", "C042");

AssertCode("cmp.b\ta0,r1l", "C042");
}

[Test]
public void M16Dasm_cmp_q_imm()
public void M16cDasm_cmp_q_imm()
{
AssertCode("cmp.w:q\t#1h,r0", "D110");
}

[Test]
public void M16Dasm_cmp_imm()
public void M16cDasm_cmp_imm()
{
AssertCode("cmp.w:q\t#41h,[043Ch]", "778F3C0441");
AssertCode("cmp.w\t#41h,[43Ch]", "778F3C044100");
}

[Test]
public void M16Dasm_cmp_b_s_imm()
public void M16cDasm_cmp_b_s_imm()
{
AssertCode("cmp.b:s\t#41h,[043Ch]", "E380");
AssertCode("cmp.b:s\t#80h,r0h", "E380");
}

[Test]
Expand Down
5 changes: 3 additions & 2 deletions src/UnitTests/Arch/M16C/M16CRewriterTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -317,8 +317,9 @@ public void M16cRw_ldc()
{
Given_HexString("EB400045");
AssertCode( // ldc #4500h,isp
"0|L--|000F820F(4): 1 instructions",
"1|L--|isp = 0x4500<16>");
"0|L--|00000100(4): 2 instructions",
"1|L--|isp = 0x4500<16>",
"2|L--|SZ = cond(0x4500<16>)");
}

[Test]
Expand Down
11 changes: 0 additions & 11 deletions subjects/PE/m68k/hello_m68k_PE_header.c

This file was deleted.

13 changes: 0 additions & 13 deletions subjects/PE/m68k/hello_m68k_PE_header.dis

This file was deleted.

106 changes: 53 additions & 53 deletions subjects/Raw/M16C/ThrottleControl.reko/ThrottleControl.globals.c

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit ee5d257

Please sign in to comment.