@@ -32,7 +32,7 @@ internal static void Main(string[] args) {
32
32
Program . ShowArm ( DisassembleMode . Arm32 ) ;
33
33
break ;
34
34
case "ARM32-V8" :
35
- Program . ShowArm ( ( int ) DisassembleMode . Arm32 + DisassembleMode . ArmV8 ) ;
35
+ Program . ShowArm ( ( int ) DisassembleMode . Arm32 + DisassembleMode . ArmV8 ) ;
36
36
break ;
37
37
case "ARM32-Thumb" :
38
38
Program . ShowArm ( DisassembleMode . ArmThumb ) ;
@@ -74,16 +74,16 @@ internal static void ShowArm(DisassembleMode mode) {
74
74
var code = new byte [ 0 ] ;
75
75
switch ( mode ) {
76
76
case DisassembleMode . Arm32 :
77
- code = new byte [ ] { 0xED , 0xFF , 0xFF , 0xEB , 0x04 , 0xe0 , 0x2d , 0xe5 , 0x00 , 0x00 , 0x00 , 0x00 , 0xe0 , 0x83 , 0x22 , 0xe5 , 0xf1 , 0x02 , 0x03 , 0x0e , 0x00 , 0x00 , 0xa0 , 0xe3 , 0x02 , 0x30 , 0xc1 , 0xe7 , 0x00 , 0x00 , 0x53 , 0xe3 , 0x00 , 0x02 , 0x01 , 0xf1 , 0x05 , 0x40 , 0xd0 , 0xe8 , 0xf4 , 0x80 , 0x00 , 0x00 } ;
77
+ code = new byte [ ] { 0xED , 0xFF , 0xFF , 0xEB , 0x04 , 0xe0 , 0x2d , 0xe5 , 0x00 , 0x00 , 0x00 , 0x00 , 0xe0 , 0x83 , 0x22 , 0xe5 , 0xf1 , 0x02 , 0x03 , 0x0e , 0x00 , 0x00 , 0xa0 , 0xe3 , 0x02 , 0x30 , 0xc1 , 0xe7 , 0x00 , 0x00 , 0x53 , 0xe3 , 0x00 , 0x02 , 0x01 , 0xf1 , 0x05 , 0x40 , 0xd0 , 0xe8 , 0xf4 , 0x80 , 0x00 , 0x00 } ;
78
78
break ;
79
- case ( int ) DisassembleMode . Arm32 + DisassembleMode . ArmV8 :
79
+ case ( int ) DisassembleMode . Arm32 + DisassembleMode . ArmV8 :
80
80
code = new byte [ ] { 0xe0 , 0x3b , 0xb2 , 0xee , 0x42 , 0x00 , 0x01 , 0xe1 , 0x51 , 0xf0 , 0x7f , 0xf5 } ;
81
81
break ;
82
82
case DisassembleMode . ArmThumb :
83
- code = new byte [ ] { 0x70 , 0x47 , 0xeb , 0x46 , 0x83 , 0xb0 , 0xc9 , 0x68 , 0x1f , 0xb1 , 0x30 , 0xbf , 0xaf , 0xf3 , 0x20 , 0x84 } ;
83
+ code = new byte [ ] { 0x70 , 0x47 , 0xeb , 0x46 , 0x83 , 0xb0 , 0xc9 , 0x68 , 0x1f , 0xb1 , 0x30 , 0xbf , 0xaf , 0xf3 , 0x20 , 0x84 } ;
84
84
break ;
85
85
case ( int ) DisassembleMode . ArmThumb + DisassembleMode . ArmCortexM :
86
- code = new byte [ ] { 0xef , 0xf3 , 0x02 , 0x80 } ;
86
+ code = new byte [ ] { 0xef , 0xf3 , 0x02 , 0x80 } ;
87
87
break ;
88
88
}
89
89
@@ -194,7 +194,7 @@ internal static void ShowArm64() {
194
194
// Disassemble All Binary Code.
195
195
//
196
196
// ...
197
- var code = new byte [ ] { 0x09 , 0x00 , 0x38 , 0xd5 , 0xbf , 0x40 , 0x00 , 0xd5 , 0x0c , 0x05 , 0x13 , 0xd5 , 0x20 , 0x50 , 0x02 , 0x0e , 0x20 , 0xe4 , 0x3d , 0x0f , 0x00 , 0x18 , 0xa0 , 0x5f , 0xa2 , 0x00 , 0xae , 0x9e , 0x9f , 0x37 , 0x03 , 0xd5 , 0xbf , 0x33 , 0x03 , 0xd5 , 0xdf , 0x3f , 0x03 , 0xd5 , 0x21 , 0x7c , 0x02 , 0x9b , 0x21 , 0x7c , 0x00 , 0x53 , 0x00 , 0x40 , 0x21 , 0x4b , 0xe1 , 0x0b , 0x40 , 0xb9 , 0x20 , 0x04 , 0x81 , 0xda , 0x20 , 0x08 , 0x02 , 0x8b , 0x10 , 0x5b , 0xe8 , 0x3c } ;
197
+ var code = new byte [ ] { 0x09 , 0x00 , 0x38 , 0xd5 , 0xbf , 0x40 , 0x00 , 0xd5 , 0x0c , 0x05 , 0x13 , 0xd5 , 0x20 , 0x50 , 0x02 , 0x0e , 0x20 , 0xe4 , 0x3d , 0x0f , 0x00 , 0x18 , 0xa0 , 0x5f , 0xa2 , 0x00 , 0xae , 0x9e , 0x9f , 0x37 , 0x03 , 0xd5 , 0xbf , 0x33 , 0x03 , 0xd5 , 0xdf , 0x3f , 0x03 , 0xd5 , 0x21 , 0x7c , 0x02 , 0x9b , 0x21 , 0x7c , 0x00 , 0x53 , 0x00 , 0x40 , 0x21 , 0x4b , 0xe1 , 0x0b , 0x40 , 0xb9 , 0x20 , 0x04 , 0x81 , 0xda , 0x20 , 0x08 , 0x02 , 0x8b , 0x10 , 0x5b , 0xe8 , 0x3c } ;
198
198
var instructions = disassembler . DisassembleAll ( code , 0x2C ) ;
199
199
200
200
var hexCode = BitConverter . ToString ( code ) . Replace ( "-" , " " ) ;
@@ -327,11 +327,11 @@ internal static void ShowX86() {
327
327
// Disassemble All Binary Code.
328
328
//
329
329
// ...
330
- var code = new byte [ ] { 0x8d , 0x4c , 0x32 , 0x08 , 0x01 , 0xd8 , 0x81 , 0xc6 , 0x34 , 0x12 , 0x00 , 0x00 , 0x05 , 0x23 , 0x01 , 0x00 , 0x00 , 0x36 , 0x8b , 0x84 , 0x91 , 0x23 , 0x01 , 0x00 , 0x00 , 0x41 , 0x8d , 0x84 , 0x39 , 0x89 , 0x67 , 0x00 , 0x00 , 0x8d , 0x87 , 0x89 , 0x67 , 0x00 , 0x00 , 0xb4 , 0xc6 } ;
330
+ var code = new byte [ ] { 0x8d , 0x4c , 0x32 , 0x08 , 0x01 , 0xd8 , 0x81 , 0xc6 , 0x34 , 0x12 , 0x00 , 0x00 , 0x05 , 0x23 , 0x01 , 0x00 , 0x00 , 0x36 , 0x8b , 0x84 , 0x91 , 0x23 , 0x01 , 0x00 , 0x00 , 0x41 , 0x8d , 0x84 , 0x39 , 0x89 , 0x67 , 0x00 , 0x00 , 0x8d , 0x87 , 0x89 , 0x67 , 0x00 , 0x00 , 0xb4 , 0xc6 } ;
331
331
#if DISASSEMBLE_STREAM
332
- //$REVIEW: uxmal: This exercises the lazy stream implementation of the disassembler.
333
- // It isn't greed and tries to disassembly all the instructions at once,
334
- // but only on demand.
332
+ //$REVIEW: uxmal: This exercises the lazy stream implementation of the disassembler.
333
+ // It isn't greed and tries to disassembly all the instructions at once,
334
+ // but only on demand.
335
335
var instructions = disassembler . DisassembleStream ( code , 0 , 0x1000 ) ;
336
336
#else
337
337
var instructions = disassembler . DisassembleAll ( code ) ;
0 commit comments