summaryrefslogtreecommitdiff
path: root/vm_core.h
diff options
context:
space:
mode:
Diffstat (limited to 'vm_core.h')
-rw-r--r--vm_core.h19
1 files changed, 15 insertions, 4 deletions
diff --git a/vm_core.h b/vm_core.h
index 8d5140729b..6213863da4 100644
--- a/vm_core.h
+++ b/vm_core.h
@@ -134,14 +134,21 @@ struct iseq_inline_cache_entry {
VALUE ic_class;
union {
VALUE value;
- rb_method_entry_t *method;
long index;
} ic_value;
- union {
- VALUE defined_class;
- } ic_value2;
};
+/* rb_call_info_t contains calling information including inline cache */
+typedef struct rb_call_info_struct {
+ /* inline cache: keys */
+ VALUE ic_vmstat;
+ VALUE ic_class;
+
+ /* inline cache: values */
+ rb_method_entry_t *method;
+ VALUE defined_class;
+} rb_call_info_t;
+
#if 1
#define GetCoreDataFromValue(obj, type, ptr) do { \
(ptr) = (type*)DATA_PTR(obj); \
@@ -201,6 +208,9 @@ struct rb_iseq_struct {
struct iseq_inline_cache_entry *ic_entries;
int ic_size;
+ rb_call_info_t *callinfo_entries;
+ int callinfo_size;
+
/**
* argument information
*
@@ -661,6 +671,7 @@ enum vm_special_object_type {
/* inline cache */
typedef struct iseq_inline_cache_entry *IC;
+typedef rb_call_info_t *CALL_INFO;
void rb_vm_change_state(void);