summaryrefslogtreecommitdiff
path: root/src/lj_target_x86.h
diff options
context:
space:
mode:
authorMike Pall <mike>2011-10-27 01:52:37 +0200
committerMike Pall <mike>2011-10-27 01:57:30 +0200
commit2dc574d06bc6e828109a3bffa975592f9417434c (patch)
tree1239baece908e2390eb378e6d7d8063825926f9b /src/lj_target_x86.h
parent1d190c99a2547b44deb8f5e483452d9f51925fb2 (diff)
downloadluajit2-2dc574d06bc6e828109a3bffa975592f9417434c.tar.gz
FFI: Compile calls to stdcall, fastcall and vararg functions.
Diffstat (limited to 'src/lj_target_x86.h')
-rw-r--r--src/lj_target_x86.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/lj_target_x86.h b/src/lj_target_x86.h
index c4445ba4..233b77e5 100644
--- a/src/lj_target_x86.h
+++ b/src/lj_target_x86.h
@@ -85,6 +85,7 @@ enum {
#define REGARG_GPRS \
(RID_ECX|((RID_EDX|((RID_R8D|(RID_R9D<<5))<<5))<<5))
#define REGARG_NUMGPR 4
+#define REGARG_NUMFPR 4
#define REGARG_FIRSTFPR RID_XMM0
#define REGARG_LASTFPR RID_XMM3
#define STACKARG_OFS (4*8)
@@ -96,6 +97,7 @@ enum {
(RID_EDI|((RID_ESI|((RID_EDX|((RID_ECX|((RID_R8D|(RID_R9D \
<<5))<<5))<<5))<<5))<<5))
#define REGARG_NUMGPR 6
+#define REGARG_NUMFPR 8
#define REGARG_FIRSTFPR RID_XMM0
#define REGARG_LASTFPR RID_XMM7
#define STACKARG_OFS 0
@@ -105,6 +107,7 @@ enum {
#define RSET_SCRATCH (RSET_ACD|RSET_FPR)
#define REGARG_GPRS (RID_ECX|(RID_EDX<<5)) /* Fastcall only. */
#define REGARG_NUMGPR 2 /* Fastcall only. */
+#define REGARG_NUMFPR 0
#define STACKARG_OFS 0
#endif
@@ -192,6 +195,7 @@ typedef enum {
XI_JCCs = 0x70, /* Really 7x. */
XI_JCCn = 0x80, /* Really 0f8x. */
XI_LEA = 0x8d,
+ XI_MOVrib = 0xb0, /* Really b0+r. */
XI_MOVri = 0xb8, /* Really b8+r. */
XI_ARITHib = 0x80,
XI_ARITHi = 0x81,