mirror of
https://github.com/ruby/ruby.git
synced 2025-08-15 13:39:04 +02:00
Add zjit_* instructions to profile the interpreter (https://github.com/Shopify/zjit/pull/16)
* Add zjit_* instructions to profile the interpreter * Rename FixnumPlus to FixnumAdd * Update a comment about Invalidate * Rename Guard to GuardType * Rename Invalidate to PatchPoint * Drop unneeded debug!() * Plan on profiling the types * Use the output of GuardType as type refined outputs
This commit is contained in:
parent
30db473389
commit
0a543daf15
Notes:
git
2025-04-18 13:48:27 +00:00
22 changed files with 498 additions and 122 deletions
19
zjit.h
Normal file
19
zjit.h
Normal file
|
@ -0,0 +1,19 @@
|
|||
#ifndef ZJIT_H
|
||||
#define ZJIT_H 1
|
||||
//
|
||||
// This file contains definitions ZJIT exposes to the CRuby codebase
|
||||
//
|
||||
|
||||
#if USE_ZJIT
|
||||
extern bool rb_zjit_enabled_p;
|
||||
extern uint64_t rb_zjit_call_threshold;
|
||||
void rb_zjit_compile_iseq(const rb_iseq_t *iseq, rb_execution_context_t *ec, bool jit_exception);
|
||||
void rb_zjit_profile_insn(enum ruby_vminsn_type insn, rb_execution_context_t *ec);
|
||||
void rb_zjit_profile_iseq(const rb_iseq_t *iseq);
|
||||
#else
|
||||
void rb_zjit_compile_iseq(const rb_iseq_t *iseq, rb_execution_context_t *ec, bool jit_exception) {}
|
||||
void rb_zjit_profile_insn(enum ruby_vminsn_type insn, rb_execution_context_t *ec) {}
|
||||
void rb_zjit_profile_iseq(const rb_iseq_t *iseq) {}
|
||||
#endif // #if USE_YJIT
|
||||
|
||||
#endif // #ifndef ZJIT_H
|
Loading…
Add table
Add a link
Reference in a new issue