Forum > Debugger

FpDebug, small x86 disassembler bug

(1/2) > >>

mika:

--- Code: Pascal  [+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i < x.length; i++) { x[i].style.maxHeight='none'; x[i].style.height = Math.min(x[i].clientHeight+15,306)+'px'; x[i].style.resize = "vertical";}};} ---program testdbg18;{$apptype console}{$mode objfpc}{$h+} uses FpDbgDisasX86, FpDbgClasses, FpDbgUtil; const  testCode : shortstring = #$a3#$1a#$00#$00#$00; {mov [$0000001a],eax} var    p : pointer  ;       codeBytes, asmInstr : string;       pr : TDbgProcess;       de : TX86AsmDecoder; begin     pr:= TDbgProcess.create(dm32);     de := TX86AsmDecoder.create( pr );     p:=@testCode[1];     de.Disassemble(p, codeBytes, asmInstr );     writeln;     writeln( codeBytes:20,'    ', asmInstr);     readln;end.
output
          A31A000000    mov dword ptr [$0000001A],al

output should be
          A31A000000    mov [$0000001A],eax

file fpdbgdisasx86.pas


--- Code: Pascal  [+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i < x.length; i++) { x[i].style.maxHeight='none'; x[i].style.height = Math.min(x[i].clientHeight+15,306)+'px'; x[i].style.resize = "vertical";}};} ---      $A3: begin        SetOpcode(OPmov);        AddOv;        AddReg(regGeneral, os8, REG_A); 
fix


--- Code: Pascal  [+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i < x.length; i++) { x[i].style.maxHeight='none'; x[i].style.height = Math.min(x[i].clientHeight+15,306)+'px'; x[i].style.resize = "vertical";}};} ---      $A3: begin        SetOpcode(OPmov);        AddOv;        AddReg(regGeneral, OperandSize, REG_A); 

PascalDragon:
Please report on the bug tracker.

mika:

--- Quote from: PascalDragon on November 30, 2022, 10:19:21 pm ---Please report on the bug tracker.

--- End quote ---
Not registered there. Not going to report.
Your suggestion i will take as a hint to not report bugs in forum.
But if some one is going to investigate this, then look at lds,les,.. instructions with operand and address size modifiers.

Martin_fr:

--- Quote from: mika on November 30, 2022, 11:47:14 pm ---
--- Quote from: PascalDragon on November 30, 2022, 10:19:21 pm ---Please report on the bug tracker.

--- End quote ---
Not registered there. Not going to report.
Your suggestion i will take as a hint to not report bugs in forum.
But if some one is going to investigate this, then look at lds,les,.. instructions with operand and address size modifiers.

--- End quote ---

You can mention bugs here. Sometimes they will be spotted. And then it's a question if they will be remembered.
For now, I noted this one. Hopefully it wont fall through the cracks....

The bug tracker makes sure it will be remembered.

Martin_fr:
Fixed

Navigation

[0] Message Index

[#] Next page

Go to full version