[svn:parrot] r48075 - in branches/gsoc_instrument: runtime/parrot/library/Instrument src/dynpmc t/dynpmc tools/build

khairul at svn.parrot.org khairul at svn.parrot.org
Mon Jul 12 15:32:46 UTC 2010


Author: khairul
Date: Mon Jul 12 15:32:45 2010
New Revision: 48075
URL: https://trac.parrot.org/parrot/changeset/48075

Log:
Refactored common items out of InstrumentGC and InstrumentVtable.

Added:
   branches/gsoc_instrument/src/dynpmc/instrumentstubbase.pmc
Modified:
   branches/gsoc_instrument/runtime/parrot/library/Instrument/EventLibrary.nqp
   branches/gsoc_instrument/src/dynpmc/Defines.in
   branches/gsoc_instrument/src/dynpmc/Rules.in
   branches/gsoc_instrument/src/dynpmc/instrumentgc.pmc
   branches/gsoc_instrument/src/dynpmc/instrumentvtable.pmc
   branches/gsoc_instrument/t/dynpmc/instrumentgc.t
   branches/gsoc_instrument/tools/build/gen_gc_stubs.pl
   branches/gsoc_instrument/tools/build/gen_vtable_stubs.pl

Modified: branches/gsoc_instrument/runtime/parrot/library/Instrument/EventLibrary.nqp
==============================================================================
--- branches/gsoc_instrument/runtime/parrot/library/Instrument/EventLibrary.nqp	Sun Jul 11 20:42:32 2010	(r48074)
+++ branches/gsoc_instrument/runtime/parrot/library/Instrument/EventLibrary.nqp	Mon Jul 12 15:32:45 2010	(r48075)
@@ -177,7 +177,7 @@
             my @hooks := $gc.get_hook_list($_);
 
             for @hooks {
-                $gc.insert_gc_hook($_);
+                $gc.insert_hook($_);
 
                 my $tokens := pir::split__PSS('_', $_);
                 my $group  := $tokens[0];
@@ -192,7 +192,7 @@
             }
         }
     };
-    
+
     method disable() {
     }
 };
@@ -202,6 +202,8 @@
     has $!class_name;
     has @!vtable_probes;
     has @!method_probes;
+    our @todo;
+    our $loadlib_event;
 
     method _self_init() {
         @!vtable_probes := ();
@@ -234,10 +236,12 @@
         my $event_prefix := 'Class::' ~ $!class_name ~ '::';
 
         # Register the vtable probes.
+        my $vtable_prefix := $event_prefix ~ 'vtable::';
         for @!vtable_probes {
-            $class.insert_vtable_hook($_);
-            
-            my $event := $event_prefix ~ $_;
+            $class.insert_hook($_);
+            my $group := ($class.get_hook_group($_)).shift();
+
+            my $event :=  $vtable_prefix ~ $group ~ '::' ~ $_;
             $dispatcher.register($event, $!callback);
         }
     };

Modified: branches/gsoc_instrument/src/dynpmc/Defines.in
==============================================================================
--- branches/gsoc_instrument/src/dynpmc/Defines.in	Sun Jul 11 20:42:32 2010	(r48074)
+++ branches/gsoc_instrument/src/dynpmc/Defines.in	Mon Jul 12 15:32:45 2010	(r48075)
@@ -23,12 +23,14 @@
 
 DYNPMC_INSTRUMENT = \
     src/dynpmc/instrument.pmc \
+    src/dynpmc/instrumentstubbase.pmc \
     src/dynpmc/instrumentgc.pmc \
     src/dynpmc/instrumentop.pmc \
     src/dynpmc/instrumentvtable.pmc
 
 DYNPMC_INSTRUMENT_OBJS = \
     src/dynpmc/instrument$(O) \
+    src/dynpmc/instrumentstubbase$(O) \
     src/dynpmc/instrumentgc$(O) \
     src/dynpmc/instrumentop$(O) \
     src/dynpmc/instrumentvtable$(O)

Modified: branches/gsoc_instrument/src/dynpmc/Rules.in
==============================================================================
--- branches/gsoc_instrument/src/dynpmc/Rules.in	Sun Jul 11 20:42:32 2010	(r48074)
+++ branches/gsoc_instrument/src/dynpmc/Rules.in	Mon Jul 12 15:32:45 2010	(r48075)
@@ -176,7 +176,7 @@
 
 src/dynpmc/subproxy.dump: src/dynpmc/subproxy.pmc vtable.dump $(CLASS_O_FILES)
 	$(PMC2CD) src/dynpmc/subproxy.pmc
-	
+
 
 $(DYNEXT_DIR)/instrument_group$(LOAD_EXT): $(DYNPMC_INSTRUMENT_OBJS) src/dynpmc/instrument_group$(O)
 	$(LD)  @ld_out@$(DYNEXT_DIR)/instrument_group$(LOAD_EXT) src/dynpmc/instrument_group$(O) $(DYNPMC_INSTRUMENT_OBJS) $(LINKARGS)
@@ -184,6 +184,7 @@
 #IF(cygwin or hpux):   $(CHMOD) 0775 $@
 
 src/dynpmc/instrument_group$(O): src/dynpmc/instrument.c src/dynpmc/instrumentop.c \
+    src/dynpmc/instrumentstubbase.c \
     src/dynpmc/instrumentvtable.c src/dynpmc/instrumentgc.c $(DYNPMC_H_FILES)
 
 src/dynpmc/instrument_group.c: $(DYNPMC_INSTRUMENT_OBJS)
@@ -202,6 +203,17 @@
 src/dynpmc/instrument.dump: src/dynpmc/instrument.pmc vtable.dump $(CLASS_O_FILES)
 	$(PMC2CD) src/dynpmc/instrument.pmc
 
+src/dynpmc/pmc_instrumentstubbase.h : src/dynpmc/instrumentstubbase.c
+
+src/dynpmc/instrumentstubbase$(O): src/dynpmc/instrumentstubbase.c $(DYNPMC_H_FILES) \
+    src/dynpmc/pmc_instrumentstubbase.h
+
+src/dynpmc/instrumentstubbase.c: src/dynpmc/instrumentstubbase.dump
+	$(PMC2CC) src/dynpmc/instrumentstubbase.pmc
+
+src/dynpmc/instrumentstubbase.dump: src/dynpmc/instrumentstubbase.pmc vtable.dump $(CLASS_O_FILES)
+	$(PMC2CD) src/dynpmc/instrumentstubbase.pmc
+
 src/dynpmc/pmc_instrumentgc.h : src/dynpmc/instrumentgc.c
 
 src/dynpmc/instrumentgc$(O): src/dynpmc/instrumentgc.c $(DYNPMC_H_FILES) \

Modified: branches/gsoc_instrument/src/dynpmc/instrumentgc.pmc
==============================================================================
--- branches/gsoc_instrument/src/dynpmc/instrumentgc.pmc	Sun Jul 11 20:42:32 2010	(r48074)
+++ branches/gsoc_instrument/src/dynpmc/instrumentgc.pmc	Mon Jul 12 15:32:45 2010	(r48075)
@@ -24,119 +24,72 @@
 #include "pmc_instrument.h"
 #include "../gc/gc_private.h"
 
+/* BELOW LIES GENERATED CODE GENERATED BY tools/build/gen_gc_stubs.pl */
 typedef struct InstrumentGC_Subsystem {
     /* Common entries taken from GC_Subsystem. */
-    gc_sys_type_enum sys_type;
-    void (*finalize_gc_system) (PARROT_INTERP);
-    void (*destroy_child_interp)(Interp *dest_interp, Interp *child_interp);
-    void (*do_gc_mark)(PARROT_INTERP, UINTVAL flags);
-    void (*compact_string_pool)(PARROT_INTERP);
-    void (*mark_special)(PARROT_INTERP, PMC *);
-    void (*pmc_needs_early_collection)(PARROT_INTERP, PMC *);
-    void (*init_pool)(PARROT_INTERP, struct Fixed_Size_Pool *);
-    PMC* (*allocate_pmc_header)(PARROT_INTERP, UINTVAL flags);
-    void (*free_pmc_header)(PARROT_INTERP, PMC *);
-    STRING* (*allocate_string_header)(PARROT_INTERP, UINTVAL flags);
-    void (*free_string_header)(PARROT_INTERP, STRING*);
-    Buffer* (*allocate_bufferlike_header)(PARROT_INTERP, size_t size);
-    void (*free_bufferlike_header)(PARROT_INTERP, Buffer*, size_t size);
-    void* (*allocate_pmc_attributes)(PARROT_INTERP, PMC *);
-    void (*free_pmc_attributes)(PARROT_INTERP, PMC *);
-    void (*allocate_string_storage)(PARROT_INTERP, STRING *str, size_t size);
-    void (*reallocate_string_storage)(PARROT_INTERP, STRING *str, size_t size);
-    void (*allocate_buffer_storage)(PARROT_INTERP, ARGMOD(Buffer *buffer), size_t nsize);
-    void (*reallocate_buffer_storage)(PARROT_INTERP, ARGMOD(Buffer *buffer), size_t newsize);
-    void* (*allocate_fixed_size_storage)(PARROT_INTERP, size_t size);
-    void (*free_fixed_size_storage)(PARROT_INTERP, size_t size, void *);
-    void* (*allocate_memory_chunk)(PARROT_INTERP, size_t size);
-    void* (*reallocate_memory_chunk)(PARROT_INTERP, void *data, size_t newsize);
-    void* (*allocate_memory_chunk_with_interior_pointers)(PARROT_INTERP, size_t size);
-    void* (*reallocate_memory_chunk_with_interior_pointers)(PARROT_INTERP, void *data,
-            size_t oldsize, size_t newsize);
-    void (*free_memory_chunk)(PARROT_INTERP, void *data);
-    void (*block_mark)(PARROT_INTERP);
-    void (*unblock_mark)(PARROT_INTERP);
-    unsigned int (*is_blocked_mark)(PARROT_INTERP);
-    void (*block_sweep)(PARROT_INTERP);
-    void (*unblock_sweep)(PARROT_INTERP);
-    unsigned int (*is_blocked_sweep)(PARROT_INTERP);
-    size_t (*get_gc_info)(PARROT_INTERP, Interpinfo_enum);
+    /* BEGIN gc struct entries */
+gc_sys_type_enum sys_type;
+void (*finalize_gc_system) (PARROT_INTERP);
+void (*destroy_child_interp)(Interp *dest_interp, Interp *child_interp);
+void (*do_gc_mark)(PARROT_INTERP, UINTVAL flags);
+void (*compact_string_pool)(PARROT_INTERP);
+void (*mark_special)(PARROT_INTERP, PMC *);
+void (*pmc_needs_early_collection)(PARROT_INTERP, PMC *);
+void (*init_pool)(PARROT_INTERP, struct Fixed_Size_Pool *);
+PMC* (*allocate_pmc_header)(PARROT_INTERP, UINTVAL flags);
+void (*free_pmc_header)(PARROT_INTERP, PMC *);
+STRING* (*allocate_string_header)(PARROT_INTERP, UINTVAL flags);
+void (*free_string_header)(PARROT_INTERP, STRING*);
+Buffer* (*allocate_bufferlike_header)(PARROT_INTERP, size_t size);
+void (*free_bufferlike_header)(PARROT_INTERP, Buffer*, size_t size);
+void* (*allocate_pmc_attributes)(PARROT_INTERP, PMC *);
+void (*free_pmc_attributes)(PARROT_INTERP, PMC *);
+void (*allocate_string_storage)(PARROT_INTERP, STRING *str, size_t size);
+void (*reallocate_string_storage)(PARROT_INTERP, STRING *str, size_t size);
+void (*allocate_buffer_storage)(PARROT_INTERP, ARGMOD(Buffer *buffer), size_t nsize);
+void (*reallocate_buffer_storage)(PARROT_INTERP, ARGMOD(Buffer *buffer), size_t newsize);
+void* (*allocate_fixed_size_storage)(PARROT_INTERP, size_t size);
+void (*free_fixed_size_storage)(PARROT_INTERP, size_t size, void *);
+void* (*allocate_memory_chunk)(PARROT_INTERP, size_t size);
+void* (*reallocate_memory_chunk)(PARROT_INTERP, void *data, size_t newsize);
+void* (*allocate_memory_chunk_with_interior_pointers)(PARROT_INTERP, size_t size);
+void* (*reallocate_memory_chunk_with_interior_pointers)(PARROT_INTERP, void *data,
+                                                        size_t oldsize, size_t newsize);
+void (*free_memory_chunk)(PARROT_INTERP, void *data);
+void (*block_mark)(PARROT_INTERP);
+void (*unblock_mark)(PARROT_INTERP);
+unsigned int (*is_blocked_mark)(PARROT_INTERP);
+void (*block_sweep)(PARROT_INTERP);
+void (*unblock_sweep)(PARROT_INTERP);
+unsigned int (*is_blocked_sweep)(PARROT_INTERP);
+size_t (*get_gc_info)(PARROT_INTERP, Interpinfo_enum);
+    /* END gc struct entries */
     /* End of common entries. */
 
     /* Additional Entries. */
     PMC           *instrument_gc;
     Parrot_Interp  supervisor;
+    GC_Subsystem  *original;
 } InstrumentGC_Subsystem;
-
-/* Prototypes for stub functions. */
-/* BEGIN gc prototypes */
-void  stub_finalize_gc_system(PARROT_INTERP);
-void  stub_destroy_child_interp(Interp* dest_interp, Interp* child_interp);
-void  stub_do_gc_mark(PARROT_INTERP, UINTVAL flags);
-void  stub_compact_string_pool(PARROT_INTERP);
-void  stub_mark_special(PARROT_INTERP, PMC*  stub_var1);
-void  stub_pmc_needs_early_collection(PARROT_INTERP, PMC*  stub_var1);
-void  stub_init_pool(PARROT_INTERP, struct Fixed_Size_Pool*  stub_var1);
-PMC*  stub_allocate_pmc_header(PARROT_INTERP, UINTVAL flags);
-void  stub_free_pmc_header(PARROT_INTERP, PMC*  stub_var1);
-STRING*  stub_allocate_string_header(PARROT_INTERP, UINTVAL flags);
-void  stub_free_string_header(PARROT_INTERP, STRING* stub_var1);
-Buffer*  stub_allocate_bufferlike_header(PARROT_INTERP, size_t size);
-void  stub_free_bufferlike_header(PARROT_INTERP, Buffer* stub_var1, size_t size);
-void*  stub_allocate_pmc_attributes(PARROT_INTERP, PMC*  stub_var1);
-void  stub_free_pmc_attributes(PARROT_INTERP, PMC*  stub_var1);
-void  stub_allocate_string_storage(PARROT_INTERP, STRING* str, size_t size);
-void  stub_reallocate_string_storage(PARROT_INTERP, STRING* str, size_t size);
-void  stub_allocate_buffer_storage(PARROT_INTERP, Buffer* buffer, size_t nsize);
-void  stub_reallocate_buffer_storage(PARROT_INTERP, Buffer* buffer, size_t newsize);
-void*  stub_allocate_fixed_size_storage(PARROT_INTERP, size_t size);
-void  stub_free_fixed_size_storage(PARROT_INTERP, size_t size, void*  stub_var1);
-void*  stub_allocate_memory_chunk(PARROT_INTERP, size_t size);
-void*  stub_reallocate_memory_chunk(PARROT_INTERP, void* data, size_t newsize);
-void*  stub_allocate_memory_chunk_with_interior_pointers(PARROT_INTERP, size_t size);
-void*  stub_reallocate_memory_chunk_with_interior_pointers(PARROT_INTERP, void* data,
-                                                           size_t oldsize, size_t newsize);
-void  stub_free_memory_chunk(PARROT_INTERP, void* data);
-void  stub_block_mark(PARROT_INTERP);
-void  stub_unblock_mark(PARROT_INTERP);
-void  stub_block_sweep(PARROT_INTERP);
-void  stub_unblock_sweep(PARROT_INTERP);
-
-/* END gc prototypes */
+/* END OF GENERATED CODE */
 
 /* Prototypes for helper functions. */
 void raise_gc_event(PARROT_INTERP, Parrot_Interp supervised, STRING *group, PMC *data);
-PMC *get_gc_funcs(PARROT_INTERP, STRING *name);
-void build_gc_func_hash(PARROT_INTERP, Hash *instr_hash, Hash *orig_hash, Hash *entry_hash,
-                        InstrumentGC_Subsystem *gc_instr, GC_Subsystem *gc_orig);
-
-pmclass InstrumentGC auto_attrs dynpmc group instrument_group  {
-    ATTR PMC                           *instrument;
-    ATTR struct GC_Subsystem           *gc_original;
-    ATTR struct InstrumentGC_Subsystem *gc_instrumented;
-    ATTR Hash                          *stub_hash;
-    ATTR Hash                          *original_hash;
-    ATTR Hash                          *entry_hash;
-    ATTR PMC                           *hook_count;
-
-/*
-
-=item C<void init()>
+void setup_gc_common_hashes(PARROT_INTERP);
+void destroy_gc_common_hashes(PARROT_INTERP);
+void setup_gc_individual_hashes(PARROT_INTERP, Hash *orig_hash, Hash *instr_hash,
+                                GC_Subsystem *gc_orig, InstrumentGC_Subsystem *gc_instr);
+
+/* Globals used internally. */
+static INTVAL  gc_first_run   = 1;
+static Hash   *gc_registry    = NULL;
+static Hash   *gc_name_stubs  = NULL;
+static Hash   *gc_group_items = NULL;
+static Hash   *gc_item_groups = NULL;
 
-Throws an exception. InstrumentGC must init with an Instrument pmc.
-
-=cut
-
-*/
-
-    VTABLE void init() {
-        /* Not supposed to be init on its own. */
-        Parrot_ex_throw_from_c_args(INTERP, NULL, 1,
-                                    "InstrumentGC should be instantiated with initpmc instead.");
-    }
+pmclass InstrumentGC auto_attrs dynpmc group instrument_group extends InstrumentStubBase {
 
 /*
-
 =item C<void init_pmc(PMC *instrument)>
 
 Initialises and prepares the supervised interpreter for GC instrumenting.
@@ -148,30 +101,38 @@
     VTABLE void init_pmc(PMC *instrument) {
         Parrot_InstrumentGC_attributes * const attr = PARROT_INSTRUMENTGC(SELF);
         Parrot_Interp supervised;
+        InstrumentGC_Subsystem *sub;
+        SUPER(instrument);
 
         GETATTR_Instrument_supervised(INTERP, instrument, supervised);
 
-        attr->instrument      = instrument;
-        attr->gc_original     = supervised->gc_sys;
-        attr->gc_instrumented = mem_gc_allocate_zeroed_typed(INTERP, InstrumentGC_Subsystem);
-        attr->hook_count      = Parrot_pmc_new(INTERP, enum_class_Hash);
+        /* Initialise the structs */
+        sub = mem_gc_allocate_zeroed_typed(INTERP, InstrumentGC_Subsystem);
+        attr->original_struct     = supervised->gc_sys;
+        attr->instrumented_struct = sub;
 
         /* Initiliase the instrumented gc_sys with the original values. */
-        attr->gc_instrumented->instrument_gc = SELF;
-        attr->gc_instrumented->supervisor    = INTERP;
+        sub->instrument_gc = SELF;
+        sub->supervisor    = INTERP;
+        sub->original      = (GC_Subsystem *) attr->original_struct;
 
         /* Set the gc_sys of the supervised to the instrumented gc_sys. */
-        mem_copy_n_typed(attr->gc_instrumented, attr->gc_original, 1, GC_Subsystem);
-        supervised->gc_sys = (GC_Subsystem *) attr->gc_instrumented;
+        mem_copy_n_typed(attr->instrumented_struct, attr->original_struct, 1, GC_Subsystem);
+        supervised->gc_sys = (GC_Subsystem *) attr->instrumented_struct;
 
         /* Initialise the hashes. */
-        attr->stub_hash     = parrot_new_hash(INTERP);
-        attr->original_hash = parrot_new_hash(INTERP);
-        attr->entry_hash    = parrot_new_hash(INTERP);
-        build_gc_func_hash(INTERP, attr->stub_hash, attr->original_hash, attr->entry_hash,
-                           attr->gc_instrumented, attr->gc_original);
+        setup_gc_common_hashes(INTERP);
+        setup_gc_individual_hashes(INTERP, attr->name_original, attr->name_offset,
+                                   (GC_Subsystem *) attr->original_struct,
+                                   (InstrumentGC_Subsystem *) attr->instrumented_struct);
+
+        /* Update the attributes to point to the static hashes. */
+        attr->name_stubs  = gc_name_stubs;
+        attr->group_items = gc_group_items;
+        attr->item_groups = gc_item_groups;
 
-        PObj_custom_destroy_SET(SELF);
+        /* Register self in the registry. */
+        parrot_hash_put(INTERP, gc_registry, SELF, SELF);
     }
 
 /*
@@ -186,267 +147,668 @@
 
     VTABLE void destroy() {
         Parrot_InstrumentGC_attributes * const attr = PARROT_INSTRUMENTGC(SELF);
-
-        /* Free the hashes. */
-        parrot_hash_destroy(INTERP, attr->stub_hash);
-        parrot_hash_destroy(INTERP, attr->original_hash);
-        parrot_hash_destroy(INTERP, attr->entry_hash);
-
-        /* Free gc_original. gc_instrumented will be freed when
-           supervised is killed. */
-        mem_gc_free(INTERP, attr->gc_original);
-    }
-
-/*
-
-=item C<void insert_gc_hook(STRING *name)>
-
-Inserts the stub function for the given GC entry given by name.
-If name denotes a group (allocate, reallocate, free, administration),
-inserts stubs for all functions in that group.
-
-=cut
-
-*/
-
-    METHOD insert_gc_hook(STRING *name) {
-        Parrot_InstrumentGC_attributes * const attr = PARROT_INSTRUMENTGC(SELF);
-        PMC *list;
-        PMC *iter;
-        (PMC *list) = PCCINVOKE(INTERP, SELF, "get_hook_list", STRING *name);
-
-        iter = VTABLE_get_iter(INTERP, list);
-        while (VTABLE_get_bool(INTERP, iter)) {
-            INTVAL count;
-            PMC *item_pmc = VTABLE_shift_pmc(INTERP, iter);
-            STRING *item  = VTABLE_get_string(INTERP, item_pmc);
-            size_t **entry, *func;
-
-            /* Check if the entry has already been instrumented. */
-            count = VTABLE_get_integer_keyed_str(INTERP, attr->hook_count, item);
-            if (count == 0) {
-                /* Replace the entry with the stub. */
-                entry = (size_t **) parrot_hash_get(INTERP, attr->entry_hash, item);
-                func  = (size_t *)  parrot_hash_get(INTERP, attr->stub_hash, item);
-                if (entry == NULL || func == NULL) {
-                    Parrot_ex_throw_from_c_args(INTERP, NULL, 1,
-                                                "Unknown GC function: %Ss", item);
-                }
-                *entry = func;
-            }
-
-            /* Update the count. */
-            count++;
-            VTABLE_set_integer_keyed_str(INTERP, attr->hook_count, item, count);
-        }
+        SUPER();
+        parrot_hash_delete(INTERP, gc_registry, SELF);
+        destroy_gc_common_hashes(INTERP);
     }
+}
 
 /*
-
-=item C<void remove_gc_hook(STRING *name)>
-
-Removes the stub function for the given GC entry given by name.
-If name denotes a group (allocate, reallocate, free, administration),
-removes stubs for all functions in that group.
-
-=cut
-
-*/
-
-    METHOD remove_gc_hook(STRING *name) {
-        Parrot_InstrumentGC_attributes * const attr = PARROT_INSTRUMENTGC(SELF);
-        PMC *list;
-        PMC *iter;
-        GC_Subsystem           *orig  = attr->gc_original;
-        InstrumentGC_Subsystem *instr = attr->gc_instrumented;
-        (PMC *list) = PCCINVOKE(INTERP, SELF, "get_hook_list", STRING *name);
-
-        iter = VTABLE_get_iter(INTERP, list);
-        while (VTABLE_get_bool(INTERP, iter)) {
-            INTVAL count;
-            PMC *item_pmc = VTABLE_shift_pmc(INTERP, iter);
-            STRING *item  = VTABLE_get_string(INTERP, item_pmc);
-            size_t **entry, *func;
-
-            /* Only remove the stub if request count == 1 => Last request. */
-            count = VTABLE_get_integer_keyed_str(INTERP, attr->hook_count, item);
-            if (count <= 0) {
-                /* Tried to remove 1 time too many. */
-                Parrot_ex_throw_from_c_args(INTERP, NULL, 1,
-                                            "GC function %Ss is not instrumented.", item);
-            }
-            else if (count == 1) {
-                /* Simply replace the stub with the original entry. */
-                entry = (size_t **) parrot_hash_get(INTERP, attr->entry_hash, item);
-                func  = (size_t *)  parrot_hash_get(INTERP, attr->original_hash, item);
-                if (entry == NULL || func == NULL) {
-                    Parrot_ex_throw_from_c_args(INTERP, NULL, 1,
-                                                "Unknown GC function: %Ss", item);
-                }
-                *entry = func;
-            }
-
-            /* Update the count. */
-            count--;
-            VTABLE_set_integer_keyed_str(INTERP, attr->hook_count, item, count);
-        }
-    }
+ * Helper functions
+ */
 
 /*
+ * raise_gc_event: Creates a Task of subtype Instrument::Event::GC::<*>
+ *                 and sets its data to the given data, adding file,
+ *                 sub, namespace and line information to the data hash.
+ */
 
-=item C<PMC* get_instrumented_list()>
-
-Returns a ResizableStringArray PMC filled with
-the names of the gc entries that has been instrumented.
-
-=cut
-
-*/
+void raise_gc_event(PARROT_INTERP, Parrot_Interp supervised, STRING *group, PMC *data) {
+    PMC *task, *task_hash, *event;
+    STRING *event_str;
+    Parrot_Context_info info;
+    event_str = VTABLE_get_string_keyed_str(interp, data, CONST_STRING(interp, "type"));
 
-    METHOD get_instrumented_list() {
-        PMC *ret = Parrot_pmc_new(INTERP, enum_class_ResizableStringArray);
-        PMC *iter, *hook_hash;
-
-        GETATTR_InstrumentGC_hook_count(INTERP, SELF, hook_hash);
-        iter = VTABLE_get_iter(INTERP, hook_hash);
-
-        while (VTABLE_get_bool(INTERP, iter)) {
-            PMC *key     = VTABLE_shift_pmc(INTERP, iter);
-            INTVAL count = VTABLE_get_integer_keyed(INTERP, hook_hash, key);
-            if (count > 0) {
-                VTABLE_push_pmc(INTERP, ret, key);
-            }
-        }
+    event = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, event, CONST_STRING(interp, "GC"));
+    VTABLE_push_string(interp, event, group);
+    VTABLE_push_string(interp, event, event_str);
 
-        RETURN(PMC *ret);
-    }
+    Parrot_Context_get_info(interp, CURRENT_CONTEXT(supervised), &info);
+    VTABLE_set_string_keyed_str(interp,  data, CONST_STRING(interp, "file"),      info.file);
+    VTABLE_set_string_keyed_str(interp,  data, CONST_STRING(interp, "sub"),       info.subname);
+    VTABLE_set_string_keyed_str(interp,  data, CONST_STRING(interp, "namespace"), info.nsname);
+    VTABLE_set_integer_keyed_str(interp, data, CONST_STRING(interp, "line"),      info.line);
+    VTABLE_set_pmc_keyed_str(interp, data, CONST_STRING(interp, "event"), event);
 
-/*
+    task_hash = Parrot_pmc_new(interp, enum_class_Hash);
+    VTABLE_set_string_keyed_str(interp, task_hash,
+                                CONST_STRING(interp, "type"),
+                                CONST_STRING(interp, "event"));
+    VTABLE_set_string_keyed_str(interp, task_hash,
+                                CONST_STRING(interp, "subtype"),
+                                CONST_STRING(interp, "Instrument"));
+    VTABLE_set_pmc_keyed_str(interp, task_hash, CONST_STRING(interp, "data"), data);
 
-=item C<PMC* get_hook_list(STRING *name)>
+    task = Parrot_pmc_new_init(interp, enum_class_Task, task_hash);
+    Parrot_cx_schedule_task(interp, task);
+}
 
-Returns a ResizableStringArray PMC filled with
-the names of the gc entries to instrument.
 
-=cut
+/* BELOW LIES GENERATED CODE GENERATED BY tools/build/gen_gc_stubs.pl */
+/* BEGIN gc prototypes */
+void  stub_finalize_gc_system(PARROT_INTERP);
+void  stub_destroy_child_interp(Interp* dest_interp, Interp* child_interp);
+void  stub_do_gc_mark(PARROT_INTERP, UINTVAL flags);
+void  stub_compact_string_pool(PARROT_INTERP);
+void  stub_mark_special(PARROT_INTERP, PMC*  stub_var1);
+void  stub_pmc_needs_early_collection(PARROT_INTERP, PMC*  stub_var1);
+void  stub_init_pool(PARROT_INTERP, struct Fixed_Size_Pool*  stub_var1);
+PMC*  stub_allocate_pmc_header(PARROT_INTERP, UINTVAL flags);
+void  stub_free_pmc_header(PARROT_INTERP, PMC*  stub_var1);
+STRING*  stub_allocate_string_header(PARROT_INTERP, UINTVAL flags);
+void  stub_free_string_header(PARROT_INTERP, STRING* stub_var1);
+Buffer*  stub_allocate_bufferlike_header(PARROT_INTERP, size_t size);
+void  stub_free_bufferlike_header(PARROT_INTERP, Buffer* stub_var1, size_t size);
+void*  stub_allocate_pmc_attributes(PARROT_INTERP, PMC*  stub_var1);
+void  stub_free_pmc_attributes(PARROT_INTERP, PMC*  stub_var1);
+void  stub_allocate_string_storage(PARROT_INTERP, STRING* str, size_t size);
+void  stub_reallocate_string_storage(PARROT_INTERP, STRING* str, size_t size);
+void  stub_allocate_buffer_storage(PARROT_INTERP, Buffer* buffer, size_t nsize);
+void  stub_reallocate_buffer_storage(PARROT_INTERP, Buffer* buffer, size_t newsize);
+void*  stub_allocate_fixed_size_storage(PARROT_INTERP, size_t size);
+void  stub_free_fixed_size_storage(PARROT_INTERP, size_t size, void*  stub_var1);
+void*  stub_allocate_memory_chunk(PARROT_INTERP, size_t size);
+void*  stub_reallocate_memory_chunk(PARROT_INTERP, void* data, size_t newsize);
+void*  stub_allocate_memory_chunk_with_interior_pointers(PARROT_INTERP, size_t size);
+void*  stub_reallocate_memory_chunk_with_interior_pointers(PARROT_INTERP, void* data,
+                                                           size_t oldsize, size_t newsize);
+void  stub_free_memory_chunk(PARROT_INTERP, void* data);
+void  stub_block_mark(PARROT_INTERP);
+void  stub_unblock_mark(PARROT_INTERP);
+void  stub_block_sweep(PARROT_INTERP);
+void  stub_unblock_sweep(PARROT_INTERP);
+/* END gc prototypes */
 
-*/
+void setup_gc_common_hashes(PARROT_INTERP) {
+    PMC *temp;
+    if(!gc_first_run) return;
 
-    METHOD get_hook_list(STRING *name) {
-        PMC *list;
+    gc_first_run   = 0;
+    gc_registry    = parrot_new_pointer_hash(interp);
+    gc_name_stubs  = parrot_new_hash(interp);
+    gc_group_items = parrot_new_hash(interp);
+    gc_item_groups = parrot_new_hash(interp);
 
-        list = Parrot_pmc_new(INTERP, enum_class_ResizableStringArray);
+    /* BEGIN gc mapping name stubs */
+    parrot_hash_put(interp, gc_name_stubs,
+        CONST_STRING(interp, "finalize_gc_system"),
+        stub_finalize_gc_system);
+    parrot_hash_put(interp, gc_name_stubs,
+        CONST_STRING(interp, "destroy_child_interp"),
+        stub_destroy_child_interp);
+    parrot_hash_put(interp, gc_name_stubs,
+        CONST_STRING(interp, "do_gc_mark"),
+        stub_do_gc_mark);
+    parrot_hash_put(interp, gc_name_stubs,
+        CONST_STRING(interp, "compact_string_pool"),
+        stub_compact_string_pool);
+    parrot_hash_put(interp, gc_name_stubs,
+        CONST_STRING(interp, "mark_special"),
+        stub_mark_special);
+    parrot_hash_put(interp, gc_name_stubs,
+        CONST_STRING(interp, "pmc_needs_early_collection"),
+        stub_pmc_needs_early_collection);
+    parrot_hash_put(interp, gc_name_stubs,
+        CONST_STRING(interp, "init_pool"),
+        stub_init_pool);
+    parrot_hash_put(interp, gc_name_stubs,
+        CONST_STRING(interp, "allocate_pmc_header"),
+        stub_allocate_pmc_header);
+    parrot_hash_put(interp, gc_name_stubs,
+        CONST_STRING(interp, "free_pmc_header"),
+        stub_free_pmc_header);
+    parrot_hash_put(interp, gc_name_stubs,
+        CONST_STRING(interp, "allocate_string_header"),
+        stub_allocate_string_header);
+    parrot_hash_put(interp, gc_name_stubs,
+        CONST_STRING(interp, "free_string_header"),
+        stub_free_string_header);
+    parrot_hash_put(interp, gc_name_stubs,
+        CONST_STRING(interp, "allocate_bufferlike_header"),
+        stub_allocate_bufferlike_header);
+    parrot_hash_put(interp, gc_name_stubs,
+        CONST_STRING(interp, "free_bufferlike_header"),
+        stub_free_bufferlike_header);
+    parrot_hash_put(interp, gc_name_stubs,
+        CONST_STRING(interp, "allocate_pmc_attributes"),
+        stub_allocate_pmc_attributes);
+    parrot_hash_put(interp, gc_name_stubs,
+        CONST_STRING(interp, "free_pmc_attributes"),
+        stub_free_pmc_attributes);
+    parrot_hash_put(interp, gc_name_stubs,
+        CONST_STRING(interp, "allocate_string_storage"),
+        stub_allocate_string_storage);
+    parrot_hash_put(interp, gc_name_stubs,
+        CONST_STRING(interp, "reallocate_string_storage"),
+        stub_reallocate_string_storage);
+    parrot_hash_put(interp, gc_name_stubs,
+        CONST_STRING(interp, "allocate_buffer_storage"),
+        stub_allocate_buffer_storage);
+    parrot_hash_put(interp, gc_name_stubs,
+        CONST_STRING(interp, "reallocate_buffer_storage"),
+        stub_reallocate_buffer_storage);
+    parrot_hash_put(interp, gc_name_stubs,
+        CONST_STRING(interp, "allocate_fixed_size_storage"),
+        stub_allocate_fixed_size_storage);
+    parrot_hash_put(interp, gc_name_stubs,
+        CONST_STRING(interp, "free_fixed_size_storage"),
+        stub_free_fixed_size_storage);
+    parrot_hash_put(interp, gc_name_stubs,
+        CONST_STRING(interp, "allocate_memory_chunk"),
+        stub_allocate_memory_chunk);
+    parrot_hash_put(interp, gc_name_stubs,
+        CONST_STRING(interp, "reallocate_memory_chunk"),
+        stub_reallocate_memory_chunk);
+    parrot_hash_put(interp, gc_name_stubs,
+        CONST_STRING(interp, "allocate_memory_chunk_with_interior_pointers"),
+        stub_allocate_memory_chunk_with_interior_pointers);
+    parrot_hash_put(interp, gc_name_stubs,
+        CONST_STRING(interp, "reallocate_memory_chunk_with_interior_pointers"),
+        stub_reallocate_memory_chunk_with_interior_pointers);
+    parrot_hash_put(interp, gc_name_stubs,
+        CONST_STRING(interp, "free_memory_chunk"),
+        stub_free_memory_chunk);
+    parrot_hash_put(interp, gc_name_stubs,
+        CONST_STRING(interp, "block_mark"),
+        stub_block_mark);
+    parrot_hash_put(interp, gc_name_stubs,
+        CONST_STRING(interp, "unblock_mark"),
+        stub_unblock_mark);
+    parrot_hash_put(interp, gc_name_stubs,
+        CONST_STRING(interp, "block_sweep"),
+        stub_block_sweep);
+    parrot_hash_put(interp, gc_name_stubs,
+        CONST_STRING(interp, "unblock_sweep"),
+        stub_unblock_sweep);
+    /* END gc mapping name stubs */
 
-        /* BEGIN gc groupings */
-        if (Parrot_str_equal(INTERP, name, CONST_STRING(INTERP, "free"))) {
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "free_pmc_header"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "free_string_header"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "free_bufferlike_header"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "free_pmc_attributes"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "free_fixed_size_storage"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "free_memory_chunk"));
-        }
-        else if (Parrot_str_equal(INTERP, name, CONST_STRING(INTERP, "administration"))) {
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "finalize_gc_system"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "destroy_child_interp"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "do_gc_mark"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "compact_string_pool"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "mark_special"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "pmc_needs_early_collection"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "init_pool"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "block_mark"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "unblock_mark"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "block_sweep"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "unblock_sweep"));
-        }
-        else if (Parrot_str_equal(INTERP, name, CONST_STRING(INTERP, "allocate"))) {
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "allocate_pmc_header"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "allocate_string_header"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "allocate_bufferlike_header"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "allocate_pmc_attributes"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "allocate_string_storage"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "allocate_buffer_storage"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "allocate_fixed_size_storage"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "allocate_memory_chunk"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "allocate_memory_chunk_with_interior_pointers"));
-        }
-        else if (Parrot_str_equal(INTERP, name, CONST_STRING(INTERP, "reallocate"))) {
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "reallocate_string_storage"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "reallocate_buffer_storage"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "reallocate_memory_chunk"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "reallocate_memory_chunk_with_interior_pointers"));
-        }
-
-        /* END gc groupings */
-        else {
-            /* Ensure that name is the name of a hook before pushing it in. */
-            size_t *check;
-            Hash *stub_hash;
-
-            GETATTR_InstrumentGC_stub_hash(INTERP, SELF, stub_hash);
-            check = (size_t *) parrot_hash_get(INTERP, stub_hash, name);
-            if (check == NULL) {
-                Parrot_ex_throw_from_c_args(INTERP, NULL, 1,
-                                            "Unknown GC function: %Ss", name);
-            }
+    /* BEGIN gc mapping group items */
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "free_pmc_header"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "free_string_header"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "free_bufferlike_header"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "free_pmc_attributes"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "free_fixed_size_storage"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "free_memory_chunk"));
+    parrot_hash_put(interp, gc_group_items,
+                    CONST_STRING(interp, "free"),
+                    temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "finalize_gc_system"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "destroy_child_interp"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "do_gc_mark"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "compact_string_pool"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "mark_special"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "pmc_needs_early_collection"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "init_pool"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "block_mark"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "unblock_mark"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "block_sweep"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "unblock_sweep"));
+    parrot_hash_put(interp, gc_group_items,
+                    CONST_STRING(interp, "administration"),
+                    temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "allocate_pmc_header"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "allocate_string_header"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "allocate_bufferlike_header"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "allocate_pmc_attributes"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "allocate_string_storage"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "allocate_buffer_storage"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "allocate_fixed_size_storage"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "allocate_memory_chunk"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "allocate_memory_chunk_with_interior_pointers"));
+    parrot_hash_put(interp, gc_group_items,
+                    CONST_STRING(interp, "allocate"),
+                    temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "reallocate_string_storage"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "reallocate_buffer_storage"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "reallocate_memory_chunk"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "reallocate_memory_chunk_with_interior_pointers"));
+    parrot_hash_put(interp, gc_group_items,
+                    CONST_STRING(interp, "reallocate"),
+                    temp);
+    /* END gc mapping group items */
+
+    /* BEGIN gc mapping item groups */
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "administration"));
+    parrot_hash_put(interp, gc_item_groups,
+        CONST_STRING(interp, "finalize_gc_system"),
+        temp);
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "administration"));
+    parrot_hash_put(interp, gc_item_groups,
+        CONST_STRING(interp, "destroy_child_interp"),
+        temp);
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "administration"));
+    parrot_hash_put(interp, gc_item_groups,
+        CONST_STRING(interp, "do_gc_mark"),
+        temp);
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "administration"));
+    parrot_hash_put(interp, gc_item_groups,
+        CONST_STRING(interp, "compact_string_pool"),
+        temp);
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "administration"));
+    parrot_hash_put(interp, gc_item_groups,
+        CONST_STRING(interp, "mark_special"),
+        temp);
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "administration"));
+    parrot_hash_put(interp, gc_item_groups,
+        CONST_STRING(interp, "pmc_needs_early_collection"),
+        temp);
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "administration"));
+    parrot_hash_put(interp, gc_item_groups,
+        CONST_STRING(interp, "init_pool"),
+        temp);
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "allocate"));
+    parrot_hash_put(interp, gc_item_groups,
+        CONST_STRING(interp, "allocate_pmc_header"),
+        temp);
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "free"));
+    parrot_hash_put(interp, gc_item_groups,
+        CONST_STRING(interp, "free_pmc_header"),
+        temp);
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "allocate"));
+    parrot_hash_put(interp, gc_item_groups,
+        CONST_STRING(interp, "allocate_string_header"),
+        temp);
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "free"));
+    parrot_hash_put(interp, gc_item_groups,
+        CONST_STRING(interp, "free_string_header"),
+        temp);
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "allocate"));
+    parrot_hash_put(interp, gc_item_groups,
+        CONST_STRING(interp, "allocate_bufferlike_header"),
+        temp);
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "free"));
+    parrot_hash_put(interp, gc_item_groups,
+        CONST_STRING(interp, "free_bufferlike_header"),
+        temp);
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "allocate"));
+    parrot_hash_put(interp, gc_item_groups,
+        CONST_STRING(interp, "allocate_pmc_attributes"),
+        temp);
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "free"));
+    parrot_hash_put(interp, gc_item_groups,
+        CONST_STRING(interp, "free_pmc_attributes"),
+        temp);
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "allocate"));
+    parrot_hash_put(interp, gc_item_groups,
+        CONST_STRING(interp, "allocate_string_storage"),
+        temp);
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "reallocate"));
+    parrot_hash_put(interp, gc_item_groups,
+        CONST_STRING(interp, "reallocate_string_storage"),
+        temp);
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "allocate"));
+    parrot_hash_put(interp, gc_item_groups,
+        CONST_STRING(interp, "allocate_buffer_storage"),
+        temp);
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "reallocate"));
+    parrot_hash_put(interp, gc_item_groups,
+        CONST_STRING(interp, "reallocate_buffer_storage"),
+        temp);
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "allocate"));
+    parrot_hash_put(interp, gc_item_groups,
+        CONST_STRING(interp, "allocate_fixed_size_storage"),
+        temp);
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "free"));
+    parrot_hash_put(interp, gc_item_groups,
+        CONST_STRING(interp, "free_fixed_size_storage"),
+        temp);
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "allocate"));
+    parrot_hash_put(interp, gc_item_groups,
+        CONST_STRING(interp, "allocate_memory_chunk"),
+        temp);
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "reallocate"));
+    parrot_hash_put(interp, gc_item_groups,
+        CONST_STRING(interp, "reallocate_memory_chunk"),
+        temp);
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "allocate"));
+    parrot_hash_put(interp, gc_item_groups,
+        CONST_STRING(interp, "allocate_memory_chunk_with_interior_pointers"),
+        temp);
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "reallocate"));
+    parrot_hash_put(interp, gc_item_groups,
+        CONST_STRING(interp, "reallocate_memory_chunk_with_interior_pointers"),
+        temp);
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "free"));
+    parrot_hash_put(interp, gc_item_groups,
+        CONST_STRING(interp, "free_memory_chunk"),
+        temp);
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "administration"));
+    parrot_hash_put(interp, gc_item_groups,
+        CONST_STRING(interp, "block_mark"),
+        temp);
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "administration"));
+    parrot_hash_put(interp, gc_item_groups,
+        CONST_STRING(interp, "unblock_mark"),
+        temp);
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "administration"));
+    parrot_hash_put(interp, gc_item_groups,
+        CONST_STRING(interp, "block_sweep"),
+        temp);
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "administration"));
+    parrot_hash_put(interp, gc_item_groups,
+        CONST_STRING(interp, "unblock_sweep"),
+        temp);
+    /* END gc mapping item groups */
+}
 
-            VTABLE_push_string(INTERP, list, name);
-        }
+void destroy_gc_common_hashes(PARROT_INTERP) {
+    if(parrot_hash_size(interp, gc_registry) == 0) {
+        parrot_hash_destroy(interp, gc_registry);
+        parrot_hash_destroy(interp, gc_name_stubs);
+        parrot_hash_destroy(interp, gc_group_items);
+        parrot_hash_destroy(interp, gc_item_groups);
 
-        RETURN(PMC *list);
+        gc_first_run = 1;
     }
-
 }
 
-/*
- * Stub Functions
- * The following stub functions map to the corresponding GC functions.
- * It will:
- * 1. Call the GC function.
- * 2. Gather the data for raising the event.
- * 3. Raise an event denoting that the function has been accessed.
- */
+void setup_gc_individual_hashes(PARROT_INTERP, Hash *orig_hash, Hash *instr_hash,
+                                GC_Subsystem *gc_orig, InstrumentGC_Subsystem *gc_instr) {
+    /* BEGIN gc mapping name offset */
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "finalize_gc_system"),
+        &(gc_instr->finalize_gc_system));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "destroy_child_interp"),
+        &(gc_instr->destroy_child_interp));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "do_gc_mark"),
+        &(gc_instr->do_gc_mark));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "compact_string_pool"),
+        &(gc_instr->compact_string_pool));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "mark_special"),
+        &(gc_instr->mark_special));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "pmc_needs_early_collection"),
+        &(gc_instr->pmc_needs_early_collection));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "init_pool"),
+        &(gc_instr->init_pool));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "allocate_pmc_header"),
+        &(gc_instr->allocate_pmc_header));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "free_pmc_header"),
+        &(gc_instr->free_pmc_header));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "allocate_string_header"),
+        &(gc_instr->allocate_string_header));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "free_string_header"),
+        &(gc_instr->free_string_header));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "allocate_bufferlike_header"),
+        &(gc_instr->allocate_bufferlike_header));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "free_bufferlike_header"),
+        &(gc_instr->free_bufferlike_header));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "allocate_pmc_attributes"),
+        &(gc_instr->allocate_pmc_attributes));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "free_pmc_attributes"),
+        &(gc_instr->free_pmc_attributes));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "allocate_string_storage"),
+        &(gc_instr->allocate_string_storage));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "reallocate_string_storage"),
+        &(gc_instr->reallocate_string_storage));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "allocate_buffer_storage"),
+        &(gc_instr->allocate_buffer_storage));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "reallocate_buffer_storage"),
+        &(gc_instr->reallocate_buffer_storage));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "allocate_fixed_size_storage"),
+        &(gc_instr->allocate_fixed_size_storage));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "free_fixed_size_storage"),
+        &(gc_instr->free_fixed_size_storage));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "allocate_memory_chunk"),
+        &(gc_instr->allocate_memory_chunk));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "reallocate_memory_chunk"),
+        &(gc_instr->reallocate_memory_chunk));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "allocate_memory_chunk_with_interior_pointers"),
+        &(gc_instr->allocate_memory_chunk_with_interior_pointers));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "reallocate_memory_chunk_with_interior_pointers"),
+        &(gc_instr->reallocate_memory_chunk_with_interior_pointers));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "free_memory_chunk"),
+        &(gc_instr->free_memory_chunk));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "block_mark"),
+        &(gc_instr->block_mark));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "unblock_mark"),
+        &(gc_instr->unblock_mark));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "block_sweep"),
+        &(gc_instr->block_sweep));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "unblock_sweep"),
+        &(gc_instr->unblock_sweep));
+    /* END gc mapping name offset */
+
+    /* BEGIN gc mapping name original */
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "finalize_gc_system"),
+        gc_orig->finalize_gc_system);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "destroy_child_interp"),
+        gc_orig->destroy_child_interp);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "do_gc_mark"),
+        gc_orig->do_gc_mark);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "compact_string_pool"),
+        gc_orig->compact_string_pool);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "mark_special"),
+        gc_orig->mark_special);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "pmc_needs_early_collection"),
+        gc_orig->pmc_needs_early_collection);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "init_pool"),
+        gc_orig->init_pool);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "allocate_pmc_header"),
+        gc_orig->allocate_pmc_header);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "free_pmc_header"),
+        gc_orig->free_pmc_header);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "allocate_string_header"),
+        gc_orig->allocate_string_header);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "free_string_header"),
+        gc_orig->free_string_header);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "allocate_bufferlike_header"),
+        gc_orig->allocate_bufferlike_header);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "free_bufferlike_header"),
+        gc_orig->free_bufferlike_header);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "allocate_pmc_attributes"),
+        gc_orig->allocate_pmc_attributes);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "free_pmc_attributes"),
+        gc_orig->free_pmc_attributes);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "allocate_string_storage"),
+        gc_orig->allocate_string_storage);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "reallocate_string_storage"),
+        gc_orig->reallocate_string_storage);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "allocate_buffer_storage"),
+        gc_orig->allocate_buffer_storage);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "reallocate_buffer_storage"),
+        gc_orig->reallocate_buffer_storage);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "allocate_fixed_size_storage"),
+        gc_orig->allocate_fixed_size_storage);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "free_fixed_size_storage"),
+        gc_orig->free_fixed_size_storage);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "allocate_memory_chunk"),
+        gc_orig->allocate_memory_chunk);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "reallocate_memory_chunk"),
+        gc_orig->reallocate_memory_chunk);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "allocate_memory_chunk_with_interior_pointers"),
+        gc_orig->allocate_memory_chunk_with_interior_pointers);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "reallocate_memory_chunk_with_interior_pointers"),
+        gc_orig->reallocate_memory_chunk_with_interior_pointers);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "free_memory_chunk"),
+        gc_orig->free_memory_chunk);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "block_mark"),
+        gc_orig->block_mark);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "unblock_mark"),
+        gc_orig->unblock_mark);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "block_sweep"),
+        gc_orig->block_sweep);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "unblock_sweep"),
+        gc_orig->unblock_sweep);
+    /* END gc mapping name original */
+}
 
 /* BEGIN gc stubs */
 void  stub_finalize_gc_system(Parrot_Interp interp) {
-    PMC *instr_gc            = ((InstrumentGC_Subsystem *) interp->gc_sys)->instrument_gc;
+    GC_Subsystem *gc_orig    = ((InstrumentGC_Subsystem *) interp->gc_sys)->original;
     Parrot_Interp supervisor = ((InstrumentGC_Subsystem *) interp->gc_sys)->supervisor;
-    GC_Subsystem *gc_orig;
+
     PMC *event_data;
     PMC *temp;
     PMC *params = Parrot_pmc_new(supervisor, enum_class_ResizablePMCArray);
 
-    GETATTR_InstrumentGC_gc_original(supervisor, instr_gc, gc_orig);
+
     gc_orig->finalize_gc_system(interp);
 
 
@@ -464,14 +826,14 @@
 }
 
 void  stub_destroy_child_interp(Interp* interp, Interp* child_interp) {
-    PMC *instr_gc            = ((InstrumentGC_Subsystem *) interp->gc_sys)->instrument_gc;
+    GC_Subsystem *gc_orig    = ((InstrumentGC_Subsystem *) interp->gc_sys)->original;
     Parrot_Interp supervisor = ((InstrumentGC_Subsystem *) interp->gc_sys)->supervisor;
-    GC_Subsystem *gc_orig;
+
     PMC *event_data;
     PMC *temp;
     PMC *params = Parrot_pmc_new(supervisor, enum_class_ResizablePMCArray);
 
-    GETATTR_InstrumentGC_gc_original(supervisor, instr_gc, gc_orig);
+
     gc_orig->destroy_child_interp(interp, child_interp);
 
     temp = Parrot_pmc_new(supervisor, enum_class_Pointer);
@@ -492,14 +854,14 @@
 }
 
 void  stub_do_gc_mark(Parrot_Interp interp, UINTVAL flags) {
-    PMC *instr_gc            = ((InstrumentGC_Subsystem *) interp->gc_sys)->instrument_gc;
+    GC_Subsystem *gc_orig    = ((InstrumentGC_Subsystem *) interp->gc_sys)->original;
     Parrot_Interp supervisor = ((InstrumentGC_Subsystem *) interp->gc_sys)->supervisor;
-    GC_Subsystem *gc_orig;
+
     PMC *event_data;
     PMC *temp;
     PMC *params = Parrot_pmc_new(supervisor, enum_class_ResizablePMCArray);
 
-    GETATTR_InstrumentGC_gc_original(supervisor, instr_gc, gc_orig);
+
     gc_orig->do_gc_mark(interp, flags);
 
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -520,14 +882,14 @@
 }
 
 void  stub_compact_string_pool(Parrot_Interp interp) {
-    PMC *instr_gc            = ((InstrumentGC_Subsystem *) interp->gc_sys)->instrument_gc;
+    GC_Subsystem *gc_orig    = ((InstrumentGC_Subsystem *) interp->gc_sys)->original;
     Parrot_Interp supervisor = ((InstrumentGC_Subsystem *) interp->gc_sys)->supervisor;
-    GC_Subsystem *gc_orig;
+
     PMC *event_data;
     PMC *temp;
     PMC *params = Parrot_pmc_new(supervisor, enum_class_ResizablePMCArray);
 
-    GETATTR_InstrumentGC_gc_original(supervisor, instr_gc, gc_orig);
+
     gc_orig->compact_string_pool(interp);
 
 
@@ -545,14 +907,14 @@
 }
 
 void  stub_mark_special(Parrot_Interp interp, PMC* stub_var1) {
-    PMC *instr_gc            = ((InstrumentGC_Subsystem *) interp->gc_sys)->instrument_gc;
+    GC_Subsystem *gc_orig    = ((InstrumentGC_Subsystem *) interp->gc_sys)->original;
     Parrot_Interp supervisor = ((InstrumentGC_Subsystem *) interp->gc_sys)->supervisor;
-    GC_Subsystem *gc_orig;
+
     PMC *event_data;
     PMC *temp;
     PMC *params = Parrot_pmc_new(supervisor, enum_class_ResizablePMCArray);
 
-    GETATTR_InstrumentGC_gc_original(supervisor, instr_gc, gc_orig);
+
     gc_orig->mark_special(interp, stub_var1);
 
     temp = Parrot_pmc_new(supervisor, enum_class_Pointer);
@@ -573,14 +935,14 @@
 }
 
 void  stub_pmc_needs_early_collection(Parrot_Interp interp, PMC* stub_var1) {
-    PMC *instr_gc            = ((InstrumentGC_Subsystem *) interp->gc_sys)->instrument_gc;
+    GC_Subsystem *gc_orig    = ((InstrumentGC_Subsystem *) interp->gc_sys)->original;
     Parrot_Interp supervisor = ((InstrumentGC_Subsystem *) interp->gc_sys)->supervisor;
-    GC_Subsystem *gc_orig;
+
     PMC *event_data;
     PMC *temp;
     PMC *params = Parrot_pmc_new(supervisor, enum_class_ResizablePMCArray);
 
-    GETATTR_InstrumentGC_gc_original(supervisor, instr_gc, gc_orig);
+
     gc_orig->pmc_needs_early_collection(interp, stub_var1);
 
     temp = Parrot_pmc_new(supervisor, enum_class_Pointer);
@@ -601,14 +963,14 @@
 }
 
 void  stub_init_pool(Parrot_Interp interp, struct Fixed_Size_Pool* stub_var1) {
-    PMC *instr_gc            = ((InstrumentGC_Subsystem *) interp->gc_sys)->instrument_gc;
+    GC_Subsystem *gc_orig    = ((InstrumentGC_Subsystem *) interp->gc_sys)->original;
     Parrot_Interp supervisor = ((InstrumentGC_Subsystem *) interp->gc_sys)->supervisor;
-    GC_Subsystem *gc_orig;
+
     PMC *event_data;
     PMC *temp;
     PMC *params = Parrot_pmc_new(supervisor, enum_class_ResizablePMCArray);
 
-    GETATTR_InstrumentGC_gc_original(supervisor, instr_gc, gc_orig);
+
     gc_orig->init_pool(interp, stub_var1);
 
     temp = Parrot_pmc_new(supervisor, enum_class_Pointer);
@@ -629,15 +991,15 @@
 }
 
 PMC*  stub_allocate_pmc_header(Parrot_Interp interp, UINTVAL flags) {
-    PMC *instr_gc            = ((InstrumentGC_Subsystem *) interp->gc_sys)->instrument_gc;
+    GC_Subsystem *gc_orig    = ((InstrumentGC_Subsystem *) interp->gc_sys)->original;
     Parrot_Interp supervisor = ((InstrumentGC_Subsystem *) interp->gc_sys)->supervisor;
-    GC_Subsystem *gc_orig;
+
     PMC *event_data;
     PMC *temp;
     PMC *params = Parrot_pmc_new(supervisor, enum_class_ResizablePMCArray);
     PMC*  ret;
 
-    GETATTR_InstrumentGC_gc_original(supervisor, instr_gc, gc_orig);
+
     ret = gc_orig->allocate_pmc_header(interp, flags);
 
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -658,14 +1020,14 @@
 }
 
 void  stub_free_pmc_header(Parrot_Interp interp, PMC* stub_var1) {
-    PMC *instr_gc            = ((InstrumentGC_Subsystem *) interp->gc_sys)->instrument_gc;
+    GC_Subsystem *gc_orig    = ((InstrumentGC_Subsystem *) interp->gc_sys)->original;
     Parrot_Interp supervisor = ((InstrumentGC_Subsystem *) interp->gc_sys)->supervisor;
-    GC_Subsystem *gc_orig;
+
     PMC *event_data;
     PMC *temp;
     PMC *params = Parrot_pmc_new(supervisor, enum_class_ResizablePMCArray);
 
-    GETATTR_InstrumentGC_gc_original(supervisor, instr_gc, gc_orig);
+
     gc_orig->free_pmc_header(interp, stub_var1);
 
     temp = Parrot_pmc_new(supervisor, enum_class_Pointer);
@@ -686,15 +1048,15 @@
 }
 
 STRING*  stub_allocate_string_header(Parrot_Interp interp, UINTVAL flags) {
-    PMC *instr_gc            = ((InstrumentGC_Subsystem *) interp->gc_sys)->instrument_gc;
+    GC_Subsystem *gc_orig    = ((InstrumentGC_Subsystem *) interp->gc_sys)->original;
     Parrot_Interp supervisor = ((InstrumentGC_Subsystem *) interp->gc_sys)->supervisor;
-    GC_Subsystem *gc_orig;
+
     PMC *event_data;
     PMC *temp;
     PMC *params = Parrot_pmc_new(supervisor, enum_class_ResizablePMCArray);
     STRING*  ret;
 
-    GETATTR_InstrumentGC_gc_original(supervisor, instr_gc, gc_orig);
+
     ret = gc_orig->allocate_string_header(interp, flags);
 
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -715,14 +1077,14 @@
 }
 
 void  stub_free_string_header(Parrot_Interp interp, STRING* stub_var1) {
-    PMC *instr_gc            = ((InstrumentGC_Subsystem *) interp->gc_sys)->instrument_gc;
+    GC_Subsystem *gc_orig    = ((InstrumentGC_Subsystem *) interp->gc_sys)->original;
     Parrot_Interp supervisor = ((InstrumentGC_Subsystem *) interp->gc_sys)->supervisor;
-    GC_Subsystem *gc_orig;
+
     PMC *event_data;
     PMC *temp;
     PMC *params = Parrot_pmc_new(supervisor, enum_class_ResizablePMCArray);
 
-    GETATTR_InstrumentGC_gc_original(supervisor, instr_gc, gc_orig);
+
     gc_orig->free_string_header(interp, stub_var1);
 
     temp = Parrot_pmc_new(supervisor, enum_class_Pointer);
@@ -743,15 +1105,15 @@
 }
 
 Buffer*  stub_allocate_bufferlike_header(Parrot_Interp interp, size_t size) {
-    PMC *instr_gc            = ((InstrumentGC_Subsystem *) interp->gc_sys)->instrument_gc;
+    GC_Subsystem *gc_orig    = ((InstrumentGC_Subsystem *) interp->gc_sys)->original;
     Parrot_Interp supervisor = ((InstrumentGC_Subsystem *) interp->gc_sys)->supervisor;
-    GC_Subsystem *gc_orig;
+
     PMC *event_data;
     PMC *temp;
     PMC *params = Parrot_pmc_new(supervisor, enum_class_ResizablePMCArray);
     Buffer*  ret;
 
-    GETATTR_InstrumentGC_gc_original(supervisor, instr_gc, gc_orig);
+
     ret = gc_orig->allocate_bufferlike_header(interp, size);
 
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -772,14 +1134,14 @@
 }
 
 void  stub_free_bufferlike_header(Parrot_Interp interp, Buffer* stub_var1, size_t size) {
-    PMC *instr_gc            = ((InstrumentGC_Subsystem *) interp->gc_sys)->instrument_gc;
+    GC_Subsystem *gc_orig    = ((InstrumentGC_Subsystem *) interp->gc_sys)->original;
     Parrot_Interp supervisor = ((InstrumentGC_Subsystem *) interp->gc_sys)->supervisor;
-    GC_Subsystem *gc_orig;
+
     PMC *event_data;
     PMC *temp;
     PMC *params = Parrot_pmc_new(supervisor, enum_class_ResizablePMCArray);
 
-    GETATTR_InstrumentGC_gc_original(supervisor, instr_gc, gc_orig);
+
     gc_orig->free_bufferlike_header(interp, stub_var1, size);
 
     temp = Parrot_pmc_new(supervisor, enum_class_Pointer);
@@ -803,15 +1165,15 @@
 }
 
 void*  stub_allocate_pmc_attributes(Parrot_Interp interp, PMC* stub_var1) {
-    PMC *instr_gc            = ((InstrumentGC_Subsystem *) interp->gc_sys)->instrument_gc;
+    GC_Subsystem *gc_orig    = ((InstrumentGC_Subsystem *) interp->gc_sys)->original;
     Parrot_Interp supervisor = ((InstrumentGC_Subsystem *) interp->gc_sys)->supervisor;
-    GC_Subsystem *gc_orig;
+
     PMC *event_data;
     PMC *temp;
     PMC *params = Parrot_pmc_new(supervisor, enum_class_ResizablePMCArray);
     void*  ret;
 
-    GETATTR_InstrumentGC_gc_original(supervisor, instr_gc, gc_orig);
+
     ret = gc_orig->allocate_pmc_attributes(interp, stub_var1);
 
     temp = Parrot_pmc_new(supervisor, enum_class_Pointer);
@@ -832,14 +1194,14 @@
 }
 
 void  stub_free_pmc_attributes(Parrot_Interp interp, PMC* stub_var1) {
-    PMC *instr_gc            = ((InstrumentGC_Subsystem *) interp->gc_sys)->instrument_gc;
+    GC_Subsystem *gc_orig    = ((InstrumentGC_Subsystem *) interp->gc_sys)->original;
     Parrot_Interp supervisor = ((InstrumentGC_Subsystem *) interp->gc_sys)->supervisor;
-    GC_Subsystem *gc_orig;
+
     PMC *event_data;
     PMC *temp;
     PMC *params = Parrot_pmc_new(supervisor, enum_class_ResizablePMCArray);
 
-    GETATTR_InstrumentGC_gc_original(supervisor, instr_gc, gc_orig);
+
     gc_orig->free_pmc_attributes(interp, stub_var1);
 
     temp = Parrot_pmc_new(supervisor, enum_class_Pointer);
@@ -860,14 +1222,14 @@
 }
 
 void  stub_allocate_string_storage(Parrot_Interp interp, STRING* str, size_t size) {
-    PMC *instr_gc            = ((InstrumentGC_Subsystem *) interp->gc_sys)->instrument_gc;
+    GC_Subsystem *gc_orig    = ((InstrumentGC_Subsystem *) interp->gc_sys)->original;
     Parrot_Interp supervisor = ((InstrumentGC_Subsystem *) interp->gc_sys)->supervisor;
-    GC_Subsystem *gc_orig;
+
     PMC *event_data;
     PMC *temp;
     PMC *params = Parrot_pmc_new(supervisor, enum_class_ResizablePMCArray);
 
-    GETATTR_InstrumentGC_gc_original(supervisor, instr_gc, gc_orig);
+
     gc_orig->allocate_string_storage(interp, str, size);
 
     temp = Parrot_pmc_new(supervisor, enum_class_Pointer);
@@ -891,14 +1253,14 @@
 }
 
 void  stub_reallocate_string_storage(Parrot_Interp interp, STRING* str, size_t size) {
-    PMC *instr_gc            = ((InstrumentGC_Subsystem *) interp->gc_sys)->instrument_gc;
+    GC_Subsystem *gc_orig    = ((InstrumentGC_Subsystem *) interp->gc_sys)->original;
     Parrot_Interp supervisor = ((InstrumentGC_Subsystem *) interp->gc_sys)->supervisor;
-    GC_Subsystem *gc_orig;
+
     PMC *event_data;
     PMC *temp;
     PMC *params = Parrot_pmc_new(supervisor, enum_class_ResizablePMCArray);
 
-    GETATTR_InstrumentGC_gc_original(supervisor, instr_gc, gc_orig);
+
     gc_orig->reallocate_string_storage(interp, str, size);
 
     temp = Parrot_pmc_new(supervisor, enum_class_Pointer);
@@ -922,14 +1284,14 @@
 }
 
 void  stub_allocate_buffer_storage(Parrot_Interp interp, Buffer* buffer, size_t nsize) {
-    PMC *instr_gc            = ((InstrumentGC_Subsystem *) interp->gc_sys)->instrument_gc;
+    GC_Subsystem *gc_orig    = ((InstrumentGC_Subsystem *) interp->gc_sys)->original;
     Parrot_Interp supervisor = ((InstrumentGC_Subsystem *) interp->gc_sys)->supervisor;
-    GC_Subsystem *gc_orig;
+
     PMC *event_data;
     PMC *temp;
     PMC *params = Parrot_pmc_new(supervisor, enum_class_ResizablePMCArray);
 
-    GETATTR_InstrumentGC_gc_original(supervisor, instr_gc, gc_orig);
+
     gc_orig->allocate_buffer_storage(interp, buffer, nsize);
 
     temp = Parrot_pmc_new(supervisor, enum_class_Pointer);
@@ -953,14 +1315,14 @@
 }
 
 void  stub_reallocate_buffer_storage(Parrot_Interp interp, Buffer* buffer, size_t newsize) {
-    PMC *instr_gc            = ((InstrumentGC_Subsystem *) interp->gc_sys)->instrument_gc;
+    GC_Subsystem *gc_orig    = ((InstrumentGC_Subsystem *) interp->gc_sys)->original;
     Parrot_Interp supervisor = ((InstrumentGC_Subsystem *) interp->gc_sys)->supervisor;
-    GC_Subsystem *gc_orig;
+
     PMC *event_data;
     PMC *temp;
     PMC *params = Parrot_pmc_new(supervisor, enum_class_ResizablePMCArray);
 
-    GETATTR_InstrumentGC_gc_original(supervisor, instr_gc, gc_orig);
+
     gc_orig->reallocate_buffer_storage(interp, buffer, newsize);
 
     temp = Parrot_pmc_new(supervisor, enum_class_Pointer);
@@ -984,15 +1346,15 @@
 }
 
 void*  stub_allocate_fixed_size_storage(Parrot_Interp interp, size_t size) {
-    PMC *instr_gc            = ((InstrumentGC_Subsystem *) interp->gc_sys)->instrument_gc;
+    GC_Subsystem *gc_orig    = ((InstrumentGC_Subsystem *) interp->gc_sys)->original;
     Parrot_Interp supervisor = ((InstrumentGC_Subsystem *) interp->gc_sys)->supervisor;
-    GC_Subsystem *gc_orig;
+
     PMC *event_data;
     PMC *temp;
     PMC *params = Parrot_pmc_new(supervisor, enum_class_ResizablePMCArray);
     void*  ret;
 
-    GETATTR_InstrumentGC_gc_original(supervisor, instr_gc, gc_orig);
+
     ret = gc_orig->allocate_fixed_size_storage(interp, size);
 
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -1013,14 +1375,14 @@
 }
 
 void  stub_free_fixed_size_storage(Parrot_Interp interp, size_t size, void* stub_var1) {
-    PMC *instr_gc            = ((InstrumentGC_Subsystem *) interp->gc_sys)->instrument_gc;
+    GC_Subsystem *gc_orig    = ((InstrumentGC_Subsystem *) interp->gc_sys)->original;
     Parrot_Interp supervisor = ((InstrumentGC_Subsystem *) interp->gc_sys)->supervisor;
-    GC_Subsystem *gc_orig;
+
     PMC *event_data;
     PMC *temp;
     PMC *params = Parrot_pmc_new(supervisor, enum_class_ResizablePMCArray);
 
-    GETATTR_InstrumentGC_gc_original(supervisor, instr_gc, gc_orig);
+
     gc_orig->free_fixed_size_storage(interp, size, stub_var1);
 
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -1044,15 +1406,15 @@
 }
 
 void*  stub_allocate_memory_chunk(Parrot_Interp interp, size_t size) {
-    PMC *instr_gc            = ((InstrumentGC_Subsystem *) interp->gc_sys)->instrument_gc;
+    GC_Subsystem *gc_orig    = ((InstrumentGC_Subsystem *) interp->gc_sys)->original;
     Parrot_Interp supervisor = ((InstrumentGC_Subsystem *) interp->gc_sys)->supervisor;
-    GC_Subsystem *gc_orig;
+
     PMC *event_data;
     PMC *temp;
     PMC *params = Parrot_pmc_new(supervisor, enum_class_ResizablePMCArray);
     void*  ret;
 
-    GETATTR_InstrumentGC_gc_original(supervisor, instr_gc, gc_orig);
+
     ret = gc_orig->allocate_memory_chunk(interp, size);
 
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -1073,15 +1435,15 @@
 }
 
 void*  stub_reallocate_memory_chunk(Parrot_Interp interp, void* data, size_t newsize) {
-    PMC *instr_gc            = ((InstrumentGC_Subsystem *) interp->gc_sys)->instrument_gc;
+    GC_Subsystem *gc_orig    = ((InstrumentGC_Subsystem *) interp->gc_sys)->original;
     Parrot_Interp supervisor = ((InstrumentGC_Subsystem *) interp->gc_sys)->supervisor;
-    GC_Subsystem *gc_orig;
+
     PMC *event_data;
     PMC *temp;
     PMC *params = Parrot_pmc_new(supervisor, enum_class_ResizablePMCArray);
     void*  ret;
 
-    GETATTR_InstrumentGC_gc_original(supervisor, instr_gc, gc_orig);
+
     ret = gc_orig->reallocate_memory_chunk(interp, data, newsize);
 
     temp = Parrot_pmc_new(supervisor, enum_class_Pointer);
@@ -1105,15 +1467,15 @@
 }
 
 void*  stub_allocate_memory_chunk_with_interior_pointers(Parrot_Interp interp, size_t size) {
-    PMC *instr_gc            = ((InstrumentGC_Subsystem *) interp->gc_sys)->instrument_gc;
+    GC_Subsystem *gc_orig    = ((InstrumentGC_Subsystem *) interp->gc_sys)->original;
     Parrot_Interp supervisor = ((InstrumentGC_Subsystem *) interp->gc_sys)->supervisor;
-    GC_Subsystem *gc_orig;
+
     PMC *event_data;
     PMC *temp;
     PMC *params = Parrot_pmc_new(supervisor, enum_class_ResizablePMCArray);
     void*  ret;
 
-    GETATTR_InstrumentGC_gc_original(supervisor, instr_gc, gc_orig);
+
     ret = gc_orig->allocate_memory_chunk_with_interior_pointers(interp, size);
 
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -1135,15 +1497,15 @@
 
 void*  stub_reallocate_memory_chunk_with_interior_pointers(Parrot_Interp interp, void* data,
                                                            size_t oldsize, size_t newsize) {
-    PMC *instr_gc            = ((InstrumentGC_Subsystem *) interp->gc_sys)->instrument_gc;
+    GC_Subsystem *gc_orig    = ((InstrumentGC_Subsystem *) interp->gc_sys)->original;
     Parrot_Interp supervisor = ((InstrumentGC_Subsystem *) interp->gc_sys)->supervisor;
-    GC_Subsystem *gc_orig;
+
     PMC *event_data;
     PMC *temp;
     PMC *params = Parrot_pmc_new(supervisor, enum_class_ResizablePMCArray);
     void*  ret;
 
-    GETATTR_InstrumentGC_gc_original(supervisor, instr_gc, gc_orig);
+
     ret = gc_orig->reallocate_memory_chunk_with_interior_pointers(interp, data, oldsize, newsize);
 
     temp = Parrot_pmc_new(supervisor, enum_class_Pointer);
@@ -1170,14 +1532,14 @@
 }
 
 void  stub_free_memory_chunk(Parrot_Interp interp, void* data) {
-    PMC *instr_gc            = ((InstrumentGC_Subsystem *) interp->gc_sys)->instrument_gc;
+    GC_Subsystem *gc_orig    = ((InstrumentGC_Subsystem *) interp->gc_sys)->original;
     Parrot_Interp supervisor = ((InstrumentGC_Subsystem *) interp->gc_sys)->supervisor;
-    GC_Subsystem *gc_orig;
+
     PMC *event_data;
     PMC *temp;
     PMC *params = Parrot_pmc_new(supervisor, enum_class_ResizablePMCArray);
 
-    GETATTR_InstrumentGC_gc_original(supervisor, instr_gc, gc_orig);
+
     gc_orig->free_memory_chunk(interp, data);
 
     temp = Parrot_pmc_new(supervisor, enum_class_Pointer);
@@ -1198,14 +1560,14 @@
 }
 
 void  stub_block_mark(Parrot_Interp interp) {
-    PMC *instr_gc            = ((InstrumentGC_Subsystem *) interp->gc_sys)->instrument_gc;
+    GC_Subsystem *gc_orig    = ((InstrumentGC_Subsystem *) interp->gc_sys)->original;
     Parrot_Interp supervisor = ((InstrumentGC_Subsystem *) interp->gc_sys)->supervisor;
-    GC_Subsystem *gc_orig;
+
     PMC *event_data;
     PMC *temp;
     PMC *params = Parrot_pmc_new(supervisor, enum_class_ResizablePMCArray);
 
-    GETATTR_InstrumentGC_gc_original(supervisor, instr_gc, gc_orig);
+
     gc_orig->block_mark(interp);
 
 
@@ -1223,14 +1585,14 @@
 }
 
 void  stub_unblock_mark(Parrot_Interp interp) {
-    PMC *instr_gc            = ((InstrumentGC_Subsystem *) interp->gc_sys)->instrument_gc;
+    GC_Subsystem *gc_orig    = ((InstrumentGC_Subsystem *) interp->gc_sys)->original;
     Parrot_Interp supervisor = ((InstrumentGC_Subsystem *) interp->gc_sys)->supervisor;
-    GC_Subsystem *gc_orig;
+
     PMC *event_data;
     PMC *temp;
     PMC *params = Parrot_pmc_new(supervisor, enum_class_ResizablePMCArray);
 
-    GETATTR_InstrumentGC_gc_original(supervisor, instr_gc, gc_orig);
+
     gc_orig->unblock_mark(interp);
 
 
@@ -1248,14 +1610,14 @@
 }
 
 void  stub_block_sweep(Parrot_Interp interp) {
-    PMC *instr_gc            = ((InstrumentGC_Subsystem *) interp->gc_sys)->instrument_gc;
+    GC_Subsystem *gc_orig    = ((InstrumentGC_Subsystem *) interp->gc_sys)->original;
     Parrot_Interp supervisor = ((InstrumentGC_Subsystem *) interp->gc_sys)->supervisor;
-    GC_Subsystem *gc_orig;
+
     PMC *event_data;
     PMC *temp;
     PMC *params = Parrot_pmc_new(supervisor, enum_class_ResizablePMCArray);
 
-    GETATTR_InstrumentGC_gc_original(supervisor, instr_gc, gc_orig);
+
     gc_orig->block_sweep(interp);
 
 
@@ -1273,14 +1635,14 @@
 }
 
 void  stub_unblock_sweep(Parrot_Interp interp) {
-    PMC *instr_gc            = ((InstrumentGC_Subsystem *) interp->gc_sys)->instrument_gc;
+    GC_Subsystem *gc_orig    = ((InstrumentGC_Subsystem *) interp->gc_sys)->original;
     Parrot_Interp supervisor = ((InstrumentGC_Subsystem *) interp->gc_sys)->supervisor;
-    GC_Subsystem *gc_orig;
+
     PMC *event_data;
     PMC *temp;
     PMC *params = Parrot_pmc_new(supervisor, enum_class_ResizablePMCArray);
 
-    GETATTR_InstrumentGC_gc_original(supervisor, instr_gc, gc_orig);
+
     gc_orig->unblock_sweep(interp);
 
 
@@ -1297,342 +1659,9 @@
     return;
 }
 
-
 /* END gc stubs */
 
-/*
- * Helper functions
- */
-
-/*
- * raise_gc_event: Creates a Task of subtype Instrument::Event::GC::<*>
- *                 and sets its data to the given data, adding file,
- *                 sub, namespace and line information to the data hash.
- */
-
-void raise_gc_event(PARROT_INTERP, Parrot_Interp supervised, STRING *group, PMC *data) {
-    PMC *task, *task_hash, *event;
-    STRING *event_str;
-    Parrot_Context_info info;
-    event_str = VTABLE_get_string_keyed_str(interp, data, CONST_STRING(interp, "type"));
-
-    event = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
-    VTABLE_push_string(interp, event, CONST_STRING(interp, "GC"));
-    VTABLE_push_string(interp, event, group);
-    VTABLE_push_string(interp, event, event_str);
-
-    Parrot_Context_get_info(interp, CURRENT_CONTEXT(supervised), &info);
-    VTABLE_set_string_keyed_str(interp,  data, CONST_STRING(interp, "file"),      info.file);
-    VTABLE_set_string_keyed_str(interp,  data, CONST_STRING(interp, "sub"),       info.subname);
-    VTABLE_set_string_keyed_str(interp,  data, CONST_STRING(interp, "namespace"), info.nsname);
-    VTABLE_set_integer_keyed_str(interp, data, CONST_STRING(interp, "line"),      info.line);
-    VTABLE_set_pmc_keyed_str(interp, data, CONST_STRING(interp, "event"), event);
-
-    task_hash = Parrot_pmc_new(interp, enum_class_Hash);
-    VTABLE_set_string_keyed_str(interp, task_hash,
-                                CONST_STRING(interp, "type"),
-                                CONST_STRING(interp, "event"));
-    VTABLE_set_string_keyed_str(interp, task_hash,
-                                CONST_STRING(interp, "subtype"),
-                                CONST_STRING(interp, "Instrument"));
-    VTABLE_set_pmc_keyed_str(interp, task_hash, CONST_STRING(interp, "data"), data);
-
-    task = Parrot_pmc_new_init(interp, enum_class_Task, task_hash);
-    Parrot_cx_schedule_task(interp, task);
-}
-
-/*
- * build_gc_func_hash: Insert the appropriate values into the given 3 hashes.
- *                     1. instr_hash: name => stub function.
- *                     2. orig_hash : name => original gc function.
- *                     3. entry_hash: name => pointer address in InstrumentGC_Subsystem.
- */
-
-void build_gc_func_hash(PARROT_INTERP,
-                        Hash *instr_hash, Hash *orig_hash, Hash *entry_hash,
-                        InstrumentGC_Subsystem *gc_instr, GC_Subsystem *gc_orig) {
-    /* BEGIN gc mappings */
-    /* Build the pointer hash to the stubs. */
-        parrot_hash_put(interp, instr_hash,
-        CONST_STRING(interp, "finalize_gc_system"),
-        stub_finalize_gc_system);
-     parrot_hash_put(interp, instr_hash,
-        CONST_STRING(interp, "destroy_child_interp"),
-        stub_destroy_child_interp);
-     parrot_hash_put(interp, instr_hash,
-        CONST_STRING(interp, "do_gc_mark"),
-        stub_do_gc_mark);
-     parrot_hash_put(interp, instr_hash,
-        CONST_STRING(interp, "compact_string_pool"),
-        stub_compact_string_pool);
-     parrot_hash_put(interp, instr_hash,
-        CONST_STRING(interp, "mark_special"),
-        stub_mark_special);
-     parrot_hash_put(interp, instr_hash,
-        CONST_STRING(interp, "pmc_needs_early_collection"),
-        stub_pmc_needs_early_collection);
-     parrot_hash_put(interp, instr_hash,
-        CONST_STRING(interp, "init_pool"),
-        stub_init_pool);
-     parrot_hash_put(interp, instr_hash,
-        CONST_STRING(interp, "allocate_pmc_header"),
-        stub_allocate_pmc_header);
-     parrot_hash_put(interp, instr_hash,
-        CONST_STRING(interp, "free_pmc_header"),
-        stub_free_pmc_header);
-     parrot_hash_put(interp, instr_hash,
-        CONST_STRING(interp, "allocate_string_header"),
-        stub_allocate_string_header);
-     parrot_hash_put(interp, instr_hash,
-        CONST_STRING(interp, "free_string_header"),
-        stub_free_string_header);
-     parrot_hash_put(interp, instr_hash,
-        CONST_STRING(interp, "allocate_bufferlike_header"),
-        stub_allocate_bufferlike_header);
-     parrot_hash_put(interp, instr_hash,
-        CONST_STRING(interp, "free_bufferlike_header"),
-        stub_free_bufferlike_header);
-     parrot_hash_put(interp, instr_hash,
-        CONST_STRING(interp, "allocate_pmc_attributes"),
-        stub_allocate_pmc_attributes);
-     parrot_hash_put(interp, instr_hash,
-        CONST_STRING(interp, "free_pmc_attributes"),
-        stub_free_pmc_attributes);
-     parrot_hash_put(interp, instr_hash,
-        CONST_STRING(interp, "allocate_string_storage"),
-        stub_allocate_string_storage);
-     parrot_hash_put(interp, instr_hash,
-        CONST_STRING(interp, "reallocate_string_storage"),
-        stub_reallocate_string_storage);
-     parrot_hash_put(interp, instr_hash,
-        CONST_STRING(interp, "allocate_buffer_storage"),
-        stub_allocate_buffer_storage);
-     parrot_hash_put(interp, instr_hash,
-        CONST_STRING(interp, "reallocate_buffer_storage"),
-        stub_reallocate_buffer_storage);
-     parrot_hash_put(interp, instr_hash,
-        CONST_STRING(interp, "allocate_fixed_size_storage"),
-        stub_allocate_fixed_size_storage);
-     parrot_hash_put(interp, instr_hash,
-        CONST_STRING(interp, "free_fixed_size_storage"),
-        stub_free_fixed_size_storage);
-     parrot_hash_put(interp, instr_hash,
-        CONST_STRING(interp, "allocate_memory_chunk"),
-        stub_allocate_memory_chunk);
-     parrot_hash_put(interp, instr_hash,
-        CONST_STRING(interp, "reallocate_memory_chunk"),
-        stub_reallocate_memory_chunk);
-     parrot_hash_put(interp, instr_hash,
-        CONST_STRING(interp, "allocate_memory_chunk_with_interior_pointers"),
-        stub_allocate_memory_chunk_with_interior_pointers);
-     parrot_hash_put(interp, instr_hash,
-        CONST_STRING(interp, "reallocate_memory_chunk_with_interior_pointers"),
-        stub_reallocate_memory_chunk_with_interior_pointers);
-     parrot_hash_put(interp, instr_hash,
-        CONST_STRING(interp, "free_memory_chunk"),
-        stub_free_memory_chunk);
-     parrot_hash_put(interp, instr_hash,
-        CONST_STRING(interp, "block_mark"),
-        stub_block_mark);
-     parrot_hash_put(interp, instr_hash,
-        CONST_STRING(interp, "unblock_mark"),
-        stub_unblock_mark);
-     parrot_hash_put(interp, instr_hash,
-        CONST_STRING(interp, "block_sweep"),
-        stub_block_sweep);
-     parrot_hash_put(interp, instr_hash,
-        CONST_STRING(interp, "unblock_sweep"),
-        stub_unblock_sweep);
-
-
-    /* Build the pointer hash to the original. */
-        parrot_hash_put(interp, orig_hash,
-        CONST_STRING(interp, "finalize_gc_system"),
-        gc_orig->finalize_gc_system);
-     parrot_hash_put(interp, orig_hash,
-        CONST_STRING(interp, "destroy_child_interp"),
-        gc_orig->destroy_child_interp);
-     parrot_hash_put(interp, orig_hash,
-        CONST_STRING(interp, "do_gc_mark"),
-        gc_orig->do_gc_mark);
-     parrot_hash_put(interp, orig_hash,
-        CONST_STRING(interp, "compact_string_pool"),
-        gc_orig->compact_string_pool);
-     parrot_hash_put(interp, orig_hash,
-        CONST_STRING(interp, "mark_special"),
-        gc_orig->mark_special);
-     parrot_hash_put(interp, orig_hash,
-        CONST_STRING(interp, "pmc_needs_early_collection"),
-        gc_orig->pmc_needs_early_collection);
-     parrot_hash_put(interp, orig_hash,
-        CONST_STRING(interp, "init_pool"),
-        gc_orig->init_pool);
-     parrot_hash_put(interp, orig_hash,
-        CONST_STRING(interp, "allocate_pmc_header"),
-        gc_orig->allocate_pmc_header);
-     parrot_hash_put(interp, orig_hash,
-        CONST_STRING(interp, "free_pmc_header"),
-        gc_orig->free_pmc_header);
-     parrot_hash_put(interp, orig_hash,
-        CONST_STRING(interp, "allocate_string_header"),
-        gc_orig->allocate_string_header);
-     parrot_hash_put(interp, orig_hash,
-        CONST_STRING(interp, "free_string_header"),
-        gc_orig->free_string_header);
-     parrot_hash_put(interp, orig_hash,
-        CONST_STRING(interp, "allocate_bufferlike_header"),
-        gc_orig->allocate_bufferlike_header);
-     parrot_hash_put(interp, orig_hash,
-        CONST_STRING(interp, "free_bufferlike_header"),
-        gc_orig->free_bufferlike_header);
-     parrot_hash_put(interp, orig_hash,
-        CONST_STRING(interp, "allocate_pmc_attributes"),
-        gc_orig->allocate_pmc_attributes);
-     parrot_hash_put(interp, orig_hash,
-        CONST_STRING(interp, "free_pmc_attributes"),
-        gc_orig->free_pmc_attributes);
-     parrot_hash_put(interp, orig_hash,
-        CONST_STRING(interp, "allocate_string_storage"),
-        gc_orig->allocate_string_storage);
-     parrot_hash_put(interp, orig_hash,
-        CONST_STRING(interp, "reallocate_string_storage"),
-        gc_orig->reallocate_string_storage);
-     parrot_hash_put(interp, orig_hash,
-        CONST_STRING(interp, "allocate_buffer_storage"),
-        gc_orig->allocate_buffer_storage);
-     parrot_hash_put(interp, orig_hash,
-        CONST_STRING(interp, "reallocate_buffer_storage"),
-        gc_orig->reallocate_buffer_storage);
-     parrot_hash_put(interp, orig_hash,
-        CONST_STRING(interp, "allocate_fixed_size_storage"),
-        gc_orig->allocate_fixed_size_storage);
-     parrot_hash_put(interp, orig_hash,
-        CONST_STRING(interp, "free_fixed_size_storage"),
-        gc_orig->free_fixed_size_storage);
-     parrot_hash_put(interp, orig_hash,
-        CONST_STRING(interp, "allocate_memory_chunk"),
-        gc_orig->allocate_memory_chunk);
-     parrot_hash_put(interp, orig_hash,
-        CONST_STRING(interp, "reallocate_memory_chunk"),
-        gc_orig->reallocate_memory_chunk);
-     parrot_hash_put(interp, orig_hash,
-        CONST_STRING(interp, "allocate_memory_chunk_with_interior_pointers"),
-        gc_orig->allocate_memory_chunk_with_interior_pointers);
-     parrot_hash_put(interp, orig_hash,
-        CONST_STRING(interp, "reallocate_memory_chunk_with_interior_pointers"),
-        gc_orig->reallocate_memory_chunk_with_interior_pointers);
-     parrot_hash_put(interp, orig_hash,
-        CONST_STRING(interp, "free_memory_chunk"),
-        gc_orig->free_memory_chunk);
-     parrot_hash_put(interp, orig_hash,
-        CONST_STRING(interp, "block_mark"),
-        gc_orig->block_mark);
-     parrot_hash_put(interp, orig_hash,
-        CONST_STRING(interp, "unblock_mark"),
-        gc_orig->unblock_mark);
-     parrot_hash_put(interp, orig_hash,
-        CONST_STRING(interp, "block_sweep"),
-        gc_orig->block_sweep);
-     parrot_hash_put(interp, orig_hash,
-        CONST_STRING(interp, "unblock_sweep"),
-        gc_orig->unblock_sweep);
-
-
-    /* Build the pointer hash for name to InstrumentGC_Subsystem entry. */
-        parrot_hash_put(interp, entry_hash,
-        CONST_STRING(interp, "finalize_gc_system"),
-        &(gc_instr->finalize_gc_system));
-     parrot_hash_put(interp, entry_hash,
-        CONST_STRING(interp, "destroy_child_interp"),
-        &(gc_instr->destroy_child_interp));
-     parrot_hash_put(interp, entry_hash,
-        CONST_STRING(interp, "do_gc_mark"),
-        &(gc_instr->do_gc_mark));
-     parrot_hash_put(interp, entry_hash,
-        CONST_STRING(interp, "compact_string_pool"),
-        &(gc_instr->compact_string_pool));
-     parrot_hash_put(interp, entry_hash,
-        CONST_STRING(interp, "mark_special"),
-        &(gc_instr->mark_special));
-     parrot_hash_put(interp, entry_hash,
-        CONST_STRING(interp, "pmc_needs_early_collection"),
-        &(gc_instr->pmc_needs_early_collection));
-     parrot_hash_put(interp, entry_hash,
-        CONST_STRING(interp, "init_pool"),
-        &(gc_instr->init_pool));
-     parrot_hash_put(interp, entry_hash,
-        CONST_STRING(interp, "allocate_pmc_header"),
-        &(gc_instr->allocate_pmc_header));
-     parrot_hash_put(interp, entry_hash,
-        CONST_STRING(interp, "free_pmc_header"),
-        &(gc_instr->free_pmc_header));
-     parrot_hash_put(interp, entry_hash,
-        CONST_STRING(interp, "allocate_string_header"),
-        &(gc_instr->allocate_string_header));
-     parrot_hash_put(interp, entry_hash,
-        CONST_STRING(interp, "free_string_header"),
-        &(gc_instr->free_string_header));
-     parrot_hash_put(interp, entry_hash,
-        CONST_STRING(interp, "allocate_bufferlike_header"),
-        &(gc_instr->allocate_bufferlike_header));
-     parrot_hash_put(interp, entry_hash,
-        CONST_STRING(interp, "free_bufferlike_header"),
-        &(gc_instr->free_bufferlike_header));
-     parrot_hash_put(interp, entry_hash,
-        CONST_STRING(interp, "allocate_pmc_attributes"),
-        &(gc_instr->allocate_pmc_attributes));
-     parrot_hash_put(interp, entry_hash,
-        CONST_STRING(interp, "free_pmc_attributes"),
-        &(gc_instr->free_pmc_attributes));
-     parrot_hash_put(interp, entry_hash,
-        CONST_STRING(interp, "allocate_string_storage"),
-        &(gc_instr->allocate_string_storage));
-     parrot_hash_put(interp, entry_hash,
-        CONST_STRING(interp, "reallocate_string_storage"),
-        &(gc_instr->reallocate_string_storage));
-     parrot_hash_put(interp, entry_hash,
-        CONST_STRING(interp, "allocate_buffer_storage"),
-        &(gc_instr->allocate_buffer_storage));
-     parrot_hash_put(interp, entry_hash,
-        CONST_STRING(interp, "reallocate_buffer_storage"),
-        &(gc_instr->reallocate_buffer_storage));
-     parrot_hash_put(interp, entry_hash,
-        CONST_STRING(interp, "allocate_fixed_size_storage"),
-        &(gc_instr->allocate_fixed_size_storage));
-     parrot_hash_put(interp, entry_hash,
-        CONST_STRING(interp, "free_fixed_size_storage"),
-        &(gc_instr->free_fixed_size_storage));
-     parrot_hash_put(interp, entry_hash,
-        CONST_STRING(interp, "allocate_memory_chunk"),
-        &(gc_instr->allocate_memory_chunk));
-     parrot_hash_put(interp, entry_hash,
-        CONST_STRING(interp, "reallocate_memory_chunk"),
-        &(gc_instr->reallocate_memory_chunk));
-     parrot_hash_put(interp, entry_hash,
-        CONST_STRING(interp, "allocate_memory_chunk_with_interior_pointers"),
-        &(gc_instr->allocate_memory_chunk_with_interior_pointers));
-     parrot_hash_put(interp, entry_hash,
-        CONST_STRING(interp, "reallocate_memory_chunk_with_interior_pointers"),
-        &(gc_instr->reallocate_memory_chunk_with_interior_pointers));
-     parrot_hash_put(interp, entry_hash,
-        CONST_STRING(interp, "free_memory_chunk"),
-        &(gc_instr->free_memory_chunk));
-     parrot_hash_put(interp, entry_hash,
-        CONST_STRING(interp, "block_mark"),
-        &(gc_instr->block_mark));
-     parrot_hash_put(interp, entry_hash,
-        CONST_STRING(interp, "unblock_mark"),
-        &(gc_instr->unblock_mark));
-     parrot_hash_put(interp, entry_hash,
-        CONST_STRING(interp, "block_sweep"),
-        &(gc_instr->block_sweep));
-     parrot_hash_put(interp, entry_hash,
-        CONST_STRING(interp, "unblock_sweep"),
-        &(gc_instr->unblock_sweep));
-
-
-    /* END gc mappings */
-}
+/* END OF GENERATED CODE */
 
 /*
  * Local variables:

Added: branches/gsoc_instrument/src/dynpmc/instrumentstubbase.pmc
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ branches/gsoc_instrument/src/dynpmc/instrumentstubbase.pmc	Mon Jul 12 15:32:45 2010	(r48075)
@@ -0,0 +1,219 @@
+/*
+Copyright (C) 2010, Parrot Foundation.
+$Id: instrumentgc.pmc 48073 2010-07-11 16:47:36Z khairul $
+
+=head1 NAME
+
+src/dynpmc/instrumentgc.pmc - Interface to instrument the gc_sys entry of Parrot_Interp.
+
+=head1 DESCRIPTION
+
+C<InstrumentPMC> is a PMC class that provides an interface to
+instrument the gc_sys entry of Parrot_Interp.
+
+=head2 Methods
+
+=over 4
+
+=cut
+
+*/
+
+#include "parrot/parrot.h"
+
+pmclass InstrumentStubBase auto_attrs dynpmc group instrument_group {
+    ATTR PMC  *instrument;          /* Reference to the Instrument object, for various purposes. */
+    ATTR PMC  *hook_count;          /* Keeps track of hook requests for a particular entry. */
+    ATTR Hash *name_stubs;          /* Mapping item name with the corresponding stub entry. */
+    ATTR Hash *name_original;       /* Mapping item name with the original item entry. */
+    ATTR Hash *name_offset;         /* Mapping item name with the pointer address in the struct. */
+    ATTR Hash *group_items;         /* Mapping groups with the items that belongs in it. */
+    ATTR Hash *item_groups;         /* Mapping item name to the groups it belongs to. */
+    ATTR Hash *registry;            /* Used by stubs to locate the instrumenting PMC. */
+    ATTR void *original_struct;     /* Reference to the original struct. */
+    ATTR void *instrumented_struct; /* Reference to the struct with stubs inserted. */
+
+    VTABLE void init() {
+        /* Not supposed to be init on its own. */
+        Parrot_ex_throw_from_c_args(INTERP, NULL, 1,
+                                    "%Ss should be instantiated with initpmc instead.",
+                                   VTABLE_name(INTERP, SELF));
+    }
+
+    VTABLE void init_pmc(PMC *instrument) {
+        Parrot_InstrumentStubBase_attributes * const attr = PARROT_INSTRUMENTSTUBBASE(SELF);
+
+        /* Initialise the common attributes, setting the others to NULL. */
+        attr->instrument          = instrument;
+        attr->hook_count          = Parrot_pmc_new(INTERP, enum_class_Hash);
+        attr->name_stubs          = NULL;
+        attr->name_original       = parrot_new_hash(INTERP);
+        attr->name_offset         = parrot_new_hash(INTERP);
+        attr->group_items         = NULL;
+        attr->item_groups         = NULL;
+        attr->original_struct     = NULL;
+        attr->instrumented_struct = NULL;
+
+        /* Set custom mark and destroy. */
+        PObj_custom_mark_destroy_SETALL(SELF);
+    }
+
+    VTABLE void mark() {
+        Parrot_InstrumentStubBase_attributes * const attr = PARROT_INSTRUMENTSTUBBASE(SELF);
+
+        Parrot_gc_mark_PMC_alive_fun(INTERP, attr->hook_count);
+    }
+
+    VTABLE void destroy() {
+        Parrot_InstrumentStubBase_attributes * const attr = PARROT_INSTRUMENTSTUBBASE(SELF);
+
+        /* Destroy the hashes, except for the following:
+           1. registry
+           2. name_stub
+           3. group_items
+           4. item_groups
+           These hashes are handled by the child class. */
+        parrot_hash_destroy(INTERP, attr->name_original);
+        parrot_hash_destroy(INTERP, attr->name_offset);
+
+        /* Free the original struct. The instrumented struct will be freed when
+           the object is destroyed. */
+        mem_gc_free(INTERP, attr->original_struct);
+    }
+
+    METHOD insert_hook(STRING *name) {
+        Parrot_InstrumentStubBase_attributes * const attr = PARROT_INSTRUMENTSTUBBASE(SELF);
+        PMC *list;
+        PMC *iter;
+        (PMC *list) = PCCINVOKE(INTERP, SELF, "get_hook_list", STRING *name);
+
+        iter = VTABLE_get_iter(INTERP, list);
+        while (VTABLE_get_bool(INTERP, iter)) {
+            INTVAL count;
+            PMC *item_pmc = VTABLE_shift_pmc(INTERP, iter);
+            STRING *item  = VTABLE_get_string(INTERP, item_pmc);
+            size_t **entry, *func;
+
+            /* Check if the entry has already been instrumented. */
+            count = VTABLE_get_integer_keyed_str(INTERP, attr->hook_count, item);
+            if (count == 0) {
+                /* Replace the entry with the stub. */
+                entry = (size_t **) parrot_hash_get(INTERP, attr->name_offset, item);
+                func  = (size_t *)  parrot_hash_get(INTERP, attr->name_stubs, item);
+                if (entry == NULL || func == NULL) {
+                    Parrot_ex_throw_from_c_args(INTERP, NULL, 1,
+                                                "%Ss : Unknown function, '%Ss'",
+                                                VTABLE_name(INTERP, SELF), item);
+                }
+                *entry = func;
+            }
+
+            /* Update the count. */
+            count++;
+            VTABLE_set_integer_keyed_str(INTERP, attr->hook_count, item, count);
+        }
+    }
+
+    METHOD remove_hook(STRING *name) {
+        Parrot_InstrumentStubBase_attributes * const attr = PARROT_INSTRUMENTSTUBBASE(SELF);
+        PMC *list;
+        PMC *iter;
+        (PMC *list) = PCCINVOKE(INTERP, SELF, "get_hook_list", STRING *name);
+
+        iter = VTABLE_get_iter(INTERP, list);
+        while (VTABLE_get_bool(INTERP, iter)) {
+            INTVAL count;
+            PMC *item_pmc = VTABLE_shift_pmc(INTERP, iter);
+            STRING *item  = VTABLE_get_string(INTERP, item_pmc);
+            size_t **entry, *func;
+
+            /* Only remove the stub if request count == 1 => Last request. */
+            count = VTABLE_get_integer_keyed_str(INTERP, attr->hook_count, item);
+            if (count <= 0) {
+                /* Tried to remove 1 time too many. */
+                Parrot_ex_throw_from_c_args(INTERP, NULL, 1,
+                                                "%Ss : Unknown function, '%Ss'",
+                                                VTABLE_name(INTERP, SELF), item);
+            }
+            else if (count == 1) {
+                /* Simply replace the stub with the original entry. */
+                entry = (size_t **) parrot_hash_get(INTERP, attr->name_offset, item);
+                func  = (size_t *)  parrot_hash_get(INTERP, attr->name_original, item);
+                if (entry == NULL || func == NULL) {
+                    Parrot_ex_throw_from_c_args(INTERP, NULL, 1,
+                                                "%Ss : Unknown function, '%Ss'",
+                                                VTABLE_name(INTERP, SELF), item);
+                }
+                *entry = func;
+            }
+
+            /* Update the count. */
+            count--;
+            VTABLE_set_integer_keyed_str(INTERP, attr->hook_count, item, count);
+        }
+    }
+
+    METHOD get_hook_list(STRING *name) {
+        Parrot_InstrumentStubBase_attributes * const attr = PARROT_INSTRUMENTSTUBBASE(SELF);
+        PMC *list;
+
+        list = (PMC *) parrot_hash_get(INTERP, attr->group_items, name);
+        if (PMC_IS_NULL(list)) {
+            /* Assume that name is a specific item. Ensure that it refers
+               to a stub name before pushing it into list. */
+            size_t *check;
+
+            check = (size_t *) parrot_hash_get(INTERP, attr->name_stubs, name);
+            if (check == NULL) {
+                Parrot_ex_throw_from_c_args(INTERP, NULL, 1,
+                                                "%Ss : Unknown function, '%Ss'",
+                                                VTABLE_name(INTERP, SELF), name);
+            }
+
+            list = Parrot_pmc_new(INTERP, enum_class_ResizableStringArray);
+            VTABLE_push_string(INTERP, list, name);
+        }
+
+        RETURN(PMC *list);
+    }
+
+    METHOD get_hook_group(STRING *name) {
+        Parrot_InstrumentStubBase_attributes * const attr = PARROT_INSTRUMENTSTUBBASE(SELF);
+        PMC *groups;
+
+        groups = (PMC *) parrot_hash_get(INTERP, attr->item_groups, name);
+        if(PMC_IS_NULL(groups)) {
+            /* Should not happen. All items should have a group mapping. */
+            Parrot_ex_throw_from_c_args(INTERP, NULL, 1,
+                                        "%Ss : Unknown function, '%Ss'",
+                                        VTABLE_name(INTERP, SELF), name);
+        }
+
+        RETURN(PMC *groups);
+    }
+
+    METHOD get_instrumented_list() {
+        Parrot_InstrumentStubBase_attributes * const attr = PARROT_INSTRUMENTSTUBBASE(SELF);
+        PMC *ret = Parrot_pmc_new(INTERP, enum_class_ResizableStringArray);
+        PMC *iter;
+
+        iter = VTABLE_get_iter(INTERP, attr->hook_count);
+
+        while (VTABLE_get_bool(INTERP, iter)) {
+            PMC *key     = VTABLE_shift_pmc(INTERP, iter);
+            INTVAL count = VTABLE_get_integer_keyed(INTERP, attr->hook_count, key);
+            if (count > 0) {
+                VTABLE_push_pmc(INTERP, ret, key);
+            }
+        }
+
+        RETURN(PMC *ret);
+    }
+}
+
+/*
+ * Local Variables:
+ *   c-file-style: "parrot"
+ * End:
+ * vim: expandtab shiftwidth=4:
+ */

Modified: branches/gsoc_instrument/src/dynpmc/instrumentvtable.pmc
==============================================================================
--- branches/gsoc_instrument/src/dynpmc/instrumentvtable.pmc	Sun Jul 11 20:42:32 2010	(r48074)
+++ branches/gsoc_instrument/src/dynpmc/instrumentvtable.pmc	Mon Jul 12 15:32:45 2010	(r48075)
@@ -23,6 +23,120 @@
 
 #include "pmc_instrument.h"
 
+/* Helper Prototypes. */
+void raise_vtable_event(PARROT_INTERP, Parrot_Interp supervised, PMC *pmc,
+                        PMC *data, STRING *group, STRING *type);
+void setup_vtable_common_hashes(PARROT_INTERP);
+void destroy_vtable_common_hashes(PARROT_INTERP);
+void setup_vtable_individual_hashes(PARROT_INTERP, Hash *orig_hash, Hash *instr_hash,
+                                    _vtable *vt_orig, _vtable *vt_instr);
+
+/* Globals used internally. */
+static INTVAL  vtable_first_run   = 1;
+static Hash   *vtable_registry    = NULL;
+static Hash   *vtable_name_stubs  = NULL;
+static Hash   *vtable_group_items = NULL;
+static Hash   *vtable_item_groups = NULL;
+
+pmclass InstrumentVtable auto_attrs dynpmc group instrument_group extends InstrumentStubBase {
+    ATTR size_t        class_index;
+    ATTR Parrot_Interp supervisor;
+
+    VTABLE void init_pmc(PMC *instrument) {
+        Parrot_InstrumentVtable_attributes * const attr = PARROT_INSTRUMENTVTABLE(SELF);
+        SUPER(instrument);
+
+        /* Initialise the attributes.
+           Other attributes are deferred to after attaching to a class. */
+        attr->supervisor = INTERP;
+
+        /* Initialise the static hashes. */
+        setup_vtable_common_hashes(INTERP);
+
+        /* Update the attributes to point to the static hashes. */
+        attr->name_stubs  = vtable_name_stubs;
+        attr->group_items = vtable_group_items;
+        attr->item_groups = vtable_item_groups;
+    }
+
+    VTABLE void destroy() {
+        Parrot_InstrumentVtable_attributes * const attr = PARROT_INSTRUMENTVTABLE(SELF);
+        SUPER();
+        parrot_hash_delete(INTERP, vtable_registry, attr->instrumented_struct);
+        destroy_vtable_common_hashes(INTERP);
+    }
+
+    METHOD attach_to_class(STRING *classname) {
+        Parrot_InstrumentVtable_attributes * const attr = PARROT_INSTRUMENTVTABLE(SELF);
+        Parrot_Interp supervised;
+
+        GETATTR_Instrument_supervised(INTERP, attr->instrument, supervised);
+
+        /* Find the class. */
+        attr->class_index     = Parrot_pmc_get_type_str(supervised, classname);
+        attr->original_struct = supervised->vtables[attr->class_index];
+
+        /* Prepare the class's vtable for instrumentation. */
+        attr->instrumented_struct = mem_gc_allocate_zeroed_typed(supervised, _vtable);
+        mem_copy_n_typed(attr->instrumented_struct, attr->original_struct, 1, _vtable);
+        supervised->vtables[attr->class_index] = (_vtable *) attr->instrumented_struct;
+
+        /* Register the instrumented vtable to SELF. */
+        parrot_hash_put(INTERP, vtable_registry, attr->instrumented_struct, SELF);
+
+        /* Build the vtable hashes, passing a sample vtable to build the offsets. */
+        setup_vtable_individual_hashes(INTERP, attr->name_original, attr->name_offset,
+                                       (_vtable *) attr->original_struct,
+                                       (_vtable *) attr->instrumented_struct);
+    }
+}
+
+/*
+ * Helpers
+ */
+
+void raise_vtable_event(PARROT_INTERP, Parrot_Interp supervised,
+                        PMC *pmc, PMC *data, STRING *group, STRING *type) {
+    Parrot_Context_info info;
+    PMC *task_hash, *task;
+    PMC *event_arr;
+
+    /* Get the current context info. */
+    Parrot_Context_get_info(interp, CURRENT_CONTEXT(supervised), &info);
+
+    /* Set the event type. */
+    event_arr = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, event_arr, CONST_STRING(interp, "Class"));
+    VTABLE_push_string(interp, event_arr, VTABLE_name(supervised, pmc));
+    VTABLE_push_string(interp, event_arr, CONST_STRING(interp, "vtable"));
+    VTABLE_push_string(interp, event_arr, group);
+    VTABLE_push_string(interp, event_arr, type);
+
+    /* Populate data with common items. */
+    VTABLE_set_pmc_keyed_str(interp, data,
+                                CONST_STRING(interp, "event"),
+                                event_arr);
+    VTABLE_set_string_keyed_str(interp,  data, CONST_STRING(interp, "file"),      info.file);
+    VTABLE_set_string_keyed_str(interp,  data, CONST_STRING(interp, "sub"),       info.subname);
+    VTABLE_set_string_keyed_str(interp,  data, CONST_STRING(interp, "namespace"), info.nsname);
+    VTABLE_set_integer_keyed_str(interp, data, CONST_STRING(interp, "line"),      info.line);
+
+    /* Raise the event. */
+    task_hash = Parrot_pmc_new(interp, enum_class_Hash);
+    VTABLE_set_string_keyed_str(interp, task_hash,
+                                CONST_STRING(interp, "type"),
+                                CONST_STRING(interp, "event"));
+    VTABLE_set_string_keyed_str(interp, task_hash,
+                                CONST_STRING(interp, "subtype"),
+                                CONST_STRING(interp, "Instrument"));
+    VTABLE_set_pmc_keyed_str(interp, task_hash, CONST_STRING(interp, "data"), data);
+
+    task = Parrot_pmc_new_init(interp, enum_class_Task, task_hash);
+    Parrot_cx_schedule_task(interp, task);
+}
+
+
+/* BELOW LIES GENERATED CODE GENERATED BY tools/build/gen_vtable_stubs.pl */
 /* Stub Prototypes */
 /* BEGIN vtable prototypes */
 static void stub_init_pmc(PARROT_INTERP, PMC* pmc, PMC* initializer);
@@ -175,1530 +289,2954 @@
 static void stub_thawfinish(PARROT_INTERP, PMC* pmc, PMC* info);
 static void stub_visit(PARROT_INTERP, PMC* pmc, PMC* info);
 static void stub_init_int(PARROT_INTERP, PMC* pmc, INTVAL initializer);
-
 /* END vtable prototypes */
 
-/* Helper Prototypes. */
-void raise_vtable_event(PARROT_INTERP, Parrot_Interp supervised, PMC *pmc,
-                        PMC *data, STRING *group, STRING *type);
-void build_vtable_hashes(PARROT_INTERP, Hash *orig, Hash *instr, Hash *stub,
-                         _vtable *vtable, _vtable *instr_vtable);
-
-/* Test */
-static Hash *Instrument_Vtable_Entries = NULL;
-static Hash *Instrument_Vtable_Stubs   = NULL;
-
-pmclass InstrumentVtable auto_attrs dynpmc group instrument_group {
-    ATTR Parrot_Interp   supervisor;
-    ATTR PMC            *instrument;
-    ATTR INTVAL          class_index;
-    ATTR struct _vtable *original_vtable;
-    ATTR struct _vtable *instrumented_vtable;
-    ATTR Hash           *original_hash;
-    ATTR Hash           *instrumented_hash;
-
-    VTABLE void init() {
-        /* Not supposed to be init on its own. */
-        Parrot_ex_throw_from_c_args(INTERP, NULL, 1,
-                                   "InstrumentVtable should be instantiated with initpmc instead.");
-    }
-
-    VTABLE void init_pmc(PMC *instrument) {
-        Parrot_InstrumentVtable_attributes * const attr = PARROT_INSTRUMENTVTABLE(SELF);
-
-        attr->supervisor          = INTERP;
-        attr->instrument          = instrument;
-        attr->original_vtable     = NULL;
-        attr->instrumented_vtable = NULL;
-        attr->original_hash        = parrot_new_hash(INTERP);
-        attr->instrumented_hash   = parrot_new_hash(INTERP);
-
-        /* Initialise the Instrumented Vtable registry if needed. */
-        if (Instrument_Vtable_Entries == NULL) {
-            Instrument_Vtable_Entries = parrot_new_hash(INTERP);
-            Instrument_Vtable_Stubs   = parrot_new_hash(INTERP);
-        }
-
-        PObj_custom_destroy_SET(SELF);
-    }
-
-    VTABLE void destroy() {
-        Parrot_InstrumentVtable_attributes * const attr = PARROT_INSTRUMENTVTABLE(SELF);
-
-        /* Remove entry from Instrument_Vtable_Entries. */
-        parrot_hash_delete(INTERP, Instrument_Vtable_Entries, attr->instrumented_vtable);
-
-        /* Delete the hash if the size is 0. */
-        if (parrot_hash_size(INTERP, Instrument_Vtable_Entries) == 0) {
-            parrot_hash_destroy(INTERP, Instrument_Vtable_Entries);
-            parrot_hash_destroy(INTERP, Instrument_Vtable_Stubs);
-            Instrument_Vtable_Entries = NULL;
-            Instrument_Vtable_Stubs   = NULL;
-        }
-    }
-
-    METHOD attach_to_class(STRING *classname) {
-        Parrot_InstrumentVtable_attributes * const attr = PARROT_INSTRUMENTVTABLE(SELF);
-        Parrot_Interp supervised;
-
-        GETATTR_Instrument_supervised(INTERP, attr->instrument, supervised);
-
-        attr->class_index     = Parrot_pmc_get_type_str(supervised, classname);
-        attr->original_vtable = supervised->vtables[attr->class_index];
-
-        /* Prepare the class's vtable for instrumentation. */
-        attr->instrumented_vtable = mem_gc_allocate_zeroed_typed(supervised, _vtable);
-        mem_copy_n_typed(attr->instrumented_vtable, attr->original_vtable, 1, _vtable);
-        supervised->vtables[attr->class_index] = attr->instrumented_vtable;
-
-        /* Register the instrumented vtable to SELF. */
-        parrot_hash_put(INTERP, Instrument_Vtable_Entries, attr->instrumented_vtable, SELF);
-
-        /* Build the vtable hashes, passing a sample vtable to build the offsets. */
-        build_vtable_hashes(INTERP,
-                            attr->original_hash, attr->instrumented_hash,
-                            Instrument_Vtable_Stubs,
-                            attr->original_vtable, attr->instrumented_vtable);
-    }
-
-    METHOD insert_vtable_hook(STRING *key) {
-        Parrot_InstrumentVtable_attributes * const attr = PARROT_INSTRUMENTVTABLE(SELF);
-        char *con_string;
-        size_t **instr, *stub;
-
-        /* Modify the entry. */
-        instr  = (size_t **) parrot_hash_get(INTERP, attr->instrumented_hash, key);
-        stub   = (size_t *)  parrot_hash_get(INTERP, Instrument_Vtable_Stubs, key);
-        if (instr == NULL || stub ==  NULL) {
-            Parrot_ex_throw_from_c_args(INTERP, NULL, 1,
-                                        "Unknown VTABLE entry: %Ss", key);
-        }
-        *instr = stub;
-    }
-
-    METHOD remove_vtable_hook(STRING *key) {
-        Parrot_InstrumentVtable_attributes * const attr = PARROT_INSTRUMENTVTABLE(SELF);
-        char *con_string;
-        size_t **instr, *orig;
-
-        /* Modify the entry. */
-        instr  = (size_t **) parrot_hash_get(INTERP, attr->instrumented_hash, key);
-        orig   = (size_t *)  parrot_hash_get(INTERP, attr->original_hash, key);
-        if (instr == NULL || orig ==  NULL) {
-            Parrot_ex_throw_from_c_args(INTERP, NULL, 1,
-                                        "Unknown VTABLE entry: %Ss", key);
-        }
-        *instr = orig;
-    }
-
-/*
-
-=item C<PMC* get_hook_list(STRING *name)>
-
-Returns a ResizableStringArray PMC filled with
-the names of the gc entries to instrument.
-
-=cut
-
-*/
-
-    METHOD get_hook_list(STRING *name) {
-        PMC *list;
-
-        list = Parrot_pmc_new(INTERP, enum_class_ResizableStringArray);
-
-        /* BEGIN vtable groupings */
-        if (Parrot_str_equal(INTERP, name, CONST_STRING(INTERP, "exists"))) {
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "exists_keyed"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "exists_keyed_int"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "exists_keyed_str"));
-        }
-        else if (Parrot_str_equal(INTERP, name, CONST_STRING(INTERP, "fetch"))) {
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "get_integer_keyed"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "get_integer_keyed_int"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "get_integer_keyed_str"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "get_number_keyed"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "get_number_keyed_int"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "get_number_keyed_str"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "get_string_keyed"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "get_string_keyed_int"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "get_string_keyed_str"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "get_pmc_keyed"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "get_pmc_keyed_int"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "get_pmc_keyed_str"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "get_pointer_keyed"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "get_pointer_keyed_int"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "get_pointer_keyed_str"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "set_integer_native"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "set_integer_keyed"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "set_integer_keyed_int"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "set_integer_keyed_str"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "set_number_native"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "set_number_keyed"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "set_number_keyed_int"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "set_number_keyed_str"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "set_string_native"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "assign_string_native"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "set_string_keyed"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "set_string_keyed_int"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "set_string_keyed_str"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "set_bool"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "set_pmc"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "assign_pmc"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "set_pmc_keyed"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "set_pmc_keyed_int"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "set_pmc_keyed_str"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "set_pointer"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "set_pointer_keyed"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "set_pointer_keyed_int"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "set_pointer_keyed_str"));
-        }
-        else if (Parrot_str_equal(INTERP, name, CONST_STRING(INTERP, "string"))) {
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "concatenate"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "concatenate_str"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_concatenate"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_concatenate_str"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "repeat"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "repeat_int"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_repeat"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_repeat_int"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "substr"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "substr_str"));
-        }
-        else if (Parrot_str_equal(INTERP, name, CONST_STRING(INTERP, "math"))) {
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "add"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "add_int"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "add_float"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_add"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_add_int"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_add_float"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "subtract"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "subtract_int"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "subtract_float"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_subtract"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_subtract_int"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_subtract_float"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "multiply"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "multiply_int"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "multiply_float"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_multiply"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_multiply_int"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_multiply_float"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "divide"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "divide_int"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "divide_float"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_divide"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_divide_int"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_divide_float"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "floor_divide"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "floor_divide_int"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "floor_divide_float"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_floor_divide"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_floor_divide_int"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_floor_divide_float"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "modulus"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "modulus_int"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "modulus_float"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_modulus"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_modulus_int"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_modulus_float"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "absolute"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "neg"));
-        }
-        else if (Parrot_str_equal(INTERP, name, CONST_STRING(INTERP, "main"))) {
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "defined_keyed"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "defined_keyed_int"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "defined_keyed_str"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "delete_keyed"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "delete_keyed_int"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "delete_keyed_str"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "invoke"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "can"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "does_pmc"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "does"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "isa_pmc"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "isa"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "get_attr_str"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "get_attr_keyed"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "set_attr_str"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "set_attr_keyed"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "add_parent"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "remove_parent"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "add_role"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "remove_role"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "add_attribute"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "remove_attribute"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "add_method"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "remove_method"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "add_vtable_override"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "remove_vtable_override"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "inspect_str"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "freeze"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "thaw"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "thawfinish"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "visit"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "init_int"));
-        }
-        else if (Parrot_str_equal(INTERP, name, CONST_STRING(INTERP, "fetchsize"))) {
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "push_integer"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "push_float"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "push_string"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "push_pmc"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "unshift_integer"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "unshift_float"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "unshift_string"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "unshift_pmc"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "splice"));
-        }
-        else if (Parrot_str_equal(INTERP, name, CONST_STRING(INTERP, "cmp"))) {
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "is_equal"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "is_equal_num"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "is_equal_string"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "is_same"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "cmp"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "cmp_num"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "cmp_string"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "cmp_pmc"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "logical_or"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "logical_and"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "logical_xor"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "logical_not"));
-        }
-        else if (Parrot_str_equal(INTERP, name, CONST_STRING(INTERP, "core"))) {
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "init_pmc"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "instantiate"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "morph"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "getprop"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "setprop"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "delprop"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "clone_pmc"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "find_method"));
-        }
-        else if (Parrot_str_equal(INTERP, name, CONST_STRING(INTERP, "write"))) {
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "morph"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_add"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_add_int"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_add_float"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_subtract"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_subtract_int"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_subtract_float"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_multiply"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_multiply_int"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_multiply_float"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_divide"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_divide_int"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_divide_float"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_floor_divide"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_floor_divide_int"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_floor_divide_float"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_modulus"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_modulus_int"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_modulus_float"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_concatenate"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_concatenate_str"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_repeat"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "i_repeat_int"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "set_attr_str"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "set_attr_keyed"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "add_parent"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "remove_parent"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "add_role"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "remove_role"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "add_attribute"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "remove_attribute"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "add_method"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "remove_method"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "add_vtable_override"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "remove_vtable_override"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "thaw"));
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "thawfinish"));
-        }
-
-        /* END vtable groupings */
-        else {
-            /* Ensure that name is the name of a hook before pushing it in. */
-            size_t *check;
-            check = (size_t *) parrot_hash_get(INTERP, Instrument_Vtable_Stubs, name);
-            if (check == NULL) {
-                Parrot_ex_throw_from_c_args(INTERP, NULL, 1,
-                                            "Unknown GC function: %Ss", name);
-            }
+void setup_vtable_common_hashes(PARROT_INTERP) {
+    PMC *temp;
+    if(!vtable_first_run) return;
 
-            VTABLE_push_string(INTERP, list, name);
-        }
+    vtable_first_run   = 0;
+    vtable_registry    = parrot_new_pointer_hash(interp);
+    vtable_name_stubs  = parrot_new_hash(interp);
+    vtable_group_items = parrot_new_hash(interp);
+    vtable_item_groups = parrot_new_hash(interp);
+
+    /* BEGIN vtable mapping name stubs */
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "init_pmc"),
+        stub_init_pmc);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "instantiate"),
+        stub_instantiate);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "morph"),
+        stub_morph);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "getprop"),
+        stub_getprop);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "setprop"),
+        stub_setprop);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "delprop"),
+        stub_delprop);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "clone_pmc"),
+        stub_clone_pmc);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "find_method"),
+        stub_find_method);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "get_integer_keyed"),
+        stub_get_integer_keyed);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "get_integer_keyed_int"),
+        stub_get_integer_keyed_int);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "get_integer_keyed_str"),
+        stub_get_integer_keyed_str);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "get_number_keyed"),
+        stub_get_number_keyed);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "get_number_keyed_int"),
+        stub_get_number_keyed_int);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "get_number_keyed_str"),
+        stub_get_number_keyed_str);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "get_string_keyed"),
+        stub_get_string_keyed);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "get_string_keyed_int"),
+        stub_get_string_keyed_int);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "get_string_keyed_str"),
+        stub_get_string_keyed_str);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "get_pmc_keyed"),
+        stub_get_pmc_keyed);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "get_pmc_keyed_int"),
+        stub_get_pmc_keyed_int);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "get_pmc_keyed_str"),
+        stub_get_pmc_keyed_str);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "get_pointer_keyed"),
+        stub_get_pointer_keyed);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "get_pointer_keyed_int"),
+        stub_get_pointer_keyed_int);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "get_pointer_keyed_str"),
+        stub_get_pointer_keyed_str);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "set_integer_native"),
+        stub_set_integer_native);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "set_integer_keyed"),
+        stub_set_integer_keyed);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "set_integer_keyed_int"),
+        stub_set_integer_keyed_int);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "set_integer_keyed_str"),
+        stub_set_integer_keyed_str);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "set_number_native"),
+        stub_set_number_native);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "set_number_keyed"),
+        stub_set_number_keyed);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "set_number_keyed_int"),
+        stub_set_number_keyed_int);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "set_number_keyed_str"),
+        stub_set_number_keyed_str);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "set_string_native"),
+        stub_set_string_native);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "assign_string_native"),
+        stub_assign_string_native);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "set_string_keyed"),
+        stub_set_string_keyed);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "set_string_keyed_int"),
+        stub_set_string_keyed_int);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "set_string_keyed_str"),
+        stub_set_string_keyed_str);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "set_bool"),
+        stub_set_bool);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "set_pmc"),
+        stub_set_pmc);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "assign_pmc"),
+        stub_assign_pmc);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "set_pmc_keyed"),
+        stub_set_pmc_keyed);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "set_pmc_keyed_int"),
+        stub_set_pmc_keyed_int);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "set_pmc_keyed_str"),
+        stub_set_pmc_keyed_str);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "set_pointer"),
+        stub_set_pointer);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "set_pointer_keyed"),
+        stub_set_pointer_keyed);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "set_pointer_keyed_int"),
+        stub_set_pointer_keyed_int);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "set_pointer_keyed_str"),
+        stub_set_pointer_keyed_str);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "push_integer"),
+        stub_push_integer);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "push_float"),
+        stub_push_float);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "push_string"),
+        stub_push_string);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "push_pmc"),
+        stub_push_pmc);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "unshift_integer"),
+        stub_unshift_integer);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "unshift_float"),
+        stub_unshift_float);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "unshift_string"),
+        stub_unshift_string);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "unshift_pmc"),
+        stub_unshift_pmc);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "splice"),
+        stub_splice);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "add"),
+        stub_add);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "add_int"),
+        stub_add_int);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "add_float"),
+        stub_add_float);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "i_add"),
+        stub_i_add);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "i_add_int"),
+        stub_i_add_int);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "i_add_float"),
+        stub_i_add_float);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "subtract"),
+        stub_subtract);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "subtract_int"),
+        stub_subtract_int);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "subtract_float"),
+        stub_subtract_float);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "i_subtract"),
+        stub_i_subtract);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "i_subtract_int"),
+        stub_i_subtract_int);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "i_subtract_float"),
+        stub_i_subtract_float);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "multiply"),
+        stub_multiply);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "multiply_int"),
+        stub_multiply_int);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "multiply_float"),
+        stub_multiply_float);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "i_multiply"),
+        stub_i_multiply);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "i_multiply_int"),
+        stub_i_multiply_int);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "i_multiply_float"),
+        stub_i_multiply_float);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "divide"),
+        stub_divide);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "divide_int"),
+        stub_divide_int);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "divide_float"),
+        stub_divide_float);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "i_divide"),
+        stub_i_divide);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "i_divide_int"),
+        stub_i_divide_int);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "i_divide_float"),
+        stub_i_divide_float);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "floor_divide"),
+        stub_floor_divide);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "floor_divide_int"),
+        stub_floor_divide_int);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "floor_divide_float"),
+        stub_floor_divide_float);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "i_floor_divide"),
+        stub_i_floor_divide);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "i_floor_divide_int"),
+        stub_i_floor_divide_int);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "i_floor_divide_float"),
+        stub_i_floor_divide_float);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "modulus"),
+        stub_modulus);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "modulus_int"),
+        stub_modulus_int);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "modulus_float"),
+        stub_modulus_float);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "i_modulus"),
+        stub_i_modulus);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "i_modulus_int"),
+        stub_i_modulus_int);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "i_modulus_float"),
+        stub_i_modulus_float);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "absolute"),
+        stub_absolute);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "neg"),
+        stub_neg);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "is_equal"),
+        stub_is_equal);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "is_equal_num"),
+        stub_is_equal_num);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "is_equal_string"),
+        stub_is_equal_string);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "is_same"),
+        stub_is_same);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "cmp"),
+        stub_cmp);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "cmp_num"),
+        stub_cmp_num);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "cmp_string"),
+        stub_cmp_string);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "cmp_pmc"),
+        stub_cmp_pmc);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "logical_or"),
+        stub_logical_or);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "logical_and"),
+        stub_logical_and);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "logical_xor"),
+        stub_logical_xor);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "logical_not"),
+        stub_logical_not);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "concatenate"),
+        stub_concatenate);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "concatenate_str"),
+        stub_concatenate_str);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "i_concatenate"),
+        stub_i_concatenate);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "i_concatenate_str"),
+        stub_i_concatenate_str);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "repeat"),
+        stub_repeat);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "repeat_int"),
+        stub_repeat_int);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "i_repeat"),
+        stub_i_repeat);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "i_repeat_int"),
+        stub_i_repeat_int);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "substr"),
+        stub_substr);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "substr_str"),
+        stub_substr_str);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "exists_keyed"),
+        stub_exists_keyed);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "exists_keyed_int"),
+        stub_exists_keyed_int);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "exists_keyed_str"),
+        stub_exists_keyed_str);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "defined_keyed"),
+        stub_defined_keyed);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "defined_keyed_int"),
+        stub_defined_keyed_int);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "defined_keyed_str"),
+        stub_defined_keyed_str);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "delete_keyed"),
+        stub_delete_keyed);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "delete_keyed_int"),
+        stub_delete_keyed_int);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "delete_keyed_str"),
+        stub_delete_keyed_str);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "invoke"),
+        stub_invoke);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "can"),
+        stub_can);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "does_pmc"),
+        stub_does_pmc);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "does"),
+        stub_does);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "isa_pmc"),
+        stub_isa_pmc);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "isa"),
+        stub_isa);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "get_attr_str"),
+        stub_get_attr_str);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "get_attr_keyed"),
+        stub_get_attr_keyed);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "set_attr_str"),
+        stub_set_attr_str);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "set_attr_keyed"),
+        stub_set_attr_keyed);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "add_parent"),
+        stub_add_parent);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "remove_parent"),
+        stub_remove_parent);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "add_role"),
+        stub_add_role);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "remove_role"),
+        stub_remove_role);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "add_attribute"),
+        stub_add_attribute);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "remove_attribute"),
+        stub_remove_attribute);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "add_method"),
+        stub_add_method);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "remove_method"),
+        stub_remove_method);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "add_vtable_override"),
+        stub_add_vtable_override);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "remove_vtable_override"),
+        stub_remove_vtable_override);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "inspect_str"),
+        stub_inspect_str);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "freeze"),
+        stub_freeze);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "thaw"),
+        stub_thaw);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "thawfinish"),
+        stub_thawfinish);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "visit"),
+        stub_visit);
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "init_int"),
+        stub_init_int);
+    /* END vtable mapping name stubs */
+
+    /* BEGIN vtable mapping group items */
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "exists_keyed"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "exists_keyed_int"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "exists_keyed_str"));
+    parrot_hash_put(interp, vtable_group_items,
+        CONST_STRING(interp, "EXISTS"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "get_integer_keyed"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "get_integer_keyed_int"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "get_integer_keyed_str"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "get_number_keyed"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "get_number_keyed_int"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "get_number_keyed_str"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "get_string_keyed"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "get_string_keyed_int"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "get_string_keyed_str"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "get_pmc_keyed"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "get_pmc_keyed_int"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "get_pmc_keyed_str"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "get_pointer_keyed"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "get_pointer_keyed_int"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "get_pointer_keyed_str"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "set_integer_native"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "set_integer_keyed"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "set_integer_keyed_int"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "set_integer_keyed_str"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "set_number_native"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "set_number_keyed"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "set_number_keyed_int"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "set_number_keyed_str"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "set_string_native"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "assign_string_native"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "set_string_keyed"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "set_string_keyed_int"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "set_string_keyed_str"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "set_bool"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "set_pmc"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "assign_pmc"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "set_pmc_keyed"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "set_pmc_keyed_int"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "set_pmc_keyed_str"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "set_pointer"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "set_pointer_keyed"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "set_pointer_keyed_int"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "set_pointer_keyed_str"));
+    parrot_hash_put(interp, vtable_group_items,
+        CONST_STRING(interp, "FETCH"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "concatenate"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "concatenate_str"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_concatenate"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_concatenate_str"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "repeat"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "repeat_int"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_repeat"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_repeat_int"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "substr"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "substr_str"));
+    parrot_hash_put(interp, vtable_group_items,
+        CONST_STRING(interp, "STRING"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "add"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "add_int"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "add_float"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_add"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_add_int"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_add_float"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "subtract"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "subtract_int"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "subtract_float"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_subtract"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_subtract_int"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_subtract_float"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "multiply"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "multiply_int"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "multiply_float"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_multiply"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_multiply_int"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_multiply_float"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "divide"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "divide_int"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "divide_float"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_divide"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_divide_int"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_divide_float"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "floor_divide"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "floor_divide_int"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "floor_divide_float"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_floor_divide"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_floor_divide_int"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_floor_divide_float"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "modulus"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "modulus_int"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "modulus_float"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_modulus"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_modulus_int"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_modulus_float"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "absolute"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "neg"));
+    parrot_hash_put(interp, vtable_group_items,
+        CONST_STRING(interp, "MATH"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "defined_keyed"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "defined_keyed_int"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "defined_keyed_str"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "delete_keyed"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "delete_keyed_int"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "delete_keyed_str"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "invoke"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "can"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "does_pmc"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "does"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "isa_pmc"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "isa"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "get_attr_str"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "get_attr_keyed"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "set_attr_str"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "set_attr_keyed"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "add_parent"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "remove_parent"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "add_role"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "remove_role"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "add_attribute"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "remove_attribute"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "add_method"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "remove_method"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "add_vtable_override"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "remove_vtable_override"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "inspect_str"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "freeze"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "thaw"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "thawfinish"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "visit"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "init_int"));
+    parrot_hash_put(interp, vtable_group_items,
+        CONST_STRING(interp, "MAIN"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "push_integer"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "push_float"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "push_string"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "push_pmc"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "unshift_integer"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "unshift_float"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "unshift_string"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "unshift_pmc"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "splice"));
+    parrot_hash_put(interp, vtable_group_items,
+        CONST_STRING(interp, "FETCHSIZE"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "is_equal"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "is_equal_num"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "is_equal_string"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "is_same"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "cmp"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "cmp_num"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "cmp_string"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "cmp_pmc"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "logical_or"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "logical_and"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "logical_xor"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "logical_not"));
+    parrot_hash_put(interp, vtable_group_items,
+        CONST_STRING(interp, "CMP"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "morph"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_add"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_add_int"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_add_float"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_subtract"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_subtract_int"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_subtract_float"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_multiply"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_multiply_int"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_multiply_float"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_divide"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_divide_int"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_divide_float"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_floor_divide"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_floor_divide_int"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_floor_divide_float"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_modulus"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_modulus_int"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_modulus_float"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_concatenate"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_concatenate_str"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_repeat"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "i_repeat_int"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "set_attr_str"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "set_attr_keyed"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "add_parent"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "remove_parent"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "add_role"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "remove_role"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "add_attribute"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "remove_attribute"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "add_method"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "remove_method"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "add_vtable_override"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "remove_vtable_override"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "thaw"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "thawfinish"));
+    parrot_hash_put(interp, vtable_group_items,
+        CONST_STRING(interp, "write"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "init_pmc"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "instantiate"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "morph"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "getprop"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "setprop"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "delprop"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "clone_pmc"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "find_method"));
+    parrot_hash_put(interp, vtable_group_items,
+        CONST_STRING(interp, "CORE"),
+        temp);
+    /* END vtable mapping group items */
+
+    /* BEGIN vtable mapping item groups */
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "core"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "init_pmc"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "core"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "instantiate"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "core"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "morph"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "core"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "getprop"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "core"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "setprop"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "core"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "delprop"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "core"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "clone_pmc"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "core"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "find_method"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "get_integer_keyed"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "get_integer_keyed_int"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "get_integer_keyed_str"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "get_number_keyed"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "get_number_keyed_int"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "get_number_keyed_str"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "get_string_keyed"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "get_string_keyed_int"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "get_string_keyed_str"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "get_pmc_keyed"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "get_pmc_keyed_int"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "get_pmc_keyed_str"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "get_pointer_keyed"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "get_pointer_keyed_int"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "get_pointer_keyed_str"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "set_integer_native"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "set_integer_keyed"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "set_integer_keyed_int"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "set_integer_keyed_str"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "set_number_native"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "set_number_keyed"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "set_number_keyed_int"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "set_number_keyed_str"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "set_string_native"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "assign_string_native"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "set_string_keyed"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "set_string_keyed_int"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "set_string_keyed_str"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "set_bool"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "set_pmc"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "assign_pmc"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "set_pmc_keyed"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "set_pmc_keyed_int"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "set_pmc_keyed_str"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "set_pointer"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "set_pointer_keyed"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "set_pointer_keyed_int"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetch"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "set_pointer_keyed_str"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetchsize"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "push_integer"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetchsize"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "push_float"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetchsize"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "push_string"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetchsize"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "push_pmc"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetchsize"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "unshift_integer"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetchsize"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "unshift_float"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetchsize"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "unshift_string"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetchsize"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "unshift_pmc"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "fetchsize"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "splice"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "add"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "add_int"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "add_float"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "i_add"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "i_add_int"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "i_add_float"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "subtract"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "subtract_int"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "subtract_float"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "i_subtract"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "i_subtract_int"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "i_subtract_float"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "multiply"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "multiply_int"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "multiply_float"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "i_multiply"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "i_multiply_int"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "i_multiply_float"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "divide"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "divide_int"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "divide_float"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "i_divide"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "i_divide_int"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "i_divide_float"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "floor_divide"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "floor_divide_int"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "floor_divide_float"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "i_floor_divide"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "i_floor_divide_int"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "i_floor_divide_float"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "modulus"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "modulus_int"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "modulus_float"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "i_modulus"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "i_modulus_int"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "i_modulus_float"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "absolute"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "math"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "neg"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "cmp"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "is_equal"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "cmp"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "is_equal_num"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "cmp"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "is_equal_string"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "cmp"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "is_same"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "cmp"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "cmp"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "cmp"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "cmp_num"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "cmp"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "cmp_string"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "cmp"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "cmp_pmc"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "cmp"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "logical_or"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "cmp"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "logical_and"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "cmp"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "logical_xor"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "cmp"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "logical_not"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "string"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "concatenate"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "string"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "concatenate_str"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "string"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "i_concatenate"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "string"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "i_concatenate_str"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "string"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "repeat"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "string"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "repeat_int"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "string"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "i_repeat"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "string"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "i_repeat_int"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "string"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "substr"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "string"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "substr_str"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "exists"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "exists_keyed"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "exists"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "exists_keyed_int"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "exists"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "exists_keyed_str"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "main"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "defined_keyed"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "main"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "defined_keyed_int"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "main"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "defined_keyed_str"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "main"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "delete_keyed"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "main"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "delete_keyed_int"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "main"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "delete_keyed_str"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "main"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "invoke"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "main"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "can"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "main"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "does_pmc"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "main"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "does"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "main"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "isa_pmc"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "main"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "isa"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "main"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "get_attr_str"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "main"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "get_attr_keyed"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "main"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "set_attr_str"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "main"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "set_attr_keyed"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "main"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "add_parent"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "main"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "remove_parent"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "main"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "add_role"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "main"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "remove_role"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "main"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "add_attribute"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "main"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "remove_attribute"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "main"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "add_method"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "main"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "remove_method"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "main"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "add_vtable_override"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "main"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "remove_vtable_override"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "main"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "inspect_str"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "main"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "freeze"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "main"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "thaw"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "main"));
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "write"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "thawfinish"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "main"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "visit"),
+        temp);
+
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "main"));
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "init_int"),
+        temp);
+    /* END vtable mapping item groups */
+}
+
+void destroy_vtable_common_hashes(PARROT_INTERP) {
+    if(parrot_hash_size(interp, vtable_registry) == 0) {
+        parrot_hash_destroy(interp, vtable_registry);
+        parrot_hash_destroy(interp, vtable_name_stubs);
+        parrot_hash_destroy(interp, vtable_group_items);
+        parrot_hash_destroy(interp, vtable_item_groups);
 
-        RETURN(PMC *list);
+        vtable_first_run = 1;
     }
-
-}
-
-/*
- * Helpers
- */
-
-void raise_vtable_event(PARROT_INTERP, Parrot_Interp supervised,
-                        PMC *pmc, PMC *data, STRING *group, STRING *type) {
-    Parrot_Context_info info;
-    PMC *task_hash, *task;
-    PMC *event_arr;
-
-    /* Get the current context info. */
-    Parrot_Context_get_info(interp, CURRENT_CONTEXT(supervised), &info);
-
-    /* Set the event type. */
-    event_arr = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
-    VTABLE_push_string(interp, event_arr, CONST_STRING(interp, "Class"));
-    VTABLE_push_string(interp, event_arr, VTABLE_name(supervised, pmc));
-    VTABLE_push_string(interp, event_arr, CONST_STRING(interp, "vtable"));
-    VTABLE_push_string(interp, event_arr, group);
-    VTABLE_push_string(interp, event_arr, type);
-
-    /* Populate data with common items. */
-    VTABLE_set_pmc_keyed_str(interp, data,
-                                CONST_STRING(interp, "event"),
-                                event_arr);
-    VTABLE_set_string_keyed_str(interp,  data, CONST_STRING(interp, "file"),      info.file);
-    VTABLE_set_string_keyed_str(interp,  data, CONST_STRING(interp, "sub"),       info.subname);
-    VTABLE_set_string_keyed_str(interp,  data, CONST_STRING(interp, "namespace"), info.nsname);
-    VTABLE_set_integer_keyed_str(interp, data, CONST_STRING(interp, "line"),      info.line);
-
-    /* Raise the event. */
-    task_hash = Parrot_pmc_new(interp, enum_class_Hash);
-    VTABLE_set_string_keyed_str(interp, task_hash,
-                                CONST_STRING(interp, "type"),
-                                CONST_STRING(interp, "event"));
-    VTABLE_set_string_keyed_str(interp, task_hash,
-                                CONST_STRING(interp, "subtype"),
-                                CONST_STRING(interp, "Instrument"));
-    VTABLE_set_pmc_keyed_str(interp, task_hash, CONST_STRING(interp, "data"), data);
-
-    task = Parrot_pmc_new_init(interp, enum_class_Task, task_hash);
-    Parrot_cx_schedule_task(interp, task);
 }
 
-void build_vtable_hashes(PARROT_INTERP, Hash *orig, Hash *instr, Hash *stub,
-                         _vtable *orig_vtable, _vtable *instr_vtable) {
-    /* BEGIN vtable mappings */
-    /* Build mappings for name -> original function.vtable entry */
-    parrot_hash_put(interp, orig, CONST_STRING(interp, "init_pmc"),
-                orig_vtable->init_pmc);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "instantiate"),
-                orig_vtable->instantiate);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "morph"),
-                orig_vtable->morph);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "getprop"),
-                orig_vtable->getprop);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "setprop"),
-                orig_vtable->setprop);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "delprop"),
-                orig_vtable->delprop);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "clone_pmc"),
-                orig_vtable->clone_pmc);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "find_method"),
-                orig_vtable->find_method);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "get_integer_keyed"),
-                orig_vtable->get_integer_keyed);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "get_integer_keyed_int"),
-                orig_vtable->get_integer_keyed_int);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "get_integer_keyed_str"),
-                orig_vtable->get_integer_keyed_str);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "get_number_keyed"),
-                orig_vtable->get_number_keyed);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "get_number_keyed_int"),
-                orig_vtable->get_number_keyed_int);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "get_number_keyed_str"),
-                orig_vtable->get_number_keyed_str);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "get_string_keyed"),
-                orig_vtable->get_string_keyed);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "get_string_keyed_int"),
-                orig_vtable->get_string_keyed_int);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "get_string_keyed_str"),
-                orig_vtable->get_string_keyed_str);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "get_pmc_keyed"),
-                orig_vtable->get_pmc_keyed);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "get_pmc_keyed_int"),
-                orig_vtable->get_pmc_keyed_int);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "get_pmc_keyed_str"),
-                orig_vtable->get_pmc_keyed_str);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "get_pointer_keyed"),
-                orig_vtable->get_pointer_keyed);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "get_pointer_keyed_int"),
-                orig_vtable->get_pointer_keyed_int);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "get_pointer_keyed_str"),
-                orig_vtable->get_pointer_keyed_str);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "set_integer_native"),
-                orig_vtable->set_integer_native);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "set_integer_keyed"),
-                orig_vtable->set_integer_keyed);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "set_integer_keyed_int"),
-                orig_vtable->set_integer_keyed_int);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "set_integer_keyed_str"),
-                orig_vtable->set_integer_keyed_str);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "set_number_native"),
-                orig_vtable->set_number_native);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "set_number_keyed"),
-                orig_vtable->set_number_keyed);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "set_number_keyed_int"),
-                orig_vtable->set_number_keyed_int);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "set_number_keyed_str"),
-                orig_vtable->set_number_keyed_str);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "set_string_native"),
-                orig_vtable->set_string_native);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "assign_string_native"),
-                orig_vtable->assign_string_native);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "set_string_keyed"),
-                orig_vtable->set_string_keyed);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "set_string_keyed_int"),
-                orig_vtable->set_string_keyed_int);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "set_string_keyed_str"),
-                orig_vtable->set_string_keyed_str);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "set_bool"),
-                orig_vtable->set_bool);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "set_pmc"),
-                orig_vtable->set_pmc);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "assign_pmc"),
-                orig_vtable->assign_pmc);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "set_pmc_keyed"),
-                orig_vtable->set_pmc_keyed);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "set_pmc_keyed_int"),
-                orig_vtable->set_pmc_keyed_int);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "set_pmc_keyed_str"),
-                orig_vtable->set_pmc_keyed_str);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "set_pointer"),
-                orig_vtable->set_pointer);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "set_pointer_keyed"),
-                orig_vtable->set_pointer_keyed);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "set_pointer_keyed_int"),
-                orig_vtable->set_pointer_keyed_int);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "set_pointer_keyed_str"),
-                orig_vtable->set_pointer_keyed_str);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "push_integer"),
-                orig_vtable->push_integer);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "push_float"),
-                orig_vtable->push_float);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "push_string"),
-                orig_vtable->push_string);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "push_pmc"),
-                orig_vtable->push_pmc);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "unshift_integer"),
-                orig_vtable->unshift_integer);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "unshift_float"),
-                orig_vtable->unshift_float);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "unshift_string"),
-                orig_vtable->unshift_string);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "unshift_pmc"),
-                orig_vtable->unshift_pmc);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "splice"),
-                orig_vtable->splice);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "add"),
-                orig_vtable->add);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "add_int"),
-                orig_vtable->add_int);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "add_float"),
-                orig_vtable->add_float);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "i_add"),
-                orig_vtable->i_add);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "i_add_int"),
-                orig_vtable->i_add_int);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "i_add_float"),
-                orig_vtable->i_add_float);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "subtract"),
-                orig_vtable->subtract);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "subtract_int"),
-                orig_vtable->subtract_int);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "subtract_float"),
-                orig_vtable->subtract_float);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "i_subtract"),
-                orig_vtable->i_subtract);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "i_subtract_int"),
-                orig_vtable->i_subtract_int);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "i_subtract_float"),
-                orig_vtable->i_subtract_float);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "multiply"),
-                orig_vtable->multiply);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "multiply_int"),
-                orig_vtable->multiply_int);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "multiply_float"),
-                orig_vtable->multiply_float);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "i_multiply"),
-                orig_vtable->i_multiply);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "i_multiply_int"),
-                orig_vtable->i_multiply_int);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "i_multiply_float"),
-                orig_vtable->i_multiply_float);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "divide"),
-                orig_vtable->divide);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "divide_int"),
-                orig_vtable->divide_int);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "divide_float"),
-                orig_vtable->divide_float);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "i_divide"),
-                orig_vtable->i_divide);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "i_divide_int"),
-                orig_vtable->i_divide_int);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "i_divide_float"),
-                orig_vtable->i_divide_float);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "floor_divide"),
-                orig_vtable->floor_divide);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "floor_divide_int"),
-                orig_vtable->floor_divide_int);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "floor_divide_float"),
-                orig_vtable->floor_divide_float);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "i_floor_divide"),
-                orig_vtable->i_floor_divide);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "i_floor_divide_int"),
-                orig_vtable->i_floor_divide_int);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "i_floor_divide_float"),
-                orig_vtable->i_floor_divide_float);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "modulus"),
-                orig_vtable->modulus);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "modulus_int"),
-                orig_vtable->modulus_int);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "modulus_float"),
-                orig_vtable->modulus_float);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "i_modulus"),
-                orig_vtable->i_modulus);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "i_modulus_int"),
-                orig_vtable->i_modulus_int);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "i_modulus_float"),
-                orig_vtable->i_modulus_float);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "absolute"),
-                orig_vtable->absolute);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "neg"),
-                orig_vtable->neg);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "is_equal"),
-                orig_vtable->is_equal);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "is_equal_num"),
-                orig_vtable->is_equal_num);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "is_equal_string"),
-                orig_vtable->is_equal_string);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "is_same"),
-                orig_vtable->is_same);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "cmp"),
-                orig_vtable->cmp);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "cmp_num"),
-                orig_vtable->cmp_num);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "cmp_string"),
-                orig_vtable->cmp_string);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "cmp_pmc"),
-                orig_vtable->cmp_pmc);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "logical_or"),
-                orig_vtable->logical_or);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "logical_and"),
-                orig_vtable->logical_and);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "logical_xor"),
-                orig_vtable->logical_xor);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "logical_not"),
-                orig_vtable->logical_not);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "concatenate"),
-                orig_vtable->concatenate);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "concatenate_str"),
-                orig_vtable->concatenate_str);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "i_concatenate"),
-                orig_vtable->i_concatenate);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "i_concatenate_str"),
-                orig_vtable->i_concatenate_str);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "repeat"),
-                orig_vtable->repeat);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "repeat_int"),
-                orig_vtable->repeat_int);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "i_repeat"),
-                orig_vtable->i_repeat);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "i_repeat_int"),
-                orig_vtable->i_repeat_int);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "substr"),
-                orig_vtable->substr);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "substr_str"),
-                orig_vtable->substr_str);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "exists_keyed"),
-                orig_vtable->exists_keyed);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "exists_keyed_int"),
-                orig_vtable->exists_keyed_int);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "exists_keyed_str"),
-                orig_vtable->exists_keyed_str);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "defined_keyed"),
-                orig_vtable->defined_keyed);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "defined_keyed_int"),
-                orig_vtable->defined_keyed_int);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "defined_keyed_str"),
-                orig_vtable->defined_keyed_str);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "delete_keyed"),
-                orig_vtable->delete_keyed);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "delete_keyed_int"),
-                orig_vtable->delete_keyed_int);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "delete_keyed_str"),
-                orig_vtable->delete_keyed_str);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "invoke"),
-                orig_vtable->invoke);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "can"),
-                orig_vtable->can);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "does_pmc"),
-                orig_vtable->does_pmc);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "does"),
-                orig_vtable->does);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "isa_pmc"),
-                orig_vtable->isa_pmc);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "isa"),
-                orig_vtable->isa);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "get_attr_str"),
-                orig_vtable->get_attr_str);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "get_attr_keyed"),
-                orig_vtable->get_attr_keyed);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "set_attr_str"),
-                orig_vtable->set_attr_str);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "set_attr_keyed"),
-                orig_vtable->set_attr_keyed);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "add_parent"),
-                orig_vtable->add_parent);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "remove_parent"),
-                orig_vtable->remove_parent);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "add_role"),
-                orig_vtable->add_role);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "remove_role"),
-                orig_vtable->remove_role);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "add_attribute"),
-                orig_vtable->add_attribute);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "remove_attribute"),
-                orig_vtable->remove_attribute);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "add_method"),
-                orig_vtable->add_method);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "remove_method"),
-                orig_vtable->remove_method);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "add_vtable_override"),
-                orig_vtable->add_vtable_override);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "remove_vtable_override"),
-                orig_vtable->remove_vtable_override);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "inspect_str"),
-                orig_vtable->inspect_str);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "freeze"),
-                orig_vtable->freeze);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "thaw"),
-                orig_vtable->thaw);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "thawfinish"),
-                orig_vtable->thawfinish);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "visit"),
-                orig_vtable->visit);
-     parrot_hash_put(interp, orig, CONST_STRING(interp, "init_int"),
-                orig_vtable->init_int);
-
-
-    /* Build mappings for name -> instrumented function.vtable entry. */
-    parrot_hash_put(interp, instr, CONST_STRING(interp, "init_pmc"),
-                &(instr_vtable->init_pmc));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "instantiate"),
-                &(instr_vtable->instantiate));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "morph"),
-                &(instr_vtable->morph));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "getprop"),
-                &(instr_vtable->getprop));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "setprop"),
-                &(instr_vtable->setprop));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "delprop"),
-                &(instr_vtable->delprop));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "clone_pmc"),
-                &(instr_vtable->clone_pmc));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "find_method"),
-                &(instr_vtable->find_method));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "get_integer_keyed"),
-                &(instr_vtable->get_integer_keyed));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "get_integer_keyed_int"),
-                &(instr_vtable->get_integer_keyed_int));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "get_integer_keyed_str"),
-                &(instr_vtable->get_integer_keyed_str));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "get_number_keyed"),
-                &(instr_vtable->get_number_keyed));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "get_number_keyed_int"),
-                &(instr_vtable->get_number_keyed_int));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "get_number_keyed_str"),
-                &(instr_vtable->get_number_keyed_str));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "get_string_keyed"),
-                &(instr_vtable->get_string_keyed));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "get_string_keyed_int"),
-                &(instr_vtable->get_string_keyed_int));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "get_string_keyed_str"),
-                &(instr_vtable->get_string_keyed_str));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "get_pmc_keyed"),
-                &(instr_vtable->get_pmc_keyed));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "get_pmc_keyed_int"),
-                &(instr_vtable->get_pmc_keyed_int));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "get_pmc_keyed_str"),
-                &(instr_vtable->get_pmc_keyed_str));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "get_pointer_keyed"),
-                &(instr_vtable->get_pointer_keyed));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "get_pointer_keyed_int"),
-                &(instr_vtable->get_pointer_keyed_int));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "get_pointer_keyed_str"),
-                &(instr_vtable->get_pointer_keyed_str));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "set_integer_native"),
-                &(instr_vtable->set_integer_native));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "set_integer_keyed"),
-                &(instr_vtable->set_integer_keyed));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "set_integer_keyed_int"),
-                &(instr_vtable->set_integer_keyed_int));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "set_integer_keyed_str"),
-                &(instr_vtable->set_integer_keyed_str));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "set_number_native"),
-                &(instr_vtable->set_number_native));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "set_number_keyed"),
-                &(instr_vtable->set_number_keyed));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "set_number_keyed_int"),
-                &(instr_vtable->set_number_keyed_int));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "set_number_keyed_str"),
-                &(instr_vtable->set_number_keyed_str));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "set_string_native"),
-                &(instr_vtable->set_string_native));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "assign_string_native"),
-                &(instr_vtable->assign_string_native));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "set_string_keyed"),
-                &(instr_vtable->set_string_keyed));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "set_string_keyed_int"),
-                &(instr_vtable->set_string_keyed_int));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "set_string_keyed_str"),
-                &(instr_vtable->set_string_keyed_str));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "set_bool"),
-                &(instr_vtable->set_bool));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "set_pmc"),
-                &(instr_vtable->set_pmc));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "assign_pmc"),
-                &(instr_vtable->assign_pmc));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "set_pmc_keyed"),
-                &(instr_vtable->set_pmc_keyed));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "set_pmc_keyed_int"),
-                &(instr_vtable->set_pmc_keyed_int));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "set_pmc_keyed_str"),
-                &(instr_vtable->set_pmc_keyed_str));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "set_pointer"),
-                &(instr_vtable->set_pointer));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "set_pointer_keyed"),
-                &(instr_vtable->set_pointer_keyed));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "set_pointer_keyed_int"),
-                &(instr_vtable->set_pointer_keyed_int));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "set_pointer_keyed_str"),
-                &(instr_vtable->set_pointer_keyed_str));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "push_integer"),
-                &(instr_vtable->push_integer));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "push_float"),
-                &(instr_vtable->push_float));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "push_string"),
-                &(instr_vtable->push_string));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "push_pmc"),
-                &(instr_vtable->push_pmc));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "unshift_integer"),
-                &(instr_vtable->unshift_integer));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "unshift_float"),
-                &(instr_vtable->unshift_float));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "unshift_string"),
-                &(instr_vtable->unshift_string));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "unshift_pmc"),
-                &(instr_vtable->unshift_pmc));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "splice"),
-                &(instr_vtable->splice));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "add"),
-                &(instr_vtable->add));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "add_int"),
-                &(instr_vtable->add_int));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "add_float"),
-                &(instr_vtable->add_float));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "i_add"),
-                &(instr_vtable->i_add));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "i_add_int"),
-                &(instr_vtable->i_add_int));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "i_add_float"),
-                &(instr_vtable->i_add_float));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "subtract"),
-                &(instr_vtable->subtract));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "subtract_int"),
-                &(instr_vtable->subtract_int));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "subtract_float"),
-                &(instr_vtable->subtract_float));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "i_subtract"),
-                &(instr_vtable->i_subtract));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "i_subtract_int"),
-                &(instr_vtable->i_subtract_int));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "i_subtract_float"),
-                &(instr_vtable->i_subtract_float));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "multiply"),
-                &(instr_vtable->multiply));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "multiply_int"),
-                &(instr_vtable->multiply_int));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "multiply_float"),
-                &(instr_vtable->multiply_float));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "i_multiply"),
-                &(instr_vtable->i_multiply));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "i_multiply_int"),
-                &(instr_vtable->i_multiply_int));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "i_multiply_float"),
-                &(instr_vtable->i_multiply_float));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "divide"),
-                &(instr_vtable->divide));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "divide_int"),
-                &(instr_vtable->divide_int));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "divide_float"),
-                &(instr_vtable->divide_float));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "i_divide"),
-                &(instr_vtable->i_divide));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "i_divide_int"),
-                &(instr_vtable->i_divide_int));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "i_divide_float"),
-                &(instr_vtable->i_divide_float));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "floor_divide"),
-                &(instr_vtable->floor_divide));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "floor_divide_int"),
-                &(instr_vtable->floor_divide_int));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "floor_divide_float"),
-                &(instr_vtable->floor_divide_float));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "i_floor_divide"),
-                &(instr_vtable->i_floor_divide));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "i_floor_divide_int"),
-                &(instr_vtable->i_floor_divide_int));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "i_floor_divide_float"),
-                &(instr_vtable->i_floor_divide_float));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "modulus"),
-                &(instr_vtable->modulus));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "modulus_int"),
-                &(instr_vtable->modulus_int));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "modulus_float"),
-                &(instr_vtable->modulus_float));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "i_modulus"),
-                &(instr_vtable->i_modulus));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "i_modulus_int"),
-                &(instr_vtable->i_modulus_int));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "i_modulus_float"),
-                &(instr_vtable->i_modulus_float));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "absolute"),
-                &(instr_vtable->absolute));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "neg"),
-                &(instr_vtable->neg));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "is_equal"),
-                &(instr_vtable->is_equal));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "is_equal_num"),
-                &(instr_vtable->is_equal_num));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "is_equal_string"),
-                &(instr_vtable->is_equal_string));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "is_same"),
-                &(instr_vtable->is_same));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "cmp"),
-                &(instr_vtable->cmp));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "cmp_num"),
-                &(instr_vtable->cmp_num));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "cmp_string"),
-                &(instr_vtable->cmp_string));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "cmp_pmc"),
-                &(instr_vtable->cmp_pmc));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "logical_or"),
-                &(instr_vtable->logical_or));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "logical_and"),
-                &(instr_vtable->logical_and));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "logical_xor"),
-                &(instr_vtable->logical_xor));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "logical_not"),
-                &(instr_vtable->logical_not));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "concatenate"),
-                &(instr_vtable->concatenate));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "concatenate_str"),
-                &(instr_vtable->concatenate_str));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "i_concatenate"),
-                &(instr_vtable->i_concatenate));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "i_concatenate_str"),
-                &(instr_vtable->i_concatenate_str));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "repeat"),
-                &(instr_vtable->repeat));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "repeat_int"),
-                &(instr_vtable->repeat_int));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "i_repeat"),
-                &(instr_vtable->i_repeat));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "i_repeat_int"),
-                &(instr_vtable->i_repeat_int));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "substr"),
-                &(instr_vtable->substr));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "substr_str"),
-                &(instr_vtable->substr_str));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "exists_keyed"),
-                &(instr_vtable->exists_keyed));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "exists_keyed_int"),
-                &(instr_vtable->exists_keyed_int));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "exists_keyed_str"),
-                &(instr_vtable->exists_keyed_str));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "defined_keyed"),
-                &(instr_vtable->defined_keyed));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "defined_keyed_int"),
-                &(instr_vtable->defined_keyed_int));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "defined_keyed_str"),
-                &(instr_vtable->defined_keyed_str));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "delete_keyed"),
-                &(instr_vtable->delete_keyed));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "delete_keyed_int"),
-                &(instr_vtable->delete_keyed_int));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "delete_keyed_str"),
-                &(instr_vtable->delete_keyed_str));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "invoke"),
-                &(instr_vtable->invoke));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "can"),
-                &(instr_vtable->can));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "does_pmc"),
-                &(instr_vtable->does_pmc));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "does"),
-                &(instr_vtable->does));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "isa_pmc"),
-                &(instr_vtable->isa_pmc));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "isa"),
-                &(instr_vtable->isa));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "get_attr_str"),
-                &(instr_vtable->get_attr_str));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "get_attr_keyed"),
-                &(instr_vtable->get_attr_keyed));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "set_attr_str"),
-                &(instr_vtable->set_attr_str));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "set_attr_keyed"),
-                &(instr_vtable->set_attr_keyed));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "add_parent"),
-                &(instr_vtable->add_parent));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "remove_parent"),
-                &(instr_vtable->remove_parent));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "add_role"),
-                &(instr_vtable->add_role));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "remove_role"),
-                &(instr_vtable->remove_role));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "add_attribute"),
-                &(instr_vtable->add_attribute));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "remove_attribute"),
-                &(instr_vtable->remove_attribute));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "add_method"),
-                &(instr_vtable->add_method));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "remove_method"),
-                &(instr_vtable->remove_method));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "add_vtable_override"),
-                &(instr_vtable->add_vtable_override));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "remove_vtable_override"),
-                &(instr_vtable->remove_vtable_override));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "inspect_str"),
-                &(instr_vtable->inspect_str));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "freeze"),
-                &(instr_vtable->freeze));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "thaw"),
-                &(instr_vtable->thaw));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "thawfinish"),
-                &(instr_vtable->thawfinish));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "visit"),
-                &(instr_vtable->visit));
-     parrot_hash_put(interp, instr, CONST_STRING(interp, "init_int"),
-                &(instr_vtable->init_int));
-
-
-    /* Build mappings for name -> stub_function if it wasn't done already. */
-    if (parrot_hash_size(interp, stub) == 0) {
-        parrot_hash_put(interp, stub, CONST_STRING(interp, "init_pmc"),
-                        stub_init_pmc);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "instantiate"),
-                        stub_instantiate);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "morph"),
-                        stub_morph);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "getprop"),
-                        stub_getprop);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "setprop"),
-                        stub_setprop);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "delprop"),
-                        stub_delprop);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "clone_pmc"),
-                        stub_clone_pmc);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "find_method"),
-                        stub_find_method);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "get_integer_keyed"),
-                        stub_get_integer_keyed);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "get_integer_keyed_int"),
-                        stub_get_integer_keyed_int);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "get_integer_keyed_str"),
-                        stub_get_integer_keyed_str);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "get_number_keyed"),
-                        stub_get_number_keyed);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "get_number_keyed_int"),
-                        stub_get_number_keyed_int);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "get_number_keyed_str"),
-                        stub_get_number_keyed_str);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "get_string_keyed"),
-                        stub_get_string_keyed);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "get_string_keyed_int"),
-                        stub_get_string_keyed_int);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "get_string_keyed_str"),
-                        stub_get_string_keyed_str);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "get_pmc_keyed"),
-                        stub_get_pmc_keyed);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "get_pmc_keyed_int"),
-                        stub_get_pmc_keyed_int);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "get_pmc_keyed_str"),
-                        stub_get_pmc_keyed_str);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "get_pointer_keyed"),
-                        stub_get_pointer_keyed);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "get_pointer_keyed_int"),
-                        stub_get_pointer_keyed_int);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "get_pointer_keyed_str"),
-                        stub_get_pointer_keyed_str);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "set_integer_native"),
-                        stub_set_integer_native);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "set_integer_keyed"),
-                        stub_set_integer_keyed);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "set_integer_keyed_int"),
-                        stub_set_integer_keyed_int);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "set_integer_keyed_str"),
-                        stub_set_integer_keyed_str);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "set_number_native"),
-                        stub_set_number_native);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "set_number_keyed"),
-                        stub_set_number_keyed);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "set_number_keyed_int"),
-                        stub_set_number_keyed_int);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "set_number_keyed_str"),
-                        stub_set_number_keyed_str);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "set_string_native"),
-                        stub_set_string_native);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "assign_string_native"),
-                        stub_assign_string_native);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "set_string_keyed"),
-                        stub_set_string_keyed);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "set_string_keyed_int"),
-                        stub_set_string_keyed_int);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "set_string_keyed_str"),
-                        stub_set_string_keyed_str);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "set_bool"),
-                        stub_set_bool);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "set_pmc"),
-                        stub_set_pmc);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "assign_pmc"),
-                        stub_assign_pmc);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "set_pmc_keyed"),
-                        stub_set_pmc_keyed);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "set_pmc_keyed_int"),
-                        stub_set_pmc_keyed_int);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "set_pmc_keyed_str"),
-                        stub_set_pmc_keyed_str);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "set_pointer"),
-                        stub_set_pointer);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "set_pointer_keyed"),
-                        stub_set_pointer_keyed);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "set_pointer_keyed_int"),
-                        stub_set_pointer_keyed_int);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "set_pointer_keyed_str"),
-                        stub_set_pointer_keyed_str);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "push_integer"),
-                        stub_push_integer);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "push_float"),
-                        stub_push_float);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "push_string"),
-                        stub_push_string);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "push_pmc"),
-                        stub_push_pmc);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "unshift_integer"),
-                        stub_unshift_integer);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "unshift_float"),
-                        stub_unshift_float);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "unshift_string"),
-                        stub_unshift_string);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "unshift_pmc"),
-                        stub_unshift_pmc);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "splice"),
-                        stub_splice);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "add"),
-                        stub_add);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "add_int"),
-                        stub_add_int);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "add_float"),
-                        stub_add_float);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "i_add"),
-                        stub_i_add);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "i_add_int"),
-                        stub_i_add_int);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "i_add_float"),
-                        stub_i_add_float);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "subtract"),
-                        stub_subtract);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "subtract_int"),
-                        stub_subtract_int);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "subtract_float"),
-                        stub_subtract_float);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "i_subtract"),
-                        stub_i_subtract);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "i_subtract_int"),
-                        stub_i_subtract_int);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "i_subtract_float"),
-                        stub_i_subtract_float);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "multiply"),
-                        stub_multiply);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "multiply_int"),
-                        stub_multiply_int);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "multiply_float"),
-                        stub_multiply_float);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "i_multiply"),
-                        stub_i_multiply);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "i_multiply_int"),
-                        stub_i_multiply_int);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "i_multiply_float"),
-                        stub_i_multiply_float);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "divide"),
-                        stub_divide);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "divide_int"),
-                        stub_divide_int);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "divide_float"),
-                        stub_divide_float);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "i_divide"),
-                        stub_i_divide);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "i_divide_int"),
-                        stub_i_divide_int);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "i_divide_float"),
-                        stub_i_divide_float);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "floor_divide"),
-                        stub_floor_divide);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "floor_divide_int"),
-                        stub_floor_divide_int);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "floor_divide_float"),
-                        stub_floor_divide_float);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "i_floor_divide"),
-                        stub_i_floor_divide);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "i_floor_divide_int"),
-                        stub_i_floor_divide_int);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "i_floor_divide_float"),
-                        stub_i_floor_divide_float);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "modulus"),
-                        stub_modulus);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "modulus_int"),
-                        stub_modulus_int);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "modulus_float"),
-                        stub_modulus_float);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "i_modulus"),
-                        stub_i_modulus);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "i_modulus_int"),
-                        stub_i_modulus_int);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "i_modulus_float"),
-                        stub_i_modulus_float);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "absolute"),
-                        stub_absolute);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "neg"),
-                        stub_neg);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "is_equal"),
-                        stub_is_equal);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "is_equal_num"),
-                        stub_is_equal_num);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "is_equal_string"),
-                        stub_is_equal_string);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "is_same"),
-                        stub_is_same);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "cmp"),
-                        stub_cmp);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "cmp_num"),
-                        stub_cmp_num);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "cmp_string"),
-                        stub_cmp_string);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "cmp_pmc"),
-                        stub_cmp_pmc);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "logical_or"),
-                        stub_logical_or);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "logical_and"),
-                        stub_logical_and);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "logical_xor"),
-                        stub_logical_xor);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "logical_not"),
-                        stub_logical_not);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "concatenate"),
-                        stub_concatenate);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "concatenate_str"),
-                        stub_concatenate_str);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "i_concatenate"),
-                        stub_i_concatenate);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "i_concatenate_str"),
-                        stub_i_concatenate_str);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "repeat"),
-                        stub_repeat);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "repeat_int"),
-                        stub_repeat_int);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "i_repeat"),
-                        stub_i_repeat);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "i_repeat_int"),
-                        stub_i_repeat_int);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "substr"),
-                        stub_substr);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "substr_str"),
-                        stub_substr_str);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "exists_keyed"),
-                        stub_exists_keyed);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "exists_keyed_int"),
-                        stub_exists_keyed_int);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "exists_keyed_str"),
-                        stub_exists_keyed_str);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "defined_keyed"),
-                        stub_defined_keyed);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "defined_keyed_int"),
-                        stub_defined_keyed_int);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "defined_keyed_str"),
-                        stub_defined_keyed_str);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "delete_keyed"),
-                        stub_delete_keyed);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "delete_keyed_int"),
-                        stub_delete_keyed_int);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "delete_keyed_str"),
-                        stub_delete_keyed_str);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "invoke"),
-                        stub_invoke);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "can"),
-                        stub_can);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "does_pmc"),
-                        stub_does_pmc);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "does"),
-                        stub_does);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "isa_pmc"),
-                        stub_isa_pmc);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "isa"),
-                        stub_isa);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "get_attr_str"),
-                        stub_get_attr_str);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "get_attr_keyed"),
-                        stub_get_attr_keyed);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "set_attr_str"),
-                        stub_set_attr_str);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "set_attr_keyed"),
-                        stub_set_attr_keyed);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "add_parent"),
-                        stub_add_parent);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "remove_parent"),
-                        stub_remove_parent);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "add_role"),
-                        stub_add_role);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "remove_role"),
-                        stub_remove_role);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "add_attribute"),
-                        stub_add_attribute);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "remove_attribute"),
-                        stub_remove_attribute);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "add_method"),
-                        stub_add_method);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "remove_method"),
-                        stub_remove_method);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "add_vtable_override"),
-                        stub_add_vtable_override);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "remove_vtable_override"),
-                        stub_remove_vtable_override);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "inspect_str"),
-                        stub_inspect_str);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "freeze"),
-                        stub_freeze);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "thaw"),
-                        stub_thaw);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "thawfinish"),
-                        stub_thawfinish);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "visit"),
-                        stub_visit);
-         parrot_hash_put(interp, stub, CONST_STRING(interp, "init_int"),
-                        stub_init_int);
-
-    }
-
-    /* END vtable mappings */
+void setup_vtable_individual_hashes(PARROT_INTERP, Hash *orig_hash, Hash *instr_hash,
+                                    _vtable *vt_orig, _vtable *vt_instr) {
+    /* BEGIN vtable mapping name offset */
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "init_pmc"),
+        &(vt_instr->init_pmc));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "instantiate"),
+        &(vt_instr->instantiate));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "morph"),
+        &(vt_instr->morph));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "getprop"),
+        &(vt_instr->getprop));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "setprop"),
+        &(vt_instr->setprop));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "delprop"),
+        &(vt_instr->delprop));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "clone_pmc"),
+        &(vt_instr->clone_pmc));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "find_method"),
+        &(vt_instr->find_method));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "get_integer_keyed"),
+        &(vt_instr->get_integer_keyed));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "get_integer_keyed_int"),
+        &(vt_instr->get_integer_keyed_int));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "get_integer_keyed_str"),
+        &(vt_instr->get_integer_keyed_str));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "get_number_keyed"),
+        &(vt_instr->get_number_keyed));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "get_number_keyed_int"),
+        &(vt_instr->get_number_keyed_int));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "get_number_keyed_str"),
+        &(vt_instr->get_number_keyed_str));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "get_string_keyed"),
+        &(vt_instr->get_string_keyed));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "get_string_keyed_int"),
+        &(vt_instr->get_string_keyed_int));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "get_string_keyed_str"),
+        &(vt_instr->get_string_keyed_str));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "get_pmc_keyed"),
+        &(vt_instr->get_pmc_keyed));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "get_pmc_keyed_int"),
+        &(vt_instr->get_pmc_keyed_int));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "get_pmc_keyed_str"),
+        &(vt_instr->get_pmc_keyed_str));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "get_pointer_keyed"),
+        &(vt_instr->get_pointer_keyed));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "get_pointer_keyed_int"),
+        &(vt_instr->get_pointer_keyed_int));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "get_pointer_keyed_str"),
+        &(vt_instr->get_pointer_keyed_str));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "set_integer_native"),
+        &(vt_instr->set_integer_native));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "set_integer_keyed"),
+        &(vt_instr->set_integer_keyed));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "set_integer_keyed_int"),
+        &(vt_instr->set_integer_keyed_int));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "set_integer_keyed_str"),
+        &(vt_instr->set_integer_keyed_str));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "set_number_native"),
+        &(vt_instr->set_number_native));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "set_number_keyed"),
+        &(vt_instr->set_number_keyed));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "set_number_keyed_int"),
+        &(vt_instr->set_number_keyed_int));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "set_number_keyed_str"),
+        &(vt_instr->set_number_keyed_str));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "set_string_native"),
+        &(vt_instr->set_string_native));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "assign_string_native"),
+        &(vt_instr->assign_string_native));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "set_string_keyed"),
+        &(vt_instr->set_string_keyed));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "set_string_keyed_int"),
+        &(vt_instr->set_string_keyed_int));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "set_string_keyed_str"),
+        &(vt_instr->set_string_keyed_str));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "set_bool"),
+        &(vt_instr->set_bool));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "set_pmc"),
+        &(vt_instr->set_pmc));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "assign_pmc"),
+        &(vt_instr->assign_pmc));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "set_pmc_keyed"),
+        &(vt_instr->set_pmc_keyed));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "set_pmc_keyed_int"),
+        &(vt_instr->set_pmc_keyed_int));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "set_pmc_keyed_str"),
+        &(vt_instr->set_pmc_keyed_str));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "set_pointer"),
+        &(vt_instr->set_pointer));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "set_pointer_keyed"),
+        &(vt_instr->set_pointer_keyed));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "set_pointer_keyed_int"),
+        &(vt_instr->set_pointer_keyed_int));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "set_pointer_keyed_str"),
+        &(vt_instr->set_pointer_keyed_str));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "push_integer"),
+        &(vt_instr->push_integer));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "push_float"),
+        &(vt_instr->push_float));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "push_string"),
+        &(vt_instr->push_string));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "push_pmc"),
+        &(vt_instr->push_pmc));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "unshift_integer"),
+        &(vt_instr->unshift_integer));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "unshift_float"),
+        &(vt_instr->unshift_float));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "unshift_string"),
+        &(vt_instr->unshift_string));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "unshift_pmc"),
+        &(vt_instr->unshift_pmc));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "splice"),
+        &(vt_instr->splice));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "add"),
+        &(vt_instr->add));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "add_int"),
+        &(vt_instr->add_int));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "add_float"),
+        &(vt_instr->add_float));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "i_add"),
+        &(vt_instr->i_add));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "i_add_int"),
+        &(vt_instr->i_add_int));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "i_add_float"),
+        &(vt_instr->i_add_float));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "subtract"),
+        &(vt_instr->subtract));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "subtract_int"),
+        &(vt_instr->subtract_int));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "subtract_float"),
+        &(vt_instr->subtract_float));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "i_subtract"),
+        &(vt_instr->i_subtract));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "i_subtract_int"),
+        &(vt_instr->i_subtract_int));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "i_subtract_float"),
+        &(vt_instr->i_subtract_float));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "multiply"),
+        &(vt_instr->multiply));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "multiply_int"),
+        &(vt_instr->multiply_int));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "multiply_float"),
+        &(vt_instr->multiply_float));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "i_multiply"),
+        &(vt_instr->i_multiply));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "i_multiply_int"),
+        &(vt_instr->i_multiply_int));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "i_multiply_float"),
+        &(vt_instr->i_multiply_float));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "divide"),
+        &(vt_instr->divide));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "divide_int"),
+        &(vt_instr->divide_int));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "divide_float"),
+        &(vt_instr->divide_float));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "i_divide"),
+        &(vt_instr->i_divide));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "i_divide_int"),
+        &(vt_instr->i_divide_int));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "i_divide_float"),
+        &(vt_instr->i_divide_float));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "floor_divide"),
+        &(vt_instr->floor_divide));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "floor_divide_int"),
+        &(vt_instr->floor_divide_int));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "floor_divide_float"),
+        &(vt_instr->floor_divide_float));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "i_floor_divide"),
+        &(vt_instr->i_floor_divide));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "i_floor_divide_int"),
+        &(vt_instr->i_floor_divide_int));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "i_floor_divide_float"),
+        &(vt_instr->i_floor_divide_float));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "modulus"),
+        &(vt_instr->modulus));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "modulus_int"),
+        &(vt_instr->modulus_int));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "modulus_float"),
+        &(vt_instr->modulus_float));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "i_modulus"),
+        &(vt_instr->i_modulus));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "i_modulus_int"),
+        &(vt_instr->i_modulus_int));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "i_modulus_float"),
+        &(vt_instr->i_modulus_float));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "absolute"),
+        &(vt_instr->absolute));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "neg"),
+        &(vt_instr->neg));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "is_equal"),
+        &(vt_instr->is_equal));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "is_equal_num"),
+        &(vt_instr->is_equal_num));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "is_equal_string"),
+        &(vt_instr->is_equal_string));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "is_same"),
+        &(vt_instr->is_same));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "cmp"),
+        &(vt_instr->cmp));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "cmp_num"),
+        &(vt_instr->cmp_num));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "cmp_string"),
+        &(vt_instr->cmp_string));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "cmp_pmc"),
+        &(vt_instr->cmp_pmc));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "logical_or"),
+        &(vt_instr->logical_or));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "logical_and"),
+        &(vt_instr->logical_and));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "logical_xor"),
+        &(vt_instr->logical_xor));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "logical_not"),
+        &(vt_instr->logical_not));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "concatenate"),
+        &(vt_instr->concatenate));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "concatenate_str"),
+        &(vt_instr->concatenate_str));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "i_concatenate"),
+        &(vt_instr->i_concatenate));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "i_concatenate_str"),
+        &(vt_instr->i_concatenate_str));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "repeat"),
+        &(vt_instr->repeat));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "repeat_int"),
+        &(vt_instr->repeat_int));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "i_repeat"),
+        &(vt_instr->i_repeat));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "i_repeat_int"),
+        &(vt_instr->i_repeat_int));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "substr"),
+        &(vt_instr->substr));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "substr_str"),
+        &(vt_instr->substr_str));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "exists_keyed"),
+        &(vt_instr->exists_keyed));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "exists_keyed_int"),
+        &(vt_instr->exists_keyed_int));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "exists_keyed_str"),
+        &(vt_instr->exists_keyed_str));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "defined_keyed"),
+        &(vt_instr->defined_keyed));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "defined_keyed_int"),
+        &(vt_instr->defined_keyed_int));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "defined_keyed_str"),
+        &(vt_instr->defined_keyed_str));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "delete_keyed"),
+        &(vt_instr->delete_keyed));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "delete_keyed_int"),
+        &(vt_instr->delete_keyed_int));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "delete_keyed_str"),
+        &(vt_instr->delete_keyed_str));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "invoke"),
+        &(vt_instr->invoke));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "can"),
+        &(vt_instr->can));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "does_pmc"),
+        &(vt_instr->does_pmc));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "does"),
+        &(vt_instr->does));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "isa_pmc"),
+        &(vt_instr->isa_pmc));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "isa"),
+        &(vt_instr->isa));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "get_attr_str"),
+        &(vt_instr->get_attr_str));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "get_attr_keyed"),
+        &(vt_instr->get_attr_keyed));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "set_attr_str"),
+        &(vt_instr->set_attr_str));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "set_attr_keyed"),
+        &(vt_instr->set_attr_keyed));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "add_parent"),
+        &(vt_instr->add_parent));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "remove_parent"),
+        &(vt_instr->remove_parent));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "add_role"),
+        &(vt_instr->add_role));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "remove_role"),
+        &(vt_instr->remove_role));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "add_attribute"),
+        &(vt_instr->add_attribute));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "remove_attribute"),
+        &(vt_instr->remove_attribute));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "add_method"),
+        &(vt_instr->add_method));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "remove_method"),
+        &(vt_instr->remove_method));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "add_vtable_override"),
+        &(vt_instr->add_vtable_override));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "remove_vtable_override"),
+        &(vt_instr->remove_vtable_override));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "inspect_str"),
+        &(vt_instr->inspect_str));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "freeze"),
+        &(vt_instr->freeze));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "thaw"),
+        &(vt_instr->thaw));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "thawfinish"),
+        &(vt_instr->thawfinish));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "visit"),
+        &(vt_instr->visit));
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "init_int"),
+        &(vt_instr->init_int));
+    /* END vtable mapping name offset */
+
+    /* BEGIN vtable mapping name original */
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "init_pmc"),
+        vt_orig->init_pmc);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "instantiate"),
+        vt_orig->instantiate);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "morph"),
+        vt_orig->morph);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "getprop"),
+        vt_orig->getprop);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "setprop"),
+        vt_orig->setprop);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "delprop"),
+        vt_orig->delprop);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "clone_pmc"),
+        vt_orig->clone_pmc);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "find_method"),
+        vt_orig->find_method);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "get_integer_keyed"),
+        vt_orig->get_integer_keyed);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "get_integer_keyed_int"),
+        vt_orig->get_integer_keyed_int);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "get_integer_keyed_str"),
+        vt_orig->get_integer_keyed_str);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "get_number_keyed"),
+        vt_orig->get_number_keyed);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "get_number_keyed_int"),
+        vt_orig->get_number_keyed_int);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "get_number_keyed_str"),
+        vt_orig->get_number_keyed_str);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "get_string_keyed"),
+        vt_orig->get_string_keyed);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "get_string_keyed_int"),
+        vt_orig->get_string_keyed_int);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "get_string_keyed_str"),
+        vt_orig->get_string_keyed_str);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "get_pmc_keyed"),
+        vt_orig->get_pmc_keyed);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "get_pmc_keyed_int"),
+        vt_orig->get_pmc_keyed_int);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "get_pmc_keyed_str"),
+        vt_orig->get_pmc_keyed_str);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "get_pointer_keyed"),
+        vt_orig->get_pointer_keyed);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "get_pointer_keyed_int"),
+        vt_orig->get_pointer_keyed_int);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "get_pointer_keyed_str"),
+        vt_orig->get_pointer_keyed_str);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "set_integer_native"),
+        vt_orig->set_integer_native);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "set_integer_keyed"),
+        vt_orig->set_integer_keyed);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "set_integer_keyed_int"),
+        vt_orig->set_integer_keyed_int);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "set_integer_keyed_str"),
+        vt_orig->set_integer_keyed_str);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "set_number_native"),
+        vt_orig->set_number_native);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "set_number_keyed"),
+        vt_orig->set_number_keyed);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "set_number_keyed_int"),
+        vt_orig->set_number_keyed_int);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "set_number_keyed_str"),
+        vt_orig->set_number_keyed_str);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "set_string_native"),
+        vt_orig->set_string_native);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "assign_string_native"),
+        vt_orig->assign_string_native);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "set_string_keyed"),
+        vt_orig->set_string_keyed);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "set_string_keyed_int"),
+        vt_orig->set_string_keyed_int);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "set_string_keyed_str"),
+        vt_orig->set_string_keyed_str);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "set_bool"),
+        vt_orig->set_bool);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "set_pmc"),
+        vt_orig->set_pmc);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "assign_pmc"),
+        vt_orig->assign_pmc);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "set_pmc_keyed"),
+        vt_orig->set_pmc_keyed);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "set_pmc_keyed_int"),
+        vt_orig->set_pmc_keyed_int);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "set_pmc_keyed_str"),
+        vt_orig->set_pmc_keyed_str);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "set_pointer"),
+        vt_orig->set_pointer);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "set_pointer_keyed"),
+        vt_orig->set_pointer_keyed);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "set_pointer_keyed_int"),
+        vt_orig->set_pointer_keyed_int);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "set_pointer_keyed_str"),
+        vt_orig->set_pointer_keyed_str);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "push_integer"),
+        vt_orig->push_integer);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "push_float"),
+        vt_orig->push_float);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "push_string"),
+        vt_orig->push_string);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "push_pmc"),
+        vt_orig->push_pmc);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "unshift_integer"),
+        vt_orig->unshift_integer);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "unshift_float"),
+        vt_orig->unshift_float);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "unshift_string"),
+        vt_orig->unshift_string);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "unshift_pmc"),
+        vt_orig->unshift_pmc);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "splice"),
+        vt_orig->splice);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "add"),
+        vt_orig->add);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "add_int"),
+        vt_orig->add_int);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "add_float"),
+        vt_orig->add_float);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "i_add"),
+        vt_orig->i_add);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "i_add_int"),
+        vt_orig->i_add_int);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "i_add_float"),
+        vt_orig->i_add_float);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "subtract"),
+        vt_orig->subtract);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "subtract_int"),
+        vt_orig->subtract_int);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "subtract_float"),
+        vt_orig->subtract_float);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "i_subtract"),
+        vt_orig->i_subtract);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "i_subtract_int"),
+        vt_orig->i_subtract_int);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "i_subtract_float"),
+        vt_orig->i_subtract_float);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "multiply"),
+        vt_orig->multiply);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "multiply_int"),
+        vt_orig->multiply_int);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "multiply_float"),
+        vt_orig->multiply_float);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "i_multiply"),
+        vt_orig->i_multiply);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "i_multiply_int"),
+        vt_orig->i_multiply_int);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "i_multiply_float"),
+        vt_orig->i_multiply_float);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "divide"),
+        vt_orig->divide);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "divide_int"),
+        vt_orig->divide_int);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "divide_float"),
+        vt_orig->divide_float);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "i_divide"),
+        vt_orig->i_divide);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "i_divide_int"),
+        vt_orig->i_divide_int);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "i_divide_float"),
+        vt_orig->i_divide_float);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "floor_divide"),
+        vt_orig->floor_divide);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "floor_divide_int"),
+        vt_orig->floor_divide_int);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "floor_divide_float"),
+        vt_orig->floor_divide_float);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "i_floor_divide"),
+        vt_orig->i_floor_divide);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "i_floor_divide_int"),
+        vt_orig->i_floor_divide_int);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "i_floor_divide_float"),
+        vt_orig->i_floor_divide_float);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "modulus"),
+        vt_orig->modulus);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "modulus_int"),
+        vt_orig->modulus_int);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "modulus_float"),
+        vt_orig->modulus_float);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "i_modulus"),
+        vt_orig->i_modulus);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "i_modulus_int"),
+        vt_orig->i_modulus_int);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "i_modulus_float"),
+        vt_orig->i_modulus_float);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "absolute"),
+        vt_orig->absolute);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "neg"),
+        vt_orig->neg);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "is_equal"),
+        vt_orig->is_equal);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "is_equal_num"),
+        vt_orig->is_equal_num);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "is_equal_string"),
+        vt_orig->is_equal_string);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "is_same"),
+        vt_orig->is_same);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "cmp"),
+        vt_orig->cmp);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "cmp_num"),
+        vt_orig->cmp_num);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "cmp_string"),
+        vt_orig->cmp_string);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "cmp_pmc"),
+        vt_orig->cmp_pmc);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "logical_or"),
+        vt_orig->logical_or);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "logical_and"),
+        vt_orig->logical_and);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "logical_xor"),
+        vt_orig->logical_xor);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "logical_not"),
+        vt_orig->logical_not);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "concatenate"),
+        vt_orig->concatenate);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "concatenate_str"),
+        vt_orig->concatenate_str);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "i_concatenate"),
+        vt_orig->i_concatenate);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "i_concatenate_str"),
+        vt_orig->i_concatenate_str);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "repeat"),
+        vt_orig->repeat);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "repeat_int"),
+        vt_orig->repeat_int);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "i_repeat"),
+        vt_orig->i_repeat);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "i_repeat_int"),
+        vt_orig->i_repeat_int);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "substr"),
+        vt_orig->substr);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "substr_str"),
+        vt_orig->substr_str);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "exists_keyed"),
+        vt_orig->exists_keyed);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "exists_keyed_int"),
+        vt_orig->exists_keyed_int);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "exists_keyed_str"),
+        vt_orig->exists_keyed_str);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "defined_keyed"),
+        vt_orig->defined_keyed);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "defined_keyed_int"),
+        vt_orig->defined_keyed_int);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "defined_keyed_str"),
+        vt_orig->defined_keyed_str);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "delete_keyed"),
+        vt_orig->delete_keyed);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "delete_keyed_int"),
+        vt_orig->delete_keyed_int);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "delete_keyed_str"),
+        vt_orig->delete_keyed_str);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "invoke"),
+        vt_orig->invoke);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "can"),
+        vt_orig->can);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "does_pmc"),
+        vt_orig->does_pmc);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "does"),
+        vt_orig->does);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "isa_pmc"),
+        vt_orig->isa_pmc);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "isa"),
+        vt_orig->isa);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "get_attr_str"),
+        vt_orig->get_attr_str);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "get_attr_keyed"),
+        vt_orig->get_attr_keyed);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "set_attr_str"),
+        vt_orig->set_attr_str);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "set_attr_keyed"),
+        vt_orig->set_attr_keyed);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "add_parent"),
+        vt_orig->add_parent);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "remove_parent"),
+        vt_orig->remove_parent);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "add_role"),
+        vt_orig->add_role);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "remove_role"),
+        vt_orig->remove_role);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "add_attribute"),
+        vt_orig->add_attribute);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "remove_attribute"),
+        vt_orig->remove_attribute);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "add_method"),
+        vt_orig->add_method);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "remove_method"),
+        vt_orig->remove_method);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "add_vtable_override"),
+        vt_orig->add_vtable_override);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "remove_vtable_override"),
+        vt_orig->remove_vtable_override);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "inspect_str"),
+        vt_orig->inspect_str);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "freeze"),
+        vt_orig->freeze);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "thaw"),
+        vt_orig->thaw);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "thawfinish"),
+        vt_orig->thawfinish);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "visit"),
+        vt_orig->visit);
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "init_int"),
+        vt_orig->init_int);
+    /* END vtable mapping name original */
 }
 
-/*
- * Stubs
- */
-
 /* BEGIN vtable stubs */
 static
 void stub_init_pmc(PARROT_INTERP, PMC* pmc, PMC* initializer) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->init_pmc(interp, pmc, initializer);
+    ((_vtable *)orig_vtable)->init_pmc(interp, pmc, initializer);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, initializer);
@@ -1713,25 +3251,24 @@
                    CONST_STRING(supervisor, "core"),
                    CONST_STRING(supervisor, "init_pmc"));
 
-
     return;
 }
 
 static
 PMC* stub_instantiate(PARROT_INTERP, PMC* pmc, PMC* sig) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->instantiate(interp, pmc, sig);
+    ret = ((_vtable *)orig_vtable)->instantiate(interp, pmc, sig);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, sig);
@@ -1746,24 +3283,23 @@
                    CONST_STRING(supervisor, "core"),
                    CONST_STRING(supervisor, "instantiate"));
 
-
     return ret;
 }
 
 static
 void stub_morph(PARROT_INTERP, PMC* pmc, PMC* type) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->morph(interp, pmc, type);
+    ((_vtable *)orig_vtable)->morph(interp, pmc, type);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, type);
@@ -1781,25 +3317,24 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "morph"));
 
-
     return;
 }
 
 static
 PMC* stub_getprop(PARROT_INTERP, PMC* pmc, STRING* key) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->getprop(interp, pmc, key);
+    ret = ((_vtable *)orig_vtable)->getprop(interp, pmc, key);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_String);
@@ -1816,24 +3351,23 @@
                    CONST_STRING(supervisor, "core"),
                    CONST_STRING(supervisor, "getprop"));
 
-
     return ret;
 }
 
 static
 void stub_setprop(PARROT_INTERP, PMC* pmc, STRING* key, PMC* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->setprop(interp, pmc, key, value);
+    ((_vtable *)orig_vtable)->setprop(interp, pmc, key, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_String);
@@ -1851,24 +3385,23 @@
                    CONST_STRING(supervisor, "core"),
                    CONST_STRING(supervisor, "setprop"));
 
-
     return;
 }
 
 static
 void stub_delprop(PARROT_INTERP, PMC* pmc, STRING* key) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->delprop(interp, pmc, key);
+    ((_vtable *)orig_vtable)->delprop(interp, pmc, key);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_String);
@@ -1885,25 +3418,24 @@
                    CONST_STRING(supervisor, "core"),
                    CONST_STRING(supervisor, "delprop"));
 
-
     return;
 }
 
 static
 PMC* stub_clone_pmc(PARROT_INTERP, PMC* pmc, PMC* args) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->clone_pmc(interp, pmc, args);
+    ret = ((_vtable *)orig_vtable)->clone_pmc(interp, pmc, args);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, args);
@@ -1918,25 +3450,24 @@
                    CONST_STRING(supervisor, "core"),
                    CONST_STRING(supervisor, "clone_pmc"));
 
-
     return ret;
 }
 
 static
 PMC* stub_find_method(PARROT_INTERP, PMC* pmc, STRING* method_name) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->find_method(interp, pmc, method_name);
+    ret = ((_vtable *)orig_vtable)->find_method(interp, pmc, method_name);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_String);
@@ -1953,25 +3484,24 @@
                    CONST_STRING(supervisor, "core"),
                    CONST_STRING(supervisor, "find_method"));
 
-
     return ret;
 }
 
 static
 INTVAL stub_get_integer_keyed(PARROT_INTERP, PMC* pmc, PMC* key) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     INTVAL ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->get_integer_keyed(interp, pmc, key);
+    ret = ((_vtable *)orig_vtable)->get_integer_keyed(interp, pmc, key);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, key);
@@ -1986,25 +3516,24 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "get_integer_keyed"));
 
-
     return ret;
 }
 
 static
 INTVAL stub_get_integer_keyed_int(PARROT_INTERP, PMC* pmc, INTVAL key) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     INTVAL ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->get_integer_keyed_int(interp, pmc, key);
+    ret = ((_vtable *)orig_vtable)->get_integer_keyed_int(interp, pmc, key);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -2021,25 +3550,24 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "get_integer_keyed_int"));
 
-
     return ret;
 }
 
 static
 INTVAL stub_get_integer_keyed_str(PARROT_INTERP, PMC* pmc, STRING* key) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     INTVAL ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->get_integer_keyed_str(interp, pmc, key);
+    ret = ((_vtable *)orig_vtable)->get_integer_keyed_str(interp, pmc, key);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_String);
@@ -2056,25 +3584,24 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "get_integer_keyed_str"));
 
-
     return ret;
 }
 
 static
 FLOATVAL stub_get_number_keyed(PARROT_INTERP, PMC* pmc, PMC* key) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     FLOATVAL ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->get_number_keyed(interp, pmc, key);
+    ret = ((_vtable *)orig_vtable)->get_number_keyed(interp, pmc, key);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, key);
@@ -2089,25 +3616,24 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "get_number_keyed"));
 
-
     return ret;
 }
 
 static
 FLOATVAL stub_get_number_keyed_int(PARROT_INTERP, PMC* pmc, INTVAL key) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     FLOATVAL ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->get_number_keyed_int(interp, pmc, key);
+    ret = ((_vtable *)orig_vtable)->get_number_keyed_int(interp, pmc, key);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -2124,25 +3650,24 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "get_number_keyed_int"));
 
-
     return ret;
 }
 
 static
 FLOATVAL stub_get_number_keyed_str(PARROT_INTERP, PMC* pmc, STRING* key) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     FLOATVAL ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->get_number_keyed_str(interp, pmc, key);
+    ret = ((_vtable *)orig_vtable)->get_number_keyed_str(interp, pmc, key);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_String);
@@ -2159,25 +3684,24 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "get_number_keyed_str"));
 
-
     return ret;
 }
 
 static
 STRING* stub_get_string_keyed(PARROT_INTERP, PMC* pmc, PMC* key) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     STRING* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->get_string_keyed(interp, pmc, key);
+    ret = ((_vtable *)orig_vtable)->get_string_keyed(interp, pmc, key);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, key);
@@ -2192,25 +3716,24 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "get_string_keyed"));
 
-
     return ret;
 }
 
 static
 STRING* stub_get_string_keyed_int(PARROT_INTERP, PMC* pmc, INTVAL key) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     STRING* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->get_string_keyed_int(interp, pmc, key);
+    ret = ((_vtable *)orig_vtable)->get_string_keyed_int(interp, pmc, key);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -2227,25 +3750,24 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "get_string_keyed_int"));
 
-
     return ret;
 }
 
 static
 STRING* stub_get_string_keyed_str(PARROT_INTERP, PMC* pmc, STRING* key) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     STRING* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->get_string_keyed_str(interp, pmc, key);
+    ret = ((_vtable *)orig_vtable)->get_string_keyed_str(interp, pmc, key);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_String);
@@ -2262,25 +3784,24 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "get_string_keyed_str"));
 
-
     return ret;
 }
 
 static
 PMC* stub_get_pmc_keyed(PARROT_INTERP, PMC* pmc, PMC* key) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->get_pmc_keyed(interp, pmc, key);
+    ret = ((_vtable *)orig_vtable)->get_pmc_keyed(interp, pmc, key);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, key);
@@ -2295,25 +3816,24 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "get_pmc_keyed"));
 
-
     return ret;
 }
 
 static
 PMC* stub_get_pmc_keyed_int(PARROT_INTERP, PMC* pmc, INTVAL key) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->get_pmc_keyed_int(interp, pmc, key);
+    ret = ((_vtable *)orig_vtable)->get_pmc_keyed_int(interp, pmc, key);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -2330,25 +3850,24 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "get_pmc_keyed_int"));
 
-
     return ret;
 }
 
 static
 PMC* stub_get_pmc_keyed_str(PARROT_INTERP, PMC* pmc, STRING* key) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->get_pmc_keyed_str(interp, pmc, key);
+    ret = ((_vtable *)orig_vtable)->get_pmc_keyed_str(interp, pmc, key);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_String);
@@ -2365,25 +3884,24 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "get_pmc_keyed_str"));
 
-
     return ret;
 }
 
 static
 void* stub_get_pointer_keyed(PARROT_INTERP, PMC* pmc, PMC* key) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     void* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->get_pointer_keyed(interp, pmc, key);
+    ret = ((_vtable *)orig_vtable)->get_pointer_keyed(interp, pmc, key);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, key);
@@ -2398,25 +3916,24 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "get_pointer_keyed"));
 
-
     return ret;
 }
 
 static
 void* stub_get_pointer_keyed_int(PARROT_INTERP, PMC* pmc, INTVAL key) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     void* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->get_pointer_keyed_int(interp, pmc, key);
+    ret = ((_vtable *)orig_vtable)->get_pointer_keyed_int(interp, pmc, key);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -2433,25 +3950,24 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "get_pointer_keyed_int"));
 
-
     return ret;
 }
 
 static
 void* stub_get_pointer_keyed_str(PARROT_INTERP, PMC* pmc, STRING* key) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     void* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->get_pointer_keyed_str(interp, pmc, key);
+    ret = ((_vtable *)orig_vtable)->get_pointer_keyed_str(interp, pmc, key);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_String);
@@ -2468,24 +3984,23 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "get_pointer_keyed_str"));
 
-
     return ret;
 }
 
 static
 void stub_set_integer_native(PARROT_INTERP, PMC* pmc, INTVAL value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->set_integer_native(interp, pmc, value);
+    ((_vtable *)orig_vtable)->set_integer_native(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -2502,24 +4017,23 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "set_integer_native"));
 
-
     return;
 }
 
 static
 void stub_set_integer_keyed(PARROT_INTERP, PMC* pmc, PMC* key, INTVAL value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->set_integer_keyed(interp, pmc, key, value);
+    ((_vtable *)orig_vtable)->set_integer_keyed(interp, pmc, key, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, key);
@@ -2537,24 +4051,23 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "set_integer_keyed"));
 
-
     return;
 }
 
 static
 void stub_set_integer_keyed_int(PARROT_INTERP, PMC* pmc, INTVAL key, INTVAL value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->set_integer_keyed_int(interp, pmc, key, value);
+    ((_vtable *)orig_vtable)->set_integer_keyed_int(interp, pmc, key, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -2574,24 +4087,23 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "set_integer_keyed_int"));
 
-
     return;
 }
 
 static
 void stub_set_integer_keyed_str(PARROT_INTERP, PMC* pmc, STRING* key, INTVAL value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->set_integer_keyed_str(interp, pmc, key, value);
+    ((_vtable *)orig_vtable)->set_integer_keyed_str(interp, pmc, key, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_String);
@@ -2611,24 +4123,23 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "set_integer_keyed_str"));
 
-
     return;
 }
 
 static
 void stub_set_number_native(PARROT_INTERP, PMC* pmc, FLOATVAL value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->set_number_native(interp, pmc, value);
+    ((_vtable *)orig_vtable)->set_number_native(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Float);
@@ -2645,24 +4156,23 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "set_number_native"));
 
-
     return;
 }
 
 static
 void stub_set_number_keyed(PARROT_INTERP, PMC* pmc, PMC* key, FLOATVAL value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->set_number_keyed(interp, pmc, key, value);
+    ((_vtable *)orig_vtable)->set_number_keyed(interp, pmc, key, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, key);
@@ -2680,24 +4190,23 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "set_number_keyed"));
 
-
     return;
 }
 
 static
 void stub_set_number_keyed_int(PARROT_INTERP, PMC* pmc, INTVAL key, FLOATVAL value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->set_number_keyed_int(interp, pmc, key, value);
+    ((_vtable *)orig_vtable)->set_number_keyed_int(interp, pmc, key, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -2717,24 +4226,23 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "set_number_keyed_int"));
 
-
     return;
 }
 
 static
 void stub_set_number_keyed_str(PARROT_INTERP, PMC* pmc, STRING* key, FLOATVAL value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->set_number_keyed_str(interp, pmc, key, value);
+    ((_vtable *)orig_vtable)->set_number_keyed_str(interp, pmc, key, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_String);
@@ -2754,24 +4262,23 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "set_number_keyed_str"));
 
-
     return;
 }
 
 static
 void stub_set_string_native(PARROT_INTERP, PMC* pmc, STRING* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->set_string_native(interp, pmc, value);
+    ((_vtable *)orig_vtable)->set_string_native(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_String);
@@ -2788,24 +4295,23 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "set_string_native"));
 
-
     return;
 }
 
 static
 void stub_assign_string_native(PARROT_INTERP, PMC* pmc, STRING* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->assign_string_native(interp, pmc, value);
+    ((_vtable *)orig_vtable)->assign_string_native(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_String);
@@ -2822,24 +4328,23 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "assign_string_native"));
 
-
     return;
 }
 
 static
 void stub_set_string_keyed(PARROT_INTERP, PMC* pmc, PMC* key, STRING* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->set_string_keyed(interp, pmc, key, value);
+    ((_vtable *)orig_vtable)->set_string_keyed(interp, pmc, key, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, key);
@@ -2857,24 +4362,23 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "set_string_keyed"));
 
-
     return;
 }
 
 static
 void stub_set_string_keyed_int(PARROT_INTERP, PMC* pmc, INTVAL key, STRING* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->set_string_keyed_int(interp, pmc, key, value);
+    ((_vtable *)orig_vtable)->set_string_keyed_int(interp, pmc, key, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -2894,24 +4398,23 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "set_string_keyed_int"));
 
-
     return;
 }
 
 static
 void stub_set_string_keyed_str(PARROT_INTERP, PMC* pmc, STRING* key, STRING* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->set_string_keyed_str(interp, pmc, key, value);
+    ((_vtable *)orig_vtable)->set_string_keyed_str(interp, pmc, key, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_String);
@@ -2931,24 +4434,23 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "set_string_keyed_str"));
 
-
     return;
 }
 
 static
 void stub_set_bool(PARROT_INTERP, PMC* pmc, INTVAL value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->set_bool(interp, pmc, value);
+    ((_vtable *)orig_vtable)->set_bool(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -2965,24 +4467,23 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "set_bool"));
 
-
     return;
 }
 
 static
 void stub_set_pmc(PARROT_INTERP, PMC* pmc, PMC* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->set_pmc(interp, pmc, value);
+    ((_vtable *)orig_vtable)->set_pmc(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, value);
@@ -2997,24 +4498,23 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "set_pmc"));
 
-
     return;
 }
 
 static
 void stub_assign_pmc(PARROT_INTERP, PMC* pmc, PMC* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->assign_pmc(interp, pmc, value);
+    ((_vtable *)orig_vtable)->assign_pmc(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, value);
@@ -3029,24 +4529,23 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "assign_pmc"));
 
-
     return;
 }
 
 static
 void stub_set_pmc_keyed(PARROT_INTERP, PMC* pmc, PMC* key, PMC* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->set_pmc_keyed(interp, pmc, key, value);
+    ((_vtable *)orig_vtable)->set_pmc_keyed(interp, pmc, key, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, key);
@@ -3062,24 +4561,23 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "set_pmc_keyed"));
 
-
     return;
 }
 
 static
 void stub_set_pmc_keyed_int(PARROT_INTERP, PMC* pmc, INTVAL key, PMC* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->set_pmc_keyed_int(interp, pmc, key, value);
+    ((_vtable *)orig_vtable)->set_pmc_keyed_int(interp, pmc, key, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -3097,24 +4595,23 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "set_pmc_keyed_int"));
 
-
     return;
 }
 
 static
 void stub_set_pmc_keyed_str(PARROT_INTERP, PMC* pmc, STRING* key, PMC* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->set_pmc_keyed_str(interp, pmc, key, value);
+    ((_vtable *)orig_vtable)->set_pmc_keyed_str(interp, pmc, key, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_String);
@@ -3132,24 +4629,23 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "set_pmc_keyed_str"));
 
-
     return;
 }
 
 static
 void stub_set_pointer(PARROT_INTERP, PMC* pmc, void* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->set_pointer(interp, pmc, value);
+    ((_vtable *)orig_vtable)->set_pointer(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Pointer);
@@ -3166,24 +4662,23 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "set_pointer"));
 
-
     return;
 }
 
 static
 void stub_set_pointer_keyed(PARROT_INTERP, PMC* pmc, PMC* key, void* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->set_pointer_keyed(interp, pmc, key, value);
+    ((_vtable *)orig_vtable)->set_pointer_keyed(interp, pmc, key, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, key);
@@ -3201,24 +4696,23 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "set_pointer_keyed"));
 
-
     return;
 }
 
 static
 void stub_set_pointer_keyed_int(PARROT_INTERP, PMC* pmc, INTVAL key, void* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->set_pointer_keyed_int(interp, pmc, key, value);
+    ((_vtable *)orig_vtable)->set_pointer_keyed_int(interp, pmc, key, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -3238,24 +4732,23 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "set_pointer_keyed_int"));
 
-
     return;
 }
 
 static
 void stub_set_pointer_keyed_str(PARROT_INTERP, PMC* pmc, STRING* key, void* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->set_pointer_keyed_str(interp, pmc, key, value);
+    ((_vtable *)orig_vtable)->set_pointer_keyed_str(interp, pmc, key, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_String);
@@ -3275,24 +4768,23 @@
                    CONST_STRING(supervisor, "fetch"),
                    CONST_STRING(supervisor, "set_pointer_keyed_str"));
 
-
     return;
 }
 
 static
 void stub_push_integer(PARROT_INTERP, PMC* pmc, INTVAL value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->push_integer(interp, pmc, value);
+    ((_vtable *)orig_vtable)->push_integer(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -3309,24 +4801,23 @@
                    CONST_STRING(supervisor, "fetchsize"),
                    CONST_STRING(supervisor, "push_integer"));
 
-
     return;
 }
 
 static
 void stub_push_float(PARROT_INTERP, PMC* pmc, FLOATVAL value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->push_float(interp, pmc, value);
+    ((_vtable *)orig_vtable)->push_float(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Float);
@@ -3343,24 +4834,23 @@
                    CONST_STRING(supervisor, "fetchsize"),
                    CONST_STRING(supervisor, "push_float"));
 
-
     return;
 }
 
 static
 void stub_push_string(PARROT_INTERP, PMC* pmc, STRING* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->push_string(interp, pmc, value);
+    ((_vtable *)orig_vtable)->push_string(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_String);
@@ -3377,24 +4867,23 @@
                    CONST_STRING(supervisor, "fetchsize"),
                    CONST_STRING(supervisor, "push_string"));
 
-
     return;
 }
 
 static
 void stub_push_pmc(PARROT_INTERP, PMC* pmc, PMC* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->push_pmc(interp, pmc, value);
+    ((_vtable *)orig_vtable)->push_pmc(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, value);
@@ -3409,24 +4898,23 @@
                    CONST_STRING(supervisor, "fetchsize"),
                    CONST_STRING(supervisor, "push_pmc"));
 
-
     return;
 }
 
 static
 void stub_unshift_integer(PARROT_INTERP, PMC* pmc, INTVAL value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->unshift_integer(interp, pmc, value);
+    ((_vtable *)orig_vtable)->unshift_integer(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -3443,24 +4931,23 @@
                    CONST_STRING(supervisor, "fetchsize"),
                    CONST_STRING(supervisor, "unshift_integer"));
 
-
     return;
 }
 
 static
 void stub_unshift_float(PARROT_INTERP, PMC* pmc, FLOATVAL value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->unshift_float(interp, pmc, value);
+    ((_vtable *)orig_vtable)->unshift_float(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Float);
@@ -3477,24 +4964,23 @@
                    CONST_STRING(supervisor, "fetchsize"),
                    CONST_STRING(supervisor, "unshift_float"));
 
-
     return;
 }
 
 static
 void stub_unshift_string(PARROT_INTERP, PMC* pmc, STRING* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->unshift_string(interp, pmc, value);
+    ((_vtable *)orig_vtable)->unshift_string(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_String);
@@ -3511,24 +4997,23 @@
                    CONST_STRING(supervisor, "fetchsize"),
                    CONST_STRING(supervisor, "unshift_string"));
 
-
     return;
 }
 
 static
 void stub_unshift_pmc(PARROT_INTERP, PMC* pmc, PMC* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->unshift_pmc(interp, pmc, value);
+    ((_vtable *)orig_vtable)->unshift_pmc(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, value);
@@ -3543,24 +5028,23 @@
                    CONST_STRING(supervisor, "fetchsize"),
                    CONST_STRING(supervisor, "unshift_pmc"));
 
-
     return;
 }
 
 static
 void stub_splice(PARROT_INTERP, PMC* pmc, PMC* value, INTVAL offset, INTVAL count) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->splice(interp, pmc, value, offset, count);
+    ((_vtable *)orig_vtable)->splice(interp, pmc, value, offset, count);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, value);
@@ -3581,25 +5065,24 @@
                    CONST_STRING(supervisor, "fetchsize"),
                    CONST_STRING(supervisor, "splice"));
 
-
     return;
 }
 
 static
 PMC* stub_add(PARROT_INTERP, PMC* pmc, PMC* value, PMC* dest) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->add(interp, pmc, value, dest);
+    ret = ((_vtable *)orig_vtable)->add(interp, pmc, value, dest);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, value);
@@ -3615,25 +5098,24 @@
                    CONST_STRING(supervisor, "math"),
                    CONST_STRING(supervisor, "add"));
 
-
     return ret;
 }
 
 static
 PMC* stub_add_int(PARROT_INTERP, PMC* pmc, INTVAL value, PMC* dest) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->add_int(interp, pmc, value, dest);
+    ret = ((_vtable *)orig_vtable)->add_int(interp, pmc, value, dest);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -3651,25 +5133,24 @@
                    CONST_STRING(supervisor, "math"),
                    CONST_STRING(supervisor, "add_int"));
 
-
     return ret;
 }
 
 static
 PMC* stub_add_float(PARROT_INTERP, PMC* pmc, FLOATVAL value, PMC* dest) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->add_float(interp, pmc, value, dest);
+    ret = ((_vtable *)orig_vtable)->add_float(interp, pmc, value, dest);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Float);
@@ -3687,24 +5168,23 @@
                    CONST_STRING(supervisor, "math"),
                    CONST_STRING(supervisor, "add_float"));
 
-
     return ret;
 }
 
 static
 void stub_i_add(PARROT_INTERP, PMC* pmc, PMC* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->i_add(interp, pmc, value);
+    ((_vtable *)orig_vtable)->i_add(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, value);
@@ -3722,24 +5202,23 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "i_add"));
 
-
     return;
 }
 
 static
 void stub_i_add_int(PARROT_INTERP, PMC* pmc, INTVAL value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->i_add_int(interp, pmc, value);
+    ((_vtable *)orig_vtable)->i_add_int(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -3759,24 +5238,23 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "i_add_int"));
 
-
     return;
 }
 
 static
 void stub_i_add_float(PARROT_INTERP, PMC* pmc, FLOATVAL value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->i_add_float(interp, pmc, value);
+    ((_vtable *)orig_vtable)->i_add_float(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Float);
@@ -3796,25 +5274,24 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "i_add_float"));
 
-
     return;
 }
 
 static
 PMC* stub_subtract(PARROT_INTERP, PMC* pmc, PMC* value, PMC* dest) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->subtract(interp, pmc, value, dest);
+    ret = ((_vtable *)orig_vtable)->subtract(interp, pmc, value, dest);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, value);
@@ -3830,25 +5307,24 @@
                    CONST_STRING(supervisor, "math"),
                    CONST_STRING(supervisor, "subtract"));
 
-
     return ret;
 }
 
 static
 PMC* stub_subtract_int(PARROT_INTERP, PMC* pmc, INTVAL value, PMC* dest) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->subtract_int(interp, pmc, value, dest);
+    ret = ((_vtable *)orig_vtable)->subtract_int(interp, pmc, value, dest);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -3866,25 +5342,24 @@
                    CONST_STRING(supervisor, "math"),
                    CONST_STRING(supervisor, "subtract_int"));
 
-
     return ret;
 }
 
 static
 PMC* stub_subtract_float(PARROT_INTERP, PMC* pmc, FLOATVAL value, PMC* dest) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->subtract_float(interp, pmc, value, dest);
+    ret = ((_vtable *)orig_vtable)->subtract_float(interp, pmc, value, dest);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Float);
@@ -3902,24 +5377,23 @@
                    CONST_STRING(supervisor, "math"),
                    CONST_STRING(supervisor, "subtract_float"));
 
-
     return ret;
 }
 
 static
 void stub_i_subtract(PARROT_INTERP, PMC* pmc, PMC* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->i_subtract(interp, pmc, value);
+    ((_vtable *)orig_vtable)->i_subtract(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, value);
@@ -3937,24 +5411,23 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "i_subtract"));
 
-
     return;
 }
 
 static
 void stub_i_subtract_int(PARROT_INTERP, PMC* pmc, INTVAL value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->i_subtract_int(interp, pmc, value);
+    ((_vtable *)orig_vtable)->i_subtract_int(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -3974,24 +5447,23 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "i_subtract_int"));
 
-
     return;
 }
 
 static
 void stub_i_subtract_float(PARROT_INTERP, PMC* pmc, FLOATVAL value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->i_subtract_float(interp, pmc, value);
+    ((_vtable *)orig_vtable)->i_subtract_float(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Float);
@@ -4011,25 +5483,24 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "i_subtract_float"));
 
-
     return;
 }
 
 static
 PMC* stub_multiply(PARROT_INTERP, PMC* pmc, PMC* value, PMC* dest) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->multiply(interp, pmc, value, dest);
+    ret = ((_vtable *)orig_vtable)->multiply(interp, pmc, value, dest);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, value);
@@ -4045,25 +5516,24 @@
                    CONST_STRING(supervisor, "math"),
                    CONST_STRING(supervisor, "multiply"));
 
-
     return ret;
 }
 
 static
 PMC* stub_multiply_int(PARROT_INTERP, PMC* pmc, INTVAL value, PMC* dest) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->multiply_int(interp, pmc, value, dest);
+    ret = ((_vtable *)orig_vtable)->multiply_int(interp, pmc, value, dest);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -4081,25 +5551,24 @@
                    CONST_STRING(supervisor, "math"),
                    CONST_STRING(supervisor, "multiply_int"));
 
-
     return ret;
 }
 
 static
 PMC* stub_multiply_float(PARROT_INTERP, PMC* pmc, FLOATVAL value, PMC* dest) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->multiply_float(interp, pmc, value, dest);
+    ret = ((_vtable *)orig_vtable)->multiply_float(interp, pmc, value, dest);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Float);
@@ -4117,24 +5586,23 @@
                    CONST_STRING(supervisor, "math"),
                    CONST_STRING(supervisor, "multiply_float"));
 
-
     return ret;
 }
 
 static
 void stub_i_multiply(PARROT_INTERP, PMC* pmc, PMC* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->i_multiply(interp, pmc, value);
+    ((_vtable *)orig_vtable)->i_multiply(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, value);
@@ -4152,24 +5620,23 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "i_multiply"));
 
-
     return;
 }
 
 static
 void stub_i_multiply_int(PARROT_INTERP, PMC* pmc, INTVAL value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->i_multiply_int(interp, pmc, value);
+    ((_vtable *)orig_vtable)->i_multiply_int(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -4189,24 +5656,23 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "i_multiply_int"));
 
-
     return;
 }
 
 static
 void stub_i_multiply_float(PARROT_INTERP, PMC* pmc, FLOATVAL value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->i_multiply_float(interp, pmc, value);
+    ((_vtable *)orig_vtable)->i_multiply_float(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Float);
@@ -4226,25 +5692,24 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "i_multiply_float"));
 
-
     return;
 }
 
 static
 PMC* stub_divide(PARROT_INTERP, PMC* pmc, PMC* value, PMC* dest) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->divide(interp, pmc, value, dest);
+    ret = ((_vtable *)orig_vtable)->divide(interp, pmc, value, dest);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, value);
@@ -4260,25 +5725,24 @@
                    CONST_STRING(supervisor, "math"),
                    CONST_STRING(supervisor, "divide"));
 
-
     return ret;
 }
 
 static
 PMC* stub_divide_int(PARROT_INTERP, PMC* pmc, INTVAL value, PMC* dest) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->divide_int(interp, pmc, value, dest);
+    ret = ((_vtable *)orig_vtable)->divide_int(interp, pmc, value, dest);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -4296,25 +5760,24 @@
                    CONST_STRING(supervisor, "math"),
                    CONST_STRING(supervisor, "divide_int"));
 
-
     return ret;
 }
 
 static
 PMC* stub_divide_float(PARROT_INTERP, PMC* pmc, FLOATVAL value, PMC* dest) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->divide_float(interp, pmc, value, dest);
+    ret = ((_vtable *)orig_vtable)->divide_float(interp, pmc, value, dest);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Float);
@@ -4332,24 +5795,23 @@
                    CONST_STRING(supervisor, "math"),
                    CONST_STRING(supervisor, "divide_float"));
 
-
     return ret;
 }
 
 static
 void stub_i_divide(PARROT_INTERP, PMC* pmc, PMC* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->i_divide(interp, pmc, value);
+    ((_vtable *)orig_vtable)->i_divide(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, value);
@@ -4367,24 +5829,23 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "i_divide"));
 
-
     return;
 }
 
 static
 void stub_i_divide_int(PARROT_INTERP, PMC* pmc, INTVAL value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->i_divide_int(interp, pmc, value);
+    ((_vtable *)orig_vtable)->i_divide_int(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -4404,24 +5865,23 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "i_divide_int"));
 
-
     return;
 }
 
 static
 void stub_i_divide_float(PARROT_INTERP, PMC* pmc, FLOATVAL value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->i_divide_float(interp, pmc, value);
+    ((_vtable *)orig_vtable)->i_divide_float(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Float);
@@ -4441,25 +5901,24 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "i_divide_float"));
 
-
     return;
 }
 
 static
 PMC* stub_floor_divide(PARROT_INTERP, PMC* pmc, PMC* value, PMC* dest) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->floor_divide(interp, pmc, value, dest);
+    ret = ((_vtable *)orig_vtable)->floor_divide(interp, pmc, value, dest);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, value);
@@ -4475,25 +5934,24 @@
                    CONST_STRING(supervisor, "math"),
                    CONST_STRING(supervisor, "floor_divide"));
 
-
     return ret;
 }
 
 static
 PMC* stub_floor_divide_int(PARROT_INTERP, PMC* pmc, INTVAL value, PMC* dest) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->floor_divide_int(interp, pmc, value, dest);
+    ret = ((_vtable *)orig_vtable)->floor_divide_int(interp, pmc, value, dest);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -4511,25 +5969,24 @@
                    CONST_STRING(supervisor, "math"),
                    CONST_STRING(supervisor, "floor_divide_int"));
 
-
     return ret;
 }
 
 static
 PMC* stub_floor_divide_float(PARROT_INTERP, PMC* pmc, FLOATVAL value, PMC* dest) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->floor_divide_float(interp, pmc, value, dest);
+    ret = ((_vtable *)orig_vtable)->floor_divide_float(interp, pmc, value, dest);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Float);
@@ -4547,24 +6004,23 @@
                    CONST_STRING(supervisor, "math"),
                    CONST_STRING(supervisor, "floor_divide_float"));
 
-
     return ret;
 }
 
 static
 void stub_i_floor_divide(PARROT_INTERP, PMC* pmc, PMC* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->i_floor_divide(interp, pmc, value);
+    ((_vtable *)orig_vtable)->i_floor_divide(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, value);
@@ -4582,24 +6038,23 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "i_floor_divide"));
 
-
     return;
 }
 
 static
 void stub_i_floor_divide_int(PARROT_INTERP, PMC* pmc, INTVAL value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->i_floor_divide_int(interp, pmc, value);
+    ((_vtable *)orig_vtable)->i_floor_divide_int(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -4619,24 +6074,23 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "i_floor_divide_int"));
 
-
     return;
 }
 
 static
 void stub_i_floor_divide_float(PARROT_INTERP, PMC* pmc, FLOATVAL value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->i_floor_divide_float(interp, pmc, value);
+    ((_vtable *)orig_vtable)->i_floor_divide_float(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Float);
@@ -4656,25 +6110,24 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "i_floor_divide_float"));
 
-
     return;
 }
 
 static
 PMC* stub_modulus(PARROT_INTERP, PMC* pmc, PMC* value, PMC* dest) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->modulus(interp, pmc, value, dest);
+    ret = ((_vtable *)orig_vtable)->modulus(interp, pmc, value, dest);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, value);
@@ -4690,25 +6143,24 @@
                    CONST_STRING(supervisor, "math"),
                    CONST_STRING(supervisor, "modulus"));
 
-
     return ret;
 }
 
 static
 PMC* stub_modulus_int(PARROT_INTERP, PMC* pmc, INTVAL value, PMC* dest) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->modulus_int(interp, pmc, value, dest);
+    ret = ((_vtable *)orig_vtable)->modulus_int(interp, pmc, value, dest);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -4726,25 +6178,24 @@
                    CONST_STRING(supervisor, "math"),
                    CONST_STRING(supervisor, "modulus_int"));
 
-
     return ret;
 }
 
 static
 PMC* stub_modulus_float(PARROT_INTERP, PMC* pmc, FLOATVAL value, PMC* dest) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->modulus_float(interp, pmc, value, dest);
+    ret = ((_vtable *)orig_vtable)->modulus_float(interp, pmc, value, dest);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Float);
@@ -4762,24 +6213,23 @@
                    CONST_STRING(supervisor, "math"),
                    CONST_STRING(supervisor, "modulus_float"));
 
-
     return ret;
 }
 
 static
 void stub_i_modulus(PARROT_INTERP, PMC* pmc, PMC* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->i_modulus(interp, pmc, value);
+    ((_vtable *)orig_vtable)->i_modulus(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, value);
@@ -4797,24 +6247,23 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "i_modulus"));
 
-
     return;
 }
 
 static
 void stub_i_modulus_int(PARROT_INTERP, PMC* pmc, INTVAL value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->i_modulus_int(interp, pmc, value);
+    ((_vtable *)orig_vtable)->i_modulus_int(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -4834,24 +6283,23 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "i_modulus_int"));
 
-
     return;
 }
 
 static
 void stub_i_modulus_float(PARROT_INTERP, PMC* pmc, FLOATVAL value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->i_modulus_float(interp, pmc, value);
+    ((_vtable *)orig_vtable)->i_modulus_float(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Float);
@@ -4871,25 +6319,24 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "i_modulus_float"));
 
-
     return;
 }
 
 static
 PMC* stub_absolute(PARROT_INTERP, PMC* pmc, PMC* dest) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->absolute(interp, pmc, dest);
+    ret = ((_vtable *)orig_vtable)->absolute(interp, pmc, dest);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, dest);
@@ -4904,25 +6351,24 @@
                    CONST_STRING(supervisor, "math"),
                    CONST_STRING(supervisor, "absolute"));
 
-
     return ret;
 }
 
 static
 PMC* stub_neg(PARROT_INTERP, PMC* pmc, PMC* dest) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->neg(interp, pmc, dest);
+    ret = ((_vtable *)orig_vtable)->neg(interp, pmc, dest);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, dest);
@@ -4937,25 +6383,24 @@
                    CONST_STRING(supervisor, "math"),
                    CONST_STRING(supervisor, "neg"));
 
-
     return ret;
 }
 
 static
 INTVAL stub_is_equal(PARROT_INTERP, PMC* pmc, PMC* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     INTVAL ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->is_equal(interp, pmc, value);
+    ret = ((_vtable *)orig_vtable)->is_equal(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, value);
@@ -4970,25 +6415,24 @@
                    CONST_STRING(supervisor, "cmp"),
                    CONST_STRING(supervisor, "is_equal"));
 
-
     return ret;
 }
 
 static
 INTVAL stub_is_equal_num(PARROT_INTERP, PMC* pmc, PMC* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     INTVAL ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->is_equal_num(interp, pmc, value);
+    ret = ((_vtable *)orig_vtable)->is_equal_num(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, value);
@@ -5003,25 +6447,24 @@
                    CONST_STRING(supervisor, "cmp"),
                    CONST_STRING(supervisor, "is_equal_num"));
 
-
     return ret;
 }
 
 static
 INTVAL stub_is_equal_string(PARROT_INTERP, PMC* pmc, PMC* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     INTVAL ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->is_equal_string(interp, pmc, value);
+    ret = ((_vtable *)orig_vtable)->is_equal_string(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, value);
@@ -5036,25 +6479,24 @@
                    CONST_STRING(supervisor, "cmp"),
                    CONST_STRING(supervisor, "is_equal_string"));
 
-
     return ret;
 }
 
 static
 INTVAL stub_is_same(PARROT_INTERP, PMC* pmc, PMC* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     INTVAL ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->is_same(interp, pmc, value);
+    ret = ((_vtable *)orig_vtable)->is_same(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, value);
@@ -5069,25 +6511,24 @@
                    CONST_STRING(supervisor, "cmp"),
                    CONST_STRING(supervisor, "is_same"));
 
-
     return ret;
 }
 
 static
 INTVAL stub_cmp(PARROT_INTERP, PMC* pmc, PMC* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     INTVAL ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->cmp(interp, pmc, value);
+    ret = ((_vtable *)orig_vtable)->cmp(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, value);
@@ -5102,25 +6543,24 @@
                    CONST_STRING(supervisor, "cmp"),
                    CONST_STRING(supervisor, "cmp"));
 
-
     return ret;
 }
 
 static
 INTVAL stub_cmp_num(PARROT_INTERP, PMC* pmc, PMC* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     INTVAL ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->cmp_num(interp, pmc, value);
+    ret = ((_vtable *)orig_vtable)->cmp_num(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, value);
@@ -5135,25 +6575,24 @@
                    CONST_STRING(supervisor, "cmp"),
                    CONST_STRING(supervisor, "cmp_num"));
 
-
     return ret;
 }
 
 static
 INTVAL stub_cmp_string(PARROT_INTERP, PMC* pmc, PMC* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     INTVAL ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->cmp_string(interp, pmc, value);
+    ret = ((_vtable *)orig_vtable)->cmp_string(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, value);
@@ -5168,25 +6607,24 @@
                    CONST_STRING(supervisor, "cmp"),
                    CONST_STRING(supervisor, "cmp_string"));
 
-
     return ret;
 }
 
 static
 PMC* stub_cmp_pmc(PARROT_INTERP, PMC* pmc, PMC* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->cmp_pmc(interp, pmc, value);
+    ret = ((_vtable *)orig_vtable)->cmp_pmc(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, value);
@@ -5201,25 +6639,24 @@
                    CONST_STRING(supervisor, "cmp"),
                    CONST_STRING(supervisor, "cmp_pmc"));
 
-
     return ret;
 }
 
 static
 PMC* stub_logical_or(PARROT_INTERP, PMC* pmc, PMC* value, PMC* dest) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->logical_or(interp, pmc, value, dest);
+    ret = ((_vtable *)orig_vtable)->logical_or(interp, pmc, value, dest);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, value);
@@ -5235,25 +6672,24 @@
                    CONST_STRING(supervisor, "cmp"),
                    CONST_STRING(supervisor, "logical_or"));
 
-
     return ret;
 }
 
 static
 PMC* stub_logical_and(PARROT_INTERP, PMC* pmc, PMC* value, PMC* dest) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->logical_and(interp, pmc, value, dest);
+    ret = ((_vtable *)orig_vtable)->logical_and(interp, pmc, value, dest);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, value);
@@ -5269,25 +6705,24 @@
                    CONST_STRING(supervisor, "cmp"),
                    CONST_STRING(supervisor, "logical_and"));
 
-
     return ret;
 }
 
 static
 PMC* stub_logical_xor(PARROT_INTERP, PMC* pmc, PMC* value, PMC* dest) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->logical_xor(interp, pmc, value, dest);
+    ret = ((_vtable *)orig_vtable)->logical_xor(interp, pmc, value, dest);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, value);
@@ -5303,25 +6738,24 @@
                    CONST_STRING(supervisor, "cmp"),
                    CONST_STRING(supervisor, "logical_xor"));
 
-
     return ret;
 }
 
 static
 PMC* stub_logical_not(PARROT_INTERP, PMC* pmc, PMC* dest) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->logical_not(interp, pmc, dest);
+    ret = ((_vtable *)orig_vtable)->logical_not(interp, pmc, dest);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, dest);
@@ -5336,25 +6770,24 @@
                    CONST_STRING(supervisor, "cmp"),
                    CONST_STRING(supervisor, "logical_not"));
 
-
     return ret;
 }
 
 static
 PMC* stub_concatenate(PARROT_INTERP, PMC* pmc, PMC* value, PMC* dest) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->concatenate(interp, pmc, value, dest);
+    ret = ((_vtable *)orig_vtable)->concatenate(interp, pmc, value, dest);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, value);
@@ -5370,25 +6803,24 @@
                    CONST_STRING(supervisor, "string"),
                    CONST_STRING(supervisor, "concatenate"));
 
-
     return ret;
 }
 
 static
 PMC* stub_concatenate_str(PARROT_INTERP, PMC* pmc, STRING* value, PMC* dest) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->concatenate_str(interp, pmc, value, dest);
+    ret = ((_vtable *)orig_vtable)->concatenate_str(interp, pmc, value, dest);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_String);
@@ -5406,24 +6838,23 @@
                    CONST_STRING(supervisor, "string"),
                    CONST_STRING(supervisor, "concatenate_str"));
 
-
     return ret;
 }
 
 static
 void stub_i_concatenate(PARROT_INTERP, PMC* pmc, PMC* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->i_concatenate(interp, pmc, value);
+    ((_vtable *)orig_vtable)->i_concatenate(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, value);
@@ -5441,24 +6872,23 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "i_concatenate"));
 
-
     return;
 }
 
 static
 void stub_i_concatenate_str(PARROT_INTERP, PMC* pmc, STRING* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->i_concatenate_str(interp, pmc, value);
+    ((_vtable *)orig_vtable)->i_concatenate_str(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_String);
@@ -5478,25 +6908,24 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "i_concatenate_str"));
 
-
     return;
 }
 
 static
 PMC* stub_repeat(PARROT_INTERP, PMC* pmc, PMC* value, PMC* dest) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->repeat(interp, pmc, value, dest);
+    ret = ((_vtable *)orig_vtable)->repeat(interp, pmc, value, dest);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, value);
@@ -5512,25 +6941,24 @@
                    CONST_STRING(supervisor, "string"),
                    CONST_STRING(supervisor, "repeat"));
 
-
     return ret;
 }
 
 static
 PMC* stub_repeat_int(PARROT_INTERP, PMC* pmc, INTVAL value, PMC* dest) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->repeat_int(interp, pmc, value, dest);
+    ret = ((_vtable *)orig_vtable)->repeat_int(interp, pmc, value, dest);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -5548,24 +6976,23 @@
                    CONST_STRING(supervisor, "string"),
                    CONST_STRING(supervisor, "repeat_int"));
 
-
     return ret;
 }
 
 static
 void stub_i_repeat(PARROT_INTERP, PMC* pmc, PMC* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->i_repeat(interp, pmc, value);
+    ((_vtable *)orig_vtable)->i_repeat(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, value);
@@ -5583,24 +7010,23 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "i_repeat"));
 
-
     return;
 }
 
 static
 void stub_i_repeat_int(PARROT_INTERP, PMC* pmc, INTVAL value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->i_repeat_int(interp, pmc, value);
+    ((_vtable *)orig_vtable)->i_repeat_int(interp, pmc, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -5620,24 +7046,23 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "i_repeat_int"));
 
-
     return;
 }
 
 static
 void stub_substr(PARROT_INTERP, PMC* pmc, INTVAL offset, INTVAL length, PMC* dest) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->substr(interp, pmc, offset, length, dest);
+    ((_vtable *)orig_vtable)->substr(interp, pmc, offset, length, dest);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -5658,25 +7083,24 @@
                    CONST_STRING(supervisor, "string"),
                    CONST_STRING(supervisor, "substr"));
 
-
     return;
 }
 
 static
 STRING* stub_substr_str(PARROT_INTERP, PMC* pmc, INTVAL offset, INTVAL length) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     STRING* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->substr_str(interp, pmc, offset, length);
+    ret = ((_vtable *)orig_vtable)->substr_str(interp, pmc, offset, length);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -5696,25 +7120,24 @@
                    CONST_STRING(supervisor, "string"),
                    CONST_STRING(supervisor, "substr_str"));
 
-
     return ret;
 }
 
 static
 INTVAL stub_exists_keyed(PARROT_INTERP, PMC* pmc, PMC* key) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     INTVAL ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->exists_keyed(interp, pmc, key);
+    ret = ((_vtable *)orig_vtable)->exists_keyed(interp, pmc, key);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, key);
@@ -5729,25 +7152,24 @@
                    CONST_STRING(supervisor, "exists"),
                    CONST_STRING(supervisor, "exists_keyed"));
 
-
     return ret;
 }
 
 static
 INTVAL stub_exists_keyed_int(PARROT_INTERP, PMC* pmc, INTVAL key) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     INTVAL ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->exists_keyed_int(interp, pmc, key);
+    ret = ((_vtable *)orig_vtable)->exists_keyed_int(interp, pmc, key);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -5764,25 +7186,24 @@
                    CONST_STRING(supervisor, "exists"),
                    CONST_STRING(supervisor, "exists_keyed_int"));
 
-
     return ret;
 }
 
 static
 INTVAL stub_exists_keyed_str(PARROT_INTERP, PMC* pmc, STRING* key) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     INTVAL ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->exists_keyed_str(interp, pmc, key);
+    ret = ((_vtable *)orig_vtable)->exists_keyed_str(interp, pmc, key);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_String);
@@ -5799,25 +7220,24 @@
                    CONST_STRING(supervisor, "exists"),
                    CONST_STRING(supervisor, "exists_keyed_str"));
 
-
     return ret;
 }
 
 static
 INTVAL stub_defined_keyed(PARROT_INTERP, PMC* pmc, PMC* key) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     INTVAL ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->defined_keyed(interp, pmc, key);
+    ret = ((_vtable *)orig_vtable)->defined_keyed(interp, pmc, key);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, key);
@@ -5832,25 +7252,24 @@
                    CONST_STRING(supervisor, "main"),
                    CONST_STRING(supervisor, "defined_keyed"));
 
-
     return ret;
 }
 
 static
 INTVAL stub_defined_keyed_int(PARROT_INTERP, PMC* pmc, INTVAL key) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     INTVAL ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->defined_keyed_int(interp, pmc, key);
+    ret = ((_vtable *)orig_vtable)->defined_keyed_int(interp, pmc, key);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -5867,25 +7286,24 @@
                    CONST_STRING(supervisor, "main"),
                    CONST_STRING(supervisor, "defined_keyed_int"));
 
-
     return ret;
 }
 
 static
 INTVAL stub_defined_keyed_str(PARROT_INTERP, PMC* pmc, STRING* key) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     INTVAL ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->defined_keyed_str(interp, pmc, key);
+    ret = ((_vtable *)orig_vtable)->defined_keyed_str(interp, pmc, key);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_String);
@@ -5902,24 +7320,23 @@
                    CONST_STRING(supervisor, "main"),
                    CONST_STRING(supervisor, "defined_keyed_str"));
 
-
     return ret;
 }
 
 static
 void stub_delete_keyed(PARROT_INTERP, PMC* pmc, PMC* key) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->delete_keyed(interp, pmc, key);
+    ((_vtable *)orig_vtable)->delete_keyed(interp, pmc, key);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, key);
@@ -5934,24 +7351,23 @@
                    CONST_STRING(supervisor, "main"),
                    CONST_STRING(supervisor, "delete_keyed"));
 
-
     return;
 }
 
 static
 void stub_delete_keyed_int(PARROT_INTERP, PMC* pmc, INTVAL key) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->delete_keyed_int(interp, pmc, key);
+    ((_vtable *)orig_vtable)->delete_keyed_int(interp, pmc, key);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -5968,24 +7384,23 @@
                    CONST_STRING(supervisor, "main"),
                    CONST_STRING(supervisor, "delete_keyed_int"));
 
-
     return;
 }
 
 static
 void stub_delete_keyed_str(PARROT_INTERP, PMC* pmc, STRING* key) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->delete_keyed_str(interp, pmc, key);
+    ((_vtable *)orig_vtable)->delete_keyed_str(interp, pmc, key);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_String);
@@ -6002,25 +7417,24 @@
                    CONST_STRING(supervisor, "main"),
                    CONST_STRING(supervisor, "delete_keyed_str"));
 
-
     return;
 }
 
 static
 opcode_t* stub_invoke(PARROT_INTERP, PMC* pmc, void* next) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     opcode_t* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->invoke(interp, pmc, next);
+    ret = ((_vtable *)orig_vtable)->invoke(interp, pmc, next);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Pointer);
@@ -6037,25 +7451,24 @@
                    CONST_STRING(supervisor, "main"),
                    CONST_STRING(supervisor, "invoke"));
 
-
     return ret;
 }
 
 static
 INTVAL stub_can(PARROT_INTERP, PMC* pmc, STRING* method) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     INTVAL ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->can(interp, pmc, method);
+    ret = ((_vtable *)orig_vtable)->can(interp, pmc, method);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_String);
@@ -6072,25 +7485,24 @@
                    CONST_STRING(supervisor, "main"),
                    CONST_STRING(supervisor, "can"));
 
-
     return ret;
 }
 
 static
 INTVAL stub_does_pmc(PARROT_INTERP, PMC* pmc, PMC* role) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     INTVAL ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->does_pmc(interp, pmc, role);
+    ret = ((_vtable *)orig_vtable)->does_pmc(interp, pmc, role);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, role);
@@ -6105,25 +7517,24 @@
                    CONST_STRING(supervisor, "main"),
                    CONST_STRING(supervisor, "does_pmc"));
 
-
     return ret;
 }
 
 static
 INTVAL stub_does(PARROT_INTERP, PMC* pmc, STRING* role) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     INTVAL ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->does(interp, pmc, role);
+    ret = ((_vtable *)orig_vtable)->does(interp, pmc, role);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_String);
@@ -6140,25 +7551,24 @@
                    CONST_STRING(supervisor, "main"),
                    CONST_STRING(supervisor, "does"));
 
-
     return ret;
 }
 
 static
 INTVAL stub_isa_pmc(PARROT_INTERP, PMC* pmc, PMC* _class) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     INTVAL ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->isa_pmc(interp, pmc, _class);
+    ret = ((_vtable *)orig_vtable)->isa_pmc(interp, pmc, _class);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, _class);
@@ -6173,25 +7583,24 @@
                    CONST_STRING(supervisor, "main"),
                    CONST_STRING(supervisor, "isa_pmc"));
 
-
     return ret;
 }
 
 static
 INTVAL stub_isa(PARROT_INTERP, PMC* pmc, STRING* _class) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     INTVAL ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->isa(interp, pmc, _class);
+    ret = ((_vtable *)orig_vtable)->isa(interp, pmc, _class);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_String);
@@ -6208,25 +7617,24 @@
                    CONST_STRING(supervisor, "main"),
                    CONST_STRING(supervisor, "isa"));
 
-
     return ret;
 }
 
 static
 PMC* stub_get_attr_str(PARROT_INTERP, PMC* pmc, STRING* idx) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->get_attr_str(interp, pmc, idx);
+    ret = ((_vtable *)orig_vtable)->get_attr_str(interp, pmc, idx);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_String);
@@ -6243,25 +7651,24 @@
                    CONST_STRING(supervisor, "main"),
                    CONST_STRING(supervisor, "get_attr_str"));
 
-
     return ret;
 }
 
 static
 PMC* stub_get_attr_keyed(PARROT_INTERP, PMC* pmc, PMC* key, STRING* idx) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->get_attr_keyed(interp, pmc, key, idx);
+    ret = ((_vtable *)orig_vtable)->get_attr_keyed(interp, pmc, key, idx);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, key);
@@ -6279,24 +7686,23 @@
                    CONST_STRING(supervisor, "main"),
                    CONST_STRING(supervisor, "get_attr_keyed"));
 
-
     return ret;
 }
 
 static
 void stub_set_attr_str(PARROT_INTERP, PMC* pmc, STRING* idx, PMC* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->set_attr_str(interp, pmc, idx, value);
+    ((_vtable *)orig_vtable)->set_attr_str(interp, pmc, idx, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_String);
@@ -6317,24 +7723,23 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "set_attr_str"));
 
-
     return;
 }
 
 static
 void stub_set_attr_keyed(PARROT_INTERP, PMC* pmc, PMC* key, STRING* idx, PMC* value) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->set_attr_keyed(interp, pmc, key, idx, value);
+    ((_vtable *)orig_vtable)->set_attr_keyed(interp, pmc, key, idx, value);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, key);
@@ -6356,24 +7761,23 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "set_attr_keyed"));
 
-
     return;
 }
 
 static
 void stub_add_parent(PARROT_INTERP, PMC* pmc, PMC* parent) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->add_parent(interp, pmc, parent);
+    ((_vtable *)orig_vtable)->add_parent(interp, pmc, parent);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, parent);
@@ -6391,24 +7795,23 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "add_parent"));
 
-
     return;
 }
 
 static
 void stub_remove_parent(PARROT_INTERP, PMC* pmc, PMC* parent) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->remove_parent(interp, pmc, parent);
+    ((_vtable *)orig_vtable)->remove_parent(interp, pmc, parent);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, parent);
@@ -6426,24 +7829,23 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "remove_parent"));
 
-
     return;
 }
 
 static
 void stub_add_role(PARROT_INTERP, PMC* pmc, PMC* role) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->add_role(interp, pmc, role);
+    ((_vtable *)orig_vtable)->add_role(interp, pmc, role);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, role);
@@ -6461,24 +7863,23 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "add_role"));
 
-
     return;
 }
 
 static
 void stub_remove_role(PARROT_INTERP, PMC* pmc, PMC* role) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->remove_role(interp, pmc, role);
+    ((_vtable *)orig_vtable)->remove_role(interp, pmc, role);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, role);
@@ -6496,24 +7897,23 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "remove_role"));
 
-
     return;
 }
 
 static
 void stub_add_attribute(PARROT_INTERP, PMC* pmc, STRING* name, PMC* type) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->add_attribute(interp, pmc, name, type);
+    ((_vtable *)orig_vtable)->add_attribute(interp, pmc, name, type);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_String);
@@ -6534,24 +7934,23 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "add_attribute"));
 
-
     return;
 }
 
 static
 void stub_remove_attribute(PARROT_INTERP, PMC* pmc, STRING* name) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->remove_attribute(interp, pmc, name);
+    ((_vtable *)orig_vtable)->remove_attribute(interp, pmc, name);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_String);
@@ -6571,24 +7970,23 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "remove_attribute"));
 
-
     return;
 }
 
 static
 void stub_add_method(PARROT_INTERP, PMC* pmc, STRING* method_name, PMC* sub_pmc) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->add_method(interp, pmc, method_name, sub_pmc);
+    ((_vtable *)orig_vtable)->add_method(interp, pmc, method_name, sub_pmc);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_String);
@@ -6609,24 +8007,23 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "add_method"));
 
-
     return;
 }
 
 static
 void stub_remove_method(PARROT_INTERP, PMC* pmc, STRING* method_name) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->remove_method(interp, pmc, method_name);
+    ((_vtable *)orig_vtable)->remove_method(interp, pmc, method_name);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_String);
@@ -6646,24 +8043,23 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "remove_method"));
 
-
     return;
 }
 
 static
 void stub_add_vtable_override(PARROT_INTERP, PMC* pmc, STRING* vtable_name, PMC* sub_pmc) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->add_vtable_override(interp, pmc, vtable_name, sub_pmc);
+    ((_vtable *)orig_vtable)->add_vtable_override(interp, pmc, vtable_name, sub_pmc);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_String);
@@ -6684,24 +8080,23 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "add_vtable_override"));
 
-
     return;
 }
 
 static
 void stub_remove_vtable_override(PARROT_INTERP, PMC* pmc, STRING* vtable_name) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->remove_vtable_override(interp, pmc, vtable_name);
+    ((_vtable *)orig_vtable)->remove_vtable_override(interp, pmc, vtable_name);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_String);
@@ -6721,25 +8116,24 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "remove_vtable_override"));
 
-
     return;
 }
 
 static
 PMC* stub_inspect_str(PARROT_INTERP, PMC* pmc, STRING* what) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
     PMC* ret;
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    ret = orig_vtable->inspect_str(interp, pmc, what);
+    ret = ((_vtable *)orig_vtable)->inspect_str(interp, pmc, what);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_String);
@@ -6756,24 +8150,23 @@
                    CONST_STRING(supervisor, "main"),
                    CONST_STRING(supervisor, "inspect_str"));
 
-
     return ret;
 }
 
 static
 void stub_freeze(PARROT_INTERP, PMC* pmc, PMC* info) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->freeze(interp, pmc, info);
+    ((_vtable *)orig_vtable)->freeze(interp, pmc, info);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, info);
@@ -6788,24 +8181,23 @@
                    CONST_STRING(supervisor, "main"),
                    CONST_STRING(supervisor, "freeze"));
 
-
     return;
 }
 
 static
 void stub_thaw(PARROT_INTERP, PMC* pmc, PMC* info) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->thaw(interp, pmc, info);
+    ((_vtable *)orig_vtable)->thaw(interp, pmc, info);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, info);
@@ -6823,24 +8215,23 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "thaw"));
 
-
     return;
 }
 
 static
 void stub_thawfinish(PARROT_INTERP, PMC* pmc, PMC* info) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->thawfinish(interp, pmc, info);
+    ((_vtable *)orig_vtable)->thawfinish(interp, pmc, info);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, info);
@@ -6858,24 +8249,23 @@
                    CONST_STRING(supervisor, "write"),
                    CONST_STRING(supervisor, "thawfinish"));
 
-
     return;
 }
 
 static
 void stub_visit(PARROT_INTERP, PMC* pmc, PMC* info) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->visit(interp, pmc, info);
+    ((_vtable *)orig_vtable)->visit(interp, pmc, info);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     VTABLE_push_pmc(supervisor, params, info);
@@ -6890,24 +8280,23 @@
                    CONST_STRING(supervisor, "main"),
                    CONST_STRING(supervisor, "visit"));
 
-
     return;
 }
 
 static
 void stub_init_int(PARROT_INTERP, PMC* pmc, INTVAL initializer) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-    orig_vtable->init_int(interp, pmc, initializer);
+    ((_vtable *)orig_vtable)->init_int(interp, pmc, initializer);
 
     VTABLE_push_pmc(supervisor, params, pmc);
     temp = Parrot_pmc_new(supervisor, enum_class_Integer);
@@ -6924,13 +8313,13 @@
                    CONST_STRING(supervisor, "main"),
                    CONST_STRING(supervisor, "init_int"));
 
-
     return;
 }
 
-
 /* END vtable stubs */
 
+/* END OF GENERATED CODE */
+
 /*
 
 =back

Modified: branches/gsoc_instrument/t/dynpmc/instrumentgc.t
==============================================================================
--- branches/gsoc_instrument/t/dynpmc/instrumentgc.t	Sun Jul 11 20:42:32 2010	(r48074)
+++ branches/gsoc_instrument/t/dynpmc/instrumentgc.t	Mon Jul 12 15:32:45 2010	(r48075)
@@ -194,7 +194,7 @@
 
     # Test inserting an individual hook.
     # sample: allocate_pmc_header
-    gc.'insert_gc_hook'('allocate_pmc_header')
+    gc.'insert_hook'('allocate_pmc_header')
     $P0 = gc.'get_instrumented_list'()
     $I0 = $P0
     is($I0, 1, 'Insert: Insert single hook count ok.')
@@ -202,7 +202,7 @@
     is($S0, 'allocate_pmc_header', 'Insert: Insert single hook name ok.')
 
     # Test inserting the same hook again.
-    gc.'insert_gc_hook'('allocate_pmc_header')
+    gc.'insert_hook'('allocate_pmc_header')
     $P0 = gc.'get_instrumented_list'()
     $I0 = $P0
     is($I0, 1, 'Re-insert: Re-inserting single hook count ok.')
@@ -210,12 +210,12 @@
     is($S0, 'allocate_pmc_header', 'Re-insert: Re-inserting single hook name ok.')
 
     # Remove the hook before testing inserting groups.
-    gc.'remove_gc_hook'('allocate_pmc_header')
-    gc.'remove_gc_hook'('allocate_pmc_header')
+    gc.'remove_hook'('allocate_pmc_header')
+    gc.'remove_hook'('allocate_pmc_header')
 
     # Test inserting a group of hooks.
     # sample: free
-    gc.'insert_gc_hook'('free')
+    gc.'insert_hook'('free')
     $P0 = gc.'get_instrumented_list'()
     $P1 = groups['free']
     $I0 = $P0
@@ -231,7 +231,7 @@
     set_addr eh, NON_EXISTENT_OK
     push_eh eh
 
-    gc.'insert_gc_hook'('non-existent')
+    gc.'insert_hook'('non-existent')
 
     ok(0, 'Insert: Non-existent entry fail.')
     goto NON_EXISTENT_END
@@ -253,28 +253,28 @@
 
     # Test removing an individual hook.
     # sample: allocate_pmc_header
-    gc.'insert_gc_hook'('allocate_pmc_header')
-    gc.'remove_gc_hook'('allocate_pmc_header')
+    gc.'insert_hook'('allocate_pmc_header')
+    gc.'remove_hook'('allocate_pmc_header')
     $P0 = gc.'get_instrumented_list'()
     $I0 = $P0
     is($I0, 0, 'Remove: Single hook removal ok.')
 
     # Test insert 2 hooks, remove 1 hook.
     # sample: allocate_pmc_header, free_pmc_header
-    gc.'insert_gc_hook'('allocate_pmc_header')
-    gc.'insert_gc_hook'('free_pmc_header')
-    gc.'remove_gc_hook'('free_pmc_header')
+    gc.'insert_hook'('allocate_pmc_header')
+    gc.'insert_hook'('free_pmc_header')
+    gc.'remove_hook'('free_pmc_header')
     $P0 = gc.'get_instrumented_list'()
     $I0 = $P0
     is($I0, 1, 'Remove2: Removal count ok.')
     $S0 = $P0[0]
     is($S0, 'allocate_pmc_header', 'Remove2: Removal name ok.')
-    gc.'remove_gc_hook'('allocate_pmc_header')
+    gc.'remove_hook'('allocate_pmc_header')
 
     # Test removing of groups.
     # sample: allocate
-    gc.'insert_gc_hook'('allocate')
-    gc.'remove_gc_hook'('allocate')
+    gc.'insert_hook'('allocate')
+    gc.'remove_hook'('allocate')
     $P0 = gc.'get_instrumented_list'()
     $I0 = $P0
     is($I0, 0, 'Remove Group: Removal ok.')
@@ -286,7 +286,7 @@
     set_addr eh, NON_EXISTENT_OK
     push_eh eh
 
-    gc.'remove_gc_hook'('non-existent')
+    gc.'remove_hook'('non-existent')
 
     ok(0, 'Remove: Non-existent removal fail.')
     goto NON_EXISTENT_END
@@ -302,9 +302,9 @@
     set_addr eh, TOO_MANY_OK
     push_eh eh
 
-    gc.'insert_gc_hook'('allocate_pmc_header')
-    gc.'remove_gc_hook'('allocate_pmc_header')
-    gc.'remove_gc_hook'('allocate_pmc_header')
+    gc.'insert_hook'('allocate_pmc_header')
+    gc.'remove_hook'('allocate_pmc_header')
+    gc.'remove_hook'('allocate_pmc_header')
 
     ok(0, 'Remove: Too many removal fail.')
     goto TOO_MANY_END

Modified: branches/gsoc_instrument/tools/build/gen_gc_stubs.pl
==============================================================================
--- branches/gsoc_instrument/tools/build/gen_gc_stubs.pl	Sun Jul 11 20:42:32 2010	(r48074)
+++ branches/gsoc_instrument/tools/build/gen_gc_stubs.pl	Mon Jul 12 15:32:45 2010	(r48075)
@@ -43,10 +43,12 @@
 
 # Extract struct GC_Subsystem.
 $contents =~ /typedef struct GC_Subsystem {(.*)} GC_Subsystem;/;
-my $subsystem = $1;
+my $subsystem      = $1;
 
 # Remove comments.
 $subsystem =~ s/\/\*.*?\*\///g;
+
+# Extract the entries.
 foreach (split /\s*;\s*/, $subsystem) {
     chomp;
 
@@ -81,15 +83,20 @@
         push @prototypes, gen_prototype(@data);
         push @stubs, gen_stub(@data);
 
-        push @entries, $data[1];
+        push @entries, \@data;
     }
 }
 
 my %placeholders = (
-    'gc prototypes' => join('', @prototypes),
-    'gc stubs'      => join('', @stubs),
-    'gc mappings'   => gen_mapping_string(@entries),
-    'gc groupings'  => gen_grouping_string(\%groups, \@entries)
+    'gc struct entries'        => join("\n", map { s/^\s+//;chomp; $_.';'; }
+                                             split(/\s*;\s*/, $subsystem)),
+    'gc prototypes'            => join("\n", map { chomp; $_; } @prototypes),
+    'gc stubs'                 => join("\n", map { chomp; $_; } @stubs),
+    'gc mapping name stubs'    => gen_mapping_name_stubs(@entries),
+    'gc mapping name offset'   => gen_mapping_name_offset(@entries),
+    'gc mapping name original' => gen_mapping_name_original(@entries),
+    'gc mapping group items'   => gen_mapping_group_items(\%groups),
+    'gc mapping item groups'   => gen_mapping_item_groups(@entries)
 );
 
 my @contents = ();
@@ -215,14 +222,14 @@
 
     return <<STUB;
 $ret stub_$name($params) {
-    PMC *instr_gc            = ((InstrumentGC_Subsystem *) interp->gc_sys)->instrument_gc;
+    GC_Subsystem *gc_orig    = ((InstrumentGC_Subsystem *) interp->gc_sys)->original;
     Parrot_Interp supervisor = ((InstrumentGC_Subsystem *) interp->gc_sys)->supervisor;
-    GC_Subsystem *gc_orig;
+
     PMC *event_data;
     PMC *temp;
     PMC *params = Parrot_pmc_new(supervisor, enum_class_ResizablePMCArray);
 $ret_dec
-    GETATTR_InstrumentGC_gc_original(supervisor, instr_gc, gc_orig);
+
    $ret_ret gc_orig->$name($param_list_flat);
 
 $instr_params
@@ -242,67 +249,95 @@
 STUB
 }
 
-sub gen_mapping_string {
+sub gen_mapping_name_stubs {
     my @entries = @_;
-
-    my($name, @orig, @instr, @stubs);
-    foreach $name (@entries) {
-        push @stubs, <<STUBS;
-    parrot_hash_put(interp, instr_hash,
+    return join("\n", map {
+        my $name = @{$_}[1];
+        my $stub = <<STUB;
+    parrot_hash_put(interp, gc_name_stubs,
         CONST_STRING(interp, "$name"),
         stub_$name);
-STUBS
-        push @orig, <<ORIG;
+STUB
+        chomp $stub;
+        $stub;
+    } @entries);
+}
+
+sub gen_mapping_name_original {
+    my @entries = @_;
+    return join("\n", map {
+        my $name = @{$_}[1];
+        my $stub = <<STUB;
     parrot_hash_put(interp, orig_hash,
         CONST_STRING(interp, "$name"),
         gc_orig->$name);
-ORIG
-        push @instr, <<INSTR;
-    parrot_hash_put(interp, entry_hash,
+STUB
+        chomp $stub;
+        $stub;
+    } @entries);
+}
+
+sub gen_mapping_name_offset {
+    my @entries = @_;
+    return join("\n", map {
+        my $name = @{$_}[1];
+        my $stub = <<STUB;
+    parrot_hash_put(interp, instr_hash,
         CONST_STRING(interp, "$name"),
         &(gc_instr->$name));
-INSTR
-    }
-
-    return <<MAPPINGS;
-    /* Build the pointer hash to the stubs. */
-    @stubs
-
-    /* Build the pointer hash to the original. */
-    @orig
-
-    /* Build the pointer hash for name to InstrumentGC_Subsystem entry. */
-    @instr
-MAPPINGS
+STUB
+        chomp $stub;
+        $stub;
+    } @entries);
 }
 
-sub gen_grouping_string {
-    my($groups, $entries) = @_;
-    my($group, $entry);
+sub gen_mapping_group_items {
+    my %groups = %{shift @_};
 
-    my @groups;
-    foreach $group (keys %{$groups}) {
-        my @list = @{$groups->{$group}};
-
-        my $ret .= <<PRE;
-if (Parrot_str_equal(INTERP, name, CONST_STRING(INTERP, "$group"))) {
+    my $key;
+    my @ret;
+    foreach $key (keys %groups) {
+        my $item;
+        my $entry = <<PRE;
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
 PRE
 
-        foreach $entry (@list) {
-            $ret .= <<ENTRY;
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "$entry"));
+        foreach $item (@{$groups{$key}}) {
+            $entry .= <<ENTRY;
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "$item"));
 ENTRY
         }
 
-        $ret .= <<END;
-        }
-END
+        $entry .= <<POST;
+    parrot_hash_put(interp, gc_group_items,
+                    CONST_STRING(interp, "$key"),
+                    temp);
+POST
 
-        push @groups, $ret;
+        chomp $entry;
+        push @ret, $entry;
     }
 
-    return '        '.join('        else ', @groups);
+    return join("\n\n", @ret);
+}
+
+sub gen_mapping_item_groups {
+my @entries = @_;
+    return join("\n", map {
+        my $name = @{$_}[1];
+        my $group = @{$_}[3];
+        my $stub = <<STUB;
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "$group"));
+    parrot_hash_put(interp, gc_item_groups,
+        CONST_STRING(interp, "$name"),
+        temp);
+STUB
+        chomp $stub;
+        $stub;
+    } @entries);
 }
 
 sub fix_params {

Modified: branches/gsoc_instrument/tools/build/gen_vtable_stubs.pl
==============================================================================
--- branches/gsoc_instrument/tools/build/gen_vtable_stubs.pl	Sun Jul 11 20:42:32 2010	(r48074)
+++ branches/gsoc_instrument/tools/build/gen_vtable_stubs.pl	Mon Jul 12 15:32:45 2010	(r48075)
@@ -77,17 +77,18 @@
 
         push @prototypes, gen_prototype(@data);
         push @stubs, gen_stub(@data);
-        push @entries, $data[1];
-
-
+        push @entries, \@data;
     }
 }
 
 my %placeholders = (
-    'vtable prototypes' => join('', @prototypes),
-    'vtable stubs'      => join('', @stubs),
-    'vtable mappings'   => gen_mapping_string(@entries),
-    'vtable groupings'     => gen_grouping_string(\%groups, \@entries)
+    'vtable prototypes'            => join("\n", map { chomp; $_; } @prototypes),
+    'vtable stubs'                 => join("\n", map { chomp; $_; } @stubs),
+    'vtable mapping name stubs'    => gen_mapping_name_stubs(@entries),
+    'vtable mapping name offset'   => gen_mapping_name_offset(@entries),
+    'vtable mapping name original' => gen_mapping_name_original(@entries),
+    'vtable mapping group items'   => gen_mapping_group_items(\%groups),
+    'vtable mapping item groups'   => gen_mapping_item_groups(@entries)
 );
 
 my @contents = ();
@@ -229,17 +230,17 @@
 static
 $ret stub_$name($params) {
     PMC *instr_vt, *data;
-    _vtable *orig_vtable;
+    void *orig_vtable;
     Parrot_Interp supervisor;
     PMC *temp;
     PMC *params = Parrot_pmc_new(interp, enum_class_ResizablePMCArray);
 $ret_dec
-    instr_vt = (PMC *) parrot_hash_get(interp, Instrument_Vtable_Entries, pmc->vtable);
+    instr_vt = (PMC *) parrot_hash_get(interp, vtable_registry, pmc->vtable);
 
-    GETATTR_InstrumentVtable_original_vtable(interp, instr_vt, orig_vtable);
+    GETATTR_InstrumentVtable_original_struct(interp, instr_vt, orig_vtable);
     GETATTR_InstrumentVtable_supervisor(interp, instr_vt, supervisor);
 
-   $ret_ret orig_vtable->$name($param_list_flat);
+   $ret_ret ((_vtable *)orig_vtable)->$name($param_list_flat);
 
 $instr_params
 
@@ -249,79 +250,115 @@
         params);
 
 $events
-
     return$ret_last;
 }
 
 CODE
 }
 
-sub gen_mapping_string {
+sub gen_mapping_name_stubs {
     my @entries = @_;
+    return join("\n", map {
+        my $name = @{$_}[1];
+        my $stub = <<STUB;
+    parrot_hash_put(interp, vtable_name_stubs,
+        CONST_STRING(interp, "$name"),
+        stub_$name);
+STUB
+        chomp $stub;
+        $stub;
+    } @entries);
+}
 
-    my($name, @orig, @instr, @stubs);
-    foreach $name (@entries) {
-        my $orig = <<OFFSET;
-    parrot_hash_put(interp, orig, CONST_STRING(interp, "$name"),
-                orig_vtable->$name);
-OFFSET
-        push @orig, $orig;
-
-        my $instr = <<INSTR;
-    parrot_hash_put(interp, instr, CONST_STRING(interp, "$name"),
-                &(instr_vtable->$name));
-INSTR
-        push @instr, $instr;
-
-        my $stub_entry = <<STUB_ENTRY;
-        parrot_hash_put(interp, stub, CONST_STRING(interp, "$name"),
-                        stub_$name);
-STUB_ENTRY
-        push @stubs, $stub_entry;
-    }
+sub gen_mapping_name_original {
+    my @entries = @_;
+    return join("\n", map {
+        my $name = @{$_}[1];
+        my $stub = <<STUB;
+    parrot_hash_put(interp, orig_hash,
+        CONST_STRING(interp, "$name"),
+        vt_orig->$name);
+STUB
+        chomp $stub;
+        $stub;
+    } @entries);
+}
 
-    return <<MAPPINGS;
-    /* Build mappings for name -> original function.vtable entry */
- at orig
-
-    /* Build mappings for name -> instrumented function.vtable entry. */
- at instr
-
-    /* Build mappings for name -> stub_function if it wasn't done already. */
-    if (parrot_hash_size(interp, stub) == 0) {
- at stubs
-    }
-MAPPINGS
+sub gen_mapping_name_offset {
+    my @entries = @_;
+    return join("\n", map {
+        my $name = @{$_}[1];
+        my $stub = <<STUB;
+    parrot_hash_put(interp, instr_hash,
+        CONST_STRING(interp, "$name"),
+        &(vt_instr->$name));
+STUB
+        chomp $stub;
+        $stub;
+    } @entries);
 }
 
-sub gen_grouping_string {
-    my($groups, $entries) = @_;
-    my($group, $entry);
-
-    my @groups;
-    foreach $group (keys %{$groups}) {
-        my @list = @{$groups->{$group}};
-        $group = lc($group);
+sub gen_mapping_group_items {
+    my %groups = %{shift @_};
 
-        my $ret .= <<PRE;
-if (Parrot_str_equal(INTERP, name, CONST_STRING(INTERP, "$group"))) {
+    my $key;
+    my @ret;
+    foreach $key (keys %groups) {
+        my $item;
+        my $entry = <<PRE;
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
 PRE
 
-        foreach $entry (@list) {
-            $ret .= <<ENTRY;
-           VTABLE_push_string(INTERP, list,
-               CONST_STRING(INTERP, "$entry"));
+        foreach $item (@{$groups{$key}}) {
+            $entry .= <<ENTRY;
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "$item"));
 ENTRY
         }
 
-        $ret .= <<END;
+        $entry .= <<POST;
+    parrot_hash_put(interp, vtable_group_items,
+        CONST_STRING(interp, "$key"),
+        temp);
+POST
+
+        chomp $entry;
+        push @ret, $entry;
+    }
+
+    return join("\n\n", @ret);
+}
+
+sub gen_mapping_item_groups {
+    my @entries = @_;
+
+    my $data;
+    my @ret;
+    foreach $data (@entries) {
+        my $item;
+        my $name = $data->[1];
+        my $entry = <<PRE;
+    temp = Parrot_pmc_new(interp, enum_class_ResizableStringArray);
+PRE
+
+        foreach $item (@{$data->[4]}) {
+            $entry .= <<ENTRY;
+    VTABLE_push_string(interp, temp,
+                       CONST_STRING(interp, "$item"));
+ENTRY
         }
-END
 
-        push @groups, $ret;
+        $entry .= <<POST;
+    parrot_hash_put(interp, vtable_item_groups,
+        CONST_STRING(interp, "$name"),
+        temp);
+POST
+
+        chomp $entry;
+        push @ret, $entry;
     }
 
-    return '        '.join('        else ', @groups);
+    return join("\n\n", @ret);
 }
 
 # Local Variables:


More information about the parrot-commits mailing list