summaryrefslogtreecommitdiff
path: root/vm_core.h
diff options
context:
space:
mode:
authorAlan Wu <XrXr@users.noreply.github.com>2021-03-24 18:07:26 -0400
committerAlan Wu <XrXr@users.noreply.github.com>2021-10-20 18:19:33 -0400
commitb626dd7211b9d45f1dab6f82057445781f34f20f (patch)
tree76f107f1a2b79b4be590eea99aa98f97bd6eed14 /vm_core.h
parente81d1f4ae31086c19b936bb8d0bf4650b0c36f44 (diff)
YJIT: Fancier opt_getinlinecache
Make sure `opt_getinlinecache` is in a block all on its own, and invalidate it from the interpreter when `opt_setinlinecache`. It will recompile with a filled cache the second time around. This lets YJIT runs well when the IC for constant is cold.
Diffstat (limited to 'vm_core.h')
-rw-r--r--vm_core.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/vm_core.h b/vm_core.h
index cd8a01d1ca..6fd24e962f 100644
--- a/vm_core.h
+++ b/vm_core.h
@@ -236,6 +236,9 @@ STATIC_ASSERT(sizeof_iseq_inline_constant_cache_entry,
struct iseq_inline_constant_cache {
struct iseq_inline_constant_cache_entry *entry;
+ // For YJIT: the index to the opt_getinlinecache instruction in the same iseq.
+ // It's set during compile time and constant once set.
+ unsigned get_insn_idx;
};
struct iseq_inline_iv_cache_entry {