コード例 #1
0
ファイル: emit-code-test_32.c プロジェクト: siam/jato
void test_emit_mov_imm_disp(void)
{
	assert_emit_insn_6(0xc7, 0x00, 0xbe, 0xba, 0xfe, 0xca, imm_membase_insn(INSN_MOV_IMM_MEMBASE, 0xcafebabe, &VAR_EAX, 0));
	assert_emit_insn_6(0xc7, 0x03, 0xef, 0xbe, 0xad, 0xde, imm_membase_insn(INSN_MOV_IMM_MEMBASE, 0xdeadbeef, &VAR_EBX, 0));
	assert_emit_insn_7(0xc7, 0x40, 0x08, 0xbe, 0xba, 0xfe, 0xca, imm_membase_insn(INSN_MOV_IMM_MEMBASE, 0xcafebabe, &VAR_EAX, 0x08));
	assert_emit_insn_7(0xc7, 0x43, 0x0c, 0xbe, 0xba, 0xfe, 0xca, imm_membase_insn(INSN_MOV_IMM_MEMBASE, 0xcafebabe, &VAR_EBX, 0x0c));
}
コード例 #2
0
ファイル: use-def-test_32.c プロジェクト: vegard/jato
void test_imm_membase_uses_target(void)
{
	assert_uses_r0(imm_membase_insn(INSN_MOV_IMM_MEMBASE, 0xdeadbeef, &r0, 0));
}