summaryrefslogtreecommitdiff
path: root/gen_x86.h
diff options
context:
space:
mode:
authorMichael Pavone <pavone@retrodev.com>2019-04-07 00:06:29 -0700
committerMichael Pavone <pavone@retrodev.com>2019-04-07 00:06:29 -0700
commit376bef93cfadf5d0f778ac887500ee8d5d70fbcc (patch)
treecf003a31f4362bf3484e6bee1608a7ceae0f507b /gen_x86.h
parentd8e444e15c16fc80e513c43e99dbb33c30f72a51 (diff)
Get 64-bit builds working for Windows target
Diffstat (limited to 'gen_x86.h')
-rw-r--r--gen_x86.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/gen_x86.h b/gen_x86.h
index d384107..6ff0da9 100644
--- a/gen_x86.h
+++ b/gen_x86.h
@@ -63,6 +63,13 @@ enum {
#ifdef X86_64
#define SZ_PTR SZ_Q
#define MAX_INST_LEN 14
+#ifdef _WIN32
+#define FIRST_ARG_REG RCX
+#define SECOND_ARG_REG RDX
+#else
+#define FIRST_ARG_REG RDI
+#define SECOND_ARG_REG RSI
+#endif
#else
#define SZ_PTR SZ_D
#define MAX_INST_LEN 11