aboutsummaryrefslogtreecommitdiffstats
path: root/modules/alg_ia32/asm_macr.h
diff options
context:
space:
mode:
Diffstat (limited to 'modules/alg_ia32/asm_macr.h')
-rw-r--r--modules/alg_ia32/asm_macr.h10
1 files changed, 8 insertions, 2 deletions
diff --git a/modules/alg_ia32/asm_macr.h b/modules/alg_ia32/asm_macr.h
index dec14b738..faa55aa96 100644
--- a/modules/alg_ia32/asm_macr.h
+++ b/modules/alg_ia32/asm_macr.h
@@ -33,11 +33,15 @@ func_name:
* Loop Control *
*************************************************/
#define START_LOOP(LABEL) \
- ALIGN; \
+ ALIGN; \
LABEL##_LOOP:
+#define LOOP_UNTIL_EQ(REG, NUM, LABEL) \
+ cmpl IMM(NUM), REG; \
+ jne LABEL##_LOOP
+
#define LOOP_UNTIL(REG, NUM, LABEL) \
- cmpl NUM, REG; \
+ cmpl NUM, REG; \
jne LABEL##_LOOP
/*************************************************
@@ -89,6 +93,8 @@ func_name:
#define ADD2_IMM(TO, FROM, NUM) leal NUM(FROM), TO
#define ADD3_IMM(TO, FROM, NUM) leal NUM(TO,FROM,1), TO
+#define CLEAR_CARRY() clc
+
#define SHL_IMM(REG, SHIFT) shll IMM(SHIFT), REG
#define SHR_IMM(REG, SHIFT) shrl IMM(SHIFT), REG
#define SHL2_3(TO, FROM) leal 0(,FROM,8), TO