[前][次][番号順一覧][スレッド一覧]

ruby-changes:68585

From: Alan <ko1@a...>
Date: Thu, 21 Oct 2021 08:09:58 +0900 (JST)
Subject: [ruby-changes:68585] 040cfdb139 (master): Small build fixes

https://git.ruby-lang.org/ruby.git/commit/?id=040cfdb139

From 040cfdb1392beb0a1e45431c1825a71fc7334ae5 Mon Sep 17 00:00:00 2001
From: Alan Wu <XrXr@u...>
Date: Mon, 5 Oct 2020 08:09:58 -0400
Subject: Small build fixes

---
 iseq.c       | 2 ++
 ujit_asm.c   | 2 +-
 ujit_utils.c | 2 +-
 3 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/iseq.c b/iseq.c
index 19ac0e0d43..971f1c54c7 100644
--- a/iseq.c
+++ b/iseq.c
@@ -162,7 +162,9 @@ static int https://github.com/ruby/ruby/blob/trunk/iseq.c#L162
 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);
diff --git a/ujit_asm.c b/ujit_asm.c
index e8aee15fab..1ff1c537b7 100644
--- a/ujit_asm.c
+++ b/ujit_asm.c
@@ -90,7 +90,7 @@ uint8_t* alloc_exec_mem(size_t mem_size) https://github.com/ruby/ruby/blob/trunk/ujit_asm.c#L90
         &alloc_exec_mem,
         mem_size,
         PROT_READ | PROT_WRITE | PROT_EXEC,
-        MAP_PRIVATE | MAP_ANON,
+        MAP_PRIVATE | MAP_ANONYMOUS,
         -1,
         0
     );
diff --git a/ujit_utils.c b/ujit_utils.c
index 5e535685a1..58389fd6b9 100644
--- a/ujit_utils.c
+++ b/ujit_utils.c
@@ -48,7 +48,7 @@ void print_int(codeblock_t* cb, x86opnd_t opnd) https://github.com/ruby/ruby/blob/trunk/ujit_utils.c#L48
         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);
-- 
cgit v1.2.1


--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]