py/asm: Add condition codes for signed comparisons.
Signed-off-by: Damien George <damien@micropython.org>
This commit is contained in:
parent
aa26fe62d8
commit
b3b8706d27
@ -80,12 +80,19 @@ void asm_thumb_exit(asm_thumb_t *as);
|
|||||||
|
|
||||||
#define ASM_THUMB_OP_IT (0xbf00)
|
#define ASM_THUMB_OP_IT (0xbf00)
|
||||||
#define ASM_THUMB_OP_ITE_EQ (0xbf0c)
|
#define ASM_THUMB_OP_ITE_EQ (0xbf0c)
|
||||||
|
#define ASM_THUMB_OP_ITE_NE (0xbf14)
|
||||||
#define ASM_THUMB_OP_ITE_CS (0xbf2c)
|
#define ASM_THUMB_OP_ITE_CS (0xbf2c)
|
||||||
|
#define ASM_THUMB_OP_ITE_CC (0xbf34)
|
||||||
#define ASM_THUMB_OP_ITE_MI (0xbf4c)
|
#define ASM_THUMB_OP_ITE_MI (0xbf4c)
|
||||||
|
#define ASM_THUMB_OP_ITE_PL (0xbf54)
|
||||||
#define ASM_THUMB_OP_ITE_VS (0xbf6c)
|
#define ASM_THUMB_OP_ITE_VS (0xbf6c)
|
||||||
|
#define ASM_THUMB_OP_ITE_VC (0xbf74)
|
||||||
#define ASM_THUMB_OP_ITE_HI (0xbf8c)
|
#define ASM_THUMB_OP_ITE_HI (0xbf8c)
|
||||||
|
#define ASM_THUMB_OP_ITE_LS (0xbf94)
|
||||||
#define ASM_THUMB_OP_ITE_GE (0xbfac)
|
#define ASM_THUMB_OP_ITE_GE (0xbfac)
|
||||||
|
#define ASM_THUMB_OP_ITE_LT (0xbfb4)
|
||||||
#define ASM_THUMB_OP_ITE_GT (0xbfcc)
|
#define ASM_THUMB_OP_ITE_GT (0xbfcc)
|
||||||
|
#define ASM_THUMB_OP_ITE_LE (0xbfd4)
|
||||||
|
|
||||||
#define ASM_THUMB_OP_NOP (0xbf00)
|
#define ASM_THUMB_OP_NOP (0xbf00)
|
||||||
#define ASM_THUMB_OP_WFI (0xbf30)
|
#define ASM_THUMB_OP_WFI (0xbf30)
|
||||||
|
@ -61,10 +61,13 @@
|
|||||||
|
|
||||||
// condition codes, used for jcc and setcc (despite their j-name!)
|
// condition codes, used for jcc and setcc (despite their j-name!)
|
||||||
#define ASM_X64_CC_JB (0x2) // below, unsigned
|
#define ASM_X64_CC_JB (0x2) // below, unsigned
|
||||||
|
#define ASM_X64_CC_JAE (0x3) // above or equal, unsigned
|
||||||
#define ASM_X64_CC_JZ (0x4)
|
#define ASM_X64_CC_JZ (0x4)
|
||||||
#define ASM_X64_CC_JE (0x4)
|
#define ASM_X64_CC_JE (0x4)
|
||||||
#define ASM_X64_CC_JNZ (0x5)
|
#define ASM_X64_CC_JNZ (0x5)
|
||||||
#define ASM_X64_CC_JNE (0x5)
|
#define ASM_X64_CC_JNE (0x5)
|
||||||
|
#define ASM_X64_CC_JBE (0x6) // below or equal, unsigned
|
||||||
|
#define ASM_X64_CC_JA (0x7) // above, unsigned
|
||||||
#define ASM_X64_CC_JL (0xc) // less, signed
|
#define ASM_X64_CC_JL (0xc) // less, signed
|
||||||
#define ASM_X64_CC_JGE (0xd) // greater or equal, signed
|
#define ASM_X64_CC_JGE (0xd) // greater or equal, signed
|
||||||
#define ASM_X64_CC_JLE (0xe) // less or equal, signed
|
#define ASM_X64_CC_JLE (0xe) // less or equal, signed
|
||||||
|
@ -63,10 +63,13 @@
|
|||||||
|
|
||||||
// condition codes, used for jcc and setcc (despite their j-name!)
|
// condition codes, used for jcc and setcc (despite their j-name!)
|
||||||
#define ASM_X86_CC_JB (0x2) // below, unsigned
|
#define ASM_X86_CC_JB (0x2) // below, unsigned
|
||||||
|
#define ASM_X86_CC_JAE (0x3) // above or equal, unsigned
|
||||||
#define ASM_X86_CC_JZ (0x4)
|
#define ASM_X86_CC_JZ (0x4)
|
||||||
#define ASM_X86_CC_JE (0x4)
|
#define ASM_X86_CC_JE (0x4)
|
||||||
#define ASM_X86_CC_JNZ (0x5)
|
#define ASM_X86_CC_JNZ (0x5)
|
||||||
#define ASM_X86_CC_JNE (0x5)
|
#define ASM_X86_CC_JNE (0x5)
|
||||||
|
#define ASM_X86_CC_JBE (0x6) // below or equal, unsigned
|
||||||
|
#define ASM_X86_CC_JA (0x7) // above, unsigned
|
||||||
#define ASM_X86_CC_JL (0xc) // less, signed
|
#define ASM_X86_CC_JL (0xc) // less, signed
|
||||||
#define ASM_X86_CC_JGE (0xd) // greater or equal, signed
|
#define ASM_X86_CC_JGE (0xd) // greater or equal, signed
|
||||||
#define ASM_X86_CC_JLE (0xe) // less or equal, signed
|
#define ASM_X86_CC_JLE (0xe) // less or equal, signed
|
||||||
|
Loading…
Reference in New Issue
Block a user