about summary refs log tree commit diff stats
path: root/test/test_all.py
diff options
context:
space:
mode:
authorserpilliere <serpilliere@users.noreply.github.com>2018-12-05 07:06:31 +0100
committerGitHub <noreply@github.com>2018-12-05 07:06:31 +0100
commit37c877b20aa1f6b3bbe81a7c79e0fa206ef2d428 (patch)
tree657de4601e520d64d264d09eee6763b47b3224f2 /test/test_all.py
parent54dafe4451d9caf9f112db513dad4f19cbe32575 (diff)
parent6afa62517fec1ec597020aec469875e404882e5b (diff)
downloadmiasm-37c877b20aa1f6b3bbe81a7c79e0fa206ef2d428.tar.gz
miasm-37c877b20aa1f6b3bbe81a7c79e0fa206ef2d428.zip
Merge pull request #894 from commial/tests/qemu-x86_64
Tests/qemu x86 64
Diffstat (limited to 'test/test_all.py')
-rwxr-xr-xtest/test_all.py54
1 files changed, 54 insertions, 0 deletions
diff --git a/test/test_all.py b/test/test_all.py
index 7ea55235..42843e90 100755
--- a/test/test_all.py
+++ b/test/test_all.py
@@ -189,6 +189,60 @@ for test_name in QEMU_TESTS:
         testset += QEMUTest(test_name, jitter, tags=tags)
 
 
+class QEMUTestx86_64(QEMUTest):
+    SAMPLE_NAME = "test-x86_64"
+    SCRIPT_NAME = "testqemu64.py"
+    EXPECTED_PATH = "expected_x86_64"
+
+
+# Test name -> supported jitter engines
+QEMU_TESTS_x86_64 = [
+    "adc",
+    "add",
+    "and",
+    "btc",
+    "bt",
+    "btr",
+    "bts",
+    "cmp",
+    "conv",
+    "dec",
+    "inc",
+    "jcc",
+    "lea",
+    "misc",
+    "mul",
+    "neg",
+    "not",
+    "or",
+    "rcl",
+    "rcr",
+    "rol",
+    "ror",
+    "sar",
+    "sbb",
+    "shld",
+    "shl",
+    "shrd",
+    "shr",
+    "string",
+    "sub",
+    "xor",
+    # Unsupported
+    # "sse", "floats", "loop", "xchg", "fxsave"
+]
+
+
+for test_name in QEMU_TESTS_x86_64:
+    for jitter in QEMUTestx86_64.jitter_engines:
+        if is_win and jitter == "llvm" and test_name in [
+                "mul", "rcl", "rcr"
+        ]:
+            continue
+        tags = [TAGS[jitter]] if jitter in TAGS else []
+        testset += QEMUTestx86_64(test_name, jitter, tags=tags)
+
+
 ## Semantic
 class SemanticTestAsm(RegressionTest):
     """Assemble an asm file"""