mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
Small build fixes
This commit is contained in:
parent
46126fe433
commit
ff93ae3711
3 changed files with 4 additions and 2 deletions
2
iseq.c
2
iseq.c
|
@ -160,7 +160,9 @@ static int
|
|||
iseq_extract_values(VALUE *code, size_t pos, iseq_value_itr_t * func, void *data, rb_vm_insns_translator_t * translator)
|
||||
{
|
||||
VALUE insn = translator((void *)code[pos]);
|
||||
#if OPT_DIRECT_THREADED_CODE || OPT_CALL_THREADED_CODE
|
||||
if (insn >= VM_INSTRUCTION_SIZE) rb_bug("invalid insn. translator=%p addr2insn=%p", (void *)translator, (void*)rb_vm_insn_addr2insn2);
|
||||
#endif
|
||||
int len = insn_len(insn);
|
||||
int op_no;
|
||||
const char *types = insn_op_types(insn);
|
||||
|
|
|
@ -90,7 +90,7 @@ uint8_t* alloc_exec_mem(size_t mem_size)
|
|||
&alloc_exec_mem,
|
||||
mem_size,
|
||||
PROT_READ | PROT_WRITE | PROT_EXEC,
|
||||
MAP_PRIVATE | MAP_ANON,
|
||||
MAP_PRIVATE | MAP_ANONYMOUS,
|
||||
-1,
|
||||
0
|
||||
);
|
||||
|
|
|
@ -48,7 +48,7 @@ void print_int(codeblock_t* cb, x86opnd_t opnd)
|
|||
mov(cb, RDI, opnd);
|
||||
|
||||
// Call the print function
|
||||
mov(cb, RAX, const_ptr_opnd(&print_int_cfun));
|
||||
mov(cb, RAX, const_ptr_opnd((void*)&print_int_cfun));
|
||||
call(cb, RAX);
|
||||
|
||||
pop_regs(cb);
|
||||
|
|
Loading…
Add table
Reference in a new issue