diff mbox

x86emul/test: avoid meaningless output

Message ID 584957E40200007800126B4F@prv-mh.provo.novell.com (mailing list archive)
State New, archived
Headers show

Commit Message

Jan Beulich Dec. 8, 2016, 11:53 a.m. UTC
Unconditionally reporting a skipped test in 64-bit builds is not very
useful, especially when quite a few more tests are about to be added.

Signed-off-by: Jan Beulich <jbeulich@suse.com>
x86emul/test: avoid meaningless output

Unconditionally reporting a skipped test in 64-bit builds is not very
useful, especially when quite a few more tests are about to be added.

Signed-off-by: Jan Beulich <jbeulich@suse.com>

--- a/tools/tests/x86_emulator/test_x86_emulator.c
+++ b/tools/tests/x86_emulator/test_x86_emulator.c
@@ -613,8 +613,8 @@ int main(int argc, char **argv)
         goto fail;
     printf("okay\n");
 
-    printf("%-40s", "Testing daa/das (all inputs)...");
 #ifndef __x86_64__
+    printf("%-40s", "Testing daa/das (all inputs)...");
     /* Bits 0-7: AL; Bit 8: EFLG_AF; Bit 9: EFLG_CF; Bit 10: DAA vs. DAS. */
     for ( i = 0; i < 0x800; i++ )
     {
@@ -679,9 +679,7 @@ int main(int argc, char **argv)
         }
     }
     printf("okay\n");
-#else
-    printf("skipped\n");
-
+#else /* x86-64 */
     printf("%-40s", "Testing cmovz %ecx,%eax...");
     instr[0] = 0x0f; instr[1] = 0x44; instr[2] = 0xc1;
     regs.eflags = 0x200;

Comments

Andrew Cooper Dec. 8, 2016, 2:05 p.m. UTC | #1
On 08/12/16 11:53, Jan Beulich wrote:
> Unconditionally reporting a skipped test in 64-bit builds is not very
> useful, especially when quite a few more tests are about to be added.
>
> Signed-off-by: Jan Beulich <jbeulich@suse.com>

Reviewed-by: Andrew Cooper <andrew.cooper3@citrix.com>
diff mbox

Patch

--- a/tools/tests/x86_emulator/test_x86_emulator.c
+++ b/tools/tests/x86_emulator/test_x86_emulator.c
@@ -613,8 +613,8 @@  int main(int argc, char **argv)
         goto fail;
     printf("okay\n");
 
-    printf("%-40s", "Testing daa/das (all inputs)...");
 #ifndef __x86_64__
+    printf("%-40s", "Testing daa/das (all inputs)...");
     /* Bits 0-7: AL; Bit 8: EFLG_AF; Bit 9: EFLG_CF; Bit 10: DAA vs. DAS. */
     for ( i = 0; i < 0x800; i++ )
     {
@@ -679,9 +679,7 @@  int main(int argc, char **argv)
         }
     }
     printf("okay\n");
-#else
-    printf("skipped\n");
-
+#else /* x86-64 */
     printf("%-40s", "Testing cmovz %ecx,%eax...");
     instr[0] = 0x0f; instr[1] = 0x44; instr[2] = 0xc1;
     regs.eflags = 0x200;