# HG changeset patch # User Doug Simon # Date 1367698792 -7200 # Node ID 85595218dab0142dd4ede9fb349389ce52e43a46 # Parent 08d1414ac62d45851ef00be03fe8597b99556e52 added compare between address and 32-bit immediate diff -r 08d1414ac62d -r 85595218dab0 graal/com.oracle.graal.asm.amd64/src/com/oracle/graal/asm/amd64/AMD64Assembler.java --- a/graal/com.oracle.graal.asm.amd64/src/com/oracle/graal/asm/amd64/AMD64Assembler.java Sat May 04 22:18:23 2013 +0200 +++ b/graal/com.oracle.graal.asm.amd64/src/com/oracle/graal/asm/amd64/AMD64Assembler.java Sat May 04 22:19:52 2013 +0200 @@ -513,6 +513,13 @@ emitOperandHelper(dst, src); } + public final void cmpl(AMD64Address dst, int imm32) { + prefix(dst); + emitByte(0x81); + emitOperandHelper(7, dst); + emitInt(imm32); + } + // The 32-bit cmpxchg compares the value at adr with the contents of X86.rax, // and stores reg into adr if so; otherwise, the value at adr is loaded into X86.rax,. // The ZF is set if the compared values were equal, and cleared otherwise.