Home
last modified time | relevance | path

Searched refs:File (Results 1 – 25 of 87) sorted by relevance

1234

/wasmtime-44.0.1/crates/wasi-preview1-component-adapter/src/
H A Ddescriptors.rs10 use crate::File;
52 StreamType::File(File { in get_read_stream()
59 StreamType::File(file) => { in get_read_stream()
80 StreamType::File(File { in get_write_stream()
87 StreamType::File(file) => { in get_write_stream()
110 File(File), enumerator
219 type_: StreamType::File(File { in open_preopens()
404 StreamType::File(File { in get_file_with_error()
429 StreamType::File( in get_dir()
430 file @ File { in get_dir()
[all …]
/wasmtime-44.0.1/crates/wasi/src/
H A Dfilesystem.rs450 File(File), enumerator
471 Self::File(f) => { in get_metadata()
484 Self::File(f) => { in sync_data()
528 Self::File(f) => { in get_flags()
555 Self::File(f) => { in get_type()
570 Self::File(f) => { in set_times()
589 Self::File(f) => { in sync()
660 pub struct File { struct
680 impl File { impl
1020 File(cap_std::fs::File), in open_at() enumerator
[all …]
H A Dp1.rs242 struct File { struct
342 File(File), enumerator
552 Descriptor::File(File { fd, .. }) => Ok(fd.borrowed()), in get_fd()
637 Descriptor::File(File { in fd_write_impl()
1474 Descriptor::File(File { in fd_fdstat_get()
1535 let File { in fd_fdstat_set_flags() localVariable
1676 Descriptor::File(File { in fd_read()
1756 Descriptor::File(File { in fd_pread()
2207 crate::filesystem::Descriptor::File(_) => Descriptor::File(File { in path_open()
2449 Descriptor::File(File { in poll_oneoff()
[all …]
/wasmtime-44.0.1/cranelift/serde/src/
H A Dclif-json.rs8 use std::fs::File;
29 fn call_de(file: &File) -> Result<(), String> { in call_de()
62 let mut file = File::open(file).expect("Unable to open the file"); in main()
69 let file = File::open(file).expect("Unable to open the file"); in main()
/wasmtime-44.0.1/crates/test-programs/src/bin/
H A Dp2_api_read_only.rs3 fs::{self, File, OpenOptions},
9 let mut file = File::open("bar.txt")?; in main()
29 assert!(File::create("new.txt").is_err()); in main()
H A Dp2_cli_file_read.rs3 fs::File,
8 let mut file = File::open("bar.txt")?; in main()
/wasmtime-44.0.1/crates/wasi-common/src/tokio/
H A Dfile.rs14 pub struct File(crate::sync::file::File); struct
16 impl File { impl
17 pub(crate) fn from_inner(file: crate::sync::file::File) -> Self { in from_inner()
18 File(file) in from_inner()
20 pub fn from_cap_std(file: cap_std::fs::File) -> Self { in from_cap_std()
21 Self::from_inner(crate::sync::file::File::from_cap_std(file)) in from_cap_std()
238 wasi_file_impl!(File);
H A Ddir.rs1 use crate::tokio::{block_on_dummy_executor, file::File};
37 crate::sync::dir::OpenResult::File(f) => { in open_file()
38 Ok(crate::dir::OpenResult::File(Box::new(File::from_inner(f)))) in open_file()
/wasmtime-44.0.1/crates/wasi-common/src/sync/
H A Dfile.rs15 pub struct File(cap_std::fs::File); struct
17 impl File { impl
18 pub fn from_cap_std(file: cap_std::fs::File) -> Self { in from_cap_std()
19 File(file) in from_cap_std()
24 impl WasiFile for File { implementation
163 impl AsHandle for File { implementation
172 impl AsRawHandleOrSocket for File { implementation
183 impl AsFd for File { implementation
H A Ddir.rs1 use crate::sync::file::{File, filetype_from};
16 File(File), enumerator
101 Ok(OpenResult::File(File::from_cap_std(f))) in open_file_()
139 OpenResult::File(f) => Ok(crate::dir::OpenResult::File(Box::new(f))), in open_file()
/wasmtime-44.0.1/crates/wasmtime/src/profiling_agent/
H A Dperfmap.rs6 use std::{fs::File, sync::Mutex};
9 static PERFMAP_FILE: Mutex<Option<File>> = Mutex::new(None);
34 fn make_line(writer: &mut File, name: &str, code: &[u8]) -> io::Result<()> { in make_line() argument
/wasmtime-44.0.1/crates/wasmtime/src/runtime/vm/sys/miri/
H A Dmmap.rs12 use std::fs::File;
18 pub fn open_file_for_mmap(path: &Path) -> Result<File> { in open_file_for_mmap() argument
19 let file = File::open(path)?; in open_file_for_mmap()
62 pub fn from_file(mut file: &File) -> Result<Self> { in from_file()
H A Dvm.rs2 use std::fs::File;
56 pub fn from_file(_file: &Arc<File>) -> Option<MemoryImageSource> { in from_file()
/wasmtime-44.0.1/crates/wasmtime/src/runtime/vm/sys/unix/
H A Dpagemap.rs11 use std::fs::File;
29 let pagemap = File::open("/proc/self/pagemap").ok()?;
98 pub struct PageMap(&'static File);
647 use std::fs::File;
721 let fd = File::open("/proc/self/pagemap").unwrap(); in ioctl_supported()
741 let fd = File::open("/proc/self/pagemap").unwrap(); in no_pages_returned()
763 let fd = File::open("/proc/self/pagemap").unwrap(); in empty_region()
785 let fd = File::open("/proc/self/pagemap").unwrap(); in basic_page_flags()
839 let fd = File::open("/proc/self/pagemap").unwrap(); in only_written_pages()
877 let fd = File::open("/proc/self/pagemap").unwrap(); in region_limit()
[all …]
H A Dvm.rs4 use std::fs::File;
94 Mmap(Arc<File>),
101 pub fn from_file(file: &Arc<File>) -> Option<MemoryImageSource> { in from_file()
160 pub(super) fn as_file(&self) -> &File { in as_file() argument
H A Dmmap.rs8 use std::{fs::File, path::Path};
12 pub fn open_file_for_mmap(path: &Path) -> Result<File> { in open_file_for_mmap() argument
13 File::open(path).context("failed to open file") in open_file_for_mmap()
86 pub fn from_file(file: &File) -> Result<Self> { in from_file()
/wasmtime-44.0.1/crates/wasi/src/cli/
H A Dfile.rs17 file: Arc<std::fs::File>,
21 pub fn new(file: std::fs::File) -> Self { in new()
94 file: Arc<std::fs::File>,
98 pub fn new(file: std::fs::File) -> Self { in new()
/wasmtime-44.0.1/crates/wasi/src/p2/
H A Dfilesystem.rs2 use crate::filesystem::File;
66 file: File,
78 pub fn new(file: &File, position: u64) -> Self { in new() argument
86 fn blocking_read(file: &cap_std::fs::File, offset: u64, size: usize) -> ReadState { in blocking_read() argument
209 file: File,
225 pub fn write_at(file: &File, position: u64) -> Self { in write_at() argument
233 pub fn append(file: &File) -> Self { in append()
242 file: &cap_std::fs::File, in blocking_write() argument
/wasmtime-44.0.1/cranelift/assembler-x64/
H A Dbuild.rs3 use std::fs::File;
16 let mut vec_of_built_files = File::create(out_dir.join("generated-files.rs")).unwrap(); in main()
/wasmtime-44.0.1/crates/c-api/src/
H A Dwasi.rs6 use std::fs::File;
25 unsafe fn open_file(path: *const c_char) -> Option<File> { in open_file() argument
26 File::open(cstr_to_path(path)?).ok() in open_file()
29 unsafe fn create_file(path: *const c_char) -> Option<File> { in create_file() argument
30 File::create(cstr_to_path(path)?).ok() in create_file()
113 let file = tokio::fs::File::from_std(file); in wasi_config_set_stdin_file()
/wasmtime-44.0.1/tests/all/native_debug/
H A Dobj.rs1 use std::fs::File;
24 let mut file = File::create(output).context("failed to create object file")?; in compile_cranelift()
/wasmtime-44.0.1/crates/jit-debug/src/
H A Dperf_jitdump.rs14 use std::fs::{File, OpenOptions};
132 jitdump_file: File,
273 pub fn file(&self) -> &File { in file() argument
278 pub fn file_mut(&mut self) -> &mut File { in file_mut() argument
/wasmtime-44.0.1/cranelift/src/
H A Dutils.rs4 use std::fs::File;
20 let mut file = File::open(path)?; in read_to_string()
/wasmtime-44.0.1/crates/wasmtime/src/runtime/vm/sys/custom/
H A Dmmap.rs8 use std::{fs::File, path::Path};
11 pub fn open_file_for_mmap(_path: &Path) -> Result<File> { in open_file_for_mmap() argument
50 pub fn from_file(_file: &File) -> Result<Self> { in from_file()
/wasmtime-44.0.1/cranelift/native/src/
H A Driscv.rs2 use std::fs::File;
61 let file = File::open("/proc/cpuinfo").map_err(|_| "failed to open /proc/cpuinfo")?; in cpuinfo_detect()

1234