| /wasmtime-44.0.1/crates/wizer/src/component/ |
| H A D | rewrite.rs | 27 match section { in rewrite_component() 53 module_encoder.section(section); in rewrite_component() 85 match section.id { in raw_section() 94 encoder.section(section); in raw_section() 112 section.data, in raw_section() 122 section.data, in raw_section() 148 &mut section, in rewrite() 152 encoder.section(§ion); in rewrite() 194 self, aliases, section, in parse_component_alias_section() 228 self, imports, section, in parse_component_import_section() [all …]
|
| H A D | instrument.rs | 31 for section in component.sections.iter_mut() { in instrument() 32 match section { in instrument() 34 encoder.section(raw); in instrument() 331 accessor_module.section(&self.accessor_types); in finish() 335 accessor_module.section(&self.accessor_code); in finish() 346 encoder.section(&extra_instances); in finish() 351 encoder.section(&self.extra_aliases); in finish() 352 encoder.section(&self.extra_types); in finish() 353 encoder.section(&self.extra_canonicals); in finish() 360 encoder.section(&extra_component_instances); in finish() [all …]
|
| /wasmtime-44.0.1/crates/environ/src/ |
| H A D | address_map.rs | 147 let mut section = Bytes(section); in parse_address_map() localVariable 150 let count = section.read::<U32<LittleEndian>>().ok()?; in parse_address_map() 152 let (offsets, section) = in parse_address_map() 153 object::slice_from_bytes::<U32<LittleEndian>>(section.0, count).ok()?; in parse_address_map() 154 let (positions, section) = in parse_address_map() 155 object::slice_from_bytes::<U32<LittleEndian>>(section, count).ok()?; in parse_address_map() 156 debug_assert!(section.is_empty()); in parse_address_map() 170 pub fn lookup_file_pos(section: &[u8], offset: usize) -> Option<FilePos> { in lookup_file_pos() 171 let (offsets, positions) = parse_address_map(section)?; in lookup_file_pos() 206 section: &'a [u8], in iterate_address_map() [all …]
|
| H A D | stack_map.rs | 11 fn parse(section: &'a [u8]) -> Option<StackMapSection<'a>> { in parse() 12 let mut section = Bytes(section); in parse() localVariable 15 let pc_count = section.read::<U32<LittleEndian>>().ok()?; in parse() 17 let (pcs, section) = in parse() 18 object::slice_from_bytes::<U32<LittleEndian>>(section.0, pc_count).ok()?; in parse() 19 let (pointers_to_stack_map, section) = in parse() 20 object::slice_from_bytes::<U32<LittleEndian>>(section, pc_count).ok()?; in parse() 21 let stack_map_data = object::slice_from_all_bytes::<U32<LittleEndian>>(section).ok()?; in parse() 76 pub fn lookup(pc: u32, section: &'a [u8]) -> Option<StackMap<'a>> { in lookup() 77 StackMapSection::parse(section)?.lookup(pc) in lookup() [all …]
|
| H A D | trap_encoding.rs | 236 pub fn lookup_trap_code(section: &[u8], offset: usize) -> Option<Trap> { in lookup_trap_code() 237 let (offsets, traps) = parse(section)?; in lookup_trap_code() 260 fn parse(section: &[u8]) -> Option<(&[U32<LittleEndian>], &[u8])> { in parse() 261 let mut section = Bytes(section); in parse() localVariable 263 let count = section.read::<U32<LittleEndian>>().ok()?; in parse() 265 let (offsets, traps) = object::slice_from_bytes::<U32<LittleEndian>>(section.0, count).ok()?; in parse() 272 pub fn iterate_traps(section: &[u8]) -> Option<impl Iterator<Item = (u32, Trap)> + '_> { in iterate_traps() 273 let (offsets, traps) = parse(section)?; in iterate_traps()
|
| /wasmtime-44.0.1/tests/misc_testsuite/ |
| H A D | empty.wast | 8 "\00" ;; custom section id 0 9 "\0e" ;; section size 10 "\04name" ;; this is the `name` custom section 21 "\00" ;; custom section id 0 22 "\10" ;; section size 23 "\04name" ;; this is the `name` custom section 36 "\00" ;; custom section id 0 37 "\10" ;; section size 38 "\04name" ;; this is the `name` custom section
|
| H A D | no-panic-on-invalid.wast | 6 "\01\06" ;; type section, 6 bytes 11 "\03\02" ;; function section, 2 bytes 14 "\0a\14" ;; code section, 20 bytes
|
| /wasmtime-44.0.1/crates/wizer/src/ |
| H A D | rewrite.rs | 53 encoder.section(&data_section); in rewrite() 56 for section in module.raw_sections() { in rewrite() 57 match section { in rewrite() 63 encoder.section(s); in rewrite() 80 encoder.section(&memories); in rewrite() 124 encoder.section(&globals); in rewrite() 157 encoder.section(&exports); in rewrite() 188 section.passive([]); in rewrite() 200 add_data_segments(&mut section); in rewrite() 201 encoder.section(§ion); in rewrite() [all …]
|
| H A D | instrument.rs | 68 for section in module.raw_sections() { in instrument() 69 match section.id { in instrument() 100 encoder.section(&exports); in instrument() 106 encoder.section(section); in instrument()
|
| /wasmtime-44.0.1/crates/environ/src/compile/ |
| H A D | stack_maps.rs | 136 let section = obj.add_section( in append_to() localVariable 145 obj.append_section_data(section, &amt.to_le_bytes(), 1); in append_to() 146 obj.append_section_data(section, object::bytes_of_slice(&self.pcs), 1); in append_to() 148 section, in append_to() 152 obj.append_section_data(section, object::bytes_of_slice(&self.stack_map_data), 1); in append_to() 163 let mut section = StackMapSection::default(); in roundtrip() localVariable 166 section.push(*pc, *frame, offsets.iter().copied()); in roundtrip() 173 section.append_to(&mut object); in roundtrip()
|
| H A D | trap_encoding.rs | 58 let section = obj.add_section( in append_to() localVariable 66 obj.append_section_data(section, &amt.to_le_bytes(), 1); in append_to() 67 obj.append_section_data(section, object::bytes_of_slice(&self.offsets), 1); in append_to() 68 obj.append_section_data(section, &self.traps, 1); in append_to()
|
| H A D | address_map.rs | 69 let section = obj.add_section( in append_to() localVariable 77 obj.append_section_data(section, &amt.to_le_bytes(), 1); in append_to() 78 obj.append_section_data(section, object::bytes_of_slice(&self.offsets), 1); in append_to() 79 obj.append_section_data(section, object::bytes_of_slice(&self.positions), 1); in append_to()
|
| /wasmtime-44.0.1/crates/environ/src/fact/ |
| H A D | core_types.rs | 9 pub section: TypeSection, field 19 let idx = self.section.len(); in function() 20 self.section in function()
|
| /wasmtime-44.0.1/crates/fuzzing/src/generators/ |
| H A D | stacks.rs | 161 section(&mut module, types); in wasm() 177 section(&mut module, imports); in wasm() 187 section(&mut module, funcs); in wasm() 198 section(&mut module, mems); in wasm() 219 section(&mut module, globals); in wasm() 226 section(&mut module, exports); in wasm() 234 section(&mut module, elems); in wasm() 392 section(&mut module, code); in wasm() 399 fn section(module: &mut wasm_encoder::Module, section: impl wasm_encoder::Section) { in wasm() function 400 module.section(§ion); in wasm()
|
| /wasmtime-44.0.1/crates/wasi-preview1-component-adapter/ |
| H A D | build.rs | 79 module.section(&types); in build_raw_intrinsics() 87 module.section(&funcs); in build_raw_intrinsics() 109 module.section(&globals); in build_raw_intrinsics() 148 module.section(&RawSection { in build_raw_intrinsics() 197 module.section(&CustomSection { in build_raw_intrinsics() 226 module.section(&CustomSection { in build_raw_intrinsics()
|
| /wasmtime-44.0.1/cranelift/object/src/ |
| H A D | backend.rs | 228 section: SymbolSection::Undefined, in declare_function() 252 section: SymbolSection::Undefined, in declare_anonymous_function() 295 section: SymbolSection::Undefined, in declare_data() 325 section: SymbolSection::Undefined, in declare_anonymous_data() 480 section, in define_data() 511 let section = if self.per_function_section { in define_function_inner() localVariable 524 section, in define_function_inner() 575 symbol.section, in finish() 630 section: SymbolSection::Undefined, in get_symbol() 685 section: SymbolSection::Section(func_symbol.section.id().unwrap()), in get_symbol() [all …]
|
| /wasmtime-44.0.1/crates/wasmtime/src/runtime/ |
| H A D | coredump.rs | 110 core_dump.section(&wasm_encoder::CoreDumpSection::new(name)); in _serialize() 158 core_dump.section(&memories); in _serialize() 230 core_dump.section(&globals); in _serialize() 233 core_dump.section(&data); in _serialize() 249 core_dump.section(&modules); in _serialize() 288 core_dump.section(&instances); in _serialize() 314 core_dump.section(&stack); in _serialize()
|
| H A D | native_debug.rs | 37 for section in obj.sections() { in relocate_dwarf_sections() 38 let section_start = match section.file_range() { in relocate_dwarf_sections() 42 for (off, r) in section.relocations() { in relocate_dwarf_sections() 136 let section: &mut SectionHeader64<E> = in convert_object_elf_to_loadable_file() localVariable 139 section.sh_addr.set(e, code_region.0 as u64); in convert_object_elf_to_loadable_file()
|
| /wasmtime-44.0.1/crates/fuzzing/src/ |
| H A D | single_module_fuzzer.rs | 245 for section in Parser::new(0).parse_all(data) { in extract_fuzz_input() 246 let section = section?; in extract_fuzz_input() localVariable 255 if let Payload::CustomSection(s) = §ion { in extract_fuzz_input() 266 if let Some((_, range)) = section.as_section() { in extract_fuzz_input()
|
| /wasmtime-44.0.1/src/commands/ |
| H A D | objdump.rs | 142 .and_then(|section| section.data().ok()) in execute() 159 .and_then(|section| section.data().ok()) in execute() 164 .and_then(|section| section.data().ok()) in execute() 169 .and_then(|section| section.data().ok()) in execute() 174 .and_then(|section| section.data().ok()) in execute() 180 .and_then(|section| section.data().ok()) in execute()
|
| /wasmtime-44.0.1/tests/all/native_debug/ |
| H A D | dump.rs | 10 pub fn get_dwarfdump(obj: &str, section: DwarfDumpSection) -> Result<String> { in get_dwarfdump() 12 let section_flag = match section { in get_dwarfdump()
|
| /wasmtime-44.0.1/tests/misc_testsuite/gc/ |
| H A D | more-rec-groups-than-types.wast | 4 ;; groups defined in the type section than actual types (and therefore the 5 ;; length that the type section reports is greater than the length of the types
|
| /wasmtime-44.0.1/crates/cranelift/src/debug/ |
| H A D | write_debuginfo.rs | 110 fn write_offset(&mut self, val: usize, section: SectionId, size: u8) -> WriteResult<()> { in write_offset() 112 let target = DwarfSectionRelocTarget::Section(section.name()); in write_offset() 126 section: SectionId, in write_offset_at() 129 let target = DwarfSectionRelocTarget::Section(section.name()); in write_offset_at()
|
| /wasmtime-44.0.1/crates/wizer/tests/all/ |
| H A D | tests.rs | 748 module.section(&types); in accept_bulk_memory_data_count() 753 module.section(&functions); in accept_bulk_memory_data_count() 763 module.section(&memory); in accept_bulk_memory_data_count() 768 module.section(&exports); in accept_bulk_memory_data_count() 770 module.section(&wasm_encoder::DataCountSection { count: 2 }); in accept_bulk_memory_data_count() 782 module.section(&code); in accept_bulk_memory_data_count() 789 module.section(&data); in accept_bulk_memory_data_count()
|
| /wasmtime-44.0.1/crates/fuzzing/src/oracles/ |
| H A D | memory.rs | 269 module.section(&types); in build_wasm() 278 module.section(&funcs); in build_wasm() 290 module.section(&memories); in build_wasm() 300 module.section(&exports); in build_wasm() 365 module.section(&code); in build_wasm() 383 module.section(&datas); in build_wasm()
|