opcodes.h   opcodes.h 
skipping to change at line 74 skipping to change at line 74
BINARY_UL(avgul, "((orc_uint64)(orc_uint32)%s + (orc_uint64)(orc_uint32)%s + 1)>>1") BINARY_UL(avgul, "((orc_uint64)(orc_uint32)%s + (orc_uint64)(orc_uint32)%s + 1)>>1")
BINARY_SL(cmpeql, "(%s == %s) ? (~0) : 0") BINARY_SL(cmpeql, "(%s == %s) ? (~0) : 0")
BINARY_SL(cmpgtsl, "(%s > %s) ? (~0) : 0") BINARY_SL(cmpgtsl, "(%s > %s) ? (~0) : 0")
UNARY_SL(copyl, "%s") UNARY_SL(copyl, "%s")
BINARY_SL(maxsl, "ORC_MAX(%s, %s)") BINARY_SL(maxsl, "ORC_MAX(%s, %s)")
BINARY_UL(maxul, "ORC_MAX((orc_uint32)%s, (orc_uint32)%s)") BINARY_UL(maxul, "ORC_MAX((orc_uint32)%s, (orc_uint32)%s)")
BINARY_SL(minsl, "ORC_MIN(%s, %s)") BINARY_SL(minsl, "ORC_MIN(%s, %s)")
BINARY_UL(minul, "ORC_MIN((orc_uint32)%s, (orc_uint32)%s)") BINARY_UL(minul, "ORC_MIN((orc_uint32)%s, (orc_uint32)%s)")
BINARY_SL(mulll, "(%s * %s) & 0xffffffff") BINARY_SL(mulll, "(%s * %s) & 0xffffffff")
BINARY_SL(mulhsl, "((orc_int64)%s * (orc_int64)%s) >> 32") BINARY_SL(mulhsl, "((orc_int64)%s * (orc_int64)%s) >> 32")
BINARY_UL(mulhul, "((orc_uint64)%s * (orc_uint64)%s) >> 32") BINARY_UL(mulhul, "((orc_uint64)(orc_uint32)%s * (orc_uint64)(orc_uint32)%s ) >> 32")
BINARY_SL(orl, "%s | %s") BINARY_SL(orl, "%s | %s")
BINARY_SL(shll, "%s << %s") BINARY_SL(shll, "%s << %s")
BINARY_SL(shrsl, "%s >> %s") BINARY_SL(shrsl, "%s >> %s")
BINARY_UL(shrul, "((orc_uint32)%s) >> %s") BINARY_UL(shrul, "((orc_uint32)%s) >> %s")
UNARY_SL(signl, "ORC_CLAMP(%s,-1,1)") UNARY_SL(signl, "ORC_CLAMP(%s,-1,1)")
BINARY_SL(subl, "%s - %s") BINARY_SL(subl, "%s - %s")
BINARY_SL(subssl, "ORC_CLAMP_SL((orc_int64)%s - (orc_int64)%s)") BINARY_SL(subssl, "ORC_CLAMP_SL((orc_int64)%s - (orc_int64)%s)")
BINARY_UL(subusl, "ORC_CLAMP_UL((orc_int64)(orc_uint32)%s - (orc_int64)(orc _uint32)%s)") BINARY_UL(subusl, "ORC_CLAMP_UL((orc_int64)(orc_uint32)%s - (orc_int64)(orc _uint32)%s)")
BINARY_SL(xorl, "%s ^ %s") BINARY_SL(xorl, "%s ^ %s")
UNARY_BW(convsbw, "%s") UNARY_BW(convsbw, "%s")
UNARY_BW(convubw, "(orc_uint8)%s") UNARY_BW(convubw, "(orc_uint8)%s")
UNARY_WL(convswl, "%s")
UNARY_WL(convuwl, "(orc_uint16)%s")
UNARY_WB(convwb, "%s") UNARY_WB(convwb, "%s")
UNARY_WB(convhwb, "((orc_uint16)%s)>>8")
UNARY_WB(convssswb, "ORC_CLAMP_SB(%s)") UNARY_WB(convssswb, "ORC_CLAMP_SB(%s)")
UNARY_WB(convsuswb, "ORC_CLAMP_UB(%s)") UNARY_WB(convsuswb, "ORC_CLAMP_UB(%s)")
UNARY_WB(convusswb, "ORC_CLAMP_SB((orc_uint16)%s)") UNARY_WB(convusswb, "ORC_CLAMP_SB((orc_uint16)%s)")
UNARY_WB(convuuswb, "ORC_CLAMP_UB((orc_uint16)%s)") UNARY_WB(convuuswb, "ORC_CLAMP_UB((orc_uint16)%s)")
UNARY_WL(convswl, "%s")
UNARY_WL(convuwl, "(orc_uint16)%s")
UNARY_LW(convlw, "%s") UNARY_LW(convlw, "%s")
UNARY_WB(convhlw, "((orc_uint32)%s)>>16")
UNARY_LW(convssslw, "ORC_CLAMP_SW(%s)") UNARY_LW(convssslw, "ORC_CLAMP_SW(%s)")
UNARY_LW(convsuslw, "ORC_CLAMP_UW(%s)") UNARY_LW(convsuslw, "ORC_CLAMP_UW(%s)")
UNARY_LW(convusslw, "ORC_CLAMP_SW((orc_uint32)%s)") UNARY_LW(convusslw, "ORC_CLAMP_SW((orc_uint32)%s)")
UNARY_LW(convuuslw, "ORC_CLAMP_UW((orc_uint32)%s)") UNARY_LW(convuuslw, "ORC_CLAMP_UW((orc_uint32)%s)")
UNARY_LQ(convslq, "%s")
UNARY_LQ(convulq, "(orc_uint32)%s")
UNARY_LW(convql, "%s")
UNARY_LW(convsssql, "ORC_CLAMP_SL(%s)")
UNARY_LW(convsusql, "ORC_CLAMP_UL(%s)")
UNARY_LW(convussql, "ORC_CLAMP_SL((orc_uint64)%s)")
UNARY_LW(convuusql, "ORC_CLAMP_UL((orc_uint64)%s)")
BINARY_BW(mulsbw, "%s * %s") BINARY_BW(mulsbw, "%s * %s")
BINARY_BW(mulubw, "(orc_uint8)%s * (orc_uint8)%s") BINARY_BW(mulubw, "(orc_uint8)%s * (orc_uint8)%s")
BINARY_WL(mulswl, "%s * %s") BINARY_WL(mulswl, "%s * %s")
BINARY_WL(muluwl, "(orc_uint16)%s * (orc_uint16)%s") BINARY_WL(muluwl, "(orc_uint16)%s * (orc_uint16)%s")
BINARY_WL(mergewl, "((orc_uint16)%s) | ((orc_uint16)%s << 16)") BINARY_WL(mergewl, "((orc_uint16)%s) | ((orc_uint16)%s << 16)")
BINARY_BW(mergebw, "((orc_uint8)%s) | ((orc_uint8)%s << 8)") BINARY_BW(mergebw, "((orc_uint8)%s) | ((orc_uint8)%s << 8)")
UNARY_WB(select0wb, "(orc_uint16)%s & 0xff") UNARY_WB(select0wb, "(orc_uint16)%s & 0xff")
UNARY_WB(select1wb, "((orc_uint16)%s >> 8)&0xff") UNARY_WB(select1wb, "((orc_uint16)%s >> 8)&0xff")
UNARY_LW(select0lw, "(orc_uint32)%s & 0xffff") UNARY_LW(select0lw, "(orc_uint32)%s & 0xffff")
UNARY_LW(select1lw, "((orc_uint32)%s >> 16)&0xffff") UNARY_LW(select1lw, "((orc_uint32)%s >> 16)&0xffff")
UNARY_UW(swapw, "ORC_SWAP_W(%s)") UNARY_UW(swapw, "ORC_SWAP_W(%s)")
UNARY_UL(swapl, "ORC_SWAP_L(%s)") UNARY_UL(swapl, "ORC_SWAP_L(%s)")
BINARY_F(addf, "%s + %s") BINARY_F(addf, "ORC_DENORMAL(ORC_DENORMAL(%s) + ORC_DENORMAL(%s))")
BINARY_F(subf, "%s - %s") BINARY_F(subf, "ORC_DENORMAL(ORC_DENORMAL(%s) - ORC_DENORMAL(%s))")
BINARY_F(mulf, "%s * %s") BINARY_F(mulf, "ORC_DENORMAL(ORC_DENORMAL(%s) * ORC_DENORMAL(%s))")
BINARY_F(divf, "%s / %s") BINARY_F(divf, "ORC_DENORMAL(ORC_DENORMAL(%s) / ORC_DENORMAL(%s))")
UNARY_F(sqrtf, "sqrt(%s)") UNARY_F(sqrtf, "sqrt(ORC_DENORMAL(%s))")
BINARY_F(maxf, "ORC_MAX(%s,%s)") BINARY_F(maxf, "ORC_MAXF(ORC_DENORMAL(%s),ORC_DENORMAL(%s))")
BINARY_F(minf, "ORC_MIN(%s,%s)") BINARY_F(minf, "ORC_MINF(ORC_DENORMAL(%s),ORC_DENORMAL(%s))")
BINARY_FL(cmpeqf, "(%s == %s) ? (~0) : 0") BINARY_FL(cmpeqf, "(ORC_DENORMAL(%s) == ORC_DENORMAL(%s)) ? (~0) : 0")
BINARY_FL(cmpltf, "(%s < %s) ? (~0) : 0") BINARY_FL(cmpltf, "(ORC_DENORMAL(%s) < ORC_DENORMAL(%s)) ? (~0) : 0")
BINARY_FL(cmplef, "(%s <= %s) ? (~0) : 0") BINARY_FL(cmplef, "(ORC_DENORMAL(%s) <= ORC_DENORMAL(%s)) ? (~0) : 0")
UNARY_FL(convfl, "(int)%s") UNARY_FL(convfl, "(int)%s")
UNARY_LF(convlf, "%s") UNARY_LF(convlf, "%s")
 End of changes. 7 change blocks. 
13 lines changed or deleted 24 lines changed or added


 orc-stdint.h   orc-stdint.h 
#ifndef _ORC_ORC_ORC_STDINT_H #ifndef _ORC_ORC_ORC_STDINT_H
#define _ORC_ORC_ORC_STDINT_H 1 #define _ORC_ORC_ORC_STDINT_H 1
#ifndef _GENERATED_STDINT_H #ifndef _GENERATED_STDINT_H
#define _GENERATED_STDINT_H "orc 0.4.6" #define _GENERATED_STDINT_H "orc 0.4.7"
/* generated using gnu compiler gcc (SUSE Linux) 4.4.1 [gcc-4_4-branch revi sion 150839] */ /* generated using gnu compiler gcc (SUSE Linux) 4.4.1 [gcc-4_4-branch revi sion 150839] */
#define _STDINT_HAVE_STDINT_H 1 #define _STDINT_HAVE_STDINT_H 1
#include <stdint.h> #include <stdint.h>
#endif #endif
#endif #endif
 End of changes. 1 change blocks. 
1 lines changed or deleted 1 lines changed or added


 orcarm.h   orcarm.h 
skipping to change at line 94 skipping to change at line 94
void orc_arm_emit_lsl_imm (OrcCompiler *compiler, int dest, int src1, int v alue); void orc_arm_emit_lsl_imm (OrcCompiler *compiler, int dest, int src1, int v alue);
void orc_arm_emit_cmp_imm (OrcCompiler *compiler, int src1, int value); void orc_arm_emit_cmp_imm (OrcCompiler *compiler, int src1, int value);
void orc_arm_emit_cmp (OrcCompiler *compiler, int src1, int src2); void orc_arm_emit_cmp (OrcCompiler *compiler, int src1, int src2);
void orc_arm_emit_mov (OrcCompiler *compiler, int dest, int src); void orc_arm_emit_mov (OrcCompiler *compiler, int dest, int src);
void orc_arm_emit_align (OrcCompiler *compiler, int align_shift); void orc_arm_emit_align (OrcCompiler *compiler, int align_shift);
void orc_arm_emit_label (OrcCompiler *compiler, int label); void orc_arm_emit_label (OrcCompiler *compiler, int label);
void orc_arm_emit_push (OrcCompiler *compiler, int regs); void orc_arm_emit_push (OrcCompiler *compiler, int regs);
void orc_arm_emit_pop (OrcCompiler *compiler, int regs); void orc_arm_emit_pop (OrcCompiler *compiler, int regs);
void orc_arm_emit_branch (OrcCompiler *compiler, int cond, int label); void orc_arm_emit_branch (OrcCompiler *compiler, int cond, int label);
void orc_arm_emit_data (OrcCompiler *compiler, orc_uint32 data);
void orc_arm_loadb (OrcCompiler *compiler, int dest, int src1, int offset); void orc_arm_loadb (OrcCompiler *compiler, int dest, int src1, int offset);
void orc_arm_storeb (OrcCompiler *compiler, int dest, int offset, int src1) ; void orc_arm_storeb (OrcCompiler *compiler, int dest, int offset, int src1) ;
void orc_arm_loadw (OrcCompiler *compiler, int dest, int src1, int offset); void orc_arm_loadw (OrcCompiler *compiler, int dest, int src1, int offset);
void orc_arm_storew (OrcCompiler *compiler, int dest, int offset, int src1) ; void orc_arm_storew (OrcCompiler *compiler, int dest, int offset, int src1) ;
void orc_arm_loadl (OrcCompiler *compiler, int dest, int src1, int offset); void orc_arm_loadl (OrcCompiler *compiler, int dest, int src1, int offset);
void orc_arm_storel (OrcCompiler *compiler, int dest, int offset, int src1) ; void orc_arm_storel (OrcCompiler *compiler, int dest, int offset, int src1) ;
void orc_arm_emit_load_reg (OrcCompiler *compiler, int dest, int src1, int offset); void orc_arm_emit_load_reg (OrcCompiler *compiler, int dest, int src1, int offset);
void orc_arm_emit_store_reg (OrcCompiler *compiler, int src, int dest, int offset); void orc_arm_emit_store_reg (OrcCompiler *compiler, int src, int dest, int offset);
skipping to change at line 120 skipping to change at line 121
void orc_arm_emit_par (OrcCompiler *p, int op, int mode, OrcArmCond cond, void orc_arm_emit_par (OrcCompiler *p, int op, int mode, OrcArmCond cond,
int Rd, int Rn, int Rm); int Rd, int Rn, int Rm);
void orc_arm_emit_xt (OrcCompiler *p, int op, OrcArmCond cond, void orc_arm_emit_xt (OrcCompiler *p, int op, OrcArmCond cond,
int Rd, int Rn, int Rm, int r8); int Rd, int Rn, int Rm, int r8);
void orc_arm_emit_pkh (OrcCompiler *p, int op, OrcArmCond cond, void orc_arm_emit_pkh (OrcCompiler *p, int op, OrcArmCond cond,
int Rd, int Rn, int Rm, int sh); int Rd, int Rn, int Rm, int sh);
void orc_arm_emit_sat (OrcCompiler *p, int op, OrcArmCond cond, void orc_arm_emit_sat (OrcCompiler *p, int op, OrcArmCond cond,
int Rd, int sat, int Rm, int sh, int asr); int Rd, int sat, int Rm, int sh, int asr);
void orc_arm_emit_rv (OrcCompiler *p, int op, OrcArmCond cond, void orc_arm_emit_rv (OrcCompiler *p, int op, OrcArmCond cond,
int Rd, int Rm); int Rd, int Rm);
void orc_arm_emit_nop (OrcCompiler *compiler);
void orc_arm_flush_cache (OrcCompiler *compiler); void orc_arm_flush_cache (OrcCompiler *compiler);
/* ALL cpus */ /* ALL cpus */
/* data procesing instructions */ /* data procesing instructions */
/* <op>{<cond>}{s} {<Rd>}, <Rn>, #imm */ /* <op>{<cond>}{s} {<Rd>}, <Rn>, #imm */
#define orc_arm_emit_and_i(p,cond,S,Rd,Rn,imm) orc_arm_emit_dp(p,0,c ond,ORC_ARM_DP_AND,S,Rd,Rn,0,0,imm) #define orc_arm_emit_and_i(p,cond,S,Rd,Rn,imm) orc_arm_emit_dp(p,0,c ond,ORC_ARM_DP_AND,S,Rd,Rn,0,0,imm)
#define orc_arm_emit_eor_i(p,cond,S,Rd,Rn,imm) orc_arm_emit_dp(p,0,c ond,ORC_ARM_DP_EOR,S,Rd,Rn,0,0,imm) #define orc_arm_emit_eor_i(p,cond,S,Rd,Rn,imm) orc_arm_emit_dp(p,0,c ond,ORC_ARM_DP_EOR,S,Rd,Rn,0,0,imm)
#define orc_arm_emit_sub_i(p,cond,S,Rd,Rn,imm) orc_arm_emit_dp(p,0,c ond,ORC_ARM_DP_SUB,S,Rd,Rn,0,0,imm) #define orc_arm_emit_sub_i(p,cond,S,Rd,Rn,imm) orc_arm_emit_dp(p,0,c ond,ORC_ARM_DP_SUB,S,Rd,Rn,0,0,imm)
#define orc_arm_emit_rsb_i(p,cond,S,Rd,Rn,imm) orc_arm_emit_dp(p,0,c ond,ORC_ARM_DP_RSB,S,Rd,Rn,0,0,imm) #define orc_arm_emit_rsb_i(p,cond,S,Rd,Rn,imm) orc_arm_emit_dp(p,0,c ond,ORC_ARM_DP_RSB,S,Rd,Rn,0,0,imm)
 End of changes. 2 change blocks. 
0 lines changed or deleted 2 lines changed or added


 orcarray.h   orcarray.h 
skipping to change at line 23 skipping to change at line 23
struct _OrcArray { struct _OrcArray {
void *data; void *data;
int stride; int stride;
int element_size; int element_size;
int n,m; int n,m;
void *alloc_data; void *alloc_data;
int alloc_len; int alloc_len;
}; };
OrcArray *orc_array_new (int n, int m, int element_size); OrcArray *orc_array_new (int n, int m, int element_size, int misalignment);
void orc_array_free (OrcArray *array); void orc_array_free (OrcArray *array);
void orc_array_set_pattern (OrcArray *array, int value); void orc_array_set_pattern (OrcArray *array, int value);
void orc_array_set_random (OrcArray *array, OrcRandomContext *context); void orc_array_set_random (OrcArray *array, OrcRandomContext *context);
int orc_array_compare (OrcArray *array1, OrcArray *array2, int flags); int orc_array_compare (OrcArray *array1, OrcArray *array2, int flags);
int orc_array_check_out_of_bounds (OrcArray *array); int orc_array_check_out_of_bounds (OrcArray *array);
#endif #endif
 End of changes. 1 change blocks. 
1 lines changed or deleted 1 lines changed or added


 orcfunctions.h   orcfunctions.h 
/* autogenerated from orcfunctions.orc */ /* autogenerated from orcfunctions.orc */
#ifndef _ORCFUNCTIONS_H_ #ifndef _ORCFUNCTIONS_H_
#define _ORCFUNCTIONS_H_ #define _ORCFUNCTIONS_H_
#ifdef __cplusplus #ifdef __cplusplus
extern "C" { extern "C" {
#endif #endif
#ifndef _ORC_INTEGER_TYPEDEFS_
#define _ORC_INTEGER_TYPEDEFS_
#if defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
#include <stdint.h>
typedef int8_t orc_int8;
typedef int16_t orc_int16;
typedef int32_t orc_int32;
typedef int64_t orc_int64;
typedef uint8_t orc_uint8;
typedef uint16_t orc_uint16;
typedef uint32_t orc_uint32;
typedef uint64_t orc_uint64;
#elif defined(_MSC_VER)
typedef signed __int8 orc_int8;
typedef signed __int16 orc_int16;
typedef signed __int32 orc_int32;
typedef signed __int64 orc_int64;
typedef unsigned __int8 orc_uint8;
typedef unsigned __int16 orc_uint16;
typedef unsigned __int32 orc_uint32;
typedef unsigned __int64 orc_uint64;
#else
#include <limits.h>
typedef signed char orc_int8;
typedef short orc_int16;
typedef int orc_int32;
typedef unsigned char orc_uint8;
typedef unsigned short orc_uint16;
typedef unsigned int orc_uint32;
#if INT_MAX == LONG_MAX
typedef long long orc_int64;
typedef unsigned long long orc_uint64;
#else
typedef long orc_int64;
typedef unsigned long orc_uint64;
#endif
#endif
typedef union { orc_int16 i; orc_int8 x2[2]; } orc_union16;
typedef union { orc_int32 i; float f; orc_int16 x2[2]; orc_int8 x4[4]; } or
c_union32;
typedef union { orc_int64 i; double f; orc_int32 x2[2]; orc_int16 x4[4]; }
orc_union64;
#endif
void orc_memcpy (void * d1, const void * s1, int n); void orc_memcpy (void * d1, const void * s1, int n);
void orc_memset (void * d1, int p1, int n); void orc_memset (void * d1, int p1, int n);
#ifdef __cplusplus #ifdef __cplusplus
} }
#endif #endif
#endif #endif
 End of changes. 1 change blocks. 
0 lines changed or deleted 43 lines changed or added


 orcmmx.h   orcmmx.h 
skipping to change at line 13 skipping to change at line 13
#define _ORC_MMX_H_ #define _ORC_MMX_H_
#include <orc/orcx86.h> #include <orc/orcx86.h>
typedef enum { typedef enum {
ORC_TARGET_MMX_MMX = (1<<0), ORC_TARGET_MMX_MMX = (1<<0),
ORC_TARGET_MMX_MMXEXT = (1<<1), ORC_TARGET_MMX_MMXEXT = (1<<1),
ORC_TARGET_MMX_3DNOW = (1<<2), ORC_TARGET_MMX_3DNOW = (1<<2),
ORC_TARGET_MMX_3DNOWEXT = (1<<3), ORC_TARGET_MMX_3DNOWEXT = (1<<3),
ORC_TARGET_MMX_SSSE3 = (1<<4), ORC_TARGET_MMX_SSSE3 = (1<<4),
ORC_TARGET_MMX_SSE4_1 = (1<<5),
ORC_TARGET_MMX_FRAME_POINTER = (1<<7), ORC_TARGET_MMX_FRAME_POINTER = (1<<7),
ORC_TARGET_MMX_SHORT_JUMPS = (1<<8), ORC_TARGET_MMX_SHORT_JUMPS = (1<<8),
ORC_TARGET_MMX_64BIT = (1<<9) ORC_TARGET_MMX_64BIT = (1<<9)
} OrcTargetMMXFlags; } OrcTargetMMXFlags;
typedef enum { typedef enum {
X86_MM0 = ORC_VEC_REG_BASE, X86_MM0 = ORC_VEC_REG_BASE,
X86_MM1, X86_MM1,
X86_MM2, X86_MM2,
X86_MM3, X86_MM3,
skipping to change at line 56 skipping to change at line 57
void orc_mmx_emit_660f (OrcCompiler *p, const char *insn_name, int code, void orc_mmx_emit_660f (OrcCompiler *p, const char *insn_name, int code,
int src, int dest); int src, int dest);
void orc_mmx_emit_f20f (OrcCompiler *p, const char *insn_name, int code, void orc_mmx_emit_f20f (OrcCompiler *p, const char *insn_name, int code,
int src, int dest); int src, int dest);
void orc_mmx_emit_f30f (OrcCompiler *p, const char *insn_name, int code, void orc_mmx_emit_f30f (OrcCompiler *p, const char *insn_name, int code,
int src, int dest); int src, int dest);
void orc_mmx_emit_0f (OrcCompiler *p, const char *insn_name, int code, void orc_mmx_emit_0f (OrcCompiler *p, const char *insn_name, int code,
int src, int dest); int src, int dest);
void orc_mmx_emit_pshufw (OrcCompiler *p, int shuf, int src, int dest); void orc_mmx_emit_pshufw (OrcCompiler *p, int shuf, int src, int dest);
void orc_mmx_emit_palignr (OrcCompiler *p, int align, int src, int dest);
void orc_mmx_emit_pinsrw_memoffset (OrcCompiler *p, int imm, int offset,
int src, int dest);
void orc_mmx_emit_pextrw_memoffset (OrcCompiler *p, int imm, int src,
int offset, int dest);
void orc_mmx_emit_shiftimm (OrcCompiler *p, const char *insn_name, void orc_mmx_emit_shiftimm (OrcCompiler *p, const char *insn_name,
int code, int modrm_code, int shift, int reg); int code, int modrm_code, int shift, int reg);
unsigned int orc_mmx_get_cpu_flags (void); unsigned int orc_mmx_get_cpu_flags (void);
void mmx_load_constant (OrcCompiler *compiler, int reg, int size, int value
);
/* MMX instructions */ /* MMX instructions */
#define orc_mmx_emit_punpcklbw(p,a,b) orc_mmx_emit_660f (p, "punpcklbw", 0 x60, a, b) #define orc_mmx_emit_punpcklbw(p,a,b) orc_mmx_emit_660f (p, "punpcklbw", 0 x60, a, b)
#define orc_mmx_emit_punpcklwd(p,a,b) orc_mmx_emit_660f (p, "punpcklwd", 0 x61, a, b) #define orc_mmx_emit_punpcklwd(p,a,b) orc_mmx_emit_660f (p, "punpcklwd", 0 x61, a, b)
#define orc_mmx_emit_punpckldq(p,a,b) orc_mmx_emit_660f (p, "punpckldq", 0 x62, a, b) #define orc_mmx_emit_punpckldq(p,a,b) orc_mmx_emit_660f (p, "punpckldq", 0 x62, a, b)
#define orc_mmx_emit_packsswb(p,a,b) orc_mmx_emit_660f (p, "packsswb", 0x 63, a, b) #define orc_mmx_emit_packsswb(p,a,b) orc_mmx_emit_660f (p, "packsswb", 0x 63, a, b)
#define orc_mmx_emit_pcmpgtb(p,a,b) orc_mmx_emit_660f (p, "pcmpgtb", 0x6 4, a, b) #define orc_mmx_emit_pcmpgtb(p,a,b) orc_mmx_emit_660f (p, "pcmpgtb", 0x6 4, a, b)
#define orc_mmx_emit_pcmpgtw(p,a,b) orc_mmx_emit_660f (p, "pcmpgtw", 0x6 5, a, b) #define orc_mmx_emit_pcmpgtw(p,a,b) orc_mmx_emit_660f (p, "pcmpgtw", 0x6 5, a, b)
#define orc_mmx_emit_pcmpgtd(p,a,b) orc_mmx_emit_660f (p, "pcmpgtd", 0x6 6, a, b) #define orc_mmx_emit_pcmpgtd(p,a,b) orc_mmx_emit_660f (p, "pcmpgtd", 0x6 6, a, b)
#define orc_mmx_emit_packuswb(p,a,b) orc_mmx_emit_660f (p, "packuswb", 0x 67, a, b) #define orc_mmx_emit_packuswb(p,a,b) orc_mmx_emit_660f (p, "packuswb", 0x 67, a, b)
#define orc_mmx_emit_punpckhbw(p,a,b) orc_mmx_emit_660f (p, "punpckhbw", 0 x68, a, b) #define orc_mmx_emit_punpckhbw(p,a,b) orc_mmx_emit_660f (p, "punpckhbw", 0 x68, a, b)
skipping to change at line 162 skipping to change at line 170
#define orc_mmx_emit_phsubsw(p,a,b) orc_mmx_emit_660f (p, "phsubsw", 0x3 807, a, b) #define orc_mmx_emit_phsubsw(p,a,b) orc_mmx_emit_660f (p, "phsubsw", 0x3 807, a, b)
#define orc_mmx_emit_psignb(p,a,b) orc_mmx_emit_660f (p, "psignb", 0x38 08, a, b) #define orc_mmx_emit_psignb(p,a,b) orc_mmx_emit_660f (p, "psignb", 0x38 08, a, b)
#define orc_mmx_emit_psignw(p,a,b) orc_mmx_emit_660f (p, "psignw", 0x38 09, a, b) #define orc_mmx_emit_psignw(p,a,b) orc_mmx_emit_660f (p, "psignw", 0x38 09, a, b)
#define orc_mmx_emit_psignd(p,a,b) orc_mmx_emit_660f (p, "psignd", 0x38 0a, a, b) #define orc_mmx_emit_psignd(p,a,b) orc_mmx_emit_660f (p, "psignd", 0x38 0a, a, b)
#define orc_mmx_emit_pmulhrsw(p,a,b) orc_mmx_emit_660f (p, "pmulhrsw", 0x 380b, a, b) #define orc_mmx_emit_pmulhrsw(p,a,b) orc_mmx_emit_660f (p, "pmulhrsw", 0x 380b, a, b)
#define orc_mmx_emit_pabsb(p,a,b) orc_mmx_emit_660f (p, "pabsb", 0x381 c, a, b) #define orc_mmx_emit_pabsb(p,a,b) orc_mmx_emit_660f (p, "pabsb", 0x381 c, a, b)
#define orc_mmx_emit_pabsw(p,a,b) orc_mmx_emit_660f (p, "pabsw", 0x381 d, a, b) #define orc_mmx_emit_pabsw(p,a,b) orc_mmx_emit_660f (p, "pabsw", 0x381 d, a, b)
#define orc_mmx_emit_pabsd(p,a,b) orc_mmx_emit_660f (p, "pabsd", 0x381 e, a, b) #define orc_mmx_emit_pabsd(p,a,b) orc_mmx_emit_660f (p, "pabsd", 0x381 e, a, b)
/* MMX SSE4.1 instructions */
#define orc_mmx_emit_pmovsxbw(p,a,b) orc_mmx_emit_660f (p, "pmovsxbw", 0x
3820, a, b)
#define orc_mmx_emit_pmovsxbd(p,a,b) orc_mmx_emit_660f (p, "pmovsxbd", 0x
3821, a, b)
#define orc_mmx_emit_pmovsxbq(p,a,b) orc_mmx_emit_660f (p, "pmovsxbq", 0x
3822, a, b)
#define orc_mmx_emit_pmovsxwd(p,a,b) orc_mmx_emit_660f (p, "pmovsxwd", 0x
3823, a, b)
#define orc_mmx_emit_pmovsxwq(p,a,b) orc_mmx_emit_660f (p, "pmovsxwq", 0x
3824, a, b)
#define orc_mmx_emit_pmovsxdq(p,a,b) orc_mmx_emit_660f (p, "pmovsxdq", 0x
3825, a, b)
#define orc_mmx_emit_pmuldq(p,a,b) orc_mmx_emit_660f (p, "pmuldq", 0x38
28, a, b)
#define orc_mmx_emit_pcmpeqq(p,a,b) orc_mmx_emit_660f (p, "pcmpeqq", 0x3
829, a, b)
#define orc_mmx_emit_packusdw(p,a,b) orc_mmx_emit_660f (p, "packuswd", 0x
382b, a, b)
#define orc_mmx_emit_pmovzxbw(p,a,b) orc_mmx_emit_660f (p, "pmovzxbw", 0x
3830, a, b)
#define orc_mmx_emit_pmovzxbd(p,a,b) orc_mmx_emit_660f (p, "pmovzxbd", 0x
3831, a, b)
#define orc_mmx_emit_pmovzxbq(p,a,b) orc_mmx_emit_660f (p, "pmovzxbq", 0x
3832, a, b)
#define orc_mmx_emit_pmovzxwd(p,a,b) orc_mmx_emit_660f (p, "pmovzxwd", 0x
3833, a, b)
#define orc_mmx_emit_pmovzxwq(p,a,b) orc_mmx_emit_660f (p, "pmovzxwq", 0x
3834, a, b)
#define orc_mmx_emit_pmovzxdq(p,a,b) orc_mmx_emit_660f (p, "pmovzxdq", 0x
3835, a, b)
#define orc_mmx_emit_pmulld(p,a,b) orc_mmx_emit_660f (p, "pmuldq", 0x38
40, a, b)
#define orc_mmx_emit_phminposuw(p,a,b) orc_mmx_emit_660f (p, "phminposuw",
0x3841, a, b)
#define orc_mmx_emit_pminsb(p,a,b) orc_mmx_emit_660f (p, "pminsb", 0x38
38, a, b)
#define orc_mmx_emit_pminsd(p,a,b) orc_mmx_emit_660f (p, "pminsd", 0x38
39, a, b)
#define orc_mmx_emit_pminuw(p,a,b) orc_mmx_emit_660f (p, "pminuw", 0x38
3a, a, b)
#define orc_mmx_emit_pminud(p,a,b) orc_mmx_emit_660f (p, "pminud", 0x38
3b, a, b)
#define orc_mmx_emit_pmaxsb(p,a,b) orc_mmx_emit_660f (p, "pmaxsb", 0x38
3c, a, b)
#define orc_mmx_emit_pmaxsd(p,a,b) orc_mmx_emit_660f (p, "pmaxsd", 0x38
3d, a, b)
#define orc_mmx_emit_pmaxuw(p,a,b) orc_mmx_emit_660f (p, "pmaxuw", 0x38
3e, a, b)
#define orc_mmx_emit_pmaxud(p,a,b) orc_mmx_emit_660f (p, "pmaxud", 0x38
3f, a, b)
/* SSE4.2 instructions */
#define orc_mmx_emit_pcmpgtq(p,a,b) orc_mmx_emit_660f (p, "pcmpgtq", 0x3
837, a, b)
#endif #endif
 End of changes. 4 change blocks. 
0 lines changed or deleted 70 lines changed or added


 orcparse.h   orcparse.h 
#ifndef __ORC_PARSE_H__ #ifndef __ORC_PARSE_H__
#define __ORC_PARSE_H__ #define __ORC_PARSE_H__
#include <orc/orcutils.h> #include <orc/orcutils.h>
ORC_BEGIN_DECLS ORC_BEGIN_DECLS
int orc_parse (const char *code, OrcProgram ***programs); int orc_parse (const char *code, OrcProgram ***programs);
int orc_parse_full (const char *code, OrcProgram ***programs, char **log);
const char * orc_parse_get_init_function (OrcProgram *program);
ORC_END_DECLS ORC_END_DECLS
#endif #endif
 End of changes. 1 change blocks. 
0 lines changed or deleted 2 lines changed or added


 orcprogram.h   orcprogram.h 
skipping to change at line 21 skipping to change at line 21
typedef struct _OrcOpcodeSet OrcOpcodeSet; typedef struct _OrcOpcodeSet OrcOpcodeSet;
typedef struct _OrcStaticOpcode OrcStaticOpcode; typedef struct _OrcStaticOpcode OrcStaticOpcode;
typedef struct _OrcInstruction OrcInstruction; typedef struct _OrcInstruction OrcInstruction;
typedef struct _OrcProgram OrcProgram; typedef struct _OrcProgram OrcProgram;
typedef struct _OrcCompiler OrcCompiler; typedef struct _OrcCompiler OrcCompiler;
typedef struct _OrcRule OrcRule; typedef struct _OrcRule OrcRule;
typedef struct _OrcRuleSet OrcRuleSet; typedef struct _OrcRuleSet OrcRuleSet;
typedef struct _OrcConstant OrcConstant; typedef struct _OrcConstant OrcConstant;
typedef struct _OrcFixup OrcFixup; typedef struct _OrcFixup OrcFixup;
typedef struct _OrcTarget OrcTarget; typedef struct _OrcTarget OrcTarget;
typedef struct _OrcCode OrcCode;
typedef void (*OrcOpcodeEmulateFunc)(OrcOpcodeExecutor *ex, void *user); typedef void (*OrcOpcodeEmulateFunc)(OrcOpcodeExecutor *ex, void *user);
typedef void (*OrcOpcodeEmulateNFunc)(OrcOpcodeExecutor *ex, int index, int
n);
typedef void (*OrcOpcodeEmulate16Func)(OrcOpcodeExecutor *ex);
typedef void (*OrcRuleEmitFunc)(OrcCompiler *p, void *user, OrcInstruction *insn); typedef void (*OrcRuleEmitFunc)(OrcCompiler *p, void *user, OrcInstruction *insn);
typedef void (*OrcExecutorFunc)(OrcExecutor *ex); typedef void (*OrcExecutorFunc)(OrcExecutor *ex);
#define ORC_N_REGS (32*4) #define ORC_N_REGS (32*4)
#define ORC_N_INSNS 100 #define ORC_N_INSNS 100
#define ORC_N_VARIABLES 64 #define ORC_N_VARIABLES 64
#define ORC_N_ARRAYS 12 #define ORC_N_ARRAYS 12
#define ORC_N_REGISTERS 20 #define ORC_N_REGISTERS 20
#define ORC_N_FIXUPS 40 #define ORC_N_FIXUPS 100
#define ORC_N_CONSTANTS 20 #define ORC_N_CONSTANTS 20
#define ORC_N_LABELS 40 #define ORC_N_LABELS 40
#define ORC_N_COMPILER_VARIABLES (ORC_N_VARIABLES+32)
#define ORC_GP_REG_BASE 32 #define ORC_GP_REG_BASE 32
#define ORC_VEC_REG_BASE 64 #define ORC_VEC_REG_BASE 64
#define ORC_REG_INVALID 0 #define ORC_REG_INVALID 0
#define ORC_STATIC_OPCODE_N_SRC 4 #define ORC_STATIC_OPCODE_N_SRC 4
#define ORC_STATIC_OPCODE_N_DEST 2 #define ORC_STATIC_OPCODE_N_DEST 2
#define ORC_OPCODE_N_ARGS 4 #define ORC_OPCODE_N_ARGS 4
#define ORC_N_TARGETS 10 #define ORC_N_TARGETS 10
#define ORC_N_RULE_SETS 10 #define ORC_N_RULE_SETS 10
#define ORC_MAX_VAR_SIZE 8
#define ORC_STRUCT_OFFSET(struct_type, member) \ #define ORC_STRUCT_OFFSET(struct_type, member) \
((long) ((unsigned int *) &((struct_type*) 0)->member)) ((long) ((unsigned int *) &((struct_type*) 0)->member))
#ifndef TRUE #ifndef TRUE
#define TRUE 1 #define TRUE 1
#endif #endif
#ifndef FALSE #ifndef FALSE
#define FALSE 0 #define FALSE 0
#endif #endif
skipping to change at line 78 skipping to change at line 84
#define ORC_COMPILER_ERROR(compiler, ...) do { \ #define ORC_COMPILER_ERROR(compiler, ...) do { \
compiler->error = TRUE; \ compiler->error = TRUE; \
compiler->result = ORC_COMPILE_RESULT_UNKNOWN_PARSE; \ compiler->result = ORC_COMPILE_RESULT_UNKNOWN_PARSE; \
orc_debug_print(ORC_DEBUG_WARNING, __FILE__, ORC_FUNCTION, __LINE__, __VA _ARGS__); \ orc_debug_print(ORC_DEBUG_WARNING, __FILE__, ORC_FUNCTION, __LINE__, __VA _ARGS__); \
} while (0) } while (0)
enum { enum {
ORC_TARGET_C_C99 = (1<<0), ORC_TARGET_C_C99 = (1<<0),
ORC_TARGET_C_BARE = (1<<1), ORC_TARGET_C_BARE = (1<<1),
ORC_TARGET_C_NOEXEC = (1<<2), ORC_TARGET_C_NOEXEC = (1<<2),
ORC_TARGET_C_OPCODE = (1<<3),
ORC_TARGET_FAST_NAN = (1<<30), ORC_TARGET_FAST_NAN = (1<<30),
ORC_TARGET_FAST_DENORMAL = (1<<31) ORC_TARGET_FAST_DENORMAL = (1<<31)
}; };
enum { enum {
ORC_TARGET_ALTIVEC_ALTIVEC = (1<<0) ORC_TARGET_ALTIVEC_ALTIVEC = (1<<0)
}; };
enum { enum {
ORC_TARGET_NEON_CLEAN_COMPILE = (1<<0), ORC_TARGET_NEON_CLEAN_COMPILE = (1<<0),
ORC_TARGET_NEON_NEON = (1<<1) ORC_TARGET_NEON_NEON = (1<<1),
ORC_TARGET_NEON_EDSP = (1<<2)
};
enum {
ORC_TARGET_ARM_EDSP = (1<<2)
}; };
typedef enum { typedef enum {
ORC_VAR_TYPE_TEMP, ORC_VAR_TYPE_TEMP,
ORC_VAR_TYPE_SRC, ORC_VAR_TYPE_SRC,
ORC_VAR_TYPE_DEST, ORC_VAR_TYPE_DEST,
ORC_VAR_TYPE_CONST, ORC_VAR_TYPE_CONST,
ORC_VAR_TYPE_PARAM, ORC_VAR_TYPE_PARAM,
ORC_VAR_TYPE_ACCUMULATOR ORC_VAR_TYPE_ACCUMULATOR
} OrcVarType; } OrcVarType;
skipping to change at line 259 skipping to change at line 271
int n_opcodes; int n_opcodes;
OrcStaticOpcode *opcodes; OrcStaticOpcode *opcodes;
}; };
#define ORC_STATIC_OPCODE_ACCUMULATOR (1<<0) #define ORC_STATIC_OPCODE_ACCUMULATOR (1<<0)
#define ORC_STATIC_OPCODE_FLOAT_SRC (1<<1) #define ORC_STATIC_OPCODE_FLOAT_SRC (1<<1)
#define ORC_STATIC_OPCODE_FLOAT_DEST (1<<2) #define ORC_STATIC_OPCODE_FLOAT_DEST (1<<2)
#define ORC_STATIC_OPCODE_FLOAT (ORC_STATIC_OPCODE_FLOAT_SRC|ORC_STATIC_OPC ODE_FLOAT_DEST) #define ORC_STATIC_OPCODE_FLOAT (ORC_STATIC_OPCODE_FLOAT_SRC|ORC_STATIC_OPC ODE_FLOAT_DEST)
#define ORC_STATIC_OPCODE_SCALAR (1<<3) #define ORC_STATIC_OPCODE_SCALAR (1<<3)
#define ORC_STATIC_OPCODE_LOAD (1<<4)
#define ORC_STATIC_OPCODE_STORE (1<<5)
#define ORC_STATIC_OPCODE_INVARIANT (1<<6)
#define ORC_STATIC_OPCODE_ITERATOR (1<<7)
struct _OrcStaticOpcode { struct _OrcStaticOpcode {
char name[16]; char name[16];
OrcOpcodeEmulateFunc emulate;
void *emulate_user;
unsigned int flags; unsigned int flags;
int dest_size[ORC_STATIC_OPCODE_N_DEST]; int dest_size[ORC_STATIC_OPCODE_N_DEST];
int src_size[ORC_STATIC_OPCODE_N_SRC]; int src_size[ORC_STATIC_OPCODE_N_SRC];
OrcOpcodeEmulateNFunc emulateN;
}; };
/** /**
* OrcInstruction: * OrcInstruction:
* *
* The OrcInstruction structure has no public members * The OrcInstruction structure has no public members
*/ */
struct _OrcInstruction { struct _OrcInstruction {
/*< private >*/ /*< private >*/
OrcStaticOpcode *opcode; OrcStaticOpcode *opcode;
int dest_args[ORC_STATIC_OPCODE_N_DEST]; int dest_args[ORC_STATIC_OPCODE_N_DEST];
int src_args[ORC_STATIC_OPCODE_N_SRC]; int src_args[ORC_STATIC_OPCODE_N_SRC];
OrcRule *rule; OrcRule *rule;
unsigned int flags;
}; };
#define ORC_INSTRUCTION_FLAG_X2 (1<<0)
#define ORC_INSTRUCTION_FLAG_X4 (1<<1)
#define ORC_INSN_FLAG_INVARIANT (1<<2)
#define ORC_INSN_FLAG_ADDED (1<<3)
/** /**
* OrcConstant: * OrcConstant:
* *
* The OrcConstant structure has no public members * The OrcConstant structure has no public members
*/ */
struct _OrcConstant { struct _OrcConstant {
/*< private >*/ /*< private >*/
int type; int type;
int alloc_reg; int alloc_reg;
unsigned int value; unsigned int value;
skipping to change at line 316 skipping to change at line 338
int label; int label;
}; };
/** /**
* OrcProgram: * OrcProgram:
* *
* The OrcProgram structure has no public members * The OrcProgram structure has no public members
*/ */
struct _OrcProgram { struct _OrcProgram {
/*< private >*/ /*< private >*/
OrcInstruction insns[ORC_N_INSNS]; struct {
OrcStaticOpcode *opcode;
int dest_args[ORC_STATIC_OPCODE_N_DEST];
int src_args[ORC_STATIC_OPCODE_N_SRC];
OrcRule *rule;
} _unused[ORC_N_INSNS]; /* needed for ABI compatibility */
int n_insns; int n_insns;
OrcVariable vars[ORC_N_VARIABLES]; OrcVariable vars[ORC_N_VARIABLES];
int n_src_vars; int n_src_vars;
int n_dest_vars; int n_dest_vars;
int n_param_vars; int n_param_vars;
int n_const_vars; int n_const_vars;
int n_temp_vars; int n_temp_vars;
int n_accum_vars; int n_accum_vars;
char *name; char *name;
char *asm_code; char *asm_code;
unsigned char *code; unsigned char *code;
void *code_exec; void *code_exec;
int code_size; int code_size;
OrcInstruction insns[ORC_N_INSNS];
void *backup_func; void *backup_func;
int is_2d; int is_2d;
int constant_n; int constant_n;
int constant_m; int constant_m;
OrcCode *orccode;
/* Hide this here. Belongs in a Parser object */
char *init_function;
}; };
/** /**
* OrcCompiler: * OrcCompiler:
* *
* The OrcCompiler structure has no public members * The OrcCompiler structure has no public members
*/ */
struct _OrcCompiler { struct _OrcCompiler {
/*< private >*/ /*< private >*/
OrcProgram *program; OrcProgram *program;
OrcTarget *target; OrcTarget *target;
unsigned int target_flags; unsigned int target_flags;
OrcInstruction insns[ORC_N_INSNS]; OrcInstruction insns[ORC_N_INSNS];
int n_insns; int n_insns;
OrcVariable vars[ORC_N_VARIABLES]; OrcVariable vars[ORC_N_COMPILER_VARIABLES];
int n_temp_vars; int n_temp_vars;
int n_dup_vars; int n_dup_vars;
unsigned char *codeptr; unsigned char *codeptr;
OrcConstant constants[ORC_N_CONSTANTS]; OrcConstant constants[ORC_N_CONSTANTS];
int n_constants; int n_constants;
OrcFixup fixups[ORC_N_FIXUPS]; OrcFixup fixups[ORC_N_FIXUPS];
int n_fixups; int n_fixups;
skipping to change at line 390 skipping to change at line 425
char *asm_code; char *asm_code;
int asm_code_len; int asm_code_len;
int is_64bit; int is_64bit;
int tmpreg; int tmpreg;
int exec_reg; int exec_reg;
int gp_tmpreg; int gp_tmpreg;
int insn_index; int insn_index;
int unroll_index;
int need_mask_regs; int need_mask_regs;
int unroll_shift; int unroll_shift;
int alloc_loop_counter; int alloc_loop_counter;
int allow_gp_on_stack;
int loop_counter; int loop_counter;
int size_region; int size_region;
int has_iterator_opcode;
int offset;
int min_temp_reg;
int max_used_temp_reg;
int insn_shift; /* used when emitting rules */
}; };
#define ORC_SRC_ARG(p,i,n) ((p)->vars[(i)->src_args[(n)]].alloc) #define ORC_SRC_ARG(p,i,n) ((p)->vars[(i)->src_args[(n)]].alloc)
#define ORC_DEST_ARG(p,i,n) ((p)->vars[(i)->dest_args[(n)]].alloc) #define ORC_DEST_ARG(p,i,n) ((p)->vars[(i)->dest_args[(n)]].alloc)
#define ORC_SRC_TYPE(p,i,n) ((p)->vars[(i)->src_args[(n)]].vartype) #define ORC_SRC_TYPE(p,i,n) ((p)->vars[(i)->src_args[(n)]].vartype)
#define ORC_DEST_TYPE(p,i,n) ((p)->vars[(i)->dest_args[(n)]].vartype) #define ORC_DEST_TYPE(p,i,n) ((p)->vars[(i)->dest_args[(n)]].vartype)
#define ORC_SRC_VAL(p,i,n) ((p)->vars[(i)->src_args[(n)]].value) #define ORC_SRC_VAL(p,i,n) ((p)->vars[(i)->src_args[(n)]].value)
#define ORC_DEST_VAL(p,i,n) ((p)->vars[(i)->dest_args[(n)]].value) #define ORC_DEST_VAL(p,i,n) ((p)->vars[(i)->dest_args[(n)]].value)
/** /**
* OrcOpcodeExecutor: * OrcOpcodeExecutor:
* *
* The OrcOpcodeExecutor structure has no public members * The OrcOpcodeExecutor structure has no public members
*/ */
struct _OrcOpcodeExecutor { struct _OrcOpcodeExecutor {
/*< private >*/ /*< private >*/
int src_values[ORC_STATIC_OPCODE_N_SRC]; int src_values[ORC_STATIC_OPCODE_N_SRC];
int dest_values[ORC_STATIC_OPCODE_N_DEST]; int dest_values[ORC_STATIC_OPCODE_N_DEST];
OrcOpcodeEmulateNFunc emulateN;
void *src_ptrs[ORC_STATIC_OPCODE_N_SRC];
void *dest_ptrs[ORC_STATIC_OPCODE_N_DEST];
int shift;
}; };
/** /**
* OrcExecutor: * OrcExecutor:
* *
*/ */
struct _OrcExecutor { struct _OrcExecutor {
/*< private >*/ /*< private >*/
OrcProgram *program; OrcProgram *program;
int n; int n;
skipping to change at line 467 skipping to change at line 517
int src_resample[8]; int src_resample[8];
int params[ORC_VAR_T1-ORC_VAR_P1]; int params[ORC_VAR_T1-ORC_VAR_P1];
int unused3[ORC_N_VARIABLES - ORC_VAR_T1]; int unused3[ORC_N_VARIABLES - ORC_VAR_T1];
int accumulators[4]; int accumulators[4];
}; };
#define ORC_EXECUTOR_EXEC(ex) ((OrcExecutorFunc)((ex)->arrays[ORC_VAR_A1])) #define ORC_EXECUTOR_EXEC(ex) ((OrcExecutorFunc)((ex)->arrays[ORC_VAR_A1]))
#define ORC_EXECUTOR_M(ex) ((ex)->params[ORC_VAR_A1]) #define ORC_EXECUTOR_M(ex) ((ex)->params[ORC_VAR_A1])
#define ORC_EXECUTOR_M_INDEX(ex) ((ex)->params[ORC_VAR_A2]) #define ORC_EXECUTOR_M_INDEX(ex) ((ex)->params[ORC_VAR_A2])
#define ORC_EXECUTOR_TIME(ex) ((ex)->params[ORC_VAR_A3]) #define ORC_EXECUTOR_TIME(ex) ((ex)->params[ORC_VAR_A3])
struct _OrcCode {
/*< private >*/
OrcCompileResult result;
char *name;
/* for execution */
OrcExecutorFunc exec;
unsigned char *code;
int code_size;
/* for emulation */
int n_insns;
OrcInstruction *insns;
OrcVariable *vars;
int is_2d;
int constant_n;
int constant_m;
};
/** /**
* OrcTarget: * OrcTarget:
* *
*/ */
struct _OrcTarget { struct _OrcTarget {
const char *name; const char *name;
orc_bool executable; orc_bool executable;
int data_register_offset; int data_register_offset;
unsigned int (*get_default_flags)(void); unsigned int (*get_default_flags)(void);
skipping to change at line 507 skipping to change at line 576
OrcStaticOpcode * orc_opcode_find_by_name (const char *name); OrcStaticOpcode * orc_opcode_find_by_name (const char *name);
void orc_opcode_init (void); void orc_opcode_init (void);
const char * orc_program_get_name (OrcProgram *program); const char * orc_program_get_name (OrcProgram *program);
void orc_program_set_name (OrcProgram *program, const char *name); void orc_program_set_name (OrcProgram *program, const char *name);
void orc_program_set_2d (OrcProgram *program); void orc_program_set_2d (OrcProgram *program);
void orc_program_set_constant_n (OrcProgram *program, int n); void orc_program_set_constant_n (OrcProgram *program, int n);
void orc_program_set_constant_m (OrcProgram *program, int m); void orc_program_set_constant_m (OrcProgram *program, int m);
void orc_program_append (OrcProgram *p, const char *opcode, int arg0, int a rg1, int arg2); void orc_program_append (OrcProgram *p, const char *opcode, int arg0, int a rg1, int arg2);
void orc_program_append_2 (OrcProgram *program, const char *name,
unsigned int flags, int arg0, int arg1, int arg2, int arg3);
void orc_program_append_str (OrcProgram *p, const char *opcode, void orc_program_append_str (OrcProgram *p, const char *opcode,
const char * arg0, const char * arg1, const char * arg2); const char * arg0, const char * arg1, const char * arg2);
void orc_program_append_str_2 (OrcProgram *program, const char *name,
unsigned int flags, const char *arg1, const char *arg2, const char *arg
3,
const char *arg4);
void orc_program_append_ds (OrcProgram *program, const char *opcode, int ar g0, void orc_program_append_ds (OrcProgram *program, const char *opcode, int ar g0,
int arg1); int arg1);
void orc_program_append_ds_str (OrcProgram *p, const char *opcode, void orc_program_append_ds_str (OrcProgram *p, const char *opcode,
const char * arg0, const char * arg1); const char * arg0, const char * arg1);
void orc_program_append_dds_str (OrcProgram *program, const char *name, void orc_program_append_dds_str (OrcProgram *program, const char *name,
const char *arg1, const char *arg2, const char *arg3); const char *arg1, const char *arg2, const char *arg3);
void orc_mmx_init (void); void orc_mmx_init (void);
void orc_sse_init (void); void orc_sse_init (void);
void orc_arm_init (void); void orc_arm_init (void);
skipping to change at line 559 skipping to change at line 633
void orc_executor_set_stride (OrcExecutor *ex, int var, int stride); void orc_executor_set_stride (OrcExecutor *ex, int var, int stride);
void orc_executor_set_array_str (OrcExecutor *ex, const char *name, void *p tr); void orc_executor_set_array_str (OrcExecutor *ex, const char *name, void *p tr);
void orc_executor_set_param (OrcExecutor *ex, int var, int value); void orc_executor_set_param (OrcExecutor *ex, int var, int value);
void orc_executor_set_param_str (OrcExecutor *ex, const char *name, int val ue); void orc_executor_set_param_str (OrcExecutor *ex, const char *name, int val ue);
int orc_executor_get_accumulator (OrcExecutor *ex, int var); int orc_executor_get_accumulator (OrcExecutor *ex, int var);
int orc_executor_get_accumulator_str (OrcExecutor *ex, const char *name); int orc_executor_get_accumulator_str (OrcExecutor *ex, const char *name);
void orc_executor_set_n (OrcExecutor *ex, int n); void orc_executor_set_n (OrcExecutor *ex, int n);
void orc_executor_set_m (OrcExecutor *ex, int m); void orc_executor_set_m (OrcExecutor *ex, int m);
void orc_executor_emulate (OrcExecutor *ex); void orc_executor_emulate (OrcExecutor *ex);
void orc_executor_run (OrcExecutor *ex); void orc_executor_run (OrcExecutor *ex);
void orc_executor_run_backup (OrcExecutor *ex);
OrcOpcodeSet *orc_opcode_set_get (const char *name); OrcOpcodeSet *orc_opcode_set_get (const char *name);
OrcOpcodeSet *orc_opcode_set_get_nth (int opcode_major); OrcOpcodeSet *orc_opcode_set_get_nth (int opcode_major);
int orc_opcode_set_find_by_name (OrcOpcodeSet *opcode_set, const char *name ); int orc_opcode_set_find_by_name (OrcOpcodeSet *opcode_set, const char *name );
int orc_opcode_register_static (OrcStaticOpcode *sopcode, char *prefix); int orc_opcode_register_static (OrcStaticOpcode *sopcode, char *prefix);
OrcRuleSet * orc_rule_set_new (OrcOpcodeSet *opcode_set, OrcTarget *target, OrcRuleSet * orc_rule_set_new (OrcOpcodeSet *opcode_set, OrcTarget *target,
unsigned int required_flags); unsigned int required_flags);
void orc_rule_register (OrcRuleSet *rule_set, const char *opcode_name, void orc_rule_register (OrcRuleSet *rule_set, const char *opcode_name,
OrcRuleEmitFunc emit, void *emit_user); OrcRuleEmitFunc emit, void *emit_user);
skipping to change at line 581 skipping to change at line 656
OrcTarget * orc_target_get_default (void); OrcTarget * orc_target_get_default (void);
unsigned int orc_target_get_default_flags (OrcTarget *target); unsigned int orc_target_get_default_flags (OrcTarget *target);
const char * orc_target_get_name (OrcTarget *target); const char * orc_target_get_name (OrcTarget *target);
const char * orc_target_get_flag_name (OrcTarget *target, int shift); const char * orc_target_get_flag_name (OrcTarget *target, int shift);
int orc_program_allocate_register (OrcProgram *program, int is_data); int orc_program_allocate_register (OrcProgram *program, int is_data);
void orc_compiler_allocate_codemem (OrcCompiler *compiler); void orc_compiler_allocate_codemem (OrcCompiler *compiler);
int orc_compiler_label_new (OrcCompiler *compiler); int orc_compiler_label_new (OrcCompiler *compiler);
int orc_compiler_get_constant (OrcCompiler *compiler, int size, int value); int orc_compiler_get_constant (OrcCompiler *compiler, int size, int value);
int orc_compiler_get_temp_constant (OrcCompiler *compiler, int size, int va
lue);
int orc_compiler_get_temp_reg (OrcCompiler *compiler);
int orc_compiler_get_constant_reg (OrcCompiler *compiler);
const char *orc_program_get_asm_code (OrcProgram *program); const char *orc_program_get_asm_code (OrcProgram *program);
const char *orc_target_get_asm_preamble (const char *target); const char *orc_target_get_asm_preamble (const char *target);
const char * orc_target_get_preamble (OrcTarget *target); const char * orc_target_get_preamble (OrcTarget *target);
const char * orc_target_c_get_typedefs (void); const char * orc_target_c_get_typedefs (void);
void orc_compiler_append_code (OrcCompiler *p, const char *fmt, ...) void orc_compiler_append_code (OrcCompiler *p, const char *fmt, ...)
ORC_GNU_PRINTF(2,3); ORC_GNU_PRINTF(2,3);
void orc_target_register (OrcTarget *target); void orc_target_register (OrcTarget *target);
OrcTarget *orc_target_get_by_name (const char *target_name); OrcTarget *orc_target_get_by_name (const char *target_name);
int orc_program_get_max_var_size (OrcProgram *program); int orc_program_get_max_var_size (OrcProgram *program);
int orc_program_get_max_array_size (OrcProgram *program); int orc_program_get_max_array_size (OrcProgram *program);
int orc_program_get_max_accumulator_size (OrcProgram *program); int orc_program_get_max_accumulator_size (OrcProgram *program);
void orc_get_data_cache_sizes (int *level1, int *level2, int *level3); void orc_get_data_cache_sizes (int *level1, int *level2, int *level3);
OrcCode * orc_code_new (void);
void orc_code_free (OrcCode *code);
#ifdef ORC_ENABLE_UNSTABLE_API #ifdef ORC_ENABLE_UNSTABLE_API
int orc_compiler_flag_check (const char *flag); int orc_compiler_flag_check (const char *flag);
extern int _orc_data_cache_size_level1; extern int _orc_data_cache_size_level1;
extern int _orc_data_cache_size_level2; extern int _orc_data_cache_size_level2;
extern int _orc_data_cache_size_level3; extern int _orc_data_cache_size_level3;
extern int _orc_compiler_flag_backup; extern int _orc_compiler_flag_backup;
extern int _orc_compiler_flag_debug; extern int _orc_compiler_flag_debug;
 End of changes. 26 change blocks. 
6 lines changed or deleted 90 lines changed or added


 orcsse.h   orcsse.h 
skipping to change at line 67 skipping to change at line 67
void orc_sse_emit_660f (OrcCompiler *p, const char *insn_name, int code, void orc_sse_emit_660f (OrcCompiler *p, const char *insn_name, int code,
int src, int dest); int src, int dest);
void orc_sse_emit_f20f (OrcCompiler *p, const char *insn_name, int code, void orc_sse_emit_f20f (OrcCompiler *p, const char *insn_name, int code,
int src, int dest); int src, int dest);
void orc_sse_emit_f30f (OrcCompiler *p, const char *insn_name, int code, void orc_sse_emit_f30f (OrcCompiler *p, const char *insn_name, int code,
int src, int dest); int src, int dest);
void orc_sse_emit_0f (OrcCompiler *p, const char *insn_name, int code, void orc_sse_emit_0f (OrcCompiler *p, const char *insn_name, int code,
int src, int dest); int src, int dest);
void orc_sse_emit_pshufd (OrcCompiler *p, int shuf, int src, int dest); void orc_sse_emit_pshufd (OrcCompiler *p, int shuf, int src, int dest);
void orc_sse_emit_pshuflw (OrcCompiler *p, int shuf, int src, int dest); void orc_sse_emit_pshuflw (OrcCompiler *p, int shuf, int src, int dest);
void orc_sse_emit_pshufhw (OrcCompiler *p, int shuf, int src, int dest);
void orc_sse_emit_palignr (OrcCompiler *p, int align, int src, int dest);
void orc_sse_emit_pinsrw_memoffset (OrcCompiler *p, int imm, int offset, in
t src, int dest);
void orc_sse_emit_pextrw_memoffset (OrcCompiler *p, int imm, int src, int o
ffset, int dest);
void orc_sse_emit_shiftimm (OrcCompiler *p, const char *insn_name, void orc_sse_emit_shiftimm (OrcCompiler *p, const char *insn_name,
int code, int modrm_code, int shift, int reg); int code, int modrm_code, int shift, int reg);
void orc_sse_set_mxcsr (OrcCompiler *compiler); void orc_sse_set_mxcsr (OrcCompiler *compiler);
void orc_sse_restore_mxcsr (OrcCompiler *compiler); void orc_sse_restore_mxcsr (OrcCompiler *compiler);
void sse_load_constant (OrcCompiler *compiler, int reg, int size, int value
);
unsigned int orc_sse_get_cpu_flags (void); unsigned int orc_sse_get_cpu_flags (void);
/* SSE instructions */ /* SSE instructions */
/* SSE2 instructions */ /* SSE2 instructions */
#define orc_sse_emit_punpcklbw(p,a,b) orc_sse_emit_660f (p, "punpcklbw", 0 x60, a, b) #define orc_sse_emit_punpcklbw(p,a,b) orc_sse_emit_660f (p, "punpcklbw", 0 x60, a, b)
#define orc_sse_emit_punpcklwd(p,a,b) orc_sse_emit_660f (p, "punpcklwd", 0 x61, a, b) #define orc_sse_emit_punpcklwd(p,a,b) orc_sse_emit_660f (p, "punpcklwd", 0 x61, a, b)
#define orc_sse_emit_punpckldq(p,a,b) orc_sse_emit_660f (p, "punpckldq", 0 x62, a, b) #define orc_sse_emit_punpckldq(p,a,b) orc_sse_emit_660f (p, "punpckldq", 0 x62, a, b)
#define orc_sse_emit_packsswb(p,a,b) orc_sse_emit_660f (p, "packsswb", 0x 63, a, b) #define orc_sse_emit_packsswb(p,a,b) orc_sse_emit_660f (p, "packsswb", 0x 63, a, b)
#define orc_sse_emit_pcmpgtb(p,a,b) orc_sse_emit_660f (p, "pcmpgtb", 0x6 4, a, b) #define orc_sse_emit_pcmpgtb(p,a,b) orc_sse_emit_660f (p, "pcmpgtb", 0x6 4, a, b)
skipping to change at line 106 skipping to change at line 112
#define orc_sse_emit_psrlw(p,a,b) orc_sse_emit_shiftimm (p, "psrlw", 0 x71, 2, a, b) #define orc_sse_emit_psrlw(p,a,b) orc_sse_emit_shiftimm (p, "psrlw", 0 x71, 2, a, b)
#define orc_sse_emit_psllw(p,a,b) orc_sse_emit_shiftimm (p, "psllw", 0 x71, 6, a, b) #define orc_sse_emit_psllw(p,a,b) orc_sse_emit_shiftimm (p, "psllw", 0 x71, 6, a, b)
#define orc_sse_emit_psrad(p,a,b) orc_sse_emit_shiftimm (p, "psrad", 0 x72, 4, a, b) #define orc_sse_emit_psrad(p,a,b) orc_sse_emit_shiftimm (p, "psrad", 0 x72, 4, a, b)
#define orc_sse_emit_psrld(p,a,b) orc_sse_emit_shiftimm (p, "psrld", 0 x72, 2, a, b) #define orc_sse_emit_psrld(p,a,b) orc_sse_emit_shiftimm (p, "psrld", 0 x72, 2, a, b)
#define orc_sse_emit_pslld(p,a,b) orc_sse_emit_shiftimm (p, "pslld", 0 x72, 6, a, b) #define orc_sse_emit_pslld(p,a,b) orc_sse_emit_shiftimm (p, "pslld", 0 x72, 6, a, b)
#define orc_sse_emit_psrlq(p,a,b) orc_sse_emit_shiftimm (p, "psrlq", 0 x73, 2, a, b) #define orc_sse_emit_psrlq(p,a,b) orc_sse_emit_shiftimm (p, "psrlq", 0 x73, 2, a, b)
#define orc_sse_emit_psllq(p,a,b) orc_sse_emit_shiftimm (p, "psllq", 0 x73, 6, a, b) #define orc_sse_emit_psllq(p,a,b) orc_sse_emit_shiftimm (p, "psllq", 0 x73, 6, a, b)
#define orc_sse_emit_psrldq(p,a,b) orc_sse_emit_shiftimm (p, "psrldq", 0x73, 3, a, b) #define orc_sse_emit_psrldq(p,a,b) orc_sse_emit_shiftimm (p, "psrldq", 0x73, 3, a, b)
#define orc_sse_emit_pslldq(p,a,b) orc_sse_emit_shiftimm (p, "pslldq", 0x73, 7, a, b) #define orc_sse_emit_pslldq(p,a,b) orc_sse_emit_shiftimm (p, "pslldq", 0x73, 7, a, b)
#define orc_sse_emit_psrlq_reg(p,a,b) orc_sse_emit_660f (p, "psrlq", 0
xd3, a, b)
#define orc_sse_emit_pcmpeqb(p,a,b) orc_sse_emit_660f (p, "pcmpeqb", 0x7 4, a, b) #define orc_sse_emit_pcmpeqb(p,a,b) orc_sse_emit_660f (p, "pcmpeqb", 0x7 4, a, b)
#define orc_sse_emit_pcmpeqw(p,a,b) orc_sse_emit_660f (p, "pcmpeqw", 0x7 5, a, b) #define orc_sse_emit_pcmpeqw(p,a,b) orc_sse_emit_660f (p, "pcmpeqw", 0x7 5, a, b)
#define orc_sse_emit_pcmpeqd(p,a,b) orc_sse_emit_660f (p, "pcmpeqd", 0x7 6, a, b) #define orc_sse_emit_pcmpeqd(p,a,b) orc_sse_emit_660f (p, "pcmpeqd", 0x7 6, a, b)
#define orc_sse_emit_pinsrw(p,a,b) orc_sse_emit_660f (p, "pinsrw", 0xc4
, a, b)
#define orc_sse_emit_pextrw(p,a,b) orc_sse_emit_660f (p, "pextrw", 0xc5
, a, b)
#define orc_sse_emit_paddq(p,a,b) orc_sse_emit_660f (p, "paddq", 0xd4, a, b) #define orc_sse_emit_paddq(p,a,b) orc_sse_emit_660f (p, "paddq", 0xd4, a, b)
#define orc_sse_emit_pmullw(p,a,b) orc_sse_emit_660f (p, "pmullw", 0xd5 , a, b) #define orc_sse_emit_pmullw(p,a,b) orc_sse_emit_660f (p, "pmullw", 0xd5 , a, b)
#define orc_sse_emit_psubusb(p,a,b) orc_sse_emit_660f (p, "psubusb", 0xd 8, a, b) #define orc_sse_emit_psubusb(p,a,b) orc_sse_emit_660f (p, "psubusb", 0xd 8, a, b)
#define orc_sse_emit_psubusw(p,a,b) orc_sse_emit_660f (p, "psubusw", 0xd 9, a, b) #define orc_sse_emit_psubusw(p,a,b) orc_sse_emit_660f (p, "psubusw", 0xd 9, a, b)
#define orc_sse_emit_pminub(p,a,b) orc_sse_emit_660f (p, "pminub", 0xda , a, b) #define orc_sse_emit_pminub(p,a,b) orc_sse_emit_660f (p, "pminub", 0xda , a, b)
#define orc_sse_emit_pand(p,a,b) orc_sse_emit_660f (p, "pand", 0xdb, a, b) #define orc_sse_emit_pand(p,a,b) orc_sse_emit_660f (p, "pand", 0xdb, a, b)
#define orc_sse_emit_paddusb(p,a,b) orc_sse_emit_660f (p, "paddusb", 0xd c, a, b) #define orc_sse_emit_paddusb(p,a,b) orc_sse_emit_660f (p, "paddusb", 0xd c, a, b)
#define orc_sse_emit_paddusw(p,a,b) orc_sse_emit_660f (p, "paddusw", 0xd d, a, b) #define orc_sse_emit_paddusw(p,a,b) orc_sse_emit_660f (p, "paddusw", 0xd d, a, b)
#define orc_sse_emit_pmaxub(p,a,b) orc_sse_emit_660f (p, "pmaxub", 0xde , a, b) #define orc_sse_emit_pmaxub(p,a,b) orc_sse_emit_660f (p, "pmaxub", 0xde , a, b)
#define orc_sse_emit_pandn(p,a,b) orc_sse_emit_660f (p, "pandn", 0xdf, a, b) #define orc_sse_emit_pandn(p,a,b) orc_sse_emit_660f (p, "pandn", 0xdf, a, b)
#define orc_sse_emit_pavgb(p,a,b) orc_sse_emit_660f (p, "pavgb", 0xe0, a, b) #define orc_sse_emit_pavgb(p,a,b) orc_sse_emit_660f (p, "pavgb", 0xe0, a, b)
#define orc_sse_emit_pavgw(p,a,b) orc_sse_emit_660f (p, "pavgw", 0xe3, a, b) #define orc_sse_emit_pavgw(p,a,b) orc_sse_emit_660f (p, "pavgw", 0xe3, a, b)
#define orc_sse_emit_pmulhuw(p,a,b) orc_sse_emit_660f (p, "pmulhuw", 0x e4, a, b)
#define orc_sse_emit_pmulhw(p,a,b) orc_sse_emit_660f (p, "pmulhw", 0xe5 , a, b) #define orc_sse_emit_pmulhw(p,a,b) orc_sse_emit_660f (p, "pmulhw", 0xe5 , a, b)
#define orc_sse_emit_psubsb(p,a,b) orc_sse_emit_660f (p, "psubsb", 0xe8 , a, b) #define orc_sse_emit_psubsb(p,a,b) orc_sse_emit_660f (p, "psubsb", 0xe8 , a, b)
#define orc_sse_emit_psubsw(p,a,b) orc_sse_emit_660f (p, "psubsw", 0xe9 , a, b) #define orc_sse_emit_psubsw(p,a,b) orc_sse_emit_660f (p, "psubsw", 0xe9 , a, b)
#define orc_sse_emit_pminsw(p,a,b) orc_sse_emit_660f (p, "pminsw", 0xea , a, b) #define orc_sse_emit_pminsw(p,a,b) orc_sse_emit_660f (p, "pminsw", 0xea , a, b)
#define orc_sse_emit_por(p,a,b) orc_sse_emit_660f (p, "por", 0xeb, a , b) #define orc_sse_emit_por(p,a,b) orc_sse_emit_660f (p, "por", 0xeb, a , b)
#define orc_sse_emit_paddsb(p,a,b) orc_sse_emit_660f (p, "paddsb", 0xec , a, b) #define orc_sse_emit_paddsb(p,a,b) orc_sse_emit_660f (p, "paddsb", 0xec , a, b)
#define orc_sse_emit_paddsw(p,a,b) orc_sse_emit_660f (p, "paddsw", 0xed , a, b) #define orc_sse_emit_paddsw(p,a,b) orc_sse_emit_660f (p, "paddsw", 0xed , a, b)
#define orc_sse_emit_pmaxsw(p,a,b) orc_sse_emit_660f (p, "pmaxsw", 0xee , a, b) #define orc_sse_emit_pmaxsw(p,a,b) orc_sse_emit_660f (p, "pmaxsw", 0xee , a, b)
#define orc_sse_emit_pxor(p,a,b) orc_sse_emit_660f (p, "pxor", 0xef, a, b) #define orc_sse_emit_pxor(p,a,b) orc_sse_emit_660f (p, "pxor", 0xef, a, b)
skipping to change at line 191 skipping to change at line 197
#define orc_sse_emit_packusdw(p,a,b) orc_sse_emit_660f (p, "packuswd", 0x 382b, a, b) #define orc_sse_emit_packusdw(p,a,b) orc_sse_emit_660f (p, "packuswd", 0x 382b, a, b)
#define orc_sse_emit_pmovzxbw(p,a,b) orc_sse_emit_660f (p, "pmovzxbw", 0x 3830, a, b) #define orc_sse_emit_pmovzxbw(p,a,b) orc_sse_emit_660f (p, "pmovzxbw", 0x 3830, a, b)
#define orc_sse_emit_pmovzxbd(p,a,b) orc_sse_emit_660f (p, "pmovzxbd", 0x 3831, a, b) #define orc_sse_emit_pmovzxbd(p,a,b) orc_sse_emit_660f (p, "pmovzxbd", 0x 3831, a, b)
#define orc_sse_emit_pmovzxbq(p,a,b) orc_sse_emit_660f (p, "pmovzxbq", 0x 3832, a, b) #define orc_sse_emit_pmovzxbq(p,a,b) orc_sse_emit_660f (p, "pmovzxbq", 0x 3832, a, b)
#define orc_sse_emit_pmovzxwd(p,a,b) orc_sse_emit_660f (p, "pmovzxwd", 0x 3833, a, b) #define orc_sse_emit_pmovzxwd(p,a,b) orc_sse_emit_660f (p, "pmovzxwd", 0x 3833, a, b)
#define orc_sse_emit_pmovzxwq(p,a,b) orc_sse_emit_660f (p, "pmovzxwq", 0x 3834, a, b) #define orc_sse_emit_pmovzxwq(p,a,b) orc_sse_emit_660f (p, "pmovzxwq", 0x 3834, a, b)
#define orc_sse_emit_pmovzxdq(p,a,b) orc_sse_emit_660f (p, "pmovzxdq", 0x 3835, a, b) #define orc_sse_emit_pmovzxdq(p,a,b) orc_sse_emit_660f (p, "pmovzxdq", 0x 3835, a, b)
#define orc_sse_emit_pmulld(p,a,b) orc_sse_emit_660f (p, "pmuldq", 0x38 40, a, b) #define orc_sse_emit_pmulld(p,a,b) orc_sse_emit_660f (p, "pmulld", 0x38 40, a, b)
#define orc_sse_emit_phminposuw(p,a,b) orc_sse_emit_660f (p, "phminposuw", 0x3841, a, b) #define orc_sse_emit_phminposuw(p,a,b) orc_sse_emit_660f (p, "phminposuw", 0x3841, a, b)
#define orc_sse_emit_pminsb(p,a,b) orc_sse_emit_660f (p, "pminsb", 0x38 38, a, b) #define orc_sse_emit_pminsb(p,a,b) orc_sse_emit_660f (p, "pminsb", 0x38 38, a, b)
#define orc_sse_emit_pminsd(p,a,b) orc_sse_emit_660f (p, "pminsd", 0x38 39, a, b) #define orc_sse_emit_pminsd(p,a,b) orc_sse_emit_660f (p, "pminsd", 0x38 39, a, b)
#define orc_sse_emit_pminuw(p,a,b) orc_sse_emit_660f (p, "pminuw", 0x38 3a, a, b) #define orc_sse_emit_pminuw(p,a,b) orc_sse_emit_660f (p, "pminuw", 0x38 3a, a, b)
#define orc_sse_emit_pminud(p,a,b) orc_sse_emit_660f (p, "pminud", 0x38 3b, a, b) #define orc_sse_emit_pminud(p,a,b) orc_sse_emit_660f (p, "pminud", 0x38 3b, a, b)
#define orc_sse_emit_pmaxsb(p,a,b) orc_sse_emit_660f (p, "pmaxsb", 0x38 3c, a, b) #define orc_sse_emit_pmaxsb(p,a,b) orc_sse_emit_660f (p, "pmaxsb", 0x38 3c, a, b)
#define orc_sse_emit_pmaxsd(p,a,b) orc_sse_emit_660f (p, "pmaxsd", 0x38 3d, a, b) #define orc_sse_emit_pmaxsd(p,a,b) orc_sse_emit_660f (p, "pmaxsd", 0x38 3d, a, b)
#define orc_sse_emit_pmaxuw(p,a,b) orc_sse_emit_660f (p, "pmaxuw", 0x38 3e, a, b) #define orc_sse_emit_pmaxuw(p,a,b) orc_sse_emit_660f (p, "pmaxuw", 0x38 3e, a, b)
#define orc_sse_emit_pmaxud(p,a,b) orc_sse_emit_660f (p, "pmaxud", 0x38 3f, a, b) #define orc_sse_emit_pmaxud(p,a,b) orc_sse_emit_660f (p, "pmaxud", 0x38 3f, a, b)
 End of changes. 6 change blocks. 
6 lines changed or deleted 14 lines changed or added


 orctest.h   orctest.h 
skipping to change at line 33 skipping to change at line 33
void orc_test_random_bits (void *data, int n_bytes); void orc_test_random_bits (void *data, int n_bytes);
OrcTestResult orc_test_compare_output (OrcProgram *program); OrcTestResult orc_test_compare_output (OrcProgram *program);
OrcTestResult orc_test_compare_output_full (OrcProgram *program, int flags) ; OrcTestResult orc_test_compare_output_full (OrcProgram *program, int flags) ;
OrcTestResult orc_test_compare_output_backup (OrcProgram *program); OrcTestResult orc_test_compare_output_backup (OrcProgram *program);
OrcProgram *orc_test_get_program_for_opcode (OrcStaticOpcode *opcode); OrcProgram *orc_test_get_program_for_opcode (OrcStaticOpcode *opcode);
OrcProgram *orc_test_get_program_for_opcode_const (OrcStaticOpcode *opcode) ; OrcProgram *orc_test_get_program_for_opcode_const (OrcStaticOpcode *opcode) ;
OrcProgram *orc_test_get_program_for_opcode_param (OrcStaticOpcode *opcode) ; OrcProgram *orc_test_get_program_for_opcode_param (OrcStaticOpcode *opcode) ;
void orc_test_performance (OrcProgram *program, int flags); void orc_test_performance (OrcProgram *program, int flags);
double orc_test_performance_full (OrcProgram *program, int flags,
const char *target);
ORC_END_DECLS ORC_END_DECLS
#endif #endif
 End of changes. 1 change blocks. 
0 lines changed or deleted 2 lines changed or added


 orcutils.h   orcutils.h 
skipping to change at line 68 skipping to change at line 68
typedef unsigned short orc_uint16; typedef unsigned short orc_uint16;
typedef unsigned int orc_uint32; typedef unsigned int orc_uint32;
#if INT_MAX == LONG_MAX #if INT_MAX == LONG_MAX
typedef long long orc_int64; typedef long long orc_int64;
typedef unsigned long long orc_uint64; typedef unsigned long long orc_uint64;
#else #else
typedef long orc_int64; typedef long orc_int64;
typedef unsigned long orc_uint64; typedef unsigned long orc_uint64;
#endif #endif
#endif #endif
typedef union { orc_int32 i; float f; } orc_union32; typedef union { orc_int16 i; orc_int8 x2[2]; } orc_union16;
typedef union { orc_int64 i; double f; } orc_union64; typedef union { orc_int32 i; float f; orc_int16 x2[2]; orc_int8 x4[4]; } or
c_union32;
typedef union { orc_int64 i; double f; orc_int32 x2[2]; orc_int16 x4[4]; }
orc_union64;
#endif #endif
#ifndef TRUE #ifndef TRUE
#define TRUE 1 #define TRUE 1
#endif #endif
#ifndef FALSE #ifndef FALSE
#define FALSE 0 #define FALSE 0
#endif #endif
typedef unsigned int orc_bool; typedef unsigned int orc_bool;
 End of changes. 1 change blocks. 
2 lines changed or deleted 5 lines changed or added


 orcx86.h   orcx86.h 
skipping to change at line 57 skipping to change at line 57
void orc_x86_emit_add_reg_reg (OrcCompiler *compiler, int size, int reg1, i nt reg2); void orc_x86_emit_add_reg_reg (OrcCompiler *compiler, int size, int reg1, i nt reg2);
void orc_x86_emit_sub_reg_reg (OrcCompiler *compiler, int size, int reg1, i nt reg2); void orc_x86_emit_sub_reg_reg (OrcCompiler *compiler, int size, int reg1, i nt reg2);
void orc_x86_emit_imul_memoffset_reg (OrcCompiler *compiler, int size, void orc_x86_emit_imul_memoffset_reg (OrcCompiler *compiler, int size,
int offset, int reg, int destreg); int offset, int reg, int destreg);
void orc_x86_emit_sub_memoffset_reg (OrcCompiler *compiler, int size, void orc_x86_emit_sub_memoffset_reg (OrcCompiler *compiler, int size,
int offset, int reg, int destreg); int offset, int reg, int destreg);
void orc_x86_emit_cmp_reg_memoffset (OrcCompiler *compiler, int size, int r eg1, void orc_x86_emit_cmp_reg_memoffset (OrcCompiler *compiler, int size, int r eg1,
int offset, int reg); int offset, int reg);
void orc_x86_emit_cmp_imm_memoffset (OrcCompiler *compiler, int size, int v alue, void orc_x86_emit_cmp_imm_memoffset (OrcCompiler *compiler, int size, int v alue,
int offset, int reg); int offset, int reg);
void orc_x86_emit_cmp_imm_reg (OrcCompiler *compiler, int size, int value, int reg);
void orc_x86_emit_test_imm_memoffset (OrcCompiler *compiler, int size, int value, void orc_x86_emit_test_imm_memoffset (OrcCompiler *compiler, int size, int value,
int offset, int reg); int offset, int reg);
void orc_x86_emit_emms (OrcCompiler *compiler); void orc_x86_emit_emms (OrcCompiler *compiler);
void orc_x86_emit_rdtsc (OrcCompiler *compiler);
void orc_x86_emit_rep_movs (OrcCompiler *compiler, int size); void orc_x86_emit_rep_movs (OrcCompiler *compiler, int size);
void orc_x86_emit_ret (OrcCompiler *compiler); void orc_x86_emit_ret (OrcCompiler *compiler);
void orc_x86_emit_jle (OrcCompiler *compiler, int label); void orc_x86_emit_jle (OrcCompiler *compiler, int label);
void orc_x86_emit_jg (OrcCompiler *compiler, int label);
void orc_x86_emit_je (OrcCompiler *compiler, int label); void orc_x86_emit_je (OrcCompiler *compiler, int label);
void orc_x86_emit_jne (OrcCompiler *compiler, int label); void orc_x86_emit_jne (OrcCompiler *compiler, int label);
void orc_x86_emit_jmp (OrcCompiler *compiler, int label); void orc_x86_emit_jmp (OrcCompiler *compiler, int label);
void orc_x86_emit_label (OrcCompiler *compiler, int label); void orc_x86_emit_label (OrcCompiler *compiler, int label);
void orc_x86_emit_align (OrcCompiler *compiler); void orc_x86_emit_align (OrcCompiler *compiler);
void orc_x86_emit_prologue (OrcCompiler *compiler); void orc_x86_emit_prologue (OrcCompiler *compiler);
void orc_x86_emit_epilogue (OrcCompiler *compiler); void orc_x86_emit_epilogue (OrcCompiler *compiler);
void orc_x86_emit_rex (OrcCompiler *compiler, int size, int reg1, int reg2, int reg3); void orc_x86_emit_rex (OrcCompiler *compiler, int size, int reg1, int reg2, int reg3);
void orc_x86_emit_modrm_memoffset (OrcCompiler *compiler, int reg1, int off set, int reg2); void orc_x86_emit_modrm_memoffset (OrcCompiler *compiler, int reg1, int off set, int reg2);
 End of changes. 3 change blocks. 
0 lines changed or deleted 3 lines changed or added

This html diff was produced by rfcdiff 1.41. The latest version is available from http://tools.ietf.org/tools/rfcdiff/