| /wasmtime-44.0.1/crates/core/src/error/ |
| H A D | oom.rs | 17 pub struct OutOfMemory { struct 23 unsafe impl Send for OutOfMemory {} argument 27 unsafe impl Sync for OutOfMemory {} implementation 29 impl fmt::Debug for OutOfMemory { implementation 40 impl fmt::Display for OutOfMemory { implementation 50 impl core::error::Error for OutOfMemory { implementation 57 impl OutOfMemory { impl 65 assert!(mem::size_of::<OutOfMemory>() == mem::size_of::<Error>()); 67 assert!(mem::align_of::<OutOfMemory>() == mem::align_of::<Error>()); 130 impl From<OutOfMemory> for OomOrDynError { [all …]
|
| H A D | boxed.rs | 1 use super::{OutOfMemory, Result}; 14 pub(crate) unsafe fn try_alloc(layout: Layout) -> Result<NonNull<u8>, OutOfMemory> { in try_alloc() argument 22 Err(OutOfMemory::new(layout.size())) in try_alloc() 28 pub(crate) fn try_new_uninit_box<T>() -> Result<Box<MaybeUninit<T>>, OutOfMemory> { in try_new_uninit_box() argument
|
| H A D | error.rs | 5 use crate::error::{OutOfMemory, Result}; 136 fn new<E>(mut error: E) -> Result<Self, OutOfMemory> in new() 592 if TypeId::of::<E>() == TypeId::of::<OutOfMemory>() { in new() 597 oom: OutOfMemory, in new() 1496 Oom(&'a OutOfMemory), 1504 Oom(&'a mut OutOfMemory), 1527 assert_send_sync::<OutOfMemory>(); 1605 unsafe fn unchecked_oom(&self) -> &OutOfMemory { in unchecked_oom() argument 1674 let boxed = try_new_uninit_box::<OutOfMemory>()?; in into_boxed_dyn_core_error() 1984 let mut error = Error::from(OutOfMemory::new(5)); in from_oom() [all …]
|
| /wasmtime-44.0.1/crates/core/src/alloc/ |
| H A D | try_clone.rs | 1 use crate::error::OutOfMemory; 10 fn try_clone(&self) -> Result<Self, OutOfMemory>; in try_clone() argument 24 fn try_clone(&self) -> Result<Self, OutOfMemory> { in try_clone() argument 34 fn try_clone(&self) -> Result<Self, OutOfMemory> { in try_clone() argument 44 fn try_clone(&self) -> Result<Self, OutOfMemory> { in try_clone() argument 55 fn try_clone(&self) -> Result<Self, OutOfMemory> { in try_clone() argument 68 fn try_clone(&self) -> Result<Self, OutOfMemory> { in try_clone() argument 78 fn try_clone(&self) -> Result<Self, OutOfMemory> { in try_clone() argument 88 fn try_clone(&self) -> Result<Self, OutOfMemory> { 111 fn try_clone(&self) -> Result<Self, OutOfMemory> { [all …]
|
| H A D | try_collect.rs | 2 use crate::error::OutOfMemory; 32 impl<T> TryFromIterator<T, OutOfMemory> for TryVec<T> { 33 fn try_from_iter<I>(iter: I) -> Result<Self, OutOfMemory> in try_from_iter() 45 impl<T> TryFromIterator<T, OutOfMemory> for Box<[T]> { 46 fn try_from_iter<I>(iter: I) -> Result<Self, OutOfMemory> in try_from_iter() 57 E: From<OutOfMemory>, 73 E: From<OutOfMemory>, 113 use crate::error::{OutOfMemory, Result}; 116 fn test_vec_collect() -> Result<(), OutOfMemory> { in test_vec_collect() 123 fn test_box_collect() -> Result<(), OutOfMemory> { in test_box_collect() [all …]
|
| H A D | boxed.rs | 2 use crate::{alloc::str_ptr_from_slice_ptr, error::OutOfMemory}; 36 fn try_new(value: T) -> Result<Self, OutOfMemory> in try_new() 49 fn try_clone(&self) -> Result<Self, OutOfMemory> { in try_clone() argument 259 Oom(OutOfMemory), 265 pub fn unwrap_oom(&self) -> OutOfMemory { in unwrap_oom() argument 279 impl From<OutOfMemory> for TooFewItemsOrOom { 280 fn from(oom: OutOfMemory) -> Self { in from() 358 Oom(OutOfMemory), 362 fn from(oom: OutOfMemory) -> Self { in from() 390 pub fn flatten(self) -> OutOfMemory { in flatten() argument [all …]
|
| H A D | string.rs | 3 error::OutOfMemory, 16 fn try_clone(&self) -> Result<Self, OutOfMemory> { in try_clone() argument 126 pub fn with_capacity(capacity: usize) -> Result<Self, OutOfMemory> { in with_capacity() argument 147 pub fn reserve(&mut self, additional: usize) -> Result<(), OutOfMemory> { in reserve() argument 150 .map_err(|_| OutOfMemory::new(self.len().saturating_add(additional))) in reserve() 156 pub fn reserve_exact(&mut self, additional: usize) -> Result<(), OutOfMemory> { in reserve_exact() argument 159 .map_err(|_| OutOfMemory::new(self.len().saturating_add(additional))) in reserve_exact() 165 pub fn push(&mut self, c: char) -> Result<(), OutOfMemory> { in push() argument 174 pub fn push_str(&mut self, s: &str) -> Result<(), OutOfMemory> { in push_str() argument 210 pub fn shrink_to_fit(&mut self) -> Result<(), OutOfMemory> { in shrink_to_fit() argument [all …]
|
| H A D | vec.rs | 2 use crate::error::OutOfMemory; 74 fn try_clone(&self) -> Result<Self, OutOfMemory> { in try_clone() argument 93 pub fn with_capacity(capacity: usize) -> Result<Self, OutOfMemory> { in with_capacity() argument 102 pub fn from_elem(elem: T, len: NonZeroUsize) -> Result<Self, OutOfMemory> in from_elem() 120 pub fn reserve(&mut self, additional: usize) -> Result<(), OutOfMemory> { in reserve() argument 122 OutOfMemory::new( in reserve() 155 pub fn push(&mut self, value: T) -> Result<(), OutOfMemory> { in push() argument 262 pub fn shrink_to_fit(&mut self) -> Result<(), OutOfMemory> { in shrink_to_fit() argument 314 pub fn into_boxed_slice(mut self) -> Result<Box<[T]>, OutOfMemory> { in into_boxed_slice() argument 499 use crate::error::OutOfMemory; [all …]
|
| H A D | try_new.rs | 1 use crate::error::OutOfMemory; 17 pub fn try_new<T>(value: T::Value) -> Result<T, OutOfMemory> in try_new() 32 fn try_new(value: Self::Value) -> Result<Self, OutOfMemory> in try_new()
|
| H A D | try_cow.rs | 12 fn try_to_owned(&self) -> Result<Self::Owned, OutOfMemory>; in try_to_owned() argument 18 fn try_to_owned(&self) -> Result<Self::Owned, OutOfMemory> { in try_to_owned() argument 31 fn try_to_owned(&self) -> Result<Self::Owned, OutOfMemory> { in try_to_owned() argument 46 fn try_to_owned(&self) -> Result<Self::Owned, OutOfMemory> { in try_to_owned() argument 98 fn try_clone(&self) -> Result<Self, OutOfMemory> { in try_clone() argument 188 pub fn to_mut(&mut self) -> Result<&mut <B as TryToOwned>::Owned, OutOfMemory> { in to_mut() argument 200 pub fn into_owned(self) -> Result<<B as TryToOwned>::Owned, OutOfMemory> { in into_owned() argument
|
| H A D | arc.rs | 2 use crate::error::OutOfMemory; 12 fn try_new(value: T) -> Result<Self, OutOfMemory> in try_new() 22 OutOfMemory::new(bytes) in try_new()
|
| /wasmtime-44.0.1/crates/core/src/ |
| H A D | alloc.rs | 24 use crate::error::OutOfMemory; 34 unsafe fn try_alloc(layout: Layout) -> Result<NonNull<u8>, OutOfMemory> { in try_alloc() argument 42 Err(OutOfMemory::new(layout.size())) in try_alloc() 59 ) -> Result<NonNull<u8>, OutOfMemory> { in try_realloc() argument 68 Err(OutOfMemory::new(new_size)) in try_realloc() 85 impl<T> PanicOnOom for Result<T, OutOfMemory> {
|
| H A D | slab.rs | 137 use crate::error::OutOfMemory; 265 pub fn with_capacity(capacity: usize) -> Result<Self, OutOfMemory> { in with_capacity() argument 277 pub fn reserve(&mut self, additional: usize) -> Result<(), OutOfMemory> { in reserve() argument 295 fn double_capacity(&mut self) -> Result<(), OutOfMemory> { in double_capacity() argument 366 pub fn alloc(&mut self, value: T) -> Result<Id, OutOfMemory> { in alloc() argument 380 fn alloc_slow(&mut self, value: T) -> Result<Id, OutOfMemory> { in alloc_slow() argument
|
| /wasmtime-44.0.1/crates/wasmtime/src/runtime/store/ |
| H A D | func_refs.rs | 94 ) -> Result<NonNull<VMFuncRef>, OutOfMemory> { in push() argument 100 .map_err(|_| OutOfMemory::new(size_of::<VMFuncRef>()))?; in push() 118 pub fn reserve_storage(&mut self, amt: usize) -> Result<(), OutOfMemory> { in reserve_storage() argument 129 ) -> Result<(), OutOfMemory> { in push_instance_pre_func_refs() argument 141 ) -> Result<(), OutOfMemory> { in push_instance_pre_definitions() argument 161 ) -> Result<NonNull<VMFuncRef>, OutOfMemory> { in push_arc_host() argument 174 ) -> Result<NonNull<VMFuncRef>, OutOfMemory> { in push_box_host() argument
|
| /wasmtime-44.0.1/crates/core/tests/ |
| H A D | tests.rs | 177 assert!(!e.is::<OutOfMemory>()); in is() 183 assert!(!e.is::<OutOfMemory>()); in is() 190 assert!(!e.is::<OutOfMemory>()); in is() 196 assert!(!e.is::<OutOfMemory>()); in is() 200 assert!(e.is::<OutOfMemory>()); in is() 438 .context(OutOfMemory::new(5)); in downcast() 445 .context(OutOfMemory::new(5)); in downcast() 452 .context(OutOfMemory::new(5)); in downcast() 560 assert!(error.is::<OutOfMemory>()); in context_on_oom() 897 let oom = OutOfMemory::new(bytes); in oom_requested_allocation_size() [all …]
|
| /wasmtime-44.0.1/crates/environ/src/collections/ |
| H A D | entity_set.rs | 2 use wasmtime_core::error::OutOfMemory; 26 pub fn with_capacity(capacity: usize) -> Result<Self, OutOfMemory> { in with_capacity() argument 33 pub fn ensure_capacity(&mut self, capacity: usize) -> Result<(), OutOfMemory> { in ensure_capacity() argument 69 pub fn insert(&mut self, k: K) -> Result<bool, OutOfMemory> { in insert() argument
|
| H A D | hash_set.rs | 1 use crate::error::OutOfMemory; 72 pub fn with_capacity(capacity: usize) -> Result<Self, OutOfMemory> { in with_capacity() argument 141 pub fn with_capacity_and_hasher(capacity: usize, hasher: S) -> Result<Self, OutOfMemory> { in with_capacity_and_hasher() argument 149 pub fn reserve(&mut self, additional: usize) -> Result<(), OutOfMemory> { in reserve() argument 151 OutOfMemory::new( in reserve() 179 pub fn insert(&mut self, value: T) -> Result<bool, OutOfMemory> { in insert() argument
|
| H A D | hash_map.rs | 1 use crate::error::OutOfMemory; 28 fn try_clone(&self) -> Result<Self, OutOfMemory> { in try_clone() argument 93 pub fn with_capacity(capacity: usize) -> Result<Self, OutOfMemory> { in with_capacity() argument 172 pub fn with_capacity_and_hasher(capacity: usize, hasher: S) -> Result<Self, OutOfMemory> { in with_capacity_and_hasher() argument 180 pub fn reserve(&mut self, additional: usize) -> Result<(), OutOfMemory> { in reserve() argument 183 OutOfMemory::new( in reserve() 211 pub fn insert(&mut self, key: K, value: V) -> Result<Option<V>, OutOfMemory> { in insert() argument
|
| H A D | index_map.rs | 1 use crate::{collections::TryClone, error::OutOfMemory}; 31 fn try_clone(&self) -> Result<Self, OutOfMemory> { in try_clone() argument 137 pub fn with_capacity(n: usize) -> Result<Self, OutOfMemory> { in with_capacity() argument 242 pub fn split_off(&mut self, at: usize) -> Result<Self, OutOfMemory> in split_off() 257 pub fn reserve(&mut self, additional: usize) -> Result<(), OutOfMemory> { in reserve() argument 260 OutOfMemory::new( in reserve() 273 OutOfMemory::new( in reserve_exact() 318 ) -> Result<(usize, Option<V>), OutOfMemory> in insert_sorted_by() 333 ) -> Result<(usize, Option<V>), OutOfMemory> in insert_sorted_by_key() 349 ) -> Result<(usize, Option<V>), OutOfMemory> { in insert_before() argument [all …]
|
| H A D | primary_map.rs | 1 use crate::error::OutOfMemory; 95 pub fn with_capacity(capacity: usize) -> Result<Self, OutOfMemory> { in with_capacity() argument 173 pub fn push(&mut self, v: V) -> Result<K, OutOfMemory> { in push() argument 189 pub fn reserve(&mut self, additional: usize) -> Result<(), OutOfMemory> { in reserve() argument 194 pub fn reserve_exact(&mut self, additional: usize) -> Result<(), OutOfMemory> { in reserve_exact() argument 225 fn try_extend<I>(&mut self, iter: I) -> Result<(), OutOfMemory> in try_extend()
|
| /wasmtime-44.0.1/crates/fuzzing/tests/oom/ |
| H A D | smoke.rs | 5 use wasmtime::{Result, error::OutOfMemory}; 69 Err(OutOfMemory::new(layout.size()).into()) in smoke_test_disallow_alloc_after_oom() 86 Err(OutOfMemory::new(layout.size()).into()) in smoke_test_allow_alloc_after_oom()
|
| /wasmtime-44.0.1/crates/wasmtime/src/runtime/vm/ |
| H A D | store_box.rs | 1 use crate::error::OutOfMemory; 19 pub fn new(val: T) -> Result<StoreBox<T>, OutOfMemory> { in new() argument
|
| /wasmtime-44.0.1/crates/wasi/src/p3/sockets/ |
| H A D | conv.rs | 164 std::io::ErrorKind::OutOfMemory => Self::OutOfMemory, in from() 206 Errno::NOMEM => Self::OutOfMemory, in from() 207 Errno::NOBUFS => Self::OutOfMemory, in from() 232 crate::sockets::util::ErrorCode::OutOfMemory => Self::OutOfMemory, in from()
|
| /wasmtime-44.0.1/crates/wasmtime/src/runtime/ |
| H A D | type_registry.rs | 7 use crate::error::OutOfMemory; 120 ) -> Result<TypeCollection, OutOfMemory> in register_and_canonicalize_types() 280 fn try_clone(&self) -> Result<Self, OutOfMemory> { in try_clone() argument 466 fn try_clone(&self) -> Result<Self, OutOfMemory> { in try_clone() argument 687 OutOfMemory, in register_module_types() argument 757 ) -> Result<RecGroupEntry, OutOfMemory> { in register_rec_group() 816 ) -> Result<RecGroupEntry, OutOfMemory> { in register_new_rec_group() argument 916 ) -> Result<(), OutOfMemory> { in insert_entry_types() argument 1007 ) -> Result<(), OutOfMemory> { in insert_entry_trampolines() argument 1095 ) -> Result<(), OutOfMemory> { in insert_entry_gc_layouts() argument [all …]
|
| H A D | func.rs | 1 use crate::error::OutOfMemory; 396 ) -> Result<Self, OutOfMemory> { in try_new_() argument 1652 ) -> Result<FuncType, OutOfMemory>; in func_type() argument 1695 ) -> Result<FuncType, OutOfMemory> { in func_type() argument 1738 ) -> Result<FuncType, OutOfMemory> { in func_type() argument 1796 ) -> Result<FuncType, OutOfMemory> { 1828 fn into_func(self, engine: &Engine) -> Result<HostFunc, OutOfMemory>; in into_func() argument 2251 ) -> Result<StoreBox<VMArrayCallHostFuncContext>, OutOfMemory> in vmctx_sync() 2286 ) -> Result<StoreBox<VMArrayCallHostFuncContext>, OutOfMemory> in vmctx_async() 2416 ) -> Result<Self, OutOfMemory> in new_unchecked() [all …]
|