Lines Matching refs:instance

126                         Instance::enter_host_from_wasm(vmctx, |store, instance| {
127 super::$name(store, instance, $($pname),*)
250 instance: InstanceId, in memory_grow()
258 let instance = store.instance_mut(instance); in memory_grow() localVariable
259 let module = instance.env_module(); in memory_grow()
262 let result = instance in memory_grow()
311 instance: InstanceId, in table_grow_func_ref()
321 let mut instance = store.instance_mut(instance); in table_grow_func_ref() localVariable
322 let table_index = instance.env_module().table_index(defined_table_index); in table_grow_func_ref()
324 instance.as_mut().table_element_type(table_index), in table_grow_func_ref()
327 let result = instance in table_grow_func_ref()
341 instance: InstanceId, in table_grow_gc_ref()
351 let (gc_store, mut instance) = store.optional_gc_store_and_instance_mut(instance); in table_grow_gc_ref()
352 let table_index = instance.env_module().table_index(defined_table_index); in table_grow_gc_ref()
354 instance.as_mut().table_element_type(table_index), in table_grow_gc_ref()
358 let result = instance in table_grow_gc_ref()
373 instance: InstanceId, in table_grow_cont_obj()
386 let mut instance = store.instance_mut(instance); in table_grow_cont_obj() localVariable
387 let table_index = instance.env_module().table_index(defined_table_index); in table_grow_cont_obj()
389 instance.as_mut().table_element_type(table_index), in table_grow_cont_obj()
392 let result = instance in table_grow_cont_obj()
405 instance: InstanceId, in table_fill_func_ref()
411 let instance = store.instance_mut(instance); in table_fill_func_ref() localVariable
413 let table = instance.get_defined_table(table_index); in table_fill_func_ref()
428 instance: InstanceId, in table_fill_gc_ref()
434 let (gc_store, instance) = store.optional_gc_store_and_instance_mut(instance); in table_fill_gc_ref()
436 let table = instance.get_defined_table(table_index); in table_fill_gc_ref()
452 instance: InstanceId, in table_fill_cont_obj()
459 let instance = store.instance_mut(instance); in table_fill_cont_obj() localVariable
461 let table = instance.get_defined_table(table_index); in table_fill_cont_obj()
475 instance: InstanceId, in table_copy()
485 let mut instance = store.instance_mut(instance); in table_copy() localVariable
489 let (dst_def_index, dst_instance) = instance in table_copy()
493 let (src_def_index, src_instance) = instance in table_copy()
515 instance: InstanceId, in table_init()
531 instance, in table_init()
544 fn elem_drop(store: &mut dyn VMStore, instance: InstanceId, elem_index: u32) -> Result<()> { in elem_drop()
546 store.instance_mut(instance).elem_drop(elem_index)?; in elem_drop()
553 instance: InstanceId, in memory_copy()
563 .instance_mut(instance) in memory_copy()
570 instance: InstanceId, in memory_fill()
579 .instance_mut(instance) in memory_fill()
586 instance: InstanceId, in memory_init()
596 .instance_mut(instance) in memory_init()
601 fn ref_func(store: &mut dyn VMStore, instance: InstanceId, func_index: u32) -> NonNull<u8> { in ref_func()
602 let (instance, registry) = store.instance_and_module_registry_mut(instance); in ref_func()
603 instance in ref_func()
610 fn data_drop(store: &mut dyn VMStore, instance: InstanceId, data_index: u32) -> Result<()> { in data_drop()
612 store.instance_mut(instance).data_drop(data_index)?; in data_drop()
619 instance: InstanceId, in table_get_lazy_init_func_ref()
624 let (instance, registry) = store.instance_and_module_registry_mut(instance); in table_get_lazy_init_func_ref()
625 let table = instance.get_table_with_lazy_init(registry, table_index, core::iter::once(index)); in table_get_lazy_init_func_ref()
692 instance: InstanceId, in gc_alloc_raw()
706 .instance(instance) in gc_alloc_raw()
776 instance: InstanceId, in get_interned_func_ref()
797 .instance(instance) in get_interned_func_ref()
825 let instance = store.instance(instance_id); in array_new_data() localVariable
829 let data_range = instance.wasm_data_range(data_index); in array_new_data()
830 let shared_ty = instance.engine_type_index(array_type_index); in array_new_data()
843 instance in array_new_data()
865 let (gc_store, instance) = store.optional_gc_store_and_instance_mut(instance_id); in array_new_data()
867 let data = &instance.wasm_data(data_range)[src..][..byte_len]; in array_new_data()
897 let instance = store.instance(instance_id); in array_init_data() localVariable
921 let shared_ty = instance.engine_type_index(array_type_index); in array_init_data()
932 let data_range = instance.wasm_data_range(data_index); in array_init_data()
933 instance in array_init_data()
955 let (gc_store, instance) = store.optional_gc_store_and_instance_mut(instance_id); in array_init_data()
957 let data = &instance.wasm_data(data_range)[src..][..data_len]; in array_init_data()
984 let instance = store.instance(instance_id); in array_new_elem() localVariable
987 let elements = instance.passive_element_segment(&mut storage, elem_index); in array_new_elem()
992 let shared_ty = instance.engine_type_index(array_type_index); in array_new_elem()
1004 let (mut instance, registry) = store.instance_and_module_registry_mut(instance_id); in array_new_elem()
1011 let raw_func_ref = instance.as_mut().get_func_ref(registry, *f); in array_new_elem()
1051 instance: InstanceId, in array_init_elem()
1096 let (mut instance, registry) = store.instance_and_module_registry_mut(instance); in array_init_elem()
1097 let elements = instance.passive_element_segment(&mut storage, elem_index); in array_init_elem()
1111 let raw_func_ref = instance.as_mut().get_func_ref(registry, *f); in array_init_elem()
1117 let mut const_context = ConstEvalContext::new(instance.id(), asyncness); in array_init_elem()
1233 instance: InstanceId, in memory_atomic_notify()
1240 .instance_mut(instance) in memory_atomic_notify()
1249 instance: InstanceId, in memory_atomic_wait32()
1258 .instance_mut(instance) in memory_atomic_wait32()
1267 instance: InstanceId, in memory_atomic_wait64()
1276 .instance_mut(instance) in memory_atomic_wait64()
1360 fn check_malloc(store: &mut dyn VMStore, instance: InstanceId, addr: u32, len: u32) -> Result<()> { in check_malloc()
1361 let instance = store.instance_mut(instance); in check_malloc() localVariable
1362 if let Some(wmemcheck_state) = instance.wmemcheck_state_mut() { in check_malloc()
1383 fn check_free(store: &mut dyn VMStore, instance: InstanceId, addr: u32) -> Result<()> { in check_free()
1384 let instance = store.instance_mut(instance); in check_free() localVariable
1385 if let Some(wmemcheck_state) = instance.wmemcheck_state_mut() { in check_free()
1405 instance: InstanceId, in check_load()
1410 let instance = store.instance_mut(instance); in check_load() localVariable
1411 if let Some(wmemcheck_state) = instance.wmemcheck_state_mut() { in check_load()
1433 instance: InstanceId, in check_store()
1438 let instance = store.instance_mut(instance); in check_store() localVariable
1439 if let Some(wmemcheck_state) = instance.wmemcheck_state_mut() { in check_store()
1459 fn malloc_start(store: &mut dyn VMStore, instance: InstanceId) { in malloc_start()
1460 let instance = store.instance_mut(instance); in malloc_start() localVariable
1461 if let Some(wmemcheck_state) = instance.wmemcheck_state_mut() { in malloc_start()
1468 fn free_start(store: &mut dyn VMStore, instance: InstanceId) { in free_start()
1469 let instance = store.instance_mut(instance); in free_start() localVariable
1470 if let Some(wmemcheck_state) = instance.wmemcheck_state_mut() { in free_start()
1488 fn update_mem_size(store: &mut dyn VMStore, instance: InstanceId, num_pages: u32) { in update_mem_size()
1489 let instance = store.instance_mut(instance); in update_mem_size() localVariable
1490 if let Some(wmemcheck_state) = instance.wmemcheck_state_mut() { in update_mem_size()
1725 instance: InstanceId, in cont_new()
1731 crate::vm::stack_switching::cont_new(store, instance, func, param_count, result_count)?; in cont_new()
1736 fn get_instance_id(_store: &mut dyn VMStore, instance: InstanceId) -> u32 { in get_instance_id()
1737 instance.as_u32() in get_instance_id()