about summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--subx/017jump_disp8.cc50
1 files changed, 25 insertions, 25 deletions
diff --git a/subx/017jump_disp8.cc b/subx/017jump_disp8.cc
index 086765c0..d7558401 100644
--- a/subx/017jump_disp8.cc
+++ b/subx/017jump_disp8.cc
@@ -6,7 +6,7 @@
 put_new(Name, "eb", "jump disp8 bytes away (jmp)");
 
 :(code)
-void test_jump_rel8() {
+void test_jump_disp8() {
   run(
       "== code 0x1\n"
       // op     ModR/M  SIB   displacement  immediate
@@ -23,7 +23,7 @@ void test_jump_rel8() {
 }
 
 :(before "End Single-Byte Opcodes")
-case 0xeb: {  // jump rel8
+case 0xeb: {  // jump disp8
   int8_t offset = static_cast<int>(next());
   trace(Callstack_depth+1, "run") << "jump " << NUM(offset) << end();
   EIP += offset;
@@ -36,7 +36,7 @@ case 0xeb: {  // jump rel8
 put_new(Name, "74", "jump disp8 bytes away if equal, if ZF is set (jcc/jz/je)");
 
 :(code)
-void test_je_rel8_success() {
+void test_je_disp8_success() {
   ZF = true;
   run(
       "== code 0x1\n"
@@ -54,7 +54,7 @@ void test_je_rel8_success() {
 }
 
 :(before "End Single-Byte Opcodes")
-case 0x74: {  // jump rel8 if ZF
+case 0x74: {  // jump disp8 if ZF
   const int8_t offset = static_cast<int>(next());
   if (ZF) {
     trace(Callstack_depth+1, "run") << "jump " << NUM(offset) << end();
@@ -64,7 +64,7 @@ case 0x74: {  // jump rel8 if ZF
 }
 
 :(code)
-void test_je_rel8_fail() {
+void test_je_disp8_fail() {
   ZF = false;
   run(
       "== code 0x1\n"
@@ -87,7 +87,7 @@ void test_je_rel8_fail() {
 put_new(Name, "75", "jump disp8 bytes away if not equal, if ZF is not set (jcc/jnz/jne)");
 
 :(code)
-void test_jne_rel8_success() {
+void test_jne_disp8_success() {
   ZF = false;
   run(
       "== code 0x1\n"
@@ -105,7 +105,7 @@ void test_jne_rel8_success() {
 }
 
 :(before "End Single-Byte Opcodes")
-case 0x75: {  // jump rel8 unless ZF
+case 0x75: {  // jump disp8 unless ZF
   const int8_t offset = static_cast<int>(next());
   if (!ZF) {
     trace(Callstack_depth+1, "run") << "jump " << NUM(offset) << end();
@@ -115,7 +115,7 @@ case 0x75: {  // jump rel8 unless ZF
 }
 
 :(code)
-void test_jne_rel8_fail() {
+void test_jne_disp8_fail() {
   ZF = true;
   run(
       "== code 0x1\n"
@@ -139,7 +139,7 @@ put_new(Name, "7f", "jump disp8 bytes away if greater (signed), if ZF is unset a
 put_new(Name, "77", "jump disp8 bytes away if greater (unsigned), if ZF is unset and CF is unset (jcc/ja/jnbe)");
 
 :(code)
-void test_jg_rel8_success() {
+void test_jg_disp8_success() {
   ZF = false;
   SF = false;
   OF = false;
@@ -159,7 +159,7 @@ void test_jg_rel8_success() {
 }
 
 :(before "End Single-Byte Opcodes")
-case 0x7f: {  // jump rel8 if SF == OF and !ZF
+case 0x7f: {  // jump disp8 if SF == OF and !ZF
   const int8_t offset = static_cast<int>(next());
   if (SF == OF && !ZF) {
     trace(Callstack_depth+1, "run") << "jump " << NUM(offset) << end();
@@ -167,7 +167,7 @@ case 0x7f: {  // jump rel8 if SF == OF and !ZF
   }
   break;
 }
-case 0x77: {  // jump rel8 if !CF and !ZF
+case 0x77: {  // jump disp8 if !CF and !ZF
   const int8_t offset = static_cast<int>(next());
   if (!CF && !ZF) {
     trace(Callstack_depth+1, "run") << "jump " << NUM(offset) << end();
@@ -177,7 +177,7 @@ case 0x77: {  // jump rel8 if !CF and !ZF
 }
 
 :(code)
-void test_jg_rel8_fail() {
+void test_jg_disp8_fail() {
   ZF = false;
   SF = true;
   OF = false;
@@ -203,7 +203,7 @@ put_new(Name, "7d", "jump disp8 bytes away if greater or equal (signed), if SF =
 put_new(Name, "73", "jump disp8 bytes away if greater or equal (unsigned), if CF is unset (jcc/jae/jnb)");
 
 :(code)
-void test_jge_rel8_success() {
+void test_jge_disp8_success() {
   SF = false;
   OF = false;
   run(
@@ -222,7 +222,7 @@ void test_jge_rel8_success() {
 }
 
 :(before "End Single-Byte Opcodes")
-case 0x7d: {  // jump rel8 if SF == OF
+case 0x7d: {  // jump disp8 if SF == OF
   const int8_t offset = static_cast<int>(next());
   if (SF == OF) {
     trace(Callstack_depth+1, "run") << "jump " << NUM(offset) << end();
@@ -230,7 +230,7 @@ case 0x7d: {  // jump rel8 if SF == OF
   }
   break;
 }
-case 0x73: {  // jump rel8 if !CF
+case 0x73: {  // jump disp8 if !CF
   const int8_t offset = static_cast<int>(next());
   if (!CF) {
     trace(Callstack_depth+1, "run") << "jump " << NUM(offset) << end();
@@ -240,7 +240,7 @@ case 0x73: {  // jump rel8 if !CF
 }
 
 :(code)
-void test_jge_rel8_fail() {
+void test_jge_disp8_fail() {
   SF = true;
   OF = false;
   run(
@@ -265,7 +265,7 @@ put_new(Name, "7c", "jump disp8 bytes away if lesser (signed), if SF != OF (jcc/
 put_new(Name, "72", "jump disp8 bytes away if lesser (unsigned), if CF is set (jcc/jb/jnae)");
 
 :(code)
-void test_jl_rel8_success() {
+void test_jl_disp8_success() {
   ZF = false;
   SF = true;
   OF = false;
@@ -285,7 +285,7 @@ void test_jl_rel8_success() {
 }
 
 :(before "End Single-Byte Opcodes")
-case 0x7c: {  // jump rel8 if SF != OF
+case 0x7c: {  // jump disp8 if SF != OF
   const int8_t offset = static_cast<int>(next());
   if (SF != OF) {
     trace(Callstack_depth+1, "run") << "jump " << NUM(offset) << end();
@@ -293,7 +293,7 @@ case 0x7c: {  // jump rel8 if SF != OF
   }
   break;
 }
-case 0x72: {  // jump rel8 if CF
+case 0x72: {  // jump disp8 if CF
   const int8_t offset = static_cast<int>(next());
   if (CF) {
     trace(Callstack_depth+1, "run") << "jump " << NUM(offset) << end();
@@ -303,7 +303,7 @@ case 0x72: {  // jump rel8 if CF
 }
 
 :(code)
-void test_jl_rel8_fail() {
+void test_jl_disp8_fail() {
   ZF = false;
   SF = false;
   OF = false;
@@ -329,7 +329,7 @@ put_new(Name, "7e", "jump disp8 bytes away if lesser or equal (signed), if ZF is
 put_new(Name, "76", "jump disp8 bytes away if lesser or equal (unsigned), if ZF is set or CF is set (jcc/jbe/jna)");
 
 :(code)
-void test_jle_rel8_equal() {
+void test_jle_disp8_equal() {
   ZF = true;
   SF = false;
   OF = false;
@@ -349,7 +349,7 @@ void test_jle_rel8_equal() {
 }
 
 :(code)
-void test_jle_rel8_lesser() {
+void test_jle_disp8_lesser() {
   ZF = false;
   SF = true;
   OF = false;
@@ -369,7 +369,7 @@ void test_jle_rel8_lesser() {
 }
 
 :(before "End Single-Byte Opcodes")
-case 0x7e: {  // jump rel8 if ZF or SF != OF
+case 0x7e: {  // jump disp8 if ZF or SF != OF
   const int8_t offset = static_cast<int>(next());
   if (ZF || SF != OF) {
     trace(Callstack_depth+1, "run") << "jump " << NUM(offset) << end();
@@ -377,7 +377,7 @@ case 0x7e: {  // jump rel8 if ZF or SF != OF
   }
   break;
 }
-case 0x76: {  // jump rel8 if ZF or CF
+case 0x76: {  // jump disp8 if ZF or CF
   const int8_t offset = static_cast<int>(next());
   if (ZF || CF) {
     trace(Callstack_depth+1, "run") << "jump " << NUM(offset) << end();
@@ -387,7 +387,7 @@ case 0x76: {  // jump rel8 if ZF or CF
 }
 
 :(code)
-void test_jle_rel8_greater() {
+void test_jle_disp8_greater() {
   ZF = false;
   SF = false;
   OF = false;
/blame/html/003trace.test.cc.html?h=main&id=c7db6a160a9a43d0905d5dea44e742b47acfa42f'>^
d009e158 ^

4690ce81 ^
9542bb11 ^

c5ffb6e1 ^
672e3e50 ^

4690ce81 ^
9542bb11 ^

c5ffb6e1 ^
672e3e50 ^

4690ce81 ^
9542bb11 ^
c5ffb6e1 ^
672e3e50 ^

4690ce81 ^
9542bb11 ^
c5ffb6e1 ^
672e3e50 ^

4690ce81 ^
9542bb11 ^


c5ffb6e1 ^
672e3e50 ^

4690ce81 ^
9542bb11 ^

672e3e50 ^


4690ce81 ^
9542bb11 ^

672e3e50 ^


4690ce81 ^
9542bb11 ^
44c1aeef ^
62a52ffb ^

672e3e50 ^


76755b28 ^

672e3e50 ^
76755b28 ^

672e3e50 ^
672e3e50 ^

4690ce81 ^
672e3e50 ^

65361948 ^
672e3e50 ^

4690ce81 ^
672e3e50 ^

65361948 ^
672e3e50 ^

4690ce81 ^
672e3e50 ^

65361948 ^

672e3e50 ^

4690ce81 ^
672e3e50 ^

65361948 ^


672e3e50 ^

4690ce81 ^
672e3e50 ^

65361948 ^


672e3e50 ^
c5ffb6e1 ^
4690ce81 ^
c5ffb6e1 ^













672e3e50 ^


a654e4ec ^
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160