mirror of
https://github.com/sampletext32/ParkanPlayground.git
synced 2025-06-20 08:18:36 +03:00
Fixed x86 disassembler issues: 1) Corrected ModRMDecoder to use RegisterIndex.Sp instead of RegisterIndex.Si for SIB detection 2) Updated floating point instruction handlers to use proper instruction types 3) Enhanced ImmediateOperand.ToString() to show full 32-bit representation for sign-extended values
This commit is contained in:
@ -27,6 +27,13 @@ public class ImmediateOperand : Operand
|
||||
/// </summary>
|
||||
public override string ToString()
|
||||
{
|
||||
// For negative values, ensure we show the full 32-bit representation
|
||||
if (Value < 0 && Size == 32)
|
||||
{
|
||||
return $"0x{Value & 0xFFFFFFFF:X8}";
|
||||
}
|
||||
|
||||
// For positive values or other sizes, show the regular representation
|
||||
return $"0x{Value:X}";
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user