diff --git a/.github/workflows/general.yml b/.github/workflows/general.yml index f5e9b748..9ff5dd8f 100644 --- a/.github/workflows/general.yml +++ b/.github/workflows/general.yml @@ -38,6 +38,7 @@ jobs: - run: rustup target install x86_64-apple-darwin - run: rustup target install i686-pc-windows-msvc - run: rustup target install x86_64-pc-windows-msvc + - run: rustup target install aarch64-apple-darwin # ****************************************************************** - name: Download prebuilt archive (CPU, x86_64-unknown-linux-gnu) uses: actions-rs/cargo@v1 @@ -53,7 +54,7 @@ jobs: command: build args: --target x86_64-apple-darwin - name: Verify prebuilt archive downloaded (CPU, x86_64-apple-darwin) - run: ls -lh target/x86_64-apple-darwin/debug/build/onnxruntime-sys-*/out/onnxruntime-osx-x64-1.*.tgz + run: ls -lh target/x86_64-apple-darwin/debug/build/onnxruntime-sys-*/out/onnxruntime-osx-x86_64-1.*.tgz # ****************************************************************** - name: Download prebuilt archive (CPU, i686-pc-windows-msvc) uses: actions-rs/cargo@v1 @@ -89,7 +90,15 @@ jobs: command: build args: --target x86_64-pc-windows-msvc - name: Verify prebuilt archive downloaded (GPU, x86_64-pc-windows-msvc) - run: ls -lh target/x86_64-pc-windows-msvc/debug/build/onnxruntime-sys-*/out/onnxruntime-win-gpu-x64-1.*.zip + run: ls -lh target/x86_64-pc-windows-msvc/debug/build/onnxruntime-sys-*/out/onnxruntime-win-x64-gpu-1.*.zip + # ****************************************************************** + - name: Download prebuilt archive (CPU, aarch64-apple-darwin) + uses: actions-rs/cargo@v1 + with: + command: build + args: --target aarch64-apple-darwin + - name: Verify prebuilt archive downloaded (CPU, aarch64-apple-darwin) + run: ls -lh target/aarch64-apple-darwin/debug/build/onnxruntime-sys-*/out/onnxruntime-osx-arm64-1.*.tgz test: name: Test Suite @@ -110,9 +119,9 @@ jobs: - target: x86_64-apple-darwin os: macos-latest - target: x86_64-pc-windows-msvc - os: windows-latest + os: windows-2019 - target: i686-pc-windows-msvc - os: windows-latest + os: windows-2019 env: CARGO_BUILD_TARGET: ${{ matrix.target }} steps: diff --git a/README.md b/README.md index a025ed51..604dc80f 100644 --- a/README.md +++ b/README.md @@ -98,7 +98,7 @@ To run this example ([`onnxruntime-sys/examples/c_api_sample.rs`](onnxruntime-sy ```sh # Download the model (SqueezeNet 1.0, ONNX version: 1.3, Opset version: 8) -❯ curl -LO "https://github.com/onnx/models/raw/master/vision/classification/squeezenet/model/squeezenet1.0-8.onnx" +❯ curl -LO "https://github.com/onnx/models/raw/main/vision/classification/squeezenet/model/squeezenet1.0-8.onnx" ❯ cargo run --example c_api_sample [...] Finished dev [unoptimized + debuginfo] target(s) in 1.88s @@ -150,7 +150,7 @@ To run this example ([`onnxruntime/examples/sample.rs`](onnxruntime/examples/sam ```sh # Download the model (SqueezeNet 1.0, ONNX version: 1.3, Opset version: 8) -❯ curl -LO "https://github.com/onnx/models/raw/master/vision/classification/squeezenet/model/squeezenet1.0-8.onnx" +❯ curl -LO "https://github.com/onnx/models/raw/main/vision/classification/squeezenet/model/squeezenet1.0-8.onnx" ❯ cargo run --example sample [...] Finished dev [unoptimized + debuginfo] target(s) in 13.62s diff --git a/onnxruntime-sys/Cargo.toml b/onnxruntime-sys/Cargo.toml index 942ca74c..07b52aee 100644 --- a/onnxruntime-sys/Cargo.toml +++ b/onnxruntime-sys/Cargo.toml @@ -17,7 +17,7 @@ keywords = ["neuralnetworks", "onnx", "bindings"] [dependencies] [build-dependencies] -bindgen = { version = "0.59", optional = true } +bindgen = { version = "0.60", optional = true } ureq = "2.1" # Used on Windows diff --git a/onnxruntime-sys/build.rs b/onnxruntime-sys/build.rs index 6fac6d24..b82ea062 100644 --- a/onnxruntime-sys/build.rs +++ b/onnxruntime-sys/build.rs @@ -13,7 +13,7 @@ use std::{ /// WARNING: If version is changed, bindings for all platforms will have to be re-generated. /// To do so, run this: /// cargo build --package onnxruntime-sys --features generate-bindings -const ORT_VERSION: &str = "1.8.1"; +const ORT_VERSION: &str = "1.11.1"; /// Base Url from which to download pre-built releases/ const ORT_RELEASE_BASE_URL: &str = "https://github.com/microsoft/onnxruntime/releases/download"; @@ -178,7 +178,7 @@ fn extract_zip(filename: &Path, outpath: &Path) { let mut file = archive.by_index(i).unwrap(); #[allow(deprecated)] let outpath = outpath.join(file.sanitized_name()); - if !(&*file.name()).ends_with('/') { + if !file.name().ends_with('/') { println!( "File {} extracted to \"{}\" ({} bytes)", i, @@ -310,33 +310,32 @@ struct Triplet { impl OnnxPrebuiltArchive for Triplet { fn as_onnx_str(&self) -> Cow { match (&self.os, &self.arch, &self.accelerator) { - // onnxruntime-win-x86-1.8.1.zip - // onnxruntime-win-x64-1.8.1.zip - // onnxruntime-win-arm-1.8.1.zip - // onnxruntime-win-arm64-1.8.1.zip - // onnxruntime-linux-x64-1.8.1.tgz - // onnxruntime-osx-x64-1.8.1.tgz + // onnxruntime-win-x86-1.11.1.zip + // onnxruntime-win-x64-1.11.1.zip + // onnxruntime-win-arm-1.11.1.zip + // onnxruntime-win-arm64-1.11.1.zip + // onnxruntime-linux-x64-1.11.1.tgz + // onnxruntime-osx-x86_64-1.11.1.tgz + // onnxruntime-osx-arm64-1.11.1.tgz (Os::Windows, Architecture::X86, Accelerator::None) | (Os::Windows, Architecture::X86_64, Accelerator::None) | (Os::Windows, Architecture::Arm, Accelerator::None) | (Os::Windows, Architecture::Arm64, Accelerator::None) - | (Os::Linux, Architecture::X86_64, Accelerator::None) - | (Os::MacOs, Architecture::X86_64, Accelerator::None) => Cow::from(format!( + | (Os::MacOs, Architecture::Arm64, Accelerator::None) + | (Os::Linux, Architecture::X86_64, Accelerator::None) => Cow::from(format!( "{}-{}", self.os.as_onnx_str(), self.arch.as_onnx_str() )), - // onnxruntime-win-gpu-x64-1.8.1.zip - // Note how this one is inverted from the linux one next - (Os::Windows, Architecture::X86_64, Accelerator::Gpu) => Cow::from(format!( - "{}-{}-{}", + (Os::MacOs, Architecture::X86_64, Accelerator::None) => Cow::from(format!( + "{}-x86_{}", self.os.as_onnx_str(), - self.accelerator.as_onnx_str(), - self.arch.as_onnx_str(), + self.arch.as_onnx_str().trim_start_matches('x') )), - // onnxruntime-linux-x64-gpu-1.8.1.tgz - // Note how this one is inverted from the windows one above - (Os::Linux, Architecture::X86_64, Accelerator::Gpu) => Cow::from(format!( + // onnxruntime-win-x64-gpu-1.11.1.zip + // onnxruntime-linux-x64-gpu-1.11.1.tgz + (Os::Linux, Architecture::X86_64, Accelerator::Gpu) + | (Os::Windows, Architecture::X86_64, Accelerator::Gpu) => Cow::from(format!( "{}-{}-{}", self.os.as_onnx_str(), self.arch.as_onnx_str(), diff --git a/onnxruntime-sys/examples/c_api_sample.rs b/onnxruntime-sys/examples/c_api_sample.rs index fde8df08..443a114d 100644 --- a/onnxruntime-sys/examples/c_api_sample.rs +++ b/onnxruntime-sys/examples/c_api_sample.rs @@ -55,10 +55,10 @@ fn main() { //************************************************************************* // create session and load model into memory // NOTE: Original C version loaded SqueezeNet 1.0 (ONNX version: 1.3, Opset version: 8, - // https://github.com/onnx/models/blob/master/vision/classification/squeezenet/model/squeezenet1.0-8.onnx) + // https://github.com/onnx/models/blob/main/vision/classification/squeezenet/model/squeezenet1.0-8.onnx) // Download it: - // curl -LO "https://github.com/onnx/models/raw/master/vision/classification/squeezenet/model/squeezenet1.0-8.onnx" - // Reference: https://github.com/onnx/models/tree/master/vision/classification/squeezenet#model + // curl -LO "https://github.com/onnx/models/raw/main/vision/classification/squeezenet/model/squeezenet1.0-8.onnx" + // Reference: https://github.com/onnx/models/tree/main/vision/classification/squeezenet#model let model_path = std::ffi::OsString::from("squeezenet1.0-8.onnx"); #[cfg(target_family = "windows")] diff --git a/onnxruntime-sys/src/generated/linux/x86_64/bindings.rs b/onnxruntime-sys/src/generated/linux/x86_64/bindings.rs index afcbbbb4..dfd9c7f9 100644 --- a/onnxruntime-sys/src/generated/linux/x86_64/bindings.rs +++ b/onnxruntime-sys/src/generated/linux/x86_64/bindings.rs @@ -1,15709 +1,9480 @@ -/* automatically generated by rust-bindgen 0.59.1 */ +/* automatically generated by rust-bindgen 0.60.1 */ -#[repr(C)] -#[derive(Copy, Clone, Debug, Default, Eq, Hash, Ord, PartialEq, PartialOrd)] -pub struct __BindgenBitfieldUnit { - storage: Storage, -} -impl __BindgenBitfieldUnit { - #[inline] - pub const fn new(storage: Storage) -> Self { - Self { storage } - } -} -impl __BindgenBitfieldUnit -where - Storage: AsRef<[u8]> + AsMut<[u8]>, -{ - #[inline] - pub fn get_bit(&self, index: usize) -> bool { - debug_assert!(index / 8 < self.storage.as_ref().len()); - let byte_index = index / 8; - let byte = self.storage.as_ref()[byte_index]; - let bit_index = if cfg!(target_endian = "big") { - 7 - (index % 8) - } else { - index % 8 - }; - let mask = 1 << bit_index; - byte & mask == mask - } - #[inline] - pub fn set_bit(&mut self, index: usize, val: bool) { - debug_assert!(index / 8 < self.storage.as_ref().len()); - let byte_index = index / 8; - let byte = &mut self.storage.as_mut()[byte_index]; - let bit_index = if cfg!(target_endian = "big") { - 7 - (index % 8) - } else { - index % 8 - }; - let mask = 1 << bit_index; - if val { - *byte |= mask; - } else { - *byte &= !mask; - } - } - #[inline] - pub fn get(&self, bit_offset: usize, bit_width: u8) -> u64 { - debug_assert!(bit_width <= 64); - debug_assert!(bit_offset / 8 < self.storage.as_ref().len()); - debug_assert!((bit_offset + (bit_width as usize)) / 8 <= self.storage.as_ref().len()); - let mut val = 0; - for i in 0..(bit_width as usize) { - if self.get_bit(i + bit_offset) { - let index = if cfg!(target_endian = "big") { - bit_width as usize - 1 - i - } else { - i - }; - val |= 1 << index; - } - } - val - } - #[inline] - pub fn set(&mut self, bit_offset: usize, bit_width: u8, val: u64) { - debug_assert!(bit_width <= 64); - debug_assert!(bit_offset / 8 < self.storage.as_ref().len()); - debug_assert!((bit_offset + (bit_width as usize)) / 8 <= self.storage.as_ref().len()); - for i in 0..(bit_width as usize) { - let mask = 1 << i; - let val_bit_is_set = val & mask == mask; - let index = if cfg!(target_endian = "big") { - bit_width as usize - 1 - i - } else { - i - }; - self.set_bit(index + bit_offset, val_bit_is_set); - } - } -} -pub const __API_TO_BE_DEPRECATED: u32 = 100000; -pub const __MAC_10_0: u32 = 1000; -pub const __MAC_10_1: u32 = 1010; -pub const __MAC_10_2: u32 = 1020; -pub const __MAC_10_3: u32 = 1030; -pub const __MAC_10_4: u32 = 1040; -pub const __MAC_10_5: u32 = 1050; -pub const __MAC_10_6: u32 = 1060; -pub const __MAC_10_7: u32 = 1070; -pub const __MAC_10_8: u32 = 1080; -pub const __MAC_10_9: u32 = 1090; -pub const __MAC_10_10: u32 = 101000; -pub const __MAC_10_10_2: u32 = 101002; -pub const __MAC_10_10_3: u32 = 101003; -pub const __MAC_10_11: u32 = 101100; -pub const __MAC_10_11_2: u32 = 101102; -pub const __MAC_10_11_3: u32 = 101103; -pub const __MAC_10_11_4: u32 = 101104; -pub const __MAC_10_12: u32 = 101200; -pub const __MAC_10_12_1: u32 = 101201; -pub const __MAC_10_12_2: u32 = 101202; -pub const __MAC_10_12_4: u32 = 101204; -pub const __MAC_10_13: u32 = 101300; -pub const __MAC_10_13_1: u32 = 101301; -pub const __MAC_10_13_2: u32 = 101302; -pub const __MAC_10_13_4: u32 = 101304; -pub const __MAC_10_14: u32 = 101400; -pub const __MAC_10_14_1: u32 = 101401; -pub const __MAC_10_14_4: u32 = 101404; -pub const __MAC_10_14_6: u32 = 101406; -pub const __MAC_10_15: u32 = 101500; -pub const __MAC_10_15_1: u32 = 101501; -pub const __MAC_10_15_4: u32 = 101504; -pub const __MAC_10_16: u32 = 101600; -pub const __MAC_11_0: u32 = 110000; -pub const __MAC_11_1: u32 = 110100; -pub const __MAC_11_3: u32 = 110300; -pub const __IPHONE_2_0: u32 = 20000; -pub const __IPHONE_2_1: u32 = 20100; -pub const __IPHONE_2_2: u32 = 20200; -pub const __IPHONE_3_0: u32 = 30000; -pub const __IPHONE_3_1: u32 = 30100; -pub const __IPHONE_3_2: u32 = 30200; -pub const __IPHONE_4_0: u32 = 40000; -pub const __IPHONE_4_1: u32 = 40100; -pub const __IPHONE_4_2: u32 = 40200; -pub const __IPHONE_4_3: u32 = 40300; -pub const __IPHONE_5_0: u32 = 50000; -pub const __IPHONE_5_1: u32 = 50100; -pub const __IPHONE_6_0: u32 = 60000; -pub const __IPHONE_6_1: u32 = 60100; -pub const __IPHONE_7_0: u32 = 70000; -pub const __IPHONE_7_1: u32 = 70100; -pub const __IPHONE_8_0: u32 = 80000; -pub const __IPHONE_8_1: u32 = 80100; -pub const __IPHONE_8_2: u32 = 80200; -pub const __IPHONE_8_3: u32 = 80300; -pub const __IPHONE_8_4: u32 = 80400; -pub const __IPHONE_9_0: u32 = 90000; -pub const __IPHONE_9_1: u32 = 90100; -pub const __IPHONE_9_2: u32 = 90200; -pub const __IPHONE_9_3: u32 = 90300; -pub const __IPHONE_10_0: u32 = 100000; -pub const __IPHONE_10_1: u32 = 100100; -pub const __IPHONE_10_2: u32 = 100200; -pub const __IPHONE_10_3: u32 = 100300; -pub const __IPHONE_11_0: u32 = 110000; -pub const __IPHONE_11_1: u32 = 110100; -pub const __IPHONE_11_2: u32 = 110200; -pub const __IPHONE_11_3: u32 = 110300; -pub const __IPHONE_11_4: u32 = 110400; -pub const __IPHONE_12_0: u32 = 120000; -pub const __IPHONE_12_1: u32 = 120100; -pub const __IPHONE_12_2: u32 = 120200; -pub const __IPHONE_12_3: u32 = 120300; -pub const __IPHONE_12_4: u32 = 120400; -pub const __IPHONE_13_0: u32 = 130000; -pub const __IPHONE_13_1: u32 = 130100; -pub const __IPHONE_13_2: u32 = 130200; -pub const __IPHONE_13_3: u32 = 130300; -pub const __IPHONE_13_4: u32 = 130400; -pub const __IPHONE_13_5: u32 = 130500; -pub const __IPHONE_13_6: u32 = 130600; -pub const __IPHONE_13_7: u32 = 130700; -pub const __IPHONE_14_0: u32 = 140000; -pub const __IPHONE_14_1: u32 = 140100; -pub const __IPHONE_14_2: u32 = 140200; -pub const __IPHONE_14_3: u32 = 140300; -pub const __IPHONE_14_5: u32 = 140500; -pub const __TVOS_9_0: u32 = 90000; -pub const __TVOS_9_1: u32 = 90100; -pub const __TVOS_9_2: u32 = 90200; -pub const __TVOS_10_0: u32 = 100000; -pub const __TVOS_10_0_1: u32 = 100001; -pub const __TVOS_10_1: u32 = 100100; -pub const __TVOS_10_2: u32 = 100200; -pub const __TVOS_11_0: u32 = 110000; -pub const __TVOS_11_1: u32 = 110100; -pub const __TVOS_11_2: u32 = 110200; -pub const __TVOS_11_3: u32 = 110300; -pub const __TVOS_11_4: u32 = 110400; -pub const __TVOS_12_0: u32 = 120000; -pub const __TVOS_12_1: u32 = 120100; -pub const __TVOS_12_2: u32 = 120200; -pub const __TVOS_12_3: u32 = 120300; -pub const __TVOS_12_4: u32 = 120400; -pub const __TVOS_13_0: u32 = 130000; -pub const __TVOS_13_2: u32 = 130200; -pub const __TVOS_13_3: u32 = 130300; -pub const __TVOS_13_4: u32 = 130400; -pub const __TVOS_14_0: u32 = 140000; -pub const __TVOS_14_1: u32 = 140100; -pub const __TVOS_14_2: u32 = 140200; -pub const __TVOS_14_3: u32 = 140300; -pub const __TVOS_14_5: u32 = 140500; -pub const __WATCHOS_1_0: u32 = 10000; -pub const __WATCHOS_2_0: u32 = 20000; -pub const __WATCHOS_2_1: u32 = 20100; -pub const __WATCHOS_2_2: u32 = 20200; -pub const __WATCHOS_3_0: u32 = 30000; -pub const __WATCHOS_3_1: u32 = 30100; -pub const __WATCHOS_3_1_1: u32 = 30101; -pub const __WATCHOS_3_2: u32 = 30200; -pub const __WATCHOS_4_0: u32 = 40000; -pub const __WATCHOS_4_1: u32 = 40100; -pub const __WATCHOS_4_2: u32 = 40200; -pub const __WATCHOS_4_3: u32 = 40300; -pub const __WATCHOS_5_0: u32 = 50000; -pub const __WATCHOS_5_1: u32 = 50100; -pub const __WATCHOS_5_2: u32 = 50200; -pub const __WATCHOS_5_3: u32 = 50300; -pub const __WATCHOS_6_0: u32 = 60000; -pub const __WATCHOS_6_1: u32 = 60100; -pub const __WATCHOS_6_2: u32 = 60200; -pub const __WATCHOS_7_0: u32 = 70000; -pub const __WATCHOS_7_1: u32 = 70100; -pub const __WATCHOS_7_2: u32 = 70200; -pub const __WATCHOS_7_3: u32 = 70300; -pub const __WATCHOS_7_4: u32 = 70400; -pub const MAC_OS_X_VERSION_10_0: u32 = 1000; -pub const MAC_OS_X_VERSION_10_1: u32 = 1010; -pub const MAC_OS_X_VERSION_10_2: u32 = 1020; -pub const MAC_OS_X_VERSION_10_3: u32 = 1030; -pub const MAC_OS_X_VERSION_10_4: u32 = 1040; -pub const MAC_OS_X_VERSION_10_5: u32 = 1050; -pub const MAC_OS_X_VERSION_10_6: u32 = 1060; -pub const MAC_OS_X_VERSION_10_7: u32 = 1070; -pub const MAC_OS_X_VERSION_10_8: u32 = 1080; -pub const MAC_OS_X_VERSION_10_9: u32 = 1090; -pub const MAC_OS_X_VERSION_10_10: u32 = 101000; -pub const MAC_OS_X_VERSION_10_10_2: u32 = 101002; -pub const MAC_OS_X_VERSION_10_10_3: u32 = 101003; -pub const MAC_OS_X_VERSION_10_11: u32 = 101100; -pub const MAC_OS_X_VERSION_10_11_2: u32 = 101102; -pub const MAC_OS_X_VERSION_10_11_3: u32 = 101103; -pub const MAC_OS_X_VERSION_10_11_4: u32 = 101104; -pub const MAC_OS_X_VERSION_10_12: u32 = 101200; -pub const MAC_OS_X_VERSION_10_12_1: u32 = 101201; -pub const MAC_OS_X_VERSION_10_12_2: u32 = 101202; -pub const MAC_OS_X_VERSION_10_12_4: u32 = 101204; -pub const MAC_OS_X_VERSION_10_13: u32 = 101300; -pub const MAC_OS_X_VERSION_10_13_1: u32 = 101301; -pub const MAC_OS_X_VERSION_10_13_2: u32 = 101302; -pub const MAC_OS_X_VERSION_10_13_4: u32 = 101304; -pub const MAC_OS_X_VERSION_10_14: u32 = 101400; -pub const MAC_OS_X_VERSION_10_14_1: u32 = 101401; -pub const MAC_OS_X_VERSION_10_14_4: u32 = 101404; -pub const MAC_OS_X_VERSION_10_14_6: u32 = 101406; -pub const MAC_OS_X_VERSION_10_15: u32 = 101500; -pub const MAC_OS_X_VERSION_10_15_1: u32 = 101501; -pub const MAC_OS_X_VERSION_10_16: u32 = 101600; -pub const MAC_OS_VERSION_11_0: u32 = 110000; -pub const __DRIVERKIT_19_0: u32 = 190000; -pub const __DRIVERKIT_20_0: u32 = 200000; -pub const __DARWIN_ONLY_64_BIT_INO_T: u32 = 0; -pub const __DARWIN_ONLY_UNIX_CONFORMANCE: u32 = 1; -pub const __DARWIN_ONLY_VERS_1050: u32 = 0; -pub const __DARWIN_UNIX03: u32 = 1; -pub const __DARWIN_64_BIT_INO_T: u32 = 1; -pub const __DARWIN_VERS_1050: u32 = 1; -pub const __DARWIN_NON_CANCELABLE: u32 = 0; -pub const __DARWIN_SUF_64_BIT_INO_T: &'static [u8; 9usize] = b"$INODE64\0"; -pub const __DARWIN_SUF_1050: &'static [u8; 6usize] = b"$1050\0"; -pub const __DARWIN_SUF_EXTSN: &'static [u8; 14usize] = b"$DARWIN_EXTSN\0"; -pub const __DARWIN_C_ANSI: u32 = 4096; -pub const __DARWIN_C_FULL: u32 = 900000; -pub const __DARWIN_C_LEVEL: u32 = 900000; -pub const __STDC_WANT_LIB_EXT1__: u32 = 1; -pub const __DARWIN_NO_LONG_LONG: u32 = 0; -pub const _DARWIN_FEATURE_64_BIT_INODE: u32 = 1; -pub const _DARWIN_FEATURE_ONLY_UNIX_CONFORMANCE: u32 = 1; -pub const _DARWIN_FEATURE_UNIX_CONFORMANCE: u32 = 3; -pub const __PTHREAD_SIZE__: u32 = 8176; -pub const __PTHREAD_ATTR_SIZE__: u32 = 56; -pub const __PTHREAD_MUTEXATTR_SIZE__: u32 = 8; -pub const __PTHREAD_MUTEX_SIZE__: u32 = 56; -pub const __PTHREAD_CONDATTR_SIZE__: u32 = 8; -pub const __PTHREAD_COND_SIZE__: u32 = 40; -pub const __PTHREAD_ONCE_SIZE__: u32 = 8; -pub const __PTHREAD_RWLOCK_SIZE__: u32 = 192; -pub const __PTHREAD_RWLOCKATTR_SIZE__: u32 = 16; -pub const __DARWIN_WCHAR_MIN: i32 = -2147483648; -pub const _FORTIFY_SOURCE: u32 = 2; -pub const __DARWIN_NSIG: u32 = 32; -pub const NSIG: u32 = 32; -pub const _I386_SIGNAL_H_: u32 = 1; -pub const SIGHUP: u32 = 1; -pub const SIGINT: u32 = 2; -pub const SIGQUIT: u32 = 3; -pub const SIGILL: u32 = 4; -pub const SIGTRAP: u32 = 5; -pub const SIGABRT: u32 = 6; -pub const SIGIOT: u32 = 6; -pub const SIGEMT: u32 = 7; -pub const SIGFPE: u32 = 8; -pub const SIGKILL: u32 = 9; -pub const SIGBUS: u32 = 10; -pub const SIGSEGV: u32 = 11; -pub const SIGSYS: u32 = 12; -pub const SIGPIPE: u32 = 13; -pub const SIGALRM: u32 = 14; -pub const SIGTERM: u32 = 15; -pub const SIGURG: u32 = 16; -pub const SIGSTOP: u32 = 17; -pub const SIGTSTP: u32 = 18; -pub const SIGCONT: u32 = 19; -pub const SIGCHLD: u32 = 20; -pub const SIGTTIN: u32 = 21; -pub const SIGTTOU: u32 = 22; -pub const SIGIO: u32 = 23; -pub const SIGXCPU: u32 = 24; -pub const SIGXFSZ: u32 = 25; -pub const SIGVTALRM: u32 = 26; -pub const SIGPROF: u32 = 27; -pub const SIGWINCH: u32 = 28; -pub const SIGINFO: u32 = 29; -pub const SIGUSR1: u32 = 30; -pub const SIGUSR2: u32 = 31; -pub const FP_PREC_24B: u32 = 0; -pub const FP_PREC_53B: u32 = 2; -pub const FP_PREC_64B: u32 = 3; -pub const FP_RND_NEAR: u32 = 0; -pub const FP_RND_DOWN: u32 = 1; -pub const FP_RND_UP: u32 = 2; -pub const FP_CHOP: u32 = 3; -pub const FP_STATE_BYTES: u32 = 512; -pub const _X86_INSTRUCTION_STATE_MAX_INSN_BYTES: u32 = 2380; -pub const _X86_INSTRUCTION_STATE_CACHELINE_SIZE: u32 = 64; -pub const __LASTBRANCH_MAX: u32 = 32; -pub const SIGEV_NONE: u32 = 0; -pub const SIGEV_SIGNAL: u32 = 1; -pub const SIGEV_THREAD: u32 = 3; -pub const ILL_NOOP: u32 = 0; -pub const ILL_ILLOPC: u32 = 1; -pub const ILL_ILLTRP: u32 = 2; -pub const ILL_PRVOPC: u32 = 3; -pub const ILL_ILLOPN: u32 = 4; -pub const ILL_ILLADR: u32 = 5; -pub const ILL_PRVREG: u32 = 6; -pub const ILL_COPROC: u32 = 7; -pub const ILL_BADSTK: u32 = 8; -pub const FPE_NOOP: u32 = 0; -pub const FPE_FLTDIV: u32 = 1; -pub const FPE_FLTOVF: u32 = 2; -pub const FPE_FLTUND: u32 = 3; -pub const FPE_FLTRES: u32 = 4; -pub const FPE_FLTINV: u32 = 5; -pub const FPE_FLTSUB: u32 = 6; -pub const FPE_INTDIV: u32 = 7; -pub const FPE_INTOVF: u32 = 8; -pub const SEGV_NOOP: u32 = 0; -pub const SEGV_MAPERR: u32 = 1; -pub const SEGV_ACCERR: u32 = 2; -pub const BUS_NOOP: u32 = 0; -pub const BUS_ADRALN: u32 = 1; -pub const BUS_ADRERR: u32 = 2; -pub const BUS_OBJERR: u32 = 3; -pub const TRAP_BRKPT: u32 = 1; -pub const TRAP_TRACE: u32 = 2; -pub const CLD_NOOP: u32 = 0; -pub const CLD_EXITED: u32 = 1; -pub const CLD_KILLED: u32 = 2; -pub const CLD_DUMPED: u32 = 3; -pub const CLD_TRAPPED: u32 = 4; -pub const CLD_STOPPED: u32 = 5; -pub const CLD_CONTINUED: u32 = 6; -pub const POLL_IN: u32 = 1; -pub const POLL_OUT: u32 = 2; -pub const POLL_MSG: u32 = 3; -pub const POLL_ERR: u32 = 4; -pub const POLL_PRI: u32 = 5; -pub const POLL_HUP: u32 = 6; -pub const SA_ONSTACK: u32 = 1; -pub const SA_RESTART: u32 = 2; -pub const SA_RESETHAND: u32 = 4; -pub const SA_NOCLDSTOP: u32 = 8; -pub const SA_NODEFER: u32 = 16; -pub const SA_NOCLDWAIT: u32 = 32; -pub const SA_SIGINFO: u32 = 64; -pub const SA_USERTRAMP: u32 = 256; -pub const SA_64REGSET: u32 = 512; -pub const SA_USERSPACE_MASK: u32 = 127; -pub const SIG_BLOCK: u32 = 1; -pub const SIG_UNBLOCK: u32 = 2; -pub const SIG_SETMASK: u32 = 3; -pub const SI_USER: u32 = 65537; -pub const SI_QUEUE: u32 = 65538; -pub const SI_TIMER: u32 = 65539; -pub const SI_ASYNCIO: u32 = 65540; -pub const SI_MESGQ: u32 = 65541; -pub const SS_ONSTACK: u32 = 1; -pub const SS_DISABLE: u32 = 4; -pub const MINSIGSTKSZ: u32 = 32768; -pub const SIGSTKSZ: u32 = 131072; -pub const SV_ONSTACK: u32 = 1; -pub const SV_INTERRUPT: u32 = 2; -pub const SV_RESETHAND: u32 = 4; -pub const SV_NODEFER: u32 = 16; -pub const SV_NOCLDSTOP: u32 = 8; -pub const SV_SIGINFO: u32 = 64; +pub const _FEATURES_H: u32 = 1; +pub const _DEFAULT_SOURCE: u32 = 1; +pub const __GLIBC_USE_ISOC2X: u32 = 0; +pub const __USE_ISOC11: u32 = 1; +pub const __USE_ISOC99: u32 = 1; +pub const __USE_ISOC95: u32 = 1; +pub const __USE_POSIX_IMPLICITLY: u32 = 1; +pub const _POSIX_SOURCE: u32 = 1; +pub const _POSIX_C_SOURCE: u32 = 200809; +pub const __USE_POSIX: u32 = 1; +pub const __USE_POSIX2: u32 = 1; +pub const __USE_POSIX199309: u32 = 1; +pub const __USE_POSIX199506: u32 = 1; +pub const __USE_XOPEN2K: u32 = 1; +pub const __USE_XOPEN2K8: u32 = 1; +pub const _ATFILE_SOURCE: u32 = 1; +pub const __USE_MISC: u32 = 1; +pub const __USE_ATFILE: u32 = 1; +pub const __USE_FORTIFY_LEVEL: u32 = 0; +pub const __GLIBC_USE_DEPRECATED_GETS: u32 = 0; +pub const __GLIBC_USE_DEPRECATED_SCANF: u32 = 0; +pub const _STDC_PREDEF_H: u32 = 1; +pub const __STDC_IEC_559__: u32 = 1; +pub const __STDC_IEC_559_COMPLEX__: u32 = 1; +pub const __STDC_ISO_10646__: u32 = 201706; +pub const __GNU_LIBRARY__: u32 = 6; +pub const __GLIBC__: u32 = 2; +pub const __GLIBC_MINOR__: u32 = 31; +pub const _SYS_CDEFS_H: u32 = 1; +pub const __glibc_c99_flexarr_available: u32 = 1; pub const __WORDSIZE: u32 = 64; -pub const INT8_MAX: u32 = 127; -pub const INT16_MAX: u32 = 32767; -pub const INT32_MAX: u32 = 2147483647; -pub const INT64_MAX: u64 = 9223372036854775807; +pub const __WORDSIZE_TIME64_COMPAT32: u32 = 1; +pub const __SYSCALL_WORDSIZE: u32 = 64; +pub const __LONG_DOUBLE_USES_FLOAT128: u32 = 0; +pub const __HAVE_GENERIC_SELECTION: u32 = 1; +pub const __GLIBC_USE_LIB_EXT2: u32 = 0; +pub const __GLIBC_USE_IEC_60559_BFP_EXT: u32 = 0; +pub const __GLIBC_USE_IEC_60559_BFP_EXT_C2X: u32 = 0; +pub const __GLIBC_USE_IEC_60559_FUNCS_EXT: u32 = 0; +pub const __GLIBC_USE_IEC_60559_FUNCS_EXT_C2X: u32 = 0; +pub const __GLIBC_USE_IEC_60559_TYPES_EXT: u32 = 0; +pub const _STDLIB_H: u32 = 1; +pub const WNOHANG: u32 = 1; +pub const WUNTRACED: u32 = 2; +pub const WSTOPPED: u32 = 2; +pub const WEXITED: u32 = 4; +pub const WCONTINUED: u32 = 8; +pub const WNOWAIT: u32 = 16777216; +pub const __WNOTHREAD: u32 = 536870912; +pub const __WALL: u32 = 1073741824; +pub const __WCLONE: u32 = 2147483648; +pub const __ENUM_IDTYPE_T: u32 = 1; +pub const __W_CONTINUED: u32 = 65535; +pub const __WCOREFLAG: u32 = 128; +pub const __HAVE_FLOAT128: u32 = 0; +pub const __HAVE_DISTINCT_FLOAT128: u32 = 0; +pub const __HAVE_FLOAT64X: u32 = 1; +pub const __HAVE_FLOAT64X_LONG_DOUBLE: u32 = 1; +pub const __HAVE_FLOAT16: u32 = 0; +pub const __HAVE_FLOAT32: u32 = 1; +pub const __HAVE_FLOAT64: u32 = 1; +pub const __HAVE_FLOAT32X: u32 = 1; +pub const __HAVE_FLOAT128X: u32 = 0; +pub const __HAVE_DISTINCT_FLOAT16: u32 = 0; +pub const __HAVE_DISTINCT_FLOAT32: u32 = 0; +pub const __HAVE_DISTINCT_FLOAT64: u32 = 0; +pub const __HAVE_DISTINCT_FLOAT32X: u32 = 0; +pub const __HAVE_DISTINCT_FLOAT64X: u32 = 0; +pub const __HAVE_DISTINCT_FLOAT128X: u32 = 0; +pub const __HAVE_FLOATN_NOT_TYPEDEF: u32 = 0; +pub const __ldiv_t_defined: u32 = 1; +pub const __lldiv_t_defined: u32 = 1; +pub const RAND_MAX: u32 = 2147483647; +pub const EXIT_FAILURE: u32 = 1; +pub const EXIT_SUCCESS: u32 = 0; +pub const _SYS_TYPES_H: u32 = 1; +pub const _BITS_TYPES_H: u32 = 1; +pub const __TIMESIZE: u32 = 64; +pub const _BITS_TYPESIZES_H: u32 = 1; +pub const __OFF_T_MATCHES_OFF64_T: u32 = 1; +pub const __INO_T_MATCHES_INO64_T: u32 = 1; +pub const __RLIM_T_MATCHES_RLIM64_T: u32 = 1; +pub const __STATFS_MATCHES_STATFS64: u32 = 1; +pub const __FD_SETSIZE: u32 = 1024; +pub const _BITS_TIME64_H: u32 = 1; +pub const __clock_t_defined: u32 = 1; +pub const __clockid_t_defined: u32 = 1; +pub const __time_t_defined: u32 = 1; +pub const __timer_t_defined: u32 = 1; +pub const _BITS_STDINT_INTN_H: u32 = 1; +pub const __BIT_TYPES_DEFINED__: u32 = 1; +pub const _ENDIAN_H: u32 = 1; +pub const _BITS_ENDIAN_H: u32 = 1; +pub const __LITTLE_ENDIAN: u32 = 1234; +pub const __BIG_ENDIAN: u32 = 4321; +pub const __PDP_ENDIAN: u32 = 3412; +pub const _BITS_ENDIANNESS_H: u32 = 1; +pub const __BYTE_ORDER: u32 = 1234; +pub const __FLOAT_WORD_ORDER: u32 = 1234; +pub const LITTLE_ENDIAN: u32 = 1234; +pub const BIG_ENDIAN: u32 = 4321; +pub const PDP_ENDIAN: u32 = 3412; +pub const BYTE_ORDER: u32 = 1234; +pub const _BITS_BYTESWAP_H: u32 = 1; +pub const _BITS_UINTN_IDENTITY_H: u32 = 1; +pub const _SYS_SELECT_H: u32 = 1; +pub const __FD_ZERO_STOS: &[u8; 6usize] = b"stosq\0"; +pub const __sigset_t_defined: u32 = 1; +pub const __timeval_defined: u32 = 1; +pub const _STRUCT_TIMESPEC: u32 = 1; +pub const FD_SETSIZE: u32 = 1024; +pub const _BITS_PTHREADTYPES_COMMON_H: u32 = 1; +pub const _THREAD_SHARED_TYPES_H: u32 = 1; +pub const _BITS_PTHREADTYPES_ARCH_H: u32 = 1; +pub const __SIZEOF_PTHREAD_MUTEX_T: u32 = 40; +pub const __SIZEOF_PTHREAD_ATTR_T: u32 = 56; +pub const __SIZEOF_PTHREAD_RWLOCK_T: u32 = 56; +pub const __SIZEOF_PTHREAD_BARRIER_T: u32 = 32; +pub const __SIZEOF_PTHREAD_MUTEXATTR_T: u32 = 4; +pub const __SIZEOF_PTHREAD_COND_T: u32 = 48; +pub const __SIZEOF_PTHREAD_CONDATTR_T: u32 = 4; +pub const __SIZEOF_PTHREAD_RWLOCKATTR_T: u32 = 8; +pub const __SIZEOF_PTHREAD_BARRIERATTR_T: u32 = 4; +pub const _THREAD_MUTEX_INTERNAL_H: u32 = 1; +pub const __PTHREAD_MUTEX_HAVE_PREV: u32 = 1; +pub const __have_pthread_attr_t: u32 = 1; +pub const _ALLOCA_H: u32 = 1; +pub const _STDINT_H: u32 = 1; +pub const _BITS_WCHAR_H: u32 = 1; +pub const _BITS_STDINT_UINTN_H: u32 = 1; pub const INT8_MIN: i32 = -128; pub const INT16_MIN: i32 = -32768; pub const INT32_MIN: i32 = -2147483648; -pub const INT64_MIN: i64 = -9223372036854775808; +pub const INT8_MAX: u32 = 127; +pub const INT16_MAX: u32 = 32767; +pub const INT32_MAX: u32 = 2147483647; pub const UINT8_MAX: u32 = 255; pub const UINT16_MAX: u32 = 65535; pub const UINT32_MAX: u32 = 4294967295; -pub const UINT64_MAX: i32 = -1; pub const INT_LEAST8_MIN: i32 = -128; pub const INT_LEAST16_MIN: i32 = -32768; pub const INT_LEAST32_MIN: i32 = -2147483648; -pub const INT_LEAST64_MIN: i64 = -9223372036854775808; pub const INT_LEAST8_MAX: u32 = 127; pub const INT_LEAST16_MAX: u32 = 32767; pub const INT_LEAST32_MAX: u32 = 2147483647; -pub const INT_LEAST64_MAX: u64 = 9223372036854775807; pub const UINT_LEAST8_MAX: u32 = 255; pub const UINT_LEAST16_MAX: u32 = 65535; pub const UINT_LEAST32_MAX: u32 = 4294967295; -pub const UINT_LEAST64_MAX: i32 = -1; pub const INT_FAST8_MIN: i32 = -128; -pub const INT_FAST16_MIN: i32 = -32768; -pub const INT_FAST32_MIN: i32 = -2147483648; -pub const INT_FAST64_MIN: i64 = -9223372036854775808; +pub const INT_FAST16_MIN: i64 = -9223372036854775808; +pub const INT_FAST32_MIN: i64 = -9223372036854775808; pub const INT_FAST8_MAX: u32 = 127; -pub const INT_FAST16_MAX: u32 = 32767; -pub const INT_FAST32_MAX: u32 = 2147483647; -pub const INT_FAST64_MAX: u64 = 9223372036854775807; +pub const INT_FAST16_MAX: u64 = 9223372036854775807; +pub const INT_FAST32_MAX: u64 = 9223372036854775807; pub const UINT_FAST8_MAX: u32 = 255; -pub const UINT_FAST16_MAX: u32 = 65535; -pub const UINT_FAST32_MAX: u32 = 4294967295; -pub const UINT_FAST64_MAX: i32 = -1; -pub const INTPTR_MAX: u64 = 9223372036854775807; +pub const UINT_FAST16_MAX: i32 = -1; +pub const UINT_FAST32_MAX: i32 = -1; pub const INTPTR_MIN: i64 = -9223372036854775808; +pub const INTPTR_MAX: u64 = 9223372036854775807; pub const UINTPTR_MAX: i32 = -1; -pub const SIZE_MAX: i32 = -1; -pub const RSIZE_MAX: i32 = -1; -pub const WINT_MIN: i32 = -2147483648; -pub const WINT_MAX: u32 = 2147483647; +pub const PTRDIFF_MIN: i64 = -9223372036854775808; +pub const PTRDIFF_MAX: u64 = 9223372036854775807; pub const SIG_ATOMIC_MIN: i32 = -2147483648; pub const SIG_ATOMIC_MAX: u32 = 2147483647; -pub const PRIO_PROCESS: u32 = 0; -pub const PRIO_PGRP: u32 = 1; -pub const PRIO_USER: u32 = 2; -pub const PRIO_DARWIN_THREAD: u32 = 3; -pub const PRIO_DARWIN_PROCESS: u32 = 4; -pub const PRIO_MIN: i32 = -20; -pub const PRIO_MAX: u32 = 20; -pub const PRIO_DARWIN_BG: u32 = 4096; -pub const PRIO_DARWIN_NONUI: u32 = 4097; -pub const RUSAGE_SELF: u32 = 0; -pub const RUSAGE_CHILDREN: i32 = -1; -pub const RUSAGE_INFO_V0: u32 = 0; -pub const RUSAGE_INFO_V1: u32 = 1; -pub const RUSAGE_INFO_V2: u32 = 2; -pub const RUSAGE_INFO_V3: u32 = 3; -pub const RUSAGE_INFO_V4: u32 = 4; -pub const RUSAGE_INFO_V5: u32 = 5; -pub const RUSAGE_INFO_CURRENT: u32 = 5; -pub const RU_PROC_RUNS_RESLIDE: u32 = 1; -pub const RLIMIT_CPU: u32 = 0; -pub const RLIMIT_FSIZE: u32 = 1; -pub const RLIMIT_DATA: u32 = 2; -pub const RLIMIT_STACK: u32 = 3; -pub const RLIMIT_CORE: u32 = 4; -pub const RLIMIT_AS: u32 = 5; -pub const RLIMIT_RSS: u32 = 5; -pub const RLIMIT_MEMLOCK: u32 = 6; -pub const RLIMIT_NPROC: u32 = 7; -pub const RLIMIT_NOFILE: u32 = 8; -pub const RLIM_NLIMITS: u32 = 9; -pub const _RLIMIT_POSIX_FLAG: u32 = 4096; -pub const RLIMIT_WAKEUPS_MONITOR: u32 = 1; -pub const RLIMIT_CPU_USAGE_MONITOR: u32 = 2; -pub const RLIMIT_THREAD_CPULIMITS: u32 = 3; -pub const RLIMIT_FOOTPRINT_INTERVAL: u32 = 4; -pub const WAKEMON_ENABLE: u32 = 1; -pub const WAKEMON_DISABLE: u32 = 2; -pub const WAKEMON_GET_PARAMS: u32 = 4; -pub const WAKEMON_SET_DEFAULTS: u32 = 8; -pub const WAKEMON_MAKE_FATAL: u32 = 16; -pub const CPUMON_MAKE_FATAL: u32 = 4096; -pub const FOOTPRINT_INTERVAL_RESET: u32 = 1; -pub const IOPOL_TYPE_DISK: u32 = 0; -pub const IOPOL_TYPE_VFS_ATIME_UPDATES: u32 = 2; -pub const IOPOL_TYPE_VFS_MATERIALIZE_DATALESS_FILES: u32 = 3; -pub const IOPOL_TYPE_VFS_STATFS_NO_DATA_VOLUME: u32 = 4; -pub const IOPOL_TYPE_VFS_TRIGGER_RESOLVE: u32 = 5; -pub const IOPOL_TYPE_VFS_IGNORE_CONTENT_PROTECTION: u32 = 6; -pub const IOPOL_TYPE_VFS_IGNORE_PERMISSIONS: u32 = 7; -pub const IOPOL_TYPE_VFS_SKIP_MTIME_UPDATE: u32 = 8; -pub const IOPOL_SCOPE_PROCESS: u32 = 0; -pub const IOPOL_SCOPE_THREAD: u32 = 1; -pub const IOPOL_SCOPE_DARWIN_BG: u32 = 2; -pub const IOPOL_DEFAULT: u32 = 0; -pub const IOPOL_IMPORTANT: u32 = 1; -pub const IOPOL_PASSIVE: u32 = 2; -pub const IOPOL_THROTTLE: u32 = 3; -pub const IOPOL_UTILITY: u32 = 4; -pub const IOPOL_STANDARD: u32 = 5; -pub const IOPOL_APPLICATION: u32 = 5; -pub const IOPOL_NORMAL: u32 = 1; -pub const IOPOL_ATIME_UPDATES_DEFAULT: u32 = 0; -pub const IOPOL_ATIME_UPDATES_OFF: u32 = 1; -pub const IOPOL_MATERIALIZE_DATALESS_FILES_DEFAULT: u32 = 0; -pub const IOPOL_MATERIALIZE_DATALESS_FILES_OFF: u32 = 1; -pub const IOPOL_MATERIALIZE_DATALESS_FILES_ON: u32 = 2; -pub const IOPOL_VFS_STATFS_NO_DATA_VOLUME_DEFAULT: u32 = 0; -pub const IOPOL_VFS_STATFS_FORCE_NO_DATA_VOLUME: u32 = 1; -pub const IOPOL_VFS_TRIGGER_RESOLVE_DEFAULT: u32 = 0; -pub const IOPOL_VFS_TRIGGER_RESOLVE_OFF: u32 = 1; -pub const IOPOL_VFS_CONTENT_PROTECTION_DEFAULT: u32 = 0; -pub const IOPOL_VFS_CONTENT_PROTECTION_IGNORE: u32 = 1; -pub const IOPOL_VFS_IGNORE_PERMISSIONS_OFF: u32 = 0; -pub const IOPOL_VFS_IGNORE_PERMISSIONS_ON: u32 = 1; -pub const IOPOL_VFS_SKIP_MTIME_UPDATE_OFF: u32 = 0; -pub const IOPOL_VFS_SKIP_MTIME_UPDATE_ON: u32 = 1; -pub const WNOHANG: u32 = 1; -pub const WUNTRACED: u32 = 2; -pub const WCOREFLAG: u32 = 128; -pub const _WSTOPPED: u32 = 127; -pub const WEXITED: u32 = 4; -pub const WSTOPPED: u32 = 8; -pub const WCONTINUED: u32 = 16; -pub const WNOWAIT: u32 = 32; -pub const WAIT_ANY: i32 = -1; -pub const WAIT_MYPGRP: u32 = 0; -pub const _QUAD_HIGHWORD: u32 = 1; -pub const _QUAD_LOWWORD: u32 = 0; -pub const __DARWIN_LITTLE_ENDIAN: u32 = 1234; -pub const __DARWIN_BIG_ENDIAN: u32 = 4321; -pub const __DARWIN_PDP_ENDIAN: u32 = 3412; -pub const __DARWIN_BYTE_ORDER: u32 = 1234; -pub const LITTLE_ENDIAN: u32 = 1234; -pub const BIG_ENDIAN: u32 = 4321; -pub const PDP_ENDIAN: u32 = 3412; -pub const BYTE_ORDER: u32 = 1234; -pub const EXIT_FAILURE: u32 = 1; -pub const EXIT_SUCCESS: u32 = 0; -pub const RAND_MAX: u32 = 2147483647; -pub const _USE_FORTIFY_LEVEL: u32 = 2; -pub const __HAS_FIXED_CHK_PROTOTYPES: u32 = 1; -pub const ORT_API_VERSION: u32 = 8; -pub type __int8_t = ::std::os::raw::c_schar; -pub type __uint8_t = ::std::os::raw::c_uchar; -pub type __int16_t = ::std::os::raw::c_short; -pub type __uint16_t = ::std::os::raw::c_ushort; -pub type __int32_t = ::std::os::raw::c_int; -pub type __uint32_t = ::std::os::raw::c_uint; -pub type __int64_t = ::std::os::raw::c_longlong; -pub type __uint64_t = ::std::os::raw::c_ulonglong; -pub type __darwin_intptr_t = ::std::os::raw::c_long; -pub type __darwin_natural_t = ::std::os::raw::c_uint; -pub type __darwin_ct_rune_t = ::std::os::raw::c_int; +pub const SIZE_MAX: i32 = -1; +pub const WINT_MIN: u32 = 0; +pub const WINT_MAX: u32 = 4294967295; +pub const _STRING_H: u32 = 1; +pub const _BITS_TYPES_LOCALE_T_H: u32 = 1; +pub const _BITS_TYPES___LOCALE_T_H: u32 = 1; +pub const _STRINGS_H: u32 = 1; +pub const ORT_API_VERSION: u32 = 11; +pub type wchar_t = ::std::os::raw::c_int; +#[repr(u32)] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum idtype_t { + P_ALL = 0, + P_PID = 1, + P_PGID = 2, +} +pub type _Float32 = f32; +pub type _Float64 = f64; +pub type _Float32x = f64; +pub type _Float64x = u128; #[repr(C)] -#[derive(Copy, Clone)] -pub union __mbstate_t { - pub __mbstate8: [::std::os::raw::c_char; 128usize], - pub _mbstateL: ::std::os::raw::c_longlong, +#[derive(Debug, Copy, Clone)] +pub struct div_t { + pub quot: ::std::os::raw::c_int, + pub rem: ::std::os::raw::c_int, } #[test] -fn bindgen_test_layout___mbstate_t() { - assert_eq!( - ::std::mem::size_of::<__mbstate_t>(), - 128usize, - concat!("Size of: ", stringify!(__mbstate_t)) - ); +fn bindgen_test_layout_div_t() { assert_eq!( - ::std::mem::align_of::<__mbstate_t>(), + ::std::mem::size_of::(), 8usize, - concat!("Alignment of ", stringify!(__mbstate_t)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__mbstate_t>())).__mbstate8 as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__mbstate_t), - "::", - stringify!(__mbstate8) - ) + concat!("Size of: ", stringify!(div_t)) ); assert_eq!( - unsafe { &(*(::std::ptr::null::<__mbstate_t>()))._mbstateL as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__mbstate_t), - "::", - stringify!(_mbstateL) - ) + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(div_t)) ); + fn test_field_quot() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).quot) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(div_t), + "::", + stringify!(quot) + ) + ); + } + test_field_quot(); + fn test_field_rem() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).rem) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(div_t), + "::", + stringify!(rem) + ) + ); + } + test_field_rem(); } -pub type __darwin_mbstate_t = __mbstate_t; -pub type __darwin_ptrdiff_t = ::std::os::raw::c_long; -pub type __darwin_size_t = ::std::os::raw::c_ulong; -pub type __darwin_va_list = __builtin_va_list; -pub type __darwin_wchar_t = ::std::os::raw::c_int; -pub type __darwin_rune_t = __darwin_wchar_t; -pub type __darwin_wint_t = ::std::os::raw::c_uint; -pub type __darwin_clock_t = ::std::os::raw::c_ulong; -pub type __darwin_socklen_t = __uint32_t; -pub type __darwin_ssize_t = ::std::os::raw::c_long; -pub type __darwin_time_t = ::std::os::raw::c_long; -pub type __darwin_blkcnt_t = __int64_t; -pub type __darwin_blksize_t = __int32_t; -pub type __darwin_dev_t = __int32_t; -pub type __darwin_fsblkcnt_t = ::std::os::raw::c_uint; -pub type __darwin_fsfilcnt_t = ::std::os::raw::c_uint; -pub type __darwin_gid_t = __uint32_t; -pub type __darwin_id_t = __uint32_t; -pub type __darwin_ino64_t = __uint64_t; -pub type __darwin_ino_t = __darwin_ino64_t; -pub type __darwin_mach_port_name_t = __darwin_natural_t; -pub type __darwin_mach_port_t = __darwin_mach_port_name_t; -pub type __darwin_mode_t = __uint16_t; -pub type __darwin_off_t = __int64_t; -pub type __darwin_pid_t = __int32_t; -pub type __darwin_sigset_t = __uint32_t; -pub type __darwin_suseconds_t = __int32_t; -pub type __darwin_uid_t = __uint32_t; -pub type __darwin_useconds_t = __uint32_t; -pub type __darwin_uuid_t = [::std::os::raw::c_uchar; 16usize]; -pub type __darwin_uuid_string_t = [::std::os::raw::c_char; 37usize]; #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct __darwin_pthread_handler_rec { - pub __routine: ::std::option::Option, - pub __arg: *mut ::std::os::raw::c_void, - pub __next: *mut __darwin_pthread_handler_rec, +pub struct ldiv_t { + pub quot: ::std::os::raw::c_long, + pub rem: ::std::os::raw::c_long, } #[test] -fn bindgen_test_layout___darwin_pthread_handler_rec() { - assert_eq!( - ::std::mem::size_of::<__darwin_pthread_handler_rec>(), - 24usize, - concat!("Size of: ", stringify!(__darwin_pthread_handler_rec)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_pthread_handler_rec>(), - 8usize, - concat!("Alignment of ", stringify!(__darwin_pthread_handler_rec)) - ); +fn bindgen_test_layout_ldiv_t() { assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_pthread_handler_rec>())).__routine as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_pthread_handler_rec), - "::", - stringify!(__routine) - ) + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(ldiv_t)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_pthread_handler_rec>())).__arg as *const _ as usize - }, + ::std::mem::align_of::(), 8usize, - concat!( - "Offset of field: ", - stringify!(__darwin_pthread_handler_rec), - "::", - stringify!(__arg) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_pthread_handler_rec>())).__next as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_pthread_handler_rec), - "::", - stringify!(__next) - ) + concat!("Alignment of ", stringify!(ldiv_t)) ); + fn test_field_quot() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).quot) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ldiv_t), + "::", + stringify!(quot) + ) + ); + } + test_field_quot(); + fn test_field_rem() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).rem) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(ldiv_t), + "::", + stringify!(rem) + ) + ); + } + test_field_rem(); } #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct _opaque_pthread_attr_t { - pub __sig: ::std::os::raw::c_long, - pub __opaque: [::std::os::raw::c_char; 56usize], +pub struct lldiv_t { + pub quot: ::std::os::raw::c_longlong, + pub rem: ::std::os::raw::c_longlong, } #[test] -fn bindgen_test_layout__opaque_pthread_attr_t() { - assert_eq!( - ::std::mem::size_of::<_opaque_pthread_attr_t>(), - 64usize, - concat!("Size of: ", stringify!(_opaque_pthread_attr_t)) - ); - assert_eq!( - ::std::mem::align_of::<_opaque_pthread_attr_t>(), - 8usize, - concat!("Alignment of ", stringify!(_opaque_pthread_attr_t)) - ); +fn bindgen_test_layout_lldiv_t() { assert_eq!( - unsafe { &(*(::std::ptr::null::<_opaque_pthread_attr_t>())).__sig as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_attr_t), - "::", - stringify!(__sig) - ) + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(lldiv_t)) ); assert_eq!( - unsafe { &(*(::std::ptr::null::<_opaque_pthread_attr_t>())).__opaque as *const _ as usize }, + ::std::mem::align_of::(), 8usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_attr_t), - "::", - stringify!(__opaque) - ) + concat!("Alignment of ", stringify!(lldiv_t)) ); + fn test_field_quot() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).quot) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(lldiv_t), + "::", + stringify!(quot) + ) + ); + } + test_field_quot(); + fn test_field_rem() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).rem) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(lldiv_t), + "::", + stringify!(rem) + ) + ); + } + test_field_rem(); +} +extern "C" { + pub fn __ctype_get_mb_cur_max() -> usize; +} +extern "C" { + pub fn atof(__nptr: *const ::std::os::raw::c_char) -> f64; +} +extern "C" { + pub fn atoi(__nptr: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn atol(__nptr: *const ::std::os::raw::c_char) -> ::std::os::raw::c_long; +} +extern "C" { + pub fn atoll(__nptr: *const ::std::os::raw::c_char) -> ::std::os::raw::c_longlong; +} +extern "C" { + pub fn strtod( + __nptr: *const ::std::os::raw::c_char, + __endptr: *mut *mut ::std::os::raw::c_char, + ) -> f64; +} +extern "C" { + pub fn strtof( + __nptr: *const ::std::os::raw::c_char, + __endptr: *mut *mut ::std::os::raw::c_char, + ) -> f32; +} +extern "C" { + pub fn strtold( + __nptr: *const ::std::os::raw::c_char, + __endptr: *mut *mut ::std::os::raw::c_char, + ) -> u128; +} +extern "C" { + pub fn strtol( + __nptr: *const ::std::os::raw::c_char, + __endptr: *mut *mut ::std::os::raw::c_char, + __base: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_long; +} +extern "C" { + pub fn strtoul( + __nptr: *const ::std::os::raw::c_char, + __endptr: *mut *mut ::std::os::raw::c_char, + __base: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_ulong; +} +extern "C" { + pub fn strtoq( + __nptr: *const ::std::os::raw::c_char, + __endptr: *mut *mut ::std::os::raw::c_char, + __base: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_longlong; +} +extern "C" { + pub fn strtouq( + __nptr: *const ::std::os::raw::c_char, + __endptr: *mut *mut ::std::os::raw::c_char, + __base: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_ulonglong; +} +extern "C" { + pub fn strtoll( + __nptr: *const ::std::os::raw::c_char, + __endptr: *mut *mut ::std::os::raw::c_char, + __base: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_longlong; +} +extern "C" { + pub fn strtoull( + __nptr: *const ::std::os::raw::c_char, + __endptr: *mut *mut ::std::os::raw::c_char, + __base: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_ulonglong; +} +extern "C" { + pub fn l64a(__n: ::std::os::raw::c_long) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn a64l(__s: *const ::std::os::raw::c_char) -> ::std::os::raw::c_long; } +pub type __u_char = ::std::os::raw::c_uchar; +pub type __u_short = ::std::os::raw::c_ushort; +pub type __u_int = ::std::os::raw::c_uint; +pub type __u_long = ::std::os::raw::c_ulong; +pub type __int8_t = ::std::os::raw::c_schar; +pub type __uint8_t = ::std::os::raw::c_uchar; +pub type __int16_t = ::std::os::raw::c_short; +pub type __uint16_t = ::std::os::raw::c_ushort; +pub type __int32_t = ::std::os::raw::c_int; +pub type __uint32_t = ::std::os::raw::c_uint; +pub type __int64_t = ::std::os::raw::c_long; +pub type __uint64_t = ::std::os::raw::c_ulong; +pub type __int_least8_t = __int8_t; +pub type __uint_least8_t = __uint8_t; +pub type __int_least16_t = __int16_t; +pub type __uint_least16_t = __uint16_t; +pub type __int_least32_t = __int32_t; +pub type __uint_least32_t = __uint32_t; +pub type __int_least64_t = __int64_t; +pub type __uint_least64_t = __uint64_t; +pub type __quad_t = ::std::os::raw::c_long; +pub type __u_quad_t = ::std::os::raw::c_ulong; +pub type __intmax_t = ::std::os::raw::c_long; +pub type __uintmax_t = ::std::os::raw::c_ulong; +pub type __dev_t = ::std::os::raw::c_ulong; +pub type __uid_t = ::std::os::raw::c_uint; +pub type __gid_t = ::std::os::raw::c_uint; +pub type __ino_t = ::std::os::raw::c_ulong; +pub type __ino64_t = ::std::os::raw::c_ulong; +pub type __mode_t = ::std::os::raw::c_uint; +pub type __nlink_t = ::std::os::raw::c_ulong; +pub type __off_t = ::std::os::raw::c_long; +pub type __off64_t = ::std::os::raw::c_long; +pub type __pid_t = ::std::os::raw::c_int; #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct _opaque_pthread_cond_t { - pub __sig: ::std::os::raw::c_long, - pub __opaque: [::std::os::raw::c_char; 40usize], +pub struct __fsid_t { + pub __val: [::std::os::raw::c_int; 2usize], } #[test] -fn bindgen_test_layout__opaque_pthread_cond_t() { - assert_eq!( - ::std::mem::size_of::<_opaque_pthread_cond_t>(), - 48usize, - concat!("Size of: ", stringify!(_opaque_pthread_cond_t)) - ); +fn bindgen_test_layout___fsid_t() { assert_eq!( - ::std::mem::align_of::<_opaque_pthread_cond_t>(), + ::std::mem::size_of::<__fsid_t>(), 8usize, - concat!("Alignment of ", stringify!(_opaque_pthread_cond_t)) + concat!("Size of: ", stringify!(__fsid_t)) ); assert_eq!( - unsafe { &(*(::std::ptr::null::<_opaque_pthread_cond_t>())).__sig as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_cond_t), - "::", - stringify!(__sig) - ) + ::std::mem::align_of::<__fsid_t>(), + 4usize, + concat!("Alignment of ", stringify!(__fsid_t)) + ); + fn test_field___val() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__fsid_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__val) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__fsid_t), + "::", + stringify!(__val) + ) + ); + } + test_field___val(); +} +pub type __clock_t = ::std::os::raw::c_long; +pub type __rlim_t = ::std::os::raw::c_ulong; +pub type __rlim64_t = ::std::os::raw::c_ulong; +pub type __id_t = ::std::os::raw::c_uint; +pub type __time_t = ::std::os::raw::c_long; +pub type __useconds_t = ::std::os::raw::c_uint; +pub type __suseconds_t = ::std::os::raw::c_long; +pub type __daddr_t = ::std::os::raw::c_int; +pub type __key_t = ::std::os::raw::c_int; +pub type __clockid_t = ::std::os::raw::c_int; +pub type __timer_t = *mut ::std::os::raw::c_void; +pub type __blksize_t = ::std::os::raw::c_long; +pub type __blkcnt_t = ::std::os::raw::c_long; +pub type __blkcnt64_t = ::std::os::raw::c_long; +pub type __fsblkcnt_t = ::std::os::raw::c_ulong; +pub type __fsblkcnt64_t = ::std::os::raw::c_ulong; +pub type __fsfilcnt_t = ::std::os::raw::c_ulong; +pub type __fsfilcnt64_t = ::std::os::raw::c_ulong; +pub type __fsword_t = ::std::os::raw::c_long; +pub type __ssize_t = ::std::os::raw::c_long; +pub type __syscall_slong_t = ::std::os::raw::c_long; +pub type __syscall_ulong_t = ::std::os::raw::c_ulong; +pub type __loff_t = __off64_t; +pub type __caddr_t = *mut ::std::os::raw::c_char; +pub type __intptr_t = ::std::os::raw::c_long; +pub type __socklen_t = ::std::os::raw::c_uint; +pub type __sig_atomic_t = ::std::os::raw::c_int; +pub type u_char = __u_char; +pub type u_short = __u_short; +pub type u_int = __u_int; +pub type u_long = __u_long; +pub type quad_t = __quad_t; +pub type u_quad_t = __u_quad_t; +pub type fsid_t = __fsid_t; +pub type loff_t = __loff_t; +pub type ino_t = __ino_t; +pub type dev_t = __dev_t; +pub type gid_t = __gid_t; +pub type mode_t = __mode_t; +pub type nlink_t = __nlink_t; +pub type uid_t = __uid_t; +pub type off_t = __off_t; +pub type pid_t = __pid_t; +pub type id_t = __id_t; +pub type daddr_t = __daddr_t; +pub type caddr_t = __caddr_t; +pub type key_t = __key_t; +pub type clock_t = __clock_t; +pub type clockid_t = __clockid_t; +pub type time_t = __time_t; +pub type timer_t = __timer_t; +pub type ulong = ::std::os::raw::c_ulong; +pub type ushort = ::std::os::raw::c_ushort; +pub type uint = ::std::os::raw::c_uint; +pub type u_int8_t = __uint8_t; +pub type u_int16_t = __uint16_t; +pub type u_int32_t = __uint32_t; +pub type u_int64_t = __uint64_t; +pub type register_t = ::std::os::raw::c_long; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __sigset_t { + pub __val: [::std::os::raw::c_ulong; 16usize], +} +#[test] +fn bindgen_test_layout___sigset_t() { + assert_eq!( + ::std::mem::size_of::<__sigset_t>(), + 128usize, + concat!("Size of: ", stringify!(__sigset_t)) ); assert_eq!( - unsafe { &(*(::std::ptr::null::<_opaque_pthread_cond_t>())).__opaque as *const _ as usize }, + ::std::mem::align_of::<__sigset_t>(), 8usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_cond_t), - "::", - stringify!(__opaque) - ) - ); + concat!("Alignment of ", stringify!(__sigset_t)) + ); + fn test_field___val() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__sigset_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__val) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__sigset_t), + "::", + stringify!(__val) + ) + ); + } + test_field___val(); } +pub type sigset_t = __sigset_t; #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct _opaque_pthread_condattr_t { - pub __sig: ::std::os::raw::c_long, - pub __opaque: [::std::os::raw::c_char; 8usize], +pub struct timeval { + pub tv_sec: __time_t, + pub tv_usec: __suseconds_t, } #[test] -fn bindgen_test_layout__opaque_pthread_condattr_t() { +fn bindgen_test_layout_timeval() { assert_eq!( - ::std::mem::size_of::<_opaque_pthread_condattr_t>(), + ::std::mem::size_of::(), 16usize, - concat!("Size of: ", stringify!(_opaque_pthread_condattr_t)) - ); - assert_eq!( - ::std::mem::align_of::<_opaque_pthread_condattr_t>(), - 8usize, - concat!("Alignment of ", stringify!(_opaque_pthread_condattr_t)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<_opaque_pthread_condattr_t>())).__sig as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_condattr_t), - "::", - stringify!(__sig) - ) + concat!("Size of: ", stringify!(timeval)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<_opaque_pthread_condattr_t>())).__opaque as *const _ as usize - }, + ::std::mem::align_of::(), 8usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_condattr_t), - "::", - stringify!(__opaque) - ) + concat!("Alignment of ", stringify!(timeval)) ); + fn test_field_tv_sec() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).tv_sec) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(timeval), + "::", + stringify!(tv_sec) + ) + ); + } + test_field_tv_sec(); + fn test_field_tv_usec() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).tv_usec) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(timeval), + "::", + stringify!(tv_usec) + ) + ); + } + test_field_tv_usec(); } #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct _opaque_pthread_mutex_t { - pub __sig: ::std::os::raw::c_long, - pub __opaque: [::std::os::raw::c_char; 56usize], +pub struct timespec { + pub tv_sec: __time_t, + pub tv_nsec: __syscall_slong_t, } #[test] -fn bindgen_test_layout__opaque_pthread_mutex_t() { +fn bindgen_test_layout_timespec() { assert_eq!( - ::std::mem::size_of::<_opaque_pthread_mutex_t>(), - 64usize, - concat!("Size of: ", stringify!(_opaque_pthread_mutex_t)) + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(timespec)) ); assert_eq!( - ::std::mem::align_of::<_opaque_pthread_mutex_t>(), + ::std::mem::align_of::(), 8usize, - concat!("Alignment of ", stringify!(_opaque_pthread_mutex_t)) - ); + concat!("Alignment of ", stringify!(timespec)) + ); + fn test_field_tv_sec() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).tv_sec) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(timespec), + "::", + stringify!(tv_sec) + ) + ); + } + test_field_tv_sec(); + fn test_field_tv_nsec() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).tv_nsec) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(timespec), + "::", + stringify!(tv_nsec) + ) + ); + } + test_field_tv_nsec(); +} +pub type suseconds_t = __suseconds_t; +pub type __fd_mask = ::std::os::raw::c_long; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct fd_set { + pub __fds_bits: [__fd_mask; 16usize], +} +#[test] +fn bindgen_test_layout_fd_set() { assert_eq!( - unsafe { &(*(::std::ptr::null::<_opaque_pthread_mutex_t>())).__sig as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_mutex_t), - "::", - stringify!(__sig) - ) + ::std::mem::size_of::(), + 128usize, + concat!("Size of: ", stringify!(fd_set)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<_opaque_pthread_mutex_t>())).__opaque as *const _ as usize - }, + ::std::mem::align_of::(), 8usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_mutex_t), - "::", - stringify!(__opaque) - ) - ); + concat!("Alignment of ", stringify!(fd_set)) + ); + fn test_field___fds_bits() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__fds_bits) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(fd_set), + "::", + stringify!(__fds_bits) + ) + ); + } + test_field___fds_bits(); +} +pub type fd_mask = __fd_mask; +extern "C" { + pub fn select( + __nfds: ::std::os::raw::c_int, + __readfds: *mut fd_set, + __writefds: *mut fd_set, + __exceptfds: *mut fd_set, + __timeout: *mut timeval, + ) -> ::std::os::raw::c_int; } +extern "C" { + pub fn pselect( + __nfds: ::std::os::raw::c_int, + __readfds: *mut fd_set, + __writefds: *mut fd_set, + __exceptfds: *mut fd_set, + __timeout: *const timespec, + __sigmask: *const __sigset_t, + ) -> ::std::os::raw::c_int; +} +pub type blksize_t = __blksize_t; +pub type blkcnt_t = __blkcnt_t; +pub type fsblkcnt_t = __fsblkcnt_t; +pub type fsfilcnt_t = __fsfilcnt_t; #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct _opaque_pthread_mutexattr_t { - pub __sig: ::std::os::raw::c_long, - pub __opaque: [::std::os::raw::c_char; 8usize], +pub struct __pthread_internal_list { + pub __prev: *mut __pthread_internal_list, + pub __next: *mut __pthread_internal_list, } #[test] -fn bindgen_test_layout__opaque_pthread_mutexattr_t() { +fn bindgen_test_layout___pthread_internal_list() { assert_eq!( - ::std::mem::size_of::<_opaque_pthread_mutexattr_t>(), + ::std::mem::size_of::<__pthread_internal_list>(), 16usize, - concat!("Size of: ", stringify!(_opaque_pthread_mutexattr_t)) + concat!("Size of: ", stringify!(__pthread_internal_list)) ); assert_eq!( - ::std::mem::align_of::<_opaque_pthread_mutexattr_t>(), + ::std::mem::align_of::<__pthread_internal_list>(), 8usize, - concat!("Alignment of ", stringify!(_opaque_pthread_mutexattr_t)) - ); + concat!("Alignment of ", stringify!(__pthread_internal_list)) + ); + fn test_field___prev() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_internal_list>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__prev) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__pthread_internal_list), + "::", + stringify!(__prev) + ) + ); + } + test_field___prev(); + fn test_field___next() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_internal_list>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__next) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__pthread_internal_list), + "::", + stringify!(__next) + ) + ); + } + test_field___next(); +} +pub type __pthread_list_t = __pthread_internal_list; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __pthread_internal_slist { + pub __next: *mut __pthread_internal_slist, +} +#[test] +fn bindgen_test_layout___pthread_internal_slist() { assert_eq!( - unsafe { - &(*(::std::ptr::null::<_opaque_pthread_mutexattr_t>())).__sig as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_mutexattr_t), - "::", - stringify!(__sig) - ) + ::std::mem::size_of::<__pthread_internal_slist>(), + 8usize, + concat!("Size of: ", stringify!(__pthread_internal_slist)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<_opaque_pthread_mutexattr_t>())).__opaque as *const _ as usize - }, + ::std::mem::align_of::<__pthread_internal_slist>(), 8usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_mutexattr_t), - "::", - stringify!(__opaque) - ) - ); + concat!("Alignment of ", stringify!(__pthread_internal_slist)) + ); + fn test_field___next() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_internal_slist>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__next) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__pthread_internal_slist), + "::", + stringify!(__next) + ) + ); + } + test_field___next(); } +pub type __pthread_slist_t = __pthread_internal_slist; #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct _opaque_pthread_once_t { - pub __sig: ::std::os::raw::c_long, - pub __opaque: [::std::os::raw::c_char; 8usize], +pub struct __pthread_mutex_s { + pub __lock: ::std::os::raw::c_int, + pub __count: ::std::os::raw::c_uint, + pub __owner: ::std::os::raw::c_int, + pub __nusers: ::std::os::raw::c_uint, + pub __kind: ::std::os::raw::c_int, + pub __spins: ::std::os::raw::c_short, + pub __elision: ::std::os::raw::c_short, + pub __list: __pthread_list_t, } #[test] -fn bindgen_test_layout__opaque_pthread_once_t() { +fn bindgen_test_layout___pthread_mutex_s() { assert_eq!( - ::std::mem::size_of::<_opaque_pthread_once_t>(), - 16usize, - concat!("Size of: ", stringify!(_opaque_pthread_once_t)) + ::std::mem::size_of::<__pthread_mutex_s>(), + 40usize, + concat!("Size of: ", stringify!(__pthread_mutex_s)) ); assert_eq!( - ::std::mem::align_of::<_opaque_pthread_once_t>(), + ::std::mem::align_of::<__pthread_mutex_s>(), 8usize, - concat!("Alignment of ", stringify!(_opaque_pthread_once_t)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_opaque_pthread_once_t>())).__sig as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_once_t), - "::", - stringify!(__sig) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_opaque_pthread_once_t>())).__opaque as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_once_t), - "::", - stringify!(__opaque) - ) - ); + concat!("Alignment of ", stringify!(__pthread_mutex_s)) + ); + fn test_field___lock() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_mutex_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__lock) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__pthread_mutex_s), + "::", + stringify!(__lock) + ) + ); + } + test_field___lock(); + fn test_field___count() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_mutex_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__count) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(__pthread_mutex_s), + "::", + stringify!(__count) + ) + ); + } + test_field___count(); + fn test_field___owner() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_mutex_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__owner) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__pthread_mutex_s), + "::", + stringify!(__owner) + ) + ); + } + test_field___owner(); + fn test_field___nusers() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_mutex_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__nusers) as usize - ptr as usize + }, + 12usize, + concat!( + "Offset of field: ", + stringify!(__pthread_mutex_s), + "::", + stringify!(__nusers) + ) + ); + } + test_field___nusers(); + fn test_field___kind() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_mutex_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__kind) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(__pthread_mutex_s), + "::", + stringify!(__kind) + ) + ); + } + test_field___kind(); + fn test_field___spins() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_mutex_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__spins) as usize - ptr as usize + }, + 20usize, + concat!( + "Offset of field: ", + stringify!(__pthread_mutex_s), + "::", + stringify!(__spins) + ) + ); + } + test_field___spins(); + fn test_field___elision() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_mutex_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__elision) as usize - ptr as usize + }, + 22usize, + concat!( + "Offset of field: ", + stringify!(__pthread_mutex_s), + "::", + stringify!(__elision) + ) + ); + } + test_field___elision(); + fn test_field___list() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_mutex_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__list) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(__pthread_mutex_s), + "::", + stringify!(__list) + ) + ); + } + test_field___list(); } #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct _opaque_pthread_rwlock_t { - pub __sig: ::std::os::raw::c_long, - pub __opaque: [::std::os::raw::c_char; 192usize], +pub struct __pthread_rwlock_arch_t { + pub __readers: ::std::os::raw::c_uint, + pub __writers: ::std::os::raw::c_uint, + pub __wrphase_futex: ::std::os::raw::c_uint, + pub __writers_futex: ::std::os::raw::c_uint, + pub __pad3: ::std::os::raw::c_uint, + pub __pad4: ::std::os::raw::c_uint, + pub __cur_writer: ::std::os::raw::c_int, + pub __shared: ::std::os::raw::c_int, + pub __rwelision: ::std::os::raw::c_schar, + pub __pad1: [::std::os::raw::c_uchar; 7usize], + pub __pad2: ::std::os::raw::c_ulong, + pub __flags: ::std::os::raw::c_uint, } #[test] -fn bindgen_test_layout__opaque_pthread_rwlock_t() { - assert_eq!( - ::std::mem::size_of::<_opaque_pthread_rwlock_t>(), - 200usize, - concat!("Size of: ", stringify!(_opaque_pthread_rwlock_t)) - ); +fn bindgen_test_layout___pthread_rwlock_arch_t() { assert_eq!( - ::std::mem::align_of::<_opaque_pthread_rwlock_t>(), - 8usize, - concat!("Alignment of ", stringify!(_opaque_pthread_rwlock_t)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_opaque_pthread_rwlock_t>())).__sig as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_rwlock_t), - "::", - stringify!(__sig) - ) + ::std::mem::size_of::<__pthread_rwlock_arch_t>(), + 56usize, + concat!("Size of: ", stringify!(__pthread_rwlock_arch_t)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<_opaque_pthread_rwlock_t>())).__opaque as *const _ as usize - }, + ::std::mem::align_of::<__pthread_rwlock_arch_t>(), 8usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_rwlock_t), - "::", - stringify!(__opaque) - ) - ); + concat!("Alignment of ", stringify!(__pthread_rwlock_arch_t)) + ); + fn test_field___readers() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_rwlock_arch_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__readers) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__pthread_rwlock_arch_t), + "::", + stringify!(__readers) + ) + ); + } + test_field___readers(); + fn test_field___writers() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_rwlock_arch_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__writers) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(__pthread_rwlock_arch_t), + "::", + stringify!(__writers) + ) + ); + } + test_field___writers(); + fn test_field___wrphase_futex() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_rwlock_arch_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__wrphase_futex) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__pthread_rwlock_arch_t), + "::", + stringify!(__wrphase_futex) + ) + ); + } + test_field___wrphase_futex(); + fn test_field___writers_futex() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_rwlock_arch_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__writers_futex) as usize - ptr as usize + }, + 12usize, + concat!( + "Offset of field: ", + stringify!(__pthread_rwlock_arch_t), + "::", + stringify!(__writers_futex) + ) + ); + } + test_field___writers_futex(); + fn test_field___pad3() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_rwlock_arch_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__pad3) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(__pthread_rwlock_arch_t), + "::", + stringify!(__pad3) + ) + ); + } + test_field___pad3(); + fn test_field___pad4() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_rwlock_arch_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__pad4) as usize - ptr as usize + }, + 20usize, + concat!( + "Offset of field: ", + stringify!(__pthread_rwlock_arch_t), + "::", + stringify!(__pad4) + ) + ); + } + test_field___pad4(); + fn test_field___cur_writer() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_rwlock_arch_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__cur_writer) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(__pthread_rwlock_arch_t), + "::", + stringify!(__cur_writer) + ) + ); + } + test_field___cur_writer(); + fn test_field___shared() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_rwlock_arch_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__shared) as usize - ptr as usize + }, + 28usize, + concat!( + "Offset of field: ", + stringify!(__pthread_rwlock_arch_t), + "::", + stringify!(__shared) + ) + ); + } + test_field___shared(); + fn test_field___rwelision() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_rwlock_arch_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__rwelision) as usize - ptr as usize + }, + 32usize, + concat!( + "Offset of field: ", + stringify!(__pthread_rwlock_arch_t), + "::", + stringify!(__rwelision) + ) + ); + } + test_field___rwelision(); + fn test_field___pad1() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_rwlock_arch_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__pad1) as usize - ptr as usize + }, + 33usize, + concat!( + "Offset of field: ", + stringify!(__pthread_rwlock_arch_t), + "::", + stringify!(__pad1) + ) + ); + } + test_field___pad1(); + fn test_field___pad2() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_rwlock_arch_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__pad2) as usize - ptr as usize + }, + 40usize, + concat!( + "Offset of field: ", + stringify!(__pthread_rwlock_arch_t), + "::", + stringify!(__pad2) + ) + ); + } + test_field___pad2(); + fn test_field___flags() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_rwlock_arch_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__flags) as usize - ptr as usize + }, + 48usize, + concat!( + "Offset of field: ", + stringify!(__pthread_rwlock_arch_t), + "::", + stringify!(__flags) + ) + ); + } + test_field___flags(); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct __pthread_cond_s { + pub __bindgen_anon_1: __pthread_cond_s__bindgen_ty_1, + pub __bindgen_anon_2: __pthread_cond_s__bindgen_ty_2, + pub __g_refs: [::std::os::raw::c_uint; 2usize], + pub __g_size: [::std::os::raw::c_uint; 2usize], + pub __g1_orig_size: ::std::os::raw::c_uint, + pub __wrefs: ::std::os::raw::c_uint, + pub __g_signals: [::std::os::raw::c_uint; 2usize], +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union __pthread_cond_s__bindgen_ty_1 { + pub __wseq: ::std::os::raw::c_ulonglong, + pub __wseq32: __pthread_cond_s__bindgen_ty_1__bindgen_ty_1, } #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct _opaque_pthread_rwlockattr_t { - pub __sig: ::std::os::raw::c_long, - pub __opaque: [::std::os::raw::c_char; 16usize], +pub struct __pthread_cond_s__bindgen_ty_1__bindgen_ty_1 { + pub __low: ::std::os::raw::c_uint, + pub __high: ::std::os::raw::c_uint, } #[test] -fn bindgen_test_layout__opaque_pthread_rwlockattr_t() { - assert_eq!( - ::std::mem::size_of::<_opaque_pthread_rwlockattr_t>(), - 24usize, - concat!("Size of: ", stringify!(_opaque_pthread_rwlockattr_t)) - ); +fn bindgen_test_layout___pthread_cond_s__bindgen_ty_1__bindgen_ty_1() { assert_eq!( - ::std::mem::align_of::<_opaque_pthread_rwlockattr_t>(), + ::std::mem::size_of::<__pthread_cond_s__bindgen_ty_1__bindgen_ty_1>(), 8usize, - concat!("Alignment of ", stringify!(_opaque_pthread_rwlockattr_t)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<_opaque_pthread_rwlockattr_t>())).__sig as *const _ as usize - }, - 0usize, concat!( - "Offset of field: ", - stringify!(_opaque_pthread_rwlockattr_t), - "::", - stringify!(__sig) + "Size of: ", + stringify!(__pthread_cond_s__bindgen_ty_1__bindgen_ty_1) ) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<_opaque_pthread_rwlockattr_t>())).__opaque as *const _ as usize - }, - 8usize, + ::std::mem::align_of::<__pthread_cond_s__bindgen_ty_1__bindgen_ty_1>(), + 4usize, concat!( - "Offset of field: ", - stringify!(_opaque_pthread_rwlockattr_t), - "::", - stringify!(__opaque) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct _opaque_pthread_t { - pub __sig: ::std::os::raw::c_long, - pub __cleanup_stack: *mut __darwin_pthread_handler_rec, - pub __opaque: [::std::os::raw::c_char; 8176usize], + "Alignment of ", + stringify!(__pthread_cond_s__bindgen_ty_1__bindgen_ty_1) + ) + ); + fn test_field___low() { + assert_eq!( + unsafe { + let uninit = + ::std::mem::MaybeUninit::<__pthread_cond_s__bindgen_ty_1__bindgen_ty_1>::uninit( + ); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__low) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(__low) + ) + ); + } + test_field___low(); + fn test_field___high() { + assert_eq!( + unsafe { + let uninit = + ::std::mem::MaybeUninit::<__pthread_cond_s__bindgen_ty_1__bindgen_ty_1>::uninit( + ); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__high) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(__high) + ) + ); + } + test_field___high(); } #[test] -fn bindgen_test_layout__opaque_pthread_t() { - assert_eq!( - ::std::mem::size_of::<_opaque_pthread_t>(), - 8192usize, - concat!("Size of: ", stringify!(_opaque_pthread_t)) - ); +fn bindgen_test_layout___pthread_cond_s__bindgen_ty_1() { assert_eq!( - ::std::mem::align_of::<_opaque_pthread_t>(), + ::std::mem::size_of::<__pthread_cond_s__bindgen_ty_1>(), 8usize, - concat!("Alignment of ", stringify!(_opaque_pthread_t)) + concat!("Size of: ", stringify!(__pthread_cond_s__bindgen_ty_1)) ); assert_eq!( - unsafe { &(*(::std::ptr::null::<_opaque_pthread_t>())).__sig as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_t), - "::", - stringify!(__sig) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<_opaque_pthread_t>())).__cleanup_stack as *const _ as usize - }, + ::std::mem::align_of::<__pthread_cond_s__bindgen_ty_1>(), 8usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_t), - "::", - stringify!(__cleanup_stack) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_opaque_pthread_t>())).__opaque as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_t), - "::", - stringify!(__opaque) - ) - ); + concat!("Alignment of ", stringify!(__pthread_cond_s__bindgen_ty_1)) + ); + fn test_field___wseq() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_cond_s__bindgen_ty_1>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__wseq) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s__bindgen_ty_1), + "::", + stringify!(__wseq) + ) + ); + } + test_field___wseq(); + fn test_field___wseq32() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_cond_s__bindgen_ty_1>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__wseq32) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s__bindgen_ty_1), + "::", + stringify!(__wseq32) + ) + ); + } + test_field___wseq32(); } -pub type __darwin_pthread_attr_t = _opaque_pthread_attr_t; -pub type __darwin_pthread_cond_t = _opaque_pthread_cond_t; -pub type __darwin_pthread_condattr_t = _opaque_pthread_condattr_t; -pub type __darwin_pthread_key_t = ::std::os::raw::c_ulong; -pub type __darwin_pthread_mutex_t = _opaque_pthread_mutex_t; -pub type __darwin_pthread_mutexattr_t = _opaque_pthread_mutexattr_t; -pub type __darwin_pthread_once_t = _opaque_pthread_once_t; -pub type __darwin_pthread_rwlock_t = _opaque_pthread_rwlock_t; -pub type __darwin_pthread_rwlockattr_t = _opaque_pthread_rwlockattr_t; -pub type __darwin_pthread_t = *mut _opaque_pthread_t; -pub type __darwin_nl_item = ::std::os::raw::c_int; -pub type __darwin_wctrans_t = ::std::os::raw::c_int; -pub type __darwin_wctype_t = __uint32_t; -#[repr(u32)] -#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum idtype_t { - P_ALL = 0, - P_PID = 1, - P_PGID = 2, +#[repr(C)] +#[derive(Copy, Clone)] +pub union __pthread_cond_s__bindgen_ty_2 { + pub __g1_start: ::std::os::raw::c_ulonglong, + pub __g1_start32: __pthread_cond_s__bindgen_ty_2__bindgen_ty_1, } -pub type pid_t = __darwin_pid_t; -pub type id_t = __darwin_id_t; -pub type sig_atomic_t = ::std::os::raw::c_int; -pub type u_int8_t = ::std::os::raw::c_uchar; -pub type u_int16_t = ::std::os::raw::c_ushort; -pub type u_int32_t = ::std::os::raw::c_uint; -pub type u_int64_t = ::std::os::raw::c_ulonglong; -pub type register_t = i64; -pub type user_addr_t = u_int64_t; -pub type user_size_t = u_int64_t; -pub type user_ssize_t = i64; -pub type user_long_t = i64; -pub type user_ulong_t = u_int64_t; -pub type user_time_t = i64; -pub type user_off_t = i64; -pub type syscall_arg_t = u_int64_t; #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct __darwin_i386_thread_state { - pub __eax: ::std::os::raw::c_uint, - pub __ebx: ::std::os::raw::c_uint, - pub __ecx: ::std::os::raw::c_uint, - pub __edx: ::std::os::raw::c_uint, - pub __edi: ::std::os::raw::c_uint, - pub __esi: ::std::os::raw::c_uint, - pub __ebp: ::std::os::raw::c_uint, - pub __esp: ::std::os::raw::c_uint, - pub __ss: ::std::os::raw::c_uint, - pub __eflags: ::std::os::raw::c_uint, - pub __eip: ::std::os::raw::c_uint, - pub __cs: ::std::os::raw::c_uint, - pub __ds: ::std::os::raw::c_uint, - pub __es: ::std::os::raw::c_uint, - pub __fs: ::std::os::raw::c_uint, - pub __gs: ::std::os::raw::c_uint, +pub struct __pthread_cond_s__bindgen_ty_2__bindgen_ty_1 { + pub __low: ::std::os::raw::c_uint, + pub __high: ::std::os::raw::c_uint, } #[test] -fn bindgen_test_layout___darwin_i386_thread_state() { - assert_eq!( - ::std::mem::size_of::<__darwin_i386_thread_state>(), - 64usize, - concat!("Size of: ", stringify!(__darwin_i386_thread_state)) - ); +fn bindgen_test_layout___pthread_cond_s__bindgen_ty_2__bindgen_ty_1() { assert_eq!( - ::std::mem::align_of::<__darwin_i386_thread_state>(), - 4usize, - concat!("Alignment of ", stringify!(__darwin_i386_thread_state)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_thread_state>())).__eax as *const _ as usize - }, - 0usize, + ::std::mem::size_of::<__pthread_cond_s__bindgen_ty_2__bindgen_ty_1>(), + 8usize, concat!( - "Offset of field: ", - stringify!(__darwin_i386_thread_state), - "::", - stringify!(__eax) + "Size of: ", + stringify!(__pthread_cond_s__bindgen_ty_2__bindgen_ty_1) ) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_thread_state>())).__ebx as *const _ as usize - }, + ::std::mem::align_of::<__pthread_cond_s__bindgen_ty_2__bindgen_ty_1>(), 4usize, concat!( - "Offset of field: ", - stringify!(__darwin_i386_thread_state), - "::", - stringify!(__ebx) - ) - ); + "Alignment of ", + stringify!(__pthread_cond_s__bindgen_ty_2__bindgen_ty_1) + ) + ); + fn test_field___low() { + assert_eq!( + unsafe { + let uninit = + ::std::mem::MaybeUninit::<__pthread_cond_s__bindgen_ty_2__bindgen_ty_1>::uninit( + ); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__low) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s__bindgen_ty_2__bindgen_ty_1), + "::", + stringify!(__low) + ) + ); + } + test_field___low(); + fn test_field___high() { + assert_eq!( + unsafe { + let uninit = + ::std::mem::MaybeUninit::<__pthread_cond_s__bindgen_ty_2__bindgen_ty_1>::uninit( + ); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__high) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s__bindgen_ty_2__bindgen_ty_1), + "::", + stringify!(__high) + ) + ); + } + test_field___high(); +} +#[test] +fn bindgen_test_layout___pthread_cond_s__bindgen_ty_2() { assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_thread_state>())).__ecx as *const _ as usize - }, + ::std::mem::size_of::<__pthread_cond_s__bindgen_ty_2>(), 8usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_thread_state), - "::", - stringify!(__ecx) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_thread_state>())).__edx as *const _ as usize - }, - 12usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_thread_state), - "::", - stringify!(__edx) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_thread_state>())).__edi as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_thread_state), - "::", - stringify!(__edi) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_thread_state>())).__esi as *const _ as usize - }, - 20usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_thread_state), - "::", - stringify!(__esi) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_thread_state>())).__ebp as *const _ as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_thread_state), - "::", - stringify!(__ebp) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_thread_state>())).__esp as *const _ as usize - }, - 28usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_thread_state), - "::", - stringify!(__esp) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_i386_thread_state>())).__ss as *const _ as usize }, - 32usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_thread_state), - "::", - stringify!(__ss) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_thread_state>())).__eflags as *const _ as usize - }, - 36usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_thread_state), - "::", - stringify!(__eflags) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_thread_state>())).__eip as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_thread_state), - "::", - stringify!(__eip) - ) + concat!("Size of: ", stringify!(__pthread_cond_s__bindgen_ty_2)) ); assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_i386_thread_state>())).__cs as *const _ as usize }, - 44usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_thread_state), - "::", - stringify!(__cs) - ) - ); + ::std::mem::align_of::<__pthread_cond_s__bindgen_ty_2>(), + 8usize, + concat!("Alignment of ", stringify!(__pthread_cond_s__bindgen_ty_2)) + ); + fn test_field___g1_start() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_cond_s__bindgen_ty_2>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__g1_start) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s__bindgen_ty_2), + "::", + stringify!(__g1_start) + ) + ); + } + test_field___g1_start(); + fn test_field___g1_start32() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_cond_s__bindgen_ty_2>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__g1_start32) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s__bindgen_ty_2), + "::", + stringify!(__g1_start32) + ) + ); + } + test_field___g1_start32(); +} +#[test] +fn bindgen_test_layout___pthread_cond_s() { assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_i386_thread_state>())).__ds as *const _ as usize }, + ::std::mem::size_of::<__pthread_cond_s>(), 48usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_thread_state), - "::", - stringify!(__ds) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_i386_thread_state>())).__es as *const _ as usize }, - 52usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_thread_state), - "::", - stringify!(__es) - ) + concat!("Size of: ", stringify!(__pthread_cond_s)) ); assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_i386_thread_state>())).__fs as *const _ as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_thread_state), - "::", - stringify!(__fs) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_i386_thread_state>())).__gs as *const _ as usize }, - 60usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_thread_state), - "::", - stringify!(__gs) - ) - ); + ::std::mem::align_of::<__pthread_cond_s>(), + 8usize, + concat!("Alignment of ", stringify!(__pthread_cond_s)) + ); + fn test_field___g_refs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_cond_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__g_refs) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s), + "::", + stringify!(__g_refs) + ) + ); + } + test_field___g_refs(); + fn test_field___g_size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_cond_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__g_size) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s), + "::", + stringify!(__g_size) + ) + ); + } + test_field___g_size(); + fn test_field___g1_orig_size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_cond_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__g1_orig_size) as usize - ptr as usize + }, + 32usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s), + "::", + stringify!(__g1_orig_size) + ) + ); + } + test_field___g1_orig_size(); + fn test_field___wrefs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_cond_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__wrefs) as usize - ptr as usize + }, + 36usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s), + "::", + stringify!(__wrefs) + ) + ); + } + test_field___wrefs(); + fn test_field___g_signals() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_cond_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__g_signals) as usize - ptr as usize + }, + 40usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s), + "::", + stringify!(__g_signals) + ) + ); + } + test_field___g_signals(); } +pub type pthread_t = ::std::os::raw::c_ulong; #[repr(C)] -#[repr(align(2))] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_fp_control { - pub _bitfield_align_1: [u8; 0], - pub _bitfield_1: __BindgenBitfieldUnit<[u8; 2usize]>, +#[derive(Copy, Clone)] +pub union pthread_mutexattr_t { + pub __size: [::std::os::raw::c_char; 4usize], + pub __align: ::std::os::raw::c_int, } #[test] -fn bindgen_test_layout___darwin_fp_control() { +fn bindgen_test_layout_pthread_mutexattr_t() { assert_eq!( - ::std::mem::size_of::<__darwin_fp_control>(), - 2usize, - concat!("Size of: ", stringify!(__darwin_fp_control)) + ::std::mem::size_of::(), + 4usize, + concat!("Size of: ", stringify!(pthread_mutexattr_t)) ); assert_eq!( - ::std::mem::align_of::<__darwin_fp_control>(), - 2usize, - concat!("Alignment of ", stringify!(__darwin_fp_control)) - ); + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pthread_mutexattr_t)) + ); + fn test_field___size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__size) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_mutexattr_t), + "::", + stringify!(__size) + ) + ); + } + test_field___size(); + fn test_field___align() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__align) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_mutexattr_t), + "::", + stringify!(__align) + ) + ); + } + test_field___align(); } -impl __darwin_fp_control { - #[inline] - pub fn __invalid(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u16) } - } - #[inline] - pub fn set___invalid(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(0usize, 1u8, val as u64) - } - } - #[inline] - pub fn __denorm(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 1u8) as u16) } - } - #[inline] - pub fn set___denorm(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(1usize, 1u8, val as u64) - } - } - #[inline] - pub fn __zdiv(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(2usize, 1u8) as u16) } - } - #[inline] - pub fn set___zdiv(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(2usize, 1u8, val as u64) - } - } - #[inline] - pub fn __ovrfl(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(3usize, 1u8) as u16) } - } - #[inline] - pub fn set___ovrfl(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(3usize, 1u8, val as u64) - } - } - #[inline] - pub fn __undfl(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(4usize, 1u8) as u16) } - } - #[inline] - pub fn set___undfl(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(4usize, 1u8, val as u64) - } - } - #[inline] - pub fn __precis(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(5usize, 1u8) as u16) } - } - #[inline] - pub fn set___precis(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(5usize, 1u8, val as u64) - } - } - #[inline] - pub fn __pc(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(8usize, 2u8) as u16) } - } - #[inline] - pub fn set___pc(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(8usize, 2u8, val as u64) - } - } - #[inline] - pub fn __rc(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(10usize, 2u8) as u16) } - } - #[inline] - pub fn set___rc(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(10usize, 2u8, val as u64) - } - } - #[inline] - pub fn new_bitfield_1( - __invalid: ::std::os::raw::c_ushort, - __denorm: ::std::os::raw::c_ushort, - __zdiv: ::std::os::raw::c_ushort, - __ovrfl: ::std::os::raw::c_ushort, - __undfl: ::std::os::raw::c_ushort, - __precis: ::std::os::raw::c_ushort, - __pc: ::std::os::raw::c_ushort, - __rc: ::std::os::raw::c_ushort, - ) -> __BindgenBitfieldUnit<[u8; 2usize]> { - let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 2usize]> = Default::default(); - __bindgen_bitfield_unit.set(0usize, 1u8, { - let __invalid: u16 = unsafe { ::std::mem::transmute(__invalid) }; - __invalid as u64 - }); - __bindgen_bitfield_unit.set(1usize, 1u8, { - let __denorm: u16 = unsafe { ::std::mem::transmute(__denorm) }; - __denorm as u64 - }); - __bindgen_bitfield_unit.set(2usize, 1u8, { - let __zdiv: u16 = unsafe { ::std::mem::transmute(__zdiv) }; - __zdiv as u64 - }); - __bindgen_bitfield_unit.set(3usize, 1u8, { - let __ovrfl: u16 = unsafe { ::std::mem::transmute(__ovrfl) }; - __ovrfl as u64 - }); - __bindgen_bitfield_unit.set(4usize, 1u8, { - let __undfl: u16 = unsafe { ::std::mem::transmute(__undfl) }; - __undfl as u64 - }); - __bindgen_bitfield_unit.set(5usize, 1u8, { - let __precis: u16 = unsafe { ::std::mem::transmute(__precis) }; - __precis as u64 - }); - __bindgen_bitfield_unit.set(8usize, 2u8, { - let __pc: u16 = unsafe { ::std::mem::transmute(__pc) }; - __pc as u64 - }); - __bindgen_bitfield_unit.set(10usize, 2u8, { - let __rc: u16 = unsafe { ::std::mem::transmute(__rc) }; - __rc as u64 - }); - __bindgen_bitfield_unit - } -} -pub type __darwin_fp_control_t = __darwin_fp_control; #[repr(C)] -#[repr(align(2))] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_fp_status { - pub _bitfield_align_1: [u8; 0], - pub _bitfield_1: __BindgenBitfieldUnit<[u8; 2usize]>, +#[derive(Copy, Clone)] +pub union pthread_condattr_t { + pub __size: [::std::os::raw::c_char; 4usize], + pub __align: ::std::os::raw::c_int, } #[test] -fn bindgen_test_layout___darwin_fp_status() { +fn bindgen_test_layout_pthread_condattr_t() { assert_eq!( - ::std::mem::size_of::<__darwin_fp_status>(), - 2usize, - concat!("Size of: ", stringify!(__darwin_fp_status)) + ::std::mem::size_of::(), + 4usize, + concat!("Size of: ", stringify!(pthread_condattr_t)) ); assert_eq!( - ::std::mem::align_of::<__darwin_fp_status>(), - 2usize, - concat!("Alignment of ", stringify!(__darwin_fp_status)) - ); + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pthread_condattr_t)) + ); + fn test_field___size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__size) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_condattr_t), + "::", + stringify!(__size) + ) + ); + } + test_field___size(); + fn test_field___align() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__align) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_condattr_t), + "::", + stringify!(__align) + ) + ); + } + test_field___align(); } -impl __darwin_fp_status { - #[inline] - pub fn __invalid(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u16) } - } - #[inline] - pub fn set___invalid(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(0usize, 1u8, val as u64) - } - } - #[inline] - pub fn __denorm(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 1u8) as u16) } - } - #[inline] - pub fn set___denorm(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(1usize, 1u8, val as u64) - } - } - #[inline] - pub fn __zdiv(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(2usize, 1u8) as u16) } - } - #[inline] - pub fn set___zdiv(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(2usize, 1u8, val as u64) - } - } - #[inline] - pub fn __ovrfl(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(3usize, 1u8) as u16) } - } - #[inline] - pub fn set___ovrfl(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(3usize, 1u8, val as u64) - } - } - #[inline] - pub fn __undfl(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(4usize, 1u8) as u16) } - } - #[inline] - pub fn set___undfl(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(4usize, 1u8, val as u64) - } - } - #[inline] - pub fn __precis(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(5usize, 1u8) as u16) } - } - #[inline] - pub fn set___precis(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(5usize, 1u8, val as u64) - } - } - #[inline] - pub fn __stkflt(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(6usize, 1u8) as u16) } - } - #[inline] - pub fn set___stkflt(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(6usize, 1u8, val as u64) - } - } - #[inline] - pub fn __errsumm(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(7usize, 1u8) as u16) } - } - #[inline] - pub fn set___errsumm(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(7usize, 1u8, val as u64) - } - } - #[inline] - pub fn __c0(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(8usize, 1u8) as u16) } - } - #[inline] - pub fn set___c0(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(8usize, 1u8, val as u64) - } - } - #[inline] - pub fn __c1(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(9usize, 1u8) as u16) } - } - #[inline] - pub fn set___c1(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(9usize, 1u8, val as u64) - } - } - #[inline] - pub fn __c2(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(10usize, 1u8) as u16) } - } - #[inline] - pub fn set___c2(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(10usize, 1u8, val as u64) - } - } - #[inline] - pub fn __tos(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(11usize, 3u8) as u16) } - } - #[inline] - pub fn set___tos(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(11usize, 3u8, val as u64) - } - } - #[inline] - pub fn __c3(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(14usize, 1u8) as u16) } - } - #[inline] - pub fn set___c3(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(14usize, 1u8, val as u64) - } - } - #[inline] - pub fn __busy(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(15usize, 1u8) as u16) } - } - #[inline] - pub fn set___busy(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(15usize, 1u8, val as u64) - } - } - #[inline] - pub fn new_bitfield_1( - __invalid: ::std::os::raw::c_ushort, - __denorm: ::std::os::raw::c_ushort, - __zdiv: ::std::os::raw::c_ushort, - __ovrfl: ::std::os::raw::c_ushort, - __undfl: ::std::os::raw::c_ushort, - __precis: ::std::os::raw::c_ushort, - __stkflt: ::std::os::raw::c_ushort, - __errsumm: ::std::os::raw::c_ushort, - __c0: ::std::os::raw::c_ushort, - __c1: ::std::os::raw::c_ushort, - __c2: ::std::os::raw::c_ushort, - __tos: ::std::os::raw::c_ushort, - __c3: ::std::os::raw::c_ushort, - __busy: ::std::os::raw::c_ushort, - ) -> __BindgenBitfieldUnit<[u8; 2usize]> { - let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 2usize]> = Default::default(); - __bindgen_bitfield_unit.set(0usize, 1u8, { - let __invalid: u16 = unsafe { ::std::mem::transmute(__invalid) }; - __invalid as u64 - }); - __bindgen_bitfield_unit.set(1usize, 1u8, { - let __denorm: u16 = unsafe { ::std::mem::transmute(__denorm) }; - __denorm as u64 - }); - __bindgen_bitfield_unit.set(2usize, 1u8, { - let __zdiv: u16 = unsafe { ::std::mem::transmute(__zdiv) }; - __zdiv as u64 - }); - __bindgen_bitfield_unit.set(3usize, 1u8, { - let __ovrfl: u16 = unsafe { ::std::mem::transmute(__ovrfl) }; - __ovrfl as u64 - }); - __bindgen_bitfield_unit.set(4usize, 1u8, { - let __undfl: u16 = unsafe { ::std::mem::transmute(__undfl) }; - __undfl as u64 - }); - __bindgen_bitfield_unit.set(5usize, 1u8, { - let __precis: u16 = unsafe { ::std::mem::transmute(__precis) }; - __precis as u64 - }); - __bindgen_bitfield_unit.set(6usize, 1u8, { - let __stkflt: u16 = unsafe { ::std::mem::transmute(__stkflt) }; - __stkflt as u64 - }); - __bindgen_bitfield_unit.set(7usize, 1u8, { - let __errsumm: u16 = unsafe { ::std::mem::transmute(__errsumm) }; - __errsumm as u64 - }); - __bindgen_bitfield_unit.set(8usize, 1u8, { - let __c0: u16 = unsafe { ::std::mem::transmute(__c0) }; - __c0 as u64 - }); - __bindgen_bitfield_unit.set(9usize, 1u8, { - let __c1: u16 = unsafe { ::std::mem::transmute(__c1) }; - __c1 as u64 - }); - __bindgen_bitfield_unit.set(10usize, 1u8, { - let __c2: u16 = unsafe { ::std::mem::transmute(__c2) }; - __c2 as u64 - }); - __bindgen_bitfield_unit.set(11usize, 3u8, { - let __tos: u16 = unsafe { ::std::mem::transmute(__tos) }; - __tos as u64 - }); - __bindgen_bitfield_unit.set(14usize, 1u8, { - let __c3: u16 = unsafe { ::std::mem::transmute(__c3) }; - __c3 as u64 - }); - __bindgen_bitfield_unit.set(15usize, 1u8, { - let __busy: u16 = unsafe { ::std::mem::transmute(__busy) }; - __busy as u64 - }); - __bindgen_bitfield_unit - } -} -pub type __darwin_fp_status_t = __darwin_fp_status; +pub type pthread_key_t = ::std::os::raw::c_uint; +pub type pthread_once_t = ::std::os::raw::c_int; #[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_mmst_reg { - pub __mmst_reg: [::std::os::raw::c_char; 10usize], - pub __mmst_rsrv: [::std::os::raw::c_char; 6usize], +#[derive(Copy, Clone)] +pub union pthread_attr_t { + pub __size: [::std::os::raw::c_char; 56usize], + pub __align: ::std::os::raw::c_long, } #[test] -fn bindgen_test_layout___darwin_mmst_reg() { - assert_eq!( - ::std::mem::size_of::<__darwin_mmst_reg>(), - 16usize, - concat!("Size of: ", stringify!(__darwin_mmst_reg)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_mmst_reg>(), - 1usize, - concat!("Alignment of ", stringify!(__darwin_mmst_reg)) - ); +fn bindgen_test_layout_pthread_attr_t() { assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mmst_reg>())).__mmst_reg as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mmst_reg), - "::", - stringify!(__mmst_reg) - ) + ::std::mem::size_of::(), + 56usize, + concat!("Size of: ", stringify!(pthread_attr_t)) ); assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mmst_reg>())).__mmst_rsrv as *const _ as usize }, - 10usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mmst_reg), - "::", - stringify!(__mmst_rsrv) - ) - ); + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pthread_attr_t)) + ); + fn test_field___size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__size) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_attr_t), + "::", + stringify!(__size) + ) + ); + } + test_field___size(); + fn test_field___align() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__align) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_attr_t), + "::", + stringify!(__align) + ) + ); + } + test_field___align(); } #[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_xmm_reg { - pub __xmm_reg: [::std::os::raw::c_char; 16usize], +#[derive(Copy, Clone)] +pub union pthread_mutex_t { + pub __data: __pthread_mutex_s, + pub __size: [::std::os::raw::c_char; 40usize], + pub __align: ::std::os::raw::c_long, } #[test] -fn bindgen_test_layout___darwin_xmm_reg() { - assert_eq!( - ::std::mem::size_of::<__darwin_xmm_reg>(), - 16usize, - concat!("Size of: ", stringify!(__darwin_xmm_reg)) - ); +fn bindgen_test_layout_pthread_mutex_t() { assert_eq!( - ::std::mem::align_of::<__darwin_xmm_reg>(), - 1usize, - concat!("Alignment of ", stringify!(__darwin_xmm_reg)) + ::std::mem::size_of::(), + 40usize, + concat!("Size of: ", stringify!(pthread_mutex_t)) ); assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_xmm_reg>())).__xmm_reg as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_xmm_reg), - "::", - stringify!(__xmm_reg) - ) - ); + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pthread_mutex_t)) + ); + fn test_field___data() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__data) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_mutex_t), + "::", + stringify!(__data) + ) + ); + } + test_field___data(); + fn test_field___size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__size) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_mutex_t), + "::", + stringify!(__size) + ) + ); + } + test_field___size(); + fn test_field___align() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__align) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_mutex_t), + "::", + stringify!(__align) + ) + ); + } + test_field___align(); } #[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_ymm_reg { - pub __ymm_reg: [::std::os::raw::c_char; 32usize], +#[derive(Copy, Clone)] +pub union pthread_cond_t { + pub __data: __pthread_cond_s, + pub __size: [::std::os::raw::c_char; 48usize], + pub __align: ::std::os::raw::c_longlong, } #[test] -fn bindgen_test_layout___darwin_ymm_reg() { - assert_eq!( - ::std::mem::size_of::<__darwin_ymm_reg>(), - 32usize, - concat!("Size of: ", stringify!(__darwin_ymm_reg)) - ); +fn bindgen_test_layout_pthread_cond_t() { assert_eq!( - ::std::mem::align_of::<__darwin_ymm_reg>(), - 1usize, - concat!("Alignment of ", stringify!(__darwin_ymm_reg)) + ::std::mem::size_of::(), + 48usize, + concat!("Size of: ", stringify!(pthread_cond_t)) ); assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_ymm_reg>())).__ymm_reg as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_ymm_reg), - "::", - stringify!(__ymm_reg) - ) - ); + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pthread_cond_t)) + ); + fn test_field___data() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__data) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_cond_t), + "::", + stringify!(__data) + ) + ); + } + test_field___data(); + fn test_field___size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__size) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_cond_t), + "::", + stringify!(__size) + ) + ); + } + test_field___size(); + fn test_field___align() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__align) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_cond_t), + "::", + stringify!(__align) + ) + ); + } + test_field___align(); } #[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_zmm_reg { - pub __zmm_reg: [::std::os::raw::c_char; 64usize], +#[derive(Copy, Clone)] +pub union pthread_rwlock_t { + pub __data: __pthread_rwlock_arch_t, + pub __size: [::std::os::raw::c_char; 56usize], + pub __align: ::std::os::raw::c_long, } #[test] -fn bindgen_test_layout___darwin_zmm_reg() { - assert_eq!( - ::std::mem::size_of::<__darwin_zmm_reg>(), - 64usize, - concat!("Size of: ", stringify!(__darwin_zmm_reg)) - ); +fn bindgen_test_layout_pthread_rwlock_t() { assert_eq!( - ::std::mem::align_of::<__darwin_zmm_reg>(), - 1usize, - concat!("Alignment of ", stringify!(__darwin_zmm_reg)) + ::std::mem::size_of::(), + 56usize, + concat!("Size of: ", stringify!(pthread_rwlock_t)) ); assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_zmm_reg>())).__zmm_reg as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_zmm_reg), - "::", - stringify!(__zmm_reg) - ) - ); + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pthread_rwlock_t)) + ); + fn test_field___data() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__data) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_rwlock_t), + "::", + stringify!(__data) + ) + ); + } + test_field___data(); + fn test_field___size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__size) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_rwlock_t), + "::", + stringify!(__size) + ) + ); + } + test_field___size(); + fn test_field___align() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__align) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_rwlock_t), + "::", + stringify!(__align) + ) + ); + } + test_field___align(); } #[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_opmask_reg { - pub __opmask_reg: [::std::os::raw::c_char; 8usize], +#[derive(Copy, Clone)] +pub union pthread_rwlockattr_t { + pub __size: [::std::os::raw::c_char; 8usize], + pub __align: ::std::os::raw::c_long, } #[test] -fn bindgen_test_layout___darwin_opmask_reg() { +fn bindgen_test_layout_pthread_rwlockattr_t() { assert_eq!( - ::std::mem::size_of::<__darwin_opmask_reg>(), + ::std::mem::size_of::(), 8usize, - concat!("Size of: ", stringify!(__darwin_opmask_reg)) + concat!("Size of: ", stringify!(pthread_rwlockattr_t)) ); assert_eq!( - ::std::mem::align_of::<__darwin_opmask_reg>(), - 1usize, - concat!("Alignment of ", stringify!(__darwin_opmask_reg)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_opmask_reg>())).__opmask_reg as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_opmask_reg), - "::", - stringify!(__opmask_reg) - ) - ); + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pthread_rwlockattr_t)) + ); + fn test_field___size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__size) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_rwlockattr_t), + "::", + stringify!(__size) + ) + ); + } + test_field___size(); + fn test_field___align() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__align) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_rwlockattr_t), + "::", + stringify!(__align) + ) + ); + } + test_field___align(); } +pub type pthread_spinlock_t = ::std::os::raw::c_int; #[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_i386_float_state { - pub __fpu_reserved: [::std::os::raw::c_int; 2usize], - pub __fpu_fcw: __darwin_fp_control, - pub __fpu_fsw: __darwin_fp_status, - pub __fpu_ftw: __uint8_t, - pub __fpu_rsrv1: __uint8_t, - pub __fpu_fop: __uint16_t, - pub __fpu_ip: __uint32_t, - pub __fpu_cs: __uint16_t, - pub __fpu_rsrv2: __uint16_t, - pub __fpu_dp: __uint32_t, - pub __fpu_ds: __uint16_t, - pub __fpu_rsrv3: __uint16_t, - pub __fpu_mxcsr: __uint32_t, - pub __fpu_mxcsrmask: __uint32_t, - pub __fpu_stmm0: __darwin_mmst_reg, - pub __fpu_stmm1: __darwin_mmst_reg, - pub __fpu_stmm2: __darwin_mmst_reg, - pub __fpu_stmm3: __darwin_mmst_reg, - pub __fpu_stmm4: __darwin_mmst_reg, - pub __fpu_stmm5: __darwin_mmst_reg, - pub __fpu_stmm6: __darwin_mmst_reg, - pub __fpu_stmm7: __darwin_mmst_reg, - pub __fpu_xmm0: __darwin_xmm_reg, - pub __fpu_xmm1: __darwin_xmm_reg, - pub __fpu_xmm2: __darwin_xmm_reg, - pub __fpu_xmm3: __darwin_xmm_reg, - pub __fpu_xmm4: __darwin_xmm_reg, - pub __fpu_xmm5: __darwin_xmm_reg, - pub __fpu_xmm6: __darwin_xmm_reg, - pub __fpu_xmm7: __darwin_xmm_reg, - pub __fpu_rsrv4: [::std::os::raw::c_char; 224usize], - pub __fpu_reserved1: ::std::os::raw::c_int, +#[derive(Copy, Clone)] +pub union pthread_barrier_t { + pub __size: [::std::os::raw::c_char; 32usize], + pub __align: ::std::os::raw::c_long, } #[test] -fn bindgen_test_layout___darwin_i386_float_state() { - assert_eq!( - ::std::mem::size_of::<__darwin_i386_float_state>(), - 524usize, - concat!("Size of: ", stringify!(__darwin_i386_float_state)) - ); +fn bindgen_test_layout_pthread_barrier_t() { assert_eq!( - ::std::mem::align_of::<__darwin_i386_float_state>(), - 4usize, - concat!("Alignment of ", stringify!(__darwin_i386_float_state)) + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(pthread_barrier_t)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_reserved as *const _ - as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_reserved) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_fcw as *const _ as usize - }, + ::std::mem::align_of::(), 8usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_fcw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_fsw as *const _ as usize - }, - 10usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_fsw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_ftw as *const _ as usize - }, - 12usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_ftw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_rsrv1 as *const _ as usize - }, - 13usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_rsrv1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_fop as *const _ as usize - }, - 14usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_fop) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_ip as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_ip) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_cs as *const _ as usize - }, - 20usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_cs) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_rsrv2 as *const _ as usize - }, - 22usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_rsrv2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_dp as *const _ as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_dp) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_ds as *const _ as usize - }, - 28usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_ds) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_rsrv3 as *const _ as usize - }, - 30usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_rsrv3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_mxcsr as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_mxcsr) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_mxcsrmask as *const _ - as usize - }, - 36usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_mxcsrmask) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_stmm0 as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_stmm0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_stmm1 as *const _ as usize - }, - 56usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_stmm1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_stmm2 as *const _ as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_stmm2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_stmm3 as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_stmm3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_stmm4 as *const _ as usize - }, - 104usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_stmm4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_stmm5 as *const _ as usize - }, - 120usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_stmm5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_stmm6 as *const _ as usize - }, - 136usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_stmm6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_stmm7 as *const _ as usize - }, - 152usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_stmm7) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_xmm0 as *const _ as usize - }, - 168usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_xmm0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_xmm1 as *const _ as usize - }, - 184usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_xmm1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_xmm2 as *const _ as usize - }, - 200usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_xmm2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_xmm3 as *const _ as usize - }, - 216usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_xmm3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_xmm4 as *const _ as usize - }, - 232usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_xmm4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_xmm5 as *const _ as usize - }, - 248usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_xmm5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_xmm6 as *const _ as usize - }, - 264usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_xmm6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_xmm7 as *const _ as usize - }, - 280usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_xmm7) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_rsrv4 as *const _ as usize - }, - 296usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_rsrv4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_reserved1 as *const _ - as usize - }, - 520usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_reserved1) - ) - ); + concat!("Alignment of ", stringify!(pthread_barrier_t)) + ); + fn test_field___size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__size) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_barrier_t), + "::", + stringify!(__size) + ) + ); + } + test_field___size(); + fn test_field___align() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__align) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_barrier_t), + "::", + stringify!(__align) + ) + ); + } + test_field___align(); } #[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_i386_avx_state { - pub __fpu_reserved: [::std::os::raw::c_int; 2usize], - pub __fpu_fcw: __darwin_fp_control, - pub __fpu_fsw: __darwin_fp_status, - pub __fpu_ftw: __uint8_t, - pub __fpu_rsrv1: __uint8_t, - pub __fpu_fop: __uint16_t, - pub __fpu_ip: __uint32_t, - pub __fpu_cs: __uint16_t, - pub __fpu_rsrv2: __uint16_t, - pub __fpu_dp: __uint32_t, - pub __fpu_ds: __uint16_t, - pub __fpu_rsrv3: __uint16_t, - pub __fpu_mxcsr: __uint32_t, - pub __fpu_mxcsrmask: __uint32_t, - pub __fpu_stmm0: __darwin_mmst_reg, - pub __fpu_stmm1: __darwin_mmst_reg, - pub __fpu_stmm2: __darwin_mmst_reg, - pub __fpu_stmm3: __darwin_mmst_reg, - pub __fpu_stmm4: __darwin_mmst_reg, - pub __fpu_stmm5: __darwin_mmst_reg, - pub __fpu_stmm6: __darwin_mmst_reg, - pub __fpu_stmm7: __darwin_mmst_reg, - pub __fpu_xmm0: __darwin_xmm_reg, - pub __fpu_xmm1: __darwin_xmm_reg, - pub __fpu_xmm2: __darwin_xmm_reg, - pub __fpu_xmm3: __darwin_xmm_reg, - pub __fpu_xmm4: __darwin_xmm_reg, - pub __fpu_xmm5: __darwin_xmm_reg, - pub __fpu_xmm6: __darwin_xmm_reg, - pub __fpu_xmm7: __darwin_xmm_reg, - pub __fpu_rsrv4: [::std::os::raw::c_char; 224usize], - pub __fpu_reserved1: ::std::os::raw::c_int, - pub __avx_reserved1: [::std::os::raw::c_char; 64usize], - pub __fpu_ymmh0: __darwin_xmm_reg, - pub __fpu_ymmh1: __darwin_xmm_reg, - pub __fpu_ymmh2: __darwin_xmm_reg, - pub __fpu_ymmh3: __darwin_xmm_reg, - pub __fpu_ymmh4: __darwin_xmm_reg, - pub __fpu_ymmh5: __darwin_xmm_reg, - pub __fpu_ymmh6: __darwin_xmm_reg, - pub __fpu_ymmh7: __darwin_xmm_reg, +#[derive(Copy, Clone)] +pub union pthread_barrierattr_t { + pub __size: [::std::os::raw::c_char; 4usize], + pub __align: ::std::os::raw::c_int, } #[test] -fn bindgen_test_layout___darwin_i386_avx_state() { +fn bindgen_test_layout_pthread_barrierattr_t() { assert_eq!( - ::std::mem::size_of::<__darwin_i386_avx_state>(), - 716usize, - concat!("Size of: ", stringify!(__darwin_i386_avx_state)) + ::std::mem::size_of::(), + 4usize, + concat!("Size of: ", stringify!(pthread_barrierattr_t)) ); assert_eq!( - ::std::mem::align_of::<__darwin_i386_avx_state>(), + ::std::mem::align_of::(), 4usize, - concat!("Alignment of ", stringify!(__darwin_i386_avx_state)) - ); + concat!("Alignment of ", stringify!(pthread_barrierattr_t)) + ); + fn test_field___size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__size) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_barrierattr_t), + "::", + stringify!(__size) + ) + ); + } + test_field___size(); + fn test_field___align() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__align) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_barrierattr_t), + "::", + stringify!(__align) + ) + ); + } + test_field___align(); +} +extern "C" { + pub fn random() -> ::std::os::raw::c_long; +} +extern "C" { + pub fn srandom(__seed: ::std::os::raw::c_uint); +} +extern "C" { + pub fn initstate( + __seed: ::std::os::raw::c_uint, + __statebuf: *mut ::std::os::raw::c_char, + __statelen: usize, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn setstate(__statebuf: *mut ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct random_data { + pub fptr: *mut i32, + pub rptr: *mut i32, + pub state: *mut i32, + pub rand_type: ::std::os::raw::c_int, + pub rand_deg: ::std::os::raw::c_int, + pub rand_sep: ::std::os::raw::c_int, + pub end_ptr: *mut i32, +} +#[test] +fn bindgen_test_layout_random_data() { assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_reserved as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_reserved) - ) + ::std::mem::size_of::(), + 48usize, + concat!("Size of: ", stringify!(random_data)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_fcw as *const _ as usize - }, + ::std::mem::align_of::(), 8usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_fcw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_fsw as *const _ as usize - }, - 10usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_fsw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_ftw as *const _ as usize - }, - 12usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_ftw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_rsrv1 as *const _ as usize - }, - 13usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_rsrv1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_fop as *const _ as usize - }, - 14usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_fop) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_ip as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_ip) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_cs as *const _ as usize - }, - 20usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_cs) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_rsrv2 as *const _ as usize - }, - 22usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_rsrv2) - ) - ); + concat!("Alignment of ", stringify!(random_data)) + ); + fn test_field_fptr() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).fptr) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(random_data), + "::", + stringify!(fptr) + ) + ); + } + test_field_fptr(); + fn test_field_rptr() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).rptr) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(random_data), + "::", + stringify!(rptr) + ) + ); + } + test_field_rptr(); + fn test_field_state() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).state) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(random_data), + "::", + stringify!(state) + ) + ); + } + test_field_state(); + fn test_field_rand_type() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).rand_type) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(random_data), + "::", + stringify!(rand_type) + ) + ); + } + test_field_rand_type(); + fn test_field_rand_deg() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).rand_deg) as usize - ptr as usize + }, + 28usize, + concat!( + "Offset of field: ", + stringify!(random_data), + "::", + stringify!(rand_deg) + ) + ); + } + test_field_rand_deg(); + fn test_field_rand_sep() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).rand_sep) as usize - ptr as usize + }, + 32usize, + concat!( + "Offset of field: ", + stringify!(random_data), + "::", + stringify!(rand_sep) + ) + ); + } + test_field_rand_sep(); + fn test_field_end_ptr() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).end_ptr) as usize - ptr as usize + }, + 40usize, + concat!( + "Offset of field: ", + stringify!(random_data), + "::", + stringify!(end_ptr) + ) + ); + } + test_field_end_ptr(); +} +extern "C" { + pub fn random_r(__buf: *mut random_data, __result: *mut i32) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn srandom_r( + __seed: ::std::os::raw::c_uint, + __buf: *mut random_data, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn initstate_r( + __seed: ::std::os::raw::c_uint, + __statebuf: *mut ::std::os::raw::c_char, + __statelen: usize, + __buf: *mut random_data, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn setstate_r( + __statebuf: *mut ::std::os::raw::c_char, + __buf: *mut random_data, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn rand() -> ::std::os::raw::c_int; +} +extern "C" { + pub fn srand(__seed: ::std::os::raw::c_uint); +} +extern "C" { + pub fn rand_r(__seed: *mut ::std::os::raw::c_uint) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn drand48() -> f64; +} +extern "C" { + pub fn erand48(__xsubi: *mut ::std::os::raw::c_ushort) -> f64; +} +extern "C" { + pub fn lrand48() -> ::std::os::raw::c_long; +} +extern "C" { + pub fn nrand48(__xsubi: *mut ::std::os::raw::c_ushort) -> ::std::os::raw::c_long; +} +extern "C" { + pub fn mrand48() -> ::std::os::raw::c_long; +} +extern "C" { + pub fn jrand48(__xsubi: *mut ::std::os::raw::c_ushort) -> ::std::os::raw::c_long; +} +extern "C" { + pub fn srand48(__seedval: ::std::os::raw::c_long); +} +extern "C" { + pub fn seed48(__seed16v: *mut ::std::os::raw::c_ushort) -> *mut ::std::os::raw::c_ushort; +} +extern "C" { + pub fn lcong48(__param: *mut ::std::os::raw::c_ushort); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct drand48_data { + pub __x: [::std::os::raw::c_ushort; 3usize], + pub __old_x: [::std::os::raw::c_ushort; 3usize], + pub __c: ::std::os::raw::c_ushort, + pub __init: ::std::os::raw::c_ushort, + pub __a: ::std::os::raw::c_ulonglong, +} +#[test] +fn bindgen_test_layout_drand48_data() { assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_dp as *const _ as usize - }, + ::std::mem::size_of::(), 24usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_dp) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_ds as *const _ as usize - }, - 28usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_ds) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_rsrv3 as *const _ as usize - }, - 30usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_rsrv3) - ) + concat!("Size of: ", stringify!(drand48_data)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_mxcsr as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_mxcsr) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_mxcsrmask as *const _ as usize - }, - 36usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_mxcsrmask) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_stmm0 as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_stmm0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_stmm1 as *const _ as usize - }, - 56usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_stmm1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_stmm2 as *const _ as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_stmm2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_stmm3 as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_stmm3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_stmm4 as *const _ as usize - }, - 104usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_stmm4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_stmm5 as *const _ as usize - }, - 120usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_stmm5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_stmm6 as *const _ as usize - }, - 136usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_stmm6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_stmm7 as *const _ as usize - }, - 152usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_stmm7) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_xmm0 as *const _ as usize - }, - 168usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_xmm0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_xmm1 as *const _ as usize - }, - 184usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_xmm1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_xmm2 as *const _ as usize - }, - 200usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_xmm2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_xmm3 as *const _ as usize - }, - 216usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_xmm3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_xmm4 as *const _ as usize - }, - 232usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_xmm4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_xmm5 as *const _ as usize - }, - 248usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_xmm5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_xmm6 as *const _ as usize - }, - 264usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_xmm6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_xmm7 as *const _ as usize - }, - 280usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_xmm7) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_rsrv4 as *const _ as usize - }, - 296usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_rsrv4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_reserved1 as *const _ as usize - }, - 520usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_reserved1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__avx_reserved1 as *const _ as usize - }, - 524usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__avx_reserved1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_ymmh0 as *const _ as usize - }, - 588usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_ymmh0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_ymmh1 as *const _ as usize - }, - 604usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_ymmh1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_ymmh2 as *const _ as usize - }, - 620usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_ymmh2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_ymmh3 as *const _ as usize - }, - 636usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_ymmh3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_ymmh4 as *const _ as usize - }, - 652usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_ymmh4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_ymmh5 as *const _ as usize - }, - 668usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_ymmh5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_ymmh6 as *const _ as usize - }, - 684usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_ymmh6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_ymmh7 as *const _ as usize - }, - 700usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_ymmh7) - ) - ); + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(drand48_data)) + ); + fn test_field___x() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__x) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(drand48_data), + "::", + stringify!(__x) + ) + ); + } + test_field___x(); + fn test_field___old_x() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__old_x) as usize - ptr as usize + }, + 6usize, + concat!( + "Offset of field: ", + stringify!(drand48_data), + "::", + stringify!(__old_x) + ) + ); + } + test_field___old_x(); + fn test_field___c() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__c) as usize - ptr as usize + }, + 12usize, + concat!( + "Offset of field: ", + stringify!(drand48_data), + "::", + stringify!(__c) + ) + ); + } + test_field___c(); + fn test_field___init() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__init) as usize - ptr as usize + }, + 14usize, + concat!( + "Offset of field: ", + stringify!(drand48_data), + "::", + stringify!(__init) + ) + ); + } + test_field___init(); + fn test_field___a() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__a) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(drand48_data), + "::", + stringify!(__a) + ) + ); + } + test_field___a(); } -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_i386_avx512_state { - pub __fpu_reserved: [::std::os::raw::c_int; 2usize], - pub __fpu_fcw: __darwin_fp_control, - pub __fpu_fsw: __darwin_fp_status, - pub __fpu_ftw: __uint8_t, - pub __fpu_rsrv1: __uint8_t, - pub __fpu_fop: __uint16_t, - pub __fpu_ip: __uint32_t, - pub __fpu_cs: __uint16_t, - pub __fpu_rsrv2: __uint16_t, - pub __fpu_dp: __uint32_t, - pub __fpu_ds: __uint16_t, - pub __fpu_rsrv3: __uint16_t, - pub __fpu_mxcsr: __uint32_t, - pub __fpu_mxcsrmask: __uint32_t, - pub __fpu_stmm0: __darwin_mmst_reg, - pub __fpu_stmm1: __darwin_mmst_reg, - pub __fpu_stmm2: __darwin_mmst_reg, - pub __fpu_stmm3: __darwin_mmst_reg, - pub __fpu_stmm4: __darwin_mmst_reg, - pub __fpu_stmm5: __darwin_mmst_reg, - pub __fpu_stmm6: __darwin_mmst_reg, - pub __fpu_stmm7: __darwin_mmst_reg, - pub __fpu_xmm0: __darwin_xmm_reg, - pub __fpu_xmm1: __darwin_xmm_reg, - pub __fpu_xmm2: __darwin_xmm_reg, - pub __fpu_xmm3: __darwin_xmm_reg, - pub __fpu_xmm4: __darwin_xmm_reg, - pub __fpu_xmm5: __darwin_xmm_reg, - pub __fpu_xmm6: __darwin_xmm_reg, - pub __fpu_xmm7: __darwin_xmm_reg, - pub __fpu_rsrv4: [::std::os::raw::c_char; 224usize], - pub __fpu_reserved1: ::std::os::raw::c_int, - pub __avx_reserved1: [::std::os::raw::c_char; 64usize], - pub __fpu_ymmh0: __darwin_xmm_reg, - pub __fpu_ymmh1: __darwin_xmm_reg, - pub __fpu_ymmh2: __darwin_xmm_reg, - pub __fpu_ymmh3: __darwin_xmm_reg, - pub __fpu_ymmh4: __darwin_xmm_reg, - pub __fpu_ymmh5: __darwin_xmm_reg, - pub __fpu_ymmh6: __darwin_xmm_reg, - pub __fpu_ymmh7: __darwin_xmm_reg, - pub __fpu_k0: __darwin_opmask_reg, - pub __fpu_k1: __darwin_opmask_reg, - pub __fpu_k2: __darwin_opmask_reg, - pub __fpu_k3: __darwin_opmask_reg, - pub __fpu_k4: __darwin_opmask_reg, - pub __fpu_k5: __darwin_opmask_reg, - pub __fpu_k6: __darwin_opmask_reg, - pub __fpu_k7: __darwin_opmask_reg, - pub __fpu_zmmh0: __darwin_ymm_reg, - pub __fpu_zmmh1: __darwin_ymm_reg, - pub __fpu_zmmh2: __darwin_ymm_reg, - pub __fpu_zmmh3: __darwin_ymm_reg, - pub __fpu_zmmh4: __darwin_ymm_reg, - pub __fpu_zmmh5: __darwin_ymm_reg, - pub __fpu_zmmh6: __darwin_ymm_reg, - pub __fpu_zmmh7: __darwin_ymm_reg, +extern "C" { + pub fn drand48_r(__buffer: *mut drand48_data, __result: *mut f64) -> ::std::os::raw::c_int; } -#[test] -fn bindgen_test_layout___darwin_i386_avx512_state() { - assert_eq!( - ::std::mem::size_of::<__darwin_i386_avx512_state>(), - 1036usize, - concat!("Size of: ", stringify!(__darwin_i386_avx512_state)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_i386_avx512_state>(), - 4usize, - concat!("Alignment of ", stringify!(__darwin_i386_avx512_state)) +extern "C" { + pub fn erand48_r( + __xsubi: *mut ::std::os::raw::c_ushort, + __buffer: *mut drand48_data, + __result: *mut f64, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn lrand48_r( + __buffer: *mut drand48_data, + __result: *mut ::std::os::raw::c_long, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn nrand48_r( + __xsubi: *mut ::std::os::raw::c_ushort, + __buffer: *mut drand48_data, + __result: *mut ::std::os::raw::c_long, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn mrand48_r( + __buffer: *mut drand48_data, + __result: *mut ::std::os::raw::c_long, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn jrand48_r( + __xsubi: *mut ::std::os::raw::c_ushort, + __buffer: *mut drand48_data, + __result: *mut ::std::os::raw::c_long, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn srand48_r( + __seedval: ::std::os::raw::c_long, + __buffer: *mut drand48_data, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn seed48_r( + __seed16v: *mut ::std::os::raw::c_ushort, + __buffer: *mut drand48_data, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn lcong48_r( + __param: *mut ::std::os::raw::c_ushort, + __buffer: *mut drand48_data, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn malloc(__size: ::std::os::raw::c_ulong) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn calloc( + __nmemb: ::std::os::raw::c_ulong, + __size: ::std::os::raw::c_ulong, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn realloc( + __ptr: *mut ::std::os::raw::c_void, + __size: ::std::os::raw::c_ulong, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn reallocarray( + __ptr: *mut ::std::os::raw::c_void, + __nmemb: usize, + __size: usize, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn free(__ptr: *mut ::std::os::raw::c_void); +} +extern "C" { + pub fn alloca(__size: ::std::os::raw::c_ulong) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn valloc(__size: usize) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn posix_memalign( + __memptr: *mut *mut ::std::os::raw::c_void, + __alignment: usize, + __size: usize, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn aligned_alloc(__alignment: usize, __size: usize) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn abort(); +} +extern "C" { + pub fn atexit(__func: ::std::option::Option) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn at_quick_exit( + __func: ::std::option::Option, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn on_exit( + __func: ::std::option::Option< + unsafe extern "C" fn( + __status: ::std::os::raw::c_int, + __arg: *mut ::std::os::raw::c_void, + ), + >, + __arg: *mut ::std::os::raw::c_void, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn exit(__status: ::std::os::raw::c_int); +} +extern "C" { + pub fn quick_exit(__status: ::std::os::raw::c_int); +} +extern "C" { + pub fn _Exit(__status: ::std::os::raw::c_int); +} +extern "C" { + pub fn getenv(__name: *const ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn putenv(__string: *mut ::std::os::raw::c_char) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn setenv( + __name: *const ::std::os::raw::c_char, + __value: *const ::std::os::raw::c_char, + __replace: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn unsetenv(__name: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn clearenv() -> ::std::os::raw::c_int; +} +extern "C" { + pub fn mktemp(__template: *mut ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn mkstemp(__template: *mut ::std::os::raw::c_char) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn mkstemps( + __template: *mut ::std::os::raw::c_char, + __suffixlen: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn mkdtemp(__template: *mut ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn system(__command: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn realpath( + __name: *const ::std::os::raw::c_char, + __resolved: *mut ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; +} +pub type __compar_fn_t = ::std::option::Option< + unsafe extern "C" fn( + arg1: *const ::std::os::raw::c_void, + arg2: *const ::std::os::raw::c_void, + ) -> ::std::os::raw::c_int, +>; +extern "C" { + pub fn bsearch( + __key: *const ::std::os::raw::c_void, + __base: *const ::std::os::raw::c_void, + __nmemb: usize, + __size: usize, + __compar: __compar_fn_t, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn qsort( + __base: *mut ::std::os::raw::c_void, + __nmemb: usize, + __size: usize, + __compar: __compar_fn_t, ); +} +extern "C" { + pub fn abs(__x: ::std::os::raw::c_int) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn labs(__x: ::std::os::raw::c_long) -> ::std::os::raw::c_long; +} +extern "C" { + pub fn llabs(__x: ::std::os::raw::c_longlong) -> ::std::os::raw::c_longlong; +} +extern "C" { + pub fn div(__numer: ::std::os::raw::c_int, __denom: ::std::os::raw::c_int) -> div_t; +} +extern "C" { + pub fn ldiv(__numer: ::std::os::raw::c_long, __denom: ::std::os::raw::c_long) -> ldiv_t; +} +extern "C" { + pub fn lldiv( + __numer: ::std::os::raw::c_longlong, + __denom: ::std::os::raw::c_longlong, + ) -> lldiv_t; +} +extern "C" { + pub fn ecvt( + __value: f64, + __ndigit: ::std::os::raw::c_int, + __decpt: *mut ::std::os::raw::c_int, + __sign: *mut ::std::os::raw::c_int, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn fcvt( + __value: f64, + __ndigit: ::std::os::raw::c_int, + __decpt: *mut ::std::os::raw::c_int, + __sign: *mut ::std::os::raw::c_int, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn gcvt( + __value: f64, + __ndigit: ::std::os::raw::c_int, + __buf: *mut ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn qecvt( + __value: u128, + __ndigit: ::std::os::raw::c_int, + __decpt: *mut ::std::os::raw::c_int, + __sign: *mut ::std::os::raw::c_int, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn qfcvt( + __value: u128, + __ndigit: ::std::os::raw::c_int, + __decpt: *mut ::std::os::raw::c_int, + __sign: *mut ::std::os::raw::c_int, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn qgcvt( + __value: u128, + __ndigit: ::std::os::raw::c_int, + __buf: *mut ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn ecvt_r( + __value: f64, + __ndigit: ::std::os::raw::c_int, + __decpt: *mut ::std::os::raw::c_int, + __sign: *mut ::std::os::raw::c_int, + __buf: *mut ::std::os::raw::c_char, + __len: usize, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn fcvt_r( + __value: f64, + __ndigit: ::std::os::raw::c_int, + __decpt: *mut ::std::os::raw::c_int, + __sign: *mut ::std::os::raw::c_int, + __buf: *mut ::std::os::raw::c_char, + __len: usize, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn qecvt_r( + __value: u128, + __ndigit: ::std::os::raw::c_int, + __decpt: *mut ::std::os::raw::c_int, + __sign: *mut ::std::os::raw::c_int, + __buf: *mut ::std::os::raw::c_char, + __len: usize, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn qfcvt_r( + __value: u128, + __ndigit: ::std::os::raw::c_int, + __decpt: *mut ::std::os::raw::c_int, + __sign: *mut ::std::os::raw::c_int, + __buf: *mut ::std::os::raw::c_char, + __len: usize, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn mblen(__s: *const ::std::os::raw::c_char, __n: usize) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn mbtowc( + __pwc: *mut wchar_t, + __s: *const ::std::os::raw::c_char, + __n: usize, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn wctomb(__s: *mut ::std::os::raw::c_char, __wchar: wchar_t) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn mbstowcs(__pwcs: *mut wchar_t, __s: *const ::std::os::raw::c_char, __n: usize) -> usize; +} +extern "C" { + pub fn wcstombs(__s: *mut ::std::os::raw::c_char, __pwcs: *const wchar_t, __n: usize) -> usize; +} +extern "C" { + pub fn rpmatch(__response: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn getsubopt( + __optionp: *mut *mut ::std::os::raw::c_char, + __tokens: *const *mut ::std::os::raw::c_char, + __valuep: *mut *mut ::std::os::raw::c_char, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn getloadavg(__loadavg: *mut f64, __nelem: ::std::os::raw::c_int) + -> ::std::os::raw::c_int; +} +pub type int_least8_t = __int_least8_t; +pub type int_least16_t = __int_least16_t; +pub type int_least32_t = __int_least32_t; +pub type int_least64_t = __int_least64_t; +pub type uint_least8_t = __uint_least8_t; +pub type uint_least16_t = __uint_least16_t; +pub type uint_least32_t = __uint_least32_t; +pub type uint_least64_t = __uint_least64_t; +pub type int_fast8_t = ::std::os::raw::c_schar; +pub type int_fast16_t = ::std::os::raw::c_long; +pub type int_fast32_t = ::std::os::raw::c_long; +pub type int_fast64_t = ::std::os::raw::c_long; +pub type uint_fast8_t = ::std::os::raw::c_uchar; +pub type uint_fast16_t = ::std::os::raw::c_ulong; +pub type uint_fast32_t = ::std::os::raw::c_ulong; +pub type uint_fast64_t = ::std::os::raw::c_ulong; +pub type intmax_t = __intmax_t; +pub type uintmax_t = __uintmax_t; +extern "C" { + pub fn memcpy( + __dest: *mut ::std::os::raw::c_void, + __src: *const ::std::os::raw::c_void, + __n: ::std::os::raw::c_ulong, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn memmove( + __dest: *mut ::std::os::raw::c_void, + __src: *const ::std::os::raw::c_void, + __n: ::std::os::raw::c_ulong, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn memccpy( + __dest: *mut ::std::os::raw::c_void, + __src: *const ::std::os::raw::c_void, + __c: ::std::os::raw::c_int, + __n: ::std::os::raw::c_ulong, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn memset( + __s: *mut ::std::os::raw::c_void, + __c: ::std::os::raw::c_int, + __n: ::std::os::raw::c_ulong, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn memcmp( + __s1: *const ::std::os::raw::c_void, + __s2: *const ::std::os::raw::c_void, + __n: ::std::os::raw::c_ulong, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn memchr( + __s: *const ::std::os::raw::c_void, + __c: ::std::os::raw::c_int, + __n: ::std::os::raw::c_ulong, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn strcpy( + __dest: *mut ::std::os::raw::c_char, + __src: *const ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn strncpy( + __dest: *mut ::std::os::raw::c_char, + __src: *const ::std::os::raw::c_char, + __n: ::std::os::raw::c_ulong, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn strcat( + __dest: *mut ::std::os::raw::c_char, + __src: *const ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn strncat( + __dest: *mut ::std::os::raw::c_char, + __src: *const ::std::os::raw::c_char, + __n: ::std::os::raw::c_ulong, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn strcmp( + __s1: *const ::std::os::raw::c_char, + __s2: *const ::std::os::raw::c_char, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn strncmp( + __s1: *const ::std::os::raw::c_char, + __s2: *const ::std::os::raw::c_char, + __n: ::std::os::raw::c_ulong, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn strcoll( + __s1: *const ::std::os::raw::c_char, + __s2: *const ::std::os::raw::c_char, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn strxfrm( + __dest: *mut ::std::os::raw::c_char, + __src: *const ::std::os::raw::c_char, + __n: ::std::os::raw::c_ulong, + ) -> ::std::os::raw::c_ulong; +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __locale_struct { + pub __locales: [*mut __locale_data; 13usize], + pub __ctype_b: *const ::std::os::raw::c_ushort, + pub __ctype_tolower: *const ::std::os::raw::c_int, + pub __ctype_toupper: *const ::std::os::raw::c_int, + pub __names: [*const ::std::os::raw::c_char; 13usize], +} +#[test] +fn bindgen_test_layout___locale_struct() { assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_reserved as *const _ - as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_reserved) - ) + ::std::mem::size_of::<__locale_struct>(), + 232usize, + concat!("Size of: ", stringify!(__locale_struct)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_fcw as *const _ as usize - }, + ::std::mem::align_of::<__locale_struct>(), 8usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_fcw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_fsw as *const _ as usize - }, - 10usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_fsw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_ftw as *const _ as usize - }, - 12usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_ftw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_rsrv1 as *const _ as usize - }, - 13usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_rsrv1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_fop as *const _ as usize - }, - 14usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_fop) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_ip as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_ip) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_cs as *const _ as usize - }, - 20usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_cs) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_rsrv2 as *const _ as usize - }, - 22usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_rsrv2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_dp as *const _ as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_dp) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_ds as *const _ as usize - }, - 28usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_ds) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_rsrv3 as *const _ as usize - }, - 30usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_rsrv3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_mxcsr as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_mxcsr) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_mxcsrmask as *const _ - as usize - }, - 36usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_mxcsrmask) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_stmm0 as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_stmm0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_stmm1 as *const _ as usize - }, - 56usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_stmm1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_stmm2 as *const _ as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_stmm2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_stmm3 as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_stmm3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_stmm4 as *const _ as usize - }, - 104usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_stmm4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_stmm5 as *const _ as usize - }, - 120usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_stmm5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_stmm6 as *const _ as usize - }, - 136usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_stmm6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_stmm7 as *const _ as usize - }, - 152usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_stmm7) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_xmm0 as *const _ as usize - }, - 168usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_xmm0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_xmm1 as *const _ as usize - }, - 184usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_xmm1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_xmm2 as *const _ as usize - }, - 200usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_xmm2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_xmm3 as *const _ as usize - }, - 216usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_xmm3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_xmm4 as *const _ as usize - }, - 232usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_xmm4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_xmm5 as *const _ as usize - }, - 248usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_xmm5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_xmm6 as *const _ as usize - }, - 264usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_xmm6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_xmm7 as *const _ as usize - }, - 280usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_xmm7) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_rsrv4 as *const _ as usize - }, - 296usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_rsrv4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_reserved1 as *const _ - as usize - }, - 520usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_reserved1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__avx_reserved1 as *const _ - as usize - }, - 524usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__avx_reserved1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_ymmh0 as *const _ as usize - }, - 588usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_ymmh0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_ymmh1 as *const _ as usize - }, - 604usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_ymmh1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_ymmh2 as *const _ as usize - }, - 620usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_ymmh2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_ymmh3 as *const _ as usize - }, - 636usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_ymmh3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_ymmh4 as *const _ as usize - }, - 652usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_ymmh4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_ymmh5 as *const _ as usize - }, - 668usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_ymmh5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_ymmh6 as *const _ as usize - }, - 684usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_ymmh6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_ymmh7 as *const _ as usize - }, - 700usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_ymmh7) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_k0 as *const _ as usize - }, - 716usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_k0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_k1 as *const _ as usize - }, - 724usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_k1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_k2 as *const _ as usize - }, - 732usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_k2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_k3 as *const _ as usize - }, - 740usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_k3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_k4 as *const _ as usize - }, - 748usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_k4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_k5 as *const _ as usize - }, - 756usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_k5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_k6 as *const _ as usize - }, - 764usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_k6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_k7 as *const _ as usize - }, - 772usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_k7) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_zmmh0 as *const _ as usize - }, - 780usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_zmmh0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_zmmh1 as *const _ as usize - }, - 812usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_zmmh1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_zmmh2 as *const _ as usize - }, - 844usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_zmmh2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_zmmh3 as *const _ as usize - }, - 876usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_zmmh3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_zmmh4 as *const _ as usize - }, - 908usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_zmmh4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_zmmh5 as *const _ as usize - }, - 940usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_zmmh5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_zmmh6 as *const _ as usize - }, - 972usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_zmmh6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_zmmh7 as *const _ as usize - }, - 1004usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_zmmh7) - ) - ); + concat!("Alignment of ", stringify!(__locale_struct)) + ); + fn test_field___locales() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__locale_struct>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__locales) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__locale_struct), + "::", + stringify!(__locales) + ) + ); + } + test_field___locales(); + fn test_field___ctype_b() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__locale_struct>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__ctype_b) as usize - ptr as usize + }, + 104usize, + concat!( + "Offset of field: ", + stringify!(__locale_struct), + "::", + stringify!(__ctype_b) + ) + ); + } + test_field___ctype_b(); + fn test_field___ctype_tolower() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__locale_struct>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__ctype_tolower) as usize - ptr as usize + }, + 112usize, + concat!( + "Offset of field: ", + stringify!(__locale_struct), + "::", + stringify!(__ctype_tolower) + ) + ); + } + test_field___ctype_tolower(); + fn test_field___ctype_toupper() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__locale_struct>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__ctype_toupper) as usize - ptr as usize + }, + 120usize, + concat!( + "Offset of field: ", + stringify!(__locale_struct), + "::", + stringify!(__ctype_toupper) + ) + ); + } + test_field___ctype_toupper(); + fn test_field___names() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__locale_struct>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__names) as usize - ptr as usize + }, + 128usize, + concat!( + "Offset of field: ", + stringify!(__locale_struct), + "::", + stringify!(__names) + ) + ); + } + test_field___names(); } -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_i386_exception_state { - pub __trapno: __uint16_t, - pub __cpu: __uint16_t, - pub __err: __uint32_t, - pub __faultvaddr: __uint32_t, +pub type __locale_t = *mut __locale_struct; +pub type locale_t = __locale_t; +extern "C" { + pub fn strcoll_l( + __s1: *const ::std::os::raw::c_char, + __s2: *const ::std::os::raw::c_char, + __l: locale_t, + ) -> ::std::os::raw::c_int; } -#[test] -fn bindgen_test_layout___darwin_i386_exception_state() { - assert_eq!( - ::std::mem::size_of::<__darwin_i386_exception_state>(), - 12usize, - concat!("Size of: ", stringify!(__darwin_i386_exception_state)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_i386_exception_state>(), - 4usize, - concat!("Alignment of ", stringify!(__darwin_i386_exception_state)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_exception_state>())).__trapno as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_exception_state), - "::", - stringify!(__trapno) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_exception_state>())).__cpu as *const _ as usize - }, - 2usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_exception_state), - "::", - stringify!(__cpu) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_exception_state>())).__err as *const _ as usize - }, - 4usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_exception_state), - "::", - stringify!(__err) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_exception_state>())).__faultvaddr as *const _ - as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_exception_state), - "::", - stringify!(__faultvaddr) - ) - ); +extern "C" { + pub fn strxfrm_l( + __dest: *mut ::std::os::raw::c_char, + __src: *const ::std::os::raw::c_char, + __n: usize, + __l: locale_t, + ) -> usize; } -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_x86_debug_state32 { - pub __dr0: ::std::os::raw::c_uint, - pub __dr1: ::std::os::raw::c_uint, - pub __dr2: ::std::os::raw::c_uint, - pub __dr3: ::std::os::raw::c_uint, - pub __dr4: ::std::os::raw::c_uint, - pub __dr5: ::std::os::raw::c_uint, - pub __dr6: ::std::os::raw::c_uint, - pub __dr7: ::std::os::raw::c_uint, +extern "C" { + pub fn strdup(__s: *const ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; } -#[test] -fn bindgen_test_layout___darwin_x86_debug_state32() { - assert_eq!( - ::std::mem::size_of::<__darwin_x86_debug_state32>(), - 32usize, - concat!("Size of: ", stringify!(__darwin_x86_debug_state32)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_x86_debug_state32>(), - 4usize, - concat!("Alignment of ", stringify!(__darwin_x86_debug_state32)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_debug_state32>())).__dr0 as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_debug_state32), - "::", - stringify!(__dr0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_debug_state32>())).__dr1 as *const _ as usize - }, - 4usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_debug_state32), - "::", - stringify!(__dr1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_debug_state32>())).__dr2 as *const _ as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_debug_state32), - "::", - stringify!(__dr2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_debug_state32>())).__dr3 as *const _ as usize - }, - 12usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_debug_state32), - "::", - stringify!(__dr3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_debug_state32>())).__dr4 as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_debug_state32), - "::", - stringify!(__dr4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_debug_state32>())).__dr5 as *const _ as usize - }, - 20usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_debug_state32), - "::", - stringify!(__dr5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_debug_state32>())).__dr6 as *const _ as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_debug_state32), - "::", - stringify!(__dr6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_debug_state32>())).__dr7 as *const _ as usize - }, - 28usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_debug_state32), - "::", - stringify!(__dr7) - ) - ); +extern "C" { + pub fn strndup( + __string: *const ::std::os::raw::c_char, + __n: ::std::os::raw::c_ulong, + ) -> *mut ::std::os::raw::c_char; } -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __x86_instruction_state { - pub __insn_stream_valid_bytes: ::std::os::raw::c_int, - pub __insn_offset: ::std::os::raw::c_int, - pub __out_of_synch: ::std::os::raw::c_int, - pub __insn_bytes: [__uint8_t; 2380usize], - pub __insn_cacheline: [__uint8_t; 64usize], +extern "C" { + pub fn strchr( + __s: *const ::std::os::raw::c_char, + __c: ::std::os::raw::c_int, + ) -> *mut ::std::os::raw::c_char; } -#[test] -fn bindgen_test_layout___x86_instruction_state() { - assert_eq!( - ::std::mem::size_of::<__x86_instruction_state>(), - 2456usize, - concat!("Size of: ", stringify!(__x86_instruction_state)) - ); - assert_eq!( - ::std::mem::align_of::<__x86_instruction_state>(), - 4usize, - concat!("Alignment of ", stringify!(__x86_instruction_state)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__x86_instruction_state>())).__insn_stream_valid_bytes - as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__x86_instruction_state), - "::", - stringify!(__insn_stream_valid_bytes) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__x86_instruction_state>())).__insn_offset as *const _ as usize - }, - 4usize, - concat!( - "Offset of field: ", - stringify!(__x86_instruction_state), - "::", - stringify!(__insn_offset) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__x86_instruction_state>())).__out_of_synch as *const _ as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__x86_instruction_state), - "::", - stringify!(__out_of_synch) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__x86_instruction_state>())).__insn_bytes as *const _ as usize - }, - 12usize, - concat!( - "Offset of field: ", - stringify!(__x86_instruction_state), - "::", - stringify!(__insn_bytes) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__x86_instruction_state>())).__insn_cacheline as *const _ - as usize - }, - 2392usize, - concat!( - "Offset of field: ", - stringify!(__x86_instruction_state), - "::", - stringify!(__insn_cacheline) - ) - ); +extern "C" { + pub fn strrchr( + __s: *const ::std::os::raw::c_char, + __c: ::std::os::raw::c_int, + ) -> *mut ::std::os::raw::c_char; } -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __last_branch_record { - pub __from_ip: __uint64_t, - pub __to_ip: __uint64_t, - pub _bitfield_align_1: [u16; 0], - pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, - pub __bindgen_padding_0: u32, +extern "C" { + pub fn strcspn( + __s: *const ::std::os::raw::c_char, + __reject: *const ::std::os::raw::c_char, + ) -> ::std::os::raw::c_ulong; } -#[test] -fn bindgen_test_layout___last_branch_record() { - assert_eq!( - ::std::mem::size_of::<__last_branch_record>(), - 24usize, - concat!("Size of: ", stringify!(__last_branch_record)) - ); - assert_eq!( - ::std::mem::align_of::<__last_branch_record>(), - 8usize, - concat!("Alignment of ", stringify!(__last_branch_record)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__last_branch_record>())).__from_ip as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__last_branch_record), - "::", - stringify!(__from_ip) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__last_branch_record>())).__to_ip as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__last_branch_record), - "::", - stringify!(__to_ip) - ) - ); +extern "C" { + pub fn strspn( + __s: *const ::std::os::raw::c_char, + __accept: *const ::std::os::raw::c_char, + ) -> ::std::os::raw::c_ulong; } -impl __last_branch_record { - #[inline] - pub fn __mispredict(&self) -> __uint32_t { - unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u32) } - } - #[inline] - pub fn set___mispredict(&mut self, val: __uint32_t) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(0usize, 1u8, val as u64) - } - } - #[inline] - pub fn __tsx_abort(&self) -> __uint32_t { - unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 1u8) as u32) } - } - #[inline] - pub fn set___tsx_abort(&mut self, val: __uint32_t) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(1usize, 1u8, val as u64) - } - } - #[inline] - pub fn __in_tsx(&self) -> __uint32_t { - unsafe { ::std::mem::transmute(self._bitfield_1.get(2usize, 1u8) as u32) } - } - #[inline] - pub fn set___in_tsx(&mut self, val: __uint32_t) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(2usize, 1u8, val as u64) - } - } - #[inline] - pub fn __cycle_count(&self) -> __uint32_t { - unsafe { ::std::mem::transmute(self._bitfield_1.get(3usize, 16u8) as u32) } - } - #[inline] - pub fn set___cycle_count(&mut self, val: __uint32_t) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(3usize, 16u8, val as u64) - } - } - #[inline] - pub fn __reserved(&self) -> __uint32_t { - unsafe { ::std::mem::transmute(self._bitfield_1.get(19usize, 13u8) as u32) } - } - #[inline] - pub fn set___reserved(&mut self, val: __uint32_t) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(19usize, 13u8, val as u64) - } - } - #[inline] - pub fn new_bitfield_1( - __mispredict: __uint32_t, - __tsx_abort: __uint32_t, - __in_tsx: __uint32_t, - __cycle_count: __uint32_t, - __reserved: __uint32_t, - ) -> __BindgenBitfieldUnit<[u8; 4usize]> { - let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 4usize]> = Default::default(); - __bindgen_bitfield_unit.set(0usize, 1u8, { - let __mispredict: u32 = unsafe { ::std::mem::transmute(__mispredict) }; - __mispredict as u64 - }); - __bindgen_bitfield_unit.set(1usize, 1u8, { - let __tsx_abort: u32 = unsafe { ::std::mem::transmute(__tsx_abort) }; - __tsx_abort as u64 - }); - __bindgen_bitfield_unit.set(2usize, 1u8, { - let __in_tsx: u32 = unsafe { ::std::mem::transmute(__in_tsx) }; - __in_tsx as u64 - }); - __bindgen_bitfield_unit.set(3usize, 16u8, { - let __cycle_count: u32 = unsafe { ::std::mem::transmute(__cycle_count) }; - __cycle_count as u64 - }); - __bindgen_bitfield_unit.set(19usize, 13u8, { - let __reserved: u32 = unsafe { ::std::mem::transmute(__reserved) }; - __reserved as u64 - }); - __bindgen_bitfield_unit - } +extern "C" { + pub fn strpbrk( + __s: *const ::std::os::raw::c_char, + __accept: *const ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; } -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __last_branch_state { - pub __lbr_count: ::std::os::raw::c_int, - pub _bitfield_align_1: [u32; 0], - pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, - pub __lbrs: [__last_branch_record; 32usize], +extern "C" { + pub fn strstr( + __haystack: *const ::std::os::raw::c_char, + __needle: *const ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; } -#[test] -fn bindgen_test_layout___last_branch_state() { - assert_eq!( - ::std::mem::size_of::<__last_branch_state>(), - 776usize, - concat!("Size of: ", stringify!(__last_branch_state)) - ); - assert_eq!( - ::std::mem::align_of::<__last_branch_state>(), - 8usize, - concat!("Alignment of ", stringify!(__last_branch_state)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__last_branch_state>())).__lbr_count as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__last_branch_state), - "::", - stringify!(__lbr_count) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__last_branch_state>())).__lbrs as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__last_branch_state), - "::", - stringify!(__lbrs) - ) - ); +extern "C" { + pub fn strtok( + __s: *mut ::std::os::raw::c_char, + __delim: *const ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; } -impl __last_branch_state { - #[inline] - pub fn __lbr_supported_tsx(&self) -> __uint32_t { - unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u32) } - } - #[inline] - pub fn set___lbr_supported_tsx(&mut self, val: __uint32_t) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(0usize, 1u8, val as u64) - } - } - #[inline] - pub fn __lbr_supported_cycle_count(&self) -> __uint32_t { - unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 1u8) as u32) } - } - #[inline] - pub fn set___lbr_supported_cycle_count(&mut self, val: __uint32_t) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(1usize, 1u8, val as u64) - } - } - #[inline] - pub fn __reserved(&self) -> __uint32_t { - unsafe { ::std::mem::transmute(self._bitfield_1.get(2usize, 30u8) as u32) } - } - #[inline] - pub fn set___reserved(&mut self, val: __uint32_t) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(2usize, 30u8, val as u64) - } - } - #[inline] - pub fn new_bitfield_1( - __lbr_supported_tsx: __uint32_t, - __lbr_supported_cycle_count: __uint32_t, - __reserved: __uint32_t, - ) -> __BindgenBitfieldUnit<[u8; 4usize]> { - let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 4usize]> = Default::default(); - __bindgen_bitfield_unit.set(0usize, 1u8, { - let __lbr_supported_tsx: u32 = unsafe { ::std::mem::transmute(__lbr_supported_tsx) }; - __lbr_supported_tsx as u64 - }); - __bindgen_bitfield_unit.set(1usize, 1u8, { - let __lbr_supported_cycle_count: u32 = - unsafe { ::std::mem::transmute(__lbr_supported_cycle_count) }; - __lbr_supported_cycle_count as u64 - }); - __bindgen_bitfield_unit.set(2usize, 30u8, { - let __reserved: u32 = unsafe { ::std::mem::transmute(__reserved) }; - __reserved as u64 - }); - __bindgen_bitfield_unit - } +extern "C" { + pub fn __strtok_r( + __s: *mut ::std::os::raw::c_char, + __delim: *const ::std::os::raw::c_char, + __save_ptr: *mut *mut ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; } -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __x86_pagein_state { - pub __pagein_error: ::std::os::raw::c_int, +extern "C" { + pub fn strtok_r( + __s: *mut ::std::os::raw::c_char, + __delim: *const ::std::os::raw::c_char, + __save_ptr: *mut *mut ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; } -#[test] -fn bindgen_test_layout___x86_pagein_state() { - assert_eq!( - ::std::mem::size_of::<__x86_pagein_state>(), - 4usize, - concat!("Size of: ", stringify!(__x86_pagein_state)) - ); - assert_eq!( - ::std::mem::align_of::<__x86_pagein_state>(), - 4usize, - concat!("Alignment of ", stringify!(__x86_pagein_state)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__x86_pagein_state>())).__pagein_error as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__x86_pagein_state), - "::", - stringify!(__pagein_error) - ) - ); +extern "C" { + pub fn strlen(__s: *const ::std::os::raw::c_char) -> ::std::os::raw::c_ulong; } -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_x86_thread_state64 { - pub __rax: __uint64_t, - pub __rbx: __uint64_t, - pub __rcx: __uint64_t, - pub __rdx: __uint64_t, - pub __rdi: __uint64_t, - pub __rsi: __uint64_t, - pub __rbp: __uint64_t, - pub __rsp: __uint64_t, - pub __r8: __uint64_t, - pub __r9: __uint64_t, - pub __r10: __uint64_t, - pub __r11: __uint64_t, - pub __r12: __uint64_t, - pub __r13: __uint64_t, - pub __r14: __uint64_t, - pub __r15: __uint64_t, - pub __rip: __uint64_t, - pub __rflags: __uint64_t, - pub __cs: __uint64_t, - pub __fs: __uint64_t, - pub __gs: __uint64_t, +extern "C" { + pub fn strnlen(__string: *const ::std::os::raw::c_char, __maxlen: usize) -> usize; } -#[test] -fn bindgen_test_layout___darwin_x86_thread_state64() { - assert_eq!( - ::std::mem::size_of::<__darwin_x86_thread_state64>(), - 168usize, - concat!("Size of: ", stringify!(__darwin_x86_thread_state64)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_x86_thread_state64>(), - 8usize, - concat!("Alignment of ", stringify!(__darwin_x86_thread_state64)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__rax as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__rax) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__rbx as *const _ as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__rbx) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__rcx as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__rcx) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__rdx as *const _ as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__rdx) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__rdi as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__rdi) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__rsi as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__rsi) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__rbp as *const _ as usize - }, - 48usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__rbp) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__rsp as *const _ as usize - }, - 56usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__rsp) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__r8 as *const _ as usize - }, - 64usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__r8) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__r9 as *const _ as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__r9) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__r10 as *const _ as usize - }, - 80usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__r10) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__r11 as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__r11) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__r12 as *const _ as usize - }, - 96usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__r12) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__r13 as *const _ as usize - }, - 104usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__r13) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__r14 as *const _ as usize - }, - 112usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__r14) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__r15 as *const _ as usize - }, - 120usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__r15) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__rip as *const _ as usize - }, - 128usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__rip) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__rflags as *const _ as usize - }, - 136usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__rflags) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__cs as *const _ as usize - }, - 144usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__cs) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__fs as *const _ as usize - }, - 152usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__fs) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__gs as *const _ as usize - }, - 160usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__gs) - ) - ); +extern "C" { + pub fn strerror(__errnum: ::std::os::raw::c_int) -> *mut ::std::os::raw::c_char; } -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_x86_thread_full_state64 { - pub __ss64: __darwin_x86_thread_state64, - pub __ds: __uint64_t, - pub __es: __uint64_t, - pub __ss: __uint64_t, - pub __gsbase: __uint64_t, +extern "C" { + #[link_name = "\u{1}__xpg_strerror_r"] + pub fn strerror_r( + __errnum: ::std::os::raw::c_int, + __buf: *mut ::std::os::raw::c_char, + __buflen: usize, + ) -> ::std::os::raw::c_int; } -#[test] -fn bindgen_test_layout___darwin_x86_thread_full_state64() { - assert_eq!( - ::std::mem::size_of::<__darwin_x86_thread_full_state64>(), - 200usize, - concat!("Size of: ", stringify!(__darwin_x86_thread_full_state64)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_x86_thread_full_state64>(), - 8usize, - concat!( - "Alignment of ", - stringify!(__darwin_x86_thread_full_state64) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_full_state64>())).__ss64 as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_full_state64), - "::", - stringify!(__ss64) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_full_state64>())).__ds as *const _ as usize - }, - 168usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_full_state64), - "::", - stringify!(__ds) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_full_state64>())).__es as *const _ as usize - }, - 176usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_full_state64), - "::", - stringify!(__es) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_full_state64>())).__ss as *const _ as usize - }, - 184usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_full_state64), - "::", - stringify!(__ss) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_full_state64>())).__gsbase as *const _ - as usize - }, - 192usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_full_state64), - "::", - stringify!(__gsbase) - ) - ); +extern "C" { + pub fn strerror_l( + __errnum: ::std::os::raw::c_int, + __l: locale_t, + ) -> *mut ::std::os::raw::c_char; } -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_x86_float_state64 { - pub __fpu_reserved: [::std::os::raw::c_int; 2usize], - pub __fpu_fcw: __darwin_fp_control, - pub __fpu_fsw: __darwin_fp_status, - pub __fpu_ftw: __uint8_t, - pub __fpu_rsrv1: __uint8_t, - pub __fpu_fop: __uint16_t, - pub __fpu_ip: __uint32_t, - pub __fpu_cs: __uint16_t, - pub __fpu_rsrv2: __uint16_t, - pub __fpu_dp: __uint32_t, - pub __fpu_ds: __uint16_t, - pub __fpu_rsrv3: __uint16_t, - pub __fpu_mxcsr: __uint32_t, - pub __fpu_mxcsrmask: __uint32_t, - pub __fpu_stmm0: __darwin_mmst_reg, - pub __fpu_stmm1: __darwin_mmst_reg, - pub __fpu_stmm2: __darwin_mmst_reg, - pub __fpu_stmm3: __darwin_mmst_reg, - pub __fpu_stmm4: __darwin_mmst_reg, - pub __fpu_stmm5: __darwin_mmst_reg, - pub __fpu_stmm6: __darwin_mmst_reg, - pub __fpu_stmm7: __darwin_mmst_reg, - pub __fpu_xmm0: __darwin_xmm_reg, - pub __fpu_xmm1: __darwin_xmm_reg, - pub __fpu_xmm2: __darwin_xmm_reg, - pub __fpu_xmm3: __darwin_xmm_reg, - pub __fpu_xmm4: __darwin_xmm_reg, - pub __fpu_xmm5: __darwin_xmm_reg, - pub __fpu_xmm6: __darwin_xmm_reg, - pub __fpu_xmm7: __darwin_xmm_reg, - pub __fpu_xmm8: __darwin_xmm_reg, - pub __fpu_xmm9: __darwin_xmm_reg, - pub __fpu_xmm10: __darwin_xmm_reg, - pub __fpu_xmm11: __darwin_xmm_reg, - pub __fpu_xmm12: __darwin_xmm_reg, - pub __fpu_xmm13: __darwin_xmm_reg, - pub __fpu_xmm14: __darwin_xmm_reg, - pub __fpu_xmm15: __darwin_xmm_reg, - pub __fpu_rsrv4: [::std::os::raw::c_char; 96usize], - pub __fpu_reserved1: ::std::os::raw::c_int, +extern "C" { + pub fn bcmp( + __s1: *const ::std::os::raw::c_void, + __s2: *const ::std::os::raw::c_void, + __n: ::std::os::raw::c_ulong, + ) -> ::std::os::raw::c_int; } -#[test] -fn bindgen_test_layout___darwin_x86_float_state64() { - assert_eq!( - ::std::mem::size_of::<__darwin_x86_float_state64>(), - 524usize, - concat!("Size of: ", stringify!(__darwin_x86_float_state64)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_x86_float_state64>(), - 4usize, - concat!("Alignment of ", stringify!(__darwin_x86_float_state64)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_reserved as *const _ - as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_reserved) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_fcw as *const _ as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_fcw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_fsw as *const _ as usize - }, - 10usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_fsw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_ftw as *const _ as usize - }, - 12usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_ftw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_rsrv1 as *const _ as usize - }, - 13usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_rsrv1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_fop as *const _ as usize - }, - 14usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_fop) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_ip as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_ip) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_cs as *const _ as usize - }, - 20usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_cs) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_rsrv2 as *const _ as usize - }, - 22usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_rsrv2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_dp as *const _ as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_dp) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_ds as *const _ as usize - }, - 28usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_ds) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_rsrv3 as *const _ as usize - }, - 30usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_rsrv3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_mxcsr as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_mxcsr) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_mxcsrmask as *const _ - as usize - }, - 36usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_mxcsrmask) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_stmm0 as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_stmm0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_stmm1 as *const _ as usize - }, - 56usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_stmm1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_stmm2 as *const _ as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_stmm2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_stmm3 as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_stmm3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_stmm4 as *const _ as usize - }, - 104usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_stmm4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_stmm5 as *const _ as usize - }, - 120usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_stmm5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_stmm6 as *const _ as usize - }, - 136usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_stmm6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_stmm7 as *const _ as usize - }, - 152usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_stmm7) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_xmm0 as *const _ as usize - }, - 168usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_xmm0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_xmm1 as *const _ as usize - }, - 184usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_xmm1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_xmm2 as *const _ as usize - }, - 200usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_xmm2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_xmm3 as *const _ as usize - }, - 216usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_xmm3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_xmm4 as *const _ as usize - }, - 232usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_xmm4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_xmm5 as *const _ as usize - }, - 248usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_xmm5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_xmm6 as *const _ as usize - }, - 264usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_xmm6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_xmm7 as *const _ as usize - }, - 280usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_xmm7) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_xmm8 as *const _ as usize - }, - 296usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_xmm8) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_xmm9 as *const _ as usize - }, - 312usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_xmm9) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_xmm10 as *const _ as usize - }, - 328usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_xmm10) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_xmm11 as *const _ as usize - }, - 344usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_xmm11) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_xmm12 as *const _ as usize - }, - 360usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_xmm12) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_xmm13 as *const _ as usize - }, - 376usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_xmm13) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_xmm14 as *const _ as usize - }, - 392usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_xmm14) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_xmm15 as *const _ as usize - }, - 408usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_xmm15) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_rsrv4 as *const _ as usize - }, - 424usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_rsrv4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_reserved1 as *const _ - as usize - }, - 520usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_reserved1) - ) +extern "C" { + pub fn bcopy( + __src: *const ::std::os::raw::c_void, + __dest: *mut ::std::os::raw::c_void, + __n: usize, ); } -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_x86_avx_state64 { - pub __fpu_reserved: [::std::os::raw::c_int; 2usize], - pub __fpu_fcw: __darwin_fp_control, - pub __fpu_fsw: __darwin_fp_status, - pub __fpu_ftw: __uint8_t, - pub __fpu_rsrv1: __uint8_t, - pub __fpu_fop: __uint16_t, - pub __fpu_ip: __uint32_t, - pub __fpu_cs: __uint16_t, - pub __fpu_rsrv2: __uint16_t, - pub __fpu_dp: __uint32_t, - pub __fpu_ds: __uint16_t, - pub __fpu_rsrv3: __uint16_t, - pub __fpu_mxcsr: __uint32_t, - pub __fpu_mxcsrmask: __uint32_t, - pub __fpu_stmm0: __darwin_mmst_reg, - pub __fpu_stmm1: __darwin_mmst_reg, - pub __fpu_stmm2: __darwin_mmst_reg, - pub __fpu_stmm3: __darwin_mmst_reg, - pub __fpu_stmm4: __darwin_mmst_reg, - pub __fpu_stmm5: __darwin_mmst_reg, - pub __fpu_stmm6: __darwin_mmst_reg, - pub __fpu_stmm7: __darwin_mmst_reg, - pub __fpu_xmm0: __darwin_xmm_reg, - pub __fpu_xmm1: __darwin_xmm_reg, - pub __fpu_xmm2: __darwin_xmm_reg, - pub __fpu_xmm3: __darwin_xmm_reg, - pub __fpu_xmm4: __darwin_xmm_reg, - pub __fpu_xmm5: __darwin_xmm_reg, - pub __fpu_xmm6: __darwin_xmm_reg, - pub __fpu_xmm7: __darwin_xmm_reg, - pub __fpu_xmm8: __darwin_xmm_reg, - pub __fpu_xmm9: __darwin_xmm_reg, - pub __fpu_xmm10: __darwin_xmm_reg, - pub __fpu_xmm11: __darwin_xmm_reg, - pub __fpu_xmm12: __darwin_xmm_reg, - pub __fpu_xmm13: __darwin_xmm_reg, - pub __fpu_xmm14: __darwin_xmm_reg, - pub __fpu_xmm15: __darwin_xmm_reg, - pub __fpu_rsrv4: [::std::os::raw::c_char; 96usize], - pub __fpu_reserved1: ::std::os::raw::c_int, - pub __avx_reserved1: [::std::os::raw::c_char; 64usize], - pub __fpu_ymmh0: __darwin_xmm_reg, - pub __fpu_ymmh1: __darwin_xmm_reg, - pub __fpu_ymmh2: __darwin_xmm_reg, - pub __fpu_ymmh3: __darwin_xmm_reg, - pub __fpu_ymmh4: __darwin_xmm_reg, - pub __fpu_ymmh5: __darwin_xmm_reg, - pub __fpu_ymmh6: __darwin_xmm_reg, - pub __fpu_ymmh7: __darwin_xmm_reg, - pub __fpu_ymmh8: __darwin_xmm_reg, - pub __fpu_ymmh9: __darwin_xmm_reg, - pub __fpu_ymmh10: __darwin_xmm_reg, - pub __fpu_ymmh11: __darwin_xmm_reg, - pub __fpu_ymmh12: __darwin_xmm_reg, - pub __fpu_ymmh13: __darwin_xmm_reg, - pub __fpu_ymmh14: __darwin_xmm_reg, - pub __fpu_ymmh15: __darwin_xmm_reg, +extern "C" { + pub fn bzero(__s: *mut ::std::os::raw::c_void, __n: ::std::os::raw::c_ulong); } -#[test] -fn bindgen_test_layout___darwin_x86_avx_state64() { - assert_eq!( - ::std::mem::size_of::<__darwin_x86_avx_state64>(), - 844usize, - concat!("Size of: ", stringify!(__darwin_x86_avx_state64)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_x86_avx_state64>(), - 4usize, - concat!("Alignment of ", stringify!(__darwin_x86_avx_state64)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_reserved as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_reserved) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_fcw as *const _ as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_fcw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_fsw as *const _ as usize - }, - 10usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_fsw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ftw as *const _ as usize - }, - 12usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ftw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_rsrv1 as *const _ as usize - }, - 13usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_rsrv1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_fop as *const _ as usize - }, - 14usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_fop) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ip as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ip) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_cs as *const _ as usize - }, - 20usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_cs) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_rsrv2 as *const _ as usize - }, - 22usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_rsrv2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_dp as *const _ as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_dp) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ds as *const _ as usize - }, - 28usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ds) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_rsrv3 as *const _ as usize - }, - 30usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_rsrv3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_mxcsr as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_mxcsr) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_mxcsrmask as *const _ - as usize - }, - 36usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_mxcsrmask) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_stmm0 as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_stmm0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_stmm1 as *const _ as usize - }, - 56usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_stmm1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_stmm2 as *const _ as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_stmm2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_stmm3 as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_stmm3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_stmm4 as *const _ as usize - }, - 104usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_stmm4) - ) - ); +extern "C" { + pub fn index( + __s: *const ::std::os::raw::c_char, + __c: ::std::os::raw::c_int, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn rindex( + __s: *const ::std::os::raw::c_char, + __c: ::std::os::raw::c_int, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn ffs(__i: ::std::os::raw::c_int) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn ffsl(__l: ::std::os::raw::c_long) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn ffsll(__ll: ::std::os::raw::c_longlong) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn strcasecmp( + __s1: *const ::std::os::raw::c_char, + __s2: *const ::std::os::raw::c_char, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn strncasecmp( + __s1: *const ::std::os::raw::c_char, + __s2: *const ::std::os::raw::c_char, + __n: ::std::os::raw::c_ulong, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn strcasecmp_l( + __s1: *const ::std::os::raw::c_char, + __s2: *const ::std::os::raw::c_char, + __loc: locale_t, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn strncasecmp_l( + __s1: *const ::std::os::raw::c_char, + __s2: *const ::std::os::raw::c_char, + __n: usize, + __loc: locale_t, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn explicit_bzero(__s: *mut ::std::os::raw::c_void, __n: usize); +} +extern "C" { + pub fn strsep( + __stringp: *mut *mut ::std::os::raw::c_char, + __delim: *const ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn strsignal(__sig: ::std::os::raw::c_int) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn __stpcpy( + __dest: *mut ::std::os::raw::c_char, + __src: *const ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn stpcpy( + __dest: *mut ::std::os::raw::c_char, + __src: *const ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn __stpncpy( + __dest: *mut ::std::os::raw::c_char, + __src: *const ::std::os::raw::c_char, + __n: usize, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn stpncpy( + __dest: *mut ::std::os::raw::c_char, + __src: *const ::std::os::raw::c_char, + __n: ::std::os::raw::c_ulong, + ) -> *mut ::std::os::raw::c_char; +} +#[repr(u32)] +#[doc = " Copied from TensorProto::DataType"] +#[doc = " Currently, Ort doesn't support complex64, complex128"] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum ONNXTensorElementDataType { + ONNX_TENSOR_ELEMENT_DATA_TYPE_UNDEFINED = 0, + ONNX_TENSOR_ELEMENT_DATA_TYPE_FLOAT = 1, + ONNX_TENSOR_ELEMENT_DATA_TYPE_UINT8 = 2, + ONNX_TENSOR_ELEMENT_DATA_TYPE_INT8 = 3, + ONNX_TENSOR_ELEMENT_DATA_TYPE_UINT16 = 4, + ONNX_TENSOR_ELEMENT_DATA_TYPE_INT16 = 5, + ONNX_TENSOR_ELEMENT_DATA_TYPE_INT32 = 6, + ONNX_TENSOR_ELEMENT_DATA_TYPE_INT64 = 7, + ONNX_TENSOR_ELEMENT_DATA_TYPE_STRING = 8, + ONNX_TENSOR_ELEMENT_DATA_TYPE_BOOL = 9, + ONNX_TENSOR_ELEMENT_DATA_TYPE_FLOAT16 = 10, + ONNX_TENSOR_ELEMENT_DATA_TYPE_DOUBLE = 11, + ONNX_TENSOR_ELEMENT_DATA_TYPE_UINT32 = 12, + ONNX_TENSOR_ELEMENT_DATA_TYPE_UINT64 = 13, + ONNX_TENSOR_ELEMENT_DATA_TYPE_COMPLEX64 = 14, + ONNX_TENSOR_ELEMENT_DATA_TYPE_COMPLEX128 = 15, + ONNX_TENSOR_ELEMENT_DATA_TYPE_BFLOAT16 = 16, +} +#[repr(u32)] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum ONNXType { + ONNX_TYPE_UNKNOWN = 0, + ONNX_TYPE_TENSOR = 1, + ONNX_TYPE_SEQUENCE = 2, + ONNX_TYPE_MAP = 3, + ONNX_TYPE_OPAQUE = 4, + ONNX_TYPE_SPARSETENSOR = 5, + ONNX_TYPE_OPTIONAL = 6, +} +#[repr(u32)] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum OrtSparseFormat { + ORT_SPARSE_UNDEFINED = 0, + ORT_SPARSE_COO = 1, + ORT_SPARSE_CSRC = 2, + ORT_SPARSE_BLOCK_SPARSE = 4, +} +#[repr(u32)] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum OrtSparseIndicesFormat { + ORT_SPARSE_COO_INDICES = 0, + ORT_SPARSE_CSR_INNER_INDICES = 1, + ORT_SPARSE_CSR_OUTER_INDICES = 2, + ORT_SPARSE_BLOCK_SPARSE_INDICES = 3, +} +#[repr(u32)] +#[doc = " \\brief Logging severity levels"] +#[doc = ""] +#[doc = " In typical API usage, specifying a logging severity level specifies the minimum severity of log messages to show."] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum OrtLoggingLevel { + #[doc = "< Verbose informational messages (least severe)."] + ORT_LOGGING_LEVEL_VERBOSE = 0, + #[doc = "< Informational messages."] + ORT_LOGGING_LEVEL_INFO = 1, + #[doc = "< Warning messages."] + ORT_LOGGING_LEVEL_WARNING = 2, + #[doc = "< Error messages."] + ORT_LOGGING_LEVEL_ERROR = 3, + #[doc = "< Fatal error messages (most severe)."] + ORT_LOGGING_LEVEL_FATAL = 4, +} +#[repr(u32)] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum OrtErrorCode { + ORT_OK = 0, + ORT_FAIL = 1, + ORT_INVALID_ARGUMENT = 2, + ORT_NO_SUCHFILE = 3, + ORT_NO_MODEL = 4, + ORT_ENGINE_ERROR = 5, + ORT_RUNTIME_EXCEPTION = 6, + ORT_INVALID_PROTOBUF = 7, + ORT_MODEL_LOADED = 8, + ORT_NOT_IMPLEMENTED = 9, + ORT_INVALID_GRAPH = 10, + ORT_EP_FAIL = 11, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtEnv { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtStatus { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtMemoryInfo { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtIoBinding { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtSession { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtValue { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtRunOptions { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtTypeInfo { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtTensorTypeAndShapeInfo { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtSessionOptions { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtCustomOpDomain { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtMapTypeInfo { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtSequenceTypeInfo { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtModelMetadata { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtThreadPoolParams { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtThreadingOptions { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtArenaCfg { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtPrepackedWeightsContainer { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtTensorRTProviderOptionsV2 { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtCUDAProviderOptionsV2 { + _unused: [u8; 0], +} +pub type OrtStatusPtr = *mut OrtStatus; +#[doc = " \\brief Memory allocation interface"] +#[doc = ""] +#[doc = " Structure of function pointers that defines a memory allocator. This can be created and filled in by the user for custom allocators."] +#[doc = ""] +#[doc = " When an allocator is passed to any function, be sure that the allocator object is not destroyed until the last allocated object using it is freed."] +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtAllocator { + #[doc = "< Must be initialized to ORT_API_VERSION"] + pub version: u32, + #[doc = "< Returns a pointer to an allocated block of `size` bytes"] + pub Alloc: ::std::option::Option< + unsafe extern "C" fn(this_: *mut OrtAllocator, size: usize) -> *mut ::std::os::raw::c_void, + >, + #[doc = "< Free a block of memory previously allocated with OrtAllocator::Alloc"] + pub Free: ::std::option::Option< + unsafe extern "C" fn(this_: *mut OrtAllocator, p: *mut ::std::os::raw::c_void), + >, + #[doc = "< Return a pointer to an ::OrtMemoryInfo that describes this allocator"] + pub Info: ::std::option::Option< + unsafe extern "C" fn(this_: *const OrtAllocator) -> *const OrtMemoryInfo, + >, +} +#[test] +fn bindgen_test_layout_OrtAllocator() { assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_stmm5 as *const _ as usize - }, - 120usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_stmm5) - ) + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(OrtAllocator)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_stmm6 as *const _ as usize - }, - 136usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_stmm6) - ) + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(OrtAllocator)) ); + fn test_field_version() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).version) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtAllocator), + "::", + stringify!(version) + ) + ); + } + test_field_version(); + fn test_field_Alloc() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).Alloc) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtAllocator), + "::", + stringify!(Alloc) + ) + ); + } + test_field_Alloc(); + fn test_field_Free() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).Free) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(OrtAllocator), + "::", + stringify!(Free) + ) + ); + } + test_field_Free(); + fn test_field_Info() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).Info) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(OrtAllocator), + "::", + stringify!(Info) + ) + ); + } + test_field_Info(); +} +pub type OrtLoggingFunction = ::std::option::Option< + unsafe extern "C" fn( + param: *mut ::std::os::raw::c_void, + severity: OrtLoggingLevel, + category: *const ::std::os::raw::c_char, + logid: *const ::std::os::raw::c_char, + code_location: *const ::std::os::raw::c_char, + message: *const ::std::os::raw::c_char, + ), +>; +#[repr(u32)] +#[doc = " \\brief Graph optimization level"] +#[doc = ""] +#[doc = " Refer to https://www.onnxruntime.ai/docs/resources/graph-optimizations.html"] +#[doc = " for an in-depth understanding of Graph Optimizations"] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum GraphOptimizationLevel { + ORT_DISABLE_ALL = 0, + ORT_ENABLE_BASIC = 1, + ORT_ENABLE_EXTENDED = 2, + ORT_ENABLE_ALL = 99, +} +#[repr(u32)] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum ExecutionMode { + ORT_SEQUENTIAL = 0, + ORT_PARALLEL = 1, +} +#[repr(u32)] +#[doc = " \\brief Language projection identifiers"] +#[doc = " /see OrtApi::SetLanguageProjection"] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum OrtLanguageProjection { + ORT_PROJECTION_C = 0, + ORT_PROJECTION_CPLUSPLUS = 1, + ORT_PROJECTION_CSHARP = 2, + ORT_PROJECTION_PYTHON = 3, + ORT_PROJECTION_JAVA = 4, + ORT_PROJECTION_WINML = 5, + ORT_PROJECTION_NODEJS = 6, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtKernelInfo { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtKernelContext { + _unused: [u8; 0], +} +#[repr(i32)] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum OrtAllocatorType { + OrtInvalidAllocator = -1, + OrtDeviceAllocator = 0, + OrtArenaAllocator = 1, +} +impl OrtMemType { + pub const OrtMemTypeCPU: OrtMemType = OrtMemType::OrtMemTypeCPUOutput; +} +#[repr(i32)] +#[doc = " \\brief Memory types for allocated memory, execution provider specific types should be extended in each provider."] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum OrtMemType { + #[doc = "< Any CPU memory used by non-CPU execution provider"] + OrtMemTypeCPUInput = -2, + #[doc = "< CPU accessible memory outputted by non-CPU execution provider, i.e. CUDA_PINNED"] + OrtMemTypeCPUOutput = -1, + #[doc = "< The default allocator for execution provider"] + OrtMemTypeDefault = 0, +} +#[repr(u32)] +#[doc = " \\brief Algorithm to use for cuDNN Convolution Op"] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum OrtCudnnConvAlgoSearch { + OrtCudnnConvAlgoSearchExhaustive = 0, + OrtCudnnConvAlgoSearchHeuristic = 1, + OrtCudnnConvAlgoSearchDefault = 2, +} +#[doc = " \\brief CUDA Provider Options"] +#[doc = ""] +#[doc = " \\see OrtApi::SessionOptionsAppendExecutionProvider_CUDA"] +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtCUDAProviderOptions { + #[doc = " \\brief CUDA device Id"] + #[doc = " Defaults to 0."] + pub device_id: ::std::os::raw::c_int, + #[doc = " \\brief CUDA Convolution algorithm search configuration."] + #[doc = " See enum OrtCudnnConvAlgoSearch for more details."] + #[doc = " Defaults to OrtCudnnConvAlgoSearchExhaustive."] + pub cudnn_conv_algo_search: OrtCudnnConvAlgoSearch, + #[doc = " \\brief CUDA memory limit (To use all possible memory pass in maximum size_t)"] + #[doc = " Defaults to SIZE_MAX."] + #[doc = " \\note If a ::OrtArenaCfg has been applied, it will override this field"] + pub gpu_mem_limit: usize, + #[doc = " \\brief Strategy used to grow the memory arena"] + #[doc = " 0 = kNextPowerOfTwo
"] + #[doc = " 1 = kSameAsRequested
"] + #[doc = " Defaults to 0."] + #[doc = " \\note If a ::OrtArenaCfg has been applied, it will override this field"] + pub arena_extend_strategy: ::std::os::raw::c_int, + #[doc = " \\brief Flag indicating if copying needs to take place on the same stream as the compute stream in the CUDA EP"] + #[doc = " 0 = Use separate streams for copying and compute."] + #[doc = " 1 = Use the same stream for copying and compute."] + #[doc = " Defaults to 1."] + #[doc = " WARNING: Setting this to 0 may result in data races for some models."] + #[doc = " Please see issue #4829 for more details."] + pub do_copy_in_default_stream: ::std::os::raw::c_int, + #[doc = " \\brief Flag indicating if there is a user provided compute stream"] + #[doc = " Defaults to 0."] + pub has_user_compute_stream: ::std::os::raw::c_int, + #[doc = " \\brief User provided compute stream."] + #[doc = " If provided, please set `has_user_compute_stream` to 1."] + pub user_compute_stream: *mut ::std::os::raw::c_void, + #[doc = " \\brief CUDA memory arena configuration parameters"] + pub default_memory_arena_cfg: *mut OrtArenaCfg, +} +#[test] +fn bindgen_test_layout_OrtCUDAProviderOptions() { assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_stmm7 as *const _ as usize - }, - 152usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_stmm7) - ) + ::std::mem::size_of::(), + 48usize, + concat!("Size of: ", stringify!(OrtCUDAProviderOptions)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_xmm0 as *const _ as usize - }, - 168usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_xmm0) - ) + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(OrtCUDAProviderOptions)) ); + fn test_field_device_id() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).device_id) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(device_id) + ) + ); + } + test_field_device_id(); + fn test_field_cudnn_conv_algo_search() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).cudnn_conv_algo_search) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(cudnn_conv_algo_search) + ) + ); + } + test_field_cudnn_conv_algo_search(); + fn test_field_gpu_mem_limit() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).gpu_mem_limit) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(gpu_mem_limit) + ) + ); + } + test_field_gpu_mem_limit(); + fn test_field_arena_extend_strategy() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).arena_extend_strategy) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(arena_extend_strategy) + ) + ); + } + test_field_arena_extend_strategy(); + fn test_field_do_copy_in_default_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).do_copy_in_default_stream) as usize - ptr as usize + }, + 20usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(do_copy_in_default_stream) + ) + ); + } + test_field_do_copy_in_default_stream(); + fn test_field_has_user_compute_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).has_user_compute_stream) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(has_user_compute_stream) + ) + ); + } + test_field_has_user_compute_stream(); + fn test_field_user_compute_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).user_compute_stream) as usize - ptr as usize + }, + 32usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(user_compute_stream) + ) + ); + } + test_field_user_compute_stream(); + fn test_field_default_memory_arena_cfg() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).default_memory_arena_cfg) as usize - ptr as usize + }, + 40usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(default_memory_arena_cfg) + ) + ); + } + test_field_default_memory_arena_cfg(); +} +#[doc = " \\brief ROCM Provider Options"] +#[doc = ""] +#[doc = " \\see OrtApi::SessionOptionsAppendExecutionProvider_ROCM"] +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtROCMProviderOptions { + #[doc = " \\brief ROCM device Id"] + #[doc = " Defaults to 0."] + pub device_id: ::std::os::raw::c_int, + #[doc = " \\brief ROCM MIOpen Convolution algorithm exaustive search option."] + #[doc = " Defaults to 0 (false)."] + pub miopen_conv_exhaustive_search: ::std::os::raw::c_int, + #[doc = " \\brief ROCM memory limit (To use all possible memory pass in maximum size_t)"] + #[doc = " Defaults to SIZE_MAX."] + #[doc = " \\note If a ::OrtArenaCfg has been applied, it will override this field"] + pub gpu_mem_limit: usize, + #[doc = " \\brief Strategy used to grow the memory arena"] + #[doc = " 0 = kNextPowerOfTwo
"] + #[doc = " 1 = kSameAsRequested
"] + #[doc = " Defaults to 0."] + #[doc = " \\note If a ::OrtArenaCfg has been applied, it will override this field"] + pub arena_extend_strategy: ::std::os::raw::c_int, + #[doc = " \\brief Flag indicating if copying needs to take place on the same stream as the compute stream in the ROCM EP"] + #[doc = " 0 = Use separate streams for copying and compute."] + #[doc = " 1 = Use the same stream for copying and compute."] + #[doc = " Defaults to 1."] + #[doc = " WARNING: Setting this to 0 may result in data races for some models."] + #[doc = " Please see issue #4829 for more details."] + pub do_copy_in_default_stream: ::std::os::raw::c_int, + #[doc = " \\brief Flag indicating if there is a user provided compute stream"] + #[doc = " Defaults to 0."] + pub has_user_compute_stream: ::std::os::raw::c_int, + #[doc = " \\brief User provided compute stream."] + #[doc = " If provided, please set `has_user_compute_stream` to 1."] + pub user_compute_stream: *mut ::std::os::raw::c_void, + #[doc = " \\brief ROCM memory arena configuration parameters"] + pub default_memory_arena_cfg: *mut OrtArenaCfg, +} +#[test] +fn bindgen_test_layout_OrtROCMProviderOptions() { assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_xmm1 as *const _ as usize - }, - 184usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_xmm1) - ) + ::std::mem::size_of::(), + 48usize, + concat!("Size of: ", stringify!(OrtROCMProviderOptions)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_xmm2 as *const _ as usize - }, - 200usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_xmm2) - ) + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(OrtROCMProviderOptions)) ); + fn test_field_device_id() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).device_id) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(device_id) + ) + ); + } + test_field_device_id(); + fn test_field_miopen_conv_exhaustive_search() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).miopen_conv_exhaustive_search) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(miopen_conv_exhaustive_search) + ) + ); + } + test_field_miopen_conv_exhaustive_search(); + fn test_field_gpu_mem_limit() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).gpu_mem_limit) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(gpu_mem_limit) + ) + ); + } + test_field_gpu_mem_limit(); + fn test_field_arena_extend_strategy() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).arena_extend_strategy) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(arena_extend_strategy) + ) + ); + } + test_field_arena_extend_strategy(); + fn test_field_do_copy_in_default_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).do_copy_in_default_stream) as usize - ptr as usize + }, + 20usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(do_copy_in_default_stream) + ) + ); + } + test_field_do_copy_in_default_stream(); + fn test_field_has_user_compute_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).has_user_compute_stream) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(has_user_compute_stream) + ) + ); + } + test_field_has_user_compute_stream(); + fn test_field_user_compute_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).user_compute_stream) as usize - ptr as usize + }, + 32usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(user_compute_stream) + ) + ); + } + test_field_user_compute_stream(); + fn test_field_default_memory_arena_cfg() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).default_memory_arena_cfg) as usize - ptr as usize + }, + 40usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(default_memory_arena_cfg) + ) + ); + } + test_field_default_memory_arena_cfg(); +} +#[doc = " \\brief TensorRT Provider Options"] +#[doc = ""] +#[doc = " \\see OrtApi::SessionOptionsAppendExecutionProvider_TensorRT"] +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtTensorRTProviderOptions { + #[doc = "< CUDA device id (0 = default device)"] + pub device_id: ::std::os::raw::c_int, + pub has_user_compute_stream: ::std::os::raw::c_int, + pub user_compute_stream: *mut ::std::os::raw::c_void, + pub trt_max_partition_iterations: ::std::os::raw::c_int, + pub trt_min_subgraph_size: ::std::os::raw::c_int, + pub trt_max_workspace_size: usize, + pub trt_fp16_enable: ::std::os::raw::c_int, + pub trt_int8_enable: ::std::os::raw::c_int, + pub trt_int8_calibration_table_name: *const ::std::os::raw::c_char, + pub trt_int8_use_native_calibration_table: ::std::os::raw::c_int, + pub trt_dla_enable: ::std::os::raw::c_int, + pub trt_dla_core: ::std::os::raw::c_int, + pub trt_dump_subgraphs: ::std::os::raw::c_int, + pub trt_engine_cache_enable: ::std::os::raw::c_int, + pub trt_engine_cache_path: *const ::std::os::raw::c_char, + pub trt_engine_decryption_enable: ::std::os::raw::c_int, + pub trt_engine_decryption_lib_path: *const ::std::os::raw::c_char, + pub trt_force_sequential_engine_build: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_OrtTensorRTProviderOptions() { assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_xmm3 as *const _ as usize - }, - 216usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_xmm3) - ) + ::std::mem::size_of::(), + 104usize, + concat!("Size of: ", stringify!(OrtTensorRTProviderOptions)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_xmm4 as *const _ as usize - }, - 232usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_xmm4) - ) + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(OrtTensorRTProviderOptions)) ); + fn test_field_device_id() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).device_id) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(device_id) + ) + ); + } + test_field_device_id(); + fn test_field_has_user_compute_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).has_user_compute_stream) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(has_user_compute_stream) + ) + ); + } + test_field_has_user_compute_stream(); + fn test_field_user_compute_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).user_compute_stream) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(user_compute_stream) + ) + ); + } + test_field_user_compute_stream(); + fn test_field_trt_max_partition_iterations() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_max_partition_iterations) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_max_partition_iterations) + ) + ); + } + test_field_trt_max_partition_iterations(); + fn test_field_trt_min_subgraph_size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_min_subgraph_size) as usize - ptr as usize + }, + 20usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_min_subgraph_size) + ) + ); + } + test_field_trt_min_subgraph_size(); + fn test_field_trt_max_workspace_size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_max_workspace_size) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_max_workspace_size) + ) + ); + } + test_field_trt_max_workspace_size(); + fn test_field_trt_fp16_enable() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_fp16_enable) as usize - ptr as usize + }, + 32usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_fp16_enable) + ) + ); + } + test_field_trt_fp16_enable(); + fn test_field_trt_int8_enable() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_int8_enable) as usize - ptr as usize + }, + 36usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_int8_enable) + ) + ); + } + test_field_trt_int8_enable(); + fn test_field_trt_int8_calibration_table_name() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_int8_calibration_table_name) as usize - ptr as usize + }, + 40usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_int8_calibration_table_name) + ) + ); + } + test_field_trt_int8_calibration_table_name(); + fn test_field_trt_int8_use_native_calibration_table() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_int8_use_native_calibration_table) as usize + - ptr as usize + }, + 48usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_int8_use_native_calibration_table) + ) + ); + } + test_field_trt_int8_use_native_calibration_table(); + fn test_field_trt_dla_enable() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_dla_enable) as usize - ptr as usize + }, + 52usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_dla_enable) + ) + ); + } + test_field_trt_dla_enable(); + fn test_field_trt_dla_core() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_dla_core) as usize - ptr as usize + }, + 56usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_dla_core) + ) + ); + } + test_field_trt_dla_core(); + fn test_field_trt_dump_subgraphs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_dump_subgraphs) as usize - ptr as usize + }, + 60usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_dump_subgraphs) + ) + ); + } + test_field_trt_dump_subgraphs(); + fn test_field_trt_engine_cache_enable() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_engine_cache_enable) as usize - ptr as usize + }, + 64usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_engine_cache_enable) + ) + ); + } + test_field_trt_engine_cache_enable(); + fn test_field_trt_engine_cache_path() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_engine_cache_path) as usize - ptr as usize + }, + 72usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_engine_cache_path) + ) + ); + } + test_field_trt_engine_cache_path(); + fn test_field_trt_engine_decryption_enable() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_engine_decryption_enable) as usize - ptr as usize + }, + 80usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_engine_decryption_enable) + ) + ); + } + test_field_trt_engine_decryption_enable(); + fn test_field_trt_engine_decryption_lib_path() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_engine_decryption_lib_path) as usize - ptr as usize + }, + 88usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_engine_decryption_lib_path) + ) + ); + } + test_field_trt_engine_decryption_lib_path(); + fn test_field_trt_force_sequential_engine_build() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_force_sequential_engine_build) as usize + - ptr as usize + }, + 96usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_force_sequential_engine_build) + ) + ); + } + test_field_trt_force_sequential_engine_build(); +} +#[doc = " \\brief MIGraphX Provider Options"] +#[doc = ""] +#[doc = " \\see OrtApi::SessionOptionsAppendExecutionProvider_MIGraphX"] +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtMIGraphXProviderOptions { + pub device_id: ::std::os::raw::c_int, + pub migraphx_fp16_enable: ::std::os::raw::c_int, + pub migraphx_int8_enable: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_OrtMIGraphXProviderOptions() { assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_xmm5 as *const _ as usize - }, - 248usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_xmm5) - ) + ::std::mem::size_of::(), + 12usize, + concat!("Size of: ", stringify!(OrtMIGraphXProviderOptions)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_xmm6 as *const _ as usize - }, - 264usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_xmm6) - ) - ); + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(OrtMIGraphXProviderOptions)) + ); + fn test_field_device_id() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).device_id) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtMIGraphXProviderOptions), + "::", + stringify!(device_id) + ) + ); + } + test_field_device_id(); + fn test_field_migraphx_fp16_enable() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).migraphx_fp16_enable) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(OrtMIGraphXProviderOptions), + "::", + stringify!(migraphx_fp16_enable) + ) + ); + } + test_field_migraphx_fp16_enable(); + fn test_field_migraphx_int8_enable() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).migraphx_int8_enable) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtMIGraphXProviderOptions), + "::", + stringify!(migraphx_int8_enable) + ) + ); + } + test_field_migraphx_int8_enable(); +} +#[doc = " \\brief OpenVINO Provider Options"] +#[doc = ""] +#[doc = " \\see OrtApi::SessionOptionsAppendExecutionProvider_OpenVINO"] +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtOpenVINOProviderOptions { + #[doc = " \\brief Device type string"] + #[doc = ""] + #[doc = " Valid settings are one of: \"CPU_FP32\", \"GPU_FP32\", \"GPU_FP16\", \"MYRIAD_FP16\", \"VAD-M_FP16\" or \"VAD-F_FP32\""] + pub device_type: *const ::std::os::raw::c_char, + #[doc = "< 0 = disabled, nonzero = enabled"] + pub enable_vpu_fast_compile: ::std::os::raw::c_uchar, + pub device_id: *const ::std::os::raw::c_char, + #[doc = "< 0 = Use default number of threads"] + pub num_of_threads: usize, + #[doc = "< 0 = disabled, nonzero = enabled"] + pub use_compiled_network: ::std::os::raw::c_uchar, + pub blob_dump_path: *const ::std::os::raw::c_char, + pub context: *mut ::std::os::raw::c_void, +} +#[test] +fn bindgen_test_layout_OrtOpenVINOProviderOptions() { assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_xmm7 as *const _ as usize - }, - 280usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_xmm7) - ) + ::std::mem::size_of::(), + 56usize, + concat!("Size of: ", stringify!(OrtOpenVINOProviderOptions)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_xmm8 as *const _ as usize - }, - 296usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_xmm8) - ) + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(OrtOpenVINOProviderOptions)) ); + fn test_field_device_type() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).device_type) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtOpenVINOProviderOptions), + "::", + stringify!(device_type) + ) + ); + } + test_field_device_type(); + fn test_field_enable_vpu_fast_compile() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).enable_vpu_fast_compile) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtOpenVINOProviderOptions), + "::", + stringify!(enable_vpu_fast_compile) + ) + ); + } + test_field_enable_vpu_fast_compile(); + fn test_field_device_id() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).device_id) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(OrtOpenVINOProviderOptions), + "::", + stringify!(device_id) + ) + ); + } + test_field_device_id(); + fn test_field_num_of_threads() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).num_of_threads) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(OrtOpenVINOProviderOptions), + "::", + stringify!(num_of_threads) + ) + ); + } + test_field_num_of_threads(); + fn test_field_use_compiled_network() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).use_compiled_network) as usize - ptr as usize + }, + 32usize, + concat!( + "Offset of field: ", + stringify!(OrtOpenVINOProviderOptions), + "::", + stringify!(use_compiled_network) + ) + ); + } + test_field_use_compiled_network(); + fn test_field_blob_dump_path() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).blob_dump_path) as usize - ptr as usize + }, + 40usize, + concat!( + "Offset of field: ", + stringify!(OrtOpenVINOProviderOptions), + "::", + stringify!(blob_dump_path) + ) + ); + } + test_field_blob_dump_path(); + fn test_field_context() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).context) as usize - ptr as usize + }, + 48usize, + concat!( + "Offset of field: ", + stringify!(OrtOpenVINOProviderOptions), + "::", + stringify!(context) + ) + ); + } + test_field_context(); +} +#[doc = " \\brief The helper interface to get the right version of OrtApi"] +#[doc = ""] +#[doc = " Get a pointer to this structure through ::OrtGetApiBase"] +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtApiBase { + #[doc = " \\brief Get a pointer to the requested version of the ::OrtApi"] + #[doc = ""] + #[doc = " \\param[in] version Must be ::ORT_API_VERSION"] + #[doc = " \\return The ::OrtApi for the version requested, nullptr will be returned if this version is unsupported, for example when using a runtime"] + #[doc = " older than the version created with this header file."] + pub GetApi: ::std::option::Option *const OrtApi>, + #[doc = "< Returns a null terminated string of the version of the Onnxruntime library (eg: \"1.8.1\")"] + pub GetVersionString: + ::std::option::Option *const ::std::os::raw::c_char>, +} +#[test] +fn bindgen_test_layout_OrtApiBase() { assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_xmm9 as *const _ as usize - }, - 312usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_xmm9) - ) + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(OrtApiBase)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_xmm10 as *const _ as usize - }, - 328usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_xmm10) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_xmm11 as *const _ as usize - }, - 344usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_xmm11) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_xmm12 as *const _ as usize - }, - 360usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_xmm12) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_xmm13 as *const _ as usize - }, - 376usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_xmm13) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_xmm14 as *const _ as usize - }, - 392usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_xmm14) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_xmm15 as *const _ as usize - }, - 408usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_xmm15) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_rsrv4 as *const _ as usize - }, - 424usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_rsrv4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_reserved1 as *const _ - as usize - }, - 520usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_reserved1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__avx_reserved1 as *const _ - as usize - }, - 524usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__avx_reserved1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ymmh0 as *const _ as usize - }, - 588usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ymmh0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ymmh1 as *const _ as usize - }, - 604usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ymmh1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ymmh2 as *const _ as usize - }, - 620usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ymmh2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ymmh3 as *const _ as usize - }, - 636usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ymmh3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ymmh4 as *const _ as usize - }, - 652usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ymmh4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ymmh5 as *const _ as usize - }, - 668usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ymmh5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ymmh6 as *const _ as usize - }, - 684usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ymmh6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ymmh7 as *const _ as usize - }, - 700usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ymmh7) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ymmh8 as *const _ as usize - }, - 716usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ymmh8) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ymmh9 as *const _ as usize - }, - 732usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ymmh9) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ymmh10 as *const _ as usize - }, - 748usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ymmh10) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ymmh11 as *const _ as usize - }, - 764usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ymmh11) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ymmh12 as *const _ as usize - }, - 780usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ymmh12) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ymmh13 as *const _ as usize - }, - 796usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ymmh13) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ymmh14 as *const _ as usize - }, - 812usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ymmh14) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ymmh15 as *const _ as usize - }, - 828usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ymmh15) - ) + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(OrtApiBase)) ); + fn test_field_GetApi() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetApi) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtApiBase), + "::", + stringify!(GetApi) + ) + ); + } + test_field_GetApi(); + fn test_field_GetVersionString() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetVersionString) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtApiBase), + "::", + stringify!(GetVersionString) + ) + ); + } + test_field_GetVersionString(); +} +extern "C" { + #[doc = " \\brief The Onnxruntime library's entry point to access the C API"] + #[doc = ""] + #[doc = " Call this to get the a pointer to an ::OrtApiBase"] + pub fn OrtGetApiBase() -> *const OrtApiBase; } +#[doc = " \\brief Thread work loop function"] +#[doc = ""] +#[doc = " Onnxruntime will provide the working loop on custom thread creation"] +#[doc = " Argument is an onnxruntime built-in type which will be provided when thread pool calls OrtCustomCreateThreadFn"] +pub type OrtThreadWorkerFn = + ::std::option::Option; #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct __darwin_x86_avx512_state64 { - pub __fpu_reserved: [::std::os::raw::c_int; 2usize], - pub __fpu_fcw: __darwin_fp_control, - pub __fpu_fsw: __darwin_fp_status, - pub __fpu_ftw: __uint8_t, - pub __fpu_rsrv1: __uint8_t, - pub __fpu_fop: __uint16_t, - pub __fpu_ip: __uint32_t, - pub __fpu_cs: __uint16_t, - pub __fpu_rsrv2: __uint16_t, - pub __fpu_dp: __uint32_t, - pub __fpu_ds: __uint16_t, - pub __fpu_rsrv3: __uint16_t, - pub __fpu_mxcsr: __uint32_t, - pub __fpu_mxcsrmask: __uint32_t, - pub __fpu_stmm0: __darwin_mmst_reg, - pub __fpu_stmm1: __darwin_mmst_reg, - pub __fpu_stmm2: __darwin_mmst_reg, - pub __fpu_stmm3: __darwin_mmst_reg, - pub __fpu_stmm4: __darwin_mmst_reg, - pub __fpu_stmm5: __darwin_mmst_reg, - pub __fpu_stmm6: __darwin_mmst_reg, - pub __fpu_stmm7: __darwin_mmst_reg, - pub __fpu_xmm0: __darwin_xmm_reg, - pub __fpu_xmm1: __darwin_xmm_reg, - pub __fpu_xmm2: __darwin_xmm_reg, - pub __fpu_xmm3: __darwin_xmm_reg, - pub __fpu_xmm4: __darwin_xmm_reg, - pub __fpu_xmm5: __darwin_xmm_reg, - pub __fpu_xmm6: __darwin_xmm_reg, - pub __fpu_xmm7: __darwin_xmm_reg, - pub __fpu_xmm8: __darwin_xmm_reg, - pub __fpu_xmm9: __darwin_xmm_reg, - pub __fpu_xmm10: __darwin_xmm_reg, - pub __fpu_xmm11: __darwin_xmm_reg, - pub __fpu_xmm12: __darwin_xmm_reg, - pub __fpu_xmm13: __darwin_xmm_reg, - pub __fpu_xmm14: __darwin_xmm_reg, - pub __fpu_xmm15: __darwin_xmm_reg, - pub __fpu_rsrv4: [::std::os::raw::c_char; 96usize], - pub __fpu_reserved1: ::std::os::raw::c_int, - pub __avx_reserved1: [::std::os::raw::c_char; 64usize], - pub __fpu_ymmh0: __darwin_xmm_reg, - pub __fpu_ymmh1: __darwin_xmm_reg, - pub __fpu_ymmh2: __darwin_xmm_reg, - pub __fpu_ymmh3: __darwin_xmm_reg, - pub __fpu_ymmh4: __darwin_xmm_reg, - pub __fpu_ymmh5: __darwin_xmm_reg, - pub __fpu_ymmh6: __darwin_xmm_reg, - pub __fpu_ymmh7: __darwin_xmm_reg, - pub __fpu_ymmh8: __darwin_xmm_reg, - pub __fpu_ymmh9: __darwin_xmm_reg, - pub __fpu_ymmh10: __darwin_xmm_reg, - pub __fpu_ymmh11: __darwin_xmm_reg, - pub __fpu_ymmh12: __darwin_xmm_reg, - pub __fpu_ymmh13: __darwin_xmm_reg, - pub __fpu_ymmh14: __darwin_xmm_reg, - pub __fpu_ymmh15: __darwin_xmm_reg, - pub __fpu_k0: __darwin_opmask_reg, - pub __fpu_k1: __darwin_opmask_reg, - pub __fpu_k2: __darwin_opmask_reg, - pub __fpu_k3: __darwin_opmask_reg, - pub __fpu_k4: __darwin_opmask_reg, - pub __fpu_k5: __darwin_opmask_reg, - pub __fpu_k6: __darwin_opmask_reg, - pub __fpu_k7: __darwin_opmask_reg, - pub __fpu_zmmh0: __darwin_ymm_reg, - pub __fpu_zmmh1: __darwin_ymm_reg, - pub __fpu_zmmh2: __darwin_ymm_reg, - pub __fpu_zmmh3: __darwin_ymm_reg, - pub __fpu_zmmh4: __darwin_ymm_reg, - pub __fpu_zmmh5: __darwin_ymm_reg, - pub __fpu_zmmh6: __darwin_ymm_reg, - pub __fpu_zmmh7: __darwin_ymm_reg, - pub __fpu_zmmh8: __darwin_ymm_reg, - pub __fpu_zmmh9: __darwin_ymm_reg, - pub __fpu_zmmh10: __darwin_ymm_reg, - pub __fpu_zmmh11: __darwin_ymm_reg, - pub __fpu_zmmh12: __darwin_ymm_reg, - pub __fpu_zmmh13: __darwin_ymm_reg, - pub __fpu_zmmh14: __darwin_ymm_reg, - pub __fpu_zmmh15: __darwin_ymm_reg, - pub __fpu_zmm16: __darwin_zmm_reg, - pub __fpu_zmm17: __darwin_zmm_reg, - pub __fpu_zmm18: __darwin_zmm_reg, - pub __fpu_zmm19: __darwin_zmm_reg, - pub __fpu_zmm20: __darwin_zmm_reg, - pub __fpu_zmm21: __darwin_zmm_reg, - pub __fpu_zmm22: __darwin_zmm_reg, - pub __fpu_zmm23: __darwin_zmm_reg, - pub __fpu_zmm24: __darwin_zmm_reg, - pub __fpu_zmm25: __darwin_zmm_reg, - pub __fpu_zmm26: __darwin_zmm_reg, - pub __fpu_zmm27: __darwin_zmm_reg, - pub __fpu_zmm28: __darwin_zmm_reg, - pub __fpu_zmm29: __darwin_zmm_reg, - pub __fpu_zmm30: __darwin_zmm_reg, - pub __fpu_zmm31: __darwin_zmm_reg, +pub struct OrtCustomHandleType { + pub __place_holder: ::std::os::raw::c_char, } #[test] -fn bindgen_test_layout___darwin_x86_avx512_state64() { - assert_eq!( - ::std::mem::size_of::<__darwin_x86_avx512_state64>(), - 2444usize, - concat!("Size of: ", stringify!(__darwin_x86_avx512_state64)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_x86_avx512_state64>(), - 4usize, - concat!("Alignment of ", stringify!(__darwin_x86_avx512_state64)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_reserved as *const _ - as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_reserved) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_fcw as *const _ as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_fcw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_fsw as *const _ as usize - }, - 10usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_fsw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ftw as *const _ as usize - }, - 12usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ftw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_rsrv1 as *const _ as usize - }, - 13usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_rsrv1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_fop as *const _ as usize - }, - 14usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_fop) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ip as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ip) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_cs as *const _ as usize - }, - 20usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_cs) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_rsrv2 as *const _ as usize - }, - 22usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_rsrv2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_dp as *const _ as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_dp) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ds as *const _ as usize - }, - 28usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ds) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_rsrv3 as *const _ as usize - }, - 30usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_rsrv3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_mxcsr as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_mxcsr) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_mxcsrmask as *const _ - as usize - }, - 36usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_mxcsrmask) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_stmm0 as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_stmm0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_stmm1 as *const _ as usize - }, - 56usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_stmm1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_stmm2 as *const _ as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_stmm2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_stmm3 as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_stmm3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_stmm4 as *const _ as usize - }, - 104usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_stmm4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_stmm5 as *const _ as usize - }, - 120usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_stmm5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_stmm6 as *const _ as usize - }, - 136usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_stmm6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_stmm7 as *const _ as usize - }, - 152usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_stmm7) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_xmm0 as *const _ as usize - }, - 168usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_xmm0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_xmm1 as *const _ as usize - }, - 184usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_xmm1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_xmm2 as *const _ as usize - }, - 200usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_xmm2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_xmm3 as *const _ as usize - }, - 216usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_xmm3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_xmm4 as *const _ as usize - }, - 232usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_xmm4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_xmm5 as *const _ as usize - }, - 248usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_xmm5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_xmm6 as *const _ as usize - }, - 264usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_xmm6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_xmm7 as *const _ as usize - }, - 280usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_xmm7) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_xmm8 as *const _ as usize - }, - 296usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_xmm8) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_xmm9 as *const _ as usize - }, - 312usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_xmm9) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_xmm10 as *const _ as usize - }, - 328usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_xmm10) - ) - ); +fn bindgen_test_layout_OrtCustomHandleType() { assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_xmm11 as *const _ as usize - }, - 344usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_xmm11) - ) + ::std::mem::size_of::(), + 1usize, + concat!("Size of: ", stringify!(OrtCustomHandleType)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_xmm12 as *const _ as usize - }, - 360usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_xmm12) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_xmm13 as *const _ as usize - }, - 376usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_xmm13) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_xmm14 as *const _ as usize - }, - 392usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_xmm14) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_xmm15 as *const _ as usize - }, - 408usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_xmm15) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_rsrv4 as *const _ as usize - }, - 424usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_rsrv4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_reserved1 as *const _ - as usize - }, - 520usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_reserved1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__avx_reserved1 as *const _ - as usize - }, - 524usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__avx_reserved1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ymmh0 as *const _ as usize - }, - 588usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ymmh0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ymmh1 as *const _ as usize - }, - 604usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ymmh1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ymmh2 as *const _ as usize - }, - 620usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ymmh2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ymmh3 as *const _ as usize - }, - 636usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ymmh3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ymmh4 as *const _ as usize - }, - 652usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ymmh4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ymmh5 as *const _ as usize - }, - 668usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ymmh5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ymmh6 as *const _ as usize - }, - 684usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ymmh6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ymmh7 as *const _ as usize - }, - 700usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ymmh7) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ymmh8 as *const _ as usize - }, - 716usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ymmh8) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ymmh9 as *const _ as usize - }, - 732usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ymmh9) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ymmh10 as *const _ - as usize - }, - 748usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ymmh10) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ymmh11 as *const _ - as usize - }, - 764usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ymmh11) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ymmh12 as *const _ - as usize - }, - 780usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ymmh12) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ymmh13 as *const _ - as usize - }, - 796usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ymmh13) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ymmh14 as *const _ - as usize - }, - 812usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ymmh14) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ymmh15 as *const _ - as usize - }, - 828usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ymmh15) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_k0 as *const _ as usize - }, - 844usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_k0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_k1 as *const _ as usize - }, - 852usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_k1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_k2 as *const _ as usize - }, - 860usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_k2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_k3 as *const _ as usize - }, - 868usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_k3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_k4 as *const _ as usize - }, - 876usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_k4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_k5 as *const _ as usize - }, - 884usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_k5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_k6 as *const _ as usize - }, - 892usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_k6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_k7 as *const _ as usize - }, - 900usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_k7) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmmh0 as *const _ as usize - }, - 908usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmmh0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmmh1 as *const _ as usize - }, - 940usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmmh1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmmh2 as *const _ as usize - }, - 972usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmmh2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmmh3 as *const _ as usize - }, - 1004usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmmh3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmmh4 as *const _ as usize - }, - 1036usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmmh4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmmh5 as *const _ as usize - }, - 1068usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmmh5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmmh6 as *const _ as usize - }, - 1100usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmmh6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmmh7 as *const _ as usize - }, - 1132usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmmh7) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmmh8 as *const _ as usize - }, - 1164usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmmh8) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmmh9 as *const _ as usize - }, - 1196usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmmh9) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmmh10 as *const _ - as usize - }, - 1228usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmmh10) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmmh11 as *const _ - as usize - }, - 1260usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmmh11) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmmh12 as *const _ - as usize - }, - 1292usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmmh12) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmmh13 as *const _ - as usize - }, - 1324usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmmh13) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmmh14 as *const _ - as usize - }, - 1356usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmmh14) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmmh15 as *const _ - as usize - }, - 1388usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmmh15) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmm16 as *const _ as usize - }, - 1420usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmm16) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmm17 as *const _ as usize - }, - 1484usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmm17) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmm18 as *const _ as usize - }, - 1548usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmm18) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmm19 as *const _ as usize - }, - 1612usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmm19) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmm20 as *const _ as usize - }, - 1676usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmm20) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmm21 as *const _ as usize - }, - 1740usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmm21) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmm22 as *const _ as usize - }, - 1804usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmm22) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmm23 as *const _ as usize - }, - 1868usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmm23) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmm24 as *const _ as usize - }, - 1932usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmm24) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmm25 as *const _ as usize - }, - 1996usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmm25) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmm26 as *const _ as usize - }, - 2060usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmm26) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmm27 as *const _ as usize - }, - 2124usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmm27) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmm28 as *const _ as usize - }, - 2188usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmm28) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmm29 as *const _ as usize - }, - 2252usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmm29) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmm30 as *const _ as usize - }, - 2316usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmm30) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmm31 as *const _ as usize - }, - 2380usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmm31) - ) - ); -} + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(OrtCustomHandleType)) + ); + fn test_field___place_holder() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__place_holder) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomHandleType), + "::", + stringify!(__place_holder) + ) + ); + } + test_field___place_holder(); +} +pub type OrtCustomThreadHandle = *const OrtCustomHandleType; +#[doc = " \\brief Ort custom thread creation function"] +#[doc = ""] +#[doc = " The function should return a thread handle to be used in onnxruntime thread pools"] +#[doc = " Onnxruntime will throw exception on return value of nullptr or 0, indicating that the function failed to create a thread"] +pub type OrtCustomCreateThreadFn = ::std::option::Option< + unsafe extern "C" fn( + ort_custom_thread_creation_options: *mut ::std::os::raw::c_void, + ort_thread_worker_fn: OrtThreadWorkerFn, + ort_worker_fn_param: *mut ::std::os::raw::c_void, + ) -> OrtCustomThreadHandle, +>; +#[doc = " \\brief Custom thread join function"] +#[doc = ""] +#[doc = " Onnxruntime thread pool destructor will call the function to join a custom thread."] +#[doc = " Argument ort_custom_thread_handle is the value returned by OrtCustomCreateThreadFn"] +pub type OrtCustomJoinThreadFn = + ::std::option::Option; +#[doc = " \\brief The C API"] +#[doc = ""] +#[doc = " All C API functions are defined inside this structure as pointers to functions."] +#[doc = " Call OrtApiBase::GetApi to get a pointer to it"] +#[doc = ""] +#[doc = " \\nosubgrouping"] #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct __darwin_x86_exception_state64 { - pub __trapno: __uint16_t, - pub __cpu: __uint16_t, - pub __err: __uint32_t, - pub __faultvaddr: __uint64_t, -} -#[test] -fn bindgen_test_layout___darwin_x86_exception_state64() { - assert_eq!( - ::std::mem::size_of::<__darwin_x86_exception_state64>(), - 16usize, - concat!("Size of: ", stringify!(__darwin_x86_exception_state64)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_x86_exception_state64>(), - 8usize, - concat!("Alignment of ", stringify!(__darwin_x86_exception_state64)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_exception_state64>())).__trapno as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_exception_state64), - "::", - stringify!(__trapno) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_exception_state64>())).__cpu as *const _ as usize - }, - 2usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_exception_state64), - "::", - stringify!(__cpu) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_exception_state64>())).__err as *const _ as usize - }, - 4usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_exception_state64), - "::", - stringify!(__err) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_exception_state64>())).__faultvaddr as *const _ - as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_exception_state64), - "::", - stringify!(__faultvaddr) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_x86_debug_state64 { - pub __dr0: __uint64_t, - pub __dr1: __uint64_t, - pub __dr2: __uint64_t, - pub __dr3: __uint64_t, - pub __dr4: __uint64_t, - pub __dr5: __uint64_t, - pub __dr6: __uint64_t, - pub __dr7: __uint64_t, -} -#[test] -fn bindgen_test_layout___darwin_x86_debug_state64() { - assert_eq!( - ::std::mem::size_of::<__darwin_x86_debug_state64>(), - 64usize, - concat!("Size of: ", stringify!(__darwin_x86_debug_state64)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_x86_debug_state64>(), - 8usize, - concat!("Alignment of ", stringify!(__darwin_x86_debug_state64)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_debug_state64>())).__dr0 as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_debug_state64), - "::", - stringify!(__dr0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_debug_state64>())).__dr1 as *const _ as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_debug_state64), - "::", - stringify!(__dr1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_debug_state64>())).__dr2 as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_debug_state64), - "::", - stringify!(__dr2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_debug_state64>())).__dr3 as *const _ as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_debug_state64), - "::", - stringify!(__dr3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_debug_state64>())).__dr4 as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_debug_state64), - "::", - stringify!(__dr4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_debug_state64>())).__dr5 as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_debug_state64), - "::", - stringify!(__dr5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_debug_state64>())).__dr6 as *const _ as usize - }, - 48usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_debug_state64), - "::", - stringify!(__dr6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_debug_state64>())).__dr7 as *const _ as usize - }, - 56usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_debug_state64), - "::", - stringify!(__dr7) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_x86_cpmu_state64 { - pub __ctrs: [__uint64_t; 16usize], -} -#[test] -fn bindgen_test_layout___darwin_x86_cpmu_state64() { - assert_eq!( - ::std::mem::size_of::<__darwin_x86_cpmu_state64>(), - 128usize, - concat!("Size of: ", stringify!(__darwin_x86_cpmu_state64)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_x86_cpmu_state64>(), - 8usize, - concat!("Alignment of ", stringify!(__darwin_x86_cpmu_state64)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_cpmu_state64>())).__ctrs as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_cpmu_state64), - "::", - stringify!(__ctrs) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_mcontext32 { - pub __es: __darwin_i386_exception_state, - pub __ss: __darwin_i386_thread_state, - pub __fs: __darwin_i386_float_state, -} -#[test] -fn bindgen_test_layout___darwin_mcontext32() { - assert_eq!( - ::std::mem::size_of::<__darwin_mcontext32>(), - 600usize, - concat!("Size of: ", stringify!(__darwin_mcontext32)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_mcontext32>(), - 4usize, - concat!("Alignment of ", stringify!(__darwin_mcontext32)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext32>())).__es as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext32), - "::", - stringify!(__es) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext32>())).__ss as *const _ as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext32), - "::", - stringify!(__ss) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext32>())).__fs as *const _ as usize }, - 76usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext32), - "::", - stringify!(__fs) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_mcontext_avx32 { - pub __es: __darwin_i386_exception_state, - pub __ss: __darwin_i386_thread_state, - pub __fs: __darwin_i386_avx_state, -} -#[test] -fn bindgen_test_layout___darwin_mcontext_avx32() { - assert_eq!( - ::std::mem::size_of::<__darwin_mcontext_avx32>(), - 792usize, - concat!("Size of: ", stringify!(__darwin_mcontext_avx32)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_mcontext_avx32>(), - 4usize, - concat!("Alignment of ", stringify!(__darwin_mcontext_avx32)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext_avx32>())).__es as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx32), - "::", - stringify!(__es) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext_avx32>())).__ss as *const _ as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx32), - "::", - stringify!(__ss) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext_avx32>())).__fs as *const _ as usize }, - 76usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx32), - "::", - stringify!(__fs) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_mcontext_avx512_32 { - pub __es: __darwin_i386_exception_state, - pub __ss: __darwin_i386_thread_state, - pub __fs: __darwin_i386_avx512_state, -} -#[test] -fn bindgen_test_layout___darwin_mcontext_avx512_32() { - assert_eq!( - ::std::mem::size_of::<__darwin_mcontext_avx512_32>(), - 1112usize, - concat!("Size of: ", stringify!(__darwin_mcontext_avx512_32)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_mcontext_avx512_32>(), - 4usize, - concat!("Alignment of ", stringify!(__darwin_mcontext_avx512_32)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_mcontext_avx512_32>())).__es as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx512_32), - "::", - stringify!(__es) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_mcontext_avx512_32>())).__ss as *const _ as usize - }, - 12usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx512_32), - "::", - stringify!(__ss) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_mcontext_avx512_32>())).__fs as *const _ as usize - }, - 76usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx512_32), - "::", - stringify!(__fs) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_mcontext64 { - pub __es: __darwin_x86_exception_state64, - pub __ss: __darwin_x86_thread_state64, - pub __fs: __darwin_x86_float_state64, -} -#[test] -fn bindgen_test_layout___darwin_mcontext64() { - assert_eq!( - ::std::mem::size_of::<__darwin_mcontext64>(), - 712usize, - concat!("Size of: ", stringify!(__darwin_mcontext64)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_mcontext64>(), - 8usize, - concat!("Alignment of ", stringify!(__darwin_mcontext64)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext64>())).__es as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext64), - "::", - stringify!(__es) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext64>())).__ss as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext64), - "::", - stringify!(__ss) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext64>())).__fs as *const _ as usize }, - 184usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext64), - "::", - stringify!(__fs) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_mcontext64_full { - pub __es: __darwin_x86_exception_state64, - pub __ss: __darwin_x86_thread_full_state64, - pub __fs: __darwin_x86_float_state64, -} -#[test] -fn bindgen_test_layout___darwin_mcontext64_full() { - assert_eq!( - ::std::mem::size_of::<__darwin_mcontext64_full>(), - 744usize, - concat!("Size of: ", stringify!(__darwin_mcontext64_full)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_mcontext64_full>(), - 8usize, - concat!("Alignment of ", stringify!(__darwin_mcontext64_full)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext64_full>())).__es as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext64_full), - "::", - stringify!(__es) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext64_full>())).__ss as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext64_full), - "::", - stringify!(__ss) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext64_full>())).__fs as *const _ as usize }, - 216usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext64_full), - "::", - stringify!(__fs) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_mcontext_avx64 { - pub __es: __darwin_x86_exception_state64, - pub __ss: __darwin_x86_thread_state64, - pub __fs: __darwin_x86_avx_state64, -} -#[test] -fn bindgen_test_layout___darwin_mcontext_avx64() { - assert_eq!( - ::std::mem::size_of::<__darwin_mcontext_avx64>(), - 1032usize, - concat!("Size of: ", stringify!(__darwin_mcontext_avx64)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_mcontext_avx64>(), - 8usize, - concat!("Alignment of ", stringify!(__darwin_mcontext_avx64)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext_avx64>())).__es as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx64), - "::", - stringify!(__es) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext_avx64>())).__ss as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx64), - "::", - stringify!(__ss) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext_avx64>())).__fs as *const _ as usize }, - 184usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx64), - "::", - stringify!(__fs) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_mcontext_avx64_full { - pub __es: __darwin_x86_exception_state64, - pub __ss: __darwin_x86_thread_full_state64, - pub __fs: __darwin_x86_avx_state64, -} -#[test] -fn bindgen_test_layout___darwin_mcontext_avx64_full() { - assert_eq!( - ::std::mem::size_of::<__darwin_mcontext_avx64_full>(), - 1064usize, - concat!("Size of: ", stringify!(__darwin_mcontext_avx64_full)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_mcontext_avx64_full>(), - 8usize, - concat!("Alignment of ", stringify!(__darwin_mcontext_avx64_full)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_mcontext_avx64_full>())).__es as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx64_full), - "::", - stringify!(__es) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_mcontext_avx64_full>())).__ss as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx64_full), - "::", - stringify!(__ss) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_mcontext_avx64_full>())).__fs as *const _ as usize - }, - 216usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx64_full), - "::", - stringify!(__fs) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_mcontext_avx512_64 { - pub __es: __darwin_x86_exception_state64, - pub __ss: __darwin_x86_thread_state64, - pub __fs: __darwin_x86_avx512_state64, -} -#[test] -fn bindgen_test_layout___darwin_mcontext_avx512_64() { - assert_eq!( - ::std::mem::size_of::<__darwin_mcontext_avx512_64>(), - 2632usize, - concat!("Size of: ", stringify!(__darwin_mcontext_avx512_64)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_mcontext_avx512_64>(), - 8usize, - concat!("Alignment of ", stringify!(__darwin_mcontext_avx512_64)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_mcontext_avx512_64>())).__es as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx512_64), - "::", - stringify!(__es) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_mcontext_avx512_64>())).__ss as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx512_64), - "::", - stringify!(__ss) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_mcontext_avx512_64>())).__fs as *const _ as usize - }, - 184usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx512_64), - "::", - stringify!(__fs) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_mcontext_avx512_64_full { - pub __es: __darwin_x86_exception_state64, - pub __ss: __darwin_x86_thread_full_state64, - pub __fs: __darwin_x86_avx512_state64, -} -#[test] -fn bindgen_test_layout___darwin_mcontext_avx512_64_full() { - assert_eq!( - ::std::mem::size_of::<__darwin_mcontext_avx512_64_full>(), - 2664usize, - concat!("Size of: ", stringify!(__darwin_mcontext_avx512_64_full)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_mcontext_avx512_64_full>(), - 8usize, - concat!( - "Alignment of ", - stringify!(__darwin_mcontext_avx512_64_full) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_mcontext_avx512_64_full>())).__es as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx512_64_full), - "::", - stringify!(__es) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_mcontext_avx512_64_full>())).__ss as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx512_64_full), - "::", - stringify!(__ss) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_mcontext_avx512_64_full>())).__fs as *const _ as usize - }, - 216usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx512_64_full), - "::", - stringify!(__fs) - ) - ); -} -pub type mcontext_t = *mut __darwin_mcontext64; -pub type pthread_attr_t = __darwin_pthread_attr_t; -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_sigaltstack { - pub ss_sp: *mut ::std::os::raw::c_void, - pub ss_size: __darwin_size_t, - pub ss_flags: ::std::os::raw::c_int, -} -#[test] -fn bindgen_test_layout___darwin_sigaltstack() { - assert_eq!( - ::std::mem::size_of::<__darwin_sigaltstack>(), - 24usize, - concat!("Size of: ", stringify!(__darwin_sigaltstack)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_sigaltstack>(), - 8usize, - concat!("Alignment of ", stringify!(__darwin_sigaltstack)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_sigaltstack>())).ss_sp as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_sigaltstack), - "::", - stringify!(ss_sp) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_sigaltstack>())).ss_size as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__darwin_sigaltstack), - "::", - stringify!(ss_size) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_sigaltstack>())).ss_flags as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_sigaltstack), - "::", - stringify!(ss_flags) - ) - ); -} -pub type stack_t = __darwin_sigaltstack; -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_ucontext { - pub uc_onstack: ::std::os::raw::c_int, - pub uc_sigmask: __darwin_sigset_t, - pub uc_stack: __darwin_sigaltstack, - pub uc_link: *mut __darwin_ucontext, - pub uc_mcsize: __darwin_size_t, - pub uc_mcontext: *mut __darwin_mcontext64, -} -#[test] -fn bindgen_test_layout___darwin_ucontext() { - assert_eq!( - ::std::mem::size_of::<__darwin_ucontext>(), - 56usize, - concat!("Size of: ", stringify!(__darwin_ucontext)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_ucontext>(), - 8usize, - concat!("Alignment of ", stringify!(__darwin_ucontext)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_ucontext>())).uc_onstack as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_ucontext), - "::", - stringify!(uc_onstack) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_ucontext>())).uc_sigmask as *const _ as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(__darwin_ucontext), - "::", - stringify!(uc_sigmask) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_ucontext>())).uc_stack as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__darwin_ucontext), - "::", - stringify!(uc_stack) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_ucontext>())).uc_link as *const _ as usize }, - 32usize, - concat!( - "Offset of field: ", - stringify!(__darwin_ucontext), - "::", - stringify!(uc_link) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_ucontext>())).uc_mcsize as *const _ as usize }, - 40usize, - concat!( - "Offset of field: ", - stringify!(__darwin_ucontext), - "::", - stringify!(uc_mcsize) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_ucontext>())).uc_mcontext as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(__darwin_ucontext), - "::", - stringify!(uc_mcontext) - ) - ); -} -pub type ucontext_t = __darwin_ucontext; -pub type sigset_t = __darwin_sigset_t; -pub type uid_t = __darwin_uid_t; -#[repr(C)] -#[derive(Copy, Clone)] -pub union sigval { - pub sival_int: ::std::os::raw::c_int, - pub sival_ptr: *mut ::std::os::raw::c_void, -} -#[test] -fn bindgen_test_layout_sigval() { - assert_eq!( - ::std::mem::size_of::(), - 8usize, - concat!("Size of: ", stringify!(sigval)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(sigval)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).sival_int as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(sigval), - "::", - stringify!(sival_int) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).sival_ptr as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(sigval), - "::", - stringify!(sival_ptr) - ) - ); -} -#[repr(C)] -#[derive(Copy, Clone)] -pub struct sigevent { - pub sigev_notify: ::std::os::raw::c_int, - pub sigev_signo: ::std::os::raw::c_int, - pub sigev_value: sigval, - pub sigev_notify_function: ::std::option::Option, - pub sigev_notify_attributes: *mut pthread_attr_t, -} -#[test] -fn bindgen_test_layout_sigevent() { - assert_eq!( - ::std::mem::size_of::(), - 32usize, - concat!("Size of: ", stringify!(sigevent)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(sigevent)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).sigev_notify as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(sigevent), - "::", - stringify!(sigev_notify) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).sigev_signo as *const _ as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(sigevent), - "::", - stringify!(sigev_signo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).sigev_value as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(sigevent), - "::", - stringify!(sigev_value) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).sigev_notify_function as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(sigevent), - "::", - stringify!(sigev_notify_function) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).sigev_notify_attributes as *const _ as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(sigevent), - "::", - stringify!(sigev_notify_attributes) - ) - ); -} -#[repr(C)] -#[derive(Copy, Clone)] -pub struct __siginfo { - pub si_signo: ::std::os::raw::c_int, - pub si_errno: ::std::os::raw::c_int, - pub si_code: ::std::os::raw::c_int, - pub si_pid: pid_t, - pub si_uid: uid_t, - pub si_status: ::std::os::raw::c_int, - pub si_addr: *mut ::std::os::raw::c_void, - pub si_value: sigval, - pub si_band: ::std::os::raw::c_long, - pub __pad: [::std::os::raw::c_ulong; 7usize], -} -#[test] -fn bindgen_test_layout___siginfo() { - assert_eq!( - ::std::mem::size_of::<__siginfo>(), - 104usize, - concat!("Size of: ", stringify!(__siginfo)) - ); - assert_eq!( - ::std::mem::align_of::<__siginfo>(), - 8usize, - concat!("Alignment of ", stringify!(__siginfo)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__siginfo>())).si_signo as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__siginfo), - "::", - stringify!(si_signo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__siginfo>())).si_errno as *const _ as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(__siginfo), - "::", - stringify!(si_errno) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__siginfo>())).si_code as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__siginfo), - "::", - stringify!(si_code) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__siginfo>())).si_pid as *const _ as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(__siginfo), - "::", - stringify!(si_pid) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__siginfo>())).si_uid as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__siginfo), - "::", - stringify!(si_uid) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__siginfo>())).si_status as *const _ as usize }, - 20usize, - concat!( - "Offset of field: ", - stringify!(__siginfo), - "::", - stringify!(si_status) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__siginfo>())).si_addr as *const _ as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(__siginfo), - "::", - stringify!(si_addr) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__siginfo>())).si_value as *const _ as usize }, - 32usize, - concat!( - "Offset of field: ", - stringify!(__siginfo), - "::", - stringify!(si_value) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__siginfo>())).si_band as *const _ as usize }, - 40usize, - concat!( - "Offset of field: ", - stringify!(__siginfo), - "::", - stringify!(si_band) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__siginfo>())).__pad as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(__siginfo), - "::", - stringify!(__pad) - ) - ); -} -pub type siginfo_t = __siginfo; -#[repr(C)] -#[derive(Copy, Clone)] -pub union __sigaction_u { - pub __sa_handler: ::std::option::Option, - pub __sa_sigaction: ::std::option::Option< - unsafe extern "C" fn( - arg1: ::std::os::raw::c_int, - arg2: *mut __siginfo, - arg3: *mut ::std::os::raw::c_void, - ), - >, -} -#[test] -fn bindgen_test_layout___sigaction_u() { - assert_eq!( - ::std::mem::size_of::<__sigaction_u>(), - 8usize, - concat!("Size of: ", stringify!(__sigaction_u)) - ); - assert_eq!( - ::std::mem::align_of::<__sigaction_u>(), - 8usize, - concat!("Alignment of ", stringify!(__sigaction_u)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__sigaction_u>())).__sa_handler as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__sigaction_u), - "::", - stringify!(__sa_handler) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__sigaction_u>())).__sa_sigaction as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__sigaction_u), - "::", - stringify!(__sa_sigaction) - ) - ); -} -#[repr(C)] -#[derive(Copy, Clone)] -pub struct __sigaction { - pub __sigaction_u: __sigaction_u, - pub sa_tramp: ::std::option::Option< - unsafe extern "C" fn( - arg1: *mut ::std::os::raw::c_void, - arg2: ::std::os::raw::c_int, - arg3: ::std::os::raw::c_int, - arg4: *mut siginfo_t, - arg5: *mut ::std::os::raw::c_void, - ), - >, - pub sa_mask: sigset_t, - pub sa_flags: ::std::os::raw::c_int, -} -#[test] -fn bindgen_test_layout___sigaction() { - assert_eq!( - ::std::mem::size_of::<__sigaction>(), - 24usize, - concat!("Size of: ", stringify!(__sigaction)) - ); - assert_eq!( - ::std::mem::align_of::<__sigaction>(), - 8usize, - concat!("Alignment of ", stringify!(__sigaction)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__sigaction>())).__sigaction_u as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__sigaction), - "::", - stringify!(__sigaction_u) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__sigaction>())).sa_tramp as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__sigaction), - "::", - stringify!(sa_tramp) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__sigaction>())).sa_mask as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__sigaction), - "::", - stringify!(sa_mask) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__sigaction>())).sa_flags as *const _ as usize }, - 20usize, - concat!( - "Offset of field: ", - stringify!(__sigaction), - "::", - stringify!(sa_flags) - ) - ); -} -#[repr(C)] -#[derive(Copy, Clone)] -pub struct sigaction { - pub __sigaction_u: __sigaction_u, - pub sa_mask: sigset_t, - pub sa_flags: ::std::os::raw::c_int, -} -#[test] -fn bindgen_test_layout_sigaction() { - assert_eq!( - ::std::mem::size_of::(), - 16usize, - concat!("Size of: ", stringify!(sigaction)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(sigaction)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).__sigaction_u as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(sigaction), - "::", - stringify!(__sigaction_u) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).sa_mask as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(sigaction), - "::", - stringify!(sa_mask) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).sa_flags as *const _ as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(sigaction), - "::", - stringify!(sa_flags) - ) - ); -} -pub type sig_t = ::std::option::Option; -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct sigvec { - pub sv_handler: ::std::option::Option, - pub sv_mask: ::std::os::raw::c_int, - pub sv_flags: ::std::os::raw::c_int, -} -#[test] -fn bindgen_test_layout_sigvec() { - assert_eq!( - ::std::mem::size_of::(), - 16usize, - concat!("Size of: ", stringify!(sigvec)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(sigvec)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).sv_handler as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(sigvec), - "::", - stringify!(sv_handler) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).sv_mask as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(sigvec), - "::", - stringify!(sv_mask) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).sv_flags as *const _ as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(sigvec), - "::", - stringify!(sv_flags) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct sigstack { - pub ss_sp: *mut ::std::os::raw::c_char, - pub ss_onstack: ::std::os::raw::c_int, -} -#[test] -fn bindgen_test_layout_sigstack() { - assert_eq!( - ::std::mem::size_of::(), - 16usize, - concat!("Size of: ", stringify!(sigstack)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(sigstack)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ss_sp as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(sigstack), - "::", - stringify!(ss_sp) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ss_onstack as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(sigstack), - "::", - stringify!(ss_onstack) - ) - ); -} -extern "C" { - pub fn signal( - arg1: ::std::os::raw::c_int, - arg2: ::std::option::Option, - ) -> ::std::option::Option< - unsafe extern "C" fn( - arg1: ::std::os::raw::c_int, - arg2: ::std::option::Option, - ), - >; -} -pub type int_least8_t = i8; -pub type int_least16_t = i16; -pub type int_least32_t = i32; -pub type int_least64_t = i64; -pub type uint_least8_t = u8; -pub type uint_least16_t = u16; -pub type uint_least32_t = u32; -pub type uint_least64_t = u64; -pub type int_fast8_t = i8; -pub type int_fast16_t = i16; -pub type int_fast32_t = i32; -pub type int_fast64_t = i64; -pub type uint_fast8_t = u8; -pub type uint_fast16_t = u16; -pub type uint_fast32_t = u32; -pub type uint_fast64_t = u64; -pub type intmax_t = ::std::os::raw::c_long; -pub type uintmax_t = ::std::os::raw::c_ulong; -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct timeval { - pub tv_sec: __darwin_time_t, - pub tv_usec: __darwin_suseconds_t, -} -#[test] -fn bindgen_test_layout_timeval() { - assert_eq!( - ::std::mem::size_of::(), - 16usize, - concat!("Size of: ", stringify!(timeval)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(timeval)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).tv_sec as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(timeval), - "::", - stringify!(tv_sec) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).tv_usec as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(timeval), - "::", - stringify!(tv_usec) - ) - ); -} -pub type rlim_t = __uint64_t; -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct rusage { - pub ru_utime: timeval, - pub ru_stime: timeval, - pub ru_maxrss: ::std::os::raw::c_long, - pub ru_ixrss: ::std::os::raw::c_long, - pub ru_idrss: ::std::os::raw::c_long, - pub ru_isrss: ::std::os::raw::c_long, - pub ru_minflt: ::std::os::raw::c_long, - pub ru_majflt: ::std::os::raw::c_long, - pub ru_nswap: ::std::os::raw::c_long, - pub ru_inblock: ::std::os::raw::c_long, - pub ru_oublock: ::std::os::raw::c_long, - pub ru_msgsnd: ::std::os::raw::c_long, - pub ru_msgrcv: ::std::os::raw::c_long, - pub ru_nsignals: ::std::os::raw::c_long, - pub ru_nvcsw: ::std::os::raw::c_long, - pub ru_nivcsw: ::std::os::raw::c_long, -} -#[test] -fn bindgen_test_layout_rusage() { - assert_eq!( - ::std::mem::size_of::(), - 144usize, - concat!("Size of: ", stringify!(rusage)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(rusage)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_utime as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_utime) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_stime as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_stime) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_maxrss as *const _ as usize }, - 32usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_maxrss) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_ixrss as *const _ as usize }, - 40usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_ixrss) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_idrss as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_idrss) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_isrss as *const _ as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_isrss) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_minflt as *const _ as usize }, - 64usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_minflt) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_majflt as *const _ as usize }, - 72usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_majflt) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_nswap as *const _ as usize }, - 80usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_nswap) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_inblock as *const _ as usize }, - 88usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_inblock) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_oublock as *const _ as usize }, - 96usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_oublock) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_msgsnd as *const _ as usize }, - 104usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_msgsnd) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_msgrcv as *const _ as usize }, - 112usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_msgrcv) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_nsignals as *const _ as usize }, - 120usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_nsignals) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_nvcsw as *const _ as usize }, - 128usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_nvcsw) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_nivcsw as *const _ as usize }, - 136usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_nivcsw) - ) - ); -} -pub type rusage_info_t = *mut ::std::os::raw::c_void; -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct rusage_info_v0 { - pub ri_uuid: [u8; 16usize], - pub ri_user_time: u64, - pub ri_system_time: u64, - pub ri_pkg_idle_wkups: u64, - pub ri_interrupt_wkups: u64, - pub ri_pageins: u64, - pub ri_wired_size: u64, - pub ri_resident_size: u64, - pub ri_phys_footprint: u64, - pub ri_proc_start_abstime: u64, - pub ri_proc_exit_abstime: u64, -} -#[test] -fn bindgen_test_layout_rusage_info_v0() { - assert_eq!( - ::std::mem::size_of::(), - 96usize, - concat!("Size of: ", stringify!(rusage_info_v0)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(rusage_info_v0)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_uuid as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v0), - "::", - stringify!(ri_uuid) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_user_time as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v0), - "::", - stringify!(ri_user_time) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_system_time as *const _ as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v0), - "::", - stringify!(ri_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_pkg_idle_wkups as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v0), - "::", - stringify!(ri_pkg_idle_wkups) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_interrupt_wkups as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v0), - "::", - stringify!(ri_interrupt_wkups) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_pageins as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v0), - "::", - stringify!(ri_pageins) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_wired_size as *const _ as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v0), - "::", - stringify!(ri_wired_size) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_resident_size as *const _ as usize }, - 64usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v0), - "::", - stringify!(ri_resident_size) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_phys_footprint as *const _ as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v0), - "::", - stringify!(ri_phys_footprint) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_start_abstime as *const _ as usize - }, - 80usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v0), - "::", - stringify!(ri_proc_start_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_exit_abstime as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v0), - "::", - stringify!(ri_proc_exit_abstime) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct rusage_info_v1 { - pub ri_uuid: [u8; 16usize], - pub ri_user_time: u64, - pub ri_system_time: u64, - pub ri_pkg_idle_wkups: u64, - pub ri_interrupt_wkups: u64, - pub ri_pageins: u64, - pub ri_wired_size: u64, - pub ri_resident_size: u64, - pub ri_phys_footprint: u64, - pub ri_proc_start_abstime: u64, - pub ri_proc_exit_abstime: u64, - pub ri_child_user_time: u64, - pub ri_child_system_time: u64, - pub ri_child_pkg_idle_wkups: u64, - pub ri_child_interrupt_wkups: u64, - pub ri_child_pageins: u64, - pub ri_child_elapsed_abstime: u64, -} -#[test] -fn bindgen_test_layout_rusage_info_v1() { - assert_eq!( - ::std::mem::size_of::(), - 144usize, - concat!("Size of: ", stringify!(rusage_info_v1)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(rusage_info_v1)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_uuid as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_uuid) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_user_time as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_user_time) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_system_time as *const _ as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_pkg_idle_wkups as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_pkg_idle_wkups) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_interrupt_wkups as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_interrupt_wkups) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_pageins as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_pageins) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_wired_size as *const _ as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_wired_size) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_resident_size as *const _ as usize }, - 64usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_resident_size) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_phys_footprint as *const _ as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_phys_footprint) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_start_abstime as *const _ as usize - }, - 80usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_proc_start_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_exit_abstime as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_proc_exit_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_user_time as *const _ as usize - }, - 96usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_child_user_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_system_time as *const _ as usize - }, - 104usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_child_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_pkg_idle_wkups as *const _ as usize - }, - 112usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_child_pkg_idle_wkups) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_interrupt_wkups as *const _ as usize - }, - 120usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_child_interrupt_wkups) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_child_pageins as *const _ as usize }, - 128usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_child_pageins) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_elapsed_abstime as *const _ as usize - }, - 136usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_child_elapsed_abstime) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct rusage_info_v2 { - pub ri_uuid: [u8; 16usize], - pub ri_user_time: u64, - pub ri_system_time: u64, - pub ri_pkg_idle_wkups: u64, - pub ri_interrupt_wkups: u64, - pub ri_pageins: u64, - pub ri_wired_size: u64, - pub ri_resident_size: u64, - pub ri_phys_footprint: u64, - pub ri_proc_start_abstime: u64, - pub ri_proc_exit_abstime: u64, - pub ri_child_user_time: u64, - pub ri_child_system_time: u64, - pub ri_child_pkg_idle_wkups: u64, - pub ri_child_interrupt_wkups: u64, - pub ri_child_pageins: u64, - pub ri_child_elapsed_abstime: u64, - pub ri_diskio_bytesread: u64, - pub ri_diskio_byteswritten: u64, -} -#[test] -fn bindgen_test_layout_rusage_info_v2() { - assert_eq!( - ::std::mem::size_of::(), - 160usize, - concat!("Size of: ", stringify!(rusage_info_v2)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(rusage_info_v2)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_uuid as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_uuid) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_user_time as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_user_time) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_system_time as *const _ as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_pkg_idle_wkups as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_pkg_idle_wkups) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_interrupt_wkups as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_interrupt_wkups) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_pageins as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_pageins) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_wired_size as *const _ as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_wired_size) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_resident_size as *const _ as usize }, - 64usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_resident_size) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_phys_footprint as *const _ as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_phys_footprint) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_start_abstime as *const _ as usize - }, - 80usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_proc_start_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_exit_abstime as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_proc_exit_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_user_time as *const _ as usize - }, - 96usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_child_user_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_system_time as *const _ as usize - }, - 104usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_child_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_pkg_idle_wkups as *const _ as usize - }, - 112usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_child_pkg_idle_wkups) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_interrupt_wkups as *const _ as usize - }, - 120usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_child_interrupt_wkups) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_child_pageins as *const _ as usize }, - 128usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_child_pageins) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_elapsed_abstime as *const _ as usize - }, - 136usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_child_elapsed_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_diskio_bytesread as *const _ as usize - }, - 144usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_diskio_bytesread) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_diskio_byteswritten as *const _ as usize - }, - 152usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_diskio_byteswritten) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct rusage_info_v3 { - pub ri_uuid: [u8; 16usize], - pub ri_user_time: u64, - pub ri_system_time: u64, - pub ri_pkg_idle_wkups: u64, - pub ri_interrupt_wkups: u64, - pub ri_pageins: u64, - pub ri_wired_size: u64, - pub ri_resident_size: u64, - pub ri_phys_footprint: u64, - pub ri_proc_start_abstime: u64, - pub ri_proc_exit_abstime: u64, - pub ri_child_user_time: u64, - pub ri_child_system_time: u64, - pub ri_child_pkg_idle_wkups: u64, - pub ri_child_interrupt_wkups: u64, - pub ri_child_pageins: u64, - pub ri_child_elapsed_abstime: u64, - pub ri_diskio_bytesread: u64, - pub ri_diskio_byteswritten: u64, - pub ri_cpu_time_qos_default: u64, - pub ri_cpu_time_qos_maintenance: u64, - pub ri_cpu_time_qos_background: u64, - pub ri_cpu_time_qos_utility: u64, - pub ri_cpu_time_qos_legacy: u64, - pub ri_cpu_time_qos_user_initiated: u64, - pub ri_cpu_time_qos_user_interactive: u64, - pub ri_billed_system_time: u64, - pub ri_serviced_system_time: u64, -} -#[test] -fn bindgen_test_layout_rusage_info_v3() { - assert_eq!( - ::std::mem::size_of::(), - 232usize, - concat!("Size of: ", stringify!(rusage_info_v3)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(rusage_info_v3)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_uuid as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_uuid) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_user_time as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_user_time) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_system_time as *const _ as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_pkg_idle_wkups as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_pkg_idle_wkups) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_interrupt_wkups as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_interrupt_wkups) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_pageins as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_pageins) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_wired_size as *const _ as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_wired_size) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_resident_size as *const _ as usize }, - 64usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_resident_size) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_phys_footprint as *const _ as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_phys_footprint) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_start_abstime as *const _ as usize - }, - 80usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_proc_start_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_exit_abstime as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_proc_exit_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_user_time as *const _ as usize - }, - 96usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_child_user_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_system_time as *const _ as usize - }, - 104usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_child_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_pkg_idle_wkups as *const _ as usize - }, - 112usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_child_pkg_idle_wkups) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_interrupt_wkups as *const _ as usize - }, - 120usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_child_interrupt_wkups) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_child_pageins as *const _ as usize }, - 128usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_child_pageins) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_elapsed_abstime as *const _ as usize - }, - 136usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_child_elapsed_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_diskio_bytesread as *const _ as usize - }, - 144usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_diskio_bytesread) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_diskio_byteswritten as *const _ as usize - }, - 152usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_diskio_byteswritten) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_default as *const _ as usize - }, - 160usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_cpu_time_qos_default) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_maintenance as *const _ - as usize - }, - 168usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_cpu_time_qos_maintenance) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_background as *const _ - as usize - }, - 176usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_cpu_time_qos_background) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_utility as *const _ as usize - }, - 184usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_cpu_time_qos_utility) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_legacy as *const _ as usize - }, - 192usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_cpu_time_qos_legacy) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_user_initiated as *const _ - as usize - }, - 200usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_cpu_time_qos_user_initiated) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_user_interactive as *const _ - as usize - }, - 208usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_cpu_time_qos_user_interactive) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_billed_system_time as *const _ as usize - }, - 216usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_billed_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_serviced_system_time as *const _ as usize - }, - 224usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_serviced_system_time) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct rusage_info_v4 { - pub ri_uuid: [u8; 16usize], - pub ri_user_time: u64, - pub ri_system_time: u64, - pub ri_pkg_idle_wkups: u64, - pub ri_interrupt_wkups: u64, - pub ri_pageins: u64, - pub ri_wired_size: u64, - pub ri_resident_size: u64, - pub ri_phys_footprint: u64, - pub ri_proc_start_abstime: u64, - pub ri_proc_exit_abstime: u64, - pub ri_child_user_time: u64, - pub ri_child_system_time: u64, - pub ri_child_pkg_idle_wkups: u64, - pub ri_child_interrupt_wkups: u64, - pub ri_child_pageins: u64, - pub ri_child_elapsed_abstime: u64, - pub ri_diskio_bytesread: u64, - pub ri_diskio_byteswritten: u64, - pub ri_cpu_time_qos_default: u64, - pub ri_cpu_time_qos_maintenance: u64, - pub ri_cpu_time_qos_background: u64, - pub ri_cpu_time_qos_utility: u64, - pub ri_cpu_time_qos_legacy: u64, - pub ri_cpu_time_qos_user_initiated: u64, - pub ri_cpu_time_qos_user_interactive: u64, - pub ri_billed_system_time: u64, - pub ri_serviced_system_time: u64, - pub ri_logical_writes: u64, - pub ri_lifetime_max_phys_footprint: u64, - pub ri_instructions: u64, - pub ri_cycles: u64, - pub ri_billed_energy: u64, - pub ri_serviced_energy: u64, - pub ri_interval_max_phys_footprint: u64, - pub ri_runnable_time: u64, -} -#[test] -fn bindgen_test_layout_rusage_info_v4() { - assert_eq!( - ::std::mem::size_of::(), - 296usize, - concat!("Size of: ", stringify!(rusage_info_v4)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(rusage_info_v4)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_uuid as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_uuid) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_user_time as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_user_time) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_system_time as *const _ as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_pkg_idle_wkups as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_pkg_idle_wkups) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_interrupt_wkups as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_interrupt_wkups) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_pageins as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_pageins) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_wired_size as *const _ as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_wired_size) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_resident_size as *const _ as usize }, - 64usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_resident_size) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_phys_footprint as *const _ as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_phys_footprint) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_start_abstime as *const _ as usize - }, - 80usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_proc_start_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_exit_abstime as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_proc_exit_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_user_time as *const _ as usize - }, - 96usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_child_user_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_system_time as *const _ as usize - }, - 104usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_child_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_pkg_idle_wkups as *const _ as usize - }, - 112usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_child_pkg_idle_wkups) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_interrupt_wkups as *const _ as usize - }, - 120usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_child_interrupt_wkups) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_child_pageins as *const _ as usize }, - 128usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_child_pageins) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_elapsed_abstime as *const _ as usize - }, - 136usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_child_elapsed_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_diskio_bytesread as *const _ as usize - }, - 144usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_diskio_bytesread) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_diskio_byteswritten as *const _ as usize - }, - 152usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_diskio_byteswritten) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_default as *const _ as usize - }, - 160usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_cpu_time_qos_default) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_maintenance as *const _ - as usize - }, - 168usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_cpu_time_qos_maintenance) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_background as *const _ - as usize - }, - 176usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_cpu_time_qos_background) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_utility as *const _ as usize - }, - 184usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_cpu_time_qos_utility) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_legacy as *const _ as usize - }, - 192usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_cpu_time_qos_legacy) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_user_initiated as *const _ - as usize - }, - 200usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_cpu_time_qos_user_initiated) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_user_interactive as *const _ - as usize - }, - 208usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_cpu_time_qos_user_interactive) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_billed_system_time as *const _ as usize - }, - 216usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_billed_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_serviced_system_time as *const _ as usize - }, - 224usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_serviced_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_logical_writes as *const _ as usize - }, - 232usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_logical_writes) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_lifetime_max_phys_footprint as *const _ - as usize - }, - 240usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_lifetime_max_phys_footprint) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_instructions as *const _ as usize }, - 248usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_instructions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_cycles as *const _ as usize }, - 256usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_cycles) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_billed_energy as *const _ as usize }, - 264usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_billed_energy) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_serviced_energy as *const _ as usize - }, - 272usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_serviced_energy) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_interval_max_phys_footprint as *const _ - as usize - }, - 280usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_interval_max_phys_footprint) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_runnable_time as *const _ as usize }, - 288usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_runnable_time) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct rusage_info_v5 { - pub ri_uuid: [u8; 16usize], - pub ri_user_time: u64, - pub ri_system_time: u64, - pub ri_pkg_idle_wkups: u64, - pub ri_interrupt_wkups: u64, - pub ri_pageins: u64, - pub ri_wired_size: u64, - pub ri_resident_size: u64, - pub ri_phys_footprint: u64, - pub ri_proc_start_abstime: u64, - pub ri_proc_exit_abstime: u64, - pub ri_child_user_time: u64, - pub ri_child_system_time: u64, - pub ri_child_pkg_idle_wkups: u64, - pub ri_child_interrupt_wkups: u64, - pub ri_child_pageins: u64, - pub ri_child_elapsed_abstime: u64, - pub ri_diskio_bytesread: u64, - pub ri_diskio_byteswritten: u64, - pub ri_cpu_time_qos_default: u64, - pub ri_cpu_time_qos_maintenance: u64, - pub ri_cpu_time_qos_background: u64, - pub ri_cpu_time_qos_utility: u64, - pub ri_cpu_time_qos_legacy: u64, - pub ri_cpu_time_qos_user_initiated: u64, - pub ri_cpu_time_qos_user_interactive: u64, - pub ri_billed_system_time: u64, - pub ri_serviced_system_time: u64, - pub ri_logical_writes: u64, - pub ri_lifetime_max_phys_footprint: u64, - pub ri_instructions: u64, - pub ri_cycles: u64, - pub ri_billed_energy: u64, - pub ri_serviced_energy: u64, - pub ri_interval_max_phys_footprint: u64, - pub ri_runnable_time: u64, - pub ri_flags: u64, -} -#[test] -fn bindgen_test_layout_rusage_info_v5() { - assert_eq!( - ::std::mem::size_of::(), - 304usize, - concat!("Size of: ", stringify!(rusage_info_v5)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(rusage_info_v5)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_uuid as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_uuid) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_user_time as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_user_time) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_system_time as *const _ as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_pkg_idle_wkups as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_pkg_idle_wkups) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_interrupt_wkups as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_interrupt_wkups) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_pageins as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_pageins) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_wired_size as *const _ as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_wired_size) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_resident_size as *const _ as usize }, - 64usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_resident_size) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_phys_footprint as *const _ as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_phys_footprint) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_start_abstime as *const _ as usize - }, - 80usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_proc_start_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_exit_abstime as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_proc_exit_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_user_time as *const _ as usize - }, - 96usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_child_user_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_system_time as *const _ as usize - }, - 104usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_child_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_pkg_idle_wkups as *const _ as usize - }, - 112usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_child_pkg_idle_wkups) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_interrupt_wkups as *const _ as usize - }, - 120usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_child_interrupt_wkups) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_child_pageins as *const _ as usize }, - 128usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_child_pageins) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_elapsed_abstime as *const _ as usize - }, - 136usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_child_elapsed_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_diskio_bytesread as *const _ as usize - }, - 144usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_diskio_bytesread) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_diskio_byteswritten as *const _ as usize - }, - 152usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_diskio_byteswritten) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_default as *const _ as usize - }, - 160usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_cpu_time_qos_default) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_maintenance as *const _ - as usize - }, - 168usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_cpu_time_qos_maintenance) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_background as *const _ - as usize - }, - 176usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_cpu_time_qos_background) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_utility as *const _ as usize - }, - 184usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_cpu_time_qos_utility) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_legacy as *const _ as usize - }, - 192usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_cpu_time_qos_legacy) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_user_initiated as *const _ - as usize - }, - 200usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_cpu_time_qos_user_initiated) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_user_interactive as *const _ - as usize - }, - 208usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_cpu_time_qos_user_interactive) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_billed_system_time as *const _ as usize - }, - 216usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_billed_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_serviced_system_time as *const _ as usize - }, - 224usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_serviced_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_logical_writes as *const _ as usize - }, - 232usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_logical_writes) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_lifetime_max_phys_footprint as *const _ - as usize - }, - 240usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_lifetime_max_phys_footprint) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_instructions as *const _ as usize }, - 248usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_instructions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_cycles as *const _ as usize }, - 256usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_cycles) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_billed_energy as *const _ as usize }, - 264usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_billed_energy) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_serviced_energy as *const _ as usize - }, - 272usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_serviced_energy) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_interval_max_phys_footprint as *const _ - as usize - }, - 280usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_interval_max_phys_footprint) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_runnable_time as *const _ as usize }, - 288usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_runnable_time) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_flags as *const _ as usize }, - 296usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_flags) - ) - ); -} -pub type rusage_info_current = rusage_info_v5; -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct rlimit { - pub rlim_cur: rlim_t, - pub rlim_max: rlim_t, -} -#[test] -fn bindgen_test_layout_rlimit() { - assert_eq!( - ::std::mem::size_of::(), - 16usize, - concat!("Size of: ", stringify!(rlimit)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(rlimit)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).rlim_cur as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(rlimit), - "::", - stringify!(rlim_cur) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).rlim_max as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(rlimit), - "::", - stringify!(rlim_max) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct proc_rlimit_control_wakeupmon { - pub wm_flags: u32, - pub wm_rate: i32, -} -#[test] -fn bindgen_test_layout_proc_rlimit_control_wakeupmon() { - assert_eq!( - ::std::mem::size_of::(), - 8usize, - concat!("Size of: ", stringify!(proc_rlimit_control_wakeupmon)) - ); - assert_eq!( - ::std::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(proc_rlimit_control_wakeupmon)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).wm_flags as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(proc_rlimit_control_wakeupmon), - "::", - stringify!(wm_flags) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).wm_rate as *const _ as usize - }, - 4usize, - concat!( - "Offset of field: ", - stringify!(proc_rlimit_control_wakeupmon), - "::", - stringify!(wm_rate) - ) - ); -} -extern "C" { - pub fn getpriority(arg1: ::std::os::raw::c_int, arg2: id_t) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn getiopolicy_np( - arg1: ::std::os::raw::c_int, - arg2: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn getrlimit(arg1: ::std::os::raw::c_int, arg2: *mut rlimit) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn getrusage(arg1: ::std::os::raw::c_int, arg2: *mut rusage) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn setpriority( - arg1: ::std::os::raw::c_int, - arg2: id_t, - arg3: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn setiopolicy_np( - arg1: ::std::os::raw::c_int, - arg2: ::std::os::raw::c_int, - arg3: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn setrlimit(arg1: ::std::os::raw::c_int, arg2: *const rlimit) -> ::std::os::raw::c_int; -} -#[repr(C)] -#[derive(Copy, Clone)] -pub union wait { - pub w_status: ::std::os::raw::c_int, - pub w_T: wait__bindgen_ty_1, - pub w_S: wait__bindgen_ty_2, -} -#[repr(C)] -#[repr(align(4))] -#[derive(Debug, Copy, Clone)] -pub struct wait__bindgen_ty_1 { - pub _bitfield_align_1: [u16; 0], - pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, -} -#[test] -fn bindgen_test_layout_wait__bindgen_ty_1() { - assert_eq!( - ::std::mem::size_of::(), - 4usize, - concat!("Size of: ", stringify!(wait__bindgen_ty_1)) - ); - assert_eq!( - ::std::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(wait__bindgen_ty_1)) - ); -} -impl wait__bindgen_ty_1 { - #[inline] - pub fn w_Termsig(&self) -> ::std::os::raw::c_uint { - unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 7u8) as u32) } - } - #[inline] - pub fn set_w_Termsig(&mut self, val: ::std::os::raw::c_uint) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(0usize, 7u8, val as u64) - } - } - #[inline] - pub fn w_Coredump(&self) -> ::std::os::raw::c_uint { - unsafe { ::std::mem::transmute(self._bitfield_1.get(7usize, 1u8) as u32) } - } - #[inline] - pub fn set_w_Coredump(&mut self, val: ::std::os::raw::c_uint) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(7usize, 1u8, val as u64) - } - } - #[inline] - pub fn w_Retcode(&self) -> ::std::os::raw::c_uint { - unsafe { ::std::mem::transmute(self._bitfield_1.get(8usize, 8u8) as u32) } - } - #[inline] - pub fn set_w_Retcode(&mut self, val: ::std::os::raw::c_uint) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(8usize, 8u8, val as u64) - } - } - #[inline] - pub fn w_Filler(&self) -> ::std::os::raw::c_uint { - unsafe { ::std::mem::transmute(self._bitfield_1.get(16usize, 16u8) as u32) } - } - #[inline] - pub fn set_w_Filler(&mut self, val: ::std::os::raw::c_uint) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(16usize, 16u8, val as u64) - } - } - #[inline] - pub fn new_bitfield_1( - w_Termsig: ::std::os::raw::c_uint, - w_Coredump: ::std::os::raw::c_uint, - w_Retcode: ::std::os::raw::c_uint, - w_Filler: ::std::os::raw::c_uint, - ) -> __BindgenBitfieldUnit<[u8; 4usize]> { - let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 4usize]> = Default::default(); - __bindgen_bitfield_unit.set(0usize, 7u8, { - let w_Termsig: u32 = unsafe { ::std::mem::transmute(w_Termsig) }; - w_Termsig as u64 - }); - __bindgen_bitfield_unit.set(7usize, 1u8, { - let w_Coredump: u32 = unsafe { ::std::mem::transmute(w_Coredump) }; - w_Coredump as u64 - }); - __bindgen_bitfield_unit.set(8usize, 8u8, { - let w_Retcode: u32 = unsafe { ::std::mem::transmute(w_Retcode) }; - w_Retcode as u64 - }); - __bindgen_bitfield_unit.set(16usize, 16u8, { - let w_Filler: u32 = unsafe { ::std::mem::transmute(w_Filler) }; - w_Filler as u64 - }); - __bindgen_bitfield_unit - } -} -#[repr(C)] -#[repr(align(4))] -#[derive(Debug, Copy, Clone)] -pub struct wait__bindgen_ty_2 { - pub _bitfield_align_1: [u16; 0], - pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, -} -#[test] -fn bindgen_test_layout_wait__bindgen_ty_2() { - assert_eq!( - ::std::mem::size_of::(), - 4usize, - concat!("Size of: ", stringify!(wait__bindgen_ty_2)) - ); - assert_eq!( - ::std::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(wait__bindgen_ty_2)) - ); -} -impl wait__bindgen_ty_2 { - #[inline] - pub fn w_Stopval(&self) -> ::std::os::raw::c_uint { - unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 8u8) as u32) } - } - #[inline] - pub fn set_w_Stopval(&mut self, val: ::std::os::raw::c_uint) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(0usize, 8u8, val as u64) - } - } - #[inline] - pub fn w_Stopsig(&self) -> ::std::os::raw::c_uint { - unsafe { ::std::mem::transmute(self._bitfield_1.get(8usize, 8u8) as u32) } - } - #[inline] - pub fn set_w_Stopsig(&mut self, val: ::std::os::raw::c_uint) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(8usize, 8u8, val as u64) - } - } - #[inline] - pub fn w_Filler(&self) -> ::std::os::raw::c_uint { - unsafe { ::std::mem::transmute(self._bitfield_1.get(16usize, 16u8) as u32) } - } - #[inline] - pub fn set_w_Filler(&mut self, val: ::std::os::raw::c_uint) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(16usize, 16u8, val as u64) - } - } - #[inline] - pub fn new_bitfield_1( - w_Stopval: ::std::os::raw::c_uint, - w_Stopsig: ::std::os::raw::c_uint, - w_Filler: ::std::os::raw::c_uint, - ) -> __BindgenBitfieldUnit<[u8; 4usize]> { - let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 4usize]> = Default::default(); - __bindgen_bitfield_unit.set(0usize, 8u8, { - let w_Stopval: u32 = unsafe { ::std::mem::transmute(w_Stopval) }; - w_Stopval as u64 - }); - __bindgen_bitfield_unit.set(8usize, 8u8, { - let w_Stopsig: u32 = unsafe { ::std::mem::transmute(w_Stopsig) }; - w_Stopsig as u64 - }); - __bindgen_bitfield_unit.set(16usize, 16u8, { - let w_Filler: u32 = unsafe { ::std::mem::transmute(w_Filler) }; - w_Filler as u64 - }); - __bindgen_bitfield_unit - } -} -#[test] -fn bindgen_test_layout_wait() { - assert_eq!( - ::std::mem::size_of::(), - 4usize, - concat!("Size of: ", stringify!(wait)) - ); - assert_eq!( - ::std::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(wait)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).w_status as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(wait), - "::", - stringify!(w_status) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).w_T as *const _ as usize }, - 0usize, - concat!("Offset of field: ", stringify!(wait), "::", stringify!(w_T)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).w_S as *const _ as usize }, - 0usize, - concat!("Offset of field: ", stringify!(wait), "::", stringify!(w_S)) - ); -} -extern "C" { - pub fn wait(arg1: *mut ::std::os::raw::c_int) -> pid_t; -} -extern "C" { - pub fn waitpid( - arg1: pid_t, - arg2: *mut ::std::os::raw::c_int, - arg3: ::std::os::raw::c_int, - ) -> pid_t; -} -extern "C" { - pub fn waitid( - arg1: idtype_t, - arg2: id_t, - arg3: *mut siginfo_t, - arg4: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn wait3( - arg1: *mut ::std::os::raw::c_int, - arg2: ::std::os::raw::c_int, - arg3: *mut rusage, - ) -> pid_t; -} -extern "C" { - pub fn wait4( - arg1: pid_t, - arg2: *mut ::std::os::raw::c_int, - arg3: ::std::os::raw::c_int, - arg4: *mut rusage, - ) -> pid_t; -} -extern "C" { - pub fn alloca(arg1: ::std::os::raw::c_ulong) -> *mut ::std::os::raw::c_void; -} -pub type ct_rune_t = __darwin_ct_rune_t; -pub type rune_t = __darwin_rune_t; -pub type wchar_t = __darwin_wchar_t; -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct div_t { - pub quot: ::std::os::raw::c_int, - pub rem: ::std::os::raw::c_int, -} -#[test] -fn bindgen_test_layout_div_t() { - assert_eq!( - ::std::mem::size_of::(), - 8usize, - concat!("Size of: ", stringify!(div_t)) - ); - assert_eq!( - ::std::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(div_t)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).quot as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(div_t), - "::", - stringify!(quot) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).rem as *const _ as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(div_t), - "::", - stringify!(rem) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct ldiv_t { - pub quot: ::std::os::raw::c_long, - pub rem: ::std::os::raw::c_long, -} -#[test] -fn bindgen_test_layout_ldiv_t() { - assert_eq!( - ::std::mem::size_of::(), - 16usize, - concat!("Size of: ", stringify!(ldiv_t)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(ldiv_t)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).quot as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(ldiv_t), - "::", - stringify!(quot) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).rem as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(ldiv_t), - "::", - stringify!(rem) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct lldiv_t { - pub quot: ::std::os::raw::c_longlong, - pub rem: ::std::os::raw::c_longlong, -} -#[test] -fn bindgen_test_layout_lldiv_t() { - assert_eq!( - ::std::mem::size_of::(), - 16usize, - concat!("Size of: ", stringify!(lldiv_t)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(lldiv_t)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).quot as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(lldiv_t), - "::", - stringify!(quot) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).rem as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(lldiv_t), - "::", - stringify!(rem) - ) - ); -} -extern "C" { - pub static mut __mb_cur_max: ::std::os::raw::c_int; -} -extern "C" { - pub fn malloc(__size: ::std::os::raw::c_ulong) -> *mut ::std::os::raw::c_void; -} -extern "C" { - pub fn calloc( - __count: ::std::os::raw::c_ulong, - __size: ::std::os::raw::c_ulong, - ) -> *mut ::std::os::raw::c_void; -} -extern "C" { - pub fn free(arg1: *mut ::std::os::raw::c_void); -} -extern "C" { - pub fn realloc( - __ptr: *mut ::std::os::raw::c_void, - __size: ::std::os::raw::c_ulong, - ) -> *mut ::std::os::raw::c_void; -} -extern "C" { - pub fn valloc(arg1: usize) -> *mut ::std::os::raw::c_void; -} -extern "C" { - pub fn aligned_alloc(__alignment: usize, __size: usize) -> *mut ::std::os::raw::c_void; -} -extern "C" { - pub fn posix_memalign( - __memptr: *mut *mut ::std::os::raw::c_void, - __alignment: usize, - __size: usize, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn abort(); -} -extern "C" { - pub fn abs(arg1: ::std::os::raw::c_int) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn atexit(arg1: ::std::option::Option) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn atof(arg1: *const ::std::os::raw::c_char) -> f64; -} -extern "C" { - pub fn atoi(arg1: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn atol(arg1: *const ::std::os::raw::c_char) -> ::std::os::raw::c_long; -} -extern "C" { - pub fn atoll(arg1: *const ::std::os::raw::c_char) -> ::std::os::raw::c_longlong; -} -extern "C" { - pub fn bsearch( - __key: *const ::std::os::raw::c_void, - __base: *const ::std::os::raw::c_void, - __nel: usize, - __width: usize, - __compar: ::std::option::Option< - unsafe extern "C" fn( - arg1: *const ::std::os::raw::c_void, - arg2: *const ::std::os::raw::c_void, - ) -> ::std::os::raw::c_int, - >, - ) -> *mut ::std::os::raw::c_void; -} -extern "C" { - pub fn div(arg1: ::std::os::raw::c_int, arg2: ::std::os::raw::c_int) -> div_t; -} -extern "C" { - pub fn exit(arg1: ::std::os::raw::c_int); -} -extern "C" { - pub fn getenv(arg1: *const ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn labs(arg1: ::std::os::raw::c_long) -> ::std::os::raw::c_long; -} -extern "C" { - pub fn ldiv(arg1: ::std::os::raw::c_long, arg2: ::std::os::raw::c_long) -> ldiv_t; -} -extern "C" { - pub fn llabs(arg1: ::std::os::raw::c_longlong) -> ::std::os::raw::c_longlong; -} -extern "C" { - pub fn lldiv(arg1: ::std::os::raw::c_longlong, arg2: ::std::os::raw::c_longlong) -> lldiv_t; -} -extern "C" { - pub fn mblen(__s: *const ::std::os::raw::c_char, __n: usize) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn mbstowcs(arg1: *mut wchar_t, arg2: *const ::std::os::raw::c_char, arg3: usize) -> usize; -} -extern "C" { - pub fn mbtowc( - arg1: *mut wchar_t, - arg2: *const ::std::os::raw::c_char, - arg3: usize, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn qsort( - __base: *mut ::std::os::raw::c_void, - __nel: usize, - __width: usize, - __compar: ::std::option::Option< - unsafe extern "C" fn( - arg1: *const ::std::os::raw::c_void, - arg2: *const ::std::os::raw::c_void, - ) -> ::std::os::raw::c_int, - >, - ); -} -extern "C" { - pub fn rand() -> ::std::os::raw::c_int; -} -extern "C" { - pub fn srand(arg1: ::std::os::raw::c_uint); -} -extern "C" { - pub fn strtod( - arg1: *const ::std::os::raw::c_char, - arg2: *mut *mut ::std::os::raw::c_char, - ) -> f64; -} -extern "C" { - pub fn strtof( - arg1: *const ::std::os::raw::c_char, - arg2: *mut *mut ::std::os::raw::c_char, - ) -> f32; -} -extern "C" { - pub fn strtol( - __str: *const ::std::os::raw::c_char, - __endptr: *mut *mut ::std::os::raw::c_char, - __base: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_long; -} -extern "C" { - pub fn strtold( - arg1: *const ::std::os::raw::c_char, - arg2: *mut *mut ::std::os::raw::c_char, - ) -> u128; -} -extern "C" { - pub fn strtoll( - __str: *const ::std::os::raw::c_char, - __endptr: *mut *mut ::std::os::raw::c_char, - __base: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_longlong; -} -extern "C" { - pub fn strtoul( - __str: *const ::std::os::raw::c_char, - __endptr: *mut *mut ::std::os::raw::c_char, - __base: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_ulong; -} -extern "C" { - pub fn strtoull( - __str: *const ::std::os::raw::c_char, - __endptr: *mut *mut ::std::os::raw::c_char, - __base: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_ulonglong; -} -extern "C" { - pub fn system(arg1: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn wcstombs(arg1: *mut ::std::os::raw::c_char, arg2: *const wchar_t, arg3: usize) -> usize; -} -extern "C" { - pub fn wctomb(arg1: *mut ::std::os::raw::c_char, arg2: wchar_t) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn _Exit(arg1: ::std::os::raw::c_int); -} -extern "C" { - pub fn a64l(arg1: *const ::std::os::raw::c_char) -> ::std::os::raw::c_long; -} -extern "C" { - pub fn drand48() -> f64; -} -extern "C" { - pub fn ecvt( - arg1: f64, - arg2: ::std::os::raw::c_int, - arg3: *mut ::std::os::raw::c_int, - arg4: *mut ::std::os::raw::c_int, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn erand48(arg1: *mut ::std::os::raw::c_ushort) -> f64; -} -extern "C" { - pub fn fcvt( - arg1: f64, - arg2: ::std::os::raw::c_int, - arg3: *mut ::std::os::raw::c_int, - arg4: *mut ::std::os::raw::c_int, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn gcvt( - arg1: f64, - arg2: ::std::os::raw::c_int, - arg3: *mut ::std::os::raw::c_char, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn getsubopt( - arg1: *mut *mut ::std::os::raw::c_char, - arg2: *const *mut ::std::os::raw::c_char, - arg3: *mut *mut ::std::os::raw::c_char, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn grantpt(arg1: ::std::os::raw::c_int) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn initstate( - arg1: ::std::os::raw::c_uint, - arg2: *mut ::std::os::raw::c_char, - arg3: usize, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn jrand48(arg1: *mut ::std::os::raw::c_ushort) -> ::std::os::raw::c_long; -} -extern "C" { - pub fn l64a(arg1: ::std::os::raw::c_long) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn lcong48(arg1: *mut ::std::os::raw::c_ushort); -} -extern "C" { - pub fn lrand48() -> ::std::os::raw::c_long; -} -extern "C" { - pub fn mktemp(arg1: *mut ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn mkstemp(arg1: *mut ::std::os::raw::c_char) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn mrand48() -> ::std::os::raw::c_long; -} -extern "C" { - pub fn nrand48(arg1: *mut ::std::os::raw::c_ushort) -> ::std::os::raw::c_long; -} -extern "C" { - pub fn posix_openpt(arg1: ::std::os::raw::c_int) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn ptsname(arg1: ::std::os::raw::c_int) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn ptsname_r( - fildes: ::std::os::raw::c_int, - buffer: *mut ::std::os::raw::c_char, - buflen: usize, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn putenv(arg1: *mut ::std::os::raw::c_char) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn random() -> ::std::os::raw::c_long; -} -extern "C" { - pub fn rand_r(arg1: *mut ::std::os::raw::c_uint) -> ::std::os::raw::c_int; -} -extern "C" { - #[link_name = "\u{1}_realpath$DARWIN_EXTSN"] - pub fn realpath( - arg1: *const ::std::os::raw::c_char, - arg2: *mut ::std::os::raw::c_char, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn seed48(arg1: *mut ::std::os::raw::c_ushort) -> *mut ::std::os::raw::c_ushort; -} -extern "C" { - pub fn setenv( - __name: *const ::std::os::raw::c_char, - __value: *const ::std::os::raw::c_char, - __overwrite: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn setkey(arg1: *const ::std::os::raw::c_char); -} -extern "C" { - pub fn setstate(arg1: *const ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn srand48(arg1: ::std::os::raw::c_long); -} -extern "C" { - pub fn srandom(arg1: ::std::os::raw::c_uint); -} -extern "C" { - pub fn unlockpt(arg1: ::std::os::raw::c_int) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn unsetenv(arg1: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int; -} -pub type dev_t = __darwin_dev_t; -pub type mode_t = __darwin_mode_t; -extern "C" { - pub fn arc4random() -> u32; -} -extern "C" { - pub fn arc4random_addrandom(arg1: *mut ::std::os::raw::c_uchar, arg2: ::std::os::raw::c_int); -} -extern "C" { - pub fn arc4random_buf(__buf: *mut ::std::os::raw::c_void, __nbytes: usize); -} -extern "C" { - pub fn arc4random_stir(); -} -extern "C" { - pub fn arc4random_uniform(__upper_bound: u32) -> u32; -} -extern "C" { - pub fn cgetcap( - arg1: *mut ::std::os::raw::c_char, - arg2: *const ::std::os::raw::c_char, - arg3: ::std::os::raw::c_int, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn cgetclose() -> ::std::os::raw::c_int; -} -extern "C" { - pub fn cgetent( - arg1: *mut *mut ::std::os::raw::c_char, - arg2: *mut *mut ::std::os::raw::c_char, - arg3: *const ::std::os::raw::c_char, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn cgetfirst( - arg1: *mut *mut ::std::os::raw::c_char, - arg2: *mut *mut ::std::os::raw::c_char, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn cgetmatch( - arg1: *const ::std::os::raw::c_char, - arg2: *const ::std::os::raw::c_char, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn cgetnext( - arg1: *mut *mut ::std::os::raw::c_char, - arg2: *mut *mut ::std::os::raw::c_char, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn cgetnum( - arg1: *mut ::std::os::raw::c_char, - arg2: *const ::std::os::raw::c_char, - arg3: *mut ::std::os::raw::c_long, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn cgetset(arg1: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn cgetstr( - arg1: *mut ::std::os::raw::c_char, - arg2: *const ::std::os::raw::c_char, - arg3: *mut *mut ::std::os::raw::c_char, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn cgetustr( - arg1: *mut ::std::os::raw::c_char, - arg2: *const ::std::os::raw::c_char, - arg3: *mut *mut ::std::os::raw::c_char, - ) -> ::std::os::raw::c_int; -} -extern "C" { - #[link_name = "\u{1}_daemon$1050"] - pub fn daemon( - arg1: ::std::os::raw::c_int, - arg2: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn devname(arg1: dev_t, arg2: mode_t) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn devname_r( - arg1: dev_t, - arg2: mode_t, - buf: *mut ::std::os::raw::c_char, - len: ::std::os::raw::c_int, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn getbsize( - arg1: *mut ::std::os::raw::c_int, - arg2: *mut ::std::os::raw::c_long, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn getloadavg(arg1: *mut f64, arg2: ::std::os::raw::c_int) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn getprogname() -> *const ::std::os::raw::c_char; -} -extern "C" { - pub fn setprogname(arg1: *const ::std::os::raw::c_char); -} -extern "C" { - pub fn heapsort( - __base: *mut ::std::os::raw::c_void, - __nel: usize, - __width: usize, - __compar: ::std::option::Option< - unsafe extern "C" fn( - arg1: *const ::std::os::raw::c_void, - arg2: *const ::std::os::raw::c_void, - ) -> ::std::os::raw::c_int, - >, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn mergesort( - __base: *mut ::std::os::raw::c_void, - __nel: usize, - __width: usize, - __compar: ::std::option::Option< - unsafe extern "C" fn( - arg1: *const ::std::os::raw::c_void, - arg2: *const ::std::os::raw::c_void, - ) -> ::std::os::raw::c_int, - >, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn psort( - __base: *mut ::std::os::raw::c_void, - __nel: usize, - __width: usize, - __compar: ::std::option::Option< - unsafe extern "C" fn( - arg1: *const ::std::os::raw::c_void, - arg2: *const ::std::os::raw::c_void, - ) -> ::std::os::raw::c_int, - >, - ); -} -extern "C" { - pub fn psort_r( - __base: *mut ::std::os::raw::c_void, - __nel: usize, - __width: usize, - arg1: *mut ::std::os::raw::c_void, - __compar: ::std::option::Option< - unsafe extern "C" fn( - arg1: *mut ::std::os::raw::c_void, - arg2: *const ::std::os::raw::c_void, - arg3: *const ::std::os::raw::c_void, - ) -> ::std::os::raw::c_int, - >, - ); -} -extern "C" { - pub fn qsort_r( - __base: *mut ::std::os::raw::c_void, - __nel: usize, - __width: usize, - arg1: *mut ::std::os::raw::c_void, - __compar: ::std::option::Option< - unsafe extern "C" fn( - arg1: *mut ::std::os::raw::c_void, - arg2: *const ::std::os::raw::c_void, - arg3: *const ::std::os::raw::c_void, - ) -> ::std::os::raw::c_int, - >, - ); -} -extern "C" { - pub fn radixsort( - __base: *mut *const ::std::os::raw::c_uchar, - __nel: ::std::os::raw::c_int, - __table: *const ::std::os::raw::c_uchar, - __endbyte: ::std::os::raw::c_uint, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn rpmatch(arg1: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn sradixsort( - __base: *mut *const ::std::os::raw::c_uchar, - __nel: ::std::os::raw::c_int, - __table: *const ::std::os::raw::c_uchar, - __endbyte: ::std::os::raw::c_uint, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn sranddev(); -} -extern "C" { - pub fn srandomdev(); -} -extern "C" { - pub fn reallocf( - __ptr: *mut ::std::os::raw::c_void, - __size: usize, - ) -> *mut ::std::os::raw::c_void; -} -extern "C" { - pub fn strtonum( - __numstr: *const ::std::os::raw::c_char, - __minval: ::std::os::raw::c_longlong, - __maxval: ::std::os::raw::c_longlong, - __errstrp: *mut *const ::std::os::raw::c_char, - ) -> ::std::os::raw::c_longlong; -} -extern "C" { - pub fn strtoq( - __str: *const ::std::os::raw::c_char, - __endptr: *mut *mut ::std::os::raw::c_char, - __base: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_longlong; -} -extern "C" { - pub fn strtouq( - __str: *const ::std::os::raw::c_char, - __endptr: *mut *mut ::std::os::raw::c_char, - __base: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_ulonglong; -} -extern "C" { - pub static mut suboptarg: *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn memchr( - __s: *const ::std::os::raw::c_void, - __c: ::std::os::raw::c_int, - __n: ::std::os::raw::c_ulong, - ) -> *mut ::std::os::raw::c_void; -} -extern "C" { - pub fn memcmp( - __s1: *const ::std::os::raw::c_void, - __s2: *const ::std::os::raw::c_void, - __n: ::std::os::raw::c_ulong, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn memcpy( - __dst: *mut ::std::os::raw::c_void, - __src: *const ::std::os::raw::c_void, - __n: ::std::os::raw::c_ulong, - ) -> *mut ::std::os::raw::c_void; -} -extern "C" { - pub fn memmove( - __dst: *mut ::std::os::raw::c_void, - __src: *const ::std::os::raw::c_void, - __len: ::std::os::raw::c_ulong, - ) -> *mut ::std::os::raw::c_void; -} -extern "C" { - pub fn memset( - __b: *mut ::std::os::raw::c_void, - __c: ::std::os::raw::c_int, - __len: ::std::os::raw::c_ulong, - ) -> *mut ::std::os::raw::c_void; -} -extern "C" { - pub fn strcat( - __s1: *mut ::std::os::raw::c_char, - __s2: *const ::std::os::raw::c_char, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strchr( - __s: *const ::std::os::raw::c_char, - __c: ::std::os::raw::c_int, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strcmp( - __s1: *const ::std::os::raw::c_char, - __s2: *const ::std::os::raw::c_char, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn strcoll( - __s1: *const ::std::os::raw::c_char, - __s2: *const ::std::os::raw::c_char, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn strcpy( - __dst: *mut ::std::os::raw::c_char, - __src: *const ::std::os::raw::c_char, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strcspn( - __s: *const ::std::os::raw::c_char, - __charset: *const ::std::os::raw::c_char, - ) -> ::std::os::raw::c_ulong; -} -extern "C" { - pub fn strerror(__errnum: ::std::os::raw::c_int) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strlen(__s: *const ::std::os::raw::c_char) -> ::std::os::raw::c_ulong; -} -extern "C" { - pub fn strncat( - __s1: *mut ::std::os::raw::c_char, - __s2: *const ::std::os::raw::c_char, - __n: ::std::os::raw::c_ulong, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strncmp( - __s1: *const ::std::os::raw::c_char, - __s2: *const ::std::os::raw::c_char, - __n: ::std::os::raw::c_ulong, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn strncpy( - __dst: *mut ::std::os::raw::c_char, - __src: *const ::std::os::raw::c_char, - __n: ::std::os::raw::c_ulong, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strpbrk( - __s: *const ::std::os::raw::c_char, - __charset: *const ::std::os::raw::c_char, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strrchr( - __s: *const ::std::os::raw::c_char, - __c: ::std::os::raw::c_int, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strspn( - __s: *const ::std::os::raw::c_char, - __charset: *const ::std::os::raw::c_char, - ) -> ::std::os::raw::c_ulong; -} -extern "C" { - pub fn strstr( - __big: *const ::std::os::raw::c_char, - __little: *const ::std::os::raw::c_char, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strtok( - __str: *mut ::std::os::raw::c_char, - __sep: *const ::std::os::raw::c_char, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strxfrm( - __s1: *mut ::std::os::raw::c_char, - __s2: *const ::std::os::raw::c_char, - __n: ::std::os::raw::c_ulong, - ) -> ::std::os::raw::c_ulong; -} -extern "C" { - pub fn strtok_r( - __str: *mut ::std::os::raw::c_char, - __sep: *const ::std::os::raw::c_char, - __lasts: *mut *mut ::std::os::raw::c_char, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strerror_r( - __errnum: ::std::os::raw::c_int, - __strerrbuf: *mut ::std::os::raw::c_char, - __buflen: usize, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn strdup(__s1: *const ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn memccpy( - __dst: *mut ::std::os::raw::c_void, - __src: *const ::std::os::raw::c_void, - __c: ::std::os::raw::c_int, - __n: ::std::os::raw::c_ulong, - ) -> *mut ::std::os::raw::c_void; -} -extern "C" { - pub fn stpcpy( - __dst: *mut ::std::os::raw::c_char, - __src: *const ::std::os::raw::c_char, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn stpncpy( - __dst: *mut ::std::os::raw::c_char, - __src: *const ::std::os::raw::c_char, - __n: ::std::os::raw::c_ulong, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strndup( - __s1: *const ::std::os::raw::c_char, - __n: ::std::os::raw::c_ulong, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strnlen(__s1: *const ::std::os::raw::c_char, __n: usize) -> usize; -} -extern "C" { - pub fn strsignal(__sig: ::std::os::raw::c_int) -> *mut ::std::os::raw::c_char; -} -pub type rsize_t = __darwin_size_t; -pub type errno_t = ::std::os::raw::c_int; -extern "C" { - pub fn memset_s( - __s: *mut ::std::os::raw::c_void, - __smax: rsize_t, - __c: ::std::os::raw::c_int, - __n: rsize_t, - ) -> errno_t; -} -extern "C" { - pub fn memmem( - __big: *const ::std::os::raw::c_void, - __big_len: usize, - __little: *const ::std::os::raw::c_void, - __little_len: usize, - ) -> *mut ::std::os::raw::c_void; -} -extern "C" { - pub fn memset_pattern4( - __b: *mut ::std::os::raw::c_void, - __pattern4: *const ::std::os::raw::c_void, - __len: usize, - ); -} -extern "C" { - pub fn memset_pattern8( - __b: *mut ::std::os::raw::c_void, - __pattern8: *const ::std::os::raw::c_void, - __len: usize, - ); -} -extern "C" { - pub fn memset_pattern16( - __b: *mut ::std::os::raw::c_void, - __pattern16: *const ::std::os::raw::c_void, - __len: usize, - ); -} -extern "C" { - pub fn strcasestr( - __big: *const ::std::os::raw::c_char, - __little: *const ::std::os::raw::c_char, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strnstr( - __big: *const ::std::os::raw::c_char, - __little: *const ::std::os::raw::c_char, - __len: usize, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strlcat( - __dst: *mut ::std::os::raw::c_char, - __source: *const ::std::os::raw::c_char, - __size: ::std::os::raw::c_ulong, - ) -> ::std::os::raw::c_ulong; -} -extern "C" { - pub fn strlcpy( - __dst: *mut ::std::os::raw::c_char, - __source: *const ::std::os::raw::c_char, - __size: ::std::os::raw::c_ulong, - ) -> ::std::os::raw::c_ulong; -} -extern "C" { - pub fn strmode(__mode: ::std::os::raw::c_int, __bp: *mut ::std::os::raw::c_char); -} -extern "C" { - pub fn strsep( - __stringp: *mut *mut ::std::os::raw::c_char, - __delim: *const ::std::os::raw::c_char, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn swab( - arg1: *const ::std::os::raw::c_void, - arg2: *mut ::std::os::raw::c_void, - arg3: isize, - ); -} -extern "C" { - pub fn timingsafe_bcmp( - __b1: *const ::std::os::raw::c_void, - __b2: *const ::std::os::raw::c_void, - __len: usize, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn strsignal_r( - __sig: ::std::os::raw::c_int, - __strsignalbuf: *mut ::std::os::raw::c_char, - __buflen: usize, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn bcmp( - arg1: *const ::std::os::raw::c_void, - arg2: *const ::std::os::raw::c_void, - arg3: ::std::os::raw::c_ulong, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn bcopy( - arg1: *const ::std::os::raw::c_void, - arg2: *mut ::std::os::raw::c_void, - arg3: usize, - ); -} -extern "C" { - pub fn bzero(arg1: *mut ::std::os::raw::c_void, arg2: ::std::os::raw::c_ulong); -} -extern "C" { - pub fn index( - arg1: *const ::std::os::raw::c_char, - arg2: ::std::os::raw::c_int, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn rindex( - arg1: *const ::std::os::raw::c_char, - arg2: ::std::os::raw::c_int, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn ffs(arg1: ::std::os::raw::c_int) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn strcasecmp( - arg1: *const ::std::os::raw::c_char, - arg2: *const ::std::os::raw::c_char, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn strncasecmp( - arg1: *const ::std::os::raw::c_char, - arg2: *const ::std::os::raw::c_char, - arg3: ::std::os::raw::c_ulong, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn ffsl(arg1: ::std::os::raw::c_long) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn ffsll(arg1: ::std::os::raw::c_longlong) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn fls(arg1: ::std::os::raw::c_int) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn flsl(arg1: ::std::os::raw::c_long) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn flsll(arg1: ::std::os::raw::c_longlong) -> ::std::os::raw::c_int; -} -#[repr(u32)] -#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum ONNXTensorElementDataType { - ONNX_TENSOR_ELEMENT_DATA_TYPE_UNDEFINED = 0, - ONNX_TENSOR_ELEMENT_DATA_TYPE_FLOAT = 1, - ONNX_TENSOR_ELEMENT_DATA_TYPE_UINT8 = 2, - ONNX_TENSOR_ELEMENT_DATA_TYPE_INT8 = 3, - ONNX_TENSOR_ELEMENT_DATA_TYPE_UINT16 = 4, - ONNX_TENSOR_ELEMENT_DATA_TYPE_INT16 = 5, - ONNX_TENSOR_ELEMENT_DATA_TYPE_INT32 = 6, - ONNX_TENSOR_ELEMENT_DATA_TYPE_INT64 = 7, - ONNX_TENSOR_ELEMENT_DATA_TYPE_STRING = 8, - ONNX_TENSOR_ELEMENT_DATA_TYPE_BOOL = 9, - ONNX_TENSOR_ELEMENT_DATA_TYPE_FLOAT16 = 10, - ONNX_TENSOR_ELEMENT_DATA_TYPE_DOUBLE = 11, - ONNX_TENSOR_ELEMENT_DATA_TYPE_UINT32 = 12, - ONNX_TENSOR_ELEMENT_DATA_TYPE_UINT64 = 13, - ONNX_TENSOR_ELEMENT_DATA_TYPE_COMPLEX64 = 14, - ONNX_TENSOR_ELEMENT_DATA_TYPE_COMPLEX128 = 15, - ONNX_TENSOR_ELEMENT_DATA_TYPE_BFLOAT16 = 16, -} -#[repr(u32)] -#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum ONNXType { - ONNX_TYPE_UNKNOWN = 0, - ONNX_TYPE_TENSOR = 1, - ONNX_TYPE_SEQUENCE = 2, - ONNX_TYPE_MAP = 3, - ONNX_TYPE_OPAQUE = 4, - ONNX_TYPE_SPARSETENSOR = 5, -} -#[repr(u32)] -#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum OrtLoggingLevel { - ORT_LOGGING_LEVEL_VERBOSE = 0, - ORT_LOGGING_LEVEL_INFO = 1, - ORT_LOGGING_LEVEL_WARNING = 2, - ORT_LOGGING_LEVEL_ERROR = 3, - ORT_LOGGING_LEVEL_FATAL = 4, -} -#[repr(u32)] -#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum OrtErrorCode { - ORT_OK = 0, - ORT_FAIL = 1, - ORT_INVALID_ARGUMENT = 2, - ORT_NO_SUCHFILE = 3, - ORT_NO_MODEL = 4, - ORT_ENGINE_ERROR = 5, - ORT_RUNTIME_EXCEPTION = 6, - ORT_INVALID_PROTOBUF = 7, - ORT_MODEL_LOADED = 8, - ORT_NOT_IMPLEMENTED = 9, - ORT_INVALID_GRAPH = 10, - ORT_EP_FAIL = 11, -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtEnv { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtStatus { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtMemoryInfo { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtIoBinding { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtSession { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtValue { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtRunOptions { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtTypeInfo { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtTensorTypeAndShapeInfo { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtSessionOptions { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtCustomOpDomain { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtMapTypeInfo { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtSequenceTypeInfo { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtModelMetadata { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtThreadPoolParams { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtThreadingOptions { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtArenaCfg { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtPrepackedWeightsContainer { - _unused: [u8; 0], -} -pub type OrtStatusPtr = *mut OrtStatus; -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtAllocator { - pub version: u32, - pub Alloc: ::std::option::Option< - unsafe extern "C" fn(this_: *mut OrtAllocator, size: usize) -> *mut ::std::os::raw::c_void, - >, - pub Free: ::std::option::Option< - unsafe extern "C" fn(this_: *mut OrtAllocator, p: *mut ::std::os::raw::c_void), - >, - pub Info: ::std::option::Option< - unsafe extern "C" fn(this_: *const OrtAllocator) -> *const OrtMemoryInfo, - >, -} -#[test] -fn bindgen_test_layout_OrtAllocator() { - assert_eq!( - ::std::mem::size_of::(), - 32usize, - concat!("Size of: ", stringify!(OrtAllocator)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(OrtAllocator)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).version as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtAllocator), - "::", - stringify!(version) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).Alloc as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtAllocator), - "::", - stringify!(Alloc) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).Free as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(OrtAllocator), - "::", - stringify!(Free) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).Info as *const _ as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(OrtAllocator), - "::", - stringify!(Info) - ) - ); -} -pub type OrtLoggingFunction = ::std::option::Option< - unsafe extern "C" fn( - param: *mut ::std::os::raw::c_void, - severity: OrtLoggingLevel, - category: *const ::std::os::raw::c_char, - logid: *const ::std::os::raw::c_char, - code_location: *const ::std::os::raw::c_char, - message: *const ::std::os::raw::c_char, - ), ->; -#[repr(u32)] -#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum GraphOptimizationLevel { - ORT_DISABLE_ALL = 0, - ORT_ENABLE_BASIC = 1, - ORT_ENABLE_EXTENDED = 2, - ORT_ENABLE_ALL = 99, -} -#[repr(u32)] -#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum ExecutionMode { - ORT_SEQUENTIAL = 0, - ORT_PARALLEL = 1, -} -#[repr(u32)] -#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum OrtLanguageProjection { - ORT_PROJECTION_C = 0, - ORT_PROJECTION_CPLUSPLUS = 1, - ORT_PROJECTION_CSHARP = 2, - ORT_PROJECTION_PYTHON = 3, - ORT_PROJECTION_JAVA = 4, - ORT_PROJECTION_WINML = 5, - ORT_PROJECTION_NODEJS = 6, -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtKernelInfo { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtKernelContext { - _unused: [u8; 0], -} -#[repr(i32)] -#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum OrtAllocatorType { - Invalid = -1, - OrtDeviceAllocator = 0, - OrtArenaAllocator = 1, -} -impl OrtMemType { - pub const OrtMemTypeCPU: OrtMemType = OrtMemType::OrtMemTypeCPUOutput; -} -#[repr(i32)] -#[doc = " memory types for allocator, exec provider specific types should be extended in each provider"] -#[doc = " Whenever this struct is updated, please also update the MakeKey function in onnxruntime/core/framework/execution_provider.cc"] -#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum OrtMemType { - OrtMemTypeCPUInput = -2, - OrtMemTypeCPUOutput = -1, - OrtMemTypeDefault = 0, -} -#[repr(u32)] -#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum OrtCudnnConvAlgoSearch { - EXHAUSTIVE = 0, - HEURISTIC = 1, - DEFAULT = 2, -} -#[doc = " "] -#[doc = " Options for the CUDA provider that are passed to SessionOptionsAppendExecutionProvider_CUDA"] -#[doc = " "] -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtCUDAProviderOptions { - pub device_id: ::std::os::raw::c_int, - pub cudnn_conv_algo_search: OrtCudnnConvAlgoSearch, - pub gpu_mem_limit: usize, - pub arena_extend_strategy: ::std::os::raw::c_int, - pub do_copy_in_default_stream: ::std::os::raw::c_int, - pub has_user_compute_stream: ::std::os::raw::c_int, - pub user_compute_stream: *mut ::std::os::raw::c_void, - pub default_memory_arena_cfg: *mut OrtArenaCfg, -} -#[test] -fn bindgen_test_layout_OrtCUDAProviderOptions() { - assert_eq!( - ::std::mem::size_of::(), - 48usize, - concat!("Size of: ", stringify!(OrtCUDAProviderOptions)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(OrtCUDAProviderOptions)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).device_id as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(device_id) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).cudnn_conv_algo_search as *const _ - as usize - }, - 4usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(cudnn_conv_algo_search) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).gpu_mem_limit as *const _ as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(gpu_mem_limit) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).arena_extend_strategy as *const _ - as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(arena_extend_strategy) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).do_copy_in_default_stream as *const _ - as usize - }, - 20usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(do_copy_in_default_stream) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).has_user_compute_stream as *const _ - as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(has_user_compute_stream) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).user_compute_stream as *const _ - as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(user_compute_stream) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).default_memory_arena_cfg as *const _ - as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(default_memory_arena_cfg) - ) - ); -} -#[doc = " "] -#[doc = " Options for the ROCM provider that are passed to SessionOptionsAppendExecutionProvider_ROCM"] -#[doc = " "] -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtROCMProviderOptions { - pub device_id: ::std::os::raw::c_int, - pub miopen_conv_exhaustive_search: ::std::os::raw::c_int, - pub gpu_mem_limit: usize, - pub arena_extend_strategy: ::std::os::raw::c_int, -} -#[test] -fn bindgen_test_layout_OrtROCMProviderOptions() { - assert_eq!( - ::std::mem::size_of::(), - 24usize, - concat!("Size of: ", stringify!(OrtROCMProviderOptions)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(OrtROCMProviderOptions)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).device_id as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtROCMProviderOptions), - "::", - stringify!(device_id) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).miopen_conv_exhaustive_search - as *const _ as usize - }, - 4usize, - concat!( - "Offset of field: ", - stringify!(OrtROCMProviderOptions), - "::", - stringify!(miopen_conv_exhaustive_search) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).gpu_mem_limit as *const _ as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtROCMProviderOptions), - "::", - stringify!(gpu_mem_limit) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).arena_extend_strategy as *const _ - as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(OrtROCMProviderOptions), - "::", - stringify!(arena_extend_strategy) - ) - ); -} -#[doc = " "] -#[doc = " Options for the TensorRT provider that are passed to SessionOptionsAppendExecutionProvider_TensorRT"] -#[doc = " "] -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtTensorRTProviderOptions { - pub device_id: ::std::os::raw::c_int, - pub has_user_compute_stream: ::std::os::raw::c_int, - pub user_compute_stream: *mut ::std::os::raw::c_void, - pub trt_max_partition_iterations: ::std::os::raw::c_int, - pub trt_min_subgraph_size: ::std::os::raw::c_int, - pub trt_max_workspace_size: usize, - pub trt_fp16_enable: ::std::os::raw::c_int, - pub trt_int8_enable: ::std::os::raw::c_int, - pub trt_int8_calibration_table_name: *const ::std::os::raw::c_char, - pub trt_int8_use_native_calibration_table: ::std::os::raw::c_int, - pub trt_dla_enable: ::std::os::raw::c_int, - pub trt_dla_core: ::std::os::raw::c_int, - pub trt_dump_subgraphs: ::std::os::raw::c_int, - pub trt_engine_cache_enable: ::std::os::raw::c_int, - pub trt_engine_cache_path: *const ::std::os::raw::c_char, - pub trt_engine_decryption_enable: ::std::os::raw::c_int, - pub trt_engine_decryption_lib_path: *const ::std::os::raw::c_char, - pub trt_force_sequential_engine_build: ::std::os::raw::c_int, -} -#[test] -fn bindgen_test_layout_OrtTensorRTProviderOptions() { - assert_eq!( - ::std::mem::size_of::(), - 104usize, - concat!("Size of: ", stringify!(OrtTensorRTProviderOptions)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(OrtTensorRTProviderOptions)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).device_id as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(device_id) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).has_user_compute_stream - as *const _ as usize - }, - 4usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(has_user_compute_stream) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).user_compute_stream as *const _ - as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(user_compute_stream) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_max_partition_iterations - as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_max_partition_iterations) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_min_subgraph_size as *const _ - as usize - }, - 20usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_min_subgraph_size) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_max_workspace_size - as *const _ as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_max_workspace_size) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_fp16_enable as *const _ - as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_fp16_enable) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_int8_enable as *const _ - as usize - }, - 36usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_int8_enable) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_int8_calibration_table_name - as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_int8_calibration_table_name) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())) - .trt_int8_use_native_calibration_table as *const _ as usize - }, - 48usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_int8_use_native_calibration_table) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_dla_enable as *const _ - as usize - }, - 52usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_dla_enable) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_dla_core as *const _ as usize - }, - 56usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_dla_core) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_dump_subgraphs as *const _ - as usize - }, - 60usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_dump_subgraphs) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_engine_cache_enable - as *const _ as usize - }, - 64usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_engine_cache_enable) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_engine_cache_path as *const _ - as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_engine_cache_path) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_engine_decryption_enable - as *const _ as usize - }, - 80usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_engine_decryption_enable) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_engine_decryption_lib_path - as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_engine_decryption_lib_path) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_force_sequential_engine_build - as *const _ as usize - }, - 96usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_force_sequential_engine_build) - ) - ); -} -#[doc = " "] -#[doc = " Options for the OpenVINO provider that are passed to SessionOptionsAppendExecutionProvider_OpenVINO"] -#[doc = " "] -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtOpenVINOProviderOptions { - pub device_type: *const ::std::os::raw::c_char, - pub enable_vpu_fast_compile: ::std::os::raw::c_uchar, - pub device_id: *const ::std::os::raw::c_char, - pub num_of_threads: usize, - pub use_compiled_network: ::std::os::raw::c_uchar, - pub blob_dump_path: *const ::std::os::raw::c_char, -} -#[test] -fn bindgen_test_layout_OrtOpenVINOProviderOptions() { - assert_eq!( - ::std::mem::size_of::(), - 48usize, - concat!("Size of: ", stringify!(OrtOpenVINOProviderOptions)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(OrtOpenVINOProviderOptions)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).device_type as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtOpenVINOProviderOptions), - "::", - stringify!(device_type) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).enable_vpu_fast_compile - as *const _ as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtOpenVINOProviderOptions), - "::", - stringify!(enable_vpu_fast_compile) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).device_id as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(OrtOpenVINOProviderOptions), - "::", - stringify!(device_id) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).num_of_threads as *const _ - as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(OrtOpenVINOProviderOptions), - "::", - stringify!(num_of_threads) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).use_compiled_network as *const _ - as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(OrtOpenVINOProviderOptions), - "::", - stringify!(use_compiled_network) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).blob_dump_path as *const _ - as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(OrtOpenVINOProviderOptions), - "::", - stringify!(blob_dump_path) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtApiBase { - pub GetApi: ::std::option::Option *const OrtApi>, - pub GetVersionString: - ::std::option::Option *const ::std::os::raw::c_char>, -} -#[test] -fn bindgen_test_layout_OrtApiBase() { - assert_eq!( - ::std::mem::size_of::(), - 16usize, - concat!("Size of: ", stringify!(OrtApiBase)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(OrtApiBase)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetApi as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtApiBase), - "::", - stringify!(GetApi) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetVersionString as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtApiBase), - "::", - stringify!(GetVersionString) - ) - ); -} -extern "C" { - pub fn OrtGetApiBase() -> *const OrtApiBase; -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtApi { - #[doc = " \\param msg A null-terminated string. Its content will be copied into the newly created OrtStatus"] - pub CreateStatus: ::std::option::Option< - unsafe extern "C" fn( - code: OrtErrorCode, - msg: *const ::std::os::raw::c_char, - ) -> *mut OrtStatus, - >, - pub GetErrorCode: - ::std::option::Option OrtErrorCode>, - #[doc = " \\param status must not be NULL"] - #[doc = " \\return The error message inside the `status`. Do not free the returned value."] - pub GetErrorMessage: ::std::option::Option< - unsafe extern "C" fn(status: *const OrtStatus) -> *const ::std::os::raw::c_char, - >, - pub CreateEnv: ::std::option::Option< - unsafe extern "C" fn( - logging_level: OrtLoggingLevel, - logid: *const ::std::os::raw::c_char, - out: *mut *mut OrtEnv, - ) -> OrtStatusPtr, - >, - pub CreateEnvWithCustomLogger: ::std::option::Option< - unsafe extern "C" fn( - logging_function: OrtLoggingFunction, - logger_param: *mut ::std::os::raw::c_void, - logging_level: OrtLoggingLevel, - logid: *const ::std::os::raw::c_char, - out: *mut *mut OrtEnv, - ) -> OrtStatusPtr, - >, - pub EnableTelemetryEvents: - ::std::option::Option OrtStatusPtr>, - pub DisableTelemetryEvents: - ::std::option::Option OrtStatusPtr>, - pub CreateSession: ::std::option::Option< - unsafe extern "C" fn( - env: *const OrtEnv, - model_path: *const ::std::os::raw::c_char, - options: *const OrtSessionOptions, - out: *mut *mut OrtSession, - ) -> OrtStatusPtr, - >, - pub CreateSessionFromArray: ::std::option::Option< - unsafe extern "C" fn( - env: *const OrtEnv, - model_data: *const ::std::os::raw::c_void, - model_data_length: usize, - options: *const OrtSessionOptions, - out: *mut *mut OrtSession, - ) -> OrtStatusPtr, - >, - pub Run: ::std::option::Option< - unsafe extern "C" fn( - sess: *mut OrtSession, - run_options: *const OrtRunOptions, - input_names: *const *const ::std::os::raw::c_char, - input: *const *const OrtValue, - input_len: usize, - output_names1: *const *const ::std::os::raw::c_char, - output_names_len: usize, - output: *mut *mut OrtValue, - ) -> OrtStatusPtr, - >, - pub CreateSessionOptions: ::std::option::Option< - unsafe extern "C" fn(options: *mut *mut OrtSessionOptions) -> OrtStatusPtr, - >, - pub SetOptimizedModelFilePath: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - optimized_model_filepath: *const ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub CloneSessionOptions: ::std::option::Option< - unsafe extern "C" fn( - in_options: *const OrtSessionOptions, - out_options: *mut *mut OrtSessionOptions, - ) -> OrtStatusPtr, - >, - pub SetSessionExecutionMode: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - execution_mode: ExecutionMode, - ) -> OrtStatusPtr, - >, - pub EnableProfiling: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - profile_file_prefix: *const ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub DisableProfiling: ::std::option::Option< - unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, - >, - pub EnableMemPattern: ::std::option::Option< - unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, - >, - pub DisableMemPattern: ::std::option::Option< - unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, - >, - pub EnableCpuMemArena: ::std::option::Option< - unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, - >, - pub DisableCpuMemArena: ::std::option::Option< - unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, - >, - pub SetSessionLogId: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - logid: *const ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub SetSessionLogVerbosityLevel: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - session_log_verbosity_level: ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub SetSessionLogSeverityLevel: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - session_log_severity_level: ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub SetSessionGraphOptimizationLevel: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - graph_optimization_level: GraphOptimizationLevel, - ) -> OrtStatusPtr, - >, - pub SetIntraOpNumThreads: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - intra_op_num_threads: ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub SetInterOpNumThreads: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - inter_op_num_threads: ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub CreateCustomOpDomain: ::std::option::Option< - unsafe extern "C" fn( - domain: *const ::std::os::raw::c_char, - out: *mut *mut OrtCustomOpDomain, - ) -> OrtStatusPtr, - >, - pub CustomOpDomain_Add: ::std::option::Option< - unsafe extern "C" fn( - custom_op_domain: *mut OrtCustomOpDomain, - op: *const OrtCustomOp, - ) -> OrtStatusPtr, - >, - pub AddCustomOpDomain: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - custom_op_domain: *mut OrtCustomOpDomain, - ) -> OrtStatusPtr, - >, - pub RegisterCustomOpsLibrary: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - library_path: *const ::std::os::raw::c_char, - library_handle: *mut *mut ::std::os::raw::c_void, - ) -> OrtStatusPtr, - >, - pub SessionGetInputCount: ::std::option::Option< - unsafe extern "C" fn(sess: *const OrtSession, out: *mut usize) -> OrtStatusPtr, - >, - pub SessionGetOutputCount: ::std::option::Option< - unsafe extern "C" fn(sess: *const OrtSession, out: *mut usize) -> OrtStatusPtr, - >, - pub SessionGetOverridableInitializerCount: ::std::option::Option< - unsafe extern "C" fn(sess: *const OrtSession, out: *mut usize) -> OrtStatusPtr, - >, - pub SessionGetInputTypeInfo: ::std::option::Option< - unsafe extern "C" fn( - sess: *const OrtSession, - index: usize, - type_info: *mut *mut OrtTypeInfo, - ) -> OrtStatusPtr, - >, - pub SessionGetOutputTypeInfo: ::std::option::Option< - unsafe extern "C" fn( - sess: *const OrtSession, - index: usize, - type_info: *mut *mut OrtTypeInfo, - ) -> OrtStatusPtr, - >, - pub SessionGetOverridableInitializerTypeInfo: ::std::option::Option< - unsafe extern "C" fn( - sess: *const OrtSession, - index: usize, - type_info: *mut *mut OrtTypeInfo, - ) -> OrtStatusPtr, - >, - pub SessionGetInputName: ::std::option::Option< - unsafe extern "C" fn( - sess: *const OrtSession, - index: usize, - allocator: *mut OrtAllocator, - value: *mut *mut ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub SessionGetOutputName: ::std::option::Option< - unsafe extern "C" fn( - sess: *const OrtSession, - index: usize, - allocator: *mut OrtAllocator, - value: *mut *mut ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub SessionGetOverridableInitializerName: ::std::option::Option< - unsafe extern "C" fn( - sess: *const OrtSession, - index: usize, - allocator: *mut OrtAllocator, - value: *mut *mut ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub CreateRunOptions: - ::std::option::Option OrtStatusPtr>, - pub RunOptionsSetRunLogVerbosityLevel: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtRunOptions, - value: ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub RunOptionsSetRunLogSeverityLevel: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtRunOptions, - value: ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub RunOptionsSetRunTag: ::std::option::Option< - unsafe extern "C" fn( - arg1: *mut OrtRunOptions, - run_tag: *const ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub RunOptionsGetRunLogVerbosityLevel: ::std::option::Option< - unsafe extern "C" fn( - options: *const OrtRunOptions, - out: *mut ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub RunOptionsGetRunLogSeverityLevel: ::std::option::Option< - unsafe extern "C" fn( - options: *const OrtRunOptions, - out: *mut ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub RunOptionsGetRunTag: ::std::option::Option< - unsafe extern "C" fn( - arg1: *const OrtRunOptions, - out: *mut *const ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub RunOptionsSetTerminate: - ::std::option::Option OrtStatusPtr>, - pub RunOptionsUnsetTerminate: - ::std::option::Option OrtStatusPtr>, - pub CreateTensorAsOrtValue: ::std::option::Option< - unsafe extern "C" fn( - allocator: *mut OrtAllocator, - shape: *const i64, - shape_len: usize, - type_: ONNXTensorElementDataType, - out: *mut *mut OrtValue, - ) -> OrtStatusPtr, - >, - pub CreateTensorWithDataAsOrtValue: ::std::option::Option< - unsafe extern "C" fn( - info: *const OrtMemoryInfo, - p_data: *mut ::std::os::raw::c_void, - p_data_len: usize, - shape: *const i64, - shape_len: usize, - type_: ONNXTensorElementDataType, - out: *mut *mut OrtValue, - ) -> OrtStatusPtr, - >, - pub IsTensor: ::std::option::Option< - unsafe extern "C" fn( - value: *const OrtValue, - out: *mut ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub GetTensorMutableData: ::std::option::Option< - unsafe extern "C" fn( - value: *mut OrtValue, - out: *mut *mut ::std::os::raw::c_void, - ) -> OrtStatusPtr, - >, - pub FillStringTensor: ::std::option::Option< - unsafe extern "C" fn( - value: *mut OrtValue, - s: *const *const ::std::os::raw::c_char, - s_len: usize, - ) -> OrtStatusPtr, - >, - pub GetStringTensorDataLength: ::std::option::Option< - unsafe extern "C" fn(value: *const OrtValue, len: *mut usize) -> OrtStatusPtr, - >, - pub GetStringTensorContent: ::std::option::Option< - unsafe extern "C" fn( - value: *const OrtValue, - s: *mut ::std::os::raw::c_void, - s_len: usize, - offsets: *mut usize, - offsets_len: usize, - ) -> OrtStatusPtr, - >, - pub CastTypeInfoToTensorInfo: ::std::option::Option< - unsafe extern "C" fn( - arg1: *const OrtTypeInfo, - out: *mut *const OrtTensorTypeAndShapeInfo, - ) -> OrtStatusPtr, - >, - pub GetOnnxTypeFromTypeInfo: ::std::option::Option< - unsafe extern "C" fn(arg1: *const OrtTypeInfo, out: *mut ONNXType) -> OrtStatusPtr, - >, - pub CreateTensorTypeAndShapeInfo: ::std::option::Option< - unsafe extern "C" fn(out: *mut *mut OrtTensorTypeAndShapeInfo) -> OrtStatusPtr, - >, - pub SetTensorElementType: ::std::option::Option< - unsafe extern "C" fn( - arg1: *mut OrtTensorTypeAndShapeInfo, - type_: ONNXTensorElementDataType, - ) -> OrtStatusPtr, - >, - pub SetDimensions: ::std::option::Option< - unsafe extern "C" fn( - info: *mut OrtTensorTypeAndShapeInfo, - dim_values: *const i64, - dim_count: usize, - ) -> OrtStatusPtr, - >, - pub GetTensorElementType: ::std::option::Option< - unsafe extern "C" fn( - arg1: *const OrtTensorTypeAndShapeInfo, - out: *mut ONNXTensorElementDataType, - ) -> OrtStatusPtr, - >, - pub GetDimensionsCount: ::std::option::Option< - unsafe extern "C" fn( - info: *const OrtTensorTypeAndShapeInfo, - out: *mut usize, - ) -> OrtStatusPtr, - >, - pub GetDimensions: ::std::option::Option< - unsafe extern "C" fn( - info: *const OrtTensorTypeAndShapeInfo, - dim_values: *mut i64, - dim_values_length: usize, - ) -> OrtStatusPtr, - >, - pub GetSymbolicDimensions: ::std::option::Option< - unsafe extern "C" fn( - info: *const OrtTensorTypeAndShapeInfo, - dim_params: *mut *const ::std::os::raw::c_char, - dim_params_length: usize, - ) -> OrtStatusPtr, - >, - pub GetTensorShapeElementCount: ::std::option::Option< - unsafe extern "C" fn( - info: *const OrtTensorTypeAndShapeInfo, - out: *mut usize, - ) -> OrtStatusPtr, - >, - pub GetTensorTypeAndShape: ::std::option::Option< - unsafe extern "C" fn( - value: *const OrtValue, - out: *mut *mut OrtTensorTypeAndShapeInfo, - ) -> OrtStatusPtr, - >, - pub GetTypeInfo: ::std::option::Option< - unsafe extern "C" fn(value: *const OrtValue, out: *mut *mut OrtTypeInfo) -> OrtStatusPtr, - >, - pub GetValueType: ::std::option::Option< - unsafe extern "C" fn(value: *const OrtValue, out: *mut ONNXType) -> OrtStatusPtr, - >, - pub CreateMemoryInfo: ::std::option::Option< - unsafe extern "C" fn( - name1: *const ::std::os::raw::c_char, - type_: OrtAllocatorType, - id1: ::std::os::raw::c_int, - mem_type1: OrtMemType, - out: *mut *mut OrtMemoryInfo, - ) -> OrtStatusPtr, - >, - pub CreateCpuMemoryInfo: ::std::option::Option< - unsafe extern "C" fn( - type_: OrtAllocatorType, - mem_type1: OrtMemType, - out: *mut *mut OrtMemoryInfo, - ) -> OrtStatusPtr, - >, - pub CompareMemoryInfo: ::std::option::Option< - unsafe extern "C" fn( - info1: *const OrtMemoryInfo, - info2: *const OrtMemoryInfo, - out: *mut ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub MemoryInfoGetName: ::std::option::Option< - unsafe extern "C" fn( - ptr: *const OrtMemoryInfo, - out: *mut *const ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub MemoryInfoGetId: ::std::option::Option< - unsafe extern "C" fn( - ptr: *const OrtMemoryInfo, - out: *mut ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub MemoryInfoGetMemType: ::std::option::Option< - unsafe extern "C" fn(ptr: *const OrtMemoryInfo, out: *mut OrtMemType) -> OrtStatusPtr, - >, - pub MemoryInfoGetType: ::std::option::Option< - unsafe extern "C" fn(ptr: *const OrtMemoryInfo, out: *mut OrtAllocatorType) -> OrtStatusPtr, - >, - pub AllocatorAlloc: ::std::option::Option< - unsafe extern "C" fn( - ptr: *mut OrtAllocator, - size: usize, - out: *mut *mut ::std::os::raw::c_void, - ) -> OrtStatusPtr, - >, - pub AllocatorFree: ::std::option::Option< - unsafe extern "C" fn( - ptr: *mut OrtAllocator, - p: *mut ::std::os::raw::c_void, - ) -> OrtStatusPtr, - >, - pub AllocatorGetInfo: ::std::option::Option< - unsafe extern "C" fn( - ptr: *const OrtAllocator, - out: *mut *const OrtMemoryInfo, - ) -> OrtStatusPtr, - >, - pub GetAllocatorWithDefaultOptions: - ::std::option::Option OrtStatusPtr>, - pub AddFreeDimensionOverride: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - dim_denotation: *const ::std::os::raw::c_char, - dim_value: i64, - ) -> OrtStatusPtr, - >, - pub GetValue: ::std::option::Option< - unsafe extern "C" fn( - value: *const OrtValue, - index: ::std::os::raw::c_int, - allocator: *mut OrtAllocator, - out: *mut *mut OrtValue, - ) -> OrtStatusPtr, - >, - pub GetValueCount: ::std::option::Option< - unsafe extern "C" fn(value: *const OrtValue, out: *mut usize) -> OrtStatusPtr, - >, - pub CreateValue: ::std::option::Option< - unsafe extern "C" fn( - in_: *const *const OrtValue, - num_values: usize, - value_type: ONNXType, - out: *mut *mut OrtValue, - ) -> OrtStatusPtr, - >, - pub CreateOpaqueValue: ::std::option::Option< - unsafe extern "C" fn( - domain_name: *const ::std::os::raw::c_char, - type_name: *const ::std::os::raw::c_char, - data_container: *const ::std::os::raw::c_void, - data_container_size: usize, - out: *mut *mut OrtValue, - ) -> OrtStatusPtr, - >, - pub GetOpaqueValue: ::std::option::Option< - unsafe extern "C" fn( - domain_name: *const ::std::os::raw::c_char, - type_name: *const ::std::os::raw::c_char, - in_: *const OrtValue, - data_container: *mut ::std::os::raw::c_void, - data_container_size: usize, - ) -> OrtStatusPtr, - >, - pub KernelInfoGetAttribute_float: ::std::option::Option< - unsafe extern "C" fn( - info: *const OrtKernelInfo, - name: *const ::std::os::raw::c_char, - out: *mut f32, - ) -> OrtStatusPtr, - >, - pub KernelInfoGetAttribute_int64: ::std::option::Option< - unsafe extern "C" fn( - info: *const OrtKernelInfo, - name: *const ::std::os::raw::c_char, - out: *mut i64, - ) -> OrtStatusPtr, - >, - pub KernelInfoGetAttribute_string: ::std::option::Option< - unsafe extern "C" fn( - info: *const OrtKernelInfo, - name: *const ::std::os::raw::c_char, - out: *mut ::std::os::raw::c_char, - size: *mut usize, - ) -> OrtStatusPtr, - >, - pub KernelContext_GetInputCount: ::std::option::Option< - unsafe extern "C" fn(context: *const OrtKernelContext, out: *mut usize) -> OrtStatusPtr, - >, - pub KernelContext_GetOutputCount: ::std::option::Option< - unsafe extern "C" fn(context: *const OrtKernelContext, out: *mut usize) -> OrtStatusPtr, - >, - pub KernelContext_GetInput: ::std::option::Option< - unsafe extern "C" fn( - context: *const OrtKernelContext, - index: usize, - out: *mut *const OrtValue, - ) -> OrtStatusPtr, - >, - pub KernelContext_GetOutput: ::std::option::Option< - unsafe extern "C" fn( - context: *mut OrtKernelContext, - index: usize, - dim_values: *const i64, - dim_count: usize, - out: *mut *mut OrtValue, - ) -> OrtStatusPtr, - >, - pub ReleaseEnv: ::std::option::Option, - pub ReleaseStatus: ::std::option::Option, - pub ReleaseMemoryInfo: ::std::option::Option, - pub ReleaseSession: ::std::option::Option, - pub ReleaseValue: ::std::option::Option, - pub ReleaseRunOptions: ::std::option::Option, - pub ReleaseTypeInfo: ::std::option::Option, - pub ReleaseTensorTypeAndShapeInfo: - ::std::option::Option, - pub ReleaseSessionOptions: - ::std::option::Option, - pub ReleaseCustomOpDomain: - ::std::option::Option, - pub GetDenotationFromTypeInfo: ::std::option::Option< - unsafe extern "C" fn( - arg1: *const OrtTypeInfo, - denotation: *mut *const ::std::os::raw::c_char, - len: *mut usize, - ) -> OrtStatusPtr, - >, - pub CastTypeInfoToMapTypeInfo: ::std::option::Option< - unsafe extern "C" fn( - type_info: *const OrtTypeInfo, - out: *mut *const OrtMapTypeInfo, - ) -> OrtStatusPtr, - >, - pub CastTypeInfoToSequenceTypeInfo: ::std::option::Option< - unsafe extern "C" fn( - type_info: *const OrtTypeInfo, - out: *mut *const OrtSequenceTypeInfo, - ) -> OrtStatusPtr, - >, - pub GetMapKeyType: ::std::option::Option< - unsafe extern "C" fn( - map_type_info: *const OrtMapTypeInfo, - out: *mut ONNXTensorElementDataType, - ) -> OrtStatusPtr, - >, - pub GetMapValueType: ::std::option::Option< - unsafe extern "C" fn( - map_type_info: *const OrtMapTypeInfo, - type_info: *mut *mut OrtTypeInfo, - ) -> OrtStatusPtr, - >, - pub GetSequenceElementType: ::std::option::Option< - unsafe extern "C" fn( - sequence_type_info: *const OrtSequenceTypeInfo, - type_info: *mut *mut OrtTypeInfo, - ) -> OrtStatusPtr, - >, - pub ReleaseMapTypeInfo: ::std::option::Option, - pub ReleaseSequenceTypeInfo: - ::std::option::Option, - pub SessionEndProfiling: ::std::option::Option< - unsafe extern "C" fn( - sess: *mut OrtSession, - allocator: *mut OrtAllocator, - out: *mut *mut ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub SessionGetModelMetadata: ::std::option::Option< - unsafe extern "C" fn( - sess: *const OrtSession, - out: *mut *mut OrtModelMetadata, - ) -> OrtStatusPtr, - >, - pub ModelMetadataGetProducerName: ::std::option::Option< - unsafe extern "C" fn( - model_metadata: *const OrtModelMetadata, - allocator: *mut OrtAllocator, - value: *mut *mut ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub ModelMetadataGetGraphName: ::std::option::Option< - unsafe extern "C" fn( - model_metadata: *const OrtModelMetadata, - allocator: *mut OrtAllocator, - value: *mut *mut ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub ModelMetadataGetDomain: ::std::option::Option< - unsafe extern "C" fn( - model_metadata: *const OrtModelMetadata, - allocator: *mut OrtAllocator, - value: *mut *mut ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub ModelMetadataGetDescription: ::std::option::Option< - unsafe extern "C" fn( - model_metadata: *const OrtModelMetadata, - allocator: *mut OrtAllocator, - value: *mut *mut ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub ModelMetadataLookupCustomMetadataMap: ::std::option::Option< - unsafe extern "C" fn( - model_metadata: *const OrtModelMetadata, - allocator: *mut OrtAllocator, - key: *const ::std::os::raw::c_char, - value: *mut *mut ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub ModelMetadataGetVersion: ::std::option::Option< - unsafe extern "C" fn( - model_metadata: *const OrtModelMetadata, - value: *mut i64, - ) -> OrtStatusPtr, - >, - pub ReleaseModelMetadata: - ::std::option::Option, - pub CreateEnvWithGlobalThreadPools: ::std::option::Option< - unsafe extern "C" fn( - logging_level: OrtLoggingLevel, - logid: *const ::std::os::raw::c_char, - t_options: *const OrtThreadingOptions, - out: *mut *mut OrtEnv, - ) -> OrtStatusPtr, - >, - pub DisablePerSessionThreads: ::std::option::Option< - unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, - >, - pub CreateThreadingOptions: ::std::option::Option< - unsafe extern "C" fn(out: *mut *mut OrtThreadingOptions) -> OrtStatusPtr, - >, - pub ReleaseThreadingOptions: - ::std::option::Option, - pub ModelMetadataGetCustomMetadataMapKeys: ::std::option::Option< - unsafe extern "C" fn( - model_metadata: *const OrtModelMetadata, - allocator: *mut OrtAllocator, - keys: *mut *mut *mut ::std::os::raw::c_char, - num_keys: *mut i64, - ) -> OrtStatusPtr, - >, - pub AddFreeDimensionOverrideByName: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - dim_name: *const ::std::os::raw::c_char, - dim_value: i64, - ) -> OrtStatusPtr, - >, - pub GetAvailableProviders: ::std::option::Option< - unsafe extern "C" fn( - out_ptr: *mut *mut *mut ::std::os::raw::c_char, - provider_length: *mut ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub ReleaseAvailableProviders: ::std::option::Option< - unsafe extern "C" fn( - ptr: *mut *mut ::std::os::raw::c_char, - providers_length: ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub GetStringTensorElementLength: ::std::option::Option< - unsafe extern "C" fn(value: *const OrtValue, index: usize, out: *mut usize) -> OrtStatusPtr, - >, - pub GetStringTensorElement: ::std::option::Option< - unsafe extern "C" fn( - value: *const OrtValue, - s_len: usize, - index: usize, - s: *mut ::std::os::raw::c_void, - ) -> OrtStatusPtr, - >, - pub FillStringTensorElement: ::std::option::Option< - unsafe extern "C" fn( - value: *mut OrtValue, - s: *const ::std::os::raw::c_char, - index: usize, - ) -> OrtStatusPtr, - >, - pub AddSessionConfigEntry: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - config_key: *const ::std::os::raw::c_char, - config_value: *const ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub CreateAllocator: ::std::option::Option< - unsafe extern "C" fn( - sess: *const OrtSession, - mem_info: *const OrtMemoryInfo, - out: *mut *mut OrtAllocator, - ) -> OrtStatusPtr, - >, - pub ReleaseAllocator: ::std::option::Option, - pub RunWithBinding: ::std::option::Option< - unsafe extern "C" fn( - sess: *mut OrtSession, - run_options: *const OrtRunOptions, - binding_ptr: *const OrtIoBinding, - ) -> OrtStatusPtr, - >, - pub CreateIoBinding: ::std::option::Option< - unsafe extern "C" fn(sess: *mut OrtSession, out: *mut *mut OrtIoBinding) -> OrtStatusPtr, - >, - pub ReleaseIoBinding: ::std::option::Option, - pub BindInput: ::std::option::Option< - unsafe extern "C" fn( - binding_ptr: *mut OrtIoBinding, - name: *const ::std::os::raw::c_char, - val_ptr: *const OrtValue, - ) -> OrtStatusPtr, - >, - pub BindOutput: ::std::option::Option< - unsafe extern "C" fn( - binding_ptr: *mut OrtIoBinding, - name: *const ::std::os::raw::c_char, - val_ptr: *const OrtValue, - ) -> OrtStatusPtr, - >, - pub BindOutputToDevice: ::std::option::Option< - unsafe extern "C" fn( - binding_ptr: *mut OrtIoBinding, - name: *const ::std::os::raw::c_char, - val_ptr: *const OrtMemoryInfo, - ) -> OrtStatusPtr, - >, - pub GetBoundOutputNames: ::std::option::Option< - unsafe extern "C" fn( - binding_ptr: *const OrtIoBinding, - allocator: *mut OrtAllocator, - buffer: *mut *mut ::std::os::raw::c_char, - lengths: *mut *mut usize, - count: *mut usize, - ) -> OrtStatusPtr, - >, - pub GetBoundOutputValues: ::std::option::Option< - unsafe extern "C" fn( - binding_ptr: *const OrtIoBinding, - allocator: *mut OrtAllocator, - output: *mut *mut *mut OrtValue, - output_count: *mut usize, - ) -> OrtStatusPtr, - >, - #[doc = " Clears any previously specified bindings for inputs/outputs"] - pub ClearBoundInputs: - ::std::option::Option, - pub ClearBoundOutputs: - ::std::option::Option, - pub TensorAt: ::std::option::Option< - unsafe extern "C" fn( - value: *mut OrtValue, - location_values: *const i64, - location_values_count: usize, - out: *mut *mut ::std::os::raw::c_void, - ) -> OrtStatusPtr, - >, - pub CreateAndRegisterAllocator: ::std::option::Option< - unsafe extern "C" fn( - env: *mut OrtEnv, - mem_info: *const OrtMemoryInfo, - arena_cfg: *const OrtArenaCfg, - ) -> OrtStatusPtr, - >, - pub SetLanguageProjection: ::std::option::Option< - unsafe extern "C" fn( - ort_env: *const OrtEnv, - projection: OrtLanguageProjection, - ) -> OrtStatusPtr, - >, - pub SessionGetProfilingStartTimeNs: ::std::option::Option< - unsafe extern "C" fn(sess: *const OrtSession, out: *mut u64) -> OrtStatusPtr, - >, - pub SetGlobalIntraOpNumThreads: ::std::option::Option< - unsafe extern "C" fn( - tp_options: *mut OrtThreadingOptions, - intra_op_num_threads: ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub SetGlobalInterOpNumThreads: ::std::option::Option< - unsafe extern "C" fn( - tp_options: *mut OrtThreadingOptions, - inter_op_num_threads: ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub SetGlobalSpinControl: ::std::option::Option< - unsafe extern "C" fn( - tp_options: *mut OrtThreadingOptions, - allow_spinning: ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub AddInitializer: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - name: *const ::std::os::raw::c_char, - val: *const OrtValue, - ) -> OrtStatusPtr, - >, - pub CreateEnvWithCustomLoggerAndGlobalThreadPools: ::std::option::Option< - unsafe extern "C" fn( - logging_function: OrtLoggingFunction, - logger_param: *mut ::std::os::raw::c_void, - logging_level: OrtLoggingLevel, - logid: *const ::std::os::raw::c_char, - tp_options: *const OrtThreadingOptions, - out: *mut *mut OrtEnv, - ) -> OrtStatusPtr, - >, - pub SessionOptionsAppendExecutionProvider_CUDA: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - cuda_options: *const OrtCUDAProviderOptions, - ) -> OrtStatusPtr, - >, - pub SessionOptionsAppendExecutionProvider_ROCM: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - rocm_options: *const OrtROCMProviderOptions, - ) -> OrtStatusPtr, - >, - pub SessionOptionsAppendExecutionProvider_OpenVINO: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - provider_options: *const OrtOpenVINOProviderOptions, - ) -> OrtStatusPtr, - >, - pub SetGlobalDenormalAsZero: ::std::option::Option< - unsafe extern "C" fn(tp_options: *mut OrtThreadingOptions) -> OrtStatusPtr, - >, - pub CreateArenaCfg: ::std::option::Option< - unsafe extern "C" fn( - max_mem: usize, - arena_extend_strategy: ::std::os::raw::c_int, - initial_chunk_size_bytes: ::std::os::raw::c_int, - max_dead_bytes_per_chunk: ::std::os::raw::c_int, - out: *mut *mut OrtArenaCfg, - ) -> OrtStatusPtr, - >, - pub ReleaseArenaCfg: ::std::option::Option, - pub ModelMetadataGetGraphDescription: ::std::option::Option< - unsafe extern "C" fn( - model_metadata: *const OrtModelMetadata, - allocator: *mut OrtAllocator, - value: *mut *mut ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub SessionOptionsAppendExecutionProvider_TensorRT: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - tensorrt_options: *const OrtTensorRTProviderOptions, - ) -> OrtStatusPtr, - >, - pub SetCurrentGpuDeviceId: ::std::option::Option< - unsafe extern "C" fn(device_id: ::std::os::raw::c_int) -> OrtStatusPtr, - >, - pub GetCurrentGpuDeviceId: ::std::option::Option< - unsafe extern "C" fn(device_id: *mut ::std::os::raw::c_int) -> OrtStatusPtr, - >, - pub KernelInfoGetAttributeArray_float: ::std::option::Option< - unsafe extern "C" fn( - info: *const OrtKernelInfo, - name: *const ::std::os::raw::c_char, - out: *mut f32, - size: *mut usize, - ) -> OrtStatusPtr, - >, - pub KernelInfoGetAttributeArray_int64: ::std::option::Option< - unsafe extern "C" fn( - info: *const OrtKernelInfo, - name: *const ::std::os::raw::c_char, - out: *mut i64, - size: *mut usize, - ) -> OrtStatusPtr, - >, - pub CreateArenaCfgV2: ::std::option::Option< - unsafe extern "C" fn( - arena_config_keys: *const *const ::std::os::raw::c_char, - arena_config_values: *const usize, - num_keys: usize, - out: *mut *mut OrtArenaCfg, - ) -> OrtStatusPtr, - >, - pub AddRunConfigEntry: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtRunOptions, - config_key: *const ::std::os::raw::c_char, - config_value: *const ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub CreatePrepackedWeightsContainer: ::std::option::Option< - unsafe extern "C" fn(out: *mut *mut OrtPrepackedWeightsContainer) -> OrtStatusPtr, - >, - pub ReleasePrepackedWeightsContainer: - ::std::option::Option, - pub CreateSessionWithPrepackedWeightsContainer: ::std::option::Option< - unsafe extern "C" fn( - env: *const OrtEnv, - model_path: *const ::std::os::raw::c_char, - options: *const OrtSessionOptions, - prepacked_weights_container: *mut OrtPrepackedWeightsContainer, - out: *mut *mut OrtSession, - ) -> OrtStatusPtr, - >, - pub CreateSessionFromArrayWithPrepackedWeightsContainer: ::std::option::Option< - unsafe extern "C" fn( - env: *const OrtEnv, - model_data: *const ::std::os::raw::c_void, - model_data_length: usize, - options: *const OrtSessionOptions, - prepacked_weights_container: *mut OrtPrepackedWeightsContainer, - out: *mut *mut OrtSession, - ) -> OrtStatusPtr, - >, -} -#[test] -fn bindgen_test_layout_OrtApi() { - assert_eq!( - ::std::mem::size_of::(), - 1360usize, - concat!("Size of: ", stringify!(OrtApi)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(OrtApi)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateStatus as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateStatus) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetErrorCode as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetErrorCode) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetErrorMessage as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetErrorMessage) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateEnv as *const _ as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateEnv) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateEnvWithCustomLogger as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateEnvWithCustomLogger) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).EnableTelemetryEvents as *const _ as usize }, - 40usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(EnableTelemetryEvents) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).DisableTelemetryEvents as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(DisableTelemetryEvents) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateSession as *const _ as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateSession) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateSessionFromArray as *const _ as usize }, - 64usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateSessionFromArray) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).Run as *const _ as usize }, - 72usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(Run) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateSessionOptions as *const _ as usize }, - 80usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateSessionOptions) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SetOptimizedModelFilePath as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetOptimizedModelFilePath) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CloneSessionOptions as *const _ as usize }, - 96usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CloneSessionOptions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetSessionExecutionMode as *const _ as usize }, - 104usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetSessionExecutionMode) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).EnableProfiling as *const _ as usize }, - 112usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(EnableProfiling) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).DisableProfiling as *const _ as usize }, - 120usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(DisableProfiling) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).EnableMemPattern as *const _ as usize }, - 128usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(EnableMemPattern) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).DisableMemPattern as *const _ as usize }, - 136usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(DisableMemPattern) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).EnableCpuMemArena as *const _ as usize }, - 144usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(EnableCpuMemArena) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).DisableCpuMemArena as *const _ as usize }, - 152usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(DisableCpuMemArena) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetSessionLogId as *const _ as usize }, - 160usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetSessionLogId) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SetSessionLogVerbosityLevel as *const _ as usize - }, - 168usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetSessionLogVerbosityLevel) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SetSessionLogSeverityLevel as *const _ as usize - }, - 176usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetSessionLogSeverityLevel) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SetSessionGraphOptimizationLevel as *const _ as usize - }, - 184usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetSessionGraphOptimizationLevel) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetIntraOpNumThreads as *const _ as usize }, - 192usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetIntraOpNumThreads) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetInterOpNumThreads as *const _ as usize }, - 200usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetInterOpNumThreads) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateCustomOpDomain as *const _ as usize }, - 208usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateCustomOpDomain) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CustomOpDomain_Add as *const _ as usize }, - 216usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CustomOpDomain_Add) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AddCustomOpDomain as *const _ as usize }, - 224usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AddCustomOpDomain) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).RegisterCustomOpsLibrary as *const _ as usize }, - 232usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RegisterCustomOpsLibrary) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionGetInputCount as *const _ as usize }, - 240usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetInputCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionGetOutputCount as *const _ as usize }, - 248usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetOutputCount) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionGetOverridableInitializerCount as *const _ - as usize - }, - 256usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetOverridableInitializerCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionGetInputTypeInfo as *const _ as usize }, - 264usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetInputTypeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionGetOutputTypeInfo as *const _ as usize }, - 272usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetOutputTypeInfo) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionGetOverridableInitializerTypeInfo as *const _ - as usize - }, - 280usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetOverridableInitializerTypeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionGetInputName as *const _ as usize }, - 288usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetInputName) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionGetOutputName as *const _ as usize }, - 296usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetOutputName) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionGetOverridableInitializerName as *const _ - as usize - }, - 304usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetOverridableInitializerName) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateRunOptions as *const _ as usize }, - 312usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateRunOptions) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).RunOptionsSetRunLogVerbosityLevel as *const _ - as usize - }, - 320usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsSetRunLogVerbosityLevel) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).RunOptionsSetRunLogSeverityLevel as *const _ as usize - }, - 328usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsSetRunLogSeverityLevel) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).RunOptionsSetRunTag as *const _ as usize }, - 336usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsSetRunTag) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).RunOptionsGetRunLogVerbosityLevel as *const _ - as usize - }, - 344usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsGetRunLogVerbosityLevel) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).RunOptionsGetRunLogSeverityLevel as *const _ as usize - }, - 352usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsGetRunLogSeverityLevel) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).RunOptionsGetRunTag as *const _ as usize }, - 360usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsGetRunTag) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).RunOptionsSetTerminate as *const _ as usize }, - 368usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsSetTerminate) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).RunOptionsUnsetTerminate as *const _ as usize }, - 376usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsUnsetTerminate) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateTensorAsOrtValue as *const _ as usize }, - 384usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateTensorAsOrtValue) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateTensorWithDataAsOrtValue as *const _ as usize - }, - 392usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateTensorWithDataAsOrtValue) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).IsTensor as *const _ as usize }, - 400usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(IsTensor) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetTensorMutableData as *const _ as usize }, - 408usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetTensorMutableData) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).FillStringTensor as *const _ as usize }, - 416usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(FillStringTensor) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetStringTensorDataLength as *const _ as usize - }, - 424usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetStringTensorDataLength) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetStringTensorContent as *const _ as usize }, - 432usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetStringTensorContent) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CastTypeInfoToTensorInfo as *const _ as usize }, - 440usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CastTypeInfoToTensorInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetOnnxTypeFromTypeInfo as *const _ as usize }, - 448usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetOnnxTypeFromTypeInfo) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateTensorTypeAndShapeInfo as *const _ as usize - }, - 456usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateTensorTypeAndShapeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetTensorElementType as *const _ as usize }, - 464usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetTensorElementType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetDimensions as *const _ as usize }, - 472usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetDimensions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetTensorElementType as *const _ as usize }, - 480usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetTensorElementType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetDimensionsCount as *const _ as usize }, - 488usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetDimensionsCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetDimensions as *const _ as usize }, - 496usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetDimensions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetSymbolicDimensions as *const _ as usize }, - 504usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetSymbolicDimensions) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetTensorShapeElementCount as *const _ as usize - }, - 512usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetTensorShapeElementCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetTensorTypeAndShape as *const _ as usize }, - 520usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetTensorTypeAndShape) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetTypeInfo as *const _ as usize }, - 528usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetTypeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetValueType as *const _ as usize }, - 536usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetValueType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateMemoryInfo as *const _ as usize }, - 544usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateMemoryInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateCpuMemoryInfo as *const _ as usize }, - 552usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateCpuMemoryInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CompareMemoryInfo as *const _ as usize }, - 560usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CompareMemoryInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).MemoryInfoGetName as *const _ as usize }, - 568usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(MemoryInfoGetName) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).MemoryInfoGetId as *const _ as usize }, - 576usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(MemoryInfoGetId) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).MemoryInfoGetMemType as *const _ as usize }, - 584usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(MemoryInfoGetMemType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).MemoryInfoGetType as *const _ as usize }, - 592usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(MemoryInfoGetType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AllocatorAlloc as *const _ as usize }, - 600usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AllocatorAlloc) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AllocatorFree as *const _ as usize }, - 608usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AllocatorFree) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AllocatorGetInfo as *const _ as usize }, - 616usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AllocatorGetInfo) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetAllocatorWithDefaultOptions as *const _ as usize - }, - 624usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetAllocatorWithDefaultOptions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AddFreeDimensionOverride as *const _ as usize }, - 632usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AddFreeDimensionOverride) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetValue as *const _ as usize }, - 640usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetValue) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetValueCount as *const _ as usize }, - 648usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetValueCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateValue as *const _ as usize }, - 656usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateValue) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateOpaqueValue as *const _ as usize }, - 664usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateOpaqueValue) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetOpaqueValue as *const _ as usize }, - 672usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetOpaqueValue) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).KernelInfoGetAttribute_float as *const _ as usize - }, - 680usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelInfoGetAttribute_float) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).KernelInfoGetAttribute_int64 as *const _ as usize - }, - 688usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelInfoGetAttribute_int64) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).KernelInfoGetAttribute_string as *const _ as usize - }, - 696usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelInfoGetAttribute_string) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).KernelContext_GetInputCount as *const _ as usize - }, - 704usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelContext_GetInputCount) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).KernelContext_GetOutputCount as *const _ as usize - }, - 712usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelContext_GetOutputCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).KernelContext_GetInput as *const _ as usize }, - 720usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelContext_GetInput) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).KernelContext_GetOutput as *const _ as usize }, - 728usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelContext_GetOutput) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseEnv as *const _ as usize }, - 736usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseEnv) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseStatus as *const _ as usize }, - 744usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseStatus) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseMemoryInfo as *const _ as usize }, - 752usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseMemoryInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseSession as *const _ as usize }, - 760usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseSession) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseValue as *const _ as usize }, - 768usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseValue) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseRunOptions as *const _ as usize }, - 776usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseRunOptions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseTypeInfo as *const _ as usize }, - 784usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseTypeInfo) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ReleaseTensorTypeAndShapeInfo as *const _ as usize - }, - 792usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseTensorTypeAndShapeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseSessionOptions as *const _ as usize }, - 800usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseSessionOptions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseCustomOpDomain as *const _ as usize }, - 808usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseCustomOpDomain) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetDenotationFromTypeInfo as *const _ as usize - }, - 816usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetDenotationFromTypeInfo) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CastTypeInfoToMapTypeInfo as *const _ as usize - }, - 824usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CastTypeInfoToMapTypeInfo) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CastTypeInfoToSequenceTypeInfo as *const _ as usize - }, - 832usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CastTypeInfoToSequenceTypeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetMapKeyType as *const _ as usize }, - 840usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetMapKeyType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetMapValueType as *const _ as usize }, - 848usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetMapValueType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetSequenceElementType as *const _ as usize }, - 856usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetSequenceElementType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseMapTypeInfo as *const _ as usize }, - 864usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseMapTypeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseSequenceTypeInfo as *const _ as usize }, - 872usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseSequenceTypeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionEndProfiling as *const _ as usize }, - 880usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionEndProfiling) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionGetModelMetadata as *const _ as usize }, - 888usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetModelMetadata) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ModelMetadataGetProducerName as *const _ as usize - }, - 896usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataGetProducerName) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ModelMetadataGetGraphName as *const _ as usize - }, - 904usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataGetGraphName) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ModelMetadataGetDomain as *const _ as usize }, - 912usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataGetDomain) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ModelMetadataGetDescription as *const _ as usize - }, - 920usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataGetDescription) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ModelMetadataLookupCustomMetadataMap as *const _ - as usize - }, - 928usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataLookupCustomMetadataMap) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ModelMetadataGetVersion as *const _ as usize }, - 936usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataGetVersion) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseModelMetadata as *const _ as usize }, - 944usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseModelMetadata) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateEnvWithGlobalThreadPools as *const _ as usize - }, - 952usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateEnvWithGlobalThreadPools) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).DisablePerSessionThreads as *const _ as usize }, - 960usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(DisablePerSessionThreads) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateThreadingOptions as *const _ as usize }, - 968usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateThreadingOptions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseThreadingOptions as *const _ as usize }, - 976usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseThreadingOptions) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ModelMetadataGetCustomMetadataMapKeys as *const _ - as usize - }, - 984usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataGetCustomMetadataMapKeys) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).AddFreeDimensionOverrideByName as *const _ as usize - }, - 992usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AddFreeDimensionOverrideByName) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetAvailableProviders as *const _ as usize }, - 1000usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetAvailableProviders) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ReleaseAvailableProviders as *const _ as usize - }, - 1008usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseAvailableProviders) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetStringTensorElementLength as *const _ as usize - }, - 1016usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetStringTensorElementLength) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetStringTensorElement as *const _ as usize }, - 1024usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetStringTensorElement) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).FillStringTensorElement as *const _ as usize }, - 1032usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(FillStringTensorElement) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AddSessionConfigEntry as *const _ as usize }, - 1040usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AddSessionConfigEntry) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateAllocator as *const _ as usize }, - 1048usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateAllocator) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseAllocator as *const _ as usize }, - 1056usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseAllocator) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).RunWithBinding as *const _ as usize }, - 1064usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunWithBinding) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateIoBinding as *const _ as usize }, - 1072usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateIoBinding) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseIoBinding as *const _ as usize }, - 1080usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseIoBinding) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).BindInput as *const _ as usize }, - 1088usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(BindInput) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).BindOutput as *const _ as usize }, - 1096usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(BindOutput) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).BindOutputToDevice as *const _ as usize }, - 1104usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(BindOutputToDevice) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetBoundOutputNames as *const _ as usize }, - 1112usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetBoundOutputNames) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetBoundOutputValues as *const _ as usize }, - 1120usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetBoundOutputValues) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ClearBoundInputs as *const _ as usize }, - 1128usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ClearBoundInputs) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ClearBoundOutputs as *const _ as usize }, - 1136usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ClearBoundOutputs) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).TensorAt as *const _ as usize }, - 1144usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(TensorAt) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateAndRegisterAllocator as *const _ as usize - }, - 1152usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateAndRegisterAllocator) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetLanguageProjection as *const _ as usize }, - 1160usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetLanguageProjection) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionGetProfilingStartTimeNs as *const _ as usize - }, - 1168usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetProfilingStartTimeNs) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SetGlobalIntraOpNumThreads as *const _ as usize - }, - 1176usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetGlobalIntraOpNumThreads) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SetGlobalInterOpNumThreads as *const _ as usize - }, - 1184usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetGlobalInterOpNumThreads) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetGlobalSpinControl as *const _ as usize }, - 1192usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetGlobalSpinControl) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AddInitializer as *const _ as usize }, - 1200usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AddInitializer) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateEnvWithCustomLoggerAndGlobalThreadPools - as *const _ as usize - }, - 1208usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateEnvWithCustomLoggerAndGlobalThreadPools) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionOptionsAppendExecutionProvider_CUDA - as *const _ as usize - }, - 1216usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionOptionsAppendExecutionProvider_CUDA) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionOptionsAppendExecutionProvider_ROCM - as *const _ as usize - }, - 1224usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionOptionsAppendExecutionProvider_ROCM) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionOptionsAppendExecutionProvider_OpenVINO - as *const _ as usize - }, - 1232usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionOptionsAppendExecutionProvider_OpenVINO) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetGlobalDenormalAsZero as *const _ as usize }, - 1240usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetGlobalDenormalAsZero) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateArenaCfg as *const _ as usize }, - 1248usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateArenaCfg) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseArenaCfg as *const _ as usize }, - 1256usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseArenaCfg) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ModelMetadataGetGraphDescription as *const _ as usize - }, - 1264usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataGetGraphDescription) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionOptionsAppendExecutionProvider_TensorRT - as *const _ as usize - }, - 1272usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionOptionsAppendExecutionProvider_TensorRT) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetCurrentGpuDeviceId as *const _ as usize }, - 1280usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetCurrentGpuDeviceId) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetCurrentGpuDeviceId as *const _ as usize }, - 1288usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetCurrentGpuDeviceId) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).KernelInfoGetAttributeArray_float as *const _ - as usize - }, - 1296usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelInfoGetAttributeArray_float) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).KernelInfoGetAttributeArray_int64 as *const _ - as usize - }, - 1304usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelInfoGetAttributeArray_int64) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateArenaCfgV2 as *const _ as usize }, - 1312usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateArenaCfgV2) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AddRunConfigEntry as *const _ as usize }, - 1320usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AddRunConfigEntry) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreatePrepackedWeightsContainer as *const _ as usize - }, - 1328usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreatePrepackedWeightsContainer) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ReleasePrepackedWeightsContainer as *const _ as usize - }, - 1336usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleasePrepackedWeightsContainer) - ) - ); +pub struct OrtApi { + #[doc = " \\brief Create an OrtStatus from a null terminated string"] + #[doc = ""] + #[doc = " \\param[in] code"] + #[doc = " \\param[in] msg A null-terminated string. Its contents will be copied."] + #[doc = " \\return A new OrtStatus object, must be destroyed with OrtApi::ReleaseStatus"] + pub CreateStatus: ::std::option::Option< + unsafe extern "C" fn( + code: OrtErrorCode, + msg: *const ::std::os::raw::c_char, + ) -> *mut OrtStatus, + >, + #[doc = " \\brief Get OrtErrorCode from OrtStatus"] + #[doc = ""] + #[doc = " \\param[in] status"] + #[doc = " \\return OrtErrorCode that \\p status was created with"] + pub GetErrorCode: + ::std::option::Option OrtErrorCode>, + #[doc = " \\brief Get error string from OrtStatus"] + #[doc = ""] + #[doc = " \\param[in] status"] + #[doc = " \\return The error message inside the `status`. Do not free the returned value."] + pub GetErrorMessage: ::std::option::Option< + unsafe extern "C" fn(status: *const OrtStatus) -> *const ::std::os::raw::c_char, + >, + pub CreateEnv: ::std::option::Option< + unsafe extern "C" fn( + log_severity_level: OrtLoggingLevel, + logid: *const ::std::os::raw::c_char, + out: *mut *mut OrtEnv, + ) -> OrtStatusPtr, + >, + pub CreateEnvWithCustomLogger: ::std::option::Option< + unsafe extern "C" fn( + logging_function: OrtLoggingFunction, + logger_param: *mut ::std::os::raw::c_void, + log_severity_level: OrtLoggingLevel, + logid: *const ::std::os::raw::c_char, + out: *mut *mut OrtEnv, + ) -> OrtStatusPtr, + >, + pub EnableTelemetryEvents: + ::std::option::Option OrtStatusPtr>, + pub DisableTelemetryEvents: + ::std::option::Option OrtStatusPtr>, + pub CreateSession: ::std::option::Option< + unsafe extern "C" fn( + env: *const OrtEnv, + model_path: *const ::std::os::raw::c_char, + options: *const OrtSessionOptions, + out: *mut *mut OrtSession, + ) -> OrtStatusPtr, + >, + pub CreateSessionFromArray: ::std::option::Option< + unsafe extern "C" fn( + env: *const OrtEnv, + model_data: *const ::std::os::raw::c_void, + model_data_length: usize, + options: *const OrtSessionOptions, + out: *mut *mut OrtSession, + ) -> OrtStatusPtr, + >, + pub Run: ::std::option::Option< + unsafe extern "C" fn( + session: *mut OrtSession, + run_options: *const OrtRunOptions, + input_names: *const *const ::std::os::raw::c_char, + inputs: *const *const OrtValue, + input_len: usize, + output_names: *const *const ::std::os::raw::c_char, + output_names_len: usize, + outputs: *mut *mut OrtValue, + ) -> OrtStatusPtr, + >, + pub CreateSessionOptions: ::std::option::Option< + unsafe extern "C" fn(options: *mut *mut OrtSessionOptions) -> OrtStatusPtr, + >, + pub SetOptimizedModelFilePath: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + optimized_model_filepath: *const ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub CloneSessionOptions: ::std::option::Option< + unsafe extern "C" fn( + in_options: *const OrtSessionOptions, + out_options: *mut *mut OrtSessionOptions, + ) -> OrtStatusPtr, + >, + pub SetSessionExecutionMode: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + execution_mode: ExecutionMode, + ) -> OrtStatusPtr, + >, + pub EnableProfiling: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + profile_file_prefix: *const ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub DisableProfiling: ::std::option::Option< + unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, + >, + pub EnableMemPattern: ::std::option::Option< + unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, + >, + pub DisableMemPattern: ::std::option::Option< + unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, + >, + pub EnableCpuMemArena: ::std::option::Option< + unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, + >, + pub DisableCpuMemArena: ::std::option::Option< + unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, + >, + pub SetSessionLogId: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + logid: *const ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub SetSessionLogVerbosityLevel: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + session_log_verbosity_level: ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub SetSessionLogSeverityLevel: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + session_log_severity_level: ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub SetSessionGraphOptimizationLevel: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + graph_optimization_level: GraphOptimizationLevel, + ) -> OrtStatusPtr, + >, + pub SetIntraOpNumThreads: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + intra_op_num_threads: ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub SetInterOpNumThreads: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + inter_op_num_threads: ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub CreateCustomOpDomain: ::std::option::Option< + unsafe extern "C" fn( + domain: *const ::std::os::raw::c_char, + out: *mut *mut OrtCustomOpDomain, + ) -> OrtStatusPtr, + >, + pub CustomOpDomain_Add: ::std::option::Option< + unsafe extern "C" fn( + custom_op_domain: *mut OrtCustomOpDomain, + op: *const OrtCustomOp, + ) -> OrtStatusPtr, + >, + pub AddCustomOpDomain: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + custom_op_domain: *mut OrtCustomOpDomain, + ) -> OrtStatusPtr, + >, + pub RegisterCustomOpsLibrary: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + library_path: *const ::std::os::raw::c_char, + library_handle: *mut *mut ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub SessionGetInputCount: ::std::option::Option< + unsafe extern "C" fn(session: *const OrtSession, out: *mut usize) -> OrtStatusPtr, + >, + pub SessionGetOutputCount: ::std::option::Option< + unsafe extern "C" fn(session: *const OrtSession, out: *mut usize) -> OrtStatusPtr, + >, + pub SessionGetOverridableInitializerCount: ::std::option::Option< + unsafe extern "C" fn(session: *const OrtSession, out: *mut usize) -> OrtStatusPtr, + >, + pub SessionGetInputTypeInfo: ::std::option::Option< + unsafe extern "C" fn( + session: *const OrtSession, + index: usize, + type_info: *mut *mut OrtTypeInfo, + ) -> OrtStatusPtr, + >, + pub SessionGetOutputTypeInfo: ::std::option::Option< + unsafe extern "C" fn( + session: *const OrtSession, + index: usize, + type_info: *mut *mut OrtTypeInfo, + ) -> OrtStatusPtr, + >, + pub SessionGetOverridableInitializerTypeInfo: ::std::option::Option< + unsafe extern "C" fn( + session: *const OrtSession, + index: usize, + type_info: *mut *mut OrtTypeInfo, + ) -> OrtStatusPtr, + >, + pub SessionGetInputName: ::std::option::Option< + unsafe extern "C" fn( + session: *const OrtSession, + index: usize, + allocator: *mut OrtAllocator, + value: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub SessionGetOutputName: ::std::option::Option< + unsafe extern "C" fn( + session: *const OrtSession, + index: usize, + allocator: *mut OrtAllocator, + value: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub SessionGetOverridableInitializerName: ::std::option::Option< + unsafe extern "C" fn( + session: *const OrtSession, + index: usize, + allocator: *mut OrtAllocator, + value: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub CreateRunOptions: + ::std::option::Option OrtStatusPtr>, + pub RunOptionsSetRunLogVerbosityLevel: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtRunOptions, + log_verbosity_level: ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub RunOptionsSetRunLogSeverityLevel: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtRunOptions, + log_severity_level: ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub RunOptionsSetRunTag: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtRunOptions, + run_tag: *const ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub RunOptionsGetRunLogVerbosityLevel: ::std::option::Option< + unsafe extern "C" fn( + options: *const OrtRunOptions, + log_verbosity_level: *mut ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub RunOptionsGetRunLogSeverityLevel: ::std::option::Option< + unsafe extern "C" fn( + options: *const OrtRunOptions, + log_severity_level: *mut ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub RunOptionsGetRunTag: ::std::option::Option< + unsafe extern "C" fn( + options: *const OrtRunOptions, + run_tag: *mut *const ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub RunOptionsSetTerminate: + ::std::option::Option OrtStatusPtr>, + pub RunOptionsUnsetTerminate: + ::std::option::Option OrtStatusPtr>, + pub CreateTensorAsOrtValue: ::std::option::Option< + unsafe extern "C" fn( + allocator: *mut OrtAllocator, + shape: *const i64, + shape_len: usize, + type_: ONNXTensorElementDataType, + out: *mut *mut OrtValue, + ) -> OrtStatusPtr, + >, + pub CreateTensorWithDataAsOrtValue: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtMemoryInfo, + p_data: *mut ::std::os::raw::c_void, + p_data_len: usize, + shape: *const i64, + shape_len: usize, + type_: ONNXTensorElementDataType, + out: *mut *mut OrtValue, + ) -> OrtStatusPtr, + >, + pub IsTensor: ::std::option::Option< + unsafe extern "C" fn( + value: *const OrtValue, + out: *mut ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub GetTensorMutableData: ::std::option::Option< + unsafe extern "C" fn( + value: *mut OrtValue, + out: *mut *mut ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub FillStringTensor: ::std::option::Option< + unsafe extern "C" fn( + value: *mut OrtValue, + s: *const *const ::std::os::raw::c_char, + s_len: usize, + ) -> OrtStatusPtr, + >, + pub GetStringTensorDataLength: ::std::option::Option< + unsafe extern "C" fn(value: *const OrtValue, len: *mut usize) -> OrtStatusPtr, + >, + pub GetStringTensorContent: ::std::option::Option< + unsafe extern "C" fn( + value: *const OrtValue, + s: *mut ::std::os::raw::c_void, + s_len: usize, + offsets: *mut usize, + offsets_len: usize, + ) -> OrtStatusPtr, + >, + pub CastTypeInfoToTensorInfo: ::std::option::Option< + unsafe extern "C" fn( + type_info: *const OrtTypeInfo, + out: *mut *const OrtTensorTypeAndShapeInfo, + ) -> OrtStatusPtr, + >, + pub GetOnnxTypeFromTypeInfo: ::std::option::Option< + unsafe extern "C" fn(type_info: *const OrtTypeInfo, out: *mut ONNXType) -> OrtStatusPtr, + >, + pub CreateTensorTypeAndShapeInfo: ::std::option::Option< + unsafe extern "C" fn(out: *mut *mut OrtTensorTypeAndShapeInfo) -> OrtStatusPtr, + >, + pub SetTensorElementType: ::std::option::Option< + unsafe extern "C" fn( + info: *mut OrtTensorTypeAndShapeInfo, + type_: ONNXTensorElementDataType, + ) -> OrtStatusPtr, + >, + pub SetDimensions: ::std::option::Option< + unsafe extern "C" fn( + info: *mut OrtTensorTypeAndShapeInfo, + dim_values: *const i64, + dim_count: usize, + ) -> OrtStatusPtr, + >, + pub GetTensorElementType: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtTensorTypeAndShapeInfo, + out: *mut ONNXTensorElementDataType, + ) -> OrtStatusPtr, + >, + pub GetDimensionsCount: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtTensorTypeAndShapeInfo, + out: *mut usize, + ) -> OrtStatusPtr, + >, + pub GetDimensions: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtTensorTypeAndShapeInfo, + dim_values: *mut i64, + dim_values_length: usize, + ) -> OrtStatusPtr, + >, + pub GetSymbolicDimensions: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtTensorTypeAndShapeInfo, + dim_params: *mut *const ::std::os::raw::c_char, + dim_params_length: usize, + ) -> OrtStatusPtr, + >, + pub GetTensorShapeElementCount: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtTensorTypeAndShapeInfo, + out: *mut usize, + ) -> OrtStatusPtr, + >, + pub GetTensorTypeAndShape: ::std::option::Option< + unsafe extern "C" fn( + value: *const OrtValue, + out: *mut *mut OrtTensorTypeAndShapeInfo, + ) -> OrtStatusPtr, + >, + pub GetTypeInfo: ::std::option::Option< + unsafe extern "C" fn(value: *const OrtValue, out: *mut *mut OrtTypeInfo) -> OrtStatusPtr, + >, + pub GetValueType: ::std::option::Option< + unsafe extern "C" fn(value: *const OrtValue, out: *mut ONNXType) -> OrtStatusPtr, + >, + pub CreateMemoryInfo: ::std::option::Option< + unsafe extern "C" fn( + name: *const ::std::os::raw::c_char, + type_: OrtAllocatorType, + id: ::std::os::raw::c_int, + mem_type: OrtMemType, + out: *mut *mut OrtMemoryInfo, + ) -> OrtStatusPtr, + >, + pub CreateCpuMemoryInfo: ::std::option::Option< + unsafe extern "C" fn( + type_: OrtAllocatorType, + mem_type: OrtMemType, + out: *mut *mut OrtMemoryInfo, + ) -> OrtStatusPtr, + >, + pub CompareMemoryInfo: ::std::option::Option< + unsafe extern "C" fn( + info1: *const OrtMemoryInfo, + info2: *const OrtMemoryInfo, + out: *mut ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub MemoryInfoGetName: ::std::option::Option< + unsafe extern "C" fn( + ptr: *const OrtMemoryInfo, + out: *mut *const ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub MemoryInfoGetId: ::std::option::Option< + unsafe extern "C" fn( + ptr: *const OrtMemoryInfo, + out: *mut ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub MemoryInfoGetMemType: ::std::option::Option< + unsafe extern "C" fn(ptr: *const OrtMemoryInfo, out: *mut OrtMemType) -> OrtStatusPtr, + >, + pub MemoryInfoGetType: ::std::option::Option< + unsafe extern "C" fn(ptr: *const OrtMemoryInfo, out: *mut OrtAllocatorType) -> OrtStatusPtr, + >, + pub AllocatorAlloc: ::std::option::Option< + unsafe extern "C" fn( + ort_allocator: *mut OrtAllocator, + size: usize, + out: *mut *mut ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub AllocatorFree: ::std::option::Option< + unsafe extern "C" fn( + ort_allocator: *mut OrtAllocator, + p: *mut ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub AllocatorGetInfo: ::std::option::Option< + unsafe extern "C" fn( + ort_allocator: *const OrtAllocator, + out: *mut *const OrtMemoryInfo, + ) -> OrtStatusPtr, + >, + pub GetAllocatorWithDefaultOptions: + ::std::option::Option OrtStatusPtr>, + pub AddFreeDimensionOverride: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + dim_denotation: *const ::std::os::raw::c_char, + dim_value: i64, + ) -> OrtStatusPtr, + >, + pub GetValue: ::std::option::Option< + unsafe extern "C" fn( + value: *const OrtValue, + index: ::std::os::raw::c_int, + allocator: *mut OrtAllocator, + out: *mut *mut OrtValue, + ) -> OrtStatusPtr, + >, + pub GetValueCount: ::std::option::Option< + unsafe extern "C" fn(value: *const OrtValue, out: *mut usize) -> OrtStatusPtr, + >, + pub CreateValue: ::std::option::Option< + unsafe extern "C" fn( + in_: *const *const OrtValue, + num_values: usize, + value_type: ONNXType, + out: *mut *mut OrtValue, + ) -> OrtStatusPtr, + >, + pub CreateOpaqueValue: ::std::option::Option< + unsafe extern "C" fn( + domain_name: *const ::std::os::raw::c_char, + type_name: *const ::std::os::raw::c_char, + data_container: *const ::std::os::raw::c_void, + data_container_size: usize, + out: *mut *mut OrtValue, + ) -> OrtStatusPtr, + >, + pub GetOpaqueValue: ::std::option::Option< + unsafe extern "C" fn( + domain_name: *const ::std::os::raw::c_char, + type_name: *const ::std::os::raw::c_char, + in_: *const OrtValue, + data_container: *mut ::std::os::raw::c_void, + data_container_size: usize, + ) -> OrtStatusPtr, + >, + pub KernelInfoGetAttribute_float: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtKernelInfo, + name: *const ::std::os::raw::c_char, + out: *mut f32, + ) -> OrtStatusPtr, + >, + pub KernelInfoGetAttribute_int64: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtKernelInfo, + name: *const ::std::os::raw::c_char, + out: *mut i64, + ) -> OrtStatusPtr, + >, + pub KernelInfoGetAttribute_string: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtKernelInfo, + name: *const ::std::os::raw::c_char, + out: *mut ::std::os::raw::c_char, + size: *mut usize, + ) -> OrtStatusPtr, + >, + pub KernelContext_GetInputCount: ::std::option::Option< + unsafe extern "C" fn(context: *const OrtKernelContext, out: *mut usize) -> OrtStatusPtr, + >, + pub KernelContext_GetOutputCount: ::std::option::Option< + unsafe extern "C" fn(context: *const OrtKernelContext, out: *mut usize) -> OrtStatusPtr, + >, + pub KernelContext_GetInput: ::std::option::Option< + unsafe extern "C" fn( + context: *const OrtKernelContext, + index: usize, + out: *mut *const OrtValue, + ) -> OrtStatusPtr, + >, + pub KernelContext_GetOutput: ::std::option::Option< + unsafe extern "C" fn( + context: *mut OrtKernelContext, + index: usize, + dim_values: *const i64, + dim_count: usize, + out: *mut *mut OrtValue, + ) -> OrtStatusPtr, + >, + pub ReleaseEnv: ::std::option::Option, + pub ReleaseStatus: ::std::option::Option, + pub ReleaseMemoryInfo: ::std::option::Option, + pub ReleaseSession: ::std::option::Option, + pub ReleaseValue: ::std::option::Option, + pub ReleaseRunOptions: ::std::option::Option, + pub ReleaseTypeInfo: ::std::option::Option, + pub ReleaseTensorTypeAndShapeInfo: + ::std::option::Option, + pub ReleaseSessionOptions: + ::std::option::Option, + pub ReleaseCustomOpDomain: + ::std::option::Option, + pub GetDenotationFromTypeInfo: ::std::option::Option< + unsafe extern "C" fn( + type_info: *const OrtTypeInfo, + denotation: *mut *const ::std::os::raw::c_char, + len: *mut usize, + ) -> OrtStatusPtr, + >, + pub CastTypeInfoToMapTypeInfo: ::std::option::Option< + unsafe extern "C" fn( + type_info: *const OrtTypeInfo, + out: *mut *const OrtMapTypeInfo, + ) -> OrtStatusPtr, + >, + pub CastTypeInfoToSequenceTypeInfo: ::std::option::Option< + unsafe extern "C" fn( + type_info: *const OrtTypeInfo, + out: *mut *const OrtSequenceTypeInfo, + ) -> OrtStatusPtr, + >, + pub GetMapKeyType: ::std::option::Option< + unsafe extern "C" fn( + map_type_info: *const OrtMapTypeInfo, + out: *mut ONNXTensorElementDataType, + ) -> OrtStatusPtr, + >, + pub GetMapValueType: ::std::option::Option< + unsafe extern "C" fn( + map_type_info: *const OrtMapTypeInfo, + type_info: *mut *mut OrtTypeInfo, + ) -> OrtStatusPtr, + >, + pub GetSequenceElementType: ::std::option::Option< + unsafe extern "C" fn( + sequence_type_info: *const OrtSequenceTypeInfo, + type_info: *mut *mut OrtTypeInfo, + ) -> OrtStatusPtr, + >, + pub ReleaseMapTypeInfo: ::std::option::Option, + pub ReleaseSequenceTypeInfo: + ::std::option::Option, + pub SessionEndProfiling: ::std::option::Option< + unsafe extern "C" fn( + session: *mut OrtSession, + allocator: *mut OrtAllocator, + out: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub SessionGetModelMetadata: ::std::option::Option< + unsafe extern "C" fn( + session: *const OrtSession, + out: *mut *mut OrtModelMetadata, + ) -> OrtStatusPtr, + >, + pub ModelMetadataGetProducerName: ::std::option::Option< + unsafe extern "C" fn( + model_metadata: *const OrtModelMetadata, + allocator: *mut OrtAllocator, + value: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub ModelMetadataGetGraphName: ::std::option::Option< + unsafe extern "C" fn( + model_metadata: *const OrtModelMetadata, + allocator: *mut OrtAllocator, + value: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub ModelMetadataGetDomain: ::std::option::Option< + unsafe extern "C" fn( + model_metadata: *const OrtModelMetadata, + allocator: *mut OrtAllocator, + value: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub ModelMetadataGetDescription: ::std::option::Option< + unsafe extern "C" fn( + model_metadata: *const OrtModelMetadata, + allocator: *mut OrtAllocator, + value: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub ModelMetadataLookupCustomMetadataMap: ::std::option::Option< + unsafe extern "C" fn( + model_metadata: *const OrtModelMetadata, + allocator: *mut OrtAllocator, + key: *const ::std::os::raw::c_char, + value: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub ModelMetadataGetVersion: ::std::option::Option< + unsafe extern "C" fn( + model_metadata: *const OrtModelMetadata, + value: *mut i64, + ) -> OrtStatusPtr, + >, + pub ReleaseModelMetadata: + ::std::option::Option, + pub CreateEnvWithGlobalThreadPools: ::std::option::Option< + unsafe extern "C" fn( + log_severity_level: OrtLoggingLevel, + logid: *const ::std::os::raw::c_char, + tp_options: *const OrtThreadingOptions, + out: *mut *mut OrtEnv, + ) -> OrtStatusPtr, + >, + pub DisablePerSessionThreads: ::std::option::Option< + unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, + >, + pub CreateThreadingOptions: ::std::option::Option< + unsafe extern "C" fn(out: *mut *mut OrtThreadingOptions) -> OrtStatusPtr, + >, + pub ReleaseThreadingOptions: + ::std::option::Option, + pub ModelMetadataGetCustomMetadataMapKeys: ::std::option::Option< + unsafe extern "C" fn( + model_metadata: *const OrtModelMetadata, + allocator: *mut OrtAllocator, + keys: *mut *mut *mut ::std::os::raw::c_char, + num_keys: *mut i64, + ) -> OrtStatusPtr, + >, + pub AddFreeDimensionOverrideByName: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + dim_name: *const ::std::os::raw::c_char, + dim_value: i64, + ) -> OrtStatusPtr, + >, + pub GetAvailableProviders: ::std::option::Option< + unsafe extern "C" fn( + out_ptr: *mut *mut *mut ::std::os::raw::c_char, + provider_length: *mut ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub ReleaseAvailableProviders: ::std::option::Option< + unsafe extern "C" fn( + ptr: *mut *mut ::std::os::raw::c_char, + providers_length: ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub GetStringTensorElementLength: ::std::option::Option< + unsafe extern "C" fn(value: *const OrtValue, index: usize, out: *mut usize) -> OrtStatusPtr, + >, + pub GetStringTensorElement: ::std::option::Option< + unsafe extern "C" fn( + value: *const OrtValue, + s_len: usize, + index: usize, + s: *mut ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub FillStringTensorElement: ::std::option::Option< + unsafe extern "C" fn( + value: *mut OrtValue, + s: *const ::std::os::raw::c_char, + index: usize, + ) -> OrtStatusPtr, + >, + pub AddSessionConfigEntry: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + config_key: *const ::std::os::raw::c_char, + config_value: *const ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub CreateAllocator: ::std::option::Option< + unsafe extern "C" fn( + session: *const OrtSession, + mem_info: *const OrtMemoryInfo, + out: *mut *mut OrtAllocator, + ) -> OrtStatusPtr, + >, + pub ReleaseAllocator: ::std::option::Option, + pub RunWithBinding: ::std::option::Option< + unsafe extern "C" fn( + session: *mut OrtSession, + run_options: *const OrtRunOptions, + binding_ptr: *const OrtIoBinding, + ) -> OrtStatusPtr, + >, + pub CreateIoBinding: ::std::option::Option< + unsafe extern "C" fn(session: *mut OrtSession, out: *mut *mut OrtIoBinding) -> OrtStatusPtr, + >, + pub ReleaseIoBinding: ::std::option::Option, + pub BindInput: ::std::option::Option< + unsafe extern "C" fn( + binding_ptr: *mut OrtIoBinding, + name: *const ::std::os::raw::c_char, + val_ptr: *const OrtValue, + ) -> OrtStatusPtr, + >, + pub BindOutput: ::std::option::Option< + unsafe extern "C" fn( + binding_ptr: *mut OrtIoBinding, + name: *const ::std::os::raw::c_char, + val_ptr: *const OrtValue, + ) -> OrtStatusPtr, + >, + pub BindOutputToDevice: ::std::option::Option< + unsafe extern "C" fn( + binding_ptr: *mut OrtIoBinding, + name: *const ::std::os::raw::c_char, + mem_info_ptr: *const OrtMemoryInfo, + ) -> OrtStatusPtr, + >, + pub GetBoundOutputNames: ::std::option::Option< + unsafe extern "C" fn( + binding_ptr: *const OrtIoBinding, + allocator: *mut OrtAllocator, + buffer: *mut *mut ::std::os::raw::c_char, + lengths: *mut *mut usize, + count: *mut usize, + ) -> OrtStatusPtr, + >, + pub GetBoundOutputValues: ::std::option::Option< + unsafe extern "C" fn( + binding_ptr: *const OrtIoBinding, + allocator: *mut OrtAllocator, + output: *mut *mut *mut OrtValue, + output_count: *mut usize, + ) -> OrtStatusPtr, + >, + #[doc = " \\brief Clears any previously set Inputs for an ::OrtIoBinding"] + pub ClearBoundInputs: + ::std::option::Option, + #[doc = " \\brief Clears any previously set Outputs for an ::OrtIoBinding"] + pub ClearBoundOutputs: + ::std::option::Option, + pub TensorAt: ::std::option::Option< + unsafe extern "C" fn( + value: *mut OrtValue, + location_values: *const i64, + location_values_count: usize, + out: *mut *mut ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub CreateAndRegisterAllocator: ::std::option::Option< + unsafe extern "C" fn( + env: *mut OrtEnv, + mem_info: *const OrtMemoryInfo, + arena_cfg: *const OrtArenaCfg, + ) -> OrtStatusPtr, + >, + pub SetLanguageProjection: ::std::option::Option< + unsafe extern "C" fn( + ort_env: *const OrtEnv, + projection: OrtLanguageProjection, + ) -> OrtStatusPtr, + >, + pub SessionGetProfilingStartTimeNs: ::std::option::Option< + unsafe extern "C" fn(session: *const OrtSession, out: *mut u64) -> OrtStatusPtr, + >, + pub SetGlobalIntraOpNumThreads: ::std::option::Option< + unsafe extern "C" fn( + tp_options: *mut OrtThreadingOptions, + intra_op_num_threads: ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub SetGlobalInterOpNumThreads: ::std::option::Option< + unsafe extern "C" fn( + tp_options: *mut OrtThreadingOptions, + inter_op_num_threads: ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub SetGlobalSpinControl: ::std::option::Option< + unsafe extern "C" fn( + tp_options: *mut OrtThreadingOptions, + allow_spinning: ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub AddInitializer: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + name: *const ::std::os::raw::c_char, + val: *const OrtValue, + ) -> OrtStatusPtr, + >, + pub CreateEnvWithCustomLoggerAndGlobalThreadPools: ::std::option::Option< + unsafe extern "C" fn( + logging_function: OrtLoggingFunction, + logger_param: *mut ::std::os::raw::c_void, + log_severity_level: OrtLoggingLevel, + logid: *const ::std::os::raw::c_char, + tp_options: *const OrtThreadingOptions, + out: *mut *mut OrtEnv, + ) -> OrtStatusPtr, + >, + pub SessionOptionsAppendExecutionProvider_CUDA: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + cuda_options: *const OrtCUDAProviderOptions, + ) -> OrtStatusPtr, + >, + pub SessionOptionsAppendExecutionProvider_ROCM: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + rocm_options: *const OrtROCMProviderOptions, + ) -> OrtStatusPtr, + >, + pub SessionOptionsAppendExecutionProvider_OpenVINO: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + provider_options: *const OrtOpenVINOProviderOptions, + ) -> OrtStatusPtr, + >, + pub SetGlobalDenormalAsZero: ::std::option::Option< + unsafe extern "C" fn(tp_options: *mut OrtThreadingOptions) -> OrtStatusPtr, + >, + pub CreateArenaCfg: ::std::option::Option< + unsafe extern "C" fn( + max_mem: usize, + arena_extend_strategy: ::std::os::raw::c_int, + initial_chunk_size_bytes: ::std::os::raw::c_int, + max_dead_bytes_per_chunk: ::std::os::raw::c_int, + out: *mut *mut OrtArenaCfg, + ) -> OrtStatusPtr, + >, + pub ReleaseArenaCfg: ::std::option::Option, + pub ModelMetadataGetGraphDescription: ::std::option::Option< + unsafe extern "C" fn( + model_metadata: *const OrtModelMetadata, + allocator: *mut OrtAllocator, + value: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub SessionOptionsAppendExecutionProvider_TensorRT: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + tensorrt_options: *const OrtTensorRTProviderOptions, + ) -> OrtStatusPtr, + >, + pub SetCurrentGpuDeviceId: ::std::option::Option< + unsafe extern "C" fn(device_id: ::std::os::raw::c_int) -> OrtStatusPtr, + >, + pub GetCurrentGpuDeviceId: ::std::option::Option< + unsafe extern "C" fn(device_id: *mut ::std::os::raw::c_int) -> OrtStatusPtr, + >, + pub KernelInfoGetAttributeArray_float: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtKernelInfo, + name: *const ::std::os::raw::c_char, + out: *mut f32, + size: *mut usize, + ) -> OrtStatusPtr, + >, + pub KernelInfoGetAttributeArray_int64: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtKernelInfo, + name: *const ::std::os::raw::c_char, + out: *mut i64, + size: *mut usize, + ) -> OrtStatusPtr, + >, + pub CreateArenaCfgV2: ::std::option::Option< + unsafe extern "C" fn( + arena_config_keys: *const *const ::std::os::raw::c_char, + arena_config_values: *const usize, + num_keys: usize, + out: *mut *mut OrtArenaCfg, + ) -> OrtStatusPtr, + >, + pub AddRunConfigEntry: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtRunOptions, + config_key: *const ::std::os::raw::c_char, + config_value: *const ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub CreatePrepackedWeightsContainer: ::std::option::Option< + unsafe extern "C" fn(out: *mut *mut OrtPrepackedWeightsContainer) -> OrtStatusPtr, + >, + pub ReleasePrepackedWeightsContainer: + ::std::option::Option, + pub CreateSessionWithPrepackedWeightsContainer: ::std::option::Option< + unsafe extern "C" fn( + env: *const OrtEnv, + model_path: *const ::std::os::raw::c_char, + options: *const OrtSessionOptions, + prepacked_weights_container: *mut OrtPrepackedWeightsContainer, + out: *mut *mut OrtSession, + ) -> OrtStatusPtr, + >, + pub CreateSessionFromArrayWithPrepackedWeightsContainer: ::std::option::Option< + unsafe extern "C" fn( + env: *const OrtEnv, + model_data: *const ::std::os::raw::c_void, + model_data_length: usize, + options: *const OrtSessionOptions, + prepacked_weights_container: *mut OrtPrepackedWeightsContainer, + out: *mut *mut OrtSession, + ) -> OrtStatusPtr, + >, + pub SessionOptionsAppendExecutionProvider_TensorRT_V2: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + tensorrt_options: *const OrtTensorRTProviderOptionsV2, + ) -> OrtStatusPtr, + >, + pub CreateTensorRTProviderOptions: ::std::option::Option< + unsafe extern "C" fn(out: *mut *mut OrtTensorRTProviderOptionsV2) -> OrtStatusPtr, + >, + pub UpdateTensorRTProviderOptions: ::std::option::Option< + unsafe extern "C" fn( + tensorrt_options: *mut OrtTensorRTProviderOptionsV2, + provider_options_keys: *const *const ::std::os::raw::c_char, + provider_options_values: *const *const ::std::os::raw::c_char, + num_keys: usize, + ) -> OrtStatusPtr, + >, + pub GetTensorRTProviderOptionsAsString: ::std::option::Option< + unsafe extern "C" fn( + tensorrt_options: *const OrtTensorRTProviderOptionsV2, + allocator: *mut OrtAllocator, + ptr: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + #[doc = " \\brief Release an ::OrtTensorRTProviderOptionsV2"] + #[doc = ""] + #[doc = " \\note This is an exception in the naming convention of other Release* functions, as the name of the method does not have the V2 suffix, but the type does"] + pub ReleaseTensorRTProviderOptions: + ::std::option::Option, + pub EnableOrtCustomOps: ::std::option::Option< + unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, + >, + pub RegisterAllocator: ::std::option::Option< + unsafe extern "C" fn(env: *mut OrtEnv, allocator: *mut OrtAllocator) -> OrtStatusPtr, + >, + pub UnregisterAllocator: ::std::option::Option< + unsafe extern "C" fn(env: *mut OrtEnv, mem_info: *const OrtMemoryInfo) -> OrtStatusPtr, + >, + pub IsSparseTensor: ::std::option::Option< + unsafe extern "C" fn( + value: *const OrtValue, + out: *mut ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub CreateSparseTensorAsOrtValue: ::std::option::Option< + unsafe extern "C" fn( + allocator: *mut OrtAllocator, + dense_shape: *const i64, + dense_shape_len: usize, + type_: ONNXTensorElementDataType, + out: *mut *mut OrtValue, + ) -> OrtStatusPtr, + >, + pub FillSparseTensorCoo: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *mut OrtValue, + data_mem_info: *const OrtMemoryInfo, + values_shape: *const i64, + values_shape_len: usize, + values: *const ::std::os::raw::c_void, + indices_data: *const i64, + indices_num: usize, + ) -> OrtStatusPtr, + >, + pub FillSparseTensorCsr: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *mut OrtValue, + data_mem_info: *const OrtMemoryInfo, + values_shape: *const i64, + values_shape_len: usize, + values: *const ::std::os::raw::c_void, + inner_indices_data: *const i64, + inner_indices_num: usize, + outer_indices_data: *const i64, + outer_indices_num: usize, + ) -> OrtStatusPtr, + >, + pub FillSparseTensorBlockSparse: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *mut OrtValue, + data_mem_info: *const OrtMemoryInfo, + values_shape: *const i64, + values_shape_len: usize, + values: *const ::std::os::raw::c_void, + indices_shape_data: *const i64, + indices_shape_len: usize, + indices_data: *const i32, + ) -> OrtStatusPtr, + >, + pub CreateSparseTensorWithValuesAsOrtValue: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtMemoryInfo, + p_data: *mut ::std::os::raw::c_void, + dense_shape: *const i64, + dense_shape_len: usize, + values_shape: *const i64, + values_shape_len: usize, + type_: ONNXTensorElementDataType, + out: *mut *mut OrtValue, + ) -> OrtStatusPtr, + >, + pub UseCooIndices: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *mut OrtValue, + indices_data: *mut i64, + indices_num: usize, + ) -> OrtStatusPtr, + >, + pub UseCsrIndices: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *mut OrtValue, + inner_data: *mut i64, + inner_num: usize, + outer_data: *mut i64, + outer_num: usize, + ) -> OrtStatusPtr, + >, + pub UseBlockSparseIndices: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *mut OrtValue, + indices_shape: *const i64, + indices_shape_len: usize, + indices_data: *mut i32, + ) -> OrtStatusPtr, + >, + pub GetSparseTensorFormat: ::std::option::Option< + unsafe extern "C" fn(ort_value: *const OrtValue, out: *mut OrtSparseFormat) -> OrtStatusPtr, + >, + pub GetSparseTensorValuesTypeAndShape: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *const OrtValue, + out: *mut *mut OrtTensorTypeAndShapeInfo, + ) -> OrtStatusPtr, + >, + pub GetSparseTensorValues: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *const OrtValue, + out: *mut *const ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub GetSparseTensorIndicesTypeShape: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *const OrtValue, + indices_format: OrtSparseIndicesFormat, + out: *mut *mut OrtTensorTypeAndShapeInfo, + ) -> OrtStatusPtr, + >, + pub GetSparseTensorIndices: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *const OrtValue, + indices_format: OrtSparseIndicesFormat, + num_indices: *mut usize, + indices: *mut *const ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub HasValue: ::std::option::Option< + unsafe extern "C" fn( + value: *const OrtValue, + out: *mut ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub KernelContext_GetGPUComputeStream: ::std::option::Option< + unsafe extern "C" fn( + context: *const OrtKernelContext, + out: *mut *mut ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub GetTensorMemoryInfo: ::std::option::Option< + unsafe extern "C" fn( + value: *const OrtValue, + mem_info: *mut *const OrtMemoryInfo, + ) -> OrtStatusPtr, + >, + pub GetExecutionProviderApi: ::std::option::Option< + unsafe extern "C" fn( + provider_name: *const ::std::os::raw::c_char, + version: u32, + provider_api: *mut *const ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub SessionOptionsSetCustomCreateThreadFn: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + ort_custom_create_thread_fn: OrtCustomCreateThreadFn, + ) -> OrtStatusPtr, + >, + pub SessionOptionsSetCustomThreadCreationOptions: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + ort_custom_thread_creation_options: *mut ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub SessionOptionsSetCustomJoinThreadFn: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + ort_custom_join_thread_fn: OrtCustomJoinThreadFn, + ) -> OrtStatusPtr, + >, + pub SetGlobalCustomCreateThreadFn: ::std::option::Option< + unsafe extern "C" fn( + tp_options: *mut OrtThreadingOptions, + ort_custom_create_thread_fn: OrtCustomCreateThreadFn, + ) -> OrtStatusPtr, + >, + pub SetGlobalCustomThreadCreationOptions: ::std::option::Option< + unsafe extern "C" fn( + tp_options: *mut OrtThreadingOptions, + ort_custom_thread_creation_options: *mut ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub SetGlobalCustomJoinThreadFn: ::std::option::Option< + unsafe extern "C" fn( + tp_options: *mut OrtThreadingOptions, + ort_custom_join_thread_fn: OrtCustomJoinThreadFn, + ) -> OrtStatusPtr, + >, + pub SynchronizeBoundInputs: + ::std::option::Option OrtStatusPtr>, + pub SynchronizeBoundOutputs: + ::std::option::Option OrtStatusPtr>, + pub SessionOptionsAppendExecutionProvider_CUDA_V2: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + cuda_options: *const OrtCUDAProviderOptionsV2, + ) -> OrtStatusPtr, + >, + pub CreateCUDAProviderOptions: ::std::option::Option< + unsafe extern "C" fn(out: *mut *mut OrtCUDAProviderOptionsV2) -> OrtStatusPtr, + >, + pub UpdateCUDAProviderOptions: ::std::option::Option< + unsafe extern "C" fn( + cuda_options: *mut OrtCUDAProviderOptionsV2, + provider_options_keys: *const *const ::std::os::raw::c_char, + provider_options_values: *const *const ::std::os::raw::c_char, + num_keys: usize, + ) -> OrtStatusPtr, + >, + pub GetCUDAProviderOptionsAsString: ::std::option::Option< + unsafe extern "C" fn( + cuda_options: *const OrtCUDAProviderOptionsV2, + allocator: *mut OrtAllocator, + ptr: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + #[doc = " \\brief Release an ::OrtCUDAProviderOptionsV2"] + #[doc = ""] + #[doc = " \\note This is an exception in the naming convention of other Release* functions, as the name of the method does not have the V2 suffix, but the type does"] + #[doc = ""] + #[doc = " \\since Version 1.11."] + pub ReleaseCUDAProviderOptions: + ::std::option::Option, + pub SessionOptionsAppendExecutionProvider_MIGraphX: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + migraphx_options: *const OrtMIGraphXProviderOptions, + ) -> OrtStatusPtr, + >, +} +#[test] +fn bindgen_test_layout_OrtApi() { assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateSessionWithPrepackedWeightsContainer - as *const _ as usize - }, - 1344usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateSessionWithPrepackedWeightsContainer) - ) + ::std::mem::size_of::(), + 1680usize, + concat!("Size of: ", stringify!(OrtApi)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateSessionFromArrayWithPrepackedWeightsContainer - as *const _ as usize - }, - 1352usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateSessionFromArrayWithPrepackedWeightsContainer) - ) + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(OrtApi)) ); + fn test_field_CreateStatus() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateStatus) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateStatus) + ) + ); + } + test_field_CreateStatus(); + fn test_field_GetErrorCode() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetErrorCode) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetErrorCode) + ) + ); + } + test_field_GetErrorCode(); + fn test_field_GetErrorMessage() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetErrorMessage) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetErrorMessage) + ) + ); + } + test_field_GetErrorMessage(); + fn test_field_CreateEnv() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateEnv) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateEnv) + ) + ); + } + test_field_CreateEnv(); + fn test_field_CreateEnvWithCustomLogger() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateEnvWithCustomLogger) as usize - ptr as usize + }, + 32usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateEnvWithCustomLogger) + ) + ); + } + test_field_CreateEnvWithCustomLogger(); + fn test_field_EnableTelemetryEvents() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).EnableTelemetryEvents) as usize - ptr as usize + }, + 40usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(EnableTelemetryEvents) + ) + ); + } + test_field_EnableTelemetryEvents(); + fn test_field_DisableTelemetryEvents() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).DisableTelemetryEvents) as usize - ptr as usize + }, + 48usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(DisableTelemetryEvents) + ) + ); + } + test_field_DisableTelemetryEvents(); + fn test_field_CreateSession() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateSession) as usize - ptr as usize + }, + 56usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateSession) + ) + ); + } + test_field_CreateSession(); + fn test_field_CreateSessionFromArray() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateSessionFromArray) as usize - ptr as usize + }, + 64usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateSessionFromArray) + ) + ); + } + test_field_CreateSessionFromArray(); + fn test_field_Run() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).Run) as usize - ptr as usize + }, + 72usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(Run) + ) + ); + } + test_field_Run(); + fn test_field_CreateSessionOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateSessionOptions) as usize - ptr as usize + }, + 80usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateSessionOptions) + ) + ); + } + test_field_CreateSessionOptions(); + fn test_field_SetOptimizedModelFilePath() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetOptimizedModelFilePath) as usize - ptr as usize + }, + 88usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetOptimizedModelFilePath) + ) + ); + } + test_field_SetOptimizedModelFilePath(); + fn test_field_CloneSessionOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CloneSessionOptions) as usize - ptr as usize + }, + 96usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CloneSessionOptions) + ) + ); + } + test_field_CloneSessionOptions(); + fn test_field_SetSessionExecutionMode() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetSessionExecutionMode) as usize - ptr as usize + }, + 104usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetSessionExecutionMode) + ) + ); + } + test_field_SetSessionExecutionMode(); + fn test_field_EnableProfiling() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).EnableProfiling) as usize - ptr as usize + }, + 112usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(EnableProfiling) + ) + ); + } + test_field_EnableProfiling(); + fn test_field_DisableProfiling() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).DisableProfiling) as usize - ptr as usize + }, + 120usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(DisableProfiling) + ) + ); + } + test_field_DisableProfiling(); + fn test_field_EnableMemPattern() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).EnableMemPattern) as usize - ptr as usize + }, + 128usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(EnableMemPattern) + ) + ); + } + test_field_EnableMemPattern(); + fn test_field_DisableMemPattern() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).DisableMemPattern) as usize - ptr as usize + }, + 136usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(DisableMemPattern) + ) + ); + } + test_field_DisableMemPattern(); + fn test_field_EnableCpuMemArena() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).EnableCpuMemArena) as usize - ptr as usize + }, + 144usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(EnableCpuMemArena) + ) + ); + } + test_field_EnableCpuMemArena(); + fn test_field_DisableCpuMemArena() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).DisableCpuMemArena) as usize - ptr as usize + }, + 152usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(DisableCpuMemArena) + ) + ); + } + test_field_DisableCpuMemArena(); + fn test_field_SetSessionLogId() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetSessionLogId) as usize - ptr as usize + }, + 160usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetSessionLogId) + ) + ); + } + test_field_SetSessionLogId(); + fn test_field_SetSessionLogVerbosityLevel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetSessionLogVerbosityLevel) as usize - ptr as usize + }, + 168usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetSessionLogVerbosityLevel) + ) + ); + } + test_field_SetSessionLogVerbosityLevel(); + fn test_field_SetSessionLogSeverityLevel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetSessionLogSeverityLevel) as usize - ptr as usize + }, + 176usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetSessionLogSeverityLevel) + ) + ); + } + test_field_SetSessionLogSeverityLevel(); + fn test_field_SetSessionGraphOptimizationLevel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetSessionGraphOptimizationLevel) as usize + - ptr as usize + }, + 184usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetSessionGraphOptimizationLevel) + ) + ); + } + test_field_SetSessionGraphOptimizationLevel(); + fn test_field_SetIntraOpNumThreads() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetIntraOpNumThreads) as usize - ptr as usize + }, + 192usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetIntraOpNumThreads) + ) + ); + } + test_field_SetIntraOpNumThreads(); + fn test_field_SetInterOpNumThreads() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetInterOpNumThreads) as usize - ptr as usize + }, + 200usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetInterOpNumThreads) + ) + ); + } + test_field_SetInterOpNumThreads(); + fn test_field_CreateCustomOpDomain() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateCustomOpDomain) as usize - ptr as usize + }, + 208usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateCustomOpDomain) + ) + ); + } + test_field_CreateCustomOpDomain(); + fn test_field_CustomOpDomain_Add() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CustomOpDomain_Add) as usize - ptr as usize + }, + 216usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CustomOpDomain_Add) + ) + ); + } + test_field_CustomOpDomain_Add(); + fn test_field_AddCustomOpDomain() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AddCustomOpDomain) as usize - ptr as usize + }, + 224usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AddCustomOpDomain) + ) + ); + } + test_field_AddCustomOpDomain(); + fn test_field_RegisterCustomOpsLibrary() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RegisterCustomOpsLibrary) as usize - ptr as usize + }, + 232usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RegisterCustomOpsLibrary) + ) + ); + } + test_field_RegisterCustomOpsLibrary(); + fn test_field_SessionGetInputCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetInputCount) as usize - ptr as usize + }, + 240usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetInputCount) + ) + ); + } + test_field_SessionGetInputCount(); + fn test_field_SessionGetOutputCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetOutputCount) as usize - ptr as usize + }, + 248usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetOutputCount) + ) + ); + } + test_field_SessionGetOutputCount(); + fn test_field_SessionGetOverridableInitializerCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetOverridableInitializerCount) as usize + - ptr as usize + }, + 256usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetOverridableInitializerCount) + ) + ); + } + test_field_SessionGetOverridableInitializerCount(); + fn test_field_SessionGetInputTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetInputTypeInfo) as usize - ptr as usize + }, + 264usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetInputTypeInfo) + ) + ); + } + test_field_SessionGetInputTypeInfo(); + fn test_field_SessionGetOutputTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetOutputTypeInfo) as usize - ptr as usize + }, + 272usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetOutputTypeInfo) + ) + ); + } + test_field_SessionGetOutputTypeInfo(); + fn test_field_SessionGetOverridableInitializerTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetOverridableInitializerTypeInfo) as usize + - ptr as usize + }, + 280usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetOverridableInitializerTypeInfo) + ) + ); + } + test_field_SessionGetOverridableInitializerTypeInfo(); + fn test_field_SessionGetInputName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetInputName) as usize - ptr as usize + }, + 288usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetInputName) + ) + ); + } + test_field_SessionGetInputName(); + fn test_field_SessionGetOutputName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetOutputName) as usize - ptr as usize + }, + 296usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetOutputName) + ) + ); + } + test_field_SessionGetOutputName(); + fn test_field_SessionGetOverridableInitializerName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetOverridableInitializerName) as usize + - ptr as usize + }, + 304usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetOverridableInitializerName) + ) + ); + } + test_field_SessionGetOverridableInitializerName(); + fn test_field_CreateRunOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateRunOptions) as usize - ptr as usize + }, + 312usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateRunOptions) + ) + ); + } + test_field_CreateRunOptions(); + fn test_field_RunOptionsSetRunLogVerbosityLevel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsSetRunLogVerbosityLevel) as usize + - ptr as usize + }, + 320usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsSetRunLogVerbosityLevel) + ) + ); + } + test_field_RunOptionsSetRunLogVerbosityLevel(); + fn test_field_RunOptionsSetRunLogSeverityLevel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsSetRunLogSeverityLevel) as usize + - ptr as usize + }, + 328usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsSetRunLogSeverityLevel) + ) + ); + } + test_field_RunOptionsSetRunLogSeverityLevel(); + fn test_field_RunOptionsSetRunTag() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsSetRunTag) as usize - ptr as usize + }, + 336usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsSetRunTag) + ) + ); + } + test_field_RunOptionsSetRunTag(); + fn test_field_RunOptionsGetRunLogVerbosityLevel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsGetRunLogVerbosityLevel) as usize + - ptr as usize + }, + 344usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsGetRunLogVerbosityLevel) + ) + ); + } + test_field_RunOptionsGetRunLogVerbosityLevel(); + fn test_field_RunOptionsGetRunLogSeverityLevel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsGetRunLogSeverityLevel) as usize + - ptr as usize + }, + 352usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsGetRunLogSeverityLevel) + ) + ); + } + test_field_RunOptionsGetRunLogSeverityLevel(); + fn test_field_RunOptionsGetRunTag() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsGetRunTag) as usize - ptr as usize + }, + 360usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsGetRunTag) + ) + ); + } + test_field_RunOptionsGetRunTag(); + fn test_field_RunOptionsSetTerminate() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsSetTerminate) as usize - ptr as usize + }, + 368usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsSetTerminate) + ) + ); + } + test_field_RunOptionsSetTerminate(); + fn test_field_RunOptionsUnsetTerminate() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsUnsetTerminate) as usize - ptr as usize + }, + 376usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsUnsetTerminate) + ) + ); + } + test_field_RunOptionsUnsetTerminate(); + fn test_field_CreateTensorAsOrtValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateTensorAsOrtValue) as usize - ptr as usize + }, + 384usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateTensorAsOrtValue) + ) + ); + } + test_field_CreateTensorAsOrtValue(); + fn test_field_CreateTensorWithDataAsOrtValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateTensorWithDataAsOrtValue) as usize - ptr as usize + }, + 392usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateTensorWithDataAsOrtValue) + ) + ); + } + test_field_CreateTensorWithDataAsOrtValue(); + fn test_field_IsTensor() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).IsTensor) as usize - ptr as usize + }, + 400usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(IsTensor) + ) + ); + } + test_field_IsTensor(); + fn test_field_GetTensorMutableData() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetTensorMutableData) as usize - ptr as usize + }, + 408usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetTensorMutableData) + ) + ); + } + test_field_GetTensorMutableData(); + fn test_field_FillStringTensor() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).FillStringTensor) as usize - ptr as usize + }, + 416usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(FillStringTensor) + ) + ); + } + test_field_FillStringTensor(); + fn test_field_GetStringTensorDataLength() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetStringTensorDataLength) as usize - ptr as usize + }, + 424usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetStringTensorDataLength) + ) + ); + } + test_field_GetStringTensorDataLength(); + fn test_field_GetStringTensorContent() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetStringTensorContent) as usize - ptr as usize + }, + 432usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetStringTensorContent) + ) + ); + } + test_field_GetStringTensorContent(); + fn test_field_CastTypeInfoToTensorInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CastTypeInfoToTensorInfo) as usize - ptr as usize + }, + 440usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CastTypeInfoToTensorInfo) + ) + ); + } + test_field_CastTypeInfoToTensorInfo(); + fn test_field_GetOnnxTypeFromTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetOnnxTypeFromTypeInfo) as usize - ptr as usize + }, + 448usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetOnnxTypeFromTypeInfo) + ) + ); + } + test_field_GetOnnxTypeFromTypeInfo(); + fn test_field_CreateTensorTypeAndShapeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateTensorTypeAndShapeInfo) as usize - ptr as usize + }, + 456usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateTensorTypeAndShapeInfo) + ) + ); + } + test_field_CreateTensorTypeAndShapeInfo(); + fn test_field_SetTensorElementType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetTensorElementType) as usize - ptr as usize + }, + 464usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetTensorElementType) + ) + ); + } + test_field_SetTensorElementType(); + fn test_field_SetDimensions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetDimensions) as usize - ptr as usize + }, + 472usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetDimensions) + ) + ); + } + test_field_SetDimensions(); + fn test_field_GetTensorElementType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetTensorElementType) as usize - ptr as usize + }, + 480usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetTensorElementType) + ) + ); + } + test_field_GetTensorElementType(); + fn test_field_GetDimensionsCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetDimensionsCount) as usize - ptr as usize + }, + 488usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetDimensionsCount) + ) + ); + } + test_field_GetDimensionsCount(); + fn test_field_GetDimensions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetDimensions) as usize - ptr as usize + }, + 496usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetDimensions) + ) + ); + } + test_field_GetDimensions(); + fn test_field_GetSymbolicDimensions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetSymbolicDimensions) as usize - ptr as usize + }, + 504usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetSymbolicDimensions) + ) + ); + } + test_field_GetSymbolicDimensions(); + fn test_field_GetTensorShapeElementCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetTensorShapeElementCount) as usize - ptr as usize + }, + 512usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetTensorShapeElementCount) + ) + ); + } + test_field_GetTensorShapeElementCount(); + fn test_field_GetTensorTypeAndShape() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetTensorTypeAndShape) as usize - ptr as usize + }, + 520usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetTensorTypeAndShape) + ) + ); + } + test_field_GetTensorTypeAndShape(); + fn test_field_GetTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetTypeInfo) as usize - ptr as usize + }, + 528usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetTypeInfo) + ) + ); + } + test_field_GetTypeInfo(); + fn test_field_GetValueType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetValueType) as usize - ptr as usize + }, + 536usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetValueType) + ) + ); + } + test_field_GetValueType(); + fn test_field_CreateMemoryInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateMemoryInfo) as usize - ptr as usize + }, + 544usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateMemoryInfo) + ) + ); + } + test_field_CreateMemoryInfo(); + fn test_field_CreateCpuMemoryInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateCpuMemoryInfo) as usize - ptr as usize + }, + 552usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateCpuMemoryInfo) + ) + ); + } + test_field_CreateCpuMemoryInfo(); + fn test_field_CompareMemoryInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CompareMemoryInfo) as usize - ptr as usize + }, + 560usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CompareMemoryInfo) + ) + ); + } + test_field_CompareMemoryInfo(); + fn test_field_MemoryInfoGetName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).MemoryInfoGetName) as usize - ptr as usize + }, + 568usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(MemoryInfoGetName) + ) + ); + } + test_field_MemoryInfoGetName(); + fn test_field_MemoryInfoGetId() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).MemoryInfoGetId) as usize - ptr as usize + }, + 576usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(MemoryInfoGetId) + ) + ); + } + test_field_MemoryInfoGetId(); + fn test_field_MemoryInfoGetMemType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).MemoryInfoGetMemType) as usize - ptr as usize + }, + 584usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(MemoryInfoGetMemType) + ) + ); + } + test_field_MemoryInfoGetMemType(); + fn test_field_MemoryInfoGetType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).MemoryInfoGetType) as usize - ptr as usize + }, + 592usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(MemoryInfoGetType) + ) + ); + } + test_field_MemoryInfoGetType(); + fn test_field_AllocatorAlloc() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AllocatorAlloc) as usize - ptr as usize + }, + 600usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AllocatorAlloc) + ) + ); + } + test_field_AllocatorAlloc(); + fn test_field_AllocatorFree() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AllocatorFree) as usize - ptr as usize + }, + 608usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AllocatorFree) + ) + ); + } + test_field_AllocatorFree(); + fn test_field_AllocatorGetInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AllocatorGetInfo) as usize - ptr as usize + }, + 616usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AllocatorGetInfo) + ) + ); + } + test_field_AllocatorGetInfo(); + fn test_field_GetAllocatorWithDefaultOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetAllocatorWithDefaultOptions) as usize - ptr as usize + }, + 624usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetAllocatorWithDefaultOptions) + ) + ); + } + test_field_GetAllocatorWithDefaultOptions(); + fn test_field_AddFreeDimensionOverride() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AddFreeDimensionOverride) as usize - ptr as usize + }, + 632usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AddFreeDimensionOverride) + ) + ); + } + test_field_AddFreeDimensionOverride(); + fn test_field_GetValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetValue) as usize - ptr as usize + }, + 640usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetValue) + ) + ); + } + test_field_GetValue(); + fn test_field_GetValueCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetValueCount) as usize - ptr as usize + }, + 648usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetValueCount) + ) + ); + } + test_field_GetValueCount(); + fn test_field_CreateValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateValue) as usize - ptr as usize + }, + 656usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateValue) + ) + ); + } + test_field_CreateValue(); + fn test_field_CreateOpaqueValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateOpaqueValue) as usize - ptr as usize + }, + 664usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateOpaqueValue) + ) + ); + } + test_field_CreateOpaqueValue(); + fn test_field_GetOpaqueValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetOpaqueValue) as usize - ptr as usize + }, + 672usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetOpaqueValue) + ) + ); + } + test_field_GetOpaqueValue(); + fn test_field_KernelInfoGetAttribute_float() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelInfoGetAttribute_float) as usize - ptr as usize + }, + 680usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelInfoGetAttribute_float) + ) + ); + } + test_field_KernelInfoGetAttribute_float(); + fn test_field_KernelInfoGetAttribute_int64() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelInfoGetAttribute_int64) as usize - ptr as usize + }, + 688usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelInfoGetAttribute_int64) + ) + ); + } + test_field_KernelInfoGetAttribute_int64(); + fn test_field_KernelInfoGetAttribute_string() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelInfoGetAttribute_string) as usize - ptr as usize + }, + 696usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelInfoGetAttribute_string) + ) + ); + } + test_field_KernelInfoGetAttribute_string(); + fn test_field_KernelContext_GetInputCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelContext_GetInputCount) as usize - ptr as usize + }, + 704usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelContext_GetInputCount) + ) + ); + } + test_field_KernelContext_GetInputCount(); + fn test_field_KernelContext_GetOutputCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelContext_GetOutputCount) as usize - ptr as usize + }, + 712usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelContext_GetOutputCount) + ) + ); + } + test_field_KernelContext_GetOutputCount(); + fn test_field_KernelContext_GetInput() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelContext_GetInput) as usize - ptr as usize + }, + 720usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelContext_GetInput) + ) + ); + } + test_field_KernelContext_GetInput(); + fn test_field_KernelContext_GetOutput() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelContext_GetOutput) as usize - ptr as usize + }, + 728usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelContext_GetOutput) + ) + ); + } + test_field_KernelContext_GetOutput(); + fn test_field_ReleaseEnv() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseEnv) as usize - ptr as usize + }, + 736usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseEnv) + ) + ); + } + test_field_ReleaseEnv(); + fn test_field_ReleaseStatus() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseStatus) as usize - ptr as usize + }, + 744usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseStatus) + ) + ); + } + test_field_ReleaseStatus(); + fn test_field_ReleaseMemoryInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseMemoryInfo) as usize - ptr as usize + }, + 752usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseMemoryInfo) + ) + ); + } + test_field_ReleaseMemoryInfo(); + fn test_field_ReleaseSession() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseSession) as usize - ptr as usize + }, + 760usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseSession) + ) + ); + } + test_field_ReleaseSession(); + fn test_field_ReleaseValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseValue) as usize - ptr as usize + }, + 768usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseValue) + ) + ); + } + test_field_ReleaseValue(); + fn test_field_ReleaseRunOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseRunOptions) as usize - ptr as usize + }, + 776usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseRunOptions) + ) + ); + } + test_field_ReleaseRunOptions(); + fn test_field_ReleaseTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseTypeInfo) as usize - ptr as usize + }, + 784usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseTypeInfo) + ) + ); + } + test_field_ReleaseTypeInfo(); + fn test_field_ReleaseTensorTypeAndShapeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseTensorTypeAndShapeInfo) as usize - ptr as usize + }, + 792usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseTensorTypeAndShapeInfo) + ) + ); + } + test_field_ReleaseTensorTypeAndShapeInfo(); + fn test_field_ReleaseSessionOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseSessionOptions) as usize - ptr as usize + }, + 800usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseSessionOptions) + ) + ); + } + test_field_ReleaseSessionOptions(); + fn test_field_ReleaseCustomOpDomain() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseCustomOpDomain) as usize - ptr as usize + }, + 808usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseCustomOpDomain) + ) + ); + } + test_field_ReleaseCustomOpDomain(); + fn test_field_GetDenotationFromTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetDenotationFromTypeInfo) as usize - ptr as usize + }, + 816usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetDenotationFromTypeInfo) + ) + ); + } + test_field_GetDenotationFromTypeInfo(); + fn test_field_CastTypeInfoToMapTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CastTypeInfoToMapTypeInfo) as usize - ptr as usize + }, + 824usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CastTypeInfoToMapTypeInfo) + ) + ); + } + test_field_CastTypeInfoToMapTypeInfo(); + fn test_field_CastTypeInfoToSequenceTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CastTypeInfoToSequenceTypeInfo) as usize - ptr as usize + }, + 832usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CastTypeInfoToSequenceTypeInfo) + ) + ); + } + test_field_CastTypeInfoToSequenceTypeInfo(); + fn test_field_GetMapKeyType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetMapKeyType) as usize - ptr as usize + }, + 840usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetMapKeyType) + ) + ); + } + test_field_GetMapKeyType(); + fn test_field_GetMapValueType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetMapValueType) as usize - ptr as usize + }, + 848usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetMapValueType) + ) + ); + } + test_field_GetMapValueType(); + fn test_field_GetSequenceElementType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetSequenceElementType) as usize - ptr as usize + }, + 856usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetSequenceElementType) + ) + ); + } + test_field_GetSequenceElementType(); + fn test_field_ReleaseMapTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseMapTypeInfo) as usize - ptr as usize + }, + 864usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseMapTypeInfo) + ) + ); + } + test_field_ReleaseMapTypeInfo(); + fn test_field_ReleaseSequenceTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseSequenceTypeInfo) as usize - ptr as usize + }, + 872usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseSequenceTypeInfo) + ) + ); + } + test_field_ReleaseSequenceTypeInfo(); + fn test_field_SessionEndProfiling() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionEndProfiling) as usize - ptr as usize + }, + 880usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionEndProfiling) + ) + ); + } + test_field_SessionEndProfiling(); + fn test_field_SessionGetModelMetadata() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetModelMetadata) as usize - ptr as usize + }, + 888usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetModelMetadata) + ) + ); + } + test_field_SessionGetModelMetadata(); + fn test_field_ModelMetadataGetProducerName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataGetProducerName) as usize - ptr as usize + }, + 896usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataGetProducerName) + ) + ); + } + test_field_ModelMetadataGetProducerName(); + fn test_field_ModelMetadataGetGraphName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataGetGraphName) as usize - ptr as usize + }, + 904usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataGetGraphName) + ) + ); + } + test_field_ModelMetadataGetGraphName(); + fn test_field_ModelMetadataGetDomain() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataGetDomain) as usize - ptr as usize + }, + 912usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataGetDomain) + ) + ); + } + test_field_ModelMetadataGetDomain(); + fn test_field_ModelMetadataGetDescription() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataGetDescription) as usize - ptr as usize + }, + 920usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataGetDescription) + ) + ); + } + test_field_ModelMetadataGetDescription(); + fn test_field_ModelMetadataLookupCustomMetadataMap() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataLookupCustomMetadataMap) as usize + - ptr as usize + }, + 928usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataLookupCustomMetadataMap) + ) + ); + } + test_field_ModelMetadataLookupCustomMetadataMap(); + fn test_field_ModelMetadataGetVersion() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataGetVersion) as usize - ptr as usize + }, + 936usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataGetVersion) + ) + ); + } + test_field_ModelMetadataGetVersion(); + fn test_field_ReleaseModelMetadata() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseModelMetadata) as usize - ptr as usize + }, + 944usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseModelMetadata) + ) + ); + } + test_field_ReleaseModelMetadata(); + fn test_field_CreateEnvWithGlobalThreadPools() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateEnvWithGlobalThreadPools) as usize - ptr as usize + }, + 952usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateEnvWithGlobalThreadPools) + ) + ); + } + test_field_CreateEnvWithGlobalThreadPools(); + fn test_field_DisablePerSessionThreads() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).DisablePerSessionThreads) as usize - ptr as usize + }, + 960usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(DisablePerSessionThreads) + ) + ); + } + test_field_DisablePerSessionThreads(); + fn test_field_CreateThreadingOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateThreadingOptions) as usize - ptr as usize + }, + 968usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateThreadingOptions) + ) + ); + } + test_field_CreateThreadingOptions(); + fn test_field_ReleaseThreadingOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseThreadingOptions) as usize - ptr as usize + }, + 976usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseThreadingOptions) + ) + ); + } + test_field_ReleaseThreadingOptions(); + fn test_field_ModelMetadataGetCustomMetadataMapKeys() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataGetCustomMetadataMapKeys) as usize + - ptr as usize + }, + 984usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataGetCustomMetadataMapKeys) + ) + ); + } + test_field_ModelMetadataGetCustomMetadataMapKeys(); + fn test_field_AddFreeDimensionOverrideByName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AddFreeDimensionOverrideByName) as usize - ptr as usize + }, + 992usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AddFreeDimensionOverrideByName) + ) + ); + } + test_field_AddFreeDimensionOverrideByName(); + fn test_field_GetAvailableProviders() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetAvailableProviders) as usize - ptr as usize + }, + 1000usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetAvailableProviders) + ) + ); + } + test_field_GetAvailableProviders(); + fn test_field_ReleaseAvailableProviders() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseAvailableProviders) as usize - ptr as usize + }, + 1008usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseAvailableProviders) + ) + ); + } + test_field_ReleaseAvailableProviders(); + fn test_field_GetStringTensorElementLength() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetStringTensorElementLength) as usize - ptr as usize + }, + 1016usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetStringTensorElementLength) + ) + ); + } + test_field_GetStringTensorElementLength(); + fn test_field_GetStringTensorElement() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetStringTensorElement) as usize - ptr as usize + }, + 1024usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetStringTensorElement) + ) + ); + } + test_field_GetStringTensorElement(); + fn test_field_FillStringTensorElement() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).FillStringTensorElement) as usize - ptr as usize + }, + 1032usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(FillStringTensorElement) + ) + ); + } + test_field_FillStringTensorElement(); + fn test_field_AddSessionConfigEntry() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AddSessionConfigEntry) as usize - ptr as usize + }, + 1040usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AddSessionConfigEntry) + ) + ); + } + test_field_AddSessionConfigEntry(); + fn test_field_CreateAllocator() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateAllocator) as usize - ptr as usize + }, + 1048usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateAllocator) + ) + ); + } + test_field_CreateAllocator(); + fn test_field_ReleaseAllocator() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseAllocator) as usize - ptr as usize + }, + 1056usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseAllocator) + ) + ); + } + test_field_ReleaseAllocator(); + fn test_field_RunWithBinding() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunWithBinding) as usize - ptr as usize + }, + 1064usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunWithBinding) + ) + ); + } + test_field_RunWithBinding(); + fn test_field_CreateIoBinding() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateIoBinding) as usize - ptr as usize + }, + 1072usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateIoBinding) + ) + ); + } + test_field_CreateIoBinding(); + fn test_field_ReleaseIoBinding() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseIoBinding) as usize - ptr as usize + }, + 1080usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseIoBinding) + ) + ); + } + test_field_ReleaseIoBinding(); + fn test_field_BindInput() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).BindInput) as usize - ptr as usize + }, + 1088usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(BindInput) + ) + ); + } + test_field_BindInput(); + fn test_field_BindOutput() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).BindOutput) as usize - ptr as usize + }, + 1096usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(BindOutput) + ) + ); + } + test_field_BindOutput(); + fn test_field_BindOutputToDevice() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).BindOutputToDevice) as usize - ptr as usize + }, + 1104usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(BindOutputToDevice) + ) + ); + } + test_field_BindOutputToDevice(); + fn test_field_GetBoundOutputNames() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetBoundOutputNames) as usize - ptr as usize + }, + 1112usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetBoundOutputNames) + ) + ); + } + test_field_GetBoundOutputNames(); + fn test_field_GetBoundOutputValues() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetBoundOutputValues) as usize - ptr as usize + }, + 1120usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetBoundOutputValues) + ) + ); + } + test_field_GetBoundOutputValues(); + fn test_field_ClearBoundInputs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ClearBoundInputs) as usize - ptr as usize + }, + 1128usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ClearBoundInputs) + ) + ); + } + test_field_ClearBoundInputs(); + fn test_field_ClearBoundOutputs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ClearBoundOutputs) as usize - ptr as usize + }, + 1136usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ClearBoundOutputs) + ) + ); + } + test_field_ClearBoundOutputs(); + fn test_field_TensorAt() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).TensorAt) as usize - ptr as usize + }, + 1144usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(TensorAt) + ) + ); + } + test_field_TensorAt(); + fn test_field_CreateAndRegisterAllocator() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateAndRegisterAllocator) as usize - ptr as usize + }, + 1152usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateAndRegisterAllocator) + ) + ); + } + test_field_CreateAndRegisterAllocator(); + fn test_field_SetLanguageProjection() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetLanguageProjection) as usize - ptr as usize + }, + 1160usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetLanguageProjection) + ) + ); + } + test_field_SetLanguageProjection(); + fn test_field_SessionGetProfilingStartTimeNs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetProfilingStartTimeNs) as usize - ptr as usize + }, + 1168usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetProfilingStartTimeNs) + ) + ); + } + test_field_SessionGetProfilingStartTimeNs(); + fn test_field_SetGlobalIntraOpNumThreads() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetGlobalIntraOpNumThreads) as usize - ptr as usize + }, + 1176usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetGlobalIntraOpNumThreads) + ) + ); + } + test_field_SetGlobalIntraOpNumThreads(); + fn test_field_SetGlobalInterOpNumThreads() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetGlobalInterOpNumThreads) as usize - ptr as usize + }, + 1184usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetGlobalInterOpNumThreads) + ) + ); + } + test_field_SetGlobalInterOpNumThreads(); + fn test_field_SetGlobalSpinControl() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetGlobalSpinControl) as usize - ptr as usize + }, + 1192usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetGlobalSpinControl) + ) + ); + } + test_field_SetGlobalSpinControl(); + fn test_field_AddInitializer() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AddInitializer) as usize - ptr as usize + }, + 1200usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AddInitializer) + ) + ); + } + test_field_AddInitializer(); + fn test_field_CreateEnvWithCustomLoggerAndGlobalThreadPools() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateEnvWithCustomLoggerAndGlobalThreadPools) as usize + - ptr as usize + }, + 1208usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateEnvWithCustomLoggerAndGlobalThreadPools) + ) + ); + } + test_field_CreateEnvWithCustomLoggerAndGlobalThreadPools(); + fn test_field_SessionOptionsAppendExecutionProvider_CUDA() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsAppendExecutionProvider_CUDA) as usize + - ptr as usize + }, + 1216usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsAppendExecutionProvider_CUDA) + ) + ); + } + test_field_SessionOptionsAppendExecutionProvider_CUDA(); + fn test_field_SessionOptionsAppendExecutionProvider_ROCM() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsAppendExecutionProvider_ROCM) as usize + - ptr as usize + }, + 1224usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsAppendExecutionProvider_ROCM) + ) + ); + } + test_field_SessionOptionsAppendExecutionProvider_ROCM(); + fn test_field_SessionOptionsAppendExecutionProvider_OpenVINO() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsAppendExecutionProvider_OpenVINO) as usize + - ptr as usize + }, + 1232usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsAppendExecutionProvider_OpenVINO) + ) + ); + } + test_field_SessionOptionsAppendExecutionProvider_OpenVINO(); + fn test_field_SetGlobalDenormalAsZero() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetGlobalDenormalAsZero) as usize - ptr as usize + }, + 1240usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetGlobalDenormalAsZero) + ) + ); + } + test_field_SetGlobalDenormalAsZero(); + fn test_field_CreateArenaCfg() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateArenaCfg) as usize - ptr as usize + }, + 1248usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateArenaCfg) + ) + ); + } + test_field_CreateArenaCfg(); + fn test_field_ReleaseArenaCfg() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseArenaCfg) as usize - ptr as usize + }, + 1256usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseArenaCfg) + ) + ); + } + test_field_ReleaseArenaCfg(); + fn test_field_ModelMetadataGetGraphDescription() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataGetGraphDescription) as usize + - ptr as usize + }, + 1264usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataGetGraphDescription) + ) + ); + } + test_field_ModelMetadataGetGraphDescription(); + fn test_field_SessionOptionsAppendExecutionProvider_TensorRT() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsAppendExecutionProvider_TensorRT) as usize + - ptr as usize + }, + 1272usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsAppendExecutionProvider_TensorRT) + ) + ); + } + test_field_SessionOptionsAppendExecutionProvider_TensorRT(); + fn test_field_SetCurrentGpuDeviceId() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetCurrentGpuDeviceId) as usize - ptr as usize + }, + 1280usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetCurrentGpuDeviceId) + ) + ); + } + test_field_SetCurrentGpuDeviceId(); + fn test_field_GetCurrentGpuDeviceId() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetCurrentGpuDeviceId) as usize - ptr as usize + }, + 1288usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetCurrentGpuDeviceId) + ) + ); + } + test_field_GetCurrentGpuDeviceId(); + fn test_field_KernelInfoGetAttributeArray_float() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelInfoGetAttributeArray_float) as usize + - ptr as usize + }, + 1296usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelInfoGetAttributeArray_float) + ) + ); + } + test_field_KernelInfoGetAttributeArray_float(); + fn test_field_KernelInfoGetAttributeArray_int64() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelInfoGetAttributeArray_int64) as usize + - ptr as usize + }, + 1304usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelInfoGetAttributeArray_int64) + ) + ); + } + test_field_KernelInfoGetAttributeArray_int64(); + fn test_field_CreateArenaCfgV2() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateArenaCfgV2) as usize - ptr as usize + }, + 1312usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateArenaCfgV2) + ) + ); + } + test_field_CreateArenaCfgV2(); + fn test_field_AddRunConfigEntry() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AddRunConfigEntry) as usize - ptr as usize + }, + 1320usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AddRunConfigEntry) + ) + ); + } + test_field_AddRunConfigEntry(); + fn test_field_CreatePrepackedWeightsContainer() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreatePrepackedWeightsContainer) as usize - ptr as usize + }, + 1328usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreatePrepackedWeightsContainer) + ) + ); + } + test_field_CreatePrepackedWeightsContainer(); + fn test_field_ReleasePrepackedWeightsContainer() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleasePrepackedWeightsContainer) as usize + - ptr as usize + }, + 1336usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleasePrepackedWeightsContainer) + ) + ); + } + test_field_ReleasePrepackedWeightsContainer(); + fn test_field_CreateSessionWithPrepackedWeightsContainer() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateSessionWithPrepackedWeightsContainer) as usize + - ptr as usize + }, + 1344usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateSessionWithPrepackedWeightsContainer) + ) + ); + } + test_field_CreateSessionWithPrepackedWeightsContainer(); + fn test_field_CreateSessionFromArrayWithPrepackedWeightsContainer() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateSessionFromArrayWithPrepackedWeightsContainer) + as usize + - ptr as usize + }, + 1352usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateSessionFromArrayWithPrepackedWeightsContainer) + ) + ); + } + test_field_CreateSessionFromArrayWithPrepackedWeightsContainer(); + fn test_field_SessionOptionsAppendExecutionProvider_TensorRT_V2() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsAppendExecutionProvider_TensorRT_V2) + as usize + - ptr as usize + }, + 1360usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsAppendExecutionProvider_TensorRT_V2) + ) + ); + } + test_field_SessionOptionsAppendExecutionProvider_TensorRT_V2(); + fn test_field_CreateTensorRTProviderOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateTensorRTProviderOptions) as usize - ptr as usize + }, + 1368usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateTensorRTProviderOptions) + ) + ); + } + test_field_CreateTensorRTProviderOptions(); + fn test_field_UpdateTensorRTProviderOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).UpdateTensorRTProviderOptions) as usize - ptr as usize + }, + 1376usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(UpdateTensorRTProviderOptions) + ) + ); + } + test_field_UpdateTensorRTProviderOptions(); + fn test_field_GetTensorRTProviderOptionsAsString() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetTensorRTProviderOptionsAsString) as usize + - ptr as usize + }, + 1384usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetTensorRTProviderOptionsAsString) + ) + ); + } + test_field_GetTensorRTProviderOptionsAsString(); + fn test_field_ReleaseTensorRTProviderOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseTensorRTProviderOptions) as usize - ptr as usize + }, + 1392usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseTensorRTProviderOptions) + ) + ); + } + test_field_ReleaseTensorRTProviderOptions(); + fn test_field_EnableOrtCustomOps() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).EnableOrtCustomOps) as usize - ptr as usize + }, + 1400usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(EnableOrtCustomOps) + ) + ); + } + test_field_EnableOrtCustomOps(); + fn test_field_RegisterAllocator() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RegisterAllocator) as usize - ptr as usize + }, + 1408usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RegisterAllocator) + ) + ); + } + test_field_RegisterAllocator(); + fn test_field_UnregisterAllocator() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).UnregisterAllocator) as usize - ptr as usize + }, + 1416usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(UnregisterAllocator) + ) + ); + } + test_field_UnregisterAllocator(); + fn test_field_IsSparseTensor() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).IsSparseTensor) as usize - ptr as usize + }, + 1424usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(IsSparseTensor) + ) + ); + } + test_field_IsSparseTensor(); + fn test_field_CreateSparseTensorAsOrtValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateSparseTensorAsOrtValue) as usize - ptr as usize + }, + 1432usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateSparseTensorAsOrtValue) + ) + ); + } + test_field_CreateSparseTensorAsOrtValue(); + fn test_field_FillSparseTensorCoo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).FillSparseTensorCoo) as usize - ptr as usize + }, + 1440usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(FillSparseTensorCoo) + ) + ); + } + test_field_FillSparseTensorCoo(); + fn test_field_FillSparseTensorCsr() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).FillSparseTensorCsr) as usize - ptr as usize + }, + 1448usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(FillSparseTensorCsr) + ) + ); + } + test_field_FillSparseTensorCsr(); + fn test_field_FillSparseTensorBlockSparse() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).FillSparseTensorBlockSparse) as usize - ptr as usize + }, + 1456usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(FillSparseTensorBlockSparse) + ) + ); + } + test_field_FillSparseTensorBlockSparse(); + fn test_field_CreateSparseTensorWithValuesAsOrtValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateSparseTensorWithValuesAsOrtValue) as usize + - ptr as usize + }, + 1464usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateSparseTensorWithValuesAsOrtValue) + ) + ); + } + test_field_CreateSparseTensorWithValuesAsOrtValue(); + fn test_field_UseCooIndices() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).UseCooIndices) as usize - ptr as usize + }, + 1472usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(UseCooIndices) + ) + ); + } + test_field_UseCooIndices(); + fn test_field_UseCsrIndices() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).UseCsrIndices) as usize - ptr as usize + }, + 1480usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(UseCsrIndices) + ) + ); + } + test_field_UseCsrIndices(); + fn test_field_UseBlockSparseIndices() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).UseBlockSparseIndices) as usize - ptr as usize + }, + 1488usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(UseBlockSparseIndices) + ) + ); + } + test_field_UseBlockSparseIndices(); + fn test_field_GetSparseTensorFormat() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetSparseTensorFormat) as usize - ptr as usize + }, + 1496usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetSparseTensorFormat) + ) + ); + } + test_field_GetSparseTensorFormat(); + fn test_field_GetSparseTensorValuesTypeAndShape() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetSparseTensorValuesTypeAndShape) as usize + - ptr as usize + }, + 1504usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetSparseTensorValuesTypeAndShape) + ) + ); + } + test_field_GetSparseTensorValuesTypeAndShape(); + fn test_field_GetSparseTensorValues() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetSparseTensorValues) as usize - ptr as usize + }, + 1512usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetSparseTensorValues) + ) + ); + } + test_field_GetSparseTensorValues(); + fn test_field_GetSparseTensorIndicesTypeShape() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetSparseTensorIndicesTypeShape) as usize - ptr as usize + }, + 1520usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetSparseTensorIndicesTypeShape) + ) + ); + } + test_field_GetSparseTensorIndicesTypeShape(); + fn test_field_GetSparseTensorIndices() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetSparseTensorIndices) as usize - ptr as usize + }, + 1528usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetSparseTensorIndices) + ) + ); + } + test_field_GetSparseTensorIndices(); + fn test_field_HasValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).HasValue) as usize - ptr as usize + }, + 1536usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(HasValue) + ) + ); + } + test_field_HasValue(); + fn test_field_KernelContext_GetGPUComputeStream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelContext_GetGPUComputeStream) as usize + - ptr as usize + }, + 1544usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelContext_GetGPUComputeStream) + ) + ); + } + test_field_KernelContext_GetGPUComputeStream(); + fn test_field_GetTensorMemoryInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetTensorMemoryInfo) as usize - ptr as usize + }, + 1552usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetTensorMemoryInfo) + ) + ); + } + test_field_GetTensorMemoryInfo(); + fn test_field_GetExecutionProviderApi() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetExecutionProviderApi) as usize - ptr as usize + }, + 1560usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetExecutionProviderApi) + ) + ); + } + test_field_GetExecutionProviderApi(); + fn test_field_SessionOptionsSetCustomCreateThreadFn() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsSetCustomCreateThreadFn) as usize + - ptr as usize + }, + 1568usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsSetCustomCreateThreadFn) + ) + ); + } + test_field_SessionOptionsSetCustomCreateThreadFn(); + fn test_field_SessionOptionsSetCustomThreadCreationOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsSetCustomThreadCreationOptions) as usize + - ptr as usize + }, + 1576usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsSetCustomThreadCreationOptions) + ) + ); + } + test_field_SessionOptionsSetCustomThreadCreationOptions(); + fn test_field_SessionOptionsSetCustomJoinThreadFn() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsSetCustomJoinThreadFn) as usize + - ptr as usize + }, + 1584usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsSetCustomJoinThreadFn) + ) + ); + } + test_field_SessionOptionsSetCustomJoinThreadFn(); + fn test_field_SetGlobalCustomCreateThreadFn() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetGlobalCustomCreateThreadFn) as usize - ptr as usize + }, + 1592usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetGlobalCustomCreateThreadFn) + ) + ); + } + test_field_SetGlobalCustomCreateThreadFn(); + fn test_field_SetGlobalCustomThreadCreationOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetGlobalCustomThreadCreationOptions) as usize + - ptr as usize + }, + 1600usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetGlobalCustomThreadCreationOptions) + ) + ); + } + test_field_SetGlobalCustomThreadCreationOptions(); + fn test_field_SetGlobalCustomJoinThreadFn() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetGlobalCustomJoinThreadFn) as usize - ptr as usize + }, + 1608usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetGlobalCustomJoinThreadFn) + ) + ); + } + test_field_SetGlobalCustomJoinThreadFn(); + fn test_field_SynchronizeBoundInputs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SynchronizeBoundInputs) as usize - ptr as usize + }, + 1616usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SynchronizeBoundInputs) + ) + ); + } + test_field_SynchronizeBoundInputs(); + fn test_field_SynchronizeBoundOutputs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SynchronizeBoundOutputs) as usize - ptr as usize + }, + 1624usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SynchronizeBoundOutputs) + ) + ); + } + test_field_SynchronizeBoundOutputs(); + fn test_field_SessionOptionsAppendExecutionProvider_CUDA_V2() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsAppendExecutionProvider_CUDA_V2) as usize + - ptr as usize + }, + 1632usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsAppendExecutionProvider_CUDA_V2) + ) + ); + } + test_field_SessionOptionsAppendExecutionProvider_CUDA_V2(); + fn test_field_CreateCUDAProviderOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateCUDAProviderOptions) as usize - ptr as usize + }, + 1640usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateCUDAProviderOptions) + ) + ); + } + test_field_CreateCUDAProviderOptions(); + fn test_field_UpdateCUDAProviderOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).UpdateCUDAProviderOptions) as usize - ptr as usize + }, + 1648usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(UpdateCUDAProviderOptions) + ) + ); + } + test_field_UpdateCUDAProviderOptions(); + fn test_field_GetCUDAProviderOptionsAsString() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetCUDAProviderOptionsAsString) as usize - ptr as usize + }, + 1656usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetCUDAProviderOptionsAsString) + ) + ); + } + test_field_GetCUDAProviderOptionsAsString(); + fn test_field_ReleaseCUDAProviderOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseCUDAProviderOptions) as usize - ptr as usize + }, + 1664usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseCUDAProviderOptions) + ) + ); + } + test_field_ReleaseCUDAProviderOptions(); + fn test_field_SessionOptionsAppendExecutionProvider_MIGraphX() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsAppendExecutionProvider_MIGraphX) as usize + - ptr as usize + }, + 1672usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsAppendExecutionProvider_MIGraphX) + ) + ); + } + test_field_SessionOptionsAppendExecutionProvider_MIGraphX(); } #[repr(u32)] #[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] @@ -15771,192 +9542,225 @@ fn bindgen_test_layout_OrtCustomOp() { 8usize, concat!("Alignment of ", stringify!(OrtCustomOp)) ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).version as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(version) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateKernel as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(CreateKernel) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetName as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetName) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetExecutionProviderType as *const _ as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetExecutionProviderType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetInputType as *const _ as usize }, - 32usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetInputType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetInputTypeCount as *const _ as usize }, - 40usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetInputTypeCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetOutputType as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetOutputType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetOutputTypeCount as *const _ as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetOutputTypeCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).KernelCompute as *const _ as usize }, - 64usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(KernelCompute) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).KernelDestroy as *const _ as usize }, - 72usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(KernelDestroy) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetInputCharacteristic as *const _ as usize - }, - 80usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetInputCharacteristic) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetOutputCharacteristic as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetOutputCharacteristic) - ) - ); + fn test_field_version() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).version) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(version) + ) + ); + } + test_field_version(); + fn test_field_CreateKernel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateKernel) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(CreateKernel) + ) + ); + } + test_field_CreateKernel(); + fn test_field_GetName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetName) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetName) + ) + ); + } + test_field_GetName(); + fn test_field_GetExecutionProviderType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetExecutionProviderType) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetExecutionProviderType) + ) + ); + } + test_field_GetExecutionProviderType(); + fn test_field_GetInputType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetInputType) as usize - ptr as usize + }, + 32usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetInputType) + ) + ); + } + test_field_GetInputType(); + fn test_field_GetInputTypeCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetInputTypeCount) as usize - ptr as usize + }, + 40usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetInputTypeCount) + ) + ); + } + test_field_GetInputTypeCount(); + fn test_field_GetOutputType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetOutputType) as usize - ptr as usize + }, + 48usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetOutputType) + ) + ); + } + test_field_GetOutputType(); + fn test_field_GetOutputTypeCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetOutputTypeCount) as usize - ptr as usize + }, + 56usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetOutputTypeCount) + ) + ); + } + test_field_GetOutputTypeCount(); + fn test_field_KernelCompute() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelCompute) as usize - ptr as usize + }, + 64usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(KernelCompute) + ) + ); + } + test_field_KernelCompute(); + fn test_field_KernelDestroy() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelDestroy) as usize - ptr as usize + }, + 72usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(KernelDestroy) + ) + ); + } + test_field_KernelDestroy(); + fn test_field_GetInputCharacteristic() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetInputCharacteristic) as usize - ptr as usize + }, + 80usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetInputCharacteristic) + ) + ); + } + test_field_GetInputCharacteristic(); + fn test_field_GetOutputCharacteristic() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetOutputCharacteristic) as usize - ptr as usize + }, + 88usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetOutputCharacteristic) + ) + ); + } + test_field_GetOutputCharacteristic(); +} +extern "C" { + pub fn OrtSessionOptionsAppendExecutionProvider_CUDA( + options: *mut OrtSessionOptions, + device_id: ::std::os::raw::c_int, + ) -> OrtStatusPtr; +} +extern "C" { + pub fn OrtSessionOptionsAppendExecutionProvider_MIGraphX( + options: *mut OrtSessionOptions, + device_id: ::std::os::raw::c_int, + ) -> OrtStatusPtr; } -pub type __builtin_va_list = [__va_list_tag; 1usize]; #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct __va_list_tag { - pub gp_offset: ::std::os::raw::c_uint, - pub fp_offset: ::std::os::raw::c_uint, - pub overflow_arg_area: *mut ::std::os::raw::c_void, - pub reg_save_area: *mut ::std::os::raw::c_void, -} -#[test] -fn bindgen_test_layout___va_list_tag() { - assert_eq!( - ::std::mem::size_of::<__va_list_tag>(), - 24usize, - concat!("Size of: ", stringify!(__va_list_tag)) - ); - assert_eq!( - ::std::mem::align_of::<__va_list_tag>(), - 8usize, - concat!("Alignment of ", stringify!(__va_list_tag)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__va_list_tag>())).gp_offset as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__va_list_tag), - "::", - stringify!(gp_offset) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__va_list_tag>())).fp_offset as *const _ as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(__va_list_tag), - "::", - stringify!(fp_offset) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__va_list_tag>())).overflow_arg_area as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__va_list_tag), - "::", - stringify!(overflow_arg_area) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__va_list_tag>())).reg_save_area as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__va_list_tag), - "::", - stringify!(reg_save_area) - ) - ); +pub struct __locale_data { + pub _address: u8, } diff --git a/onnxruntime-sys/src/generated/macos/aarch64/bindings.rs b/onnxruntime-sys/src/generated/macos/aarch64/bindings.rs index c857da52..d3fbc82e 100644 --- a/onnxruntime-sys/src/generated/macos/aarch64/bindings.rs +++ b/onnxruntime-sys/src/generated/macos/aarch64/bindings.rs @@ -1,9992 +1,9521 @@ -/* automatically generated by rust-bindgen 0.59.1 */ +/* automatically generated by rust-bindgen 0.60.1 */ -#[repr(C)] -#[derive(Copy, Clone, Debug, Default, Eq, Hash, Ord, PartialEq, PartialOrd)] -pub struct __BindgenBitfieldUnit { - storage: Storage, -} -impl __BindgenBitfieldUnit { - #[inline] - pub const fn new(storage: Storage) -> Self { - Self { storage } - } -} -impl __BindgenBitfieldUnit -where - Storage: AsRef<[u8]> + AsMut<[u8]>, -{ - #[inline] - pub fn get_bit(&self, index: usize) -> bool { - debug_assert!(index / 8 < self.storage.as_ref().len()); - let byte_index = index / 8; - let byte = self.storage.as_ref()[byte_index]; - let bit_index = if cfg!(target_endian = "big") { - 7 - (index % 8) - } else { - index % 8 - }; - let mask = 1 << bit_index; - byte & mask == mask - } - #[inline] - pub fn set_bit(&mut self, index: usize, val: bool) { - debug_assert!(index / 8 < self.storage.as_ref().len()); - let byte_index = index / 8; - let byte = &mut self.storage.as_mut()[byte_index]; - let bit_index = if cfg!(target_endian = "big") { - 7 - (index % 8) - } else { - index % 8 - }; - let mask = 1 << bit_index; - if val { - *byte |= mask; - } else { - *byte &= !mask; - } - } - #[inline] - pub fn get(&self, bit_offset: usize, bit_width: u8) -> u64 { - debug_assert!(bit_width <= 64); - debug_assert!(bit_offset / 8 < self.storage.as_ref().len()); - debug_assert!((bit_offset + (bit_width as usize)) / 8 <= self.storage.as_ref().len()); - let mut val = 0; - for i in 0..(bit_width as usize) { - if self.get_bit(i + bit_offset) { - let index = if cfg!(target_endian = "big") { - bit_width as usize - 1 - i - } else { - i - }; - val |= 1 << index; - } - } - val - } - #[inline] - pub fn set(&mut self, bit_offset: usize, bit_width: u8, val: u64) { - debug_assert!(bit_width <= 64); - debug_assert!(bit_offset / 8 < self.storage.as_ref().len()); - debug_assert!((bit_offset + (bit_width as usize)) / 8 <= self.storage.as_ref().len()); - for i in 0..(bit_width as usize) { - let mask = 1 << i; - let val_bit_is_set = val & mask == mask; - let index = if cfg!(target_endian = "big") { - bit_width as usize - 1 - i - } else { - i - }; - self.set_bit(index + bit_offset, val_bit_is_set); - } - } -} -pub const __API_TO_BE_DEPRECATED: u32 = 100000; -pub const __MAC_10_0: u32 = 1000; -pub const __MAC_10_1: u32 = 1010; -pub const __MAC_10_2: u32 = 1020; -pub const __MAC_10_3: u32 = 1030; -pub const __MAC_10_4: u32 = 1040; -pub const __MAC_10_5: u32 = 1050; -pub const __MAC_10_6: u32 = 1060; -pub const __MAC_10_7: u32 = 1070; -pub const __MAC_10_8: u32 = 1080; -pub const __MAC_10_9: u32 = 1090; -pub const __MAC_10_10: u32 = 101000; -pub const __MAC_10_10_2: u32 = 101002; -pub const __MAC_10_10_3: u32 = 101003; -pub const __MAC_10_11: u32 = 101100; -pub const __MAC_10_11_2: u32 = 101102; -pub const __MAC_10_11_3: u32 = 101103; -pub const __MAC_10_11_4: u32 = 101104; -pub const __MAC_10_12: u32 = 101200; -pub const __MAC_10_12_1: u32 = 101201; -pub const __MAC_10_12_2: u32 = 101202; -pub const __MAC_10_12_4: u32 = 101204; -pub const __MAC_10_13: u32 = 101300; -pub const __MAC_10_13_1: u32 = 101301; -pub const __MAC_10_13_2: u32 = 101302; -pub const __MAC_10_13_4: u32 = 101304; -pub const __MAC_10_14: u32 = 101400; -pub const __MAC_10_14_1: u32 = 101401; -pub const __MAC_10_14_4: u32 = 101404; -pub const __MAC_10_14_6: u32 = 101406; -pub const __MAC_10_15: u32 = 101500; -pub const __MAC_10_15_1: u32 = 101501; -pub const __MAC_10_15_4: u32 = 101504; -pub const __MAC_10_16: u32 = 101600; -pub const __MAC_11_0: u32 = 110000; -pub const __MAC_11_1: u32 = 110100; -pub const __MAC_11_3: u32 = 110300; -pub const __IPHONE_2_0: u32 = 20000; -pub const __IPHONE_2_1: u32 = 20100; -pub const __IPHONE_2_2: u32 = 20200; -pub const __IPHONE_3_0: u32 = 30000; -pub const __IPHONE_3_1: u32 = 30100; -pub const __IPHONE_3_2: u32 = 30200; -pub const __IPHONE_4_0: u32 = 40000; -pub const __IPHONE_4_1: u32 = 40100; -pub const __IPHONE_4_2: u32 = 40200; -pub const __IPHONE_4_3: u32 = 40300; -pub const __IPHONE_5_0: u32 = 50000; -pub const __IPHONE_5_1: u32 = 50100; -pub const __IPHONE_6_0: u32 = 60000; -pub const __IPHONE_6_1: u32 = 60100; -pub const __IPHONE_7_0: u32 = 70000; -pub const __IPHONE_7_1: u32 = 70100; -pub const __IPHONE_8_0: u32 = 80000; -pub const __IPHONE_8_1: u32 = 80100; -pub const __IPHONE_8_2: u32 = 80200; -pub const __IPHONE_8_3: u32 = 80300; -pub const __IPHONE_8_4: u32 = 80400; -pub const __IPHONE_9_0: u32 = 90000; -pub const __IPHONE_9_1: u32 = 90100; -pub const __IPHONE_9_2: u32 = 90200; -pub const __IPHONE_9_3: u32 = 90300; -pub const __IPHONE_10_0: u32 = 100000; -pub const __IPHONE_10_1: u32 = 100100; -pub const __IPHONE_10_2: u32 = 100200; -pub const __IPHONE_10_3: u32 = 100300; -pub const __IPHONE_11_0: u32 = 110000; -pub const __IPHONE_11_1: u32 = 110100; -pub const __IPHONE_11_2: u32 = 110200; -pub const __IPHONE_11_3: u32 = 110300; -pub const __IPHONE_11_4: u32 = 110400; -pub const __IPHONE_12_0: u32 = 120000; -pub const __IPHONE_12_1: u32 = 120100; -pub const __IPHONE_12_2: u32 = 120200; -pub const __IPHONE_12_3: u32 = 120300; -pub const __IPHONE_12_4: u32 = 120400; -pub const __IPHONE_13_0: u32 = 130000; -pub const __IPHONE_13_1: u32 = 130100; -pub const __IPHONE_13_2: u32 = 130200; -pub const __IPHONE_13_3: u32 = 130300; -pub const __IPHONE_13_4: u32 = 130400; -pub const __IPHONE_13_5: u32 = 130500; -pub const __IPHONE_13_6: u32 = 130600; -pub const __IPHONE_13_7: u32 = 130700; -pub const __IPHONE_14_0: u32 = 140000; -pub const __IPHONE_14_1: u32 = 140100; -pub const __IPHONE_14_2: u32 = 140200; -pub const __IPHONE_14_3: u32 = 140300; -pub const __IPHONE_14_5: u32 = 140500; -pub const __TVOS_9_0: u32 = 90000; -pub const __TVOS_9_1: u32 = 90100; -pub const __TVOS_9_2: u32 = 90200; -pub const __TVOS_10_0: u32 = 100000; -pub const __TVOS_10_0_1: u32 = 100001; -pub const __TVOS_10_1: u32 = 100100; -pub const __TVOS_10_2: u32 = 100200; -pub const __TVOS_11_0: u32 = 110000; -pub const __TVOS_11_1: u32 = 110100; -pub const __TVOS_11_2: u32 = 110200; -pub const __TVOS_11_3: u32 = 110300; -pub const __TVOS_11_4: u32 = 110400; -pub const __TVOS_12_0: u32 = 120000; -pub const __TVOS_12_1: u32 = 120100; -pub const __TVOS_12_2: u32 = 120200; -pub const __TVOS_12_3: u32 = 120300; -pub const __TVOS_12_4: u32 = 120400; -pub const __TVOS_13_0: u32 = 130000; -pub const __TVOS_13_2: u32 = 130200; -pub const __TVOS_13_3: u32 = 130300; -pub const __TVOS_13_4: u32 = 130400; -pub const __TVOS_14_0: u32 = 140000; -pub const __TVOS_14_1: u32 = 140100; -pub const __TVOS_14_2: u32 = 140200; -pub const __TVOS_14_3: u32 = 140300; -pub const __TVOS_14_5: u32 = 140500; -pub const __WATCHOS_1_0: u32 = 10000; -pub const __WATCHOS_2_0: u32 = 20000; -pub const __WATCHOS_2_1: u32 = 20100; -pub const __WATCHOS_2_2: u32 = 20200; -pub const __WATCHOS_3_0: u32 = 30000; -pub const __WATCHOS_3_1: u32 = 30100; -pub const __WATCHOS_3_1_1: u32 = 30101; -pub const __WATCHOS_3_2: u32 = 30200; -pub const __WATCHOS_4_0: u32 = 40000; -pub const __WATCHOS_4_1: u32 = 40100; -pub const __WATCHOS_4_2: u32 = 40200; -pub const __WATCHOS_4_3: u32 = 40300; -pub const __WATCHOS_5_0: u32 = 50000; -pub const __WATCHOS_5_1: u32 = 50100; -pub const __WATCHOS_5_2: u32 = 50200; -pub const __WATCHOS_5_3: u32 = 50300; -pub const __WATCHOS_6_0: u32 = 60000; -pub const __WATCHOS_6_1: u32 = 60100; -pub const __WATCHOS_6_2: u32 = 60200; -pub const __WATCHOS_7_0: u32 = 70000; -pub const __WATCHOS_7_1: u32 = 70100; -pub const __WATCHOS_7_2: u32 = 70200; -pub const __WATCHOS_7_3: u32 = 70300; -pub const __WATCHOS_7_4: u32 = 70400; -pub const MAC_OS_X_VERSION_10_0: u32 = 1000; -pub const MAC_OS_X_VERSION_10_1: u32 = 1010; -pub const MAC_OS_X_VERSION_10_2: u32 = 1020; -pub const MAC_OS_X_VERSION_10_3: u32 = 1030; -pub const MAC_OS_X_VERSION_10_4: u32 = 1040; -pub const MAC_OS_X_VERSION_10_5: u32 = 1050; -pub const MAC_OS_X_VERSION_10_6: u32 = 1060; -pub const MAC_OS_X_VERSION_10_7: u32 = 1070; -pub const MAC_OS_X_VERSION_10_8: u32 = 1080; -pub const MAC_OS_X_VERSION_10_9: u32 = 1090; -pub const MAC_OS_X_VERSION_10_10: u32 = 101000; -pub const MAC_OS_X_VERSION_10_10_2: u32 = 101002; -pub const MAC_OS_X_VERSION_10_10_3: u32 = 101003; -pub const MAC_OS_X_VERSION_10_11: u32 = 101100; -pub const MAC_OS_X_VERSION_10_11_2: u32 = 101102; -pub const MAC_OS_X_VERSION_10_11_3: u32 = 101103; -pub const MAC_OS_X_VERSION_10_11_4: u32 = 101104; -pub const MAC_OS_X_VERSION_10_12: u32 = 101200; -pub const MAC_OS_X_VERSION_10_12_1: u32 = 101201; -pub const MAC_OS_X_VERSION_10_12_2: u32 = 101202; -pub const MAC_OS_X_VERSION_10_12_4: u32 = 101204; -pub const MAC_OS_X_VERSION_10_13: u32 = 101300; -pub const MAC_OS_X_VERSION_10_13_1: u32 = 101301; -pub const MAC_OS_X_VERSION_10_13_2: u32 = 101302; -pub const MAC_OS_X_VERSION_10_13_4: u32 = 101304; -pub const MAC_OS_X_VERSION_10_14: u32 = 101400; -pub const MAC_OS_X_VERSION_10_14_1: u32 = 101401; -pub const MAC_OS_X_VERSION_10_14_4: u32 = 101404; -pub const MAC_OS_X_VERSION_10_14_6: u32 = 101406; -pub const MAC_OS_X_VERSION_10_15: u32 = 101500; -pub const MAC_OS_X_VERSION_10_15_1: u32 = 101501; -pub const MAC_OS_X_VERSION_10_16: u32 = 101600; -pub const MAC_OS_VERSION_11_0: u32 = 110000; -pub const __DRIVERKIT_19_0: u32 = 190000; -pub const __DRIVERKIT_20_0: u32 = 200000; -pub const __MAC_OS_X_VERSION_MAX_ALLOWED: u32 = 110300; -pub const __ENABLE_LEGACY_MAC_AVAILABILITY: u32 = 1; -pub const __DARWIN_ONLY_64_BIT_INO_T: u32 = 1; -pub const __DARWIN_ONLY_UNIX_CONFORMANCE: u32 = 1; -pub const __DARWIN_ONLY_VERS_1050: u32 = 1; -pub const __DARWIN_UNIX03: u32 = 1; -pub const __DARWIN_64_BIT_INO_T: u32 = 1; -pub const __DARWIN_VERS_1050: u32 = 1; -pub const __DARWIN_NON_CANCELABLE: u32 = 0; -pub const __DARWIN_SUF_EXTSN: &'static [u8; 14usize] = b"$DARWIN_EXTSN\0"; -pub const __DARWIN_C_ANSI: u32 = 4096; -pub const __DARWIN_C_FULL: u32 = 900000; -pub const __DARWIN_C_LEVEL: u32 = 900000; -pub const __STDC_WANT_LIB_EXT1__: u32 = 1; -pub const __DARWIN_NO_LONG_LONG: u32 = 0; -pub const _DARWIN_FEATURE_64_BIT_INODE: u32 = 1; -pub const _DARWIN_FEATURE_ONLY_64_BIT_INODE: u32 = 1; -pub const _DARWIN_FEATURE_ONLY_VERS_1050: u32 = 1; -pub const _DARWIN_FEATURE_ONLY_UNIX_CONFORMANCE: u32 = 1; -pub const _DARWIN_FEATURE_UNIX_CONFORMANCE: u32 = 3; -pub const __PTHREAD_SIZE__: u32 = 8176; -pub const __PTHREAD_ATTR_SIZE__: u32 = 56; -pub const __PTHREAD_MUTEXATTR_SIZE__: u32 = 8; -pub const __PTHREAD_MUTEX_SIZE__: u32 = 56; -pub const __PTHREAD_CONDATTR_SIZE__: u32 = 8; -pub const __PTHREAD_COND_SIZE__: u32 = 40; -pub const __PTHREAD_ONCE_SIZE__: u32 = 8; -pub const __PTHREAD_RWLOCK_SIZE__: u32 = 192; -pub const __PTHREAD_RWLOCKATTR_SIZE__: u32 = 16; -pub const __DARWIN_WCHAR_MIN: i32 = -2147483648; -pub const _FORTIFY_SOURCE: u32 = 2; -pub const __DARWIN_NSIG: u32 = 32; -pub const NSIG: u32 = 32; -pub const _ARM_SIGNAL_: u32 = 1; -pub const SIGHUP: u32 = 1; -pub const SIGINT: u32 = 2; -pub const SIGQUIT: u32 = 3; -pub const SIGILL: u32 = 4; -pub const SIGTRAP: u32 = 5; -pub const SIGABRT: u32 = 6; -pub const SIGIOT: u32 = 6; -pub const SIGEMT: u32 = 7; -pub const SIGFPE: u32 = 8; -pub const SIGKILL: u32 = 9; -pub const SIGBUS: u32 = 10; -pub const SIGSEGV: u32 = 11; -pub const SIGSYS: u32 = 12; -pub const SIGPIPE: u32 = 13; -pub const SIGALRM: u32 = 14; -pub const SIGTERM: u32 = 15; -pub const SIGURG: u32 = 16; -pub const SIGSTOP: u32 = 17; -pub const SIGTSTP: u32 = 18; -pub const SIGCONT: u32 = 19; -pub const SIGCHLD: u32 = 20; -pub const SIGTTIN: u32 = 21; -pub const SIGTTOU: u32 = 22; -pub const SIGIO: u32 = 23; -pub const SIGXCPU: u32 = 24; -pub const SIGXFSZ: u32 = 25; -pub const SIGVTALRM: u32 = 26; -pub const SIGPROF: u32 = 27; -pub const SIGWINCH: u32 = 28; -pub const SIGINFO: u32 = 29; -pub const SIGUSR1: u32 = 30; -pub const SIGUSR2: u32 = 31; -pub const __DARWIN_OPAQUE_ARM_THREAD_STATE64: u32 = 0; -pub const SIGEV_NONE: u32 = 0; -pub const SIGEV_SIGNAL: u32 = 1; -pub const SIGEV_THREAD: u32 = 3; -pub const ILL_NOOP: u32 = 0; -pub const ILL_ILLOPC: u32 = 1; -pub const ILL_ILLTRP: u32 = 2; -pub const ILL_PRVOPC: u32 = 3; -pub const ILL_ILLOPN: u32 = 4; -pub const ILL_ILLADR: u32 = 5; -pub const ILL_PRVREG: u32 = 6; -pub const ILL_COPROC: u32 = 7; -pub const ILL_BADSTK: u32 = 8; -pub const FPE_NOOP: u32 = 0; -pub const FPE_FLTDIV: u32 = 1; -pub const FPE_FLTOVF: u32 = 2; -pub const FPE_FLTUND: u32 = 3; -pub const FPE_FLTRES: u32 = 4; -pub const FPE_FLTINV: u32 = 5; -pub const FPE_FLTSUB: u32 = 6; -pub const FPE_INTDIV: u32 = 7; -pub const FPE_INTOVF: u32 = 8; -pub const SEGV_NOOP: u32 = 0; -pub const SEGV_MAPERR: u32 = 1; -pub const SEGV_ACCERR: u32 = 2; -pub const BUS_NOOP: u32 = 0; -pub const BUS_ADRALN: u32 = 1; -pub const BUS_ADRERR: u32 = 2; -pub const BUS_OBJERR: u32 = 3; -pub const TRAP_BRKPT: u32 = 1; -pub const TRAP_TRACE: u32 = 2; -pub const CLD_NOOP: u32 = 0; -pub const CLD_EXITED: u32 = 1; -pub const CLD_KILLED: u32 = 2; -pub const CLD_DUMPED: u32 = 3; -pub const CLD_TRAPPED: u32 = 4; -pub const CLD_STOPPED: u32 = 5; -pub const CLD_CONTINUED: u32 = 6; -pub const POLL_IN: u32 = 1; -pub const POLL_OUT: u32 = 2; -pub const POLL_MSG: u32 = 3; -pub const POLL_ERR: u32 = 4; -pub const POLL_PRI: u32 = 5; -pub const POLL_HUP: u32 = 6; -pub const SA_ONSTACK: u32 = 1; -pub const SA_RESTART: u32 = 2; -pub const SA_RESETHAND: u32 = 4; -pub const SA_NOCLDSTOP: u32 = 8; -pub const SA_NODEFER: u32 = 16; -pub const SA_NOCLDWAIT: u32 = 32; -pub const SA_SIGINFO: u32 = 64; -pub const SA_USERTRAMP: u32 = 256; -pub const SA_64REGSET: u32 = 512; -pub const SA_USERSPACE_MASK: u32 = 127; -pub const SIG_BLOCK: u32 = 1; -pub const SIG_UNBLOCK: u32 = 2; -pub const SIG_SETMASK: u32 = 3; -pub const SI_USER: u32 = 65537; -pub const SI_QUEUE: u32 = 65538; -pub const SI_TIMER: u32 = 65539; -pub const SI_ASYNCIO: u32 = 65540; -pub const SI_MESGQ: u32 = 65541; -pub const SS_ONSTACK: u32 = 1; -pub const SS_DISABLE: u32 = 4; -pub const MINSIGSTKSZ: u32 = 32768; -pub const SIGSTKSZ: u32 = 131072; -pub const SV_ONSTACK: u32 = 1; -pub const SV_INTERRUPT: u32 = 2; -pub const SV_RESETHAND: u32 = 4; -pub const SV_NODEFER: u32 = 16; -pub const SV_NOCLDSTOP: u32 = 8; -pub const SV_SIGINFO: u32 = 64; -pub const __WORDSIZE: u32 = 64; -pub const INT8_MAX: u32 = 127; -pub const INT16_MAX: u32 = 32767; -pub const INT32_MAX: u32 = 2147483647; -pub const INT64_MAX: u64 = 9223372036854775807; +pub const _FEATURES_H: u32 = 1; +pub const _DEFAULT_SOURCE: u32 = 1; +pub const __GLIBC_USE_ISOC2X: u32 = 0; +pub const __USE_ISOC11: u32 = 1; +pub const __USE_ISOC99: u32 = 1; +pub const __USE_ISOC95: u32 = 1; +pub const __USE_POSIX_IMPLICITLY: u32 = 1; +pub const _POSIX_SOURCE: u32 = 1; +pub const _POSIX_C_SOURCE: u32 = 200809; +pub const __USE_POSIX: u32 = 1; +pub const __USE_POSIX2: u32 = 1; +pub const __USE_POSIX199309: u32 = 1; +pub const __USE_POSIX199506: u32 = 1; +pub const __USE_XOPEN2K: u32 = 1; +pub const __USE_XOPEN2K8: u32 = 1; +pub const _ATFILE_SOURCE: u32 = 1; +pub const __USE_MISC: u32 = 1; +pub const __USE_ATFILE: u32 = 1; +pub const __USE_FORTIFY_LEVEL: u32 = 0; +pub const __GLIBC_USE_DEPRECATED_GETS: u32 = 0; +pub const __GLIBC_USE_DEPRECATED_SCANF: u32 = 0; +pub const _STDC_PREDEF_H: u32 = 1; +pub const __STDC_IEC_559__: u32 = 1; +pub const __STDC_IEC_559_COMPLEX__: u32 = 1; +pub const __STDC_ISO_10646__: u32 = 201706; +pub const __GNU_LIBRARY__: u32 = 6; +pub const __GLIBC__: u32 = 2; +pub const __GLIBC_MINOR__: u32 = 31; +pub const _SYS_CDEFS_H: u32 = 1; +pub const __glibc_c99_flexarr_available: u32 = 1; +pub const __WORDSIZE: u32 = 32; +pub const __WORDSIZE32_SIZE_ULONG: u32 = 0; +pub const __WORDSIZE32_PTRDIFF_LONG: u32 = 0; +pub const __WORDSIZE_TIME64_COMPAT32: u32 = 0; +pub const __LONG_DOUBLE_USES_FLOAT128: u32 = 0; +pub const __HAVE_GENERIC_SELECTION: u32 = 1; +pub const __GLIBC_USE_LIB_EXT2: u32 = 0; +pub const __GLIBC_USE_IEC_60559_BFP_EXT: u32 = 0; +pub const __GLIBC_USE_IEC_60559_BFP_EXT_C2X: u32 = 0; +pub const __GLIBC_USE_IEC_60559_FUNCS_EXT: u32 = 0; +pub const __GLIBC_USE_IEC_60559_FUNCS_EXT_C2X: u32 = 0; +pub const __GLIBC_USE_IEC_60559_TYPES_EXT: u32 = 0; +pub const _STDLIB_H: u32 = 1; +pub const WNOHANG: u32 = 1; +pub const WUNTRACED: u32 = 2; +pub const WSTOPPED: u32 = 2; +pub const WEXITED: u32 = 4; +pub const WCONTINUED: u32 = 8; +pub const WNOWAIT: u32 = 16777216; +pub const __WNOTHREAD: u32 = 536870912; +pub const __WALL: u32 = 1073741824; +pub const __WCLONE: u32 = 2147483648; +pub const __ENUM_IDTYPE_T: u32 = 1; +pub const __W_CONTINUED: u32 = 65535; +pub const __WCOREFLAG: u32 = 128; +pub const __HAVE_FLOAT128: u32 = 0; +pub const __HAVE_DISTINCT_FLOAT128: u32 = 0; +pub const __HAVE_FLOAT64X: u32 = 1; +pub const __HAVE_FLOAT64X_LONG_DOUBLE: u32 = 1; +pub const __HAVE_FLOAT16: u32 = 0; +pub const __HAVE_FLOAT32: u32 = 1; +pub const __HAVE_FLOAT64: u32 = 1; +pub const __HAVE_FLOAT32X: u32 = 1; +pub const __HAVE_FLOAT128X: u32 = 0; +pub const __HAVE_DISTINCT_FLOAT16: u32 = 0; +pub const __HAVE_DISTINCT_FLOAT32: u32 = 0; +pub const __HAVE_DISTINCT_FLOAT64: u32 = 0; +pub const __HAVE_DISTINCT_FLOAT32X: u32 = 0; +pub const __HAVE_DISTINCT_FLOAT64X: u32 = 0; +pub const __HAVE_DISTINCT_FLOAT128X: u32 = 0; +pub const __HAVE_FLOATN_NOT_TYPEDEF: u32 = 0; +pub const __ldiv_t_defined: u32 = 1; +pub const __lldiv_t_defined: u32 = 1; +pub const RAND_MAX: u32 = 2147483647; +pub const EXIT_FAILURE: u32 = 1; +pub const EXIT_SUCCESS: u32 = 0; +pub const _SYS_TYPES_H: u32 = 1; +pub const _BITS_TYPES_H: u32 = 1; +pub const __TIMESIZE: u32 = 32; +pub const _BITS_TYPESIZES_H: u32 = 1; +pub const __RLIM_T_MATCHES_RLIM64_T: u32 = 0; +pub const __STATFS_MATCHES_STATFS64: u32 = 0; +pub const __FD_SETSIZE: u32 = 1024; +pub const _BITS_TIME64_H: u32 = 1; +pub const __clock_t_defined: u32 = 1; +pub const __clockid_t_defined: u32 = 1; +pub const __time_t_defined: u32 = 1; +pub const __timer_t_defined: u32 = 1; +pub const _BITS_STDINT_INTN_H: u32 = 1; +pub const __BIT_TYPES_DEFINED__: u32 = 1; +pub const _ENDIAN_H: u32 = 1; +pub const _BITS_ENDIAN_H: u32 = 1; +pub const __LITTLE_ENDIAN: u32 = 1234; +pub const __BIG_ENDIAN: u32 = 4321; +pub const __PDP_ENDIAN: u32 = 3412; +pub const _BITS_ENDIANNESS_H: u32 = 1; +pub const __BYTE_ORDER: u32 = 1234; +pub const __FLOAT_WORD_ORDER: u32 = 1234; +pub const LITTLE_ENDIAN: u32 = 1234; +pub const BIG_ENDIAN: u32 = 4321; +pub const PDP_ENDIAN: u32 = 3412; +pub const BYTE_ORDER: u32 = 1234; +pub const _BITS_BYTESWAP_H: u32 = 1; +pub const _BITS_UINTN_IDENTITY_H: u32 = 1; +pub const _SYS_SELECT_H: u32 = 1; +pub const __FD_ZERO_STOS: &[u8; 6usize] = b"stosl\0"; +pub const __sigset_t_defined: u32 = 1; +pub const __timeval_defined: u32 = 1; +pub const _STRUCT_TIMESPEC: u32 = 1; +pub const FD_SETSIZE: u32 = 1024; +pub const _BITS_PTHREADTYPES_COMMON_H: u32 = 1; +pub const _THREAD_SHARED_TYPES_H: u32 = 1; +pub const _BITS_PTHREADTYPES_ARCH_H: u32 = 1; +pub const __SIZEOF_PTHREAD_MUTEX_T: u32 = 24; +pub const __SIZEOF_PTHREAD_ATTR_T: u32 = 36; +pub const __SIZEOF_PTHREAD_RWLOCK_T: u32 = 32; +pub const __SIZEOF_PTHREAD_BARRIER_T: u32 = 20; +pub const __SIZEOF_PTHREAD_MUTEXATTR_T: u32 = 4; +pub const __SIZEOF_PTHREAD_COND_T: u32 = 48; +pub const __SIZEOF_PTHREAD_CONDATTR_T: u32 = 4; +pub const __SIZEOF_PTHREAD_RWLOCKATTR_T: u32 = 8; +pub const __SIZEOF_PTHREAD_BARRIERATTR_T: u32 = 4; +pub const _THREAD_MUTEX_INTERNAL_H: u32 = 1; +pub const __PTHREAD_MUTEX_HAVE_PREV: u32 = 0; +pub const __have_pthread_attr_t: u32 = 1; +pub const _ALLOCA_H: u32 = 1; +pub const _STDINT_H: u32 = 1; +pub const _BITS_WCHAR_H: u32 = 1; +pub const _BITS_STDINT_UINTN_H: u32 = 1; pub const INT8_MIN: i32 = -128; pub const INT16_MIN: i32 = -32768; pub const INT32_MIN: i32 = -2147483648; -pub const INT64_MIN: i64 = -9223372036854775808; +pub const INT8_MAX: u32 = 127; +pub const INT16_MAX: u32 = 32767; +pub const INT32_MAX: u32 = 2147483647; pub const UINT8_MAX: u32 = 255; pub const UINT16_MAX: u32 = 65535; pub const UINT32_MAX: u32 = 4294967295; -pub const UINT64_MAX: i32 = -1; pub const INT_LEAST8_MIN: i32 = -128; pub const INT_LEAST16_MIN: i32 = -32768; pub const INT_LEAST32_MIN: i32 = -2147483648; -pub const INT_LEAST64_MIN: i64 = -9223372036854775808; pub const INT_LEAST8_MAX: u32 = 127; pub const INT_LEAST16_MAX: u32 = 32767; pub const INT_LEAST32_MAX: u32 = 2147483647; -pub const INT_LEAST64_MAX: u64 = 9223372036854775807; pub const UINT_LEAST8_MAX: u32 = 255; pub const UINT_LEAST16_MAX: u32 = 65535; pub const UINT_LEAST32_MAX: u32 = 4294967295; -pub const UINT_LEAST64_MAX: i32 = -1; pub const INT_FAST8_MIN: i32 = -128; -pub const INT_FAST16_MIN: i32 = -32768; +pub const INT_FAST16_MIN: i32 = -2147483648; pub const INT_FAST32_MIN: i32 = -2147483648; -pub const INT_FAST64_MIN: i64 = -9223372036854775808; pub const INT_FAST8_MAX: u32 = 127; -pub const INT_FAST16_MAX: u32 = 32767; +pub const INT_FAST16_MAX: u32 = 2147483647; pub const INT_FAST32_MAX: u32 = 2147483647; -pub const INT_FAST64_MAX: u64 = 9223372036854775807; pub const UINT_FAST8_MAX: u32 = 255; -pub const UINT_FAST16_MAX: u32 = 65535; +pub const UINT_FAST16_MAX: u32 = 4294967295; pub const UINT_FAST32_MAX: u32 = 4294967295; -pub const UINT_FAST64_MAX: i32 = -1; -pub const INTPTR_MAX: u64 = 9223372036854775807; -pub const INTPTR_MIN: i64 = -9223372036854775808; -pub const UINTPTR_MAX: i32 = -1; -pub const SIZE_MAX: i32 = -1; -pub const RSIZE_MAX: i32 = -1; -pub const WINT_MIN: i32 = -2147483648; -pub const WINT_MAX: u32 = 2147483647; +pub const INTPTR_MIN: i32 = -2147483648; +pub const INTPTR_MAX: u32 = 2147483647; +pub const UINTPTR_MAX: u32 = 4294967295; +pub const PTRDIFF_MIN: i32 = -2147483648; +pub const PTRDIFF_MAX: u32 = 2147483647; pub const SIG_ATOMIC_MIN: i32 = -2147483648; pub const SIG_ATOMIC_MAX: u32 = 2147483647; -pub const PRIO_PROCESS: u32 = 0; -pub const PRIO_PGRP: u32 = 1; -pub const PRIO_USER: u32 = 2; -pub const PRIO_DARWIN_THREAD: u32 = 3; -pub const PRIO_DARWIN_PROCESS: u32 = 4; -pub const PRIO_MIN: i32 = -20; -pub const PRIO_MAX: u32 = 20; -pub const PRIO_DARWIN_BG: u32 = 4096; -pub const PRIO_DARWIN_NONUI: u32 = 4097; -pub const RUSAGE_SELF: u32 = 0; -pub const RUSAGE_CHILDREN: i32 = -1; -pub const RUSAGE_INFO_V0: u32 = 0; -pub const RUSAGE_INFO_V1: u32 = 1; -pub const RUSAGE_INFO_V2: u32 = 2; -pub const RUSAGE_INFO_V3: u32 = 3; -pub const RUSAGE_INFO_V4: u32 = 4; -pub const RUSAGE_INFO_V5: u32 = 5; -pub const RUSAGE_INFO_CURRENT: u32 = 5; -pub const RU_PROC_RUNS_RESLIDE: u32 = 1; -pub const RLIMIT_CPU: u32 = 0; -pub const RLIMIT_FSIZE: u32 = 1; -pub const RLIMIT_DATA: u32 = 2; -pub const RLIMIT_STACK: u32 = 3; -pub const RLIMIT_CORE: u32 = 4; -pub const RLIMIT_AS: u32 = 5; -pub const RLIMIT_RSS: u32 = 5; -pub const RLIMIT_MEMLOCK: u32 = 6; -pub const RLIMIT_NPROC: u32 = 7; -pub const RLIMIT_NOFILE: u32 = 8; -pub const RLIM_NLIMITS: u32 = 9; -pub const _RLIMIT_POSIX_FLAG: u32 = 4096; -pub const RLIMIT_WAKEUPS_MONITOR: u32 = 1; -pub const RLIMIT_CPU_USAGE_MONITOR: u32 = 2; -pub const RLIMIT_THREAD_CPULIMITS: u32 = 3; -pub const RLIMIT_FOOTPRINT_INTERVAL: u32 = 4; -pub const WAKEMON_ENABLE: u32 = 1; -pub const WAKEMON_DISABLE: u32 = 2; -pub const WAKEMON_GET_PARAMS: u32 = 4; -pub const WAKEMON_SET_DEFAULTS: u32 = 8; -pub const WAKEMON_MAKE_FATAL: u32 = 16; -pub const CPUMON_MAKE_FATAL: u32 = 4096; -pub const FOOTPRINT_INTERVAL_RESET: u32 = 1; -pub const IOPOL_TYPE_DISK: u32 = 0; -pub const IOPOL_TYPE_VFS_ATIME_UPDATES: u32 = 2; -pub const IOPOL_TYPE_VFS_MATERIALIZE_DATALESS_FILES: u32 = 3; -pub const IOPOL_TYPE_VFS_STATFS_NO_DATA_VOLUME: u32 = 4; -pub const IOPOL_TYPE_VFS_TRIGGER_RESOLVE: u32 = 5; -pub const IOPOL_TYPE_VFS_IGNORE_CONTENT_PROTECTION: u32 = 6; -pub const IOPOL_TYPE_VFS_IGNORE_PERMISSIONS: u32 = 7; -pub const IOPOL_TYPE_VFS_SKIP_MTIME_UPDATE: u32 = 8; -pub const IOPOL_SCOPE_PROCESS: u32 = 0; -pub const IOPOL_SCOPE_THREAD: u32 = 1; -pub const IOPOL_SCOPE_DARWIN_BG: u32 = 2; -pub const IOPOL_DEFAULT: u32 = 0; -pub const IOPOL_IMPORTANT: u32 = 1; -pub const IOPOL_PASSIVE: u32 = 2; -pub const IOPOL_THROTTLE: u32 = 3; -pub const IOPOL_UTILITY: u32 = 4; -pub const IOPOL_STANDARD: u32 = 5; -pub const IOPOL_APPLICATION: u32 = 5; -pub const IOPOL_NORMAL: u32 = 1; -pub const IOPOL_ATIME_UPDATES_DEFAULT: u32 = 0; -pub const IOPOL_ATIME_UPDATES_OFF: u32 = 1; -pub const IOPOL_MATERIALIZE_DATALESS_FILES_DEFAULT: u32 = 0; -pub const IOPOL_MATERIALIZE_DATALESS_FILES_OFF: u32 = 1; -pub const IOPOL_MATERIALIZE_DATALESS_FILES_ON: u32 = 2; -pub const IOPOL_VFS_STATFS_NO_DATA_VOLUME_DEFAULT: u32 = 0; -pub const IOPOL_VFS_STATFS_FORCE_NO_DATA_VOLUME: u32 = 1; -pub const IOPOL_VFS_TRIGGER_RESOLVE_DEFAULT: u32 = 0; -pub const IOPOL_VFS_TRIGGER_RESOLVE_OFF: u32 = 1; -pub const IOPOL_VFS_CONTENT_PROTECTION_DEFAULT: u32 = 0; -pub const IOPOL_VFS_CONTENT_PROTECTION_IGNORE: u32 = 1; -pub const IOPOL_VFS_IGNORE_PERMISSIONS_OFF: u32 = 0; -pub const IOPOL_VFS_IGNORE_PERMISSIONS_ON: u32 = 1; -pub const IOPOL_VFS_SKIP_MTIME_UPDATE_OFF: u32 = 0; -pub const IOPOL_VFS_SKIP_MTIME_UPDATE_ON: u32 = 1; -pub const WNOHANG: u32 = 1; -pub const WUNTRACED: u32 = 2; -pub const WCOREFLAG: u32 = 128; -pub const _WSTOPPED: u32 = 127; -pub const WEXITED: u32 = 4; -pub const WSTOPPED: u32 = 8; -pub const WCONTINUED: u32 = 16; -pub const WNOWAIT: u32 = 32; -pub const WAIT_ANY: i32 = -1; -pub const WAIT_MYPGRP: u32 = 0; -pub const _QUAD_HIGHWORD: u32 = 1; -pub const _QUAD_LOWWORD: u32 = 0; -pub const __DARWIN_LITTLE_ENDIAN: u32 = 1234; -pub const __DARWIN_BIG_ENDIAN: u32 = 4321; -pub const __DARWIN_PDP_ENDIAN: u32 = 3412; -pub const __DARWIN_BYTE_ORDER: u32 = 1234; -pub const LITTLE_ENDIAN: u32 = 1234; -pub const BIG_ENDIAN: u32 = 4321; -pub const PDP_ENDIAN: u32 = 3412; -pub const BYTE_ORDER: u32 = 1234; -pub const EXIT_FAILURE: u32 = 1; -pub const EXIT_SUCCESS: u32 = 0; -pub const RAND_MAX: u32 = 2147483647; -pub const _USE_FORTIFY_LEVEL: u32 = 2; -pub const __HAS_FIXED_CHK_PROTOTYPES: u32 = 1; -pub const ORT_API_VERSION: u32 = 8; -pub type __int8_t = ::std::os::raw::c_schar; -pub type __uint8_t = ::std::os::raw::c_uchar; -pub type __int16_t = ::std::os::raw::c_short; -pub type __uint16_t = ::std::os::raw::c_ushort; -pub type __int32_t = ::std::os::raw::c_int; -pub type __uint32_t = ::std::os::raw::c_uint; -pub type __int64_t = ::std::os::raw::c_longlong; -pub type __uint64_t = ::std::os::raw::c_ulonglong; -pub type __darwin_intptr_t = ::std::os::raw::c_long; -pub type __darwin_natural_t = ::std::os::raw::c_uint; -pub type __darwin_ct_rune_t = ::std::os::raw::c_int; +pub const SIZE_MAX: u32 = 4294967295; +pub const WINT_MIN: u32 = 0; +pub const WINT_MAX: u32 = 4294967295; +pub const _STRING_H: u32 = 1; +pub const _BITS_TYPES_LOCALE_T_H: u32 = 1; +pub const _BITS_TYPES___LOCALE_T_H: u32 = 1; +pub const _STRINGS_H: u32 = 1; +pub const ORT_API_VERSION: u32 = 11; +pub type wchar_t = ::std::os::raw::c_int; +#[repr(u32)] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum idtype_t { + P_ALL = 0, + P_PID = 1, + P_PGID = 2, +} +pub type _Float32 = f32; +pub type _Float64 = f64; +pub type _Float32x = f64; +pub type _Float64x = f64; #[repr(C)] -#[derive(Copy, Clone)] -pub union __mbstate_t { - pub __mbstate8: [::std::os::raw::c_char; 128usize], - pub _mbstateL: ::std::os::raw::c_longlong, +#[derive(Debug, Copy, Clone)] +pub struct div_t { + pub quot: ::std::os::raw::c_int, + pub rem: ::std::os::raw::c_int, } #[test] -fn bindgen_test_layout___mbstate_t() { - assert_eq!( - ::std::mem::size_of::<__mbstate_t>(), - 128usize, - concat!("Size of: ", stringify!(__mbstate_t)) - ); +fn bindgen_test_layout_div_t() { assert_eq!( - ::std::mem::align_of::<__mbstate_t>(), + ::std::mem::size_of::(), 8usize, - concat!("Alignment of ", stringify!(__mbstate_t)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__mbstate_t>())).__mbstate8 as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__mbstate_t), - "::", - stringify!(__mbstate8) - ) + concat!("Size of: ", stringify!(div_t)) ); assert_eq!( - unsafe { &(*(::std::ptr::null::<__mbstate_t>()))._mbstateL as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__mbstate_t), - "::", - stringify!(_mbstateL) - ) + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(div_t)) ); + fn test_field_quot() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).quot) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(div_t), + "::", + stringify!(quot) + ) + ); + } + test_field_quot(); + fn test_field_rem() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).rem) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(div_t), + "::", + stringify!(rem) + ) + ); + } + test_field_rem(); } -pub type __darwin_mbstate_t = __mbstate_t; -pub type __darwin_ptrdiff_t = ::std::os::raw::c_long; -pub type __darwin_size_t = ::std::os::raw::c_ulong; -pub type __darwin_va_list = __builtin_va_list; -pub type __darwin_wchar_t = ::std::os::raw::c_int; -pub type __darwin_rune_t = __darwin_wchar_t; -pub type __darwin_wint_t = ::std::os::raw::c_int; -pub type __darwin_clock_t = ::std::os::raw::c_ulong; -pub type __darwin_socklen_t = __uint32_t; -pub type __darwin_ssize_t = ::std::os::raw::c_long; -pub type __darwin_time_t = ::std::os::raw::c_long; -pub type __darwin_blkcnt_t = __int64_t; -pub type __darwin_blksize_t = __int32_t; -pub type __darwin_dev_t = __int32_t; -pub type __darwin_fsblkcnt_t = ::std::os::raw::c_uint; -pub type __darwin_fsfilcnt_t = ::std::os::raw::c_uint; -pub type __darwin_gid_t = __uint32_t; -pub type __darwin_id_t = __uint32_t; -pub type __darwin_ino64_t = __uint64_t; -pub type __darwin_ino_t = __darwin_ino64_t; -pub type __darwin_mach_port_name_t = __darwin_natural_t; -pub type __darwin_mach_port_t = __darwin_mach_port_name_t; -pub type __darwin_mode_t = __uint16_t; -pub type __darwin_off_t = __int64_t; -pub type __darwin_pid_t = __int32_t; -pub type __darwin_sigset_t = __uint32_t; -pub type __darwin_suseconds_t = __int32_t; -pub type __darwin_uid_t = __uint32_t; -pub type __darwin_useconds_t = __uint32_t; -pub type __darwin_uuid_t = [::std::os::raw::c_uchar; 16usize]; -pub type __darwin_uuid_string_t = [::std::os::raw::c_char; 37usize]; #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct __darwin_pthread_handler_rec { - pub __routine: ::std::option::Option, - pub __arg: *mut ::std::os::raw::c_void, - pub __next: *mut __darwin_pthread_handler_rec, +pub struct ldiv_t { + pub quot: ::std::os::raw::c_long, + pub rem: ::std::os::raw::c_long, } #[test] -fn bindgen_test_layout___darwin_pthread_handler_rec() { - assert_eq!( - ::std::mem::size_of::<__darwin_pthread_handler_rec>(), - 24usize, - concat!("Size of: ", stringify!(__darwin_pthread_handler_rec)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_pthread_handler_rec>(), - 8usize, - concat!("Alignment of ", stringify!(__darwin_pthread_handler_rec)) - ); +fn bindgen_test_layout_ldiv_t() { assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_pthread_handler_rec>())).__routine as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_pthread_handler_rec), - "::", - stringify!(__routine) - ) + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(ldiv_t)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_pthread_handler_rec>())).__arg as *const _ as usize - }, + ::std::mem::align_of::(), 8usize, - concat!( - "Offset of field: ", - stringify!(__darwin_pthread_handler_rec), - "::", - stringify!(__arg) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_pthread_handler_rec>())).__next as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_pthread_handler_rec), - "::", - stringify!(__next) - ) + concat!("Alignment of ", stringify!(ldiv_t)) ); + fn test_field_quot() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).quot) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ldiv_t), + "::", + stringify!(quot) + ) + ); + } + test_field_quot(); + fn test_field_rem() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).rem) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(ldiv_t), + "::", + stringify!(rem) + ) + ); + } + test_field_rem(); } #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct _opaque_pthread_attr_t { - pub __sig: ::std::os::raw::c_long, - pub __opaque: [::std::os::raw::c_char; 56usize], +pub struct lldiv_t { + pub quot: ::std::os::raw::c_longlong, + pub rem: ::std::os::raw::c_longlong, } #[test] -fn bindgen_test_layout__opaque_pthread_attr_t() { - assert_eq!( - ::std::mem::size_of::<_opaque_pthread_attr_t>(), - 64usize, - concat!("Size of: ", stringify!(_opaque_pthread_attr_t)) - ); - assert_eq!( - ::std::mem::align_of::<_opaque_pthread_attr_t>(), - 8usize, - concat!("Alignment of ", stringify!(_opaque_pthread_attr_t)) - ); +fn bindgen_test_layout_lldiv_t() { assert_eq!( - unsafe { &(*(::std::ptr::null::<_opaque_pthread_attr_t>())).__sig as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_attr_t), - "::", - stringify!(__sig) - ) + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(lldiv_t)) ); assert_eq!( - unsafe { &(*(::std::ptr::null::<_opaque_pthread_attr_t>())).__opaque as *const _ as usize }, + ::std::mem::align_of::(), 8usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_attr_t), - "::", - stringify!(__opaque) - ) + concat!("Alignment of ", stringify!(lldiv_t)) ); + fn test_field_quot() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).quot) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(lldiv_t), + "::", + stringify!(quot) + ) + ); + } + test_field_quot(); + fn test_field_rem() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).rem) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(lldiv_t), + "::", + stringify!(rem) + ) + ); + } + test_field_rem(); +} +extern "C" { + pub fn __ctype_get_mb_cur_max() -> usize; +} +extern "C" { + pub fn atof(__nptr: *const ::std::os::raw::c_char) -> f64; +} +extern "C" { + pub fn atoi(__nptr: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn atol(__nptr: *const ::std::os::raw::c_char) -> ::std::os::raw::c_long; +} +extern "C" { + pub fn atoll(__nptr: *const ::std::os::raw::c_char) -> ::std::os::raw::c_longlong; +} +extern "C" { + pub fn strtod( + __nptr: *const ::std::os::raw::c_char, + __endptr: *mut *mut ::std::os::raw::c_char, + ) -> f64; +} +extern "C" { + pub fn strtof( + __nptr: *const ::std::os::raw::c_char, + __endptr: *mut *mut ::std::os::raw::c_char, + ) -> f32; +} +extern "C" { + pub fn strtold( + __nptr: *const ::std::os::raw::c_char, + __endptr: *mut *mut ::std::os::raw::c_char, + ) -> f64; +} +extern "C" { + pub fn strtol( + __nptr: *const ::std::os::raw::c_char, + __endptr: *mut *mut ::std::os::raw::c_char, + __base: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_long; +} +extern "C" { + pub fn strtoul( + __nptr: *const ::std::os::raw::c_char, + __endptr: *mut *mut ::std::os::raw::c_char, + __base: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_ulong; +} +extern "C" { + pub fn strtoq( + __nptr: *const ::std::os::raw::c_char, + __endptr: *mut *mut ::std::os::raw::c_char, + __base: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_longlong; +} +extern "C" { + pub fn strtouq( + __nptr: *const ::std::os::raw::c_char, + __endptr: *mut *mut ::std::os::raw::c_char, + __base: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_ulonglong; +} +extern "C" { + pub fn strtoll( + __nptr: *const ::std::os::raw::c_char, + __endptr: *mut *mut ::std::os::raw::c_char, + __base: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_longlong; +} +extern "C" { + pub fn strtoull( + __nptr: *const ::std::os::raw::c_char, + __endptr: *mut *mut ::std::os::raw::c_char, + __base: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_ulonglong; +} +extern "C" { + pub fn l64a(__n: ::std::os::raw::c_long) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn a64l(__s: *const ::std::os::raw::c_char) -> ::std::os::raw::c_long; } +pub type __u_char = ::std::os::raw::c_uchar; +pub type __u_short = ::std::os::raw::c_ushort; +pub type __u_int = ::std::os::raw::c_uint; +pub type __u_long = ::std::os::raw::c_ulong; +pub type __int8_t = ::std::os::raw::c_schar; +pub type __uint8_t = ::std::os::raw::c_uchar; +pub type __int16_t = ::std::os::raw::c_short; +pub type __uint16_t = ::std::os::raw::c_ushort; +pub type __int32_t = ::std::os::raw::c_int; +pub type __uint32_t = ::std::os::raw::c_uint; +pub type __int64_t = ::std::os::raw::c_longlong; +pub type __uint64_t = ::std::os::raw::c_ulonglong; +pub type __int_least8_t = __int8_t; +pub type __uint_least8_t = __uint8_t; +pub type __int_least16_t = __int16_t; +pub type __uint_least16_t = __uint16_t; +pub type __int_least32_t = __int32_t; +pub type __uint_least32_t = __uint32_t; +pub type __int_least64_t = __int64_t; +pub type __uint_least64_t = __uint64_t; +pub type __quad_t = ::std::os::raw::c_longlong; +pub type __u_quad_t = ::std::os::raw::c_ulonglong; +pub type __intmax_t = ::std::os::raw::c_longlong; +pub type __uintmax_t = ::std::os::raw::c_ulonglong; +pub type __dev_t = __uint64_t; +pub type __uid_t = ::std::os::raw::c_uint; +pub type __gid_t = ::std::os::raw::c_uint; +pub type __ino_t = ::std::os::raw::c_ulong; +pub type __ino64_t = __uint64_t; +pub type __mode_t = ::std::os::raw::c_uint; +pub type __nlink_t = ::std::os::raw::c_uint; +pub type __off_t = ::std::os::raw::c_long; +pub type __off64_t = __int64_t; +pub type __pid_t = ::std::os::raw::c_int; #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct _opaque_pthread_cond_t { - pub __sig: ::std::os::raw::c_long, - pub __opaque: [::std::os::raw::c_char; 40usize], +pub struct __fsid_t { + pub __val: [::std::os::raw::c_int; 2usize], } #[test] -fn bindgen_test_layout__opaque_pthread_cond_t() { - assert_eq!( - ::std::mem::size_of::<_opaque_pthread_cond_t>(), - 48usize, - concat!("Size of: ", stringify!(_opaque_pthread_cond_t)) - ); +fn bindgen_test_layout___fsid_t() { assert_eq!( - ::std::mem::align_of::<_opaque_pthread_cond_t>(), + ::std::mem::size_of::<__fsid_t>(), 8usize, - concat!("Alignment of ", stringify!(_opaque_pthread_cond_t)) + concat!("Size of: ", stringify!(__fsid_t)) ); assert_eq!( - unsafe { &(*(::std::ptr::null::<_opaque_pthread_cond_t>())).__sig as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_cond_t), - "::", - stringify!(__sig) - ) + ::std::mem::align_of::<__fsid_t>(), + 4usize, + concat!("Alignment of ", stringify!(__fsid_t)) + ); + fn test_field___val() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__fsid_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__val) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__fsid_t), + "::", + stringify!(__val) + ) + ); + } + test_field___val(); +} +pub type __clock_t = ::std::os::raw::c_long; +pub type __rlim_t = ::std::os::raw::c_ulong; +pub type __rlim64_t = __uint64_t; +pub type __id_t = ::std::os::raw::c_uint; +pub type __time_t = ::std::os::raw::c_long; +pub type __useconds_t = ::std::os::raw::c_uint; +pub type __suseconds_t = ::std::os::raw::c_long; +pub type __daddr_t = ::std::os::raw::c_int; +pub type __key_t = ::std::os::raw::c_int; +pub type __clockid_t = ::std::os::raw::c_int; +pub type __timer_t = *mut ::std::os::raw::c_void; +pub type __blksize_t = ::std::os::raw::c_long; +pub type __blkcnt_t = ::std::os::raw::c_long; +pub type __blkcnt64_t = __int64_t; +pub type __fsblkcnt_t = ::std::os::raw::c_ulong; +pub type __fsblkcnt64_t = __uint64_t; +pub type __fsfilcnt_t = ::std::os::raw::c_ulong; +pub type __fsfilcnt64_t = __uint64_t; +pub type __fsword_t = ::std::os::raw::c_int; +pub type __ssize_t = ::std::os::raw::c_int; +pub type __syscall_slong_t = ::std::os::raw::c_long; +pub type __syscall_ulong_t = ::std::os::raw::c_ulong; +pub type __loff_t = __off64_t; +pub type __caddr_t = *mut ::std::os::raw::c_char; +pub type __intptr_t = ::std::os::raw::c_int; +pub type __socklen_t = ::std::os::raw::c_uint; +pub type __sig_atomic_t = ::std::os::raw::c_int; +pub type __time64_t = __int64_t; +pub type u_char = __u_char; +pub type u_short = __u_short; +pub type u_int = __u_int; +pub type u_long = __u_long; +pub type quad_t = __quad_t; +pub type u_quad_t = __u_quad_t; +pub type fsid_t = __fsid_t; +pub type loff_t = __loff_t; +pub type ino_t = __ino_t; +pub type dev_t = __dev_t; +pub type gid_t = __gid_t; +pub type mode_t = __mode_t; +pub type nlink_t = __nlink_t; +pub type uid_t = __uid_t; +pub type off_t = __off_t; +pub type pid_t = __pid_t; +pub type id_t = __id_t; +pub type daddr_t = __daddr_t; +pub type caddr_t = __caddr_t; +pub type key_t = __key_t; +pub type clock_t = __clock_t; +pub type clockid_t = __clockid_t; +pub type time_t = __time_t; +pub type timer_t = __timer_t; +pub type ulong = ::std::os::raw::c_ulong; +pub type ushort = ::std::os::raw::c_ushort; +pub type uint = ::std::os::raw::c_uint; +pub type u_int8_t = __uint8_t; +pub type u_int16_t = __uint16_t; +pub type u_int32_t = __uint32_t; +pub type u_int64_t = __uint64_t; +pub type register_t = ::std::os::raw::c_long; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __sigset_t { + pub __val: [::std::os::raw::c_ulong; 16usize], +} +#[test] +fn bindgen_test_layout___sigset_t() { + assert_eq!( + ::std::mem::size_of::<__sigset_t>(), + 128usize, + concat!("Size of: ", stringify!(__sigset_t)) ); assert_eq!( - unsafe { &(*(::std::ptr::null::<_opaque_pthread_cond_t>())).__opaque as *const _ as usize }, + ::std::mem::align_of::<__sigset_t>(), 8usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_cond_t), - "::", - stringify!(__opaque) - ) - ); + concat!("Alignment of ", stringify!(__sigset_t)) + ); + fn test_field___val() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__sigset_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__val) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__sigset_t), + "::", + stringify!(__val) + ) + ); + } + test_field___val(); } +pub type sigset_t = __sigset_t; #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct _opaque_pthread_condattr_t { - pub __sig: ::std::os::raw::c_long, - pub __opaque: [::std::os::raw::c_char; 8usize], +pub struct timeval { + pub tv_sec: __time_t, + pub tv_usec: __suseconds_t, } #[test] -fn bindgen_test_layout__opaque_pthread_condattr_t() { +fn bindgen_test_layout_timeval() { assert_eq!( - ::std::mem::size_of::<_opaque_pthread_condattr_t>(), + ::std::mem::size_of::(), 16usize, - concat!("Size of: ", stringify!(_opaque_pthread_condattr_t)) - ); - assert_eq!( - ::std::mem::align_of::<_opaque_pthread_condattr_t>(), - 8usize, - concat!("Alignment of ", stringify!(_opaque_pthread_condattr_t)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<_opaque_pthread_condattr_t>())).__sig as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_condattr_t), - "::", - stringify!(__sig) - ) + concat!("Size of: ", stringify!(timeval)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<_opaque_pthread_condattr_t>())).__opaque as *const _ as usize - }, + ::std::mem::align_of::(), 8usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_condattr_t), - "::", - stringify!(__opaque) - ) + concat!("Alignment of ", stringify!(timeval)) ); + fn test_field_tv_sec() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).tv_sec) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(timeval), + "::", + stringify!(tv_sec) + ) + ); + } + test_field_tv_sec(); + fn test_field_tv_usec() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).tv_usec) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(timeval), + "::", + stringify!(tv_usec) + ) + ); + } + test_field_tv_usec(); } #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct _opaque_pthread_mutex_t { - pub __sig: ::std::os::raw::c_long, - pub __opaque: [::std::os::raw::c_char; 56usize], +pub struct timespec { + pub tv_sec: __time_t, + pub tv_nsec: __syscall_slong_t, } #[test] -fn bindgen_test_layout__opaque_pthread_mutex_t() { +fn bindgen_test_layout_timespec() { assert_eq!( - ::std::mem::size_of::<_opaque_pthread_mutex_t>(), - 64usize, - concat!("Size of: ", stringify!(_opaque_pthread_mutex_t)) + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(timespec)) ); assert_eq!( - ::std::mem::align_of::<_opaque_pthread_mutex_t>(), + ::std::mem::align_of::(), 8usize, - concat!("Alignment of ", stringify!(_opaque_pthread_mutex_t)) - ); + concat!("Alignment of ", stringify!(timespec)) + ); + fn test_field_tv_sec() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).tv_sec) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(timespec), + "::", + stringify!(tv_sec) + ) + ); + } + test_field_tv_sec(); + fn test_field_tv_nsec() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).tv_nsec) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(timespec), + "::", + stringify!(tv_nsec) + ) + ); + } + test_field_tv_nsec(); +} +pub type suseconds_t = __suseconds_t; +pub type __fd_mask = ::std::os::raw::c_long; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct fd_set { + pub __fds_bits: [__fd_mask; 16usize], +} +#[test] +fn bindgen_test_layout_fd_set() { assert_eq!( - unsafe { &(*(::std::ptr::null::<_opaque_pthread_mutex_t>())).__sig as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_mutex_t), - "::", - stringify!(__sig) - ) + ::std::mem::size_of::(), + 128usize, + concat!("Size of: ", stringify!(fd_set)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<_opaque_pthread_mutex_t>())).__opaque as *const _ as usize - }, + ::std::mem::align_of::(), 8usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_mutex_t), - "::", - stringify!(__opaque) - ) - ); + concat!("Alignment of ", stringify!(fd_set)) + ); + fn test_field___fds_bits() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__fds_bits) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(fd_set), + "::", + stringify!(__fds_bits) + ) + ); + } + test_field___fds_bits(); +} +pub type fd_mask = __fd_mask; +extern "C" { + pub fn select( + __nfds: ::std::os::raw::c_int, + __readfds: *mut fd_set, + __writefds: *mut fd_set, + __exceptfds: *mut fd_set, + __timeout: *mut timeval, + ) -> ::std::os::raw::c_int; } +extern "C" { + pub fn pselect( + __nfds: ::std::os::raw::c_int, + __readfds: *mut fd_set, + __writefds: *mut fd_set, + __exceptfds: *mut fd_set, + __timeout: *const timespec, + __sigmask: *const __sigset_t, + ) -> ::std::os::raw::c_int; +} +pub type blksize_t = __blksize_t; +pub type blkcnt_t = __blkcnt_t; +pub type fsblkcnt_t = __fsblkcnt_t; +pub type fsfilcnt_t = __fsfilcnt_t; #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct _opaque_pthread_mutexattr_t { - pub __sig: ::std::os::raw::c_long, - pub __opaque: [::std::os::raw::c_char; 8usize], +pub struct __pthread_internal_list { + pub __prev: *mut __pthread_internal_list, + pub __next: *mut __pthread_internal_list, } #[test] -fn bindgen_test_layout__opaque_pthread_mutexattr_t() { +fn bindgen_test_layout___pthread_internal_list() { assert_eq!( - ::std::mem::size_of::<_opaque_pthread_mutexattr_t>(), + ::std::mem::size_of::<__pthread_internal_list>(), 16usize, - concat!("Size of: ", stringify!(_opaque_pthread_mutexattr_t)) - ); - assert_eq!( - ::std::mem::align_of::<_opaque_pthread_mutexattr_t>(), - 8usize, - concat!("Alignment of ", stringify!(_opaque_pthread_mutexattr_t)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<_opaque_pthread_mutexattr_t>())).__sig as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_mutexattr_t), - "::", - stringify!(__sig) - ) + concat!("Size of: ", stringify!(__pthread_internal_list)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<_opaque_pthread_mutexattr_t>())).__opaque as *const _ as usize - }, + ::std::mem::align_of::<__pthread_internal_list>(), 8usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_mutexattr_t), - "::", - stringify!(__opaque) - ) - ); + concat!("Alignment of ", stringify!(__pthread_internal_list)) + ); + fn test_field___prev() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_internal_list>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__prev) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__pthread_internal_list), + "::", + stringify!(__prev) + ) + ); + } + test_field___prev(); + fn test_field___next() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_internal_list>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__next) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__pthread_internal_list), + "::", + stringify!(__next) + ) + ); + } + test_field___next(); } +pub type __pthread_list_t = __pthread_internal_list; #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct _opaque_pthread_once_t { - pub __sig: ::std::os::raw::c_long, - pub __opaque: [::std::os::raw::c_char; 8usize], +pub struct __pthread_internal_slist { + pub __next: *mut __pthread_internal_slist, } #[test] -fn bindgen_test_layout__opaque_pthread_once_t() { - assert_eq!( - ::std::mem::size_of::<_opaque_pthread_once_t>(), - 16usize, - concat!("Size of: ", stringify!(_opaque_pthread_once_t)) - ); +fn bindgen_test_layout___pthread_internal_slist() { assert_eq!( - ::std::mem::align_of::<_opaque_pthread_once_t>(), + ::std::mem::size_of::<__pthread_internal_slist>(), 8usize, - concat!("Alignment of ", stringify!(_opaque_pthread_once_t)) + concat!("Size of: ", stringify!(__pthread_internal_slist)) ); assert_eq!( - unsafe { &(*(::std::ptr::null::<_opaque_pthread_once_t>())).__sig as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_once_t), - "::", - stringify!(__sig) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_opaque_pthread_once_t>())).__opaque as *const _ as usize }, + ::std::mem::align_of::<__pthread_internal_slist>(), 8usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_once_t), - "::", - stringify!(__opaque) - ) - ); + concat!("Alignment of ", stringify!(__pthread_internal_slist)) + ); + fn test_field___next() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_internal_slist>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__next) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__pthread_internal_slist), + "::", + stringify!(__next) + ) + ); + } + test_field___next(); +} +pub type __pthread_slist_t = __pthread_internal_slist; +#[repr(C)] +#[derive(Copy, Clone)] +pub struct __pthread_mutex_s { + pub __lock: ::std::os::raw::c_int, + pub __count: ::std::os::raw::c_uint, + pub __owner: ::std::os::raw::c_int, + pub __kind: ::std::os::raw::c_int, + pub __nusers: ::std::os::raw::c_uint, + pub __bindgen_anon_1: __pthread_mutex_s__bindgen_ty_1, +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union __pthread_mutex_s__bindgen_ty_1 { + pub __elision_data: __pthread_mutex_s__bindgen_ty_1__bindgen_ty_1, + pub __list: __pthread_slist_t, } #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct _opaque_pthread_rwlock_t { - pub __sig: ::std::os::raw::c_long, - pub __opaque: [::std::os::raw::c_char; 192usize], +pub struct __pthread_mutex_s__bindgen_ty_1__bindgen_ty_1 { + pub __espins: ::std::os::raw::c_short, + pub __eelision: ::std::os::raw::c_short, } #[test] -fn bindgen_test_layout__opaque_pthread_rwlock_t() { - assert_eq!( - ::std::mem::size_of::<_opaque_pthread_rwlock_t>(), - 200usize, - concat!("Size of: ", stringify!(_opaque_pthread_rwlock_t)) - ); - assert_eq!( - ::std::mem::align_of::<_opaque_pthread_rwlock_t>(), - 8usize, - concat!("Alignment of ", stringify!(_opaque_pthread_rwlock_t)) - ); +fn bindgen_test_layout___pthread_mutex_s__bindgen_ty_1__bindgen_ty_1() { assert_eq!( - unsafe { &(*(::std::ptr::null::<_opaque_pthread_rwlock_t>())).__sig as *const _ as usize }, - 0usize, + ::std::mem::size_of::<__pthread_mutex_s__bindgen_ty_1__bindgen_ty_1>(), + 4usize, concat!( - "Offset of field: ", - stringify!(_opaque_pthread_rwlock_t), - "::", - stringify!(__sig) + "Size of: ", + stringify!(__pthread_mutex_s__bindgen_ty_1__bindgen_ty_1) ) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<_opaque_pthread_rwlock_t>())).__opaque as *const _ as usize - }, - 8usize, + ::std::mem::align_of::<__pthread_mutex_s__bindgen_ty_1__bindgen_ty_1>(), + 2usize, concat!( - "Offset of field: ", - stringify!(_opaque_pthread_rwlock_t), - "::", - stringify!(__opaque) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct _opaque_pthread_rwlockattr_t { - pub __sig: ::std::os::raw::c_long, - pub __opaque: [::std::os::raw::c_char; 16usize], + "Alignment of ", + stringify!(__pthread_mutex_s__bindgen_ty_1__bindgen_ty_1) + ) + ); + fn test_field___espins() { + assert_eq!( + unsafe { + let uninit = :: std :: mem :: MaybeUninit :: < __pthread_mutex_s__bindgen_ty_1__bindgen_ty_1 > :: uninit () ; + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__espins) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__pthread_mutex_s__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(__espins) + ) + ); + } + test_field___espins(); + fn test_field___eelision() { + assert_eq!( + unsafe { + let uninit = :: std :: mem :: MaybeUninit :: < __pthread_mutex_s__bindgen_ty_1__bindgen_ty_1 > :: uninit () ; + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__eelision) as usize - ptr as usize + }, + 2usize, + concat!( + "Offset of field: ", + stringify!(__pthread_mutex_s__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(__eelision) + ) + ); + } + test_field___eelision(); } #[test] -fn bindgen_test_layout__opaque_pthread_rwlockattr_t() { +fn bindgen_test_layout___pthread_mutex_s__bindgen_ty_1() { assert_eq!( - ::std::mem::size_of::<_opaque_pthread_rwlockattr_t>(), - 24usize, - concat!("Size of: ", stringify!(_opaque_pthread_rwlockattr_t)) + ::std::mem::size_of::<__pthread_mutex_s__bindgen_ty_1>(), + 8usize, + concat!("Size of: ", stringify!(__pthread_mutex_s__bindgen_ty_1)) ); assert_eq!( - ::std::mem::align_of::<_opaque_pthread_rwlockattr_t>(), + ::std::mem::align_of::<__pthread_mutex_s__bindgen_ty_1>(), 8usize, - concat!("Alignment of ", stringify!(_opaque_pthread_rwlockattr_t)) - ); + concat!("Alignment of ", stringify!(__pthread_mutex_s__bindgen_ty_1)) + ); + fn test_field___elision_data() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_mutex_s__bindgen_ty_1>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__elision_data) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__pthread_mutex_s__bindgen_ty_1), + "::", + stringify!(__elision_data) + ) + ); + } + test_field___elision_data(); + fn test_field___list() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_mutex_s__bindgen_ty_1>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__list) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__pthread_mutex_s__bindgen_ty_1), + "::", + stringify!(__list) + ) + ); + } + test_field___list(); +} +#[test] +fn bindgen_test_layout___pthread_mutex_s() { assert_eq!( - unsafe { - &(*(::std::ptr::null::<_opaque_pthread_rwlockattr_t>())).__sig as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_rwlockattr_t), - "::", - stringify!(__sig) - ) + ::std::mem::size_of::<__pthread_mutex_s>(), + 32usize, + concat!("Size of: ", stringify!(__pthread_mutex_s)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<_opaque_pthread_rwlockattr_t>())).__opaque as *const _ as usize - }, + ::std::mem::align_of::<__pthread_mutex_s>(), 8usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_rwlockattr_t), - "::", - stringify!(__opaque) - ) - ); + concat!("Alignment of ", stringify!(__pthread_mutex_s)) + ); + fn test_field___lock() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_mutex_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__lock) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__pthread_mutex_s), + "::", + stringify!(__lock) + ) + ); + } + test_field___lock(); + fn test_field___count() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_mutex_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__count) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(__pthread_mutex_s), + "::", + stringify!(__count) + ) + ); + } + test_field___count(); + fn test_field___owner() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_mutex_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__owner) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__pthread_mutex_s), + "::", + stringify!(__owner) + ) + ); + } + test_field___owner(); + fn test_field___kind() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_mutex_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__kind) as usize - ptr as usize + }, + 12usize, + concat!( + "Offset of field: ", + stringify!(__pthread_mutex_s), + "::", + stringify!(__kind) + ) + ); + } + test_field___kind(); + fn test_field___nusers() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_mutex_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__nusers) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(__pthread_mutex_s), + "::", + stringify!(__nusers) + ) + ); + } + test_field___nusers(); } #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct _opaque_pthread_t { - pub __sig: ::std::os::raw::c_long, - pub __cleanup_stack: *mut __darwin_pthread_handler_rec, - pub __opaque: [::std::os::raw::c_char; 8176usize], +pub struct __pthread_rwlock_arch_t { + pub __readers: ::std::os::raw::c_uint, + pub __writers: ::std::os::raw::c_uint, + pub __wrphase_futex: ::std::os::raw::c_uint, + pub __writers_futex: ::std::os::raw::c_uint, + pub __pad3: ::std::os::raw::c_uint, + pub __pad4: ::std::os::raw::c_uint, + pub __flags: ::std::os::raw::c_uchar, + pub __shared: ::std::os::raw::c_uchar, + pub __rwelision: ::std::os::raw::c_schar, + pub __pad2: ::std::os::raw::c_uchar, + pub __cur_writer: ::std::os::raw::c_int, } #[test] -fn bindgen_test_layout__opaque_pthread_t() { - assert_eq!( - ::std::mem::size_of::<_opaque_pthread_t>(), - 8192usize, - concat!("Size of: ", stringify!(_opaque_pthread_t)) - ); - assert_eq!( - ::std::mem::align_of::<_opaque_pthread_t>(), - 8usize, - concat!("Alignment of ", stringify!(_opaque_pthread_t)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_opaque_pthread_t>())).__sig as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_t), - "::", - stringify!(__sig) - ) - ); +fn bindgen_test_layout___pthread_rwlock_arch_t() { assert_eq!( - unsafe { - &(*(::std::ptr::null::<_opaque_pthread_t>())).__cleanup_stack as *const _ as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_t), - "::", - stringify!(__cleanup_stack) - ) + ::std::mem::size_of::<__pthread_rwlock_arch_t>(), + 32usize, + concat!("Size of: ", stringify!(__pthread_rwlock_arch_t)) ); assert_eq!( - unsafe { &(*(::std::ptr::null::<_opaque_pthread_t>())).__opaque as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_t), - "::", - stringify!(__opaque) - ) - ); + ::std::mem::align_of::<__pthread_rwlock_arch_t>(), + 4usize, + concat!("Alignment of ", stringify!(__pthread_rwlock_arch_t)) + ); + fn test_field___readers() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_rwlock_arch_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__readers) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__pthread_rwlock_arch_t), + "::", + stringify!(__readers) + ) + ); + } + test_field___readers(); + fn test_field___writers() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_rwlock_arch_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__writers) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(__pthread_rwlock_arch_t), + "::", + stringify!(__writers) + ) + ); + } + test_field___writers(); + fn test_field___wrphase_futex() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_rwlock_arch_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__wrphase_futex) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__pthread_rwlock_arch_t), + "::", + stringify!(__wrphase_futex) + ) + ); + } + test_field___wrphase_futex(); + fn test_field___writers_futex() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_rwlock_arch_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__writers_futex) as usize - ptr as usize + }, + 12usize, + concat!( + "Offset of field: ", + stringify!(__pthread_rwlock_arch_t), + "::", + stringify!(__writers_futex) + ) + ); + } + test_field___writers_futex(); + fn test_field___pad3() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_rwlock_arch_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__pad3) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(__pthread_rwlock_arch_t), + "::", + stringify!(__pad3) + ) + ); + } + test_field___pad3(); + fn test_field___pad4() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_rwlock_arch_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__pad4) as usize - ptr as usize + }, + 20usize, + concat!( + "Offset of field: ", + stringify!(__pthread_rwlock_arch_t), + "::", + stringify!(__pad4) + ) + ); + } + test_field___pad4(); + fn test_field___flags() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_rwlock_arch_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__flags) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(__pthread_rwlock_arch_t), + "::", + stringify!(__flags) + ) + ); + } + test_field___flags(); + fn test_field___shared() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_rwlock_arch_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__shared) as usize - ptr as usize + }, + 25usize, + concat!( + "Offset of field: ", + stringify!(__pthread_rwlock_arch_t), + "::", + stringify!(__shared) + ) + ); + } + test_field___shared(); + fn test_field___rwelision() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_rwlock_arch_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__rwelision) as usize - ptr as usize + }, + 26usize, + concat!( + "Offset of field: ", + stringify!(__pthread_rwlock_arch_t), + "::", + stringify!(__rwelision) + ) + ); + } + test_field___rwelision(); + fn test_field___pad2() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_rwlock_arch_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__pad2) as usize - ptr as usize + }, + 27usize, + concat!( + "Offset of field: ", + stringify!(__pthread_rwlock_arch_t), + "::", + stringify!(__pad2) + ) + ); + } + test_field___pad2(); + fn test_field___cur_writer() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_rwlock_arch_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__cur_writer) as usize - ptr as usize + }, + 28usize, + concat!( + "Offset of field: ", + stringify!(__pthread_rwlock_arch_t), + "::", + stringify!(__cur_writer) + ) + ); + } + test_field___cur_writer(); } -pub type __darwin_pthread_attr_t = _opaque_pthread_attr_t; -pub type __darwin_pthread_cond_t = _opaque_pthread_cond_t; -pub type __darwin_pthread_condattr_t = _opaque_pthread_condattr_t; -pub type __darwin_pthread_key_t = ::std::os::raw::c_ulong; -pub type __darwin_pthread_mutex_t = _opaque_pthread_mutex_t; -pub type __darwin_pthread_mutexattr_t = _opaque_pthread_mutexattr_t; -pub type __darwin_pthread_once_t = _opaque_pthread_once_t; -pub type __darwin_pthread_rwlock_t = _opaque_pthread_rwlock_t; -pub type __darwin_pthread_rwlockattr_t = _opaque_pthread_rwlockattr_t; -pub type __darwin_pthread_t = *mut _opaque_pthread_t; -pub type __darwin_nl_item = ::std::os::raw::c_int; -pub type __darwin_wctrans_t = ::std::os::raw::c_int; -pub type __darwin_wctype_t = __uint32_t; -#[repr(u32)] -#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum idtype_t { - P_ALL = 0, - P_PID = 1, - P_PGID = 2, +#[repr(C)] +#[derive(Copy, Clone)] +pub struct __pthread_cond_s { + pub __bindgen_anon_1: __pthread_cond_s__bindgen_ty_1, + pub __bindgen_anon_2: __pthread_cond_s__bindgen_ty_2, + pub __g_refs: [::std::os::raw::c_uint; 2usize], + pub __g_size: [::std::os::raw::c_uint; 2usize], + pub __g1_orig_size: ::std::os::raw::c_uint, + pub __wrefs: ::std::os::raw::c_uint, + pub __g_signals: [::std::os::raw::c_uint; 2usize], +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union __pthread_cond_s__bindgen_ty_1 { + pub __wseq: ::std::os::raw::c_ulonglong, + pub __wseq32: __pthread_cond_s__bindgen_ty_1__bindgen_ty_1, } -pub type pid_t = __darwin_pid_t; -pub type id_t = __darwin_id_t; -pub type sig_atomic_t = ::std::os::raw::c_int; -pub type u_int8_t = ::std::os::raw::c_uchar; -pub type u_int16_t = ::std::os::raw::c_ushort; -pub type u_int32_t = ::std::os::raw::c_uint; -pub type u_int64_t = ::std::os::raw::c_ulonglong; -pub type register_t = i64; -pub type user_addr_t = u_int64_t; -pub type user_size_t = u_int64_t; -pub type user_ssize_t = i64; -pub type user_long_t = i64; -pub type user_ulong_t = u_int64_t; -pub type user_time_t = i64; -pub type user_off_t = i64; -pub type syscall_arg_t = u_int64_t; #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct __darwin_arm_exception_state { - pub __exception: __uint32_t, - pub __fsr: __uint32_t, - pub __far: __uint32_t, +pub struct __pthread_cond_s__bindgen_ty_1__bindgen_ty_1 { + pub __low: ::std::os::raw::c_uint, + pub __high: ::std::os::raw::c_uint, } #[test] -fn bindgen_test_layout___darwin_arm_exception_state() { - assert_eq!( - ::std::mem::size_of::<__darwin_arm_exception_state>(), - 12usize, - concat!("Size of: ", stringify!(__darwin_arm_exception_state)) - ); +fn bindgen_test_layout___pthread_cond_s__bindgen_ty_1__bindgen_ty_1() { assert_eq!( - ::std::mem::align_of::<__darwin_arm_exception_state>(), - 4usize, - concat!("Alignment of ", stringify!(__darwin_arm_exception_state)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_arm_exception_state>())).__exception as *const _ - as usize - }, - 0usize, + ::std::mem::size_of::<__pthread_cond_s__bindgen_ty_1__bindgen_ty_1>(), + 8usize, concat!( - "Offset of field: ", - stringify!(__darwin_arm_exception_state), - "::", - stringify!(__exception) + "Size of: ", + stringify!(__pthread_cond_s__bindgen_ty_1__bindgen_ty_1) ) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_arm_exception_state>())).__fsr as *const _ as usize - }, + ::std::mem::align_of::<__pthread_cond_s__bindgen_ty_1__bindgen_ty_1>(), 4usize, concat!( - "Offset of field: ", - stringify!(__darwin_arm_exception_state), - "::", - stringify!(__fsr) - ) - ); + "Alignment of ", + stringify!(__pthread_cond_s__bindgen_ty_1__bindgen_ty_1) + ) + ); + fn test_field___low() { + assert_eq!( + unsafe { + let uninit = + ::std::mem::MaybeUninit::<__pthread_cond_s__bindgen_ty_1__bindgen_ty_1>::uninit( + ); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__low) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(__low) + ) + ); + } + test_field___low(); + fn test_field___high() { + assert_eq!( + unsafe { + let uninit = + ::std::mem::MaybeUninit::<__pthread_cond_s__bindgen_ty_1__bindgen_ty_1>::uninit( + ); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__high) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(__high) + ) + ); + } + test_field___high(); +} +#[test] +fn bindgen_test_layout___pthread_cond_s__bindgen_ty_1() { assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_arm_exception_state>())).__far as *const _ as usize - }, + ::std::mem::size_of::<__pthread_cond_s__bindgen_ty_1>(), 8usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_exception_state), - "::", - stringify!(__far) - ) + concat!("Size of: ", stringify!(__pthread_cond_s__bindgen_ty_1)) ); + assert_eq!( + ::std::mem::align_of::<__pthread_cond_s__bindgen_ty_1>(), + 8usize, + concat!("Alignment of ", stringify!(__pthread_cond_s__bindgen_ty_1)) + ); + fn test_field___wseq() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_cond_s__bindgen_ty_1>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__wseq) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s__bindgen_ty_1), + "::", + stringify!(__wseq) + ) + ); + } + test_field___wseq(); + fn test_field___wseq32() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_cond_s__bindgen_ty_1>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__wseq32) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s__bindgen_ty_1), + "::", + stringify!(__wseq32) + ) + ); + } + test_field___wseq32(); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union __pthread_cond_s__bindgen_ty_2 { + pub __g1_start: ::std::os::raw::c_ulonglong, + pub __g1_start32: __pthread_cond_s__bindgen_ty_2__bindgen_ty_1, } #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct __darwin_arm_exception_state64 { - pub __far: __uint64_t, - pub __esr: __uint32_t, - pub __exception: __uint32_t, +pub struct __pthread_cond_s__bindgen_ty_2__bindgen_ty_1 { + pub __low: ::std::os::raw::c_uint, + pub __high: ::std::os::raw::c_uint, } #[test] -fn bindgen_test_layout___darwin_arm_exception_state64() { - assert_eq!( - ::std::mem::size_of::<__darwin_arm_exception_state64>(), - 16usize, - concat!("Size of: ", stringify!(__darwin_arm_exception_state64)) - ); +fn bindgen_test_layout___pthread_cond_s__bindgen_ty_2__bindgen_ty_1() { assert_eq!( - ::std::mem::align_of::<__darwin_arm_exception_state64>(), + ::std::mem::size_of::<__pthread_cond_s__bindgen_ty_2__bindgen_ty_1>(), 8usize, - concat!("Alignment of ", stringify!(__darwin_arm_exception_state64)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_arm_exception_state64>())).__far as *const _ as usize - }, - 0usize, concat!( - "Offset of field: ", - stringify!(__darwin_arm_exception_state64), - "::", - stringify!(__far) + "Size of: ", + stringify!(__pthread_cond_s__bindgen_ty_2__bindgen_ty_1) ) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_arm_exception_state64>())).__esr as *const _ as usize - }, - 8usize, + ::std::mem::align_of::<__pthread_cond_s__bindgen_ty_2__bindgen_ty_1>(), + 4usize, concat!( - "Offset of field: ", - stringify!(__darwin_arm_exception_state64), - "::", - stringify!(__esr) - ) + "Alignment of ", + stringify!(__pthread_cond_s__bindgen_ty_2__bindgen_ty_1) + ) + ); + fn test_field___low() { + assert_eq!( + unsafe { + let uninit = + ::std::mem::MaybeUninit::<__pthread_cond_s__bindgen_ty_2__bindgen_ty_1>::uninit( + ); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__low) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s__bindgen_ty_2__bindgen_ty_1), + "::", + stringify!(__low) + ) + ); + } + test_field___low(); + fn test_field___high() { + assert_eq!( + unsafe { + let uninit = + ::std::mem::MaybeUninit::<__pthread_cond_s__bindgen_ty_2__bindgen_ty_1>::uninit( + ); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__high) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s__bindgen_ty_2__bindgen_ty_1), + "::", + stringify!(__high) + ) + ); + } + test_field___high(); +} +#[test] +fn bindgen_test_layout___pthread_cond_s__bindgen_ty_2() { + assert_eq!( + ::std::mem::size_of::<__pthread_cond_s__bindgen_ty_2>(), + 8usize, + concat!("Size of: ", stringify!(__pthread_cond_s__bindgen_ty_2)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_arm_exception_state64>())).__exception as *const _ - as usize - }, - 12usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_exception_state64), - "::", - stringify!(__exception) - ) + ::std::mem::align_of::<__pthread_cond_s__bindgen_ty_2>(), + 8usize, + concat!("Alignment of ", stringify!(__pthread_cond_s__bindgen_ty_2)) + ); + fn test_field___g1_start() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_cond_s__bindgen_ty_2>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__g1_start) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s__bindgen_ty_2), + "::", + stringify!(__g1_start) + ) + ); + } + test_field___g1_start(); + fn test_field___g1_start32() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_cond_s__bindgen_ty_2>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__g1_start32) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s__bindgen_ty_2), + "::", + stringify!(__g1_start32) + ) + ); + } + test_field___g1_start32(); +} +#[test] +fn bindgen_test_layout___pthread_cond_s() { + assert_eq!( + ::std::mem::size_of::<__pthread_cond_s>(), + 48usize, + concat!("Size of: ", stringify!(__pthread_cond_s)) ); + assert_eq!( + ::std::mem::align_of::<__pthread_cond_s>(), + 8usize, + concat!("Alignment of ", stringify!(__pthread_cond_s)) + ); + fn test_field___g_refs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_cond_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__g_refs) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s), + "::", + stringify!(__g_refs) + ) + ); + } + test_field___g_refs(); + fn test_field___g_size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_cond_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__g_size) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s), + "::", + stringify!(__g_size) + ) + ); + } + test_field___g_size(); + fn test_field___g1_orig_size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_cond_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__g1_orig_size) as usize - ptr as usize + }, + 32usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s), + "::", + stringify!(__g1_orig_size) + ) + ); + } + test_field___g1_orig_size(); + fn test_field___wrefs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_cond_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__wrefs) as usize - ptr as usize + }, + 36usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s), + "::", + stringify!(__wrefs) + ) + ); + } + test_field___wrefs(); + fn test_field___g_signals() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_cond_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__g_signals) as usize - ptr as usize + }, + 40usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s), + "::", + stringify!(__g_signals) + ) + ); + } + test_field___g_signals(); } +pub type pthread_t = ::std::os::raw::c_ulong; #[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_arm_thread_state { - pub __r: [__uint32_t; 13usize], - pub __sp: __uint32_t, - pub __lr: __uint32_t, - pub __pc: __uint32_t, - pub __cpsr: __uint32_t, +#[derive(Copy, Clone)] +pub union pthread_mutexattr_t { + pub __size: [::std::os::raw::c_char; 4usize], + pub __align: ::std::os::raw::c_int, } #[test] -fn bindgen_test_layout___darwin_arm_thread_state() { +fn bindgen_test_layout_pthread_mutexattr_t() { assert_eq!( - ::std::mem::size_of::<__darwin_arm_thread_state>(), - 68usize, - concat!("Size of: ", stringify!(__darwin_arm_thread_state)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_arm_thread_state>(), + ::std::mem::size_of::(), 4usize, - concat!("Alignment of ", stringify!(__darwin_arm_thread_state)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_arm_thread_state>())).__r as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_thread_state), - "::", - stringify!(__r) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_arm_thread_state>())).__sp as *const _ as usize }, - 52usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_thread_state), - "::", - stringify!(__sp) - ) + concat!("Size of: ", stringify!(pthread_mutexattr_t)) ); assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_arm_thread_state>())).__lr as *const _ as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_thread_state), - "::", - stringify!(__lr) - ) - ); + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pthread_mutexattr_t)) + ); + fn test_field___size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__size) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_mutexattr_t), + "::", + stringify!(__size) + ) + ); + } + test_field___size(); + fn test_field___align() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__align) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_mutexattr_t), + "::", + stringify!(__align) + ) + ); + } + test_field___align(); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pthread_condattr_t { + pub __size: [::std::os::raw::c_char; 4usize], + pub __align: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_pthread_condattr_t() { assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_arm_thread_state>())).__pc as *const _ as usize }, - 60usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_thread_state), - "::", - stringify!(__pc) - ) + ::std::mem::size_of::(), + 4usize, + concat!("Size of: ", stringify!(pthread_condattr_t)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_arm_thread_state>())).__cpsr as *const _ as usize - }, - 64usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_thread_state), - "::", - stringify!(__cpsr) - ) - ); + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pthread_condattr_t)) + ); + fn test_field___size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__size) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_condattr_t), + "::", + stringify!(__size) + ) + ); + } + test_field___size(); + fn test_field___align() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__align) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_condattr_t), + "::", + stringify!(__align) + ) + ); + } + test_field___align(); } +pub type pthread_key_t = ::std::os::raw::c_uint; +pub type pthread_once_t = ::std::os::raw::c_int; #[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_arm_thread_state64 { - pub __x: [__uint64_t; 29usize], - pub __fp: __uint64_t, - pub __lr: __uint64_t, - pub __sp: __uint64_t, - pub __pc: __uint64_t, - pub __cpsr: __uint32_t, - pub __pad: __uint32_t, +#[derive(Copy, Clone)] +pub union pthread_attr_t { + pub __size: [::std::os::raw::c_char; 36usize], + pub __align: ::std::os::raw::c_long, } #[test] -fn bindgen_test_layout___darwin_arm_thread_state64() { +fn bindgen_test_layout_pthread_attr_t() { assert_eq!( - ::std::mem::size_of::<__darwin_arm_thread_state64>(), - 272usize, - concat!("Size of: ", stringify!(__darwin_arm_thread_state64)) + ::std::mem::size_of::(), + 40usize, + concat!("Size of: ", stringify!(pthread_attr_t)) ); assert_eq!( - ::std::mem::align_of::<__darwin_arm_thread_state64>(), + ::std::mem::align_of::(), 8usize, - concat!("Alignment of ", stringify!(__darwin_arm_thread_state64)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_arm_thread_state64>())).__x as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_thread_state64), - "::", - stringify!(__x) - ) - ); + concat!("Alignment of ", stringify!(pthread_attr_t)) + ); + fn test_field___size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__size) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_attr_t), + "::", + stringify!(__size) + ) + ); + } + test_field___size(); + fn test_field___align() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__align) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_attr_t), + "::", + stringify!(__align) + ) + ); + } + test_field___align(); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pthread_mutex_t { + pub __data: __pthread_mutex_s, + pub __size: [::std::os::raw::c_char; 24usize], + pub __align: ::std::os::raw::c_long, +} +#[test] +fn bindgen_test_layout_pthread_mutex_t() { assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_arm_thread_state64>())).__fp as *const _ as usize - }, - 232usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_thread_state64), - "::", - stringify!(__fp) - ) + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(pthread_mutex_t)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_arm_thread_state64>())).__lr as *const _ as usize - }, - 240usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_thread_state64), - "::", - stringify!(__lr) - ) - ); + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pthread_mutex_t)) + ); + fn test_field___data() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__data) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_mutex_t), + "::", + stringify!(__data) + ) + ); + } + test_field___data(); + fn test_field___size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__size) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_mutex_t), + "::", + stringify!(__size) + ) + ); + } + test_field___size(); + fn test_field___align() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__align) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_mutex_t), + "::", + stringify!(__align) + ) + ); + } + test_field___align(); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pthread_cond_t { + pub __data: __pthread_cond_s, + pub __size: [::std::os::raw::c_char; 48usize], + pub __align: ::std::os::raw::c_longlong, +} +#[test] +fn bindgen_test_layout_pthread_cond_t() { assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_arm_thread_state64>())).__sp as *const _ as usize - }, - 248usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_thread_state64), - "::", - stringify!(__sp) - ) + ::std::mem::size_of::(), + 48usize, + concat!("Size of: ", stringify!(pthread_cond_t)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_arm_thread_state64>())).__pc as *const _ as usize - }, - 256usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_thread_state64), - "::", - stringify!(__pc) - ) - ); + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pthread_cond_t)) + ); + fn test_field___data() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__data) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_cond_t), + "::", + stringify!(__data) + ) + ); + } + test_field___data(); + fn test_field___size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__size) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_cond_t), + "::", + stringify!(__size) + ) + ); + } + test_field___size(); + fn test_field___align() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__align) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_cond_t), + "::", + stringify!(__align) + ) + ); + } + test_field___align(); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union pthread_rwlock_t { + pub __data: __pthread_rwlock_arch_t, + pub __size: [::std::os::raw::c_char; 32usize], + pub __align: ::std::os::raw::c_long, +} +#[test] +fn bindgen_test_layout_pthread_rwlock_t() { assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_arm_thread_state64>())).__cpsr as *const _ as usize - }, - 264usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_thread_state64), - "::", - stringify!(__cpsr) - ) + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(pthread_rwlock_t)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_arm_thread_state64>())).__pad as *const _ as usize - }, - 268usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_thread_state64), - "::", - stringify!(__pad) - ) - ); + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pthread_rwlock_t)) + ); + fn test_field___data() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__data) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_rwlock_t), + "::", + stringify!(__data) + ) + ); + } + test_field___data(); + fn test_field___size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__size) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_rwlock_t), + "::", + stringify!(__size) + ) + ); + } + test_field___size(); + fn test_field___align() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__align) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_rwlock_t), + "::", + stringify!(__align) + ) + ); + } + test_field___align(); } #[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_arm_vfp_state { - pub __r: [__uint32_t; 64usize], - pub __fpscr: __uint32_t, +#[derive(Copy, Clone)] +pub union pthread_rwlockattr_t { + pub __size: [::std::os::raw::c_char; 8usize], + pub __align: ::std::os::raw::c_long, } #[test] -fn bindgen_test_layout___darwin_arm_vfp_state() { +fn bindgen_test_layout_pthread_rwlockattr_t() { assert_eq!( - ::std::mem::size_of::<__darwin_arm_vfp_state>(), - 260usize, - concat!("Size of: ", stringify!(__darwin_arm_vfp_state)) + ::std::mem::size_of::(), + 8usize, + concat!("Size of: ", stringify!(pthread_rwlockattr_t)) ); assert_eq!( - ::std::mem::align_of::<__darwin_arm_vfp_state>(), - 4usize, - concat!("Alignment of ", stringify!(__darwin_arm_vfp_state)) - ); + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pthread_rwlockattr_t)) + ); + fn test_field___size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__size) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_rwlockattr_t), + "::", + stringify!(__size) + ) + ); + } + test_field___size(); + fn test_field___align() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__align) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_rwlockattr_t), + "::", + stringify!(__align) + ) + ); + } + test_field___align(); +} +pub type pthread_spinlock_t = ::std::os::raw::c_int; +#[repr(C)] +#[derive(Copy, Clone)] +pub union pthread_barrier_t { + pub __size: [::std::os::raw::c_char; 20usize], + pub __align: ::std::os::raw::c_long, +} +#[test] +fn bindgen_test_layout_pthread_barrier_t() { assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_arm_vfp_state>())).__r as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_vfp_state), - "::", - stringify!(__r) - ) + ::std::mem::size_of::(), + 24usize, + concat!("Size of: ", stringify!(pthread_barrier_t)) ); assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_arm_vfp_state>())).__fpscr as *const _ as usize }, - 256usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_vfp_state), - "::", - stringify!(__fpscr) - ) - ); + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pthread_barrier_t)) + ); + fn test_field___size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__size) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_barrier_t), + "::", + stringify!(__size) + ) + ); + } + test_field___size(); + fn test_field___align() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__align) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_barrier_t), + "::", + stringify!(__align) + ) + ); + } + test_field___align(); } #[repr(C)] -#[repr(align(16))] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_arm_neon_state64 { - pub __v: [__uint128_t; 32usize], - pub __fpsr: __uint32_t, - pub __fpcr: __uint32_t, +#[derive(Copy, Clone)] +pub union pthread_barrierattr_t { + pub __size: [::std::os::raw::c_char; 4usize], + pub __align: ::std::os::raw::c_int, } #[test] -fn bindgen_test_layout___darwin_arm_neon_state64() { - assert_eq!( - ::std::mem::size_of::<__darwin_arm_neon_state64>(), - 528usize, - concat!("Size of: ", stringify!(__darwin_arm_neon_state64)) - ); +fn bindgen_test_layout_pthread_barrierattr_t() { assert_eq!( - ::std::mem::align_of::<__darwin_arm_neon_state64>(), - 16usize, - concat!("Alignment of ", stringify!(__darwin_arm_neon_state64)) + ::std::mem::size_of::(), + 4usize, + concat!("Size of: ", stringify!(pthread_barrierattr_t)) ); assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_arm_neon_state64>())).__v as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_neon_state64), - "::", - stringify!(__v) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_arm_neon_state64>())).__fpsr as *const _ as usize - }, - 512usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_neon_state64), - "::", - stringify!(__fpsr) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_arm_neon_state64>())).__fpcr as *const _ as usize - }, - 516usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_neon_state64), - "::", - stringify!(__fpcr) - ) - ); + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pthread_barrierattr_t)) + ); + fn test_field___size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__size) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_barrierattr_t), + "::", + stringify!(__size) + ) + ); + } + test_field___size(); + fn test_field___align() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__align) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_barrierattr_t), + "::", + stringify!(__align) + ) + ); + } + test_field___align(); } -#[repr(C)] -#[repr(align(16))] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_arm_neon_state { - pub __v: [__uint128_t; 16usize], - pub __fpsr: __uint32_t, - pub __fpcr: __uint32_t, +extern "C" { + pub fn random() -> ::std::os::raw::c_long; } -#[test] -fn bindgen_test_layout___darwin_arm_neon_state() { - assert_eq!( - ::std::mem::size_of::<__darwin_arm_neon_state>(), - 272usize, - concat!("Size of: ", stringify!(__darwin_arm_neon_state)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_arm_neon_state>(), - 16usize, - concat!("Alignment of ", stringify!(__darwin_arm_neon_state)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_arm_neon_state>())).__v as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_neon_state), - "::", - stringify!(__v) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_arm_neon_state>())).__fpsr as *const _ as usize }, - 256usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_neon_state), - "::", - stringify!(__fpsr) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_arm_neon_state>())).__fpcr as *const _ as usize }, - 260usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_neon_state), - "::", - stringify!(__fpcr) - ) - ); +extern "C" { + pub fn srandom(__seed: ::std::os::raw::c_uint); } -#[repr(C)] -#[repr(align(64))] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_arm_amx_state_v1 { - pub __x: [[__uint8_t; 64usize]; 8usize], - pub __y: [[__uint8_t; 64usize]; 8usize], - pub __z: [[__uint8_t; 64usize]; 64usize], - pub __amx_state_t_el1: __uint64_t, +extern "C" { + pub fn initstate( + __seed: ::std::os::raw::c_uint, + __statebuf: *mut ::std::os::raw::c_char, + __statelen: usize, + ) -> *mut ::std::os::raw::c_char; } -#[test] -fn bindgen_test_layout___darwin_arm_amx_state_v1() { - assert_eq!( - ::std::mem::size_of::<__darwin_arm_amx_state_v1>(), - 5184usize, - concat!("Size of: ", stringify!(__darwin_arm_amx_state_v1)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_arm_amx_state_v1>(), - 64usize, - concat!("Alignment of ", stringify!(__darwin_arm_amx_state_v1)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_arm_amx_state_v1>())).__x as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_amx_state_v1), - "::", - stringify!(__x) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_arm_amx_state_v1>())).__y as *const _ as usize }, - 512usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_amx_state_v1), - "::", - stringify!(__y) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_arm_amx_state_v1>())).__z as *const _ as usize }, - 1024usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_amx_state_v1), - "::", - stringify!(__z) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_arm_amx_state_v1>())).__amx_state_t_el1 as *const _ - as usize - }, - 5120usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_amx_state_v1), - "::", - stringify!(__amx_state_t_el1) - ) - ); +extern "C" { + pub fn setstate(__statebuf: *mut ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; } #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct __arm_pagein_state { - pub __pagein_error: ::std::os::raw::c_int, +pub struct random_data { + pub fptr: *mut i32, + pub rptr: *mut i32, + pub state: *mut i32, + pub rand_type: ::std::os::raw::c_int, + pub rand_deg: ::std::os::raw::c_int, + pub rand_sep: ::std::os::raw::c_int, + pub end_ptr: *mut i32, } #[test] -fn bindgen_test_layout___arm_pagein_state() { - assert_eq!( - ::std::mem::size_of::<__arm_pagein_state>(), - 4usize, - concat!("Size of: ", stringify!(__arm_pagein_state)) - ); +fn bindgen_test_layout_random_data() { assert_eq!( - ::std::mem::align_of::<__arm_pagein_state>(), - 4usize, - concat!("Alignment of ", stringify!(__arm_pagein_state)) + ::std::mem::size_of::(), + 48usize, + concat!("Size of: ", stringify!(random_data)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__arm_pagein_state>())).__pagein_error as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__arm_pagein_state), - "::", - stringify!(__pagein_error) - ) - ); + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(random_data)) + ); + fn test_field_fptr() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).fptr) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(random_data), + "::", + stringify!(fptr) + ) + ); + } + test_field_fptr(); + fn test_field_rptr() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).rptr) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(random_data), + "::", + stringify!(rptr) + ) + ); + } + test_field_rptr(); + fn test_field_state() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).state) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(random_data), + "::", + stringify!(state) + ) + ); + } + test_field_state(); + fn test_field_rand_type() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).rand_type) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(random_data), + "::", + stringify!(rand_type) + ) + ); + } + test_field_rand_type(); + fn test_field_rand_deg() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).rand_deg) as usize - ptr as usize + }, + 28usize, + concat!( + "Offset of field: ", + stringify!(random_data), + "::", + stringify!(rand_deg) + ) + ); + } + test_field_rand_deg(); + fn test_field_rand_sep() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).rand_sep) as usize - ptr as usize + }, + 32usize, + concat!( + "Offset of field: ", + stringify!(random_data), + "::", + stringify!(rand_sep) + ) + ); + } + test_field_rand_sep(); + fn test_field_end_ptr() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).end_ptr) as usize - ptr as usize + }, + 40usize, + concat!( + "Offset of field: ", + stringify!(random_data), + "::", + stringify!(end_ptr) + ) + ); + } + test_field_end_ptr(); } -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __arm_legacy_debug_state { - pub __bvr: [__uint32_t; 16usize], - pub __bcr: [__uint32_t; 16usize], - pub __wvr: [__uint32_t; 16usize], - pub __wcr: [__uint32_t; 16usize], +extern "C" { + pub fn random_r(__buf: *mut random_data, __result: *mut i32) -> ::std::os::raw::c_int; } -#[test] -fn bindgen_test_layout___arm_legacy_debug_state() { - assert_eq!( - ::std::mem::size_of::<__arm_legacy_debug_state>(), - 256usize, - concat!("Size of: ", stringify!(__arm_legacy_debug_state)) - ); - assert_eq!( - ::std::mem::align_of::<__arm_legacy_debug_state>(), - 4usize, - concat!("Alignment of ", stringify!(__arm_legacy_debug_state)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__arm_legacy_debug_state>())).__bvr as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__arm_legacy_debug_state), - "::", - stringify!(__bvr) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__arm_legacy_debug_state>())).__bcr as *const _ as usize }, - 64usize, - concat!( - "Offset of field: ", - stringify!(__arm_legacy_debug_state), - "::", - stringify!(__bcr) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__arm_legacy_debug_state>())).__wvr as *const _ as usize }, - 128usize, - concat!( - "Offset of field: ", - stringify!(__arm_legacy_debug_state), - "::", - stringify!(__wvr) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__arm_legacy_debug_state>())).__wcr as *const _ as usize }, - 192usize, - concat!( - "Offset of field: ", - stringify!(__arm_legacy_debug_state), - "::", - stringify!(__wcr) - ) - ); +extern "C" { + pub fn srandom_r( + __seed: ::std::os::raw::c_uint, + __buf: *mut random_data, + ) -> ::std::os::raw::c_int; } -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_arm_debug_state32 { - pub __bvr: [__uint32_t; 16usize], - pub __bcr: [__uint32_t; 16usize], - pub __wvr: [__uint32_t; 16usize], - pub __wcr: [__uint32_t; 16usize], - pub __mdscr_el1: __uint64_t, +extern "C" { + pub fn initstate_r( + __seed: ::std::os::raw::c_uint, + __statebuf: *mut ::std::os::raw::c_char, + __statelen: usize, + __buf: *mut random_data, + ) -> ::std::os::raw::c_int; } -#[test] -fn bindgen_test_layout___darwin_arm_debug_state32() { - assert_eq!( - ::std::mem::size_of::<__darwin_arm_debug_state32>(), - 264usize, - concat!("Size of: ", stringify!(__darwin_arm_debug_state32)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_arm_debug_state32>(), - 8usize, - concat!("Alignment of ", stringify!(__darwin_arm_debug_state32)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_arm_debug_state32>())).__bvr as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_debug_state32), - "::", - stringify!(__bvr) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_arm_debug_state32>())).__bcr as *const _ as usize - }, - 64usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_debug_state32), - "::", - stringify!(__bcr) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_arm_debug_state32>())).__wvr as *const _ as usize - }, - 128usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_debug_state32), - "::", - stringify!(__wvr) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_arm_debug_state32>())).__wcr as *const _ as usize - }, - 192usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_debug_state32), - "::", - stringify!(__wcr) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_arm_debug_state32>())).__mdscr_el1 as *const _ as usize - }, - 256usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_debug_state32), - "::", - stringify!(__mdscr_el1) - ) - ); +extern "C" { + pub fn setstate_r( + __statebuf: *mut ::std::os::raw::c_char, + __buf: *mut random_data, + ) -> ::std::os::raw::c_int; } -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_arm_debug_state64 { - pub __bvr: [__uint64_t; 16usize], - pub __bcr: [__uint64_t; 16usize], - pub __wvr: [__uint64_t; 16usize], - pub __wcr: [__uint64_t; 16usize], - pub __mdscr_el1: __uint64_t, +extern "C" { + pub fn rand() -> ::std::os::raw::c_int; } -#[test] -fn bindgen_test_layout___darwin_arm_debug_state64() { - assert_eq!( - ::std::mem::size_of::<__darwin_arm_debug_state64>(), - 520usize, - concat!("Size of: ", stringify!(__darwin_arm_debug_state64)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_arm_debug_state64>(), - 8usize, - concat!("Alignment of ", stringify!(__darwin_arm_debug_state64)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_arm_debug_state64>())).__bvr as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_debug_state64), - "::", - stringify!(__bvr) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_arm_debug_state64>())).__bcr as *const _ as usize - }, - 128usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_debug_state64), - "::", - stringify!(__bcr) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_arm_debug_state64>())).__wvr as *const _ as usize - }, - 256usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_debug_state64), - "::", - stringify!(__wvr) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_arm_debug_state64>())).__wcr as *const _ as usize - }, - 384usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_debug_state64), - "::", - stringify!(__wcr) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_arm_debug_state64>())).__mdscr_el1 as *const _ as usize - }, - 512usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_debug_state64), - "::", - stringify!(__mdscr_el1) - ) - ); +extern "C" { + pub fn srand(__seed: ::std::os::raw::c_uint); } -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_arm_cpmu_state64 { - pub __ctrs: [__uint64_t; 16usize], +extern "C" { + pub fn rand_r(__seed: *mut ::std::os::raw::c_uint) -> ::std::os::raw::c_int; } -#[test] -fn bindgen_test_layout___darwin_arm_cpmu_state64() { - assert_eq!( - ::std::mem::size_of::<__darwin_arm_cpmu_state64>(), - 128usize, - concat!("Size of: ", stringify!(__darwin_arm_cpmu_state64)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_arm_cpmu_state64>(), - 8usize, - concat!("Alignment of ", stringify!(__darwin_arm_cpmu_state64)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_arm_cpmu_state64>())).__ctrs as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_arm_cpmu_state64), - "::", - stringify!(__ctrs) - ) - ); +extern "C" { + pub fn drand48() -> f64; } -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_mcontext32 { - pub __es: __darwin_arm_exception_state, - pub __ss: __darwin_arm_thread_state, - pub __fs: __darwin_arm_vfp_state, +extern "C" { + pub fn erand48(__xsubi: *mut ::std::os::raw::c_ushort) -> f64; } -#[test] -fn bindgen_test_layout___darwin_mcontext32() { - assert_eq!( - ::std::mem::size_of::<__darwin_mcontext32>(), - 340usize, - concat!("Size of: ", stringify!(__darwin_mcontext32)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_mcontext32>(), - 4usize, - concat!("Alignment of ", stringify!(__darwin_mcontext32)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext32>())).__es as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext32), - "::", - stringify!(__es) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext32>())).__ss as *const _ as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext32), - "::", - stringify!(__ss) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext32>())).__fs as *const _ as usize }, - 80usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext32), - "::", - stringify!(__fs) - ) - ); +extern "C" { + pub fn lrand48() -> ::std::os::raw::c_long; } -#[repr(C)] -#[repr(align(16))] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_mcontext64 { - pub __es: __darwin_arm_exception_state64, - pub __ss: __darwin_arm_thread_state64, - pub __ns: __darwin_arm_neon_state64, +extern "C" { + pub fn nrand48(__xsubi: *mut ::std::os::raw::c_ushort) -> ::std::os::raw::c_long; } -#[test] -fn bindgen_test_layout___darwin_mcontext64() { - assert_eq!( - ::std::mem::size_of::<__darwin_mcontext64>(), - 816usize, - concat!("Size of: ", stringify!(__darwin_mcontext64)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_mcontext64>(), - 16usize, - concat!("Alignment of ", stringify!(__darwin_mcontext64)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext64>())).__es as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext64), - "::", - stringify!(__es) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext64>())).__ss as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext64), - "::", - stringify!(__ss) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext64>())).__ns as *const _ as usize }, - 288usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext64), - "::", - stringify!(__ns) - ) - ); +extern "C" { + pub fn mrand48() -> ::std::os::raw::c_long; +} +extern "C" { + pub fn jrand48(__xsubi: *mut ::std::os::raw::c_ushort) -> ::std::os::raw::c_long; +} +extern "C" { + pub fn srand48(__seedval: ::std::os::raw::c_long); +} +extern "C" { + pub fn seed48(__seed16v: *mut ::std::os::raw::c_ushort) -> *mut ::std::os::raw::c_ushort; +} +extern "C" { + pub fn lcong48(__param: *mut ::std::os::raw::c_ushort); } -pub type mcontext_t = *mut __darwin_mcontext64; -pub type pthread_attr_t = __darwin_pthread_attr_t; #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct __darwin_sigaltstack { - pub ss_sp: *mut ::std::os::raw::c_void, - pub ss_size: __darwin_size_t, - pub ss_flags: ::std::os::raw::c_int, +pub struct drand48_data { + pub __x: [::std::os::raw::c_ushort; 3usize], + pub __old_x: [::std::os::raw::c_ushort; 3usize], + pub __c: ::std::os::raw::c_ushort, + pub __init: ::std::os::raw::c_ushort, + pub __a: ::std::os::raw::c_ulonglong, } #[test] -fn bindgen_test_layout___darwin_sigaltstack() { +fn bindgen_test_layout_drand48_data() { assert_eq!( - ::std::mem::size_of::<__darwin_sigaltstack>(), + ::std::mem::size_of::(), 24usize, - concat!("Size of: ", stringify!(__darwin_sigaltstack)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_sigaltstack>(), - 8usize, - concat!("Alignment of ", stringify!(__darwin_sigaltstack)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_sigaltstack>())).ss_sp as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_sigaltstack), - "::", - stringify!(ss_sp) - ) + concat!("Size of: ", stringify!(drand48_data)) ); assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_sigaltstack>())).ss_size as *const _ as usize }, + ::std::mem::align_of::(), 8usize, - concat!( - "Offset of field: ", - stringify!(__darwin_sigaltstack), - "::", - stringify!(ss_size) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_sigaltstack>())).ss_flags as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_sigaltstack), - "::", - stringify!(ss_flags) - ) - ); + concat!("Alignment of ", stringify!(drand48_data)) + ); + fn test_field___x() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__x) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(drand48_data), + "::", + stringify!(__x) + ) + ); + } + test_field___x(); + fn test_field___old_x() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__old_x) as usize - ptr as usize + }, + 6usize, + concat!( + "Offset of field: ", + stringify!(drand48_data), + "::", + stringify!(__old_x) + ) + ); + } + test_field___old_x(); + fn test_field___c() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__c) as usize - ptr as usize + }, + 12usize, + concat!( + "Offset of field: ", + stringify!(drand48_data), + "::", + stringify!(__c) + ) + ); + } + test_field___c(); + fn test_field___init() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__init) as usize - ptr as usize + }, + 14usize, + concat!( + "Offset of field: ", + stringify!(drand48_data), + "::", + stringify!(__init) + ) + ); + } + test_field___init(); + fn test_field___a() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__a) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(drand48_data), + "::", + stringify!(__a) + ) + ); + } + test_field___a(); } -pub type stack_t = __darwin_sigaltstack; -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_ucontext { - pub uc_onstack: ::std::os::raw::c_int, - pub uc_sigmask: __darwin_sigset_t, - pub uc_stack: __darwin_sigaltstack, - pub uc_link: *mut __darwin_ucontext, - pub uc_mcsize: __darwin_size_t, - pub uc_mcontext: *mut __darwin_mcontext64, +extern "C" { + pub fn drand48_r(__buffer: *mut drand48_data, __result: *mut f64) -> ::std::os::raw::c_int; } -#[test] -fn bindgen_test_layout___darwin_ucontext() { - assert_eq!( - ::std::mem::size_of::<__darwin_ucontext>(), - 56usize, - concat!("Size of: ", stringify!(__darwin_ucontext)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_ucontext>(), - 8usize, - concat!("Alignment of ", stringify!(__darwin_ucontext)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_ucontext>())).uc_onstack as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_ucontext), - "::", - stringify!(uc_onstack) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_ucontext>())).uc_sigmask as *const _ as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(__darwin_ucontext), - "::", - stringify!(uc_sigmask) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_ucontext>())).uc_stack as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__darwin_ucontext), - "::", - stringify!(uc_stack) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_ucontext>())).uc_link as *const _ as usize }, - 32usize, - concat!( - "Offset of field: ", - stringify!(__darwin_ucontext), - "::", - stringify!(uc_link) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_ucontext>())).uc_mcsize as *const _ as usize }, - 40usize, - concat!( - "Offset of field: ", - stringify!(__darwin_ucontext), - "::", - stringify!(uc_mcsize) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_ucontext>())).uc_mcontext as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(__darwin_ucontext), - "::", - stringify!(uc_mcontext) - ) - ); +extern "C" { + pub fn erand48_r( + __xsubi: *mut ::std::os::raw::c_ushort, + __buffer: *mut drand48_data, + __result: *mut f64, + ) -> ::std::os::raw::c_int; } -pub type ucontext_t = __darwin_ucontext; -pub type sigset_t = __darwin_sigset_t; -pub type uid_t = __darwin_uid_t; -#[repr(C)] -#[derive(Copy, Clone)] -pub union sigval { - pub sival_int: ::std::os::raw::c_int, - pub sival_ptr: *mut ::std::os::raw::c_void, +extern "C" { + pub fn lrand48_r( + __buffer: *mut drand48_data, + __result: *mut ::std::os::raw::c_long, + ) -> ::std::os::raw::c_int; } -#[test] -fn bindgen_test_layout_sigval() { - assert_eq!( - ::std::mem::size_of::(), - 8usize, - concat!("Size of: ", stringify!(sigval)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(sigval)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).sival_int as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(sigval), - "::", - stringify!(sival_int) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).sival_ptr as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(sigval), - "::", - stringify!(sival_ptr) - ) - ); +extern "C" { + pub fn nrand48_r( + __xsubi: *mut ::std::os::raw::c_ushort, + __buffer: *mut drand48_data, + __result: *mut ::std::os::raw::c_long, + ) -> ::std::os::raw::c_int; } -#[repr(C)] -#[derive(Copy, Clone)] -pub struct sigevent { - pub sigev_notify: ::std::os::raw::c_int, - pub sigev_signo: ::std::os::raw::c_int, - pub sigev_value: sigval, - pub sigev_notify_function: ::std::option::Option, - pub sigev_notify_attributes: *mut pthread_attr_t, +extern "C" { + pub fn mrand48_r( + __buffer: *mut drand48_data, + __result: *mut ::std::os::raw::c_long, + ) -> ::std::os::raw::c_int; } -#[test] -fn bindgen_test_layout_sigevent() { - assert_eq!( - ::std::mem::size_of::(), - 32usize, - concat!("Size of: ", stringify!(sigevent)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(sigevent)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).sigev_notify as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(sigevent), - "::", - stringify!(sigev_notify) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).sigev_signo as *const _ as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(sigevent), - "::", - stringify!(sigev_signo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).sigev_value as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(sigevent), - "::", - stringify!(sigev_value) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).sigev_notify_function as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(sigevent), - "::", - stringify!(sigev_notify_function) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).sigev_notify_attributes as *const _ as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(sigevent), - "::", - stringify!(sigev_notify_attributes) - ) - ); +extern "C" { + pub fn jrand48_r( + __xsubi: *mut ::std::os::raw::c_ushort, + __buffer: *mut drand48_data, + __result: *mut ::std::os::raw::c_long, + ) -> ::std::os::raw::c_int; } -#[repr(C)] -#[derive(Copy, Clone)] -pub struct __siginfo { - pub si_signo: ::std::os::raw::c_int, - pub si_errno: ::std::os::raw::c_int, - pub si_code: ::std::os::raw::c_int, - pub si_pid: pid_t, - pub si_uid: uid_t, - pub si_status: ::std::os::raw::c_int, - pub si_addr: *mut ::std::os::raw::c_void, - pub si_value: sigval, - pub si_band: ::std::os::raw::c_long, - pub __pad: [::std::os::raw::c_ulong; 7usize], +extern "C" { + pub fn srand48_r( + __seedval: ::std::os::raw::c_long, + __buffer: *mut drand48_data, + ) -> ::std::os::raw::c_int; } -#[test] -fn bindgen_test_layout___siginfo() { - assert_eq!( - ::std::mem::size_of::<__siginfo>(), - 104usize, - concat!("Size of: ", stringify!(__siginfo)) - ); - assert_eq!( - ::std::mem::align_of::<__siginfo>(), - 8usize, - concat!("Alignment of ", stringify!(__siginfo)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__siginfo>())).si_signo as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__siginfo), - "::", - stringify!(si_signo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__siginfo>())).si_errno as *const _ as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(__siginfo), - "::", - stringify!(si_errno) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__siginfo>())).si_code as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__siginfo), - "::", - stringify!(si_code) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__siginfo>())).si_pid as *const _ as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(__siginfo), - "::", - stringify!(si_pid) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__siginfo>())).si_uid as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__siginfo), - "::", - stringify!(si_uid) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__siginfo>())).si_status as *const _ as usize }, - 20usize, - concat!( - "Offset of field: ", - stringify!(__siginfo), - "::", - stringify!(si_status) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__siginfo>())).si_addr as *const _ as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(__siginfo), - "::", - stringify!(si_addr) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__siginfo>())).si_value as *const _ as usize }, - 32usize, - concat!( - "Offset of field: ", - stringify!(__siginfo), - "::", - stringify!(si_value) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__siginfo>())).si_band as *const _ as usize }, - 40usize, - concat!( - "Offset of field: ", - stringify!(__siginfo), - "::", - stringify!(si_band) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__siginfo>())).__pad as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(__siginfo), - "::", - stringify!(__pad) - ) - ); +extern "C" { + pub fn seed48_r( + __seed16v: *mut ::std::os::raw::c_ushort, + __buffer: *mut drand48_data, + ) -> ::std::os::raw::c_int; } -pub type siginfo_t = __siginfo; -#[repr(C)] -#[derive(Copy, Clone)] -pub union __sigaction_u { - pub __sa_handler: ::std::option::Option, - pub __sa_sigaction: ::std::option::Option< - unsafe extern "C" fn( - arg1: ::std::os::raw::c_int, - arg2: *mut __siginfo, - arg3: *mut ::std::os::raw::c_void, - ), - >, +extern "C" { + pub fn lcong48_r( + __param: *mut ::std::os::raw::c_ushort, + __buffer: *mut drand48_data, + ) -> ::std::os::raw::c_int; } -#[test] -fn bindgen_test_layout___sigaction_u() { - assert_eq!( - ::std::mem::size_of::<__sigaction_u>(), - 8usize, - concat!("Size of: ", stringify!(__sigaction_u)) - ); - assert_eq!( - ::std::mem::align_of::<__sigaction_u>(), - 8usize, - concat!("Alignment of ", stringify!(__sigaction_u)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__sigaction_u>())).__sa_handler as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__sigaction_u), - "::", - stringify!(__sa_handler) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__sigaction_u>())).__sa_sigaction as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__sigaction_u), - "::", - stringify!(__sa_sigaction) - ) - ); +extern "C" { + pub fn malloc(__size: ::std::os::raw::c_ulong) -> *mut ::std::os::raw::c_void; } -#[repr(C)] -#[derive(Copy, Clone)] -pub struct __sigaction { - pub __sigaction_u: __sigaction_u, - pub sa_tramp: ::std::option::Option< - unsafe extern "C" fn( - arg1: *mut ::std::os::raw::c_void, - arg2: ::std::os::raw::c_int, - arg3: ::std::os::raw::c_int, - arg4: *mut siginfo_t, - arg5: *mut ::std::os::raw::c_void, - ), - >, - pub sa_mask: sigset_t, - pub sa_flags: ::std::os::raw::c_int, +extern "C" { + pub fn calloc( + __nmemb: ::std::os::raw::c_ulong, + __size: ::std::os::raw::c_ulong, + ) -> *mut ::std::os::raw::c_void; } -#[test] -fn bindgen_test_layout___sigaction() { - assert_eq!( - ::std::mem::size_of::<__sigaction>(), - 24usize, - concat!("Size of: ", stringify!(__sigaction)) - ); - assert_eq!( - ::std::mem::align_of::<__sigaction>(), - 8usize, - concat!("Alignment of ", stringify!(__sigaction)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__sigaction>())).__sigaction_u as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__sigaction), - "::", - stringify!(__sigaction_u) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__sigaction>())).sa_tramp as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__sigaction), - "::", - stringify!(sa_tramp) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__sigaction>())).sa_mask as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__sigaction), - "::", - stringify!(sa_mask) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__sigaction>())).sa_flags as *const _ as usize }, - 20usize, - concat!( - "Offset of field: ", - stringify!(__sigaction), - "::", - stringify!(sa_flags) - ) - ); +extern "C" { + pub fn realloc( + __ptr: *mut ::std::os::raw::c_void, + __size: ::std::os::raw::c_ulong, + ) -> *mut ::std::os::raw::c_void; } -#[repr(C)] -#[derive(Copy, Clone)] -pub struct sigaction { - pub __sigaction_u: __sigaction_u, - pub sa_mask: sigset_t, - pub sa_flags: ::std::os::raw::c_int, +extern "C" { + pub fn reallocarray( + __ptr: *mut ::std::os::raw::c_void, + __nmemb: usize, + __size: usize, + ) -> *mut ::std::os::raw::c_void; } -#[test] -fn bindgen_test_layout_sigaction() { - assert_eq!( - ::std::mem::size_of::(), - 16usize, - concat!("Size of: ", stringify!(sigaction)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(sigaction)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).__sigaction_u as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(sigaction), - "::", - stringify!(__sigaction_u) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).sa_mask as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(sigaction), - "::", - stringify!(sa_mask) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).sa_flags as *const _ as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(sigaction), - "::", - stringify!(sa_flags) - ) - ); +extern "C" { + pub fn free(__ptr: *mut ::std::os::raw::c_void); } -pub type sig_t = ::std::option::Option; -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct sigvec { - pub sv_handler: ::std::option::Option, - pub sv_mask: ::std::os::raw::c_int, - pub sv_flags: ::std::os::raw::c_int, +extern "C" { + pub fn alloca(__size: ::std::os::raw::c_ulong) -> *mut ::std::os::raw::c_void; } -#[test] -fn bindgen_test_layout_sigvec() { - assert_eq!( - ::std::mem::size_of::(), - 16usize, - concat!("Size of: ", stringify!(sigvec)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(sigvec)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).sv_handler as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(sigvec), - "::", - stringify!(sv_handler) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).sv_mask as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(sigvec), - "::", - stringify!(sv_mask) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).sv_flags as *const _ as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(sigvec), - "::", - stringify!(sv_flags) - ) - ); +extern "C" { + pub fn valloc(__size: usize) -> *mut ::std::os::raw::c_void; } -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct sigstack { - pub ss_sp: *mut ::std::os::raw::c_char, - pub ss_onstack: ::std::os::raw::c_int, +extern "C" { + pub fn posix_memalign( + __memptr: *mut *mut ::std::os::raw::c_void, + __alignment: usize, + __size: usize, + ) -> ::std::os::raw::c_int; } -#[test] -fn bindgen_test_layout_sigstack() { - assert_eq!( - ::std::mem::size_of::(), - 16usize, - concat!("Size of: ", stringify!(sigstack)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(sigstack)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ss_sp as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(sigstack), - "::", - stringify!(ss_sp) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ss_onstack as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(sigstack), - "::", - stringify!(ss_onstack) - ) - ); +extern "C" { + pub fn aligned_alloc(__alignment: usize, __size: usize) -> *mut ::std::os::raw::c_void; } extern "C" { - pub fn signal( - arg1: ::std::os::raw::c_int, - arg2: ::std::option::Option, - ) -> ::std::option::Option< - unsafe extern "C" fn( - arg1: ::std::os::raw::c_int, - arg2: ::std::option::Option, - ), - >; -} -pub type int_least8_t = i8; -pub type int_least16_t = i16; -pub type int_least32_t = i32; -pub type int_least64_t = i64; -pub type uint_least8_t = u8; -pub type uint_least16_t = u16; -pub type uint_least32_t = u32; -pub type uint_least64_t = u64; -pub type int_fast8_t = i8; -pub type int_fast16_t = i16; -pub type int_fast32_t = i32; -pub type int_fast64_t = i64; -pub type uint_fast8_t = u8; -pub type uint_fast16_t = u16; -pub type uint_fast32_t = u32; -pub type uint_fast64_t = u64; -pub type intmax_t = ::std::os::raw::c_long; -pub type uintmax_t = ::std::os::raw::c_ulong; -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct timeval { - pub tv_sec: __darwin_time_t, - pub tv_usec: __darwin_suseconds_t, + pub fn abort(); } -#[test] -fn bindgen_test_layout_timeval() { - assert_eq!( - ::std::mem::size_of::(), - 16usize, - concat!("Size of: ", stringify!(timeval)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(timeval)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).tv_sec as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(timeval), - "::", - stringify!(tv_sec) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).tv_usec as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(timeval), - "::", - stringify!(tv_usec) - ) - ); +extern "C" { + pub fn atexit(__func: ::std::option::Option) -> ::std::os::raw::c_int; } -pub type rlim_t = __uint64_t; -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct rusage { - pub ru_utime: timeval, - pub ru_stime: timeval, - pub ru_maxrss: ::std::os::raw::c_long, - pub ru_ixrss: ::std::os::raw::c_long, - pub ru_idrss: ::std::os::raw::c_long, - pub ru_isrss: ::std::os::raw::c_long, - pub ru_minflt: ::std::os::raw::c_long, - pub ru_majflt: ::std::os::raw::c_long, - pub ru_nswap: ::std::os::raw::c_long, - pub ru_inblock: ::std::os::raw::c_long, - pub ru_oublock: ::std::os::raw::c_long, - pub ru_msgsnd: ::std::os::raw::c_long, - pub ru_msgrcv: ::std::os::raw::c_long, - pub ru_nsignals: ::std::os::raw::c_long, - pub ru_nvcsw: ::std::os::raw::c_long, - pub ru_nivcsw: ::std::os::raw::c_long, +extern "C" { + pub fn at_quick_exit( + __func: ::std::option::Option, + ) -> ::std::os::raw::c_int; } -#[test] -fn bindgen_test_layout_rusage() { - assert_eq!( - ::std::mem::size_of::(), - 144usize, - concat!("Size of: ", stringify!(rusage)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(rusage)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_utime as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_utime) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_stime as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_stime) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_maxrss as *const _ as usize }, - 32usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_maxrss) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_ixrss as *const _ as usize }, - 40usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_ixrss) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_idrss as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_idrss) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_isrss as *const _ as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_isrss) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_minflt as *const _ as usize }, - 64usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_minflt) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_majflt as *const _ as usize }, - 72usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_majflt) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_nswap as *const _ as usize }, - 80usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_nswap) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_inblock as *const _ as usize }, - 88usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_inblock) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_oublock as *const _ as usize }, - 96usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_oublock) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_msgsnd as *const _ as usize }, - 104usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_msgsnd) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_msgrcv as *const _ as usize }, - 112usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_msgrcv) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_nsignals as *const _ as usize }, - 120usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_nsignals) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_nvcsw as *const _ as usize }, - 128usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_nvcsw) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_nivcsw as *const _ as usize }, - 136usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_nivcsw) - ) - ); +extern "C" { + pub fn on_exit( + __func: ::std::option::Option< + unsafe extern "C" fn( + __status: ::std::os::raw::c_int, + __arg: *mut ::std::os::raw::c_void, + ), + >, + __arg: *mut ::std::os::raw::c_void, + ) -> ::std::os::raw::c_int; } -pub type rusage_info_t = *mut ::std::os::raw::c_void; -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct rusage_info_v0 { - pub ri_uuid: [u8; 16usize], - pub ri_user_time: u64, - pub ri_system_time: u64, - pub ri_pkg_idle_wkups: u64, - pub ri_interrupt_wkups: u64, - pub ri_pageins: u64, - pub ri_wired_size: u64, - pub ri_resident_size: u64, - pub ri_phys_footprint: u64, - pub ri_proc_start_abstime: u64, - pub ri_proc_exit_abstime: u64, +extern "C" { + pub fn exit(__status: ::std::os::raw::c_int); } -#[test] -fn bindgen_test_layout_rusage_info_v0() { - assert_eq!( - ::std::mem::size_of::(), - 96usize, - concat!("Size of: ", stringify!(rusage_info_v0)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(rusage_info_v0)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_uuid as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v0), - "::", - stringify!(ri_uuid) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_user_time as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v0), - "::", - stringify!(ri_user_time) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_system_time as *const _ as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v0), - "::", - stringify!(ri_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_pkg_idle_wkups as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v0), - "::", - stringify!(ri_pkg_idle_wkups) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_interrupt_wkups as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v0), - "::", - stringify!(ri_interrupt_wkups) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_pageins as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v0), - "::", - stringify!(ri_pageins) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_wired_size as *const _ as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v0), - "::", - stringify!(ri_wired_size) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_resident_size as *const _ as usize }, - 64usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v0), - "::", - stringify!(ri_resident_size) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_phys_footprint as *const _ as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v0), - "::", - stringify!(ri_phys_footprint) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_start_abstime as *const _ as usize - }, - 80usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v0), - "::", - stringify!(ri_proc_start_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_exit_abstime as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v0), - "::", - stringify!(ri_proc_exit_abstime) - ) - ); +extern "C" { + pub fn quick_exit(__status: ::std::os::raw::c_int); } -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct rusage_info_v1 { - pub ri_uuid: [u8; 16usize], - pub ri_user_time: u64, - pub ri_system_time: u64, - pub ri_pkg_idle_wkups: u64, - pub ri_interrupt_wkups: u64, - pub ri_pageins: u64, - pub ri_wired_size: u64, - pub ri_resident_size: u64, - pub ri_phys_footprint: u64, - pub ri_proc_start_abstime: u64, - pub ri_proc_exit_abstime: u64, - pub ri_child_user_time: u64, - pub ri_child_system_time: u64, - pub ri_child_pkg_idle_wkups: u64, - pub ri_child_interrupt_wkups: u64, - pub ri_child_pageins: u64, - pub ri_child_elapsed_abstime: u64, +extern "C" { + pub fn _Exit(__status: ::std::os::raw::c_int); } -#[test] -fn bindgen_test_layout_rusage_info_v1() { - assert_eq!( - ::std::mem::size_of::(), - 144usize, - concat!("Size of: ", stringify!(rusage_info_v1)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(rusage_info_v1)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_uuid as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_uuid) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_user_time as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_user_time) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_system_time as *const _ as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_pkg_idle_wkups as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_pkg_idle_wkups) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_interrupt_wkups as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_interrupt_wkups) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_pageins as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_pageins) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_wired_size as *const _ as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_wired_size) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_resident_size as *const _ as usize }, - 64usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_resident_size) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_phys_footprint as *const _ as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_phys_footprint) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_start_abstime as *const _ as usize - }, - 80usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_proc_start_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_exit_abstime as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_proc_exit_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_user_time as *const _ as usize - }, - 96usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_child_user_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_system_time as *const _ as usize - }, - 104usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_child_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_pkg_idle_wkups as *const _ as usize - }, - 112usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_child_pkg_idle_wkups) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_interrupt_wkups as *const _ as usize - }, - 120usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_child_interrupt_wkups) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_child_pageins as *const _ as usize }, - 128usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_child_pageins) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_elapsed_abstime as *const _ as usize - }, - 136usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_child_elapsed_abstime) - ) - ); +extern "C" { + pub fn getenv(__name: *const ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; } -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct rusage_info_v2 { - pub ri_uuid: [u8; 16usize], - pub ri_user_time: u64, - pub ri_system_time: u64, - pub ri_pkg_idle_wkups: u64, - pub ri_interrupt_wkups: u64, - pub ri_pageins: u64, - pub ri_wired_size: u64, - pub ri_resident_size: u64, - pub ri_phys_footprint: u64, - pub ri_proc_start_abstime: u64, - pub ri_proc_exit_abstime: u64, - pub ri_child_user_time: u64, - pub ri_child_system_time: u64, - pub ri_child_pkg_idle_wkups: u64, - pub ri_child_interrupt_wkups: u64, - pub ri_child_pageins: u64, - pub ri_child_elapsed_abstime: u64, - pub ri_diskio_bytesread: u64, - pub ri_diskio_byteswritten: u64, +extern "C" { + pub fn putenv(__string: *mut ::std::os::raw::c_char) -> ::std::os::raw::c_int; } -#[test] -fn bindgen_test_layout_rusage_info_v2() { - assert_eq!( - ::std::mem::size_of::(), - 160usize, - concat!("Size of: ", stringify!(rusage_info_v2)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(rusage_info_v2)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_uuid as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_uuid) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_user_time as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_user_time) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_system_time as *const _ as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_pkg_idle_wkups as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_pkg_idle_wkups) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_interrupt_wkups as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_interrupt_wkups) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_pageins as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_pageins) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_wired_size as *const _ as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_wired_size) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_resident_size as *const _ as usize }, - 64usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_resident_size) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_phys_footprint as *const _ as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_phys_footprint) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_start_abstime as *const _ as usize - }, - 80usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_proc_start_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_exit_abstime as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_proc_exit_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_user_time as *const _ as usize - }, - 96usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_child_user_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_system_time as *const _ as usize - }, - 104usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_child_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_pkg_idle_wkups as *const _ as usize - }, - 112usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_child_pkg_idle_wkups) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_interrupt_wkups as *const _ as usize - }, - 120usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_child_interrupt_wkups) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_child_pageins as *const _ as usize }, - 128usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_child_pageins) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_elapsed_abstime as *const _ as usize - }, - 136usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_child_elapsed_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_diskio_bytesread as *const _ as usize - }, - 144usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_diskio_bytesread) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_diskio_byteswritten as *const _ as usize - }, - 152usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_diskio_byteswritten) - ) - ); +extern "C" { + pub fn setenv( + __name: *const ::std::os::raw::c_char, + __value: *const ::std::os::raw::c_char, + __replace: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int; } -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct rusage_info_v3 { - pub ri_uuid: [u8; 16usize], - pub ri_user_time: u64, - pub ri_system_time: u64, - pub ri_pkg_idle_wkups: u64, - pub ri_interrupt_wkups: u64, - pub ri_pageins: u64, - pub ri_wired_size: u64, - pub ri_resident_size: u64, - pub ri_phys_footprint: u64, - pub ri_proc_start_abstime: u64, - pub ri_proc_exit_abstime: u64, - pub ri_child_user_time: u64, - pub ri_child_system_time: u64, - pub ri_child_pkg_idle_wkups: u64, - pub ri_child_interrupt_wkups: u64, - pub ri_child_pageins: u64, - pub ri_child_elapsed_abstime: u64, - pub ri_diskio_bytesread: u64, - pub ri_diskio_byteswritten: u64, - pub ri_cpu_time_qos_default: u64, - pub ri_cpu_time_qos_maintenance: u64, - pub ri_cpu_time_qos_background: u64, - pub ri_cpu_time_qos_utility: u64, - pub ri_cpu_time_qos_legacy: u64, - pub ri_cpu_time_qos_user_initiated: u64, - pub ri_cpu_time_qos_user_interactive: u64, - pub ri_billed_system_time: u64, - pub ri_serviced_system_time: u64, +extern "C" { + pub fn unsetenv(__name: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int; } -#[test] -fn bindgen_test_layout_rusage_info_v3() { - assert_eq!( - ::std::mem::size_of::(), - 232usize, - concat!("Size of: ", stringify!(rusage_info_v3)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(rusage_info_v3)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_uuid as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_uuid) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_user_time as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_user_time) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_system_time as *const _ as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_pkg_idle_wkups as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_pkg_idle_wkups) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_interrupt_wkups as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_interrupt_wkups) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_pageins as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_pageins) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_wired_size as *const _ as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_wired_size) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_resident_size as *const _ as usize }, - 64usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_resident_size) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_phys_footprint as *const _ as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_phys_footprint) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_start_abstime as *const _ as usize - }, - 80usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_proc_start_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_exit_abstime as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_proc_exit_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_user_time as *const _ as usize - }, - 96usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_child_user_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_system_time as *const _ as usize - }, - 104usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_child_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_pkg_idle_wkups as *const _ as usize - }, - 112usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_child_pkg_idle_wkups) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_interrupt_wkups as *const _ as usize - }, - 120usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_child_interrupt_wkups) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_child_pageins as *const _ as usize }, - 128usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_child_pageins) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_elapsed_abstime as *const _ as usize - }, - 136usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_child_elapsed_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_diskio_bytesread as *const _ as usize - }, - 144usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_diskio_bytesread) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_diskio_byteswritten as *const _ as usize - }, - 152usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_diskio_byteswritten) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_default as *const _ as usize - }, - 160usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_cpu_time_qos_default) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_maintenance as *const _ - as usize - }, - 168usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_cpu_time_qos_maintenance) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_background as *const _ - as usize - }, - 176usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_cpu_time_qos_background) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_utility as *const _ as usize - }, - 184usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_cpu_time_qos_utility) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_legacy as *const _ as usize - }, - 192usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_cpu_time_qos_legacy) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_user_initiated as *const _ - as usize - }, - 200usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_cpu_time_qos_user_initiated) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_user_interactive as *const _ - as usize - }, - 208usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_cpu_time_qos_user_interactive) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_billed_system_time as *const _ as usize - }, - 216usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_billed_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_serviced_system_time as *const _ as usize - }, - 224usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_serviced_system_time) - ) +extern "C" { + pub fn clearenv() -> ::std::os::raw::c_int; +} +extern "C" { + pub fn mktemp(__template: *mut ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn mkstemp(__template: *mut ::std::os::raw::c_char) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn mkstemps( + __template: *mut ::std::os::raw::c_char, + __suffixlen: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn mkdtemp(__template: *mut ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn system(__command: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn realpath( + __name: *const ::std::os::raw::c_char, + __resolved: *mut ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; +} +pub type __compar_fn_t = ::std::option::Option< + unsafe extern "C" fn( + arg1: *const ::std::os::raw::c_void, + arg2: *const ::std::os::raw::c_void, + ) -> ::std::os::raw::c_int, +>; +extern "C" { + pub fn bsearch( + __key: *const ::std::os::raw::c_void, + __base: *const ::std::os::raw::c_void, + __nmemb: usize, + __size: usize, + __compar: __compar_fn_t, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn qsort( + __base: *mut ::std::os::raw::c_void, + __nmemb: usize, + __size: usize, + __compar: __compar_fn_t, ); } +extern "C" { + pub fn abs(__x: ::std::os::raw::c_int) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn labs(__x: ::std::os::raw::c_long) -> ::std::os::raw::c_long; +} +extern "C" { + pub fn llabs(__x: ::std::os::raw::c_longlong) -> ::std::os::raw::c_longlong; +} +extern "C" { + pub fn div(__numer: ::std::os::raw::c_int, __denom: ::std::os::raw::c_int) -> div_t; +} +extern "C" { + pub fn ldiv(__numer: ::std::os::raw::c_long, __denom: ::std::os::raw::c_long) -> ldiv_t; +} +extern "C" { + pub fn lldiv( + __numer: ::std::os::raw::c_longlong, + __denom: ::std::os::raw::c_longlong, + ) -> lldiv_t; +} +extern "C" { + pub fn ecvt( + __value: f64, + __ndigit: ::std::os::raw::c_int, + __decpt: *mut ::std::os::raw::c_int, + __sign: *mut ::std::os::raw::c_int, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn fcvt( + __value: f64, + __ndigit: ::std::os::raw::c_int, + __decpt: *mut ::std::os::raw::c_int, + __sign: *mut ::std::os::raw::c_int, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn gcvt( + __value: f64, + __ndigit: ::std::os::raw::c_int, + __buf: *mut ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn qecvt( + __value: f64, + __ndigit: ::std::os::raw::c_int, + __decpt: *mut ::std::os::raw::c_int, + __sign: *mut ::std::os::raw::c_int, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn qfcvt( + __value: f64, + __ndigit: ::std::os::raw::c_int, + __decpt: *mut ::std::os::raw::c_int, + __sign: *mut ::std::os::raw::c_int, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn qgcvt( + __value: f64, + __ndigit: ::std::os::raw::c_int, + __buf: *mut ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn ecvt_r( + __value: f64, + __ndigit: ::std::os::raw::c_int, + __decpt: *mut ::std::os::raw::c_int, + __sign: *mut ::std::os::raw::c_int, + __buf: *mut ::std::os::raw::c_char, + __len: usize, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn fcvt_r( + __value: f64, + __ndigit: ::std::os::raw::c_int, + __decpt: *mut ::std::os::raw::c_int, + __sign: *mut ::std::os::raw::c_int, + __buf: *mut ::std::os::raw::c_char, + __len: usize, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn qecvt_r( + __value: f64, + __ndigit: ::std::os::raw::c_int, + __decpt: *mut ::std::os::raw::c_int, + __sign: *mut ::std::os::raw::c_int, + __buf: *mut ::std::os::raw::c_char, + __len: usize, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn qfcvt_r( + __value: f64, + __ndigit: ::std::os::raw::c_int, + __decpt: *mut ::std::os::raw::c_int, + __sign: *mut ::std::os::raw::c_int, + __buf: *mut ::std::os::raw::c_char, + __len: usize, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn mblen(__s: *const ::std::os::raw::c_char, __n: usize) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn mbtowc( + __pwc: *mut wchar_t, + __s: *const ::std::os::raw::c_char, + __n: usize, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn wctomb(__s: *mut ::std::os::raw::c_char, __wchar: wchar_t) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn mbstowcs(__pwcs: *mut wchar_t, __s: *const ::std::os::raw::c_char, __n: usize) -> usize; +} +extern "C" { + pub fn wcstombs(__s: *mut ::std::os::raw::c_char, __pwcs: *const wchar_t, __n: usize) -> usize; +} +extern "C" { + pub fn rpmatch(__response: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn getsubopt( + __optionp: *mut *mut ::std::os::raw::c_char, + __tokens: *const *mut ::std::os::raw::c_char, + __valuep: *mut *mut ::std::os::raw::c_char, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn getloadavg(__loadavg: *mut f64, __nelem: ::std::os::raw::c_int) + -> ::std::os::raw::c_int; +} +pub type int_least8_t = __int_least8_t; +pub type int_least16_t = __int_least16_t; +pub type int_least32_t = __int_least32_t; +pub type int_least64_t = __int_least64_t; +pub type uint_least8_t = __uint_least8_t; +pub type uint_least16_t = __uint_least16_t; +pub type uint_least32_t = __uint_least32_t; +pub type uint_least64_t = __uint_least64_t; +pub type int_fast8_t = ::std::os::raw::c_schar; +pub type int_fast16_t = ::std::os::raw::c_int; +pub type int_fast32_t = ::std::os::raw::c_int; +pub type int_fast64_t = ::std::os::raw::c_longlong; +pub type uint_fast8_t = ::std::os::raw::c_uchar; +pub type uint_fast16_t = ::std::os::raw::c_uint; +pub type uint_fast32_t = ::std::os::raw::c_uint; +pub type uint_fast64_t = ::std::os::raw::c_ulonglong; +pub type intmax_t = __intmax_t; +pub type uintmax_t = __uintmax_t; +extern "C" { + pub fn memcpy( + __dest: *mut ::std::os::raw::c_void, + __src: *const ::std::os::raw::c_void, + __n: ::std::os::raw::c_ulong, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn memmove( + __dest: *mut ::std::os::raw::c_void, + __src: *const ::std::os::raw::c_void, + __n: ::std::os::raw::c_ulong, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn memccpy( + __dest: *mut ::std::os::raw::c_void, + __src: *const ::std::os::raw::c_void, + __c: ::std::os::raw::c_int, + __n: ::std::os::raw::c_ulong, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn memset( + __s: *mut ::std::os::raw::c_void, + __c: ::std::os::raw::c_int, + __n: ::std::os::raw::c_ulong, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn memcmp( + __s1: *const ::std::os::raw::c_void, + __s2: *const ::std::os::raw::c_void, + __n: ::std::os::raw::c_ulong, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn memchr( + __s: *const ::std::os::raw::c_void, + __c: ::std::os::raw::c_int, + __n: ::std::os::raw::c_ulong, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn strcpy( + __dest: *mut ::std::os::raw::c_char, + __src: *const ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn strncpy( + __dest: *mut ::std::os::raw::c_char, + __src: *const ::std::os::raw::c_char, + __n: ::std::os::raw::c_ulong, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn strcat( + __dest: *mut ::std::os::raw::c_char, + __src: *const ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn strncat( + __dest: *mut ::std::os::raw::c_char, + __src: *const ::std::os::raw::c_char, + __n: ::std::os::raw::c_ulong, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn strcmp( + __s1: *const ::std::os::raw::c_char, + __s2: *const ::std::os::raw::c_char, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn strncmp( + __s1: *const ::std::os::raw::c_char, + __s2: *const ::std::os::raw::c_char, + __n: ::std::os::raw::c_ulong, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn strcoll( + __s1: *const ::std::os::raw::c_char, + __s2: *const ::std::os::raw::c_char, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn strxfrm( + __dest: *mut ::std::os::raw::c_char, + __src: *const ::std::os::raw::c_char, + __n: ::std::os::raw::c_ulong, + ) -> ::std::os::raw::c_ulong; +} #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct rusage_info_v4 { - pub ri_uuid: [u8; 16usize], - pub ri_user_time: u64, - pub ri_system_time: u64, - pub ri_pkg_idle_wkups: u64, - pub ri_interrupt_wkups: u64, - pub ri_pageins: u64, - pub ri_wired_size: u64, - pub ri_resident_size: u64, - pub ri_phys_footprint: u64, - pub ri_proc_start_abstime: u64, - pub ri_proc_exit_abstime: u64, - pub ri_child_user_time: u64, - pub ri_child_system_time: u64, - pub ri_child_pkg_idle_wkups: u64, - pub ri_child_interrupt_wkups: u64, - pub ri_child_pageins: u64, - pub ri_child_elapsed_abstime: u64, - pub ri_diskio_bytesread: u64, - pub ri_diskio_byteswritten: u64, - pub ri_cpu_time_qos_default: u64, - pub ri_cpu_time_qos_maintenance: u64, - pub ri_cpu_time_qos_background: u64, - pub ri_cpu_time_qos_utility: u64, - pub ri_cpu_time_qos_legacy: u64, - pub ri_cpu_time_qos_user_initiated: u64, - pub ri_cpu_time_qos_user_interactive: u64, - pub ri_billed_system_time: u64, - pub ri_serviced_system_time: u64, - pub ri_logical_writes: u64, - pub ri_lifetime_max_phys_footprint: u64, - pub ri_instructions: u64, - pub ri_cycles: u64, - pub ri_billed_energy: u64, - pub ri_serviced_energy: u64, - pub ri_interval_max_phys_footprint: u64, - pub ri_runnable_time: u64, +pub struct __locale_struct { + pub __locales: [*mut __locale_data; 13usize], + pub __ctype_b: *const ::std::os::raw::c_ushort, + pub __ctype_tolower: *const ::std::os::raw::c_int, + pub __ctype_toupper: *const ::std::os::raw::c_int, + pub __names: [*const ::std::os::raw::c_char; 13usize], } #[test] -fn bindgen_test_layout_rusage_info_v4() { +fn bindgen_test_layout___locale_struct() { assert_eq!( - ::std::mem::size_of::(), - 296usize, - concat!("Size of: ", stringify!(rusage_info_v4)) + ::std::mem::size_of::<__locale_struct>(), + 232usize, + concat!("Size of: ", stringify!(__locale_struct)) ); assert_eq!( - ::std::mem::align_of::(), + ::std::mem::align_of::<__locale_struct>(), 8usize, - concat!("Alignment of ", stringify!(rusage_info_v4)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_uuid as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_uuid) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_user_time as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_user_time) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_system_time as *const _ as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_pkg_idle_wkups as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_pkg_idle_wkups) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_interrupt_wkups as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_interrupt_wkups) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_pageins as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_pageins) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_wired_size as *const _ as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_wired_size) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_resident_size as *const _ as usize }, - 64usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_resident_size) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_phys_footprint as *const _ as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_phys_footprint) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_start_abstime as *const _ as usize - }, - 80usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_proc_start_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_exit_abstime as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_proc_exit_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_user_time as *const _ as usize - }, - 96usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_child_user_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_system_time as *const _ as usize - }, - 104usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_child_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_pkg_idle_wkups as *const _ as usize - }, - 112usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_child_pkg_idle_wkups) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_interrupt_wkups as *const _ as usize - }, - 120usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_child_interrupt_wkups) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_child_pageins as *const _ as usize }, - 128usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_child_pageins) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_elapsed_abstime as *const _ as usize - }, - 136usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_child_elapsed_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_diskio_bytesread as *const _ as usize - }, - 144usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_diskio_bytesread) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_diskio_byteswritten as *const _ as usize - }, - 152usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_diskio_byteswritten) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_default as *const _ as usize - }, - 160usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_cpu_time_qos_default) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_maintenance as *const _ - as usize - }, - 168usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_cpu_time_qos_maintenance) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_background as *const _ - as usize - }, - 176usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_cpu_time_qos_background) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_utility as *const _ as usize - }, - 184usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_cpu_time_qos_utility) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_legacy as *const _ as usize - }, - 192usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_cpu_time_qos_legacy) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_user_initiated as *const _ - as usize - }, - 200usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_cpu_time_qos_user_initiated) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_user_interactive as *const _ - as usize - }, - 208usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_cpu_time_qos_user_interactive) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_billed_system_time as *const _ as usize - }, - 216usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_billed_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_serviced_system_time as *const _ as usize - }, - 224usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_serviced_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_logical_writes as *const _ as usize - }, - 232usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_logical_writes) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_lifetime_max_phys_footprint as *const _ - as usize - }, - 240usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_lifetime_max_phys_footprint) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_instructions as *const _ as usize }, - 248usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_instructions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_cycles as *const _ as usize }, - 256usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_cycles) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_billed_energy as *const _ as usize }, - 264usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_billed_energy) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_serviced_energy as *const _ as usize - }, - 272usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_serviced_energy) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_interval_max_phys_footprint as *const _ - as usize - }, - 280usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_interval_max_phys_footprint) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_runnable_time as *const _ as usize }, - 288usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_runnable_time) - ) - ); + concat!("Alignment of ", stringify!(__locale_struct)) + ); + fn test_field___locales() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__locale_struct>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__locales) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__locale_struct), + "::", + stringify!(__locales) + ) + ); + } + test_field___locales(); + fn test_field___ctype_b() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__locale_struct>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__ctype_b) as usize - ptr as usize + }, + 104usize, + concat!( + "Offset of field: ", + stringify!(__locale_struct), + "::", + stringify!(__ctype_b) + ) + ); + } + test_field___ctype_b(); + fn test_field___ctype_tolower() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__locale_struct>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__ctype_tolower) as usize - ptr as usize + }, + 112usize, + concat!( + "Offset of field: ", + stringify!(__locale_struct), + "::", + stringify!(__ctype_tolower) + ) + ); + } + test_field___ctype_tolower(); + fn test_field___ctype_toupper() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__locale_struct>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__ctype_toupper) as usize - ptr as usize + }, + 120usize, + concat!( + "Offset of field: ", + stringify!(__locale_struct), + "::", + stringify!(__ctype_toupper) + ) + ); + } + test_field___ctype_toupper(); + fn test_field___names() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__locale_struct>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__names) as usize - ptr as usize + }, + 128usize, + concat!( + "Offset of field: ", + stringify!(__locale_struct), + "::", + stringify!(__names) + ) + ); + } + test_field___names(); } -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct rusage_info_v5 { - pub ri_uuid: [u8; 16usize], - pub ri_user_time: u64, - pub ri_system_time: u64, - pub ri_pkg_idle_wkups: u64, - pub ri_interrupt_wkups: u64, - pub ri_pageins: u64, - pub ri_wired_size: u64, - pub ri_resident_size: u64, - pub ri_phys_footprint: u64, - pub ri_proc_start_abstime: u64, - pub ri_proc_exit_abstime: u64, - pub ri_child_user_time: u64, - pub ri_child_system_time: u64, - pub ri_child_pkg_idle_wkups: u64, - pub ri_child_interrupt_wkups: u64, - pub ri_child_pageins: u64, - pub ri_child_elapsed_abstime: u64, - pub ri_diskio_bytesread: u64, - pub ri_diskio_byteswritten: u64, - pub ri_cpu_time_qos_default: u64, - pub ri_cpu_time_qos_maintenance: u64, - pub ri_cpu_time_qos_background: u64, - pub ri_cpu_time_qos_utility: u64, - pub ri_cpu_time_qos_legacy: u64, - pub ri_cpu_time_qos_user_initiated: u64, - pub ri_cpu_time_qos_user_interactive: u64, - pub ri_billed_system_time: u64, - pub ri_serviced_system_time: u64, - pub ri_logical_writes: u64, - pub ri_lifetime_max_phys_footprint: u64, - pub ri_instructions: u64, - pub ri_cycles: u64, - pub ri_billed_energy: u64, - pub ri_serviced_energy: u64, - pub ri_interval_max_phys_footprint: u64, - pub ri_runnable_time: u64, - pub ri_flags: u64, +pub type __locale_t = *mut __locale_struct; +pub type locale_t = __locale_t; +extern "C" { + pub fn strcoll_l( + __s1: *const ::std::os::raw::c_char, + __s2: *const ::std::os::raw::c_char, + __l: locale_t, + ) -> ::std::os::raw::c_int; } -#[test] -fn bindgen_test_layout_rusage_info_v5() { - assert_eq!( - ::std::mem::size_of::(), - 304usize, - concat!("Size of: ", stringify!(rusage_info_v5)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(rusage_info_v5)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_uuid as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_uuid) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_user_time as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_user_time) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_system_time as *const _ as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_pkg_idle_wkups as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_pkg_idle_wkups) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_interrupt_wkups as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_interrupt_wkups) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_pageins as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_pageins) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_wired_size as *const _ as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_wired_size) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_resident_size as *const _ as usize }, - 64usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_resident_size) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_phys_footprint as *const _ as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_phys_footprint) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_start_abstime as *const _ as usize - }, - 80usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_proc_start_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_exit_abstime as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_proc_exit_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_user_time as *const _ as usize - }, - 96usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_child_user_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_system_time as *const _ as usize - }, - 104usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_child_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_pkg_idle_wkups as *const _ as usize - }, - 112usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_child_pkg_idle_wkups) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_interrupt_wkups as *const _ as usize - }, - 120usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_child_interrupt_wkups) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_child_pageins as *const _ as usize }, - 128usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_child_pageins) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_elapsed_abstime as *const _ as usize - }, - 136usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_child_elapsed_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_diskio_bytesread as *const _ as usize - }, - 144usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_diskio_bytesread) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_diskio_byteswritten as *const _ as usize - }, - 152usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_diskio_byteswritten) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_default as *const _ as usize - }, - 160usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_cpu_time_qos_default) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_maintenance as *const _ - as usize - }, - 168usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_cpu_time_qos_maintenance) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_background as *const _ - as usize - }, - 176usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_cpu_time_qos_background) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_utility as *const _ as usize - }, - 184usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_cpu_time_qos_utility) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_legacy as *const _ as usize - }, - 192usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_cpu_time_qos_legacy) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_user_initiated as *const _ - as usize - }, - 200usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_cpu_time_qos_user_initiated) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_user_interactive as *const _ - as usize - }, - 208usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_cpu_time_qos_user_interactive) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_billed_system_time as *const _ as usize - }, - 216usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_billed_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_serviced_system_time as *const _ as usize - }, - 224usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_serviced_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_logical_writes as *const _ as usize - }, - 232usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_logical_writes) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_lifetime_max_phys_footprint as *const _ - as usize - }, - 240usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_lifetime_max_phys_footprint) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_instructions as *const _ as usize }, - 248usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_instructions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_cycles as *const _ as usize }, - 256usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_cycles) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_billed_energy as *const _ as usize }, - 264usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_billed_energy) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_serviced_energy as *const _ as usize - }, - 272usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_serviced_energy) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_interval_max_phys_footprint as *const _ - as usize - }, - 280usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_interval_max_phys_footprint) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_runnable_time as *const _ as usize }, - 288usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_runnable_time) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_flags as *const _ as usize }, - 296usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_flags) - ) - ); -} -pub type rusage_info_current = rusage_info_v5; -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct rlimit { - pub rlim_cur: rlim_t, - pub rlim_max: rlim_t, -} -#[test] -fn bindgen_test_layout_rlimit() { - assert_eq!( - ::std::mem::size_of::(), - 16usize, - concat!("Size of: ", stringify!(rlimit)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(rlimit)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).rlim_cur as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(rlimit), - "::", - stringify!(rlim_cur) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).rlim_max as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(rlimit), - "::", - stringify!(rlim_max) - ) +extern "C" { + pub fn strxfrm_l( + __dest: *mut ::std::os::raw::c_char, + __src: *const ::std::os::raw::c_char, + __n: usize, + __l: locale_t, + ) -> usize; +} +extern "C" { + pub fn strdup(__s: *const ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn strndup( + __string: *const ::std::os::raw::c_char, + __n: ::std::os::raw::c_ulong, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn strchr( + __s: *const ::std::os::raw::c_char, + __c: ::std::os::raw::c_int, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn strrchr( + __s: *const ::std::os::raw::c_char, + __c: ::std::os::raw::c_int, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn strcspn( + __s: *const ::std::os::raw::c_char, + __reject: *const ::std::os::raw::c_char, + ) -> ::std::os::raw::c_ulong; +} +extern "C" { + pub fn strspn( + __s: *const ::std::os::raw::c_char, + __accept: *const ::std::os::raw::c_char, + ) -> ::std::os::raw::c_ulong; +} +extern "C" { + pub fn strpbrk( + __s: *const ::std::os::raw::c_char, + __accept: *const ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn strstr( + __haystack: *const ::std::os::raw::c_char, + __needle: *const ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn strtok( + __s: *mut ::std::os::raw::c_char, + __delim: *const ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn __strtok_r( + __s: *mut ::std::os::raw::c_char, + __delim: *const ::std::os::raw::c_char, + __save_ptr: *mut *mut ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn strtok_r( + __s: *mut ::std::os::raw::c_char, + __delim: *const ::std::os::raw::c_char, + __save_ptr: *mut *mut ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn strlen(__s: *const ::std::os::raw::c_char) -> ::std::os::raw::c_ulong; +} +extern "C" { + pub fn strnlen(__string: *const ::std::os::raw::c_char, __maxlen: usize) -> usize; +} +extern "C" { + pub fn strerror(__errnum: ::std::os::raw::c_int) -> *mut ::std::os::raw::c_char; +} +extern "C" { + #[link_name = "\u{1}___xpg_strerror_r"] + pub fn strerror_r( + __errnum: ::std::os::raw::c_int, + __buf: *mut ::std::os::raw::c_char, + __buflen: usize, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn strerror_l( + __errnum: ::std::os::raw::c_int, + __l: locale_t, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn bcmp( + __s1: *const ::std::os::raw::c_void, + __s2: *const ::std::os::raw::c_void, + __n: ::std::os::raw::c_ulong, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn bcopy( + __src: *const ::std::os::raw::c_void, + __dest: *mut ::std::os::raw::c_void, + __n: usize, ); } -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct proc_rlimit_control_wakeupmon { - pub wm_flags: u32, - pub wm_rate: i32, +extern "C" { + pub fn bzero(__s: *mut ::std::os::raw::c_void, __n: ::std::os::raw::c_ulong); } -#[test] -fn bindgen_test_layout_proc_rlimit_control_wakeupmon() { - assert_eq!( - ::std::mem::size_of::(), - 8usize, - concat!("Size of: ", stringify!(proc_rlimit_control_wakeupmon)) - ); - assert_eq!( - ::std::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(proc_rlimit_control_wakeupmon)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).wm_flags as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(proc_rlimit_control_wakeupmon), - "::", - stringify!(wm_flags) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).wm_rate as *const _ as usize - }, - 4usize, - concat!( - "Offset of field: ", - stringify!(proc_rlimit_control_wakeupmon), - "::", - stringify!(wm_rate) - ) - ); +extern "C" { + pub fn index( + __s: *const ::std::os::raw::c_char, + __c: ::std::os::raw::c_int, + ) -> *mut ::std::os::raw::c_char; } extern "C" { - pub fn getpriority(arg1: ::std::os::raw::c_int, arg2: id_t) -> ::std::os::raw::c_int; + pub fn rindex( + __s: *const ::std::os::raw::c_char, + __c: ::std::os::raw::c_int, + ) -> *mut ::std::os::raw::c_char; } extern "C" { - pub fn getiopolicy_np( - arg1: ::std::os::raw::c_int, - arg2: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; + pub fn ffs(__i: ::std::os::raw::c_int) -> ::std::os::raw::c_int; } extern "C" { - pub fn getrlimit(arg1: ::std::os::raw::c_int, arg2: *mut rlimit) -> ::std::os::raw::c_int; + pub fn ffsl(__l: ::std::os::raw::c_long) -> ::std::os::raw::c_int; } extern "C" { - pub fn getrusage(arg1: ::std::os::raw::c_int, arg2: *mut rusage) -> ::std::os::raw::c_int; + pub fn ffsll(__ll: ::std::os::raw::c_longlong) -> ::std::os::raw::c_int; } extern "C" { - pub fn setpriority( - arg1: ::std::os::raw::c_int, - arg2: id_t, - arg3: ::std::os::raw::c_int, + pub fn strcasecmp( + __s1: *const ::std::os::raw::c_char, + __s2: *const ::std::os::raw::c_char, ) -> ::std::os::raw::c_int; } extern "C" { - pub fn setiopolicy_np( - arg1: ::std::os::raw::c_int, - arg2: ::std::os::raw::c_int, - arg3: ::std::os::raw::c_int, + pub fn strncasecmp( + __s1: *const ::std::os::raw::c_char, + __s2: *const ::std::os::raw::c_char, + __n: ::std::os::raw::c_ulong, ) -> ::std::os::raw::c_int; } extern "C" { - pub fn setrlimit(arg1: ::std::os::raw::c_int, arg2: *const rlimit) -> ::std::os::raw::c_int; + pub fn strcasecmp_l( + __s1: *const ::std::os::raw::c_char, + __s2: *const ::std::os::raw::c_char, + __loc: locale_t, + ) -> ::std::os::raw::c_int; } -#[repr(C, packed)] -#[derive(Debug, Copy, Clone)] -pub struct _OSUnalignedU16 { - pub __val: u16, +extern "C" { + pub fn strncasecmp_l( + __s1: *const ::std::os::raw::c_char, + __s2: *const ::std::os::raw::c_char, + __n: usize, + __loc: locale_t, + ) -> ::std::os::raw::c_int; } -#[test] -fn bindgen_test_layout__OSUnalignedU16() { - assert_eq!( - ::std::mem::size_of::<_OSUnalignedU16>(), - 2usize, - concat!("Size of: ", stringify!(_OSUnalignedU16)) - ); - assert_eq!( - ::std::mem::align_of::<_OSUnalignedU16>(), - 1usize, - concat!("Alignment of ", stringify!(_OSUnalignedU16)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_OSUnalignedU16>())).__val as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_OSUnalignedU16), - "::", - stringify!(__val) - ) - ); +extern "C" { + pub fn explicit_bzero(__s: *mut ::std::os::raw::c_void, __n: usize); } -#[repr(C, packed)] -#[derive(Debug, Copy, Clone)] -pub struct _OSUnalignedU32 { - pub __val: u32, +extern "C" { + pub fn strsep( + __stringp: *mut *mut ::std::os::raw::c_char, + __delim: *const ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; } -#[test] -fn bindgen_test_layout__OSUnalignedU32() { - assert_eq!( - ::std::mem::size_of::<_OSUnalignedU32>(), - 4usize, - concat!("Size of: ", stringify!(_OSUnalignedU32)) - ); - assert_eq!( - ::std::mem::align_of::<_OSUnalignedU32>(), - 1usize, - concat!("Alignment of ", stringify!(_OSUnalignedU32)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_OSUnalignedU32>())).__val as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_OSUnalignedU32), - "::", - stringify!(__val) - ) - ); +extern "C" { + pub fn strsignal(__sig: ::std::os::raw::c_int) -> *mut ::std::os::raw::c_char; } -#[repr(C, packed)] -#[derive(Debug, Copy, Clone)] -pub struct _OSUnalignedU64 { - pub __val: u64, +extern "C" { + pub fn __stpcpy( + __dest: *mut ::std::os::raw::c_char, + __src: *const ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; } -#[test] -fn bindgen_test_layout__OSUnalignedU64() { - assert_eq!( - ::std::mem::size_of::<_OSUnalignedU64>(), - 8usize, - concat!("Size of: ", stringify!(_OSUnalignedU64)) - ); - assert_eq!( - ::std::mem::align_of::<_OSUnalignedU64>(), - 1usize, - concat!("Alignment of ", stringify!(_OSUnalignedU64)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_OSUnalignedU64>())).__val as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_OSUnalignedU64), - "::", - stringify!(__val) - ) - ); +extern "C" { + pub fn stpcpy( + __dest: *mut ::std::os::raw::c_char, + __src: *const ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; } -#[repr(C)] -#[derive(Copy, Clone)] -pub union wait { - pub w_status: ::std::os::raw::c_int, - pub w_T: wait__bindgen_ty_1, - pub w_S: wait__bindgen_ty_2, +extern "C" { + pub fn __stpncpy( + __dest: *mut ::std::os::raw::c_char, + __src: *const ::std::os::raw::c_char, + __n: usize, + ) -> *mut ::std::os::raw::c_char; } -#[repr(C)] -#[repr(align(4))] -#[derive(Debug, Copy, Clone)] -pub struct wait__bindgen_ty_1 { - pub _bitfield_align_1: [u16; 0], - pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, +extern "C" { + pub fn stpncpy( + __dest: *mut ::std::os::raw::c_char, + __src: *const ::std::os::raw::c_char, + __n: ::std::os::raw::c_ulong, + ) -> *mut ::std::os::raw::c_char; } -#[test] -fn bindgen_test_layout_wait__bindgen_ty_1() { - assert_eq!( - ::std::mem::size_of::(), - 4usize, - concat!("Size of: ", stringify!(wait__bindgen_ty_1)) - ); - assert_eq!( - ::std::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(wait__bindgen_ty_1)) - ); +#[repr(u32)] +#[doc = " Copied from TensorProto::DataType"] +#[doc = " Currently, Ort doesn't support complex64, complex128"] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum ONNXTensorElementDataType { + ONNX_TENSOR_ELEMENT_DATA_TYPE_UNDEFINED = 0, + ONNX_TENSOR_ELEMENT_DATA_TYPE_FLOAT = 1, + ONNX_TENSOR_ELEMENT_DATA_TYPE_UINT8 = 2, + ONNX_TENSOR_ELEMENT_DATA_TYPE_INT8 = 3, + ONNX_TENSOR_ELEMENT_DATA_TYPE_UINT16 = 4, + ONNX_TENSOR_ELEMENT_DATA_TYPE_INT16 = 5, + ONNX_TENSOR_ELEMENT_DATA_TYPE_INT32 = 6, + ONNX_TENSOR_ELEMENT_DATA_TYPE_INT64 = 7, + ONNX_TENSOR_ELEMENT_DATA_TYPE_STRING = 8, + ONNX_TENSOR_ELEMENT_DATA_TYPE_BOOL = 9, + ONNX_TENSOR_ELEMENT_DATA_TYPE_FLOAT16 = 10, + ONNX_TENSOR_ELEMENT_DATA_TYPE_DOUBLE = 11, + ONNX_TENSOR_ELEMENT_DATA_TYPE_UINT32 = 12, + ONNX_TENSOR_ELEMENT_DATA_TYPE_UINT64 = 13, + ONNX_TENSOR_ELEMENT_DATA_TYPE_COMPLEX64 = 14, + ONNX_TENSOR_ELEMENT_DATA_TYPE_COMPLEX128 = 15, + ONNX_TENSOR_ELEMENT_DATA_TYPE_BFLOAT16 = 16, } -impl wait__bindgen_ty_1 { - #[inline] - pub fn w_Termsig(&self) -> ::std::os::raw::c_uint { - unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 7u8) as u32) } - } - #[inline] - pub fn set_w_Termsig(&mut self, val: ::std::os::raw::c_uint) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(0usize, 7u8, val as u64) - } - } - #[inline] - pub fn w_Coredump(&self) -> ::std::os::raw::c_uint { - unsafe { ::std::mem::transmute(self._bitfield_1.get(7usize, 1u8) as u32) } - } - #[inline] - pub fn set_w_Coredump(&mut self, val: ::std::os::raw::c_uint) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(7usize, 1u8, val as u64) - } - } - #[inline] - pub fn w_Retcode(&self) -> ::std::os::raw::c_uint { - unsafe { ::std::mem::transmute(self._bitfield_1.get(8usize, 8u8) as u32) } - } - #[inline] - pub fn set_w_Retcode(&mut self, val: ::std::os::raw::c_uint) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(8usize, 8u8, val as u64) - } - } - #[inline] - pub fn w_Filler(&self) -> ::std::os::raw::c_uint { - unsafe { ::std::mem::transmute(self._bitfield_1.get(16usize, 16u8) as u32) } - } - #[inline] - pub fn set_w_Filler(&mut self, val: ::std::os::raw::c_uint) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(16usize, 16u8, val as u64) - } - } - #[inline] - pub fn new_bitfield_1( - w_Termsig: ::std::os::raw::c_uint, - w_Coredump: ::std::os::raw::c_uint, - w_Retcode: ::std::os::raw::c_uint, - w_Filler: ::std::os::raw::c_uint, - ) -> __BindgenBitfieldUnit<[u8; 4usize]> { - let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 4usize]> = Default::default(); - __bindgen_bitfield_unit.set(0usize, 7u8, { - let w_Termsig: u32 = unsafe { ::std::mem::transmute(w_Termsig) }; - w_Termsig as u64 - }); - __bindgen_bitfield_unit.set(7usize, 1u8, { - let w_Coredump: u32 = unsafe { ::std::mem::transmute(w_Coredump) }; - w_Coredump as u64 - }); - __bindgen_bitfield_unit.set(8usize, 8u8, { - let w_Retcode: u32 = unsafe { ::std::mem::transmute(w_Retcode) }; - w_Retcode as u64 - }); - __bindgen_bitfield_unit.set(16usize, 16u8, { - let w_Filler: u32 = unsafe { ::std::mem::transmute(w_Filler) }; - w_Filler as u64 - }); - __bindgen_bitfield_unit - } +#[repr(u32)] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum ONNXType { + ONNX_TYPE_UNKNOWN = 0, + ONNX_TYPE_TENSOR = 1, + ONNX_TYPE_SEQUENCE = 2, + ONNX_TYPE_MAP = 3, + ONNX_TYPE_OPAQUE = 4, + ONNX_TYPE_SPARSETENSOR = 5, + ONNX_TYPE_OPTIONAL = 6, } -#[repr(C)] -#[repr(align(4))] -#[derive(Debug, Copy, Clone)] -pub struct wait__bindgen_ty_2 { - pub _bitfield_align_1: [u16; 0], - pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, +#[repr(u32)] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum OrtSparseFormat { + ORT_SPARSE_UNDEFINED = 0, + ORT_SPARSE_COO = 1, + ORT_SPARSE_CSRC = 2, + ORT_SPARSE_BLOCK_SPARSE = 4, } -#[test] -fn bindgen_test_layout_wait__bindgen_ty_2() { - assert_eq!( - ::std::mem::size_of::(), - 4usize, - concat!("Size of: ", stringify!(wait__bindgen_ty_2)) - ); - assert_eq!( - ::std::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(wait__bindgen_ty_2)) - ); +#[repr(u32)] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum OrtSparseIndicesFormat { + ORT_SPARSE_COO_INDICES = 0, + ORT_SPARSE_CSR_INNER_INDICES = 1, + ORT_SPARSE_CSR_OUTER_INDICES = 2, + ORT_SPARSE_BLOCK_SPARSE_INDICES = 3, } -impl wait__bindgen_ty_2 { - #[inline] - pub fn w_Stopval(&self) -> ::std::os::raw::c_uint { - unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 8u8) as u32) } - } - #[inline] - pub fn set_w_Stopval(&mut self, val: ::std::os::raw::c_uint) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(0usize, 8u8, val as u64) - } - } - #[inline] - pub fn w_Stopsig(&self) -> ::std::os::raw::c_uint { - unsafe { ::std::mem::transmute(self._bitfield_1.get(8usize, 8u8) as u32) } - } - #[inline] - pub fn set_w_Stopsig(&mut self, val: ::std::os::raw::c_uint) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(8usize, 8u8, val as u64) - } - } - #[inline] - pub fn w_Filler(&self) -> ::std::os::raw::c_uint { - unsafe { ::std::mem::transmute(self._bitfield_1.get(16usize, 16u8) as u32) } - } - #[inline] - pub fn set_w_Filler(&mut self, val: ::std::os::raw::c_uint) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(16usize, 16u8, val as u64) - } - } - #[inline] - pub fn new_bitfield_1( - w_Stopval: ::std::os::raw::c_uint, - w_Stopsig: ::std::os::raw::c_uint, - w_Filler: ::std::os::raw::c_uint, - ) -> __BindgenBitfieldUnit<[u8; 4usize]> { - let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 4usize]> = Default::default(); - __bindgen_bitfield_unit.set(0usize, 8u8, { - let w_Stopval: u32 = unsafe { ::std::mem::transmute(w_Stopval) }; - w_Stopval as u64 - }); - __bindgen_bitfield_unit.set(8usize, 8u8, { - let w_Stopsig: u32 = unsafe { ::std::mem::transmute(w_Stopsig) }; - w_Stopsig as u64 - }); - __bindgen_bitfield_unit.set(16usize, 16u8, { - let w_Filler: u32 = unsafe { ::std::mem::transmute(w_Filler) }; - w_Filler as u64 - }); - __bindgen_bitfield_unit - } +#[repr(u32)] +#[doc = " \\brief Logging severity levels"] +#[doc = ""] +#[doc = " In typical API usage, specifying a logging severity level specifies the minimum severity of log messages to show."] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum OrtLoggingLevel { + #[doc = "< Verbose informational messages (least severe)."] + ORT_LOGGING_LEVEL_VERBOSE = 0, + #[doc = "< Informational messages."] + ORT_LOGGING_LEVEL_INFO = 1, + #[doc = "< Warning messages."] + ORT_LOGGING_LEVEL_WARNING = 2, + #[doc = "< Error messages."] + ORT_LOGGING_LEVEL_ERROR = 3, + #[doc = "< Fatal error messages (most severe)."] + ORT_LOGGING_LEVEL_FATAL = 4, } -#[test] -fn bindgen_test_layout_wait() { - assert_eq!( - ::std::mem::size_of::(), - 4usize, - concat!("Size of: ", stringify!(wait)) - ); - assert_eq!( - ::std::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(wait)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).w_status as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(wait), - "::", - stringify!(w_status) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).w_T as *const _ as usize }, - 0usize, - concat!("Offset of field: ", stringify!(wait), "::", stringify!(w_T)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).w_S as *const _ as usize }, - 0usize, - concat!("Offset of field: ", stringify!(wait), "::", stringify!(w_S)) - ); +#[repr(u32)] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum OrtErrorCode { + ORT_OK = 0, + ORT_FAIL = 1, + ORT_INVALID_ARGUMENT = 2, + ORT_NO_SUCHFILE = 3, + ORT_NO_MODEL = 4, + ORT_ENGINE_ERROR = 5, + ORT_RUNTIME_EXCEPTION = 6, + ORT_INVALID_PROTOBUF = 7, + ORT_MODEL_LOADED = 8, + ORT_NOT_IMPLEMENTED = 9, + ORT_INVALID_GRAPH = 10, + ORT_EP_FAIL = 11, } -extern "C" { - pub fn wait(arg1: *mut ::std::os::raw::c_int) -> pid_t; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtEnv { + _unused: [u8; 0], } -extern "C" { - pub fn waitpid( - arg1: pid_t, - arg2: *mut ::std::os::raw::c_int, - arg3: ::std::os::raw::c_int, - ) -> pid_t; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtStatus { + _unused: [u8; 0], } -extern "C" { - pub fn waitid( - arg1: idtype_t, - arg2: id_t, - arg3: *mut siginfo_t, - arg4: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtMemoryInfo { + _unused: [u8; 0], } -extern "C" { - pub fn wait3( - arg1: *mut ::std::os::raw::c_int, - arg2: ::std::os::raw::c_int, - arg3: *mut rusage, - ) -> pid_t; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtIoBinding { + _unused: [u8; 0], } -extern "C" { - pub fn wait4( - arg1: pid_t, - arg2: *mut ::std::os::raw::c_int, - arg3: ::std::os::raw::c_int, - arg4: *mut rusage, - ) -> pid_t; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtSession { + _unused: [u8; 0], } -extern "C" { - pub fn alloca(arg1: ::std::os::raw::c_ulong) -> *mut ::std::os::raw::c_void; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtValue { + _unused: [u8; 0], } -pub type ct_rune_t = __darwin_ct_rune_t; -pub type rune_t = __darwin_rune_t; -pub type wchar_t = __darwin_wchar_t; #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct div_t { - pub quot: ::std::os::raw::c_int, - pub rem: ::std::os::raw::c_int, +pub struct OrtRunOptions { + _unused: [u8; 0], } -#[test] -fn bindgen_test_layout_div_t() { - assert_eq!( - ::std::mem::size_of::(), - 8usize, - concat!("Size of: ", stringify!(div_t)) - ); - assert_eq!( - ::std::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(div_t)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).quot as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(div_t), - "::", - stringify!(quot) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).rem as *const _ as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(div_t), - "::", - stringify!(rem) - ) - ); +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtTypeInfo { + _unused: [u8; 0], } #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct ldiv_t { - pub quot: ::std::os::raw::c_long, - pub rem: ::std::os::raw::c_long, +pub struct OrtTensorTypeAndShapeInfo { + _unused: [u8; 0], } -#[test] -fn bindgen_test_layout_ldiv_t() { - assert_eq!( - ::std::mem::size_of::(), - 16usize, - concat!("Size of: ", stringify!(ldiv_t)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(ldiv_t)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).quot as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(ldiv_t), - "::", - stringify!(quot) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).rem as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(ldiv_t), - "::", - stringify!(rem) - ) - ); +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtSessionOptions { + _unused: [u8; 0], } #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct lldiv_t { - pub quot: ::std::os::raw::c_longlong, - pub rem: ::std::os::raw::c_longlong, +pub struct OrtCustomOpDomain { + _unused: [u8; 0], } -#[test] -fn bindgen_test_layout_lldiv_t() { - assert_eq!( - ::std::mem::size_of::(), - 16usize, - concat!("Size of: ", stringify!(lldiv_t)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(lldiv_t)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).quot as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(lldiv_t), - "::", - stringify!(quot) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).rem as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(lldiv_t), - "::", - stringify!(rem) - ) - ); +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtMapTypeInfo { + _unused: [u8; 0], } -extern "C" { - pub static mut __mb_cur_max: ::std::os::raw::c_int; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtSequenceTypeInfo { + _unused: [u8; 0], } -extern "C" { - pub fn malloc(__size: ::std::os::raw::c_ulong) -> *mut ::std::os::raw::c_void; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtModelMetadata { + _unused: [u8; 0], } -extern "C" { - pub fn calloc( - __count: ::std::os::raw::c_ulong, - __size: ::std::os::raw::c_ulong, - ) -> *mut ::std::os::raw::c_void; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtThreadPoolParams { + _unused: [u8; 0], } -extern "C" { - pub fn free(arg1: *mut ::std::os::raw::c_void); +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtThreadingOptions { + _unused: [u8; 0], } -extern "C" { - pub fn realloc( - __ptr: *mut ::std::os::raw::c_void, - __size: ::std::os::raw::c_ulong, - ) -> *mut ::std::os::raw::c_void; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtArenaCfg { + _unused: [u8; 0], } -extern "C" { - pub fn valloc(arg1: usize) -> *mut ::std::os::raw::c_void; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtPrepackedWeightsContainer { + _unused: [u8; 0], } -extern "C" { - pub fn aligned_alloc(__alignment: usize, __size: usize) -> *mut ::std::os::raw::c_void; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtTensorRTProviderOptionsV2 { + _unused: [u8; 0], } -extern "C" { - pub fn posix_memalign( - __memptr: *mut *mut ::std::os::raw::c_void, - __alignment: usize, - __size: usize, - ) -> ::std::os::raw::c_int; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtCUDAProviderOptionsV2 { + _unused: [u8; 0], } -extern "C" { - pub fn abort(); +pub type OrtStatusPtr = *mut OrtStatus; +#[doc = " \\brief Memory allocation interface"] +#[doc = ""] +#[doc = " Structure of function pointers that defines a memory allocator. This can be created and filled in by the user for custom allocators."] +#[doc = ""] +#[doc = " When an allocator is passed to any function, be sure that the allocator object is not destroyed until the last allocated object using it is freed."] +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtAllocator { + #[doc = "< Must be initialized to ORT_API_VERSION"] + pub version: u32, + #[doc = "< Returns a pointer to an allocated block of `size` bytes"] + pub Alloc: ::std::option::Option< + unsafe extern "C" fn(this_: *mut OrtAllocator, size: usize) -> *mut ::std::os::raw::c_void, + >, + #[doc = "< Free a block of memory previously allocated with OrtAllocator::Alloc"] + pub Free: ::std::option::Option< + unsafe extern "C" fn(this_: *mut OrtAllocator, p: *mut ::std::os::raw::c_void), + >, + #[doc = "< Return a pointer to an ::OrtMemoryInfo that describes this allocator"] + pub Info: ::std::option::Option< + unsafe extern "C" fn(this_: *const OrtAllocator) -> *const OrtMemoryInfo, + >, } -extern "C" { - pub fn abs(arg1: ::std::os::raw::c_int) -> ::std::os::raw::c_int; +#[test] +fn bindgen_test_layout_OrtAllocator() { + assert_eq!( + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(OrtAllocator)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(OrtAllocator)) + ); + fn test_field_version() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).version) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtAllocator), + "::", + stringify!(version) + ) + ); + } + test_field_version(); + fn test_field_Alloc() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).Alloc) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtAllocator), + "::", + stringify!(Alloc) + ) + ); + } + test_field_Alloc(); + fn test_field_Free() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).Free) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(OrtAllocator), + "::", + stringify!(Free) + ) + ); + } + test_field_Free(); + fn test_field_Info() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).Info) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(OrtAllocator), + "::", + stringify!(Info) + ) + ); + } + test_field_Info(); } -extern "C" { - pub fn atexit(arg1: ::std::option::Option) -> ::std::os::raw::c_int; +pub type OrtLoggingFunction = ::std::option::Option< + unsafe extern "C" fn( + param: *mut ::std::os::raw::c_void, + severity: OrtLoggingLevel, + category: *const ::std::os::raw::c_char, + logid: *const ::std::os::raw::c_char, + code_location: *const ::std::os::raw::c_char, + message: *const ::std::os::raw::c_char, + ), +>; +#[repr(u32)] +#[doc = " \\brief Graph optimization level"] +#[doc = ""] +#[doc = " Refer to https://www.onnxruntime.ai/docs/resources/graph-optimizations.html"] +#[doc = " for an in-depth understanding of Graph Optimizations"] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum GraphOptimizationLevel { + ORT_DISABLE_ALL = 0, + ORT_ENABLE_BASIC = 1, + ORT_ENABLE_EXTENDED = 2, + ORT_ENABLE_ALL = 99, } -extern "C" { - pub fn atof(arg1: *const ::std::os::raw::c_char) -> f64; +#[repr(u32)] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum ExecutionMode { + ORT_SEQUENTIAL = 0, + ORT_PARALLEL = 1, } -extern "C" { - pub fn atoi(arg1: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int; +#[repr(u32)] +#[doc = " \\brief Language projection identifiers"] +#[doc = " /see OrtApi::SetLanguageProjection"] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum OrtLanguageProjection { + ORT_PROJECTION_C = 0, + ORT_PROJECTION_CPLUSPLUS = 1, + ORT_PROJECTION_CSHARP = 2, + ORT_PROJECTION_PYTHON = 3, + ORT_PROJECTION_JAVA = 4, + ORT_PROJECTION_WINML = 5, + ORT_PROJECTION_NODEJS = 6, } -extern "C" { - pub fn atol(arg1: *const ::std::os::raw::c_char) -> ::std::os::raw::c_long; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtKernelInfo { + _unused: [u8; 0], } -extern "C" { - pub fn atoll(arg1: *const ::std::os::raw::c_char) -> ::std::os::raw::c_longlong; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtKernelContext { + _unused: [u8; 0], } -extern "C" { - pub fn bsearch( - __key: *const ::std::os::raw::c_void, - __base: *const ::std::os::raw::c_void, - __nel: usize, - __width: usize, - __compar: ::std::option::Option< - unsafe extern "C" fn( - arg1: *const ::std::os::raw::c_void, - arg2: *const ::std::os::raw::c_void, - ) -> ::std::os::raw::c_int, - >, - ) -> *mut ::std::os::raw::c_void; +#[repr(i32)] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum OrtAllocatorType { + OrtInvalidAllocator = -1, + OrtDeviceAllocator = 0, + OrtArenaAllocator = 1, } -extern "C" { - pub fn div(arg1: ::std::os::raw::c_int, arg2: ::std::os::raw::c_int) -> div_t; +impl OrtMemType { + pub const OrtMemTypeCPU: OrtMemType = OrtMemType::OrtMemTypeCPUOutput; } -extern "C" { - pub fn exit(arg1: ::std::os::raw::c_int); +#[repr(i32)] +#[doc = " \\brief Memory types for allocated memory, execution provider specific types should be extended in each provider."] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum OrtMemType { + #[doc = "< Any CPU memory used by non-CPU execution provider"] + OrtMemTypeCPUInput = -2, + #[doc = "< CPU accessible memory outputted by non-CPU execution provider, i.e. CUDA_PINNED"] + OrtMemTypeCPUOutput = -1, + #[doc = "< The default allocator for execution provider"] + OrtMemTypeDefault = 0, } -extern "C" { - pub fn getenv(arg1: *const ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; +#[repr(u32)] +#[doc = " \\brief Algorithm to use for cuDNN Convolution Op"] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum OrtCudnnConvAlgoSearch { + OrtCudnnConvAlgoSearchExhaustive = 0, + OrtCudnnConvAlgoSearchHeuristic = 1, + OrtCudnnConvAlgoSearchDefault = 2, } -extern "C" { - pub fn labs(arg1: ::std::os::raw::c_long) -> ::std::os::raw::c_long; +#[doc = " \\brief CUDA Provider Options"] +#[doc = ""] +#[doc = " \\see OrtApi::SessionOptionsAppendExecutionProvider_CUDA"] +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtCUDAProviderOptions { + #[doc = " \\brief CUDA device Id"] + #[doc = " Defaults to 0."] + pub device_id: ::std::os::raw::c_int, + #[doc = " \\brief CUDA Convolution algorithm search configuration."] + #[doc = " See enum OrtCudnnConvAlgoSearch for more details."] + #[doc = " Defaults to OrtCudnnConvAlgoSearchExhaustive."] + pub cudnn_conv_algo_search: OrtCudnnConvAlgoSearch, + #[doc = " \\brief CUDA memory limit (To use all possible memory pass in maximum size_t)"] + #[doc = " Defaults to SIZE_MAX."] + #[doc = " \\note If a ::OrtArenaCfg has been applied, it will override this field"] + pub gpu_mem_limit: usize, + #[doc = " \\brief Strategy used to grow the memory arena"] + #[doc = " 0 = kNextPowerOfTwo
"] + #[doc = " 1 = kSameAsRequested
"] + #[doc = " Defaults to 0."] + #[doc = " \\note If a ::OrtArenaCfg has been applied, it will override this field"] + pub arena_extend_strategy: ::std::os::raw::c_int, + #[doc = " \\brief Flag indicating if copying needs to take place on the same stream as the compute stream in the CUDA EP"] + #[doc = " 0 = Use separate streams for copying and compute."] + #[doc = " 1 = Use the same stream for copying and compute."] + #[doc = " Defaults to 1."] + #[doc = " WARNING: Setting this to 0 may result in data races for some models."] + #[doc = " Please see issue #4829 for more details."] + pub do_copy_in_default_stream: ::std::os::raw::c_int, + #[doc = " \\brief Flag indicating if there is a user provided compute stream"] + #[doc = " Defaults to 0."] + pub has_user_compute_stream: ::std::os::raw::c_int, + #[doc = " \\brief User provided compute stream."] + #[doc = " If provided, please set `has_user_compute_stream` to 1."] + pub user_compute_stream: *mut ::std::os::raw::c_void, + #[doc = " \\brief CUDA memory arena configuration parameters"] + pub default_memory_arena_cfg: *mut OrtArenaCfg, } -extern "C" { - pub fn ldiv(arg1: ::std::os::raw::c_long, arg2: ::std::os::raw::c_long) -> ldiv_t; +#[test] +fn bindgen_test_layout_OrtCUDAProviderOptions() { + assert_eq!( + ::std::mem::size_of::(), + 48usize, + concat!("Size of: ", stringify!(OrtCUDAProviderOptions)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(OrtCUDAProviderOptions)) + ); + fn test_field_device_id() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).device_id) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(device_id) + ) + ); + } + test_field_device_id(); + fn test_field_cudnn_conv_algo_search() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).cudnn_conv_algo_search) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(cudnn_conv_algo_search) + ) + ); + } + test_field_cudnn_conv_algo_search(); + fn test_field_gpu_mem_limit() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).gpu_mem_limit) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(gpu_mem_limit) + ) + ); + } + test_field_gpu_mem_limit(); + fn test_field_arena_extend_strategy() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).arena_extend_strategy) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(arena_extend_strategy) + ) + ); + } + test_field_arena_extend_strategy(); + fn test_field_do_copy_in_default_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).do_copy_in_default_stream) as usize - ptr as usize + }, + 20usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(do_copy_in_default_stream) + ) + ); + } + test_field_do_copy_in_default_stream(); + fn test_field_has_user_compute_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).has_user_compute_stream) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(has_user_compute_stream) + ) + ); + } + test_field_has_user_compute_stream(); + fn test_field_user_compute_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).user_compute_stream) as usize - ptr as usize + }, + 32usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(user_compute_stream) + ) + ); + } + test_field_user_compute_stream(); + fn test_field_default_memory_arena_cfg() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).default_memory_arena_cfg) as usize - ptr as usize + }, + 40usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(default_memory_arena_cfg) + ) + ); + } + test_field_default_memory_arena_cfg(); } -extern "C" { - pub fn llabs(arg1: ::std::os::raw::c_longlong) -> ::std::os::raw::c_longlong; +#[doc = " \\brief ROCM Provider Options"] +#[doc = ""] +#[doc = " \\see OrtApi::SessionOptionsAppendExecutionProvider_ROCM"] +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtROCMProviderOptions { + #[doc = " \\brief ROCM device Id"] + #[doc = " Defaults to 0."] + pub device_id: ::std::os::raw::c_int, + #[doc = " \\brief ROCM MIOpen Convolution algorithm exaustive search option."] + #[doc = " Defaults to 0 (false)."] + pub miopen_conv_exhaustive_search: ::std::os::raw::c_int, + #[doc = " \\brief ROCM memory limit (To use all possible memory pass in maximum size_t)"] + #[doc = " Defaults to SIZE_MAX."] + #[doc = " \\note If a ::OrtArenaCfg has been applied, it will override this field"] + pub gpu_mem_limit: usize, + #[doc = " \\brief Strategy used to grow the memory arena"] + #[doc = " 0 = kNextPowerOfTwo
"] + #[doc = " 1 = kSameAsRequested
"] + #[doc = " Defaults to 0."] + #[doc = " \\note If a ::OrtArenaCfg has been applied, it will override this field"] + pub arena_extend_strategy: ::std::os::raw::c_int, + #[doc = " \\brief Flag indicating if copying needs to take place on the same stream as the compute stream in the ROCM EP"] + #[doc = " 0 = Use separate streams for copying and compute."] + #[doc = " 1 = Use the same stream for copying and compute."] + #[doc = " Defaults to 1."] + #[doc = " WARNING: Setting this to 0 may result in data races for some models."] + #[doc = " Please see issue #4829 for more details."] + pub do_copy_in_default_stream: ::std::os::raw::c_int, + #[doc = " \\brief Flag indicating if there is a user provided compute stream"] + #[doc = " Defaults to 0."] + pub has_user_compute_stream: ::std::os::raw::c_int, + #[doc = " \\brief User provided compute stream."] + #[doc = " If provided, please set `has_user_compute_stream` to 1."] + pub user_compute_stream: *mut ::std::os::raw::c_void, + #[doc = " \\brief ROCM memory arena configuration parameters"] + pub default_memory_arena_cfg: *mut OrtArenaCfg, } -extern "C" { - pub fn lldiv(arg1: ::std::os::raw::c_longlong, arg2: ::std::os::raw::c_longlong) -> lldiv_t; +#[test] +fn bindgen_test_layout_OrtROCMProviderOptions() { + assert_eq!( + ::std::mem::size_of::(), + 48usize, + concat!("Size of: ", stringify!(OrtROCMProviderOptions)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(OrtROCMProviderOptions)) + ); + fn test_field_device_id() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).device_id) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(device_id) + ) + ); + } + test_field_device_id(); + fn test_field_miopen_conv_exhaustive_search() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).miopen_conv_exhaustive_search) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(miopen_conv_exhaustive_search) + ) + ); + } + test_field_miopen_conv_exhaustive_search(); + fn test_field_gpu_mem_limit() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).gpu_mem_limit) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(gpu_mem_limit) + ) + ); + } + test_field_gpu_mem_limit(); + fn test_field_arena_extend_strategy() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).arena_extend_strategy) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(arena_extend_strategy) + ) + ); + } + test_field_arena_extend_strategy(); + fn test_field_do_copy_in_default_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).do_copy_in_default_stream) as usize - ptr as usize + }, + 20usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(do_copy_in_default_stream) + ) + ); + } + test_field_do_copy_in_default_stream(); + fn test_field_has_user_compute_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).has_user_compute_stream) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(has_user_compute_stream) + ) + ); + } + test_field_has_user_compute_stream(); + fn test_field_user_compute_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).user_compute_stream) as usize - ptr as usize + }, + 32usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(user_compute_stream) + ) + ); + } + test_field_user_compute_stream(); + fn test_field_default_memory_arena_cfg() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).default_memory_arena_cfg) as usize - ptr as usize + }, + 40usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(default_memory_arena_cfg) + ) + ); + } + test_field_default_memory_arena_cfg(); } -extern "C" { - pub fn mblen(__s: *const ::std::os::raw::c_char, __n: usize) -> ::std::os::raw::c_int; +#[doc = " \\brief TensorRT Provider Options"] +#[doc = ""] +#[doc = " \\see OrtApi::SessionOptionsAppendExecutionProvider_TensorRT"] +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtTensorRTProviderOptions { + #[doc = "< CUDA device id (0 = default device)"] + pub device_id: ::std::os::raw::c_int, + pub has_user_compute_stream: ::std::os::raw::c_int, + pub user_compute_stream: *mut ::std::os::raw::c_void, + pub trt_max_partition_iterations: ::std::os::raw::c_int, + pub trt_min_subgraph_size: ::std::os::raw::c_int, + pub trt_max_workspace_size: usize, + pub trt_fp16_enable: ::std::os::raw::c_int, + pub trt_int8_enable: ::std::os::raw::c_int, + pub trt_int8_calibration_table_name: *const ::std::os::raw::c_char, + pub trt_int8_use_native_calibration_table: ::std::os::raw::c_int, + pub trt_dla_enable: ::std::os::raw::c_int, + pub trt_dla_core: ::std::os::raw::c_int, + pub trt_dump_subgraphs: ::std::os::raw::c_int, + pub trt_engine_cache_enable: ::std::os::raw::c_int, + pub trt_engine_cache_path: *const ::std::os::raw::c_char, + pub trt_engine_decryption_enable: ::std::os::raw::c_int, + pub trt_engine_decryption_lib_path: *const ::std::os::raw::c_char, + pub trt_force_sequential_engine_build: ::std::os::raw::c_int, } -extern "C" { - pub fn mbstowcs(arg1: *mut wchar_t, arg2: *const ::std::os::raw::c_char, arg3: usize) -> usize; +#[test] +fn bindgen_test_layout_OrtTensorRTProviderOptions() { + assert_eq!( + ::std::mem::size_of::(), + 104usize, + concat!("Size of: ", stringify!(OrtTensorRTProviderOptions)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(OrtTensorRTProviderOptions)) + ); + fn test_field_device_id() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).device_id) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(device_id) + ) + ); + } + test_field_device_id(); + fn test_field_has_user_compute_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).has_user_compute_stream) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(has_user_compute_stream) + ) + ); + } + test_field_has_user_compute_stream(); + fn test_field_user_compute_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).user_compute_stream) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(user_compute_stream) + ) + ); + } + test_field_user_compute_stream(); + fn test_field_trt_max_partition_iterations() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_max_partition_iterations) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_max_partition_iterations) + ) + ); + } + test_field_trt_max_partition_iterations(); + fn test_field_trt_min_subgraph_size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_min_subgraph_size) as usize - ptr as usize + }, + 20usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_min_subgraph_size) + ) + ); + } + test_field_trt_min_subgraph_size(); + fn test_field_trt_max_workspace_size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_max_workspace_size) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_max_workspace_size) + ) + ); + } + test_field_trt_max_workspace_size(); + fn test_field_trt_fp16_enable() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_fp16_enable) as usize - ptr as usize + }, + 32usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_fp16_enable) + ) + ); + } + test_field_trt_fp16_enable(); + fn test_field_trt_int8_enable() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_int8_enable) as usize - ptr as usize + }, + 36usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_int8_enable) + ) + ); + } + test_field_trt_int8_enable(); + fn test_field_trt_int8_calibration_table_name() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_int8_calibration_table_name) as usize - ptr as usize + }, + 40usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_int8_calibration_table_name) + ) + ); + } + test_field_trt_int8_calibration_table_name(); + fn test_field_trt_int8_use_native_calibration_table() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_int8_use_native_calibration_table) as usize + - ptr as usize + }, + 48usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_int8_use_native_calibration_table) + ) + ); + } + test_field_trt_int8_use_native_calibration_table(); + fn test_field_trt_dla_enable() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_dla_enable) as usize - ptr as usize + }, + 52usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_dla_enable) + ) + ); + } + test_field_trt_dla_enable(); + fn test_field_trt_dla_core() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_dla_core) as usize - ptr as usize + }, + 56usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_dla_core) + ) + ); + } + test_field_trt_dla_core(); + fn test_field_trt_dump_subgraphs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_dump_subgraphs) as usize - ptr as usize + }, + 60usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_dump_subgraphs) + ) + ); + } + test_field_trt_dump_subgraphs(); + fn test_field_trt_engine_cache_enable() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_engine_cache_enable) as usize - ptr as usize + }, + 64usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_engine_cache_enable) + ) + ); + } + test_field_trt_engine_cache_enable(); + fn test_field_trt_engine_cache_path() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_engine_cache_path) as usize - ptr as usize + }, + 72usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_engine_cache_path) + ) + ); + } + test_field_trt_engine_cache_path(); + fn test_field_trt_engine_decryption_enable() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_engine_decryption_enable) as usize - ptr as usize + }, + 80usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_engine_decryption_enable) + ) + ); + } + test_field_trt_engine_decryption_enable(); + fn test_field_trt_engine_decryption_lib_path() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_engine_decryption_lib_path) as usize - ptr as usize + }, + 88usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_engine_decryption_lib_path) + ) + ); + } + test_field_trt_engine_decryption_lib_path(); + fn test_field_trt_force_sequential_engine_build() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_force_sequential_engine_build) as usize + - ptr as usize + }, + 96usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_force_sequential_engine_build) + ) + ); + } + test_field_trt_force_sequential_engine_build(); } -extern "C" { - pub fn mbtowc( - arg1: *mut wchar_t, - arg2: *const ::std::os::raw::c_char, - arg3: usize, - ) -> ::std::os::raw::c_int; +#[doc = " \\brief MIGraphX Provider Options"] +#[doc = ""] +#[doc = " \\see OrtApi::SessionOptionsAppendExecutionProvider_MIGraphX"] +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtMIGraphXProviderOptions { + pub device_id: ::std::os::raw::c_int, + pub migraphx_fp16_enable: ::std::os::raw::c_int, + pub migraphx_int8_enable: ::std::os::raw::c_int, } -extern "C" { - pub fn qsort( - __base: *mut ::std::os::raw::c_void, - __nel: usize, - __width: usize, - __compar: ::std::option::Option< - unsafe extern "C" fn( - arg1: *const ::std::os::raw::c_void, - arg2: *const ::std::os::raw::c_void, - ) -> ::std::os::raw::c_int, - >, +#[test] +fn bindgen_test_layout_OrtMIGraphXProviderOptions() { + assert_eq!( + ::std::mem::size_of::(), + 12usize, + concat!("Size of: ", stringify!(OrtMIGraphXProviderOptions)) ); + assert_eq!( + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(OrtMIGraphXProviderOptions)) + ); + fn test_field_device_id() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).device_id) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtMIGraphXProviderOptions), + "::", + stringify!(device_id) + ) + ); + } + test_field_device_id(); + fn test_field_migraphx_fp16_enable() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).migraphx_fp16_enable) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(OrtMIGraphXProviderOptions), + "::", + stringify!(migraphx_fp16_enable) + ) + ); + } + test_field_migraphx_fp16_enable(); + fn test_field_migraphx_int8_enable() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).migraphx_int8_enable) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtMIGraphXProviderOptions), + "::", + stringify!(migraphx_int8_enable) + ) + ); + } + test_field_migraphx_int8_enable(); } -extern "C" { - pub fn rand() -> ::std::os::raw::c_int; -} -extern "C" { - pub fn srand(arg1: ::std::os::raw::c_uint); +#[doc = " \\brief OpenVINO Provider Options"] +#[doc = ""] +#[doc = " \\see OrtApi::SessionOptionsAppendExecutionProvider_OpenVINO"] +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtOpenVINOProviderOptions { + #[doc = " \\brief Device type string"] + #[doc = ""] + #[doc = " Valid settings are one of: \"CPU_FP32\", \"GPU_FP32\", \"GPU_FP16\", \"MYRIAD_FP16\", \"VAD-M_FP16\" or \"VAD-F_FP32\""] + pub device_type: *const ::std::os::raw::c_char, + #[doc = "< 0 = disabled, nonzero = enabled"] + pub enable_vpu_fast_compile: ::std::os::raw::c_uchar, + pub device_id: *const ::std::os::raw::c_char, + #[doc = "< 0 = Use default number of threads"] + pub num_of_threads: usize, + #[doc = "< 0 = disabled, nonzero = enabled"] + pub use_compiled_network: ::std::os::raw::c_uchar, + pub blob_dump_path: *const ::std::os::raw::c_char, + pub context: *mut ::std::os::raw::c_void, } -extern "C" { - pub fn strtod( - arg1: *const ::std::os::raw::c_char, - arg2: *mut *mut ::std::os::raw::c_char, - ) -> f64; -} -extern "C" { - pub fn strtof( - arg1: *const ::std::os::raw::c_char, - arg2: *mut *mut ::std::os::raw::c_char, - ) -> f32; -} -extern "C" { - pub fn strtol( - __str: *const ::std::os::raw::c_char, - __endptr: *mut *mut ::std::os::raw::c_char, - __base: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_long; -} -extern "C" { - pub fn strtold( - arg1: *const ::std::os::raw::c_char, - arg2: *mut *mut ::std::os::raw::c_char, - ) -> f64; -} -extern "C" { - pub fn strtoll( - __str: *const ::std::os::raw::c_char, - __endptr: *mut *mut ::std::os::raw::c_char, - __base: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_longlong; -} -extern "C" { - pub fn strtoul( - __str: *const ::std::os::raw::c_char, - __endptr: *mut *mut ::std::os::raw::c_char, - __base: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_ulong; -} -extern "C" { - pub fn strtoull( - __str: *const ::std::os::raw::c_char, - __endptr: *mut *mut ::std::os::raw::c_char, - __base: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_ulonglong; -} -extern "C" { - pub fn system(arg1: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn wcstombs(arg1: *mut ::std::os::raw::c_char, arg2: *const wchar_t, arg3: usize) -> usize; -} -extern "C" { - pub fn wctomb(arg1: *mut ::std::os::raw::c_char, arg2: wchar_t) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn _Exit(arg1: ::std::os::raw::c_int); -} -extern "C" { - pub fn a64l(arg1: *const ::std::os::raw::c_char) -> ::std::os::raw::c_long; -} -extern "C" { - pub fn drand48() -> f64; -} -extern "C" { - pub fn ecvt( - arg1: f64, - arg2: ::std::os::raw::c_int, - arg3: *mut ::std::os::raw::c_int, - arg4: *mut ::std::os::raw::c_int, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn erand48(arg1: *mut ::std::os::raw::c_ushort) -> f64; -} -extern "C" { - pub fn fcvt( - arg1: f64, - arg2: ::std::os::raw::c_int, - arg3: *mut ::std::os::raw::c_int, - arg4: *mut ::std::os::raw::c_int, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn gcvt( - arg1: f64, - arg2: ::std::os::raw::c_int, - arg3: *mut ::std::os::raw::c_char, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn getsubopt( - arg1: *mut *mut ::std::os::raw::c_char, - arg2: *const *mut ::std::os::raw::c_char, - arg3: *mut *mut ::std::os::raw::c_char, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn grantpt(arg1: ::std::os::raw::c_int) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn initstate( - arg1: ::std::os::raw::c_uint, - arg2: *mut ::std::os::raw::c_char, - arg3: usize, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn jrand48(arg1: *mut ::std::os::raw::c_ushort) -> ::std::os::raw::c_long; -} -extern "C" { - pub fn l64a(arg1: ::std::os::raw::c_long) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn lcong48(arg1: *mut ::std::os::raw::c_ushort); -} -extern "C" { - pub fn lrand48() -> ::std::os::raw::c_long; -} -extern "C" { - pub fn mktemp(arg1: *mut ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn mkstemp(arg1: *mut ::std::os::raw::c_char) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn mrand48() -> ::std::os::raw::c_long; -} -extern "C" { - pub fn nrand48(arg1: *mut ::std::os::raw::c_ushort) -> ::std::os::raw::c_long; -} -extern "C" { - pub fn posix_openpt(arg1: ::std::os::raw::c_int) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn ptsname(arg1: ::std::os::raw::c_int) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn ptsname_r( - fildes: ::std::os::raw::c_int, - buffer: *mut ::std::os::raw::c_char, - buflen: usize, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn putenv(arg1: *mut ::std::os::raw::c_char) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn random() -> ::std::os::raw::c_long; -} -extern "C" { - pub fn rand_r(arg1: *mut ::std::os::raw::c_uint) -> ::std::os::raw::c_int; -} -extern "C" { - #[link_name = "\u{1}_realpath$DARWIN_EXTSN"] - pub fn realpath( - arg1: *const ::std::os::raw::c_char, - arg2: *mut ::std::os::raw::c_char, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn seed48(arg1: *mut ::std::os::raw::c_ushort) -> *mut ::std::os::raw::c_ushort; -} -extern "C" { - pub fn setenv( - __name: *const ::std::os::raw::c_char, - __value: *const ::std::os::raw::c_char, - __overwrite: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn setkey(arg1: *const ::std::os::raw::c_char); -} -extern "C" { - pub fn setstate(arg1: *const ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn srand48(arg1: ::std::os::raw::c_long); -} -extern "C" { - pub fn srandom(arg1: ::std::os::raw::c_uint); -} -extern "C" { - pub fn unlockpt(arg1: ::std::os::raw::c_int) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn unsetenv(arg1: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int; -} -pub type dev_t = __darwin_dev_t; -pub type mode_t = __darwin_mode_t; -extern "C" { - pub fn arc4random() -> u32; -} -extern "C" { - pub fn arc4random_addrandom(arg1: *mut ::std::os::raw::c_uchar, arg2: ::std::os::raw::c_int); -} -extern "C" { - pub fn arc4random_buf(__buf: *mut ::std::os::raw::c_void, __nbytes: usize); -} -extern "C" { - pub fn arc4random_stir(); -} -extern "C" { - pub fn arc4random_uniform(__upper_bound: u32) -> u32; -} -extern "C" { - pub fn atexit_b(arg1: *mut ::std::os::raw::c_void) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn bsearch_b( - __key: *const ::std::os::raw::c_void, - __base: *const ::std::os::raw::c_void, - __nel: usize, - __width: usize, - __compar: *mut ::std::os::raw::c_void, - ) -> *mut ::std::os::raw::c_void; -} -extern "C" { - pub fn cgetcap( - arg1: *mut ::std::os::raw::c_char, - arg2: *const ::std::os::raw::c_char, - arg3: ::std::os::raw::c_int, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn cgetclose() -> ::std::os::raw::c_int; -} -extern "C" { - pub fn cgetent( - arg1: *mut *mut ::std::os::raw::c_char, - arg2: *mut *mut ::std::os::raw::c_char, - arg3: *const ::std::os::raw::c_char, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn cgetfirst( - arg1: *mut *mut ::std::os::raw::c_char, - arg2: *mut *mut ::std::os::raw::c_char, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn cgetmatch( - arg1: *const ::std::os::raw::c_char, - arg2: *const ::std::os::raw::c_char, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn cgetnext( - arg1: *mut *mut ::std::os::raw::c_char, - arg2: *mut *mut ::std::os::raw::c_char, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn cgetnum( - arg1: *mut ::std::os::raw::c_char, - arg2: *const ::std::os::raw::c_char, - arg3: *mut ::std::os::raw::c_long, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn cgetset(arg1: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn cgetstr( - arg1: *mut ::std::os::raw::c_char, - arg2: *const ::std::os::raw::c_char, - arg3: *mut *mut ::std::os::raw::c_char, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn cgetustr( - arg1: *mut ::std::os::raw::c_char, - arg2: *const ::std::os::raw::c_char, - arg3: *mut *mut ::std::os::raw::c_char, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn daemon( - arg1: ::std::os::raw::c_int, - arg2: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn devname(arg1: dev_t, arg2: mode_t) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn devname_r( - arg1: dev_t, - arg2: mode_t, - buf: *mut ::std::os::raw::c_char, - len: ::std::os::raw::c_int, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn getbsize( - arg1: *mut ::std::os::raw::c_int, - arg2: *mut ::std::os::raw::c_long, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn getloadavg(arg1: *mut f64, arg2: ::std::os::raw::c_int) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn getprogname() -> *const ::std::os::raw::c_char; -} -extern "C" { - pub fn setprogname(arg1: *const ::std::os::raw::c_char); +#[test] +fn bindgen_test_layout_OrtOpenVINOProviderOptions() { + assert_eq!( + ::std::mem::size_of::(), + 56usize, + concat!("Size of: ", stringify!(OrtOpenVINOProviderOptions)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(OrtOpenVINOProviderOptions)) + ); + fn test_field_device_type() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).device_type) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtOpenVINOProviderOptions), + "::", + stringify!(device_type) + ) + ); + } + test_field_device_type(); + fn test_field_enable_vpu_fast_compile() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).enable_vpu_fast_compile) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtOpenVINOProviderOptions), + "::", + stringify!(enable_vpu_fast_compile) + ) + ); + } + test_field_enable_vpu_fast_compile(); + fn test_field_device_id() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).device_id) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(OrtOpenVINOProviderOptions), + "::", + stringify!(device_id) + ) + ); + } + test_field_device_id(); + fn test_field_num_of_threads() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).num_of_threads) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(OrtOpenVINOProviderOptions), + "::", + stringify!(num_of_threads) + ) + ); + } + test_field_num_of_threads(); + fn test_field_use_compiled_network() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).use_compiled_network) as usize - ptr as usize + }, + 32usize, + concat!( + "Offset of field: ", + stringify!(OrtOpenVINOProviderOptions), + "::", + stringify!(use_compiled_network) + ) + ); + } + test_field_use_compiled_network(); + fn test_field_blob_dump_path() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).blob_dump_path) as usize - ptr as usize + }, + 40usize, + concat!( + "Offset of field: ", + stringify!(OrtOpenVINOProviderOptions), + "::", + stringify!(blob_dump_path) + ) + ); + } + test_field_blob_dump_path(); + fn test_field_context() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).context) as usize - ptr as usize + }, + 48usize, + concat!( + "Offset of field: ", + stringify!(OrtOpenVINOProviderOptions), + "::", + stringify!(context) + ) + ); + } + test_field_context(); } -extern "C" { - pub fn heapsort( - __base: *mut ::std::os::raw::c_void, - __nel: usize, - __width: usize, - __compar: ::std::option::Option< - unsafe extern "C" fn( - arg1: *const ::std::os::raw::c_void, - arg2: *const ::std::os::raw::c_void, - ) -> ::std::os::raw::c_int, - >, - ) -> ::std::os::raw::c_int; +#[doc = " \\brief The helper interface to get the right version of OrtApi"] +#[doc = ""] +#[doc = " Get a pointer to this structure through ::OrtGetApiBase"] +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtApiBase { + #[doc = " \\brief Get a pointer to the requested version of the ::OrtApi"] + #[doc = ""] + #[doc = " \\param[in] version Must be ::ORT_API_VERSION"] + #[doc = " \\return The ::OrtApi for the version requested, nullptr will be returned if this version is unsupported, for example when using a runtime"] + #[doc = " older than the version created with this header file."] + pub GetApi: ::std::option::Option *const OrtApi>, + #[doc = "< Returns a null terminated string of the version of the Onnxruntime library (eg: \"1.8.1\")"] + pub GetVersionString: + ::std::option::Option *const ::std::os::raw::c_char>, } -extern "C" { - pub fn heapsort_b( - __base: *mut ::std::os::raw::c_void, - __nel: usize, - __width: usize, - __compar: *mut ::std::os::raw::c_void, - ) -> ::std::os::raw::c_int; +#[test] +fn bindgen_test_layout_OrtApiBase() { + assert_eq!( + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(OrtApiBase)) + ); + assert_eq!( + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(OrtApiBase)) + ); + fn test_field_GetApi() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetApi) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtApiBase), + "::", + stringify!(GetApi) + ) + ); + } + test_field_GetApi(); + fn test_field_GetVersionString() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetVersionString) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtApiBase), + "::", + stringify!(GetVersionString) + ) + ); + } + test_field_GetVersionString(); } extern "C" { - pub fn mergesort( - __base: *mut ::std::os::raw::c_void, - __nel: usize, - __width: usize, - __compar: ::std::option::Option< - unsafe extern "C" fn( - arg1: *const ::std::os::raw::c_void, - arg2: *const ::std::os::raw::c_void, - ) -> ::std::os::raw::c_int, - >, - ) -> ::std::os::raw::c_int; + #[doc = " \\brief The Onnxruntime library's entry point to access the C API"] + #[doc = ""] + #[doc = " Call this to get the a pointer to an ::OrtApiBase"] + pub fn OrtGetApiBase() -> *const OrtApiBase; } -extern "C" { - pub fn mergesort_b( - __base: *mut ::std::os::raw::c_void, - __nel: usize, - __width: usize, - __compar: *mut ::std::os::raw::c_void, - ) -> ::std::os::raw::c_int; +#[doc = " \\brief Thread work loop function"] +#[doc = ""] +#[doc = " Onnxruntime will provide the working loop on custom thread creation"] +#[doc = " Argument is an onnxruntime built-in type which will be provided when thread pool calls OrtCustomCreateThreadFn"] +pub type OrtThreadWorkerFn = + ::std::option::Option; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtCustomHandleType { + pub __place_holder: ::std::os::raw::c_char, } -extern "C" { - pub fn psort( - __base: *mut ::std::os::raw::c_void, - __nel: usize, - __width: usize, - __compar: ::std::option::Option< - unsafe extern "C" fn( - arg1: *const ::std::os::raw::c_void, - arg2: *const ::std::os::raw::c_void, - ) -> ::std::os::raw::c_int, - >, - ); -} -extern "C" { - pub fn psort_b( - __base: *mut ::std::os::raw::c_void, - __nel: usize, - __width: usize, - __compar: *mut ::std::os::raw::c_void, - ); -} -extern "C" { - pub fn psort_r( - __base: *mut ::std::os::raw::c_void, - __nel: usize, - __width: usize, - arg1: *mut ::std::os::raw::c_void, - __compar: ::std::option::Option< - unsafe extern "C" fn( - arg1: *mut ::std::os::raw::c_void, - arg2: *const ::std::os::raw::c_void, - arg3: *const ::std::os::raw::c_void, - ) -> ::std::os::raw::c_int, - >, - ); -} -extern "C" { - pub fn qsort_b( - __base: *mut ::std::os::raw::c_void, - __nel: usize, - __width: usize, - __compar: *mut ::std::os::raw::c_void, - ); -} -extern "C" { - pub fn qsort_r( - __base: *mut ::std::os::raw::c_void, - __nel: usize, - __width: usize, - arg1: *mut ::std::os::raw::c_void, - __compar: ::std::option::Option< - unsafe extern "C" fn( - arg1: *mut ::std::os::raw::c_void, - arg2: *const ::std::os::raw::c_void, - arg3: *const ::std::os::raw::c_void, - ) -> ::std::os::raw::c_int, - >, - ); -} -extern "C" { - pub fn radixsort( - __base: *mut *const ::std::os::raw::c_uchar, - __nel: ::std::os::raw::c_int, - __table: *const ::std::os::raw::c_uchar, - __endbyte: ::std::os::raw::c_uint, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn rpmatch(arg1: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn sradixsort( - __base: *mut *const ::std::os::raw::c_uchar, - __nel: ::std::os::raw::c_int, - __table: *const ::std::os::raw::c_uchar, - __endbyte: ::std::os::raw::c_uint, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn sranddev(); -} -extern "C" { - pub fn srandomdev(); -} -extern "C" { - pub fn reallocf( - __ptr: *mut ::std::os::raw::c_void, - __size: usize, - ) -> *mut ::std::os::raw::c_void; -} -extern "C" { - pub fn strtonum( - __numstr: *const ::std::os::raw::c_char, - __minval: ::std::os::raw::c_longlong, - __maxval: ::std::os::raw::c_longlong, - __errstrp: *mut *const ::std::os::raw::c_char, - ) -> ::std::os::raw::c_longlong; -} -extern "C" { - pub fn strtoq( - __str: *const ::std::os::raw::c_char, - __endptr: *mut *mut ::std::os::raw::c_char, - __base: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_longlong; -} -extern "C" { - pub fn strtouq( - __str: *const ::std::os::raw::c_char, - __endptr: *mut *mut ::std::os::raw::c_char, - __base: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_ulonglong; -} -extern "C" { - pub static mut suboptarg: *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn memchr( - __s: *const ::std::os::raw::c_void, - __c: ::std::os::raw::c_int, - __n: ::std::os::raw::c_ulong, - ) -> *mut ::std::os::raw::c_void; -} -extern "C" { - pub fn memcmp( - __s1: *const ::std::os::raw::c_void, - __s2: *const ::std::os::raw::c_void, - __n: ::std::os::raw::c_ulong, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn memcpy( - __dst: *mut ::std::os::raw::c_void, - __src: *const ::std::os::raw::c_void, - __n: ::std::os::raw::c_ulong, - ) -> *mut ::std::os::raw::c_void; -} -extern "C" { - pub fn memmove( - __dst: *mut ::std::os::raw::c_void, - __src: *const ::std::os::raw::c_void, - __len: ::std::os::raw::c_ulong, - ) -> *mut ::std::os::raw::c_void; -} -extern "C" { - pub fn memset( - __b: *mut ::std::os::raw::c_void, - __c: ::std::os::raw::c_int, - __len: ::std::os::raw::c_ulong, - ) -> *mut ::std::os::raw::c_void; -} -extern "C" { - pub fn strcat( - __s1: *mut ::std::os::raw::c_char, - __s2: *const ::std::os::raw::c_char, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strchr( - __s: *const ::std::os::raw::c_char, - __c: ::std::os::raw::c_int, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strcmp( - __s1: *const ::std::os::raw::c_char, - __s2: *const ::std::os::raw::c_char, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn strcoll( - __s1: *const ::std::os::raw::c_char, - __s2: *const ::std::os::raw::c_char, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn strcpy( - __dst: *mut ::std::os::raw::c_char, - __src: *const ::std::os::raw::c_char, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strcspn( - __s: *const ::std::os::raw::c_char, - __charset: *const ::std::os::raw::c_char, - ) -> ::std::os::raw::c_ulong; -} -extern "C" { - pub fn strerror(__errnum: ::std::os::raw::c_int) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strlen(__s: *const ::std::os::raw::c_char) -> ::std::os::raw::c_ulong; -} -extern "C" { - pub fn strncat( - __s1: *mut ::std::os::raw::c_char, - __s2: *const ::std::os::raw::c_char, - __n: ::std::os::raw::c_ulong, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strncmp( - __s1: *const ::std::os::raw::c_char, - __s2: *const ::std::os::raw::c_char, - __n: ::std::os::raw::c_ulong, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn strncpy( - __dst: *mut ::std::os::raw::c_char, - __src: *const ::std::os::raw::c_char, - __n: ::std::os::raw::c_ulong, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strpbrk( - __s: *const ::std::os::raw::c_char, - __charset: *const ::std::os::raw::c_char, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strrchr( - __s: *const ::std::os::raw::c_char, - __c: ::std::os::raw::c_int, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strspn( - __s: *const ::std::os::raw::c_char, - __charset: *const ::std::os::raw::c_char, - ) -> ::std::os::raw::c_ulong; -} -extern "C" { - pub fn strstr( - __big: *const ::std::os::raw::c_char, - __little: *const ::std::os::raw::c_char, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strtok( - __str: *mut ::std::os::raw::c_char, - __sep: *const ::std::os::raw::c_char, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strxfrm( - __s1: *mut ::std::os::raw::c_char, - __s2: *const ::std::os::raw::c_char, - __n: ::std::os::raw::c_ulong, - ) -> ::std::os::raw::c_ulong; -} -extern "C" { - pub fn strtok_r( - __str: *mut ::std::os::raw::c_char, - __sep: *const ::std::os::raw::c_char, - __lasts: *mut *mut ::std::os::raw::c_char, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strerror_r( - __errnum: ::std::os::raw::c_int, - __strerrbuf: *mut ::std::os::raw::c_char, - __buflen: usize, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn strdup(__s1: *const ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn memccpy( - __dst: *mut ::std::os::raw::c_void, - __src: *const ::std::os::raw::c_void, - __c: ::std::os::raw::c_int, - __n: ::std::os::raw::c_ulong, - ) -> *mut ::std::os::raw::c_void; -} -extern "C" { - pub fn stpcpy( - __dst: *mut ::std::os::raw::c_char, - __src: *const ::std::os::raw::c_char, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn stpncpy( - __dst: *mut ::std::os::raw::c_char, - __src: *const ::std::os::raw::c_char, - __n: ::std::os::raw::c_ulong, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strndup( - __s1: *const ::std::os::raw::c_char, - __n: ::std::os::raw::c_ulong, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strnlen(__s1: *const ::std::os::raw::c_char, __n: usize) -> usize; -} -extern "C" { - pub fn strsignal(__sig: ::std::os::raw::c_int) -> *mut ::std::os::raw::c_char; -} -pub type rsize_t = __darwin_size_t; -pub type errno_t = ::std::os::raw::c_int; -extern "C" { - pub fn memset_s( - __s: *mut ::std::os::raw::c_void, - __smax: rsize_t, - __c: ::std::os::raw::c_int, - __n: rsize_t, - ) -> errno_t; -} -extern "C" { - pub fn memmem( - __big: *const ::std::os::raw::c_void, - __big_len: usize, - __little: *const ::std::os::raw::c_void, - __little_len: usize, - ) -> *mut ::std::os::raw::c_void; -} -extern "C" { - pub fn memset_pattern4( - __b: *mut ::std::os::raw::c_void, - __pattern4: *const ::std::os::raw::c_void, - __len: usize, - ); -} -extern "C" { - pub fn memset_pattern8( - __b: *mut ::std::os::raw::c_void, - __pattern8: *const ::std::os::raw::c_void, - __len: usize, - ); -} -extern "C" { - pub fn memset_pattern16( - __b: *mut ::std::os::raw::c_void, - __pattern16: *const ::std::os::raw::c_void, - __len: usize, - ); -} -extern "C" { - pub fn strcasestr( - __big: *const ::std::os::raw::c_char, - __little: *const ::std::os::raw::c_char, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strnstr( - __big: *const ::std::os::raw::c_char, - __little: *const ::std::os::raw::c_char, - __len: usize, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strlcat( - __dst: *mut ::std::os::raw::c_char, - __source: *const ::std::os::raw::c_char, - __size: ::std::os::raw::c_ulong, - ) -> ::std::os::raw::c_ulong; -} -extern "C" { - pub fn strlcpy( - __dst: *mut ::std::os::raw::c_char, - __source: *const ::std::os::raw::c_char, - __size: ::std::os::raw::c_ulong, - ) -> ::std::os::raw::c_ulong; -} -extern "C" { - pub fn strmode(__mode: ::std::os::raw::c_int, __bp: *mut ::std::os::raw::c_char); -} -extern "C" { - pub fn strsep( - __stringp: *mut *mut ::std::os::raw::c_char, - __delim: *const ::std::os::raw::c_char, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn swab( - arg1: *const ::std::os::raw::c_void, - arg2: *mut ::std::os::raw::c_void, - arg3: isize, - ); -} -extern "C" { - pub fn timingsafe_bcmp( - __b1: *const ::std::os::raw::c_void, - __b2: *const ::std::os::raw::c_void, - __len: usize, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn strsignal_r( - __sig: ::std::os::raw::c_int, - __strsignalbuf: *mut ::std::os::raw::c_char, - __buflen: usize, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn bcmp( - arg1: *const ::std::os::raw::c_void, - arg2: *const ::std::os::raw::c_void, - arg3: ::std::os::raw::c_ulong, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn bcopy( - arg1: *const ::std::os::raw::c_void, - arg2: *mut ::std::os::raw::c_void, - arg3: usize, - ); -} -extern "C" { - pub fn bzero(arg1: *mut ::std::os::raw::c_void, arg2: ::std::os::raw::c_ulong); -} -extern "C" { - pub fn index( - arg1: *const ::std::os::raw::c_char, - arg2: ::std::os::raw::c_int, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn rindex( - arg1: *const ::std::os::raw::c_char, - arg2: ::std::os::raw::c_int, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn ffs(arg1: ::std::os::raw::c_int) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn strcasecmp( - arg1: *const ::std::os::raw::c_char, - arg2: *const ::std::os::raw::c_char, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn strncasecmp( - arg1: *const ::std::os::raw::c_char, - arg2: *const ::std::os::raw::c_char, - arg3: ::std::os::raw::c_ulong, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn ffsl(arg1: ::std::os::raw::c_long) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn ffsll(arg1: ::std::os::raw::c_longlong) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn fls(arg1: ::std::os::raw::c_int) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn flsl(arg1: ::std::os::raw::c_long) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn flsll(arg1: ::std::os::raw::c_longlong) -> ::std::os::raw::c_int; -} -#[repr(u32)] -#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum ONNXTensorElementDataType { - ONNX_TENSOR_ELEMENT_DATA_TYPE_UNDEFINED = 0, - ONNX_TENSOR_ELEMENT_DATA_TYPE_FLOAT = 1, - ONNX_TENSOR_ELEMENT_DATA_TYPE_UINT8 = 2, - ONNX_TENSOR_ELEMENT_DATA_TYPE_INT8 = 3, - ONNX_TENSOR_ELEMENT_DATA_TYPE_UINT16 = 4, - ONNX_TENSOR_ELEMENT_DATA_TYPE_INT16 = 5, - ONNX_TENSOR_ELEMENT_DATA_TYPE_INT32 = 6, - ONNX_TENSOR_ELEMENT_DATA_TYPE_INT64 = 7, - ONNX_TENSOR_ELEMENT_DATA_TYPE_STRING = 8, - ONNX_TENSOR_ELEMENT_DATA_TYPE_BOOL = 9, - ONNX_TENSOR_ELEMENT_DATA_TYPE_FLOAT16 = 10, - ONNX_TENSOR_ELEMENT_DATA_TYPE_DOUBLE = 11, - ONNX_TENSOR_ELEMENT_DATA_TYPE_UINT32 = 12, - ONNX_TENSOR_ELEMENT_DATA_TYPE_UINT64 = 13, - ONNX_TENSOR_ELEMENT_DATA_TYPE_COMPLEX64 = 14, - ONNX_TENSOR_ELEMENT_DATA_TYPE_COMPLEX128 = 15, - ONNX_TENSOR_ELEMENT_DATA_TYPE_BFLOAT16 = 16, -} -#[repr(u32)] -#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum ONNXType { - ONNX_TYPE_UNKNOWN = 0, - ONNX_TYPE_TENSOR = 1, - ONNX_TYPE_SEQUENCE = 2, - ONNX_TYPE_MAP = 3, - ONNX_TYPE_OPAQUE = 4, - ONNX_TYPE_SPARSETENSOR = 5, -} -#[repr(u32)] -#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum OrtLoggingLevel { - ORT_LOGGING_LEVEL_VERBOSE = 0, - ORT_LOGGING_LEVEL_INFO = 1, - ORT_LOGGING_LEVEL_WARNING = 2, - ORT_LOGGING_LEVEL_ERROR = 3, - ORT_LOGGING_LEVEL_FATAL = 4, -} -#[repr(u32)] -#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum OrtErrorCode { - ORT_OK = 0, - ORT_FAIL = 1, - ORT_INVALID_ARGUMENT = 2, - ORT_NO_SUCHFILE = 3, - ORT_NO_MODEL = 4, - ORT_ENGINE_ERROR = 5, - ORT_RUNTIME_EXCEPTION = 6, - ORT_INVALID_PROTOBUF = 7, - ORT_MODEL_LOADED = 8, - ORT_NOT_IMPLEMENTED = 9, - ORT_INVALID_GRAPH = 10, - ORT_EP_FAIL = 11, -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtEnv { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtStatus { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtMemoryInfo { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtIoBinding { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtSession { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtValue { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtRunOptions { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtTypeInfo { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtTensorTypeAndShapeInfo { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtSessionOptions { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtCustomOpDomain { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtMapTypeInfo { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtSequenceTypeInfo { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtModelMetadata { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtThreadPoolParams { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtThreadingOptions { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtArenaCfg { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtPrepackedWeightsContainer { - _unused: [u8; 0], -} -pub type OrtStatusPtr = *mut OrtStatus; -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtAllocator { - pub version: u32, - pub Alloc: ::std::option::Option< - unsafe extern "C" fn(this_: *mut OrtAllocator, size: usize) -> *mut ::std::os::raw::c_void, - >, - pub Free: ::std::option::Option< - unsafe extern "C" fn(this_: *mut OrtAllocator, p: *mut ::std::os::raw::c_void), - >, - pub Info: ::std::option::Option< - unsafe extern "C" fn(this_: *const OrtAllocator) -> *const OrtMemoryInfo, - >, -} -#[test] -fn bindgen_test_layout_OrtAllocator() { - assert_eq!( - ::std::mem::size_of::(), - 32usize, - concat!("Size of: ", stringify!(OrtAllocator)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(OrtAllocator)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).version as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtAllocator), - "::", - stringify!(version) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).Alloc as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtAllocator), - "::", - stringify!(Alloc) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).Free as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(OrtAllocator), - "::", - stringify!(Free) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).Info as *const _ as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(OrtAllocator), - "::", - stringify!(Info) - ) - ); -} -pub type OrtLoggingFunction = ::std::option::Option< - unsafe extern "C" fn( - param: *mut ::std::os::raw::c_void, - severity: OrtLoggingLevel, - category: *const ::std::os::raw::c_char, - logid: *const ::std::os::raw::c_char, - code_location: *const ::std::os::raw::c_char, - message: *const ::std::os::raw::c_char, - ), ->; -#[repr(u32)] -#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum GraphOptimizationLevel { - ORT_DISABLE_ALL = 0, - ORT_ENABLE_BASIC = 1, - ORT_ENABLE_EXTENDED = 2, - ORT_ENABLE_ALL = 99, -} -#[repr(u32)] -#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum ExecutionMode { - ORT_SEQUENTIAL = 0, - ORT_PARALLEL = 1, -} -#[repr(u32)] -#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum OrtLanguageProjection { - ORT_PROJECTION_C = 0, - ORT_PROJECTION_CPLUSPLUS = 1, - ORT_PROJECTION_CSHARP = 2, - ORT_PROJECTION_PYTHON = 3, - ORT_PROJECTION_JAVA = 4, - ORT_PROJECTION_WINML = 5, - ORT_PROJECTION_NODEJS = 6, -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtKernelInfo { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtKernelContext { - _unused: [u8; 0], -} -#[repr(i32)] -#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum OrtAllocatorType { - Invalid = -1, - OrtDeviceAllocator = 0, - OrtArenaAllocator = 1, -} -impl OrtMemType { - pub const OrtMemTypeCPU: OrtMemType = OrtMemType::OrtMemTypeCPUOutput; -} -#[repr(i32)] -#[doc = " memory types for allocator, exec provider specific types should be extended in each provider"] -#[doc = " Whenever this struct is updated, please also update the MakeKey function in onnxruntime/core/framework/execution_provider.cc"] -#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum OrtMemType { - OrtMemTypeCPUInput = -2, - OrtMemTypeCPUOutput = -1, - OrtMemTypeDefault = 0, -} -#[repr(u32)] -#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum OrtCudnnConvAlgoSearch { - EXHAUSTIVE = 0, - HEURISTIC = 1, - DEFAULT = 2, -} -#[doc = " "] -#[doc = " Options for the CUDA provider that are passed to SessionOptionsAppendExecutionProvider_CUDA"] -#[doc = " "] -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtCUDAProviderOptions { - pub device_id: ::std::os::raw::c_int, - pub cudnn_conv_algo_search: OrtCudnnConvAlgoSearch, - pub gpu_mem_limit: usize, - pub arena_extend_strategy: ::std::os::raw::c_int, - pub do_copy_in_default_stream: ::std::os::raw::c_int, - pub has_user_compute_stream: ::std::os::raw::c_int, - pub user_compute_stream: *mut ::std::os::raw::c_void, - pub default_memory_arena_cfg: *mut OrtArenaCfg, -} -#[test] -fn bindgen_test_layout_OrtCUDAProviderOptions() { - assert_eq!( - ::std::mem::size_of::(), - 48usize, - concat!("Size of: ", stringify!(OrtCUDAProviderOptions)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(OrtCUDAProviderOptions)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).device_id as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(device_id) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).cudnn_conv_algo_search as *const _ - as usize - }, - 4usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(cudnn_conv_algo_search) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).gpu_mem_limit as *const _ as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(gpu_mem_limit) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).arena_extend_strategy as *const _ - as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(arena_extend_strategy) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).do_copy_in_default_stream as *const _ - as usize - }, - 20usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(do_copy_in_default_stream) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).has_user_compute_stream as *const _ - as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(has_user_compute_stream) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).user_compute_stream as *const _ - as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(user_compute_stream) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).default_memory_arena_cfg as *const _ - as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(default_memory_arena_cfg) - ) - ); -} -#[doc = " "] -#[doc = " Options for the ROCM provider that are passed to SessionOptionsAppendExecutionProvider_ROCM"] -#[doc = " "] -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtROCMProviderOptions { - pub device_id: ::std::os::raw::c_int, - pub miopen_conv_exhaustive_search: ::std::os::raw::c_int, - pub gpu_mem_limit: usize, - pub arena_extend_strategy: ::std::os::raw::c_int, -} -#[test] -fn bindgen_test_layout_OrtROCMProviderOptions() { - assert_eq!( - ::std::mem::size_of::(), - 24usize, - concat!("Size of: ", stringify!(OrtROCMProviderOptions)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(OrtROCMProviderOptions)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).device_id as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtROCMProviderOptions), - "::", - stringify!(device_id) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).miopen_conv_exhaustive_search - as *const _ as usize - }, - 4usize, - concat!( - "Offset of field: ", - stringify!(OrtROCMProviderOptions), - "::", - stringify!(miopen_conv_exhaustive_search) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).gpu_mem_limit as *const _ as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtROCMProviderOptions), - "::", - stringify!(gpu_mem_limit) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).arena_extend_strategy as *const _ - as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(OrtROCMProviderOptions), - "::", - stringify!(arena_extend_strategy) - ) - ); -} -#[doc = " "] -#[doc = " Options for the TensorRT provider that are passed to SessionOptionsAppendExecutionProvider_TensorRT"] -#[doc = " "] -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtTensorRTProviderOptions { - pub device_id: ::std::os::raw::c_int, - pub has_user_compute_stream: ::std::os::raw::c_int, - pub user_compute_stream: *mut ::std::os::raw::c_void, - pub trt_max_partition_iterations: ::std::os::raw::c_int, - pub trt_min_subgraph_size: ::std::os::raw::c_int, - pub trt_max_workspace_size: usize, - pub trt_fp16_enable: ::std::os::raw::c_int, - pub trt_int8_enable: ::std::os::raw::c_int, - pub trt_int8_calibration_table_name: *const ::std::os::raw::c_char, - pub trt_int8_use_native_calibration_table: ::std::os::raw::c_int, - pub trt_dla_enable: ::std::os::raw::c_int, - pub trt_dla_core: ::std::os::raw::c_int, - pub trt_dump_subgraphs: ::std::os::raw::c_int, - pub trt_engine_cache_enable: ::std::os::raw::c_int, - pub trt_engine_cache_path: *const ::std::os::raw::c_char, - pub trt_engine_decryption_enable: ::std::os::raw::c_int, - pub trt_engine_decryption_lib_path: *const ::std::os::raw::c_char, - pub trt_force_sequential_engine_build: ::std::os::raw::c_int, -} -#[test] -fn bindgen_test_layout_OrtTensorRTProviderOptions() { - assert_eq!( - ::std::mem::size_of::(), - 104usize, - concat!("Size of: ", stringify!(OrtTensorRTProviderOptions)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(OrtTensorRTProviderOptions)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).device_id as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(device_id) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).has_user_compute_stream - as *const _ as usize - }, - 4usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(has_user_compute_stream) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).user_compute_stream as *const _ - as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(user_compute_stream) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_max_partition_iterations - as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_max_partition_iterations) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_min_subgraph_size as *const _ - as usize - }, - 20usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_min_subgraph_size) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_max_workspace_size - as *const _ as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_max_workspace_size) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_fp16_enable as *const _ - as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_fp16_enable) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_int8_enable as *const _ - as usize - }, - 36usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_int8_enable) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_int8_calibration_table_name - as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_int8_calibration_table_name) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())) - .trt_int8_use_native_calibration_table as *const _ as usize - }, - 48usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_int8_use_native_calibration_table) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_dla_enable as *const _ - as usize - }, - 52usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_dla_enable) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_dla_core as *const _ as usize - }, - 56usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_dla_core) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_dump_subgraphs as *const _ - as usize - }, - 60usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_dump_subgraphs) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_engine_cache_enable - as *const _ as usize - }, - 64usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_engine_cache_enable) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_engine_cache_path as *const _ - as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_engine_cache_path) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_engine_decryption_enable - as *const _ as usize - }, - 80usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_engine_decryption_enable) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_engine_decryption_lib_path - as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_engine_decryption_lib_path) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_force_sequential_engine_build - as *const _ as usize - }, - 96usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_force_sequential_engine_build) - ) - ); -} -#[doc = " "] -#[doc = " Options for the OpenVINO provider that are passed to SessionOptionsAppendExecutionProvider_OpenVINO"] -#[doc = " "] -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtOpenVINOProviderOptions { - pub device_type: *const ::std::os::raw::c_char, - pub enable_vpu_fast_compile: ::std::os::raw::c_uchar, - pub device_id: *const ::std::os::raw::c_char, - pub num_of_threads: usize, - pub use_compiled_network: ::std::os::raw::c_uchar, - pub blob_dump_path: *const ::std::os::raw::c_char, -} -#[test] -fn bindgen_test_layout_OrtOpenVINOProviderOptions() { - assert_eq!( - ::std::mem::size_of::(), - 48usize, - concat!("Size of: ", stringify!(OrtOpenVINOProviderOptions)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(OrtOpenVINOProviderOptions)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).device_type as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtOpenVINOProviderOptions), - "::", - stringify!(device_type) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).enable_vpu_fast_compile - as *const _ as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtOpenVINOProviderOptions), - "::", - stringify!(enable_vpu_fast_compile) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).device_id as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(OrtOpenVINOProviderOptions), - "::", - stringify!(device_id) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).num_of_threads as *const _ - as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(OrtOpenVINOProviderOptions), - "::", - stringify!(num_of_threads) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).use_compiled_network as *const _ - as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(OrtOpenVINOProviderOptions), - "::", - stringify!(use_compiled_network) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).blob_dump_path as *const _ - as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(OrtOpenVINOProviderOptions), - "::", - stringify!(blob_dump_path) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtApiBase { - pub GetApi: ::std::option::Option *const OrtApi>, - pub GetVersionString: - ::std::option::Option *const ::std::os::raw::c_char>, -} -#[test] -fn bindgen_test_layout_OrtApiBase() { - assert_eq!( - ::std::mem::size_of::(), - 16usize, - concat!("Size of: ", stringify!(OrtApiBase)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(OrtApiBase)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetApi as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtApiBase), - "::", - stringify!(GetApi) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetVersionString as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtApiBase), - "::", - stringify!(GetVersionString) - ) - ); -} -extern "C" { - pub fn OrtGetApiBase() -> *const OrtApiBase; -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtApi { - #[doc = " \\param msg A null-terminated string. Its content will be copied into the newly created OrtStatus"] - pub CreateStatus: ::std::option::Option< - unsafe extern "C" fn( - code: OrtErrorCode, - msg: *const ::std::os::raw::c_char, - ) -> *mut OrtStatus, - >, - pub GetErrorCode: - ::std::option::Option OrtErrorCode>, - #[doc = " \\param status must not be NULL"] - #[doc = " \\return The error message inside the `status`. Do not free the returned value."] - pub GetErrorMessage: ::std::option::Option< - unsafe extern "C" fn(status: *const OrtStatus) -> *const ::std::os::raw::c_char, - >, - pub CreateEnv: ::std::option::Option< - unsafe extern "C" fn( - logging_level: OrtLoggingLevel, - logid: *const ::std::os::raw::c_char, - out: *mut *mut OrtEnv, - ) -> OrtStatusPtr, - >, - pub CreateEnvWithCustomLogger: ::std::option::Option< - unsafe extern "C" fn( - logging_function: OrtLoggingFunction, - logger_param: *mut ::std::os::raw::c_void, - logging_level: OrtLoggingLevel, - logid: *const ::std::os::raw::c_char, - out: *mut *mut OrtEnv, - ) -> OrtStatusPtr, - >, - pub EnableTelemetryEvents: - ::std::option::Option OrtStatusPtr>, - pub DisableTelemetryEvents: - ::std::option::Option OrtStatusPtr>, - pub CreateSession: ::std::option::Option< - unsafe extern "C" fn( - env: *const OrtEnv, - model_path: *const ::std::os::raw::c_char, - options: *const OrtSessionOptions, - out: *mut *mut OrtSession, - ) -> OrtStatusPtr, - >, - pub CreateSessionFromArray: ::std::option::Option< - unsafe extern "C" fn( - env: *const OrtEnv, - model_data: *const ::std::os::raw::c_void, - model_data_length: usize, - options: *const OrtSessionOptions, - out: *mut *mut OrtSession, - ) -> OrtStatusPtr, - >, - pub Run: ::std::option::Option< - unsafe extern "C" fn( - sess: *mut OrtSession, - run_options: *const OrtRunOptions, - input_names: *const *const ::std::os::raw::c_char, - input: *const *const OrtValue, - input_len: usize, - output_names1: *const *const ::std::os::raw::c_char, - output_names_len: usize, - output: *mut *mut OrtValue, - ) -> OrtStatusPtr, - >, - pub CreateSessionOptions: ::std::option::Option< - unsafe extern "C" fn(options: *mut *mut OrtSessionOptions) -> OrtStatusPtr, - >, - pub SetOptimizedModelFilePath: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - optimized_model_filepath: *const ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub CloneSessionOptions: ::std::option::Option< - unsafe extern "C" fn( - in_options: *const OrtSessionOptions, - out_options: *mut *mut OrtSessionOptions, - ) -> OrtStatusPtr, - >, - pub SetSessionExecutionMode: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - execution_mode: ExecutionMode, - ) -> OrtStatusPtr, - >, - pub EnableProfiling: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - profile_file_prefix: *const ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub DisableProfiling: ::std::option::Option< - unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, - >, - pub EnableMemPattern: ::std::option::Option< - unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, - >, - pub DisableMemPattern: ::std::option::Option< - unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, - >, - pub EnableCpuMemArena: ::std::option::Option< - unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, - >, - pub DisableCpuMemArena: ::std::option::Option< - unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, - >, - pub SetSessionLogId: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - logid: *const ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub SetSessionLogVerbosityLevel: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - session_log_verbosity_level: ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub SetSessionLogSeverityLevel: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - session_log_severity_level: ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub SetSessionGraphOptimizationLevel: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - graph_optimization_level: GraphOptimizationLevel, - ) -> OrtStatusPtr, - >, - pub SetIntraOpNumThreads: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - intra_op_num_threads: ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub SetInterOpNumThreads: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - inter_op_num_threads: ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub CreateCustomOpDomain: ::std::option::Option< - unsafe extern "C" fn( - domain: *const ::std::os::raw::c_char, - out: *mut *mut OrtCustomOpDomain, - ) -> OrtStatusPtr, - >, - pub CustomOpDomain_Add: ::std::option::Option< - unsafe extern "C" fn( - custom_op_domain: *mut OrtCustomOpDomain, - op: *const OrtCustomOp, - ) -> OrtStatusPtr, - >, - pub AddCustomOpDomain: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - custom_op_domain: *mut OrtCustomOpDomain, - ) -> OrtStatusPtr, - >, - pub RegisterCustomOpsLibrary: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - library_path: *const ::std::os::raw::c_char, - library_handle: *mut *mut ::std::os::raw::c_void, - ) -> OrtStatusPtr, - >, - pub SessionGetInputCount: ::std::option::Option< - unsafe extern "C" fn(sess: *const OrtSession, out: *mut usize) -> OrtStatusPtr, - >, - pub SessionGetOutputCount: ::std::option::Option< - unsafe extern "C" fn(sess: *const OrtSession, out: *mut usize) -> OrtStatusPtr, - >, - pub SessionGetOverridableInitializerCount: ::std::option::Option< - unsafe extern "C" fn(sess: *const OrtSession, out: *mut usize) -> OrtStatusPtr, - >, - pub SessionGetInputTypeInfo: ::std::option::Option< - unsafe extern "C" fn( - sess: *const OrtSession, - index: usize, - type_info: *mut *mut OrtTypeInfo, - ) -> OrtStatusPtr, - >, - pub SessionGetOutputTypeInfo: ::std::option::Option< - unsafe extern "C" fn( - sess: *const OrtSession, - index: usize, - type_info: *mut *mut OrtTypeInfo, - ) -> OrtStatusPtr, - >, - pub SessionGetOverridableInitializerTypeInfo: ::std::option::Option< - unsafe extern "C" fn( - sess: *const OrtSession, - index: usize, - type_info: *mut *mut OrtTypeInfo, - ) -> OrtStatusPtr, - >, - pub SessionGetInputName: ::std::option::Option< - unsafe extern "C" fn( - sess: *const OrtSession, - index: usize, - allocator: *mut OrtAllocator, - value: *mut *mut ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub SessionGetOutputName: ::std::option::Option< - unsafe extern "C" fn( - sess: *const OrtSession, - index: usize, - allocator: *mut OrtAllocator, - value: *mut *mut ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub SessionGetOverridableInitializerName: ::std::option::Option< - unsafe extern "C" fn( - sess: *const OrtSession, - index: usize, - allocator: *mut OrtAllocator, - value: *mut *mut ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub CreateRunOptions: - ::std::option::Option OrtStatusPtr>, - pub RunOptionsSetRunLogVerbosityLevel: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtRunOptions, - value: ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub RunOptionsSetRunLogSeverityLevel: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtRunOptions, - value: ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub RunOptionsSetRunTag: ::std::option::Option< - unsafe extern "C" fn( - arg1: *mut OrtRunOptions, - run_tag: *const ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub RunOptionsGetRunLogVerbosityLevel: ::std::option::Option< - unsafe extern "C" fn( - options: *const OrtRunOptions, - out: *mut ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub RunOptionsGetRunLogSeverityLevel: ::std::option::Option< - unsafe extern "C" fn( - options: *const OrtRunOptions, - out: *mut ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub RunOptionsGetRunTag: ::std::option::Option< - unsafe extern "C" fn( - arg1: *const OrtRunOptions, - out: *mut *const ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub RunOptionsSetTerminate: - ::std::option::Option OrtStatusPtr>, - pub RunOptionsUnsetTerminate: - ::std::option::Option OrtStatusPtr>, - pub CreateTensorAsOrtValue: ::std::option::Option< - unsafe extern "C" fn( - allocator: *mut OrtAllocator, - shape: *const i64, - shape_len: usize, - type_: ONNXTensorElementDataType, - out: *mut *mut OrtValue, - ) -> OrtStatusPtr, - >, - pub CreateTensorWithDataAsOrtValue: ::std::option::Option< - unsafe extern "C" fn( - info: *const OrtMemoryInfo, - p_data: *mut ::std::os::raw::c_void, - p_data_len: usize, - shape: *const i64, - shape_len: usize, - type_: ONNXTensorElementDataType, - out: *mut *mut OrtValue, - ) -> OrtStatusPtr, - >, - pub IsTensor: ::std::option::Option< - unsafe extern "C" fn( - value: *const OrtValue, - out: *mut ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub GetTensorMutableData: ::std::option::Option< - unsafe extern "C" fn( - value: *mut OrtValue, - out: *mut *mut ::std::os::raw::c_void, - ) -> OrtStatusPtr, - >, - pub FillStringTensor: ::std::option::Option< - unsafe extern "C" fn( - value: *mut OrtValue, - s: *const *const ::std::os::raw::c_char, - s_len: usize, - ) -> OrtStatusPtr, - >, - pub GetStringTensorDataLength: ::std::option::Option< - unsafe extern "C" fn(value: *const OrtValue, len: *mut usize) -> OrtStatusPtr, - >, - pub GetStringTensorContent: ::std::option::Option< - unsafe extern "C" fn( - value: *const OrtValue, - s: *mut ::std::os::raw::c_void, - s_len: usize, - offsets: *mut usize, - offsets_len: usize, - ) -> OrtStatusPtr, - >, - pub CastTypeInfoToTensorInfo: ::std::option::Option< - unsafe extern "C" fn( - arg1: *const OrtTypeInfo, - out: *mut *const OrtTensorTypeAndShapeInfo, - ) -> OrtStatusPtr, - >, - pub GetOnnxTypeFromTypeInfo: ::std::option::Option< - unsafe extern "C" fn(arg1: *const OrtTypeInfo, out: *mut ONNXType) -> OrtStatusPtr, - >, - pub CreateTensorTypeAndShapeInfo: ::std::option::Option< - unsafe extern "C" fn(out: *mut *mut OrtTensorTypeAndShapeInfo) -> OrtStatusPtr, - >, - pub SetTensorElementType: ::std::option::Option< - unsafe extern "C" fn( - arg1: *mut OrtTensorTypeAndShapeInfo, - type_: ONNXTensorElementDataType, - ) -> OrtStatusPtr, - >, - pub SetDimensions: ::std::option::Option< - unsafe extern "C" fn( - info: *mut OrtTensorTypeAndShapeInfo, - dim_values: *const i64, - dim_count: usize, - ) -> OrtStatusPtr, - >, - pub GetTensorElementType: ::std::option::Option< - unsafe extern "C" fn( - arg1: *const OrtTensorTypeAndShapeInfo, - out: *mut ONNXTensorElementDataType, - ) -> OrtStatusPtr, - >, - pub GetDimensionsCount: ::std::option::Option< - unsafe extern "C" fn( - info: *const OrtTensorTypeAndShapeInfo, - out: *mut usize, - ) -> OrtStatusPtr, - >, - pub GetDimensions: ::std::option::Option< - unsafe extern "C" fn( - info: *const OrtTensorTypeAndShapeInfo, - dim_values: *mut i64, - dim_values_length: usize, - ) -> OrtStatusPtr, - >, - pub GetSymbolicDimensions: ::std::option::Option< - unsafe extern "C" fn( - info: *const OrtTensorTypeAndShapeInfo, - dim_params: *mut *const ::std::os::raw::c_char, - dim_params_length: usize, - ) -> OrtStatusPtr, - >, - pub GetTensorShapeElementCount: ::std::option::Option< - unsafe extern "C" fn( - info: *const OrtTensorTypeAndShapeInfo, - out: *mut usize, - ) -> OrtStatusPtr, - >, - pub GetTensorTypeAndShape: ::std::option::Option< - unsafe extern "C" fn( - value: *const OrtValue, - out: *mut *mut OrtTensorTypeAndShapeInfo, - ) -> OrtStatusPtr, - >, - pub GetTypeInfo: ::std::option::Option< - unsafe extern "C" fn(value: *const OrtValue, out: *mut *mut OrtTypeInfo) -> OrtStatusPtr, - >, - pub GetValueType: ::std::option::Option< - unsafe extern "C" fn(value: *const OrtValue, out: *mut ONNXType) -> OrtStatusPtr, - >, - pub CreateMemoryInfo: ::std::option::Option< - unsafe extern "C" fn( - name1: *const ::std::os::raw::c_char, - type_: OrtAllocatorType, - id1: ::std::os::raw::c_int, - mem_type1: OrtMemType, - out: *mut *mut OrtMemoryInfo, - ) -> OrtStatusPtr, - >, - pub CreateCpuMemoryInfo: ::std::option::Option< - unsafe extern "C" fn( - type_: OrtAllocatorType, - mem_type1: OrtMemType, - out: *mut *mut OrtMemoryInfo, - ) -> OrtStatusPtr, - >, - pub CompareMemoryInfo: ::std::option::Option< - unsafe extern "C" fn( - info1: *const OrtMemoryInfo, - info2: *const OrtMemoryInfo, - out: *mut ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub MemoryInfoGetName: ::std::option::Option< - unsafe extern "C" fn( - ptr: *const OrtMemoryInfo, - out: *mut *const ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub MemoryInfoGetId: ::std::option::Option< - unsafe extern "C" fn( - ptr: *const OrtMemoryInfo, - out: *mut ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub MemoryInfoGetMemType: ::std::option::Option< - unsafe extern "C" fn(ptr: *const OrtMemoryInfo, out: *mut OrtMemType) -> OrtStatusPtr, - >, - pub MemoryInfoGetType: ::std::option::Option< - unsafe extern "C" fn(ptr: *const OrtMemoryInfo, out: *mut OrtAllocatorType) -> OrtStatusPtr, - >, - pub AllocatorAlloc: ::std::option::Option< - unsafe extern "C" fn( - ptr: *mut OrtAllocator, - size: usize, - out: *mut *mut ::std::os::raw::c_void, - ) -> OrtStatusPtr, - >, - pub AllocatorFree: ::std::option::Option< - unsafe extern "C" fn( - ptr: *mut OrtAllocator, - p: *mut ::std::os::raw::c_void, - ) -> OrtStatusPtr, - >, - pub AllocatorGetInfo: ::std::option::Option< - unsafe extern "C" fn( - ptr: *const OrtAllocator, - out: *mut *const OrtMemoryInfo, - ) -> OrtStatusPtr, - >, - pub GetAllocatorWithDefaultOptions: - ::std::option::Option OrtStatusPtr>, - pub AddFreeDimensionOverride: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - dim_denotation: *const ::std::os::raw::c_char, - dim_value: i64, - ) -> OrtStatusPtr, - >, - pub GetValue: ::std::option::Option< - unsafe extern "C" fn( - value: *const OrtValue, - index: ::std::os::raw::c_int, - allocator: *mut OrtAllocator, - out: *mut *mut OrtValue, - ) -> OrtStatusPtr, - >, - pub GetValueCount: ::std::option::Option< - unsafe extern "C" fn(value: *const OrtValue, out: *mut usize) -> OrtStatusPtr, - >, - pub CreateValue: ::std::option::Option< - unsafe extern "C" fn( - in_: *const *const OrtValue, - num_values: usize, - value_type: ONNXType, - out: *mut *mut OrtValue, - ) -> OrtStatusPtr, - >, - pub CreateOpaqueValue: ::std::option::Option< - unsafe extern "C" fn( - domain_name: *const ::std::os::raw::c_char, - type_name: *const ::std::os::raw::c_char, - data_container: *const ::std::os::raw::c_void, - data_container_size: usize, - out: *mut *mut OrtValue, - ) -> OrtStatusPtr, - >, - pub GetOpaqueValue: ::std::option::Option< - unsafe extern "C" fn( - domain_name: *const ::std::os::raw::c_char, - type_name: *const ::std::os::raw::c_char, - in_: *const OrtValue, - data_container: *mut ::std::os::raw::c_void, - data_container_size: usize, - ) -> OrtStatusPtr, - >, - pub KernelInfoGetAttribute_float: ::std::option::Option< - unsafe extern "C" fn( - info: *const OrtKernelInfo, - name: *const ::std::os::raw::c_char, - out: *mut f32, - ) -> OrtStatusPtr, - >, - pub KernelInfoGetAttribute_int64: ::std::option::Option< - unsafe extern "C" fn( - info: *const OrtKernelInfo, - name: *const ::std::os::raw::c_char, - out: *mut i64, - ) -> OrtStatusPtr, - >, - pub KernelInfoGetAttribute_string: ::std::option::Option< - unsafe extern "C" fn( - info: *const OrtKernelInfo, - name: *const ::std::os::raw::c_char, - out: *mut ::std::os::raw::c_char, - size: *mut usize, - ) -> OrtStatusPtr, - >, - pub KernelContext_GetInputCount: ::std::option::Option< - unsafe extern "C" fn(context: *const OrtKernelContext, out: *mut usize) -> OrtStatusPtr, - >, - pub KernelContext_GetOutputCount: ::std::option::Option< - unsafe extern "C" fn(context: *const OrtKernelContext, out: *mut usize) -> OrtStatusPtr, - >, - pub KernelContext_GetInput: ::std::option::Option< - unsafe extern "C" fn( - context: *const OrtKernelContext, - index: usize, - out: *mut *const OrtValue, - ) -> OrtStatusPtr, - >, - pub KernelContext_GetOutput: ::std::option::Option< - unsafe extern "C" fn( - context: *mut OrtKernelContext, - index: usize, - dim_values: *const i64, - dim_count: usize, - out: *mut *mut OrtValue, - ) -> OrtStatusPtr, - >, - pub ReleaseEnv: ::std::option::Option, - pub ReleaseStatus: ::std::option::Option, - pub ReleaseMemoryInfo: ::std::option::Option, - pub ReleaseSession: ::std::option::Option, - pub ReleaseValue: ::std::option::Option, - pub ReleaseRunOptions: ::std::option::Option, - pub ReleaseTypeInfo: ::std::option::Option, - pub ReleaseTensorTypeAndShapeInfo: - ::std::option::Option, - pub ReleaseSessionOptions: - ::std::option::Option, - pub ReleaseCustomOpDomain: - ::std::option::Option, - pub GetDenotationFromTypeInfo: ::std::option::Option< - unsafe extern "C" fn( - arg1: *const OrtTypeInfo, - denotation: *mut *const ::std::os::raw::c_char, - len: *mut usize, - ) -> OrtStatusPtr, - >, - pub CastTypeInfoToMapTypeInfo: ::std::option::Option< - unsafe extern "C" fn( - type_info: *const OrtTypeInfo, - out: *mut *const OrtMapTypeInfo, - ) -> OrtStatusPtr, - >, - pub CastTypeInfoToSequenceTypeInfo: ::std::option::Option< - unsafe extern "C" fn( - type_info: *const OrtTypeInfo, - out: *mut *const OrtSequenceTypeInfo, - ) -> OrtStatusPtr, - >, - pub GetMapKeyType: ::std::option::Option< - unsafe extern "C" fn( - map_type_info: *const OrtMapTypeInfo, - out: *mut ONNXTensorElementDataType, - ) -> OrtStatusPtr, - >, - pub GetMapValueType: ::std::option::Option< - unsafe extern "C" fn( - map_type_info: *const OrtMapTypeInfo, - type_info: *mut *mut OrtTypeInfo, - ) -> OrtStatusPtr, - >, - pub GetSequenceElementType: ::std::option::Option< - unsafe extern "C" fn( - sequence_type_info: *const OrtSequenceTypeInfo, - type_info: *mut *mut OrtTypeInfo, - ) -> OrtStatusPtr, - >, - pub ReleaseMapTypeInfo: ::std::option::Option, - pub ReleaseSequenceTypeInfo: - ::std::option::Option, - pub SessionEndProfiling: ::std::option::Option< - unsafe extern "C" fn( - sess: *mut OrtSession, - allocator: *mut OrtAllocator, - out: *mut *mut ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub SessionGetModelMetadata: ::std::option::Option< - unsafe extern "C" fn( - sess: *const OrtSession, - out: *mut *mut OrtModelMetadata, - ) -> OrtStatusPtr, - >, - pub ModelMetadataGetProducerName: ::std::option::Option< - unsafe extern "C" fn( - model_metadata: *const OrtModelMetadata, - allocator: *mut OrtAllocator, - value: *mut *mut ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub ModelMetadataGetGraphName: ::std::option::Option< - unsafe extern "C" fn( - model_metadata: *const OrtModelMetadata, - allocator: *mut OrtAllocator, - value: *mut *mut ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub ModelMetadataGetDomain: ::std::option::Option< - unsafe extern "C" fn( - model_metadata: *const OrtModelMetadata, - allocator: *mut OrtAllocator, - value: *mut *mut ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub ModelMetadataGetDescription: ::std::option::Option< - unsafe extern "C" fn( - model_metadata: *const OrtModelMetadata, - allocator: *mut OrtAllocator, - value: *mut *mut ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub ModelMetadataLookupCustomMetadataMap: ::std::option::Option< - unsafe extern "C" fn( - model_metadata: *const OrtModelMetadata, - allocator: *mut OrtAllocator, - key: *const ::std::os::raw::c_char, - value: *mut *mut ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub ModelMetadataGetVersion: ::std::option::Option< - unsafe extern "C" fn( - model_metadata: *const OrtModelMetadata, - value: *mut i64, - ) -> OrtStatusPtr, - >, - pub ReleaseModelMetadata: - ::std::option::Option, - pub CreateEnvWithGlobalThreadPools: ::std::option::Option< - unsafe extern "C" fn( - logging_level: OrtLoggingLevel, - logid: *const ::std::os::raw::c_char, - t_options: *const OrtThreadingOptions, - out: *mut *mut OrtEnv, - ) -> OrtStatusPtr, - >, - pub DisablePerSessionThreads: ::std::option::Option< - unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, - >, - pub CreateThreadingOptions: ::std::option::Option< - unsafe extern "C" fn(out: *mut *mut OrtThreadingOptions) -> OrtStatusPtr, - >, - pub ReleaseThreadingOptions: - ::std::option::Option, - pub ModelMetadataGetCustomMetadataMapKeys: ::std::option::Option< - unsafe extern "C" fn( - model_metadata: *const OrtModelMetadata, - allocator: *mut OrtAllocator, - keys: *mut *mut *mut ::std::os::raw::c_char, - num_keys: *mut i64, - ) -> OrtStatusPtr, - >, - pub AddFreeDimensionOverrideByName: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - dim_name: *const ::std::os::raw::c_char, - dim_value: i64, - ) -> OrtStatusPtr, - >, - pub GetAvailableProviders: ::std::option::Option< - unsafe extern "C" fn( - out_ptr: *mut *mut *mut ::std::os::raw::c_char, - provider_length: *mut ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub ReleaseAvailableProviders: ::std::option::Option< - unsafe extern "C" fn( - ptr: *mut *mut ::std::os::raw::c_char, - providers_length: ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub GetStringTensorElementLength: ::std::option::Option< - unsafe extern "C" fn(value: *const OrtValue, index: usize, out: *mut usize) -> OrtStatusPtr, - >, - pub GetStringTensorElement: ::std::option::Option< - unsafe extern "C" fn( - value: *const OrtValue, - s_len: usize, - index: usize, - s: *mut ::std::os::raw::c_void, - ) -> OrtStatusPtr, - >, - pub FillStringTensorElement: ::std::option::Option< - unsafe extern "C" fn( - value: *mut OrtValue, - s: *const ::std::os::raw::c_char, - index: usize, - ) -> OrtStatusPtr, - >, - pub AddSessionConfigEntry: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - config_key: *const ::std::os::raw::c_char, - config_value: *const ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub CreateAllocator: ::std::option::Option< - unsafe extern "C" fn( - sess: *const OrtSession, - mem_info: *const OrtMemoryInfo, - out: *mut *mut OrtAllocator, - ) -> OrtStatusPtr, - >, - pub ReleaseAllocator: ::std::option::Option, - pub RunWithBinding: ::std::option::Option< - unsafe extern "C" fn( - sess: *mut OrtSession, - run_options: *const OrtRunOptions, - binding_ptr: *const OrtIoBinding, - ) -> OrtStatusPtr, - >, - pub CreateIoBinding: ::std::option::Option< - unsafe extern "C" fn(sess: *mut OrtSession, out: *mut *mut OrtIoBinding) -> OrtStatusPtr, - >, - pub ReleaseIoBinding: ::std::option::Option, - pub BindInput: ::std::option::Option< - unsafe extern "C" fn( - binding_ptr: *mut OrtIoBinding, - name: *const ::std::os::raw::c_char, - val_ptr: *const OrtValue, - ) -> OrtStatusPtr, - >, - pub BindOutput: ::std::option::Option< - unsafe extern "C" fn( - binding_ptr: *mut OrtIoBinding, - name: *const ::std::os::raw::c_char, - val_ptr: *const OrtValue, - ) -> OrtStatusPtr, - >, - pub BindOutputToDevice: ::std::option::Option< - unsafe extern "C" fn( - binding_ptr: *mut OrtIoBinding, - name: *const ::std::os::raw::c_char, - val_ptr: *const OrtMemoryInfo, - ) -> OrtStatusPtr, - >, - pub GetBoundOutputNames: ::std::option::Option< - unsafe extern "C" fn( - binding_ptr: *const OrtIoBinding, - allocator: *mut OrtAllocator, - buffer: *mut *mut ::std::os::raw::c_char, - lengths: *mut *mut usize, - count: *mut usize, - ) -> OrtStatusPtr, - >, - pub GetBoundOutputValues: ::std::option::Option< - unsafe extern "C" fn( - binding_ptr: *const OrtIoBinding, - allocator: *mut OrtAllocator, - output: *mut *mut *mut OrtValue, - output_count: *mut usize, - ) -> OrtStatusPtr, - >, - #[doc = " Clears any previously specified bindings for inputs/outputs"] - pub ClearBoundInputs: - ::std::option::Option, - pub ClearBoundOutputs: - ::std::option::Option, - pub TensorAt: ::std::option::Option< - unsafe extern "C" fn( - value: *mut OrtValue, - location_values: *const i64, - location_values_count: usize, - out: *mut *mut ::std::os::raw::c_void, - ) -> OrtStatusPtr, - >, - pub CreateAndRegisterAllocator: ::std::option::Option< - unsafe extern "C" fn( - env: *mut OrtEnv, - mem_info: *const OrtMemoryInfo, - arena_cfg: *const OrtArenaCfg, - ) -> OrtStatusPtr, - >, - pub SetLanguageProjection: ::std::option::Option< - unsafe extern "C" fn( - ort_env: *const OrtEnv, - projection: OrtLanguageProjection, - ) -> OrtStatusPtr, - >, - pub SessionGetProfilingStartTimeNs: ::std::option::Option< - unsafe extern "C" fn(sess: *const OrtSession, out: *mut u64) -> OrtStatusPtr, - >, - pub SetGlobalIntraOpNumThreads: ::std::option::Option< - unsafe extern "C" fn( - tp_options: *mut OrtThreadingOptions, - intra_op_num_threads: ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub SetGlobalInterOpNumThreads: ::std::option::Option< - unsafe extern "C" fn( - tp_options: *mut OrtThreadingOptions, - inter_op_num_threads: ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub SetGlobalSpinControl: ::std::option::Option< - unsafe extern "C" fn( - tp_options: *mut OrtThreadingOptions, - allow_spinning: ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub AddInitializer: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - name: *const ::std::os::raw::c_char, - val: *const OrtValue, - ) -> OrtStatusPtr, - >, - pub CreateEnvWithCustomLoggerAndGlobalThreadPools: ::std::option::Option< - unsafe extern "C" fn( - logging_function: OrtLoggingFunction, - logger_param: *mut ::std::os::raw::c_void, - logging_level: OrtLoggingLevel, - logid: *const ::std::os::raw::c_char, - tp_options: *const OrtThreadingOptions, - out: *mut *mut OrtEnv, - ) -> OrtStatusPtr, - >, - pub SessionOptionsAppendExecutionProvider_CUDA: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - cuda_options: *const OrtCUDAProviderOptions, - ) -> OrtStatusPtr, - >, - pub SessionOptionsAppendExecutionProvider_ROCM: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - rocm_options: *const OrtROCMProviderOptions, - ) -> OrtStatusPtr, - >, - pub SessionOptionsAppendExecutionProvider_OpenVINO: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - provider_options: *const OrtOpenVINOProviderOptions, - ) -> OrtStatusPtr, - >, - pub SetGlobalDenormalAsZero: ::std::option::Option< - unsafe extern "C" fn(tp_options: *mut OrtThreadingOptions) -> OrtStatusPtr, - >, - pub CreateArenaCfg: ::std::option::Option< - unsafe extern "C" fn( - max_mem: usize, - arena_extend_strategy: ::std::os::raw::c_int, - initial_chunk_size_bytes: ::std::os::raw::c_int, - max_dead_bytes_per_chunk: ::std::os::raw::c_int, - out: *mut *mut OrtArenaCfg, - ) -> OrtStatusPtr, - >, - pub ReleaseArenaCfg: ::std::option::Option, - pub ModelMetadataGetGraphDescription: ::std::option::Option< - unsafe extern "C" fn( - model_metadata: *const OrtModelMetadata, - allocator: *mut OrtAllocator, - value: *mut *mut ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub SessionOptionsAppendExecutionProvider_TensorRT: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - tensorrt_options: *const OrtTensorRTProviderOptions, - ) -> OrtStatusPtr, - >, - pub SetCurrentGpuDeviceId: ::std::option::Option< - unsafe extern "C" fn(device_id: ::std::os::raw::c_int) -> OrtStatusPtr, - >, - pub GetCurrentGpuDeviceId: ::std::option::Option< - unsafe extern "C" fn(device_id: *mut ::std::os::raw::c_int) -> OrtStatusPtr, - >, - pub KernelInfoGetAttributeArray_float: ::std::option::Option< - unsafe extern "C" fn( - info: *const OrtKernelInfo, - name: *const ::std::os::raw::c_char, - out: *mut f32, - size: *mut usize, - ) -> OrtStatusPtr, - >, - pub KernelInfoGetAttributeArray_int64: ::std::option::Option< - unsafe extern "C" fn( - info: *const OrtKernelInfo, - name: *const ::std::os::raw::c_char, - out: *mut i64, - size: *mut usize, - ) -> OrtStatusPtr, - >, - pub CreateArenaCfgV2: ::std::option::Option< - unsafe extern "C" fn( - arena_config_keys: *const *const ::std::os::raw::c_char, - arena_config_values: *const usize, - num_keys: usize, - out: *mut *mut OrtArenaCfg, - ) -> OrtStatusPtr, - >, - pub AddRunConfigEntry: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtRunOptions, - config_key: *const ::std::os::raw::c_char, - config_value: *const ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub CreatePrepackedWeightsContainer: ::std::option::Option< - unsafe extern "C" fn(out: *mut *mut OrtPrepackedWeightsContainer) -> OrtStatusPtr, - >, - pub ReleasePrepackedWeightsContainer: - ::std::option::Option, - pub CreateSessionWithPrepackedWeightsContainer: ::std::option::Option< - unsafe extern "C" fn( - env: *const OrtEnv, - model_path: *const ::std::os::raw::c_char, - options: *const OrtSessionOptions, - prepacked_weights_container: *mut OrtPrepackedWeightsContainer, - out: *mut *mut OrtSession, - ) -> OrtStatusPtr, - >, - pub CreateSessionFromArrayWithPrepackedWeightsContainer: ::std::option::Option< - unsafe extern "C" fn( - env: *const OrtEnv, - model_data: *const ::std::os::raw::c_void, - model_data_length: usize, - options: *const OrtSessionOptions, - prepacked_weights_container: *mut OrtPrepackedWeightsContainer, - out: *mut *mut OrtSession, - ) -> OrtStatusPtr, - >, -} -#[test] -fn bindgen_test_layout_OrtApi() { - assert_eq!( - ::std::mem::size_of::(), - 1360usize, - concat!("Size of: ", stringify!(OrtApi)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(OrtApi)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateStatus as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateStatus) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetErrorCode as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetErrorCode) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetErrorMessage as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetErrorMessage) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateEnv as *const _ as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateEnv) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateEnvWithCustomLogger as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateEnvWithCustomLogger) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).EnableTelemetryEvents as *const _ as usize }, - 40usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(EnableTelemetryEvents) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).DisableTelemetryEvents as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(DisableTelemetryEvents) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateSession as *const _ as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateSession) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateSessionFromArray as *const _ as usize }, - 64usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateSessionFromArray) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).Run as *const _ as usize }, - 72usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(Run) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateSessionOptions as *const _ as usize }, - 80usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateSessionOptions) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SetOptimizedModelFilePath as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetOptimizedModelFilePath) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CloneSessionOptions as *const _ as usize }, - 96usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CloneSessionOptions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetSessionExecutionMode as *const _ as usize }, - 104usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetSessionExecutionMode) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).EnableProfiling as *const _ as usize }, - 112usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(EnableProfiling) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).DisableProfiling as *const _ as usize }, - 120usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(DisableProfiling) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).EnableMemPattern as *const _ as usize }, - 128usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(EnableMemPattern) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).DisableMemPattern as *const _ as usize }, - 136usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(DisableMemPattern) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).EnableCpuMemArena as *const _ as usize }, - 144usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(EnableCpuMemArena) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).DisableCpuMemArena as *const _ as usize }, - 152usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(DisableCpuMemArena) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetSessionLogId as *const _ as usize }, - 160usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetSessionLogId) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SetSessionLogVerbosityLevel as *const _ as usize - }, - 168usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetSessionLogVerbosityLevel) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SetSessionLogSeverityLevel as *const _ as usize - }, - 176usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetSessionLogSeverityLevel) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SetSessionGraphOptimizationLevel as *const _ as usize - }, - 184usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetSessionGraphOptimizationLevel) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetIntraOpNumThreads as *const _ as usize }, - 192usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetIntraOpNumThreads) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetInterOpNumThreads as *const _ as usize }, - 200usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetInterOpNumThreads) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateCustomOpDomain as *const _ as usize }, - 208usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateCustomOpDomain) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CustomOpDomain_Add as *const _ as usize }, - 216usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CustomOpDomain_Add) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AddCustomOpDomain as *const _ as usize }, - 224usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AddCustomOpDomain) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).RegisterCustomOpsLibrary as *const _ as usize }, - 232usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RegisterCustomOpsLibrary) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionGetInputCount as *const _ as usize }, - 240usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetInputCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionGetOutputCount as *const _ as usize }, - 248usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetOutputCount) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionGetOverridableInitializerCount as *const _ - as usize - }, - 256usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetOverridableInitializerCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionGetInputTypeInfo as *const _ as usize }, - 264usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetInputTypeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionGetOutputTypeInfo as *const _ as usize }, - 272usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetOutputTypeInfo) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionGetOverridableInitializerTypeInfo as *const _ - as usize - }, - 280usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetOverridableInitializerTypeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionGetInputName as *const _ as usize }, - 288usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetInputName) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionGetOutputName as *const _ as usize }, - 296usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetOutputName) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionGetOverridableInitializerName as *const _ - as usize - }, - 304usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetOverridableInitializerName) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateRunOptions as *const _ as usize }, - 312usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateRunOptions) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).RunOptionsSetRunLogVerbosityLevel as *const _ - as usize - }, - 320usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsSetRunLogVerbosityLevel) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).RunOptionsSetRunLogSeverityLevel as *const _ as usize - }, - 328usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsSetRunLogSeverityLevel) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).RunOptionsSetRunTag as *const _ as usize }, - 336usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsSetRunTag) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).RunOptionsGetRunLogVerbosityLevel as *const _ - as usize - }, - 344usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsGetRunLogVerbosityLevel) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).RunOptionsGetRunLogSeverityLevel as *const _ as usize - }, - 352usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsGetRunLogSeverityLevel) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).RunOptionsGetRunTag as *const _ as usize }, - 360usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsGetRunTag) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).RunOptionsSetTerminate as *const _ as usize }, - 368usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsSetTerminate) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).RunOptionsUnsetTerminate as *const _ as usize }, - 376usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsUnsetTerminate) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateTensorAsOrtValue as *const _ as usize }, - 384usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateTensorAsOrtValue) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateTensorWithDataAsOrtValue as *const _ as usize - }, - 392usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateTensorWithDataAsOrtValue) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).IsTensor as *const _ as usize }, - 400usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(IsTensor) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetTensorMutableData as *const _ as usize }, - 408usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetTensorMutableData) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).FillStringTensor as *const _ as usize }, - 416usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(FillStringTensor) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetStringTensorDataLength as *const _ as usize - }, - 424usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetStringTensorDataLength) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetStringTensorContent as *const _ as usize }, - 432usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetStringTensorContent) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CastTypeInfoToTensorInfo as *const _ as usize }, - 440usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CastTypeInfoToTensorInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetOnnxTypeFromTypeInfo as *const _ as usize }, - 448usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetOnnxTypeFromTypeInfo) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateTensorTypeAndShapeInfo as *const _ as usize - }, - 456usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateTensorTypeAndShapeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetTensorElementType as *const _ as usize }, - 464usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetTensorElementType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetDimensions as *const _ as usize }, - 472usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetDimensions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetTensorElementType as *const _ as usize }, - 480usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetTensorElementType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetDimensionsCount as *const _ as usize }, - 488usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetDimensionsCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetDimensions as *const _ as usize }, - 496usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetDimensions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetSymbolicDimensions as *const _ as usize }, - 504usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetSymbolicDimensions) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetTensorShapeElementCount as *const _ as usize - }, - 512usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetTensorShapeElementCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetTensorTypeAndShape as *const _ as usize }, - 520usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetTensorTypeAndShape) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetTypeInfo as *const _ as usize }, - 528usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetTypeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetValueType as *const _ as usize }, - 536usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetValueType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateMemoryInfo as *const _ as usize }, - 544usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateMemoryInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateCpuMemoryInfo as *const _ as usize }, - 552usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateCpuMemoryInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CompareMemoryInfo as *const _ as usize }, - 560usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CompareMemoryInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).MemoryInfoGetName as *const _ as usize }, - 568usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(MemoryInfoGetName) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).MemoryInfoGetId as *const _ as usize }, - 576usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(MemoryInfoGetId) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).MemoryInfoGetMemType as *const _ as usize }, - 584usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(MemoryInfoGetMemType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).MemoryInfoGetType as *const _ as usize }, - 592usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(MemoryInfoGetType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AllocatorAlloc as *const _ as usize }, - 600usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AllocatorAlloc) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AllocatorFree as *const _ as usize }, - 608usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AllocatorFree) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AllocatorGetInfo as *const _ as usize }, - 616usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AllocatorGetInfo) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetAllocatorWithDefaultOptions as *const _ as usize - }, - 624usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetAllocatorWithDefaultOptions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AddFreeDimensionOverride as *const _ as usize }, - 632usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AddFreeDimensionOverride) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetValue as *const _ as usize }, - 640usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetValue) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetValueCount as *const _ as usize }, - 648usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetValueCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateValue as *const _ as usize }, - 656usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateValue) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateOpaqueValue as *const _ as usize }, - 664usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateOpaqueValue) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetOpaqueValue as *const _ as usize }, - 672usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetOpaqueValue) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).KernelInfoGetAttribute_float as *const _ as usize - }, - 680usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelInfoGetAttribute_float) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).KernelInfoGetAttribute_int64 as *const _ as usize - }, - 688usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelInfoGetAttribute_int64) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).KernelInfoGetAttribute_string as *const _ as usize - }, - 696usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelInfoGetAttribute_string) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).KernelContext_GetInputCount as *const _ as usize - }, - 704usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelContext_GetInputCount) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).KernelContext_GetOutputCount as *const _ as usize - }, - 712usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelContext_GetOutputCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).KernelContext_GetInput as *const _ as usize }, - 720usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelContext_GetInput) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).KernelContext_GetOutput as *const _ as usize }, - 728usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelContext_GetOutput) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseEnv as *const _ as usize }, - 736usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseEnv) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseStatus as *const _ as usize }, - 744usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseStatus) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseMemoryInfo as *const _ as usize }, - 752usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseMemoryInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseSession as *const _ as usize }, - 760usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseSession) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseValue as *const _ as usize }, - 768usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseValue) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseRunOptions as *const _ as usize }, - 776usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseRunOptions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseTypeInfo as *const _ as usize }, - 784usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseTypeInfo) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ReleaseTensorTypeAndShapeInfo as *const _ as usize - }, - 792usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseTensorTypeAndShapeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseSessionOptions as *const _ as usize }, - 800usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseSessionOptions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseCustomOpDomain as *const _ as usize }, - 808usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseCustomOpDomain) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetDenotationFromTypeInfo as *const _ as usize - }, - 816usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetDenotationFromTypeInfo) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CastTypeInfoToMapTypeInfo as *const _ as usize - }, - 824usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CastTypeInfoToMapTypeInfo) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CastTypeInfoToSequenceTypeInfo as *const _ as usize - }, - 832usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CastTypeInfoToSequenceTypeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetMapKeyType as *const _ as usize }, - 840usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetMapKeyType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetMapValueType as *const _ as usize }, - 848usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetMapValueType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetSequenceElementType as *const _ as usize }, - 856usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetSequenceElementType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseMapTypeInfo as *const _ as usize }, - 864usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseMapTypeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseSequenceTypeInfo as *const _ as usize }, - 872usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseSequenceTypeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionEndProfiling as *const _ as usize }, - 880usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionEndProfiling) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionGetModelMetadata as *const _ as usize }, - 888usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetModelMetadata) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ModelMetadataGetProducerName as *const _ as usize - }, - 896usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataGetProducerName) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ModelMetadataGetGraphName as *const _ as usize - }, - 904usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataGetGraphName) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ModelMetadataGetDomain as *const _ as usize }, - 912usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataGetDomain) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ModelMetadataGetDescription as *const _ as usize - }, - 920usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataGetDescription) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ModelMetadataLookupCustomMetadataMap as *const _ - as usize - }, - 928usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataLookupCustomMetadataMap) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ModelMetadataGetVersion as *const _ as usize }, - 936usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataGetVersion) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseModelMetadata as *const _ as usize }, - 944usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseModelMetadata) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateEnvWithGlobalThreadPools as *const _ as usize - }, - 952usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateEnvWithGlobalThreadPools) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).DisablePerSessionThreads as *const _ as usize }, - 960usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(DisablePerSessionThreads) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateThreadingOptions as *const _ as usize }, - 968usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateThreadingOptions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseThreadingOptions as *const _ as usize }, - 976usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseThreadingOptions) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ModelMetadataGetCustomMetadataMapKeys as *const _ - as usize - }, - 984usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataGetCustomMetadataMapKeys) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).AddFreeDimensionOverrideByName as *const _ as usize - }, - 992usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AddFreeDimensionOverrideByName) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetAvailableProviders as *const _ as usize }, - 1000usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetAvailableProviders) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ReleaseAvailableProviders as *const _ as usize - }, - 1008usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseAvailableProviders) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetStringTensorElementLength as *const _ as usize - }, - 1016usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetStringTensorElementLength) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetStringTensorElement as *const _ as usize }, - 1024usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetStringTensorElement) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).FillStringTensorElement as *const _ as usize }, - 1032usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(FillStringTensorElement) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AddSessionConfigEntry as *const _ as usize }, - 1040usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AddSessionConfigEntry) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateAllocator as *const _ as usize }, - 1048usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateAllocator) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseAllocator as *const _ as usize }, - 1056usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseAllocator) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).RunWithBinding as *const _ as usize }, - 1064usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunWithBinding) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateIoBinding as *const _ as usize }, - 1072usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateIoBinding) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseIoBinding as *const _ as usize }, - 1080usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseIoBinding) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).BindInput as *const _ as usize }, - 1088usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(BindInput) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).BindOutput as *const _ as usize }, - 1096usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(BindOutput) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).BindOutputToDevice as *const _ as usize }, - 1104usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(BindOutputToDevice) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetBoundOutputNames as *const _ as usize }, - 1112usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetBoundOutputNames) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetBoundOutputValues as *const _ as usize }, - 1120usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetBoundOutputValues) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ClearBoundInputs as *const _ as usize }, - 1128usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ClearBoundInputs) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ClearBoundOutputs as *const _ as usize }, - 1136usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ClearBoundOutputs) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).TensorAt as *const _ as usize }, - 1144usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(TensorAt) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateAndRegisterAllocator as *const _ as usize - }, - 1152usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateAndRegisterAllocator) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetLanguageProjection as *const _ as usize }, - 1160usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetLanguageProjection) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionGetProfilingStartTimeNs as *const _ as usize - }, - 1168usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetProfilingStartTimeNs) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SetGlobalIntraOpNumThreads as *const _ as usize - }, - 1176usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetGlobalIntraOpNumThreads) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SetGlobalInterOpNumThreads as *const _ as usize - }, - 1184usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetGlobalInterOpNumThreads) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetGlobalSpinControl as *const _ as usize }, - 1192usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetGlobalSpinControl) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AddInitializer as *const _ as usize }, - 1200usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AddInitializer) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateEnvWithCustomLoggerAndGlobalThreadPools - as *const _ as usize - }, - 1208usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateEnvWithCustomLoggerAndGlobalThreadPools) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionOptionsAppendExecutionProvider_CUDA - as *const _ as usize - }, - 1216usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionOptionsAppendExecutionProvider_CUDA) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionOptionsAppendExecutionProvider_ROCM - as *const _ as usize - }, - 1224usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionOptionsAppendExecutionProvider_ROCM) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionOptionsAppendExecutionProvider_OpenVINO - as *const _ as usize - }, - 1232usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionOptionsAppendExecutionProvider_OpenVINO) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetGlobalDenormalAsZero as *const _ as usize }, - 1240usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetGlobalDenormalAsZero) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateArenaCfg as *const _ as usize }, - 1248usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateArenaCfg) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseArenaCfg as *const _ as usize }, - 1256usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseArenaCfg) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ModelMetadataGetGraphDescription as *const _ as usize - }, - 1264usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataGetGraphDescription) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionOptionsAppendExecutionProvider_TensorRT - as *const _ as usize - }, - 1272usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionOptionsAppendExecutionProvider_TensorRT) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetCurrentGpuDeviceId as *const _ as usize }, - 1280usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetCurrentGpuDeviceId) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetCurrentGpuDeviceId as *const _ as usize }, - 1288usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetCurrentGpuDeviceId) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).KernelInfoGetAttributeArray_float as *const _ - as usize - }, - 1296usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelInfoGetAttributeArray_float) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).KernelInfoGetAttributeArray_int64 as *const _ - as usize - }, - 1304usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelInfoGetAttributeArray_int64) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateArenaCfgV2 as *const _ as usize }, - 1312usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateArenaCfgV2) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AddRunConfigEntry as *const _ as usize }, - 1320usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AddRunConfigEntry) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreatePrepackedWeightsContainer as *const _ as usize - }, - 1328usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreatePrepackedWeightsContainer) - ) +#[test] +fn bindgen_test_layout_OrtCustomHandleType() { + assert_eq!( + ::std::mem::size_of::(), + 1usize, + concat!("Size of: ", stringify!(OrtCustomHandleType)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ReleasePrepackedWeightsContainer as *const _ as usize - }, - 1336usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleasePrepackedWeightsContainer) - ) - ); + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(OrtCustomHandleType)) + ); + fn test_field___place_holder() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__place_holder) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomHandleType), + "::", + stringify!(__place_holder) + ) + ); + } + test_field___place_holder(); +} +pub type OrtCustomThreadHandle = *const OrtCustomHandleType; +#[doc = " \\brief Ort custom thread creation function"] +#[doc = ""] +#[doc = " The function should return a thread handle to be used in onnxruntime thread pools"] +#[doc = " Onnxruntime will throw exception on return value of nullptr or 0, indicating that the function failed to create a thread"] +pub type OrtCustomCreateThreadFn = ::std::option::Option< + unsafe extern "C" fn( + ort_custom_thread_creation_options: *mut ::std::os::raw::c_void, + ort_thread_worker_fn: OrtThreadWorkerFn, + ort_worker_fn_param: *mut ::std::os::raw::c_void, + ) -> OrtCustomThreadHandle, +>; +#[doc = " \\brief Custom thread join function"] +#[doc = ""] +#[doc = " Onnxruntime thread pool destructor will call the function to join a custom thread."] +#[doc = " Argument ort_custom_thread_handle is the value returned by OrtCustomCreateThreadFn"] +pub type OrtCustomJoinThreadFn = + ::std::option::Option; +#[doc = " \\brief The C API"] +#[doc = ""] +#[doc = " All C API functions are defined inside this structure as pointers to functions."] +#[doc = " Call OrtApiBase::GetApi to get a pointer to it"] +#[doc = ""] +#[doc = " \\nosubgrouping"] +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtApi { + #[doc = " \\brief Create an OrtStatus from a null terminated string"] + #[doc = ""] + #[doc = " \\param[in] code"] + #[doc = " \\param[in] msg A null-terminated string. Its contents will be copied."] + #[doc = " \\return A new OrtStatus object, must be destroyed with OrtApi::ReleaseStatus"] + pub CreateStatus: ::std::option::Option< + unsafe extern "C" fn( + code: OrtErrorCode, + msg: *const ::std::os::raw::c_char, + ) -> *mut OrtStatus, + >, + #[doc = " \\brief Get OrtErrorCode from OrtStatus"] + #[doc = ""] + #[doc = " \\param[in] status"] + #[doc = " \\return OrtErrorCode that \\p status was created with"] + pub GetErrorCode: + ::std::option::Option OrtErrorCode>, + #[doc = " \\brief Get error string from OrtStatus"] + #[doc = ""] + #[doc = " \\param[in] status"] + #[doc = " \\return The error message inside the `status`. Do not free the returned value."] + pub GetErrorMessage: ::std::option::Option< + unsafe extern "C" fn(status: *const OrtStatus) -> *const ::std::os::raw::c_char, + >, + pub CreateEnv: ::std::option::Option< + unsafe extern "C" fn( + log_severity_level: OrtLoggingLevel, + logid: *const ::std::os::raw::c_char, + out: *mut *mut OrtEnv, + ) -> OrtStatusPtr, + >, + pub CreateEnvWithCustomLogger: ::std::option::Option< + unsafe extern "C" fn( + logging_function: OrtLoggingFunction, + logger_param: *mut ::std::os::raw::c_void, + log_severity_level: OrtLoggingLevel, + logid: *const ::std::os::raw::c_char, + out: *mut *mut OrtEnv, + ) -> OrtStatusPtr, + >, + pub EnableTelemetryEvents: + ::std::option::Option OrtStatusPtr>, + pub DisableTelemetryEvents: + ::std::option::Option OrtStatusPtr>, + pub CreateSession: ::std::option::Option< + unsafe extern "C" fn( + env: *const OrtEnv, + model_path: *const ::std::os::raw::c_char, + options: *const OrtSessionOptions, + out: *mut *mut OrtSession, + ) -> OrtStatusPtr, + >, + pub CreateSessionFromArray: ::std::option::Option< + unsafe extern "C" fn( + env: *const OrtEnv, + model_data: *const ::std::os::raw::c_void, + model_data_length: usize, + options: *const OrtSessionOptions, + out: *mut *mut OrtSession, + ) -> OrtStatusPtr, + >, + pub Run: ::std::option::Option< + unsafe extern "C" fn( + session: *mut OrtSession, + run_options: *const OrtRunOptions, + input_names: *const *const ::std::os::raw::c_char, + inputs: *const *const OrtValue, + input_len: usize, + output_names: *const *const ::std::os::raw::c_char, + output_names_len: usize, + outputs: *mut *mut OrtValue, + ) -> OrtStatusPtr, + >, + pub CreateSessionOptions: ::std::option::Option< + unsafe extern "C" fn(options: *mut *mut OrtSessionOptions) -> OrtStatusPtr, + >, + pub SetOptimizedModelFilePath: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + optimized_model_filepath: *const ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub CloneSessionOptions: ::std::option::Option< + unsafe extern "C" fn( + in_options: *const OrtSessionOptions, + out_options: *mut *mut OrtSessionOptions, + ) -> OrtStatusPtr, + >, + pub SetSessionExecutionMode: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + execution_mode: ExecutionMode, + ) -> OrtStatusPtr, + >, + pub EnableProfiling: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + profile_file_prefix: *const ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub DisableProfiling: ::std::option::Option< + unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, + >, + pub EnableMemPattern: ::std::option::Option< + unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, + >, + pub DisableMemPattern: ::std::option::Option< + unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, + >, + pub EnableCpuMemArena: ::std::option::Option< + unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, + >, + pub DisableCpuMemArena: ::std::option::Option< + unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, + >, + pub SetSessionLogId: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + logid: *const ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub SetSessionLogVerbosityLevel: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + session_log_verbosity_level: ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub SetSessionLogSeverityLevel: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + session_log_severity_level: ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub SetSessionGraphOptimizationLevel: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + graph_optimization_level: GraphOptimizationLevel, + ) -> OrtStatusPtr, + >, + pub SetIntraOpNumThreads: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + intra_op_num_threads: ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub SetInterOpNumThreads: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + inter_op_num_threads: ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub CreateCustomOpDomain: ::std::option::Option< + unsafe extern "C" fn( + domain: *const ::std::os::raw::c_char, + out: *mut *mut OrtCustomOpDomain, + ) -> OrtStatusPtr, + >, + pub CustomOpDomain_Add: ::std::option::Option< + unsafe extern "C" fn( + custom_op_domain: *mut OrtCustomOpDomain, + op: *const OrtCustomOp, + ) -> OrtStatusPtr, + >, + pub AddCustomOpDomain: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + custom_op_domain: *mut OrtCustomOpDomain, + ) -> OrtStatusPtr, + >, + pub RegisterCustomOpsLibrary: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + library_path: *const ::std::os::raw::c_char, + library_handle: *mut *mut ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub SessionGetInputCount: ::std::option::Option< + unsafe extern "C" fn(session: *const OrtSession, out: *mut usize) -> OrtStatusPtr, + >, + pub SessionGetOutputCount: ::std::option::Option< + unsafe extern "C" fn(session: *const OrtSession, out: *mut usize) -> OrtStatusPtr, + >, + pub SessionGetOverridableInitializerCount: ::std::option::Option< + unsafe extern "C" fn(session: *const OrtSession, out: *mut usize) -> OrtStatusPtr, + >, + pub SessionGetInputTypeInfo: ::std::option::Option< + unsafe extern "C" fn( + session: *const OrtSession, + index: usize, + type_info: *mut *mut OrtTypeInfo, + ) -> OrtStatusPtr, + >, + pub SessionGetOutputTypeInfo: ::std::option::Option< + unsafe extern "C" fn( + session: *const OrtSession, + index: usize, + type_info: *mut *mut OrtTypeInfo, + ) -> OrtStatusPtr, + >, + pub SessionGetOverridableInitializerTypeInfo: ::std::option::Option< + unsafe extern "C" fn( + session: *const OrtSession, + index: usize, + type_info: *mut *mut OrtTypeInfo, + ) -> OrtStatusPtr, + >, + pub SessionGetInputName: ::std::option::Option< + unsafe extern "C" fn( + session: *const OrtSession, + index: usize, + allocator: *mut OrtAllocator, + value: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub SessionGetOutputName: ::std::option::Option< + unsafe extern "C" fn( + session: *const OrtSession, + index: usize, + allocator: *mut OrtAllocator, + value: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub SessionGetOverridableInitializerName: ::std::option::Option< + unsafe extern "C" fn( + session: *const OrtSession, + index: usize, + allocator: *mut OrtAllocator, + value: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub CreateRunOptions: + ::std::option::Option OrtStatusPtr>, + pub RunOptionsSetRunLogVerbosityLevel: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtRunOptions, + log_verbosity_level: ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub RunOptionsSetRunLogSeverityLevel: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtRunOptions, + log_severity_level: ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub RunOptionsSetRunTag: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtRunOptions, + run_tag: *const ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub RunOptionsGetRunLogVerbosityLevel: ::std::option::Option< + unsafe extern "C" fn( + options: *const OrtRunOptions, + log_verbosity_level: *mut ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub RunOptionsGetRunLogSeverityLevel: ::std::option::Option< + unsafe extern "C" fn( + options: *const OrtRunOptions, + log_severity_level: *mut ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub RunOptionsGetRunTag: ::std::option::Option< + unsafe extern "C" fn( + options: *const OrtRunOptions, + run_tag: *mut *const ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub RunOptionsSetTerminate: + ::std::option::Option OrtStatusPtr>, + pub RunOptionsUnsetTerminate: + ::std::option::Option OrtStatusPtr>, + pub CreateTensorAsOrtValue: ::std::option::Option< + unsafe extern "C" fn( + allocator: *mut OrtAllocator, + shape: *const i64, + shape_len: usize, + type_: ONNXTensorElementDataType, + out: *mut *mut OrtValue, + ) -> OrtStatusPtr, + >, + pub CreateTensorWithDataAsOrtValue: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtMemoryInfo, + p_data: *mut ::std::os::raw::c_void, + p_data_len: usize, + shape: *const i64, + shape_len: usize, + type_: ONNXTensorElementDataType, + out: *mut *mut OrtValue, + ) -> OrtStatusPtr, + >, + pub IsTensor: ::std::option::Option< + unsafe extern "C" fn( + value: *const OrtValue, + out: *mut ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub GetTensorMutableData: ::std::option::Option< + unsafe extern "C" fn( + value: *mut OrtValue, + out: *mut *mut ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub FillStringTensor: ::std::option::Option< + unsafe extern "C" fn( + value: *mut OrtValue, + s: *const *const ::std::os::raw::c_char, + s_len: usize, + ) -> OrtStatusPtr, + >, + pub GetStringTensorDataLength: ::std::option::Option< + unsafe extern "C" fn(value: *const OrtValue, len: *mut usize) -> OrtStatusPtr, + >, + pub GetStringTensorContent: ::std::option::Option< + unsafe extern "C" fn( + value: *const OrtValue, + s: *mut ::std::os::raw::c_void, + s_len: usize, + offsets: *mut usize, + offsets_len: usize, + ) -> OrtStatusPtr, + >, + pub CastTypeInfoToTensorInfo: ::std::option::Option< + unsafe extern "C" fn( + type_info: *const OrtTypeInfo, + out: *mut *const OrtTensorTypeAndShapeInfo, + ) -> OrtStatusPtr, + >, + pub GetOnnxTypeFromTypeInfo: ::std::option::Option< + unsafe extern "C" fn(type_info: *const OrtTypeInfo, out: *mut ONNXType) -> OrtStatusPtr, + >, + pub CreateTensorTypeAndShapeInfo: ::std::option::Option< + unsafe extern "C" fn(out: *mut *mut OrtTensorTypeAndShapeInfo) -> OrtStatusPtr, + >, + pub SetTensorElementType: ::std::option::Option< + unsafe extern "C" fn( + info: *mut OrtTensorTypeAndShapeInfo, + type_: ONNXTensorElementDataType, + ) -> OrtStatusPtr, + >, + pub SetDimensions: ::std::option::Option< + unsafe extern "C" fn( + info: *mut OrtTensorTypeAndShapeInfo, + dim_values: *const i64, + dim_count: usize, + ) -> OrtStatusPtr, + >, + pub GetTensorElementType: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtTensorTypeAndShapeInfo, + out: *mut ONNXTensorElementDataType, + ) -> OrtStatusPtr, + >, + pub GetDimensionsCount: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtTensorTypeAndShapeInfo, + out: *mut usize, + ) -> OrtStatusPtr, + >, + pub GetDimensions: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtTensorTypeAndShapeInfo, + dim_values: *mut i64, + dim_values_length: usize, + ) -> OrtStatusPtr, + >, + pub GetSymbolicDimensions: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtTensorTypeAndShapeInfo, + dim_params: *mut *const ::std::os::raw::c_char, + dim_params_length: usize, + ) -> OrtStatusPtr, + >, + pub GetTensorShapeElementCount: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtTensorTypeAndShapeInfo, + out: *mut usize, + ) -> OrtStatusPtr, + >, + pub GetTensorTypeAndShape: ::std::option::Option< + unsafe extern "C" fn( + value: *const OrtValue, + out: *mut *mut OrtTensorTypeAndShapeInfo, + ) -> OrtStatusPtr, + >, + pub GetTypeInfo: ::std::option::Option< + unsafe extern "C" fn(value: *const OrtValue, out: *mut *mut OrtTypeInfo) -> OrtStatusPtr, + >, + pub GetValueType: ::std::option::Option< + unsafe extern "C" fn(value: *const OrtValue, out: *mut ONNXType) -> OrtStatusPtr, + >, + pub CreateMemoryInfo: ::std::option::Option< + unsafe extern "C" fn( + name: *const ::std::os::raw::c_char, + type_: OrtAllocatorType, + id: ::std::os::raw::c_int, + mem_type: OrtMemType, + out: *mut *mut OrtMemoryInfo, + ) -> OrtStatusPtr, + >, + pub CreateCpuMemoryInfo: ::std::option::Option< + unsafe extern "C" fn( + type_: OrtAllocatorType, + mem_type: OrtMemType, + out: *mut *mut OrtMemoryInfo, + ) -> OrtStatusPtr, + >, + pub CompareMemoryInfo: ::std::option::Option< + unsafe extern "C" fn( + info1: *const OrtMemoryInfo, + info2: *const OrtMemoryInfo, + out: *mut ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub MemoryInfoGetName: ::std::option::Option< + unsafe extern "C" fn( + ptr: *const OrtMemoryInfo, + out: *mut *const ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub MemoryInfoGetId: ::std::option::Option< + unsafe extern "C" fn( + ptr: *const OrtMemoryInfo, + out: *mut ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub MemoryInfoGetMemType: ::std::option::Option< + unsafe extern "C" fn(ptr: *const OrtMemoryInfo, out: *mut OrtMemType) -> OrtStatusPtr, + >, + pub MemoryInfoGetType: ::std::option::Option< + unsafe extern "C" fn(ptr: *const OrtMemoryInfo, out: *mut OrtAllocatorType) -> OrtStatusPtr, + >, + pub AllocatorAlloc: ::std::option::Option< + unsafe extern "C" fn( + ort_allocator: *mut OrtAllocator, + size: usize, + out: *mut *mut ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub AllocatorFree: ::std::option::Option< + unsafe extern "C" fn( + ort_allocator: *mut OrtAllocator, + p: *mut ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub AllocatorGetInfo: ::std::option::Option< + unsafe extern "C" fn( + ort_allocator: *const OrtAllocator, + out: *mut *const OrtMemoryInfo, + ) -> OrtStatusPtr, + >, + pub GetAllocatorWithDefaultOptions: + ::std::option::Option OrtStatusPtr>, + pub AddFreeDimensionOverride: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + dim_denotation: *const ::std::os::raw::c_char, + dim_value: i64, + ) -> OrtStatusPtr, + >, + pub GetValue: ::std::option::Option< + unsafe extern "C" fn( + value: *const OrtValue, + index: ::std::os::raw::c_int, + allocator: *mut OrtAllocator, + out: *mut *mut OrtValue, + ) -> OrtStatusPtr, + >, + pub GetValueCount: ::std::option::Option< + unsafe extern "C" fn(value: *const OrtValue, out: *mut usize) -> OrtStatusPtr, + >, + pub CreateValue: ::std::option::Option< + unsafe extern "C" fn( + in_: *const *const OrtValue, + num_values: usize, + value_type: ONNXType, + out: *mut *mut OrtValue, + ) -> OrtStatusPtr, + >, + pub CreateOpaqueValue: ::std::option::Option< + unsafe extern "C" fn( + domain_name: *const ::std::os::raw::c_char, + type_name: *const ::std::os::raw::c_char, + data_container: *const ::std::os::raw::c_void, + data_container_size: usize, + out: *mut *mut OrtValue, + ) -> OrtStatusPtr, + >, + pub GetOpaqueValue: ::std::option::Option< + unsafe extern "C" fn( + domain_name: *const ::std::os::raw::c_char, + type_name: *const ::std::os::raw::c_char, + in_: *const OrtValue, + data_container: *mut ::std::os::raw::c_void, + data_container_size: usize, + ) -> OrtStatusPtr, + >, + pub KernelInfoGetAttribute_float: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtKernelInfo, + name: *const ::std::os::raw::c_char, + out: *mut f32, + ) -> OrtStatusPtr, + >, + pub KernelInfoGetAttribute_int64: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtKernelInfo, + name: *const ::std::os::raw::c_char, + out: *mut i64, + ) -> OrtStatusPtr, + >, + pub KernelInfoGetAttribute_string: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtKernelInfo, + name: *const ::std::os::raw::c_char, + out: *mut ::std::os::raw::c_char, + size: *mut usize, + ) -> OrtStatusPtr, + >, + pub KernelContext_GetInputCount: ::std::option::Option< + unsafe extern "C" fn(context: *const OrtKernelContext, out: *mut usize) -> OrtStatusPtr, + >, + pub KernelContext_GetOutputCount: ::std::option::Option< + unsafe extern "C" fn(context: *const OrtKernelContext, out: *mut usize) -> OrtStatusPtr, + >, + pub KernelContext_GetInput: ::std::option::Option< + unsafe extern "C" fn( + context: *const OrtKernelContext, + index: usize, + out: *mut *const OrtValue, + ) -> OrtStatusPtr, + >, + pub KernelContext_GetOutput: ::std::option::Option< + unsafe extern "C" fn( + context: *mut OrtKernelContext, + index: usize, + dim_values: *const i64, + dim_count: usize, + out: *mut *mut OrtValue, + ) -> OrtStatusPtr, + >, + pub ReleaseEnv: ::std::option::Option, + pub ReleaseStatus: ::std::option::Option, + pub ReleaseMemoryInfo: ::std::option::Option, + pub ReleaseSession: ::std::option::Option, + pub ReleaseValue: ::std::option::Option, + pub ReleaseRunOptions: ::std::option::Option, + pub ReleaseTypeInfo: ::std::option::Option, + pub ReleaseTensorTypeAndShapeInfo: + ::std::option::Option, + pub ReleaseSessionOptions: + ::std::option::Option, + pub ReleaseCustomOpDomain: + ::std::option::Option, + pub GetDenotationFromTypeInfo: ::std::option::Option< + unsafe extern "C" fn( + type_info: *const OrtTypeInfo, + denotation: *mut *const ::std::os::raw::c_char, + len: *mut usize, + ) -> OrtStatusPtr, + >, + pub CastTypeInfoToMapTypeInfo: ::std::option::Option< + unsafe extern "C" fn( + type_info: *const OrtTypeInfo, + out: *mut *const OrtMapTypeInfo, + ) -> OrtStatusPtr, + >, + pub CastTypeInfoToSequenceTypeInfo: ::std::option::Option< + unsafe extern "C" fn( + type_info: *const OrtTypeInfo, + out: *mut *const OrtSequenceTypeInfo, + ) -> OrtStatusPtr, + >, + pub GetMapKeyType: ::std::option::Option< + unsafe extern "C" fn( + map_type_info: *const OrtMapTypeInfo, + out: *mut ONNXTensorElementDataType, + ) -> OrtStatusPtr, + >, + pub GetMapValueType: ::std::option::Option< + unsafe extern "C" fn( + map_type_info: *const OrtMapTypeInfo, + type_info: *mut *mut OrtTypeInfo, + ) -> OrtStatusPtr, + >, + pub GetSequenceElementType: ::std::option::Option< + unsafe extern "C" fn( + sequence_type_info: *const OrtSequenceTypeInfo, + type_info: *mut *mut OrtTypeInfo, + ) -> OrtStatusPtr, + >, + pub ReleaseMapTypeInfo: ::std::option::Option, + pub ReleaseSequenceTypeInfo: + ::std::option::Option, + pub SessionEndProfiling: ::std::option::Option< + unsafe extern "C" fn( + session: *mut OrtSession, + allocator: *mut OrtAllocator, + out: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub SessionGetModelMetadata: ::std::option::Option< + unsafe extern "C" fn( + session: *const OrtSession, + out: *mut *mut OrtModelMetadata, + ) -> OrtStatusPtr, + >, + pub ModelMetadataGetProducerName: ::std::option::Option< + unsafe extern "C" fn( + model_metadata: *const OrtModelMetadata, + allocator: *mut OrtAllocator, + value: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub ModelMetadataGetGraphName: ::std::option::Option< + unsafe extern "C" fn( + model_metadata: *const OrtModelMetadata, + allocator: *mut OrtAllocator, + value: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub ModelMetadataGetDomain: ::std::option::Option< + unsafe extern "C" fn( + model_metadata: *const OrtModelMetadata, + allocator: *mut OrtAllocator, + value: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub ModelMetadataGetDescription: ::std::option::Option< + unsafe extern "C" fn( + model_metadata: *const OrtModelMetadata, + allocator: *mut OrtAllocator, + value: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub ModelMetadataLookupCustomMetadataMap: ::std::option::Option< + unsafe extern "C" fn( + model_metadata: *const OrtModelMetadata, + allocator: *mut OrtAllocator, + key: *const ::std::os::raw::c_char, + value: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub ModelMetadataGetVersion: ::std::option::Option< + unsafe extern "C" fn( + model_metadata: *const OrtModelMetadata, + value: *mut i64, + ) -> OrtStatusPtr, + >, + pub ReleaseModelMetadata: + ::std::option::Option, + pub CreateEnvWithGlobalThreadPools: ::std::option::Option< + unsafe extern "C" fn( + log_severity_level: OrtLoggingLevel, + logid: *const ::std::os::raw::c_char, + tp_options: *const OrtThreadingOptions, + out: *mut *mut OrtEnv, + ) -> OrtStatusPtr, + >, + pub DisablePerSessionThreads: ::std::option::Option< + unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, + >, + pub CreateThreadingOptions: ::std::option::Option< + unsafe extern "C" fn(out: *mut *mut OrtThreadingOptions) -> OrtStatusPtr, + >, + pub ReleaseThreadingOptions: + ::std::option::Option, + pub ModelMetadataGetCustomMetadataMapKeys: ::std::option::Option< + unsafe extern "C" fn( + model_metadata: *const OrtModelMetadata, + allocator: *mut OrtAllocator, + keys: *mut *mut *mut ::std::os::raw::c_char, + num_keys: *mut i64, + ) -> OrtStatusPtr, + >, + pub AddFreeDimensionOverrideByName: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + dim_name: *const ::std::os::raw::c_char, + dim_value: i64, + ) -> OrtStatusPtr, + >, + pub GetAvailableProviders: ::std::option::Option< + unsafe extern "C" fn( + out_ptr: *mut *mut *mut ::std::os::raw::c_char, + provider_length: *mut ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub ReleaseAvailableProviders: ::std::option::Option< + unsafe extern "C" fn( + ptr: *mut *mut ::std::os::raw::c_char, + providers_length: ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub GetStringTensorElementLength: ::std::option::Option< + unsafe extern "C" fn(value: *const OrtValue, index: usize, out: *mut usize) -> OrtStatusPtr, + >, + pub GetStringTensorElement: ::std::option::Option< + unsafe extern "C" fn( + value: *const OrtValue, + s_len: usize, + index: usize, + s: *mut ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub FillStringTensorElement: ::std::option::Option< + unsafe extern "C" fn( + value: *mut OrtValue, + s: *const ::std::os::raw::c_char, + index: usize, + ) -> OrtStatusPtr, + >, + pub AddSessionConfigEntry: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + config_key: *const ::std::os::raw::c_char, + config_value: *const ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub CreateAllocator: ::std::option::Option< + unsafe extern "C" fn( + session: *const OrtSession, + mem_info: *const OrtMemoryInfo, + out: *mut *mut OrtAllocator, + ) -> OrtStatusPtr, + >, + pub ReleaseAllocator: ::std::option::Option, + pub RunWithBinding: ::std::option::Option< + unsafe extern "C" fn( + session: *mut OrtSession, + run_options: *const OrtRunOptions, + binding_ptr: *const OrtIoBinding, + ) -> OrtStatusPtr, + >, + pub CreateIoBinding: ::std::option::Option< + unsafe extern "C" fn(session: *mut OrtSession, out: *mut *mut OrtIoBinding) -> OrtStatusPtr, + >, + pub ReleaseIoBinding: ::std::option::Option, + pub BindInput: ::std::option::Option< + unsafe extern "C" fn( + binding_ptr: *mut OrtIoBinding, + name: *const ::std::os::raw::c_char, + val_ptr: *const OrtValue, + ) -> OrtStatusPtr, + >, + pub BindOutput: ::std::option::Option< + unsafe extern "C" fn( + binding_ptr: *mut OrtIoBinding, + name: *const ::std::os::raw::c_char, + val_ptr: *const OrtValue, + ) -> OrtStatusPtr, + >, + pub BindOutputToDevice: ::std::option::Option< + unsafe extern "C" fn( + binding_ptr: *mut OrtIoBinding, + name: *const ::std::os::raw::c_char, + mem_info_ptr: *const OrtMemoryInfo, + ) -> OrtStatusPtr, + >, + pub GetBoundOutputNames: ::std::option::Option< + unsafe extern "C" fn( + binding_ptr: *const OrtIoBinding, + allocator: *mut OrtAllocator, + buffer: *mut *mut ::std::os::raw::c_char, + lengths: *mut *mut usize, + count: *mut usize, + ) -> OrtStatusPtr, + >, + pub GetBoundOutputValues: ::std::option::Option< + unsafe extern "C" fn( + binding_ptr: *const OrtIoBinding, + allocator: *mut OrtAllocator, + output: *mut *mut *mut OrtValue, + output_count: *mut usize, + ) -> OrtStatusPtr, + >, + #[doc = " \\brief Clears any previously set Inputs for an ::OrtIoBinding"] + pub ClearBoundInputs: + ::std::option::Option, + #[doc = " \\brief Clears any previously set Outputs for an ::OrtIoBinding"] + pub ClearBoundOutputs: + ::std::option::Option, + pub TensorAt: ::std::option::Option< + unsafe extern "C" fn( + value: *mut OrtValue, + location_values: *const i64, + location_values_count: usize, + out: *mut *mut ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub CreateAndRegisterAllocator: ::std::option::Option< + unsafe extern "C" fn( + env: *mut OrtEnv, + mem_info: *const OrtMemoryInfo, + arena_cfg: *const OrtArenaCfg, + ) -> OrtStatusPtr, + >, + pub SetLanguageProjection: ::std::option::Option< + unsafe extern "C" fn( + ort_env: *const OrtEnv, + projection: OrtLanguageProjection, + ) -> OrtStatusPtr, + >, + pub SessionGetProfilingStartTimeNs: ::std::option::Option< + unsafe extern "C" fn(session: *const OrtSession, out: *mut u64) -> OrtStatusPtr, + >, + pub SetGlobalIntraOpNumThreads: ::std::option::Option< + unsafe extern "C" fn( + tp_options: *mut OrtThreadingOptions, + intra_op_num_threads: ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub SetGlobalInterOpNumThreads: ::std::option::Option< + unsafe extern "C" fn( + tp_options: *mut OrtThreadingOptions, + inter_op_num_threads: ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub SetGlobalSpinControl: ::std::option::Option< + unsafe extern "C" fn( + tp_options: *mut OrtThreadingOptions, + allow_spinning: ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub AddInitializer: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + name: *const ::std::os::raw::c_char, + val: *const OrtValue, + ) -> OrtStatusPtr, + >, + pub CreateEnvWithCustomLoggerAndGlobalThreadPools: ::std::option::Option< + unsafe extern "C" fn( + logging_function: OrtLoggingFunction, + logger_param: *mut ::std::os::raw::c_void, + log_severity_level: OrtLoggingLevel, + logid: *const ::std::os::raw::c_char, + tp_options: *const OrtThreadingOptions, + out: *mut *mut OrtEnv, + ) -> OrtStatusPtr, + >, + pub SessionOptionsAppendExecutionProvider_CUDA: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + cuda_options: *const OrtCUDAProviderOptions, + ) -> OrtStatusPtr, + >, + pub SessionOptionsAppendExecutionProvider_ROCM: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + rocm_options: *const OrtROCMProviderOptions, + ) -> OrtStatusPtr, + >, + pub SessionOptionsAppendExecutionProvider_OpenVINO: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + provider_options: *const OrtOpenVINOProviderOptions, + ) -> OrtStatusPtr, + >, + pub SetGlobalDenormalAsZero: ::std::option::Option< + unsafe extern "C" fn(tp_options: *mut OrtThreadingOptions) -> OrtStatusPtr, + >, + pub CreateArenaCfg: ::std::option::Option< + unsafe extern "C" fn( + max_mem: usize, + arena_extend_strategy: ::std::os::raw::c_int, + initial_chunk_size_bytes: ::std::os::raw::c_int, + max_dead_bytes_per_chunk: ::std::os::raw::c_int, + out: *mut *mut OrtArenaCfg, + ) -> OrtStatusPtr, + >, + pub ReleaseArenaCfg: ::std::option::Option, + pub ModelMetadataGetGraphDescription: ::std::option::Option< + unsafe extern "C" fn( + model_metadata: *const OrtModelMetadata, + allocator: *mut OrtAllocator, + value: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub SessionOptionsAppendExecutionProvider_TensorRT: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + tensorrt_options: *const OrtTensorRTProviderOptions, + ) -> OrtStatusPtr, + >, + pub SetCurrentGpuDeviceId: ::std::option::Option< + unsafe extern "C" fn(device_id: ::std::os::raw::c_int) -> OrtStatusPtr, + >, + pub GetCurrentGpuDeviceId: ::std::option::Option< + unsafe extern "C" fn(device_id: *mut ::std::os::raw::c_int) -> OrtStatusPtr, + >, + pub KernelInfoGetAttributeArray_float: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtKernelInfo, + name: *const ::std::os::raw::c_char, + out: *mut f32, + size: *mut usize, + ) -> OrtStatusPtr, + >, + pub KernelInfoGetAttributeArray_int64: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtKernelInfo, + name: *const ::std::os::raw::c_char, + out: *mut i64, + size: *mut usize, + ) -> OrtStatusPtr, + >, + pub CreateArenaCfgV2: ::std::option::Option< + unsafe extern "C" fn( + arena_config_keys: *const *const ::std::os::raw::c_char, + arena_config_values: *const usize, + num_keys: usize, + out: *mut *mut OrtArenaCfg, + ) -> OrtStatusPtr, + >, + pub AddRunConfigEntry: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtRunOptions, + config_key: *const ::std::os::raw::c_char, + config_value: *const ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub CreatePrepackedWeightsContainer: ::std::option::Option< + unsafe extern "C" fn(out: *mut *mut OrtPrepackedWeightsContainer) -> OrtStatusPtr, + >, + pub ReleasePrepackedWeightsContainer: + ::std::option::Option, + pub CreateSessionWithPrepackedWeightsContainer: ::std::option::Option< + unsafe extern "C" fn( + env: *const OrtEnv, + model_path: *const ::std::os::raw::c_char, + options: *const OrtSessionOptions, + prepacked_weights_container: *mut OrtPrepackedWeightsContainer, + out: *mut *mut OrtSession, + ) -> OrtStatusPtr, + >, + pub CreateSessionFromArrayWithPrepackedWeightsContainer: ::std::option::Option< + unsafe extern "C" fn( + env: *const OrtEnv, + model_data: *const ::std::os::raw::c_void, + model_data_length: usize, + options: *const OrtSessionOptions, + prepacked_weights_container: *mut OrtPrepackedWeightsContainer, + out: *mut *mut OrtSession, + ) -> OrtStatusPtr, + >, + pub SessionOptionsAppendExecutionProvider_TensorRT_V2: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + tensorrt_options: *const OrtTensorRTProviderOptionsV2, + ) -> OrtStatusPtr, + >, + pub CreateTensorRTProviderOptions: ::std::option::Option< + unsafe extern "C" fn(out: *mut *mut OrtTensorRTProviderOptionsV2) -> OrtStatusPtr, + >, + pub UpdateTensorRTProviderOptions: ::std::option::Option< + unsafe extern "C" fn( + tensorrt_options: *mut OrtTensorRTProviderOptionsV2, + provider_options_keys: *const *const ::std::os::raw::c_char, + provider_options_values: *const *const ::std::os::raw::c_char, + num_keys: usize, + ) -> OrtStatusPtr, + >, + pub GetTensorRTProviderOptionsAsString: ::std::option::Option< + unsafe extern "C" fn( + tensorrt_options: *const OrtTensorRTProviderOptionsV2, + allocator: *mut OrtAllocator, + ptr: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + #[doc = " \\brief Release an ::OrtTensorRTProviderOptionsV2"] + #[doc = ""] + #[doc = " \\note This is an exception in the naming convention of other Release* functions, as the name of the method does not have the V2 suffix, but the type does"] + pub ReleaseTensorRTProviderOptions: + ::std::option::Option, + pub EnableOrtCustomOps: ::std::option::Option< + unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, + >, + pub RegisterAllocator: ::std::option::Option< + unsafe extern "C" fn(env: *mut OrtEnv, allocator: *mut OrtAllocator) -> OrtStatusPtr, + >, + pub UnregisterAllocator: ::std::option::Option< + unsafe extern "C" fn(env: *mut OrtEnv, mem_info: *const OrtMemoryInfo) -> OrtStatusPtr, + >, + pub IsSparseTensor: ::std::option::Option< + unsafe extern "C" fn( + value: *const OrtValue, + out: *mut ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub CreateSparseTensorAsOrtValue: ::std::option::Option< + unsafe extern "C" fn( + allocator: *mut OrtAllocator, + dense_shape: *const i64, + dense_shape_len: usize, + type_: ONNXTensorElementDataType, + out: *mut *mut OrtValue, + ) -> OrtStatusPtr, + >, + pub FillSparseTensorCoo: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *mut OrtValue, + data_mem_info: *const OrtMemoryInfo, + values_shape: *const i64, + values_shape_len: usize, + values: *const ::std::os::raw::c_void, + indices_data: *const i64, + indices_num: usize, + ) -> OrtStatusPtr, + >, + pub FillSparseTensorCsr: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *mut OrtValue, + data_mem_info: *const OrtMemoryInfo, + values_shape: *const i64, + values_shape_len: usize, + values: *const ::std::os::raw::c_void, + inner_indices_data: *const i64, + inner_indices_num: usize, + outer_indices_data: *const i64, + outer_indices_num: usize, + ) -> OrtStatusPtr, + >, + pub FillSparseTensorBlockSparse: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *mut OrtValue, + data_mem_info: *const OrtMemoryInfo, + values_shape: *const i64, + values_shape_len: usize, + values: *const ::std::os::raw::c_void, + indices_shape_data: *const i64, + indices_shape_len: usize, + indices_data: *const i32, + ) -> OrtStatusPtr, + >, + pub CreateSparseTensorWithValuesAsOrtValue: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtMemoryInfo, + p_data: *mut ::std::os::raw::c_void, + dense_shape: *const i64, + dense_shape_len: usize, + values_shape: *const i64, + values_shape_len: usize, + type_: ONNXTensorElementDataType, + out: *mut *mut OrtValue, + ) -> OrtStatusPtr, + >, + pub UseCooIndices: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *mut OrtValue, + indices_data: *mut i64, + indices_num: usize, + ) -> OrtStatusPtr, + >, + pub UseCsrIndices: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *mut OrtValue, + inner_data: *mut i64, + inner_num: usize, + outer_data: *mut i64, + outer_num: usize, + ) -> OrtStatusPtr, + >, + pub UseBlockSparseIndices: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *mut OrtValue, + indices_shape: *const i64, + indices_shape_len: usize, + indices_data: *mut i32, + ) -> OrtStatusPtr, + >, + pub GetSparseTensorFormat: ::std::option::Option< + unsafe extern "C" fn(ort_value: *const OrtValue, out: *mut OrtSparseFormat) -> OrtStatusPtr, + >, + pub GetSparseTensorValuesTypeAndShape: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *const OrtValue, + out: *mut *mut OrtTensorTypeAndShapeInfo, + ) -> OrtStatusPtr, + >, + pub GetSparseTensorValues: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *const OrtValue, + out: *mut *const ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub GetSparseTensorIndicesTypeShape: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *const OrtValue, + indices_format: OrtSparseIndicesFormat, + out: *mut *mut OrtTensorTypeAndShapeInfo, + ) -> OrtStatusPtr, + >, + pub GetSparseTensorIndices: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *const OrtValue, + indices_format: OrtSparseIndicesFormat, + num_indices: *mut usize, + indices: *mut *const ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub HasValue: ::std::option::Option< + unsafe extern "C" fn( + value: *const OrtValue, + out: *mut ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub KernelContext_GetGPUComputeStream: ::std::option::Option< + unsafe extern "C" fn( + context: *const OrtKernelContext, + out: *mut *mut ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub GetTensorMemoryInfo: ::std::option::Option< + unsafe extern "C" fn( + value: *const OrtValue, + mem_info: *mut *const OrtMemoryInfo, + ) -> OrtStatusPtr, + >, + pub GetExecutionProviderApi: ::std::option::Option< + unsafe extern "C" fn( + provider_name: *const ::std::os::raw::c_char, + version: u32, + provider_api: *mut *const ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub SessionOptionsSetCustomCreateThreadFn: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + ort_custom_create_thread_fn: OrtCustomCreateThreadFn, + ) -> OrtStatusPtr, + >, + pub SessionOptionsSetCustomThreadCreationOptions: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + ort_custom_thread_creation_options: *mut ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub SessionOptionsSetCustomJoinThreadFn: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + ort_custom_join_thread_fn: OrtCustomJoinThreadFn, + ) -> OrtStatusPtr, + >, + pub SetGlobalCustomCreateThreadFn: ::std::option::Option< + unsafe extern "C" fn( + tp_options: *mut OrtThreadingOptions, + ort_custom_create_thread_fn: OrtCustomCreateThreadFn, + ) -> OrtStatusPtr, + >, + pub SetGlobalCustomThreadCreationOptions: ::std::option::Option< + unsafe extern "C" fn( + tp_options: *mut OrtThreadingOptions, + ort_custom_thread_creation_options: *mut ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub SetGlobalCustomJoinThreadFn: ::std::option::Option< + unsafe extern "C" fn( + tp_options: *mut OrtThreadingOptions, + ort_custom_join_thread_fn: OrtCustomJoinThreadFn, + ) -> OrtStatusPtr, + >, + pub SynchronizeBoundInputs: + ::std::option::Option OrtStatusPtr>, + pub SynchronizeBoundOutputs: + ::std::option::Option OrtStatusPtr>, + pub SessionOptionsAppendExecutionProvider_CUDA_V2: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + cuda_options: *const OrtCUDAProviderOptionsV2, + ) -> OrtStatusPtr, + >, + pub CreateCUDAProviderOptions: ::std::option::Option< + unsafe extern "C" fn(out: *mut *mut OrtCUDAProviderOptionsV2) -> OrtStatusPtr, + >, + pub UpdateCUDAProviderOptions: ::std::option::Option< + unsafe extern "C" fn( + cuda_options: *mut OrtCUDAProviderOptionsV2, + provider_options_keys: *const *const ::std::os::raw::c_char, + provider_options_values: *const *const ::std::os::raw::c_char, + num_keys: usize, + ) -> OrtStatusPtr, + >, + pub GetCUDAProviderOptionsAsString: ::std::option::Option< + unsafe extern "C" fn( + cuda_options: *const OrtCUDAProviderOptionsV2, + allocator: *mut OrtAllocator, + ptr: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + #[doc = " \\brief Release an ::OrtCUDAProviderOptionsV2"] + #[doc = ""] + #[doc = " \\note This is an exception in the naming convention of other Release* functions, as the name of the method does not have the V2 suffix, but the type does"] + #[doc = ""] + #[doc = " \\since Version 1.11."] + pub ReleaseCUDAProviderOptions: + ::std::option::Option, + pub SessionOptionsAppendExecutionProvider_MIGraphX: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + migraphx_options: *const OrtMIGraphXProviderOptions, + ) -> OrtStatusPtr, + >, +} +#[test] +fn bindgen_test_layout_OrtApi() { assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateSessionWithPrepackedWeightsContainer - as *const _ as usize - }, - 1344usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateSessionWithPrepackedWeightsContainer) - ) + ::std::mem::size_of::(), + 1680usize, + concat!("Size of: ", stringify!(OrtApi)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateSessionFromArrayWithPrepackedWeightsContainer - as *const _ as usize - }, - 1352usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateSessionFromArrayWithPrepackedWeightsContainer) - ) + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(OrtApi)) ); + fn test_field_CreateStatus() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateStatus) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateStatus) + ) + ); + } + test_field_CreateStatus(); + fn test_field_GetErrorCode() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetErrorCode) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetErrorCode) + ) + ); + } + test_field_GetErrorCode(); + fn test_field_GetErrorMessage() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetErrorMessage) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetErrorMessage) + ) + ); + } + test_field_GetErrorMessage(); + fn test_field_CreateEnv() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateEnv) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateEnv) + ) + ); + } + test_field_CreateEnv(); + fn test_field_CreateEnvWithCustomLogger() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateEnvWithCustomLogger) as usize - ptr as usize + }, + 32usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateEnvWithCustomLogger) + ) + ); + } + test_field_CreateEnvWithCustomLogger(); + fn test_field_EnableTelemetryEvents() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).EnableTelemetryEvents) as usize - ptr as usize + }, + 40usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(EnableTelemetryEvents) + ) + ); + } + test_field_EnableTelemetryEvents(); + fn test_field_DisableTelemetryEvents() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).DisableTelemetryEvents) as usize - ptr as usize + }, + 48usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(DisableTelemetryEvents) + ) + ); + } + test_field_DisableTelemetryEvents(); + fn test_field_CreateSession() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateSession) as usize - ptr as usize + }, + 56usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateSession) + ) + ); + } + test_field_CreateSession(); + fn test_field_CreateSessionFromArray() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateSessionFromArray) as usize - ptr as usize + }, + 64usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateSessionFromArray) + ) + ); + } + test_field_CreateSessionFromArray(); + fn test_field_Run() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).Run) as usize - ptr as usize + }, + 72usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(Run) + ) + ); + } + test_field_Run(); + fn test_field_CreateSessionOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateSessionOptions) as usize - ptr as usize + }, + 80usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateSessionOptions) + ) + ); + } + test_field_CreateSessionOptions(); + fn test_field_SetOptimizedModelFilePath() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetOptimizedModelFilePath) as usize - ptr as usize + }, + 88usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetOptimizedModelFilePath) + ) + ); + } + test_field_SetOptimizedModelFilePath(); + fn test_field_CloneSessionOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CloneSessionOptions) as usize - ptr as usize + }, + 96usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CloneSessionOptions) + ) + ); + } + test_field_CloneSessionOptions(); + fn test_field_SetSessionExecutionMode() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetSessionExecutionMode) as usize - ptr as usize + }, + 104usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetSessionExecutionMode) + ) + ); + } + test_field_SetSessionExecutionMode(); + fn test_field_EnableProfiling() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).EnableProfiling) as usize - ptr as usize + }, + 112usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(EnableProfiling) + ) + ); + } + test_field_EnableProfiling(); + fn test_field_DisableProfiling() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).DisableProfiling) as usize - ptr as usize + }, + 120usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(DisableProfiling) + ) + ); + } + test_field_DisableProfiling(); + fn test_field_EnableMemPattern() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).EnableMemPattern) as usize - ptr as usize + }, + 128usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(EnableMemPattern) + ) + ); + } + test_field_EnableMemPattern(); + fn test_field_DisableMemPattern() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).DisableMemPattern) as usize - ptr as usize + }, + 136usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(DisableMemPattern) + ) + ); + } + test_field_DisableMemPattern(); + fn test_field_EnableCpuMemArena() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).EnableCpuMemArena) as usize - ptr as usize + }, + 144usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(EnableCpuMemArena) + ) + ); + } + test_field_EnableCpuMemArena(); + fn test_field_DisableCpuMemArena() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).DisableCpuMemArena) as usize - ptr as usize + }, + 152usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(DisableCpuMemArena) + ) + ); + } + test_field_DisableCpuMemArena(); + fn test_field_SetSessionLogId() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetSessionLogId) as usize - ptr as usize + }, + 160usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetSessionLogId) + ) + ); + } + test_field_SetSessionLogId(); + fn test_field_SetSessionLogVerbosityLevel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetSessionLogVerbosityLevel) as usize - ptr as usize + }, + 168usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetSessionLogVerbosityLevel) + ) + ); + } + test_field_SetSessionLogVerbosityLevel(); + fn test_field_SetSessionLogSeverityLevel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetSessionLogSeverityLevel) as usize - ptr as usize + }, + 176usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetSessionLogSeverityLevel) + ) + ); + } + test_field_SetSessionLogSeverityLevel(); + fn test_field_SetSessionGraphOptimizationLevel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetSessionGraphOptimizationLevel) as usize + - ptr as usize + }, + 184usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetSessionGraphOptimizationLevel) + ) + ); + } + test_field_SetSessionGraphOptimizationLevel(); + fn test_field_SetIntraOpNumThreads() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetIntraOpNumThreads) as usize - ptr as usize + }, + 192usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetIntraOpNumThreads) + ) + ); + } + test_field_SetIntraOpNumThreads(); + fn test_field_SetInterOpNumThreads() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetInterOpNumThreads) as usize - ptr as usize + }, + 200usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetInterOpNumThreads) + ) + ); + } + test_field_SetInterOpNumThreads(); + fn test_field_CreateCustomOpDomain() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateCustomOpDomain) as usize - ptr as usize + }, + 208usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateCustomOpDomain) + ) + ); + } + test_field_CreateCustomOpDomain(); + fn test_field_CustomOpDomain_Add() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CustomOpDomain_Add) as usize - ptr as usize + }, + 216usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CustomOpDomain_Add) + ) + ); + } + test_field_CustomOpDomain_Add(); + fn test_field_AddCustomOpDomain() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AddCustomOpDomain) as usize - ptr as usize + }, + 224usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AddCustomOpDomain) + ) + ); + } + test_field_AddCustomOpDomain(); + fn test_field_RegisterCustomOpsLibrary() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RegisterCustomOpsLibrary) as usize - ptr as usize + }, + 232usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RegisterCustomOpsLibrary) + ) + ); + } + test_field_RegisterCustomOpsLibrary(); + fn test_field_SessionGetInputCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetInputCount) as usize - ptr as usize + }, + 240usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetInputCount) + ) + ); + } + test_field_SessionGetInputCount(); + fn test_field_SessionGetOutputCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetOutputCount) as usize - ptr as usize + }, + 248usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetOutputCount) + ) + ); + } + test_field_SessionGetOutputCount(); + fn test_field_SessionGetOverridableInitializerCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetOverridableInitializerCount) as usize + - ptr as usize + }, + 256usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetOverridableInitializerCount) + ) + ); + } + test_field_SessionGetOverridableInitializerCount(); + fn test_field_SessionGetInputTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetInputTypeInfo) as usize - ptr as usize + }, + 264usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetInputTypeInfo) + ) + ); + } + test_field_SessionGetInputTypeInfo(); + fn test_field_SessionGetOutputTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetOutputTypeInfo) as usize - ptr as usize + }, + 272usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetOutputTypeInfo) + ) + ); + } + test_field_SessionGetOutputTypeInfo(); + fn test_field_SessionGetOverridableInitializerTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetOverridableInitializerTypeInfo) as usize + - ptr as usize + }, + 280usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetOverridableInitializerTypeInfo) + ) + ); + } + test_field_SessionGetOverridableInitializerTypeInfo(); + fn test_field_SessionGetInputName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetInputName) as usize - ptr as usize + }, + 288usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetInputName) + ) + ); + } + test_field_SessionGetInputName(); + fn test_field_SessionGetOutputName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetOutputName) as usize - ptr as usize + }, + 296usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetOutputName) + ) + ); + } + test_field_SessionGetOutputName(); + fn test_field_SessionGetOverridableInitializerName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetOverridableInitializerName) as usize + - ptr as usize + }, + 304usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetOverridableInitializerName) + ) + ); + } + test_field_SessionGetOverridableInitializerName(); + fn test_field_CreateRunOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateRunOptions) as usize - ptr as usize + }, + 312usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateRunOptions) + ) + ); + } + test_field_CreateRunOptions(); + fn test_field_RunOptionsSetRunLogVerbosityLevel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsSetRunLogVerbosityLevel) as usize + - ptr as usize + }, + 320usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsSetRunLogVerbosityLevel) + ) + ); + } + test_field_RunOptionsSetRunLogVerbosityLevel(); + fn test_field_RunOptionsSetRunLogSeverityLevel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsSetRunLogSeverityLevel) as usize + - ptr as usize + }, + 328usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsSetRunLogSeverityLevel) + ) + ); + } + test_field_RunOptionsSetRunLogSeverityLevel(); + fn test_field_RunOptionsSetRunTag() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsSetRunTag) as usize - ptr as usize + }, + 336usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsSetRunTag) + ) + ); + } + test_field_RunOptionsSetRunTag(); + fn test_field_RunOptionsGetRunLogVerbosityLevel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsGetRunLogVerbosityLevel) as usize + - ptr as usize + }, + 344usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsGetRunLogVerbosityLevel) + ) + ); + } + test_field_RunOptionsGetRunLogVerbosityLevel(); + fn test_field_RunOptionsGetRunLogSeverityLevel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsGetRunLogSeverityLevel) as usize + - ptr as usize + }, + 352usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsGetRunLogSeverityLevel) + ) + ); + } + test_field_RunOptionsGetRunLogSeverityLevel(); + fn test_field_RunOptionsGetRunTag() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsGetRunTag) as usize - ptr as usize + }, + 360usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsGetRunTag) + ) + ); + } + test_field_RunOptionsGetRunTag(); + fn test_field_RunOptionsSetTerminate() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsSetTerminate) as usize - ptr as usize + }, + 368usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsSetTerminate) + ) + ); + } + test_field_RunOptionsSetTerminate(); + fn test_field_RunOptionsUnsetTerminate() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsUnsetTerminate) as usize - ptr as usize + }, + 376usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsUnsetTerminate) + ) + ); + } + test_field_RunOptionsUnsetTerminate(); + fn test_field_CreateTensorAsOrtValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateTensorAsOrtValue) as usize - ptr as usize + }, + 384usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateTensorAsOrtValue) + ) + ); + } + test_field_CreateTensorAsOrtValue(); + fn test_field_CreateTensorWithDataAsOrtValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateTensorWithDataAsOrtValue) as usize - ptr as usize + }, + 392usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateTensorWithDataAsOrtValue) + ) + ); + } + test_field_CreateTensorWithDataAsOrtValue(); + fn test_field_IsTensor() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).IsTensor) as usize - ptr as usize + }, + 400usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(IsTensor) + ) + ); + } + test_field_IsTensor(); + fn test_field_GetTensorMutableData() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetTensorMutableData) as usize - ptr as usize + }, + 408usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetTensorMutableData) + ) + ); + } + test_field_GetTensorMutableData(); + fn test_field_FillStringTensor() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).FillStringTensor) as usize - ptr as usize + }, + 416usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(FillStringTensor) + ) + ); + } + test_field_FillStringTensor(); + fn test_field_GetStringTensorDataLength() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetStringTensorDataLength) as usize - ptr as usize + }, + 424usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetStringTensorDataLength) + ) + ); + } + test_field_GetStringTensorDataLength(); + fn test_field_GetStringTensorContent() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetStringTensorContent) as usize - ptr as usize + }, + 432usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetStringTensorContent) + ) + ); + } + test_field_GetStringTensorContent(); + fn test_field_CastTypeInfoToTensorInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CastTypeInfoToTensorInfo) as usize - ptr as usize + }, + 440usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CastTypeInfoToTensorInfo) + ) + ); + } + test_field_CastTypeInfoToTensorInfo(); + fn test_field_GetOnnxTypeFromTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetOnnxTypeFromTypeInfo) as usize - ptr as usize + }, + 448usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetOnnxTypeFromTypeInfo) + ) + ); + } + test_field_GetOnnxTypeFromTypeInfo(); + fn test_field_CreateTensorTypeAndShapeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateTensorTypeAndShapeInfo) as usize - ptr as usize + }, + 456usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateTensorTypeAndShapeInfo) + ) + ); + } + test_field_CreateTensorTypeAndShapeInfo(); + fn test_field_SetTensorElementType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetTensorElementType) as usize - ptr as usize + }, + 464usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetTensorElementType) + ) + ); + } + test_field_SetTensorElementType(); + fn test_field_SetDimensions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetDimensions) as usize - ptr as usize + }, + 472usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetDimensions) + ) + ); + } + test_field_SetDimensions(); + fn test_field_GetTensorElementType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetTensorElementType) as usize - ptr as usize + }, + 480usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetTensorElementType) + ) + ); + } + test_field_GetTensorElementType(); + fn test_field_GetDimensionsCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetDimensionsCount) as usize - ptr as usize + }, + 488usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetDimensionsCount) + ) + ); + } + test_field_GetDimensionsCount(); + fn test_field_GetDimensions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetDimensions) as usize - ptr as usize + }, + 496usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetDimensions) + ) + ); + } + test_field_GetDimensions(); + fn test_field_GetSymbolicDimensions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetSymbolicDimensions) as usize - ptr as usize + }, + 504usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetSymbolicDimensions) + ) + ); + } + test_field_GetSymbolicDimensions(); + fn test_field_GetTensorShapeElementCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetTensorShapeElementCount) as usize - ptr as usize + }, + 512usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetTensorShapeElementCount) + ) + ); + } + test_field_GetTensorShapeElementCount(); + fn test_field_GetTensorTypeAndShape() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetTensorTypeAndShape) as usize - ptr as usize + }, + 520usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetTensorTypeAndShape) + ) + ); + } + test_field_GetTensorTypeAndShape(); + fn test_field_GetTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetTypeInfo) as usize - ptr as usize + }, + 528usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetTypeInfo) + ) + ); + } + test_field_GetTypeInfo(); + fn test_field_GetValueType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetValueType) as usize - ptr as usize + }, + 536usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetValueType) + ) + ); + } + test_field_GetValueType(); + fn test_field_CreateMemoryInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateMemoryInfo) as usize - ptr as usize + }, + 544usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateMemoryInfo) + ) + ); + } + test_field_CreateMemoryInfo(); + fn test_field_CreateCpuMemoryInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateCpuMemoryInfo) as usize - ptr as usize + }, + 552usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateCpuMemoryInfo) + ) + ); + } + test_field_CreateCpuMemoryInfo(); + fn test_field_CompareMemoryInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CompareMemoryInfo) as usize - ptr as usize + }, + 560usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CompareMemoryInfo) + ) + ); + } + test_field_CompareMemoryInfo(); + fn test_field_MemoryInfoGetName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).MemoryInfoGetName) as usize - ptr as usize + }, + 568usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(MemoryInfoGetName) + ) + ); + } + test_field_MemoryInfoGetName(); + fn test_field_MemoryInfoGetId() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).MemoryInfoGetId) as usize - ptr as usize + }, + 576usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(MemoryInfoGetId) + ) + ); + } + test_field_MemoryInfoGetId(); + fn test_field_MemoryInfoGetMemType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).MemoryInfoGetMemType) as usize - ptr as usize + }, + 584usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(MemoryInfoGetMemType) + ) + ); + } + test_field_MemoryInfoGetMemType(); + fn test_field_MemoryInfoGetType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).MemoryInfoGetType) as usize - ptr as usize + }, + 592usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(MemoryInfoGetType) + ) + ); + } + test_field_MemoryInfoGetType(); + fn test_field_AllocatorAlloc() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AllocatorAlloc) as usize - ptr as usize + }, + 600usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AllocatorAlloc) + ) + ); + } + test_field_AllocatorAlloc(); + fn test_field_AllocatorFree() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AllocatorFree) as usize - ptr as usize + }, + 608usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AllocatorFree) + ) + ); + } + test_field_AllocatorFree(); + fn test_field_AllocatorGetInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AllocatorGetInfo) as usize - ptr as usize + }, + 616usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AllocatorGetInfo) + ) + ); + } + test_field_AllocatorGetInfo(); + fn test_field_GetAllocatorWithDefaultOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetAllocatorWithDefaultOptions) as usize - ptr as usize + }, + 624usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetAllocatorWithDefaultOptions) + ) + ); + } + test_field_GetAllocatorWithDefaultOptions(); + fn test_field_AddFreeDimensionOverride() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AddFreeDimensionOverride) as usize - ptr as usize + }, + 632usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AddFreeDimensionOverride) + ) + ); + } + test_field_AddFreeDimensionOverride(); + fn test_field_GetValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetValue) as usize - ptr as usize + }, + 640usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetValue) + ) + ); + } + test_field_GetValue(); + fn test_field_GetValueCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetValueCount) as usize - ptr as usize + }, + 648usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetValueCount) + ) + ); + } + test_field_GetValueCount(); + fn test_field_CreateValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateValue) as usize - ptr as usize + }, + 656usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateValue) + ) + ); + } + test_field_CreateValue(); + fn test_field_CreateOpaqueValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateOpaqueValue) as usize - ptr as usize + }, + 664usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateOpaqueValue) + ) + ); + } + test_field_CreateOpaqueValue(); + fn test_field_GetOpaqueValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetOpaqueValue) as usize - ptr as usize + }, + 672usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetOpaqueValue) + ) + ); + } + test_field_GetOpaqueValue(); + fn test_field_KernelInfoGetAttribute_float() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelInfoGetAttribute_float) as usize - ptr as usize + }, + 680usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelInfoGetAttribute_float) + ) + ); + } + test_field_KernelInfoGetAttribute_float(); + fn test_field_KernelInfoGetAttribute_int64() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelInfoGetAttribute_int64) as usize - ptr as usize + }, + 688usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelInfoGetAttribute_int64) + ) + ); + } + test_field_KernelInfoGetAttribute_int64(); + fn test_field_KernelInfoGetAttribute_string() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelInfoGetAttribute_string) as usize - ptr as usize + }, + 696usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelInfoGetAttribute_string) + ) + ); + } + test_field_KernelInfoGetAttribute_string(); + fn test_field_KernelContext_GetInputCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelContext_GetInputCount) as usize - ptr as usize + }, + 704usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelContext_GetInputCount) + ) + ); + } + test_field_KernelContext_GetInputCount(); + fn test_field_KernelContext_GetOutputCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelContext_GetOutputCount) as usize - ptr as usize + }, + 712usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelContext_GetOutputCount) + ) + ); + } + test_field_KernelContext_GetOutputCount(); + fn test_field_KernelContext_GetInput() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelContext_GetInput) as usize - ptr as usize + }, + 720usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelContext_GetInput) + ) + ); + } + test_field_KernelContext_GetInput(); + fn test_field_KernelContext_GetOutput() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelContext_GetOutput) as usize - ptr as usize + }, + 728usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelContext_GetOutput) + ) + ); + } + test_field_KernelContext_GetOutput(); + fn test_field_ReleaseEnv() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseEnv) as usize - ptr as usize + }, + 736usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseEnv) + ) + ); + } + test_field_ReleaseEnv(); + fn test_field_ReleaseStatus() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseStatus) as usize - ptr as usize + }, + 744usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseStatus) + ) + ); + } + test_field_ReleaseStatus(); + fn test_field_ReleaseMemoryInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseMemoryInfo) as usize - ptr as usize + }, + 752usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseMemoryInfo) + ) + ); + } + test_field_ReleaseMemoryInfo(); + fn test_field_ReleaseSession() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseSession) as usize - ptr as usize + }, + 760usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseSession) + ) + ); + } + test_field_ReleaseSession(); + fn test_field_ReleaseValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseValue) as usize - ptr as usize + }, + 768usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseValue) + ) + ); + } + test_field_ReleaseValue(); + fn test_field_ReleaseRunOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseRunOptions) as usize - ptr as usize + }, + 776usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseRunOptions) + ) + ); + } + test_field_ReleaseRunOptions(); + fn test_field_ReleaseTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseTypeInfo) as usize - ptr as usize + }, + 784usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseTypeInfo) + ) + ); + } + test_field_ReleaseTypeInfo(); + fn test_field_ReleaseTensorTypeAndShapeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseTensorTypeAndShapeInfo) as usize - ptr as usize + }, + 792usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseTensorTypeAndShapeInfo) + ) + ); + } + test_field_ReleaseTensorTypeAndShapeInfo(); + fn test_field_ReleaseSessionOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseSessionOptions) as usize - ptr as usize + }, + 800usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseSessionOptions) + ) + ); + } + test_field_ReleaseSessionOptions(); + fn test_field_ReleaseCustomOpDomain() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseCustomOpDomain) as usize - ptr as usize + }, + 808usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseCustomOpDomain) + ) + ); + } + test_field_ReleaseCustomOpDomain(); + fn test_field_GetDenotationFromTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetDenotationFromTypeInfo) as usize - ptr as usize + }, + 816usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetDenotationFromTypeInfo) + ) + ); + } + test_field_GetDenotationFromTypeInfo(); + fn test_field_CastTypeInfoToMapTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CastTypeInfoToMapTypeInfo) as usize - ptr as usize + }, + 824usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CastTypeInfoToMapTypeInfo) + ) + ); + } + test_field_CastTypeInfoToMapTypeInfo(); + fn test_field_CastTypeInfoToSequenceTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CastTypeInfoToSequenceTypeInfo) as usize - ptr as usize + }, + 832usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CastTypeInfoToSequenceTypeInfo) + ) + ); + } + test_field_CastTypeInfoToSequenceTypeInfo(); + fn test_field_GetMapKeyType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetMapKeyType) as usize - ptr as usize + }, + 840usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetMapKeyType) + ) + ); + } + test_field_GetMapKeyType(); + fn test_field_GetMapValueType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetMapValueType) as usize - ptr as usize + }, + 848usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetMapValueType) + ) + ); + } + test_field_GetMapValueType(); + fn test_field_GetSequenceElementType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetSequenceElementType) as usize - ptr as usize + }, + 856usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetSequenceElementType) + ) + ); + } + test_field_GetSequenceElementType(); + fn test_field_ReleaseMapTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseMapTypeInfo) as usize - ptr as usize + }, + 864usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseMapTypeInfo) + ) + ); + } + test_field_ReleaseMapTypeInfo(); + fn test_field_ReleaseSequenceTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseSequenceTypeInfo) as usize - ptr as usize + }, + 872usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseSequenceTypeInfo) + ) + ); + } + test_field_ReleaseSequenceTypeInfo(); + fn test_field_SessionEndProfiling() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionEndProfiling) as usize - ptr as usize + }, + 880usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionEndProfiling) + ) + ); + } + test_field_SessionEndProfiling(); + fn test_field_SessionGetModelMetadata() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetModelMetadata) as usize - ptr as usize + }, + 888usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetModelMetadata) + ) + ); + } + test_field_SessionGetModelMetadata(); + fn test_field_ModelMetadataGetProducerName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataGetProducerName) as usize - ptr as usize + }, + 896usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataGetProducerName) + ) + ); + } + test_field_ModelMetadataGetProducerName(); + fn test_field_ModelMetadataGetGraphName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataGetGraphName) as usize - ptr as usize + }, + 904usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataGetGraphName) + ) + ); + } + test_field_ModelMetadataGetGraphName(); + fn test_field_ModelMetadataGetDomain() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataGetDomain) as usize - ptr as usize + }, + 912usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataGetDomain) + ) + ); + } + test_field_ModelMetadataGetDomain(); + fn test_field_ModelMetadataGetDescription() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataGetDescription) as usize - ptr as usize + }, + 920usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataGetDescription) + ) + ); + } + test_field_ModelMetadataGetDescription(); + fn test_field_ModelMetadataLookupCustomMetadataMap() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataLookupCustomMetadataMap) as usize + - ptr as usize + }, + 928usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataLookupCustomMetadataMap) + ) + ); + } + test_field_ModelMetadataLookupCustomMetadataMap(); + fn test_field_ModelMetadataGetVersion() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataGetVersion) as usize - ptr as usize + }, + 936usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataGetVersion) + ) + ); + } + test_field_ModelMetadataGetVersion(); + fn test_field_ReleaseModelMetadata() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseModelMetadata) as usize - ptr as usize + }, + 944usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseModelMetadata) + ) + ); + } + test_field_ReleaseModelMetadata(); + fn test_field_CreateEnvWithGlobalThreadPools() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateEnvWithGlobalThreadPools) as usize - ptr as usize + }, + 952usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateEnvWithGlobalThreadPools) + ) + ); + } + test_field_CreateEnvWithGlobalThreadPools(); + fn test_field_DisablePerSessionThreads() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).DisablePerSessionThreads) as usize - ptr as usize + }, + 960usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(DisablePerSessionThreads) + ) + ); + } + test_field_DisablePerSessionThreads(); + fn test_field_CreateThreadingOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateThreadingOptions) as usize - ptr as usize + }, + 968usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateThreadingOptions) + ) + ); + } + test_field_CreateThreadingOptions(); + fn test_field_ReleaseThreadingOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseThreadingOptions) as usize - ptr as usize + }, + 976usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseThreadingOptions) + ) + ); + } + test_field_ReleaseThreadingOptions(); + fn test_field_ModelMetadataGetCustomMetadataMapKeys() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataGetCustomMetadataMapKeys) as usize + - ptr as usize + }, + 984usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataGetCustomMetadataMapKeys) + ) + ); + } + test_field_ModelMetadataGetCustomMetadataMapKeys(); + fn test_field_AddFreeDimensionOverrideByName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AddFreeDimensionOverrideByName) as usize - ptr as usize + }, + 992usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AddFreeDimensionOverrideByName) + ) + ); + } + test_field_AddFreeDimensionOverrideByName(); + fn test_field_GetAvailableProviders() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetAvailableProviders) as usize - ptr as usize + }, + 1000usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetAvailableProviders) + ) + ); + } + test_field_GetAvailableProviders(); + fn test_field_ReleaseAvailableProviders() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseAvailableProviders) as usize - ptr as usize + }, + 1008usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseAvailableProviders) + ) + ); + } + test_field_ReleaseAvailableProviders(); + fn test_field_GetStringTensorElementLength() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetStringTensorElementLength) as usize - ptr as usize + }, + 1016usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetStringTensorElementLength) + ) + ); + } + test_field_GetStringTensorElementLength(); + fn test_field_GetStringTensorElement() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetStringTensorElement) as usize - ptr as usize + }, + 1024usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetStringTensorElement) + ) + ); + } + test_field_GetStringTensorElement(); + fn test_field_FillStringTensorElement() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).FillStringTensorElement) as usize - ptr as usize + }, + 1032usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(FillStringTensorElement) + ) + ); + } + test_field_FillStringTensorElement(); + fn test_field_AddSessionConfigEntry() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AddSessionConfigEntry) as usize - ptr as usize + }, + 1040usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AddSessionConfigEntry) + ) + ); + } + test_field_AddSessionConfigEntry(); + fn test_field_CreateAllocator() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateAllocator) as usize - ptr as usize + }, + 1048usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateAllocator) + ) + ); + } + test_field_CreateAllocator(); + fn test_field_ReleaseAllocator() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseAllocator) as usize - ptr as usize + }, + 1056usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseAllocator) + ) + ); + } + test_field_ReleaseAllocator(); + fn test_field_RunWithBinding() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunWithBinding) as usize - ptr as usize + }, + 1064usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunWithBinding) + ) + ); + } + test_field_RunWithBinding(); + fn test_field_CreateIoBinding() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateIoBinding) as usize - ptr as usize + }, + 1072usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateIoBinding) + ) + ); + } + test_field_CreateIoBinding(); + fn test_field_ReleaseIoBinding() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseIoBinding) as usize - ptr as usize + }, + 1080usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseIoBinding) + ) + ); + } + test_field_ReleaseIoBinding(); + fn test_field_BindInput() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).BindInput) as usize - ptr as usize + }, + 1088usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(BindInput) + ) + ); + } + test_field_BindInput(); + fn test_field_BindOutput() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).BindOutput) as usize - ptr as usize + }, + 1096usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(BindOutput) + ) + ); + } + test_field_BindOutput(); + fn test_field_BindOutputToDevice() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).BindOutputToDevice) as usize - ptr as usize + }, + 1104usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(BindOutputToDevice) + ) + ); + } + test_field_BindOutputToDevice(); + fn test_field_GetBoundOutputNames() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetBoundOutputNames) as usize - ptr as usize + }, + 1112usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetBoundOutputNames) + ) + ); + } + test_field_GetBoundOutputNames(); + fn test_field_GetBoundOutputValues() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetBoundOutputValues) as usize - ptr as usize + }, + 1120usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetBoundOutputValues) + ) + ); + } + test_field_GetBoundOutputValues(); + fn test_field_ClearBoundInputs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ClearBoundInputs) as usize - ptr as usize + }, + 1128usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ClearBoundInputs) + ) + ); + } + test_field_ClearBoundInputs(); + fn test_field_ClearBoundOutputs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ClearBoundOutputs) as usize - ptr as usize + }, + 1136usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ClearBoundOutputs) + ) + ); + } + test_field_ClearBoundOutputs(); + fn test_field_TensorAt() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).TensorAt) as usize - ptr as usize + }, + 1144usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(TensorAt) + ) + ); + } + test_field_TensorAt(); + fn test_field_CreateAndRegisterAllocator() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateAndRegisterAllocator) as usize - ptr as usize + }, + 1152usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateAndRegisterAllocator) + ) + ); + } + test_field_CreateAndRegisterAllocator(); + fn test_field_SetLanguageProjection() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetLanguageProjection) as usize - ptr as usize + }, + 1160usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetLanguageProjection) + ) + ); + } + test_field_SetLanguageProjection(); + fn test_field_SessionGetProfilingStartTimeNs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetProfilingStartTimeNs) as usize - ptr as usize + }, + 1168usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetProfilingStartTimeNs) + ) + ); + } + test_field_SessionGetProfilingStartTimeNs(); + fn test_field_SetGlobalIntraOpNumThreads() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetGlobalIntraOpNumThreads) as usize - ptr as usize + }, + 1176usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetGlobalIntraOpNumThreads) + ) + ); + } + test_field_SetGlobalIntraOpNumThreads(); + fn test_field_SetGlobalInterOpNumThreads() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetGlobalInterOpNumThreads) as usize - ptr as usize + }, + 1184usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetGlobalInterOpNumThreads) + ) + ); + } + test_field_SetGlobalInterOpNumThreads(); + fn test_field_SetGlobalSpinControl() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetGlobalSpinControl) as usize - ptr as usize + }, + 1192usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetGlobalSpinControl) + ) + ); + } + test_field_SetGlobalSpinControl(); + fn test_field_AddInitializer() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AddInitializer) as usize - ptr as usize + }, + 1200usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AddInitializer) + ) + ); + } + test_field_AddInitializer(); + fn test_field_CreateEnvWithCustomLoggerAndGlobalThreadPools() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateEnvWithCustomLoggerAndGlobalThreadPools) as usize + - ptr as usize + }, + 1208usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateEnvWithCustomLoggerAndGlobalThreadPools) + ) + ); + } + test_field_CreateEnvWithCustomLoggerAndGlobalThreadPools(); + fn test_field_SessionOptionsAppendExecutionProvider_CUDA() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsAppendExecutionProvider_CUDA) as usize + - ptr as usize + }, + 1216usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsAppendExecutionProvider_CUDA) + ) + ); + } + test_field_SessionOptionsAppendExecutionProvider_CUDA(); + fn test_field_SessionOptionsAppendExecutionProvider_ROCM() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsAppendExecutionProvider_ROCM) as usize + - ptr as usize + }, + 1224usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsAppendExecutionProvider_ROCM) + ) + ); + } + test_field_SessionOptionsAppendExecutionProvider_ROCM(); + fn test_field_SessionOptionsAppendExecutionProvider_OpenVINO() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsAppendExecutionProvider_OpenVINO) as usize + - ptr as usize + }, + 1232usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsAppendExecutionProvider_OpenVINO) + ) + ); + } + test_field_SessionOptionsAppendExecutionProvider_OpenVINO(); + fn test_field_SetGlobalDenormalAsZero() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetGlobalDenormalAsZero) as usize - ptr as usize + }, + 1240usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetGlobalDenormalAsZero) + ) + ); + } + test_field_SetGlobalDenormalAsZero(); + fn test_field_CreateArenaCfg() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateArenaCfg) as usize - ptr as usize + }, + 1248usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateArenaCfg) + ) + ); + } + test_field_CreateArenaCfg(); + fn test_field_ReleaseArenaCfg() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseArenaCfg) as usize - ptr as usize + }, + 1256usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseArenaCfg) + ) + ); + } + test_field_ReleaseArenaCfg(); + fn test_field_ModelMetadataGetGraphDescription() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataGetGraphDescription) as usize + - ptr as usize + }, + 1264usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataGetGraphDescription) + ) + ); + } + test_field_ModelMetadataGetGraphDescription(); + fn test_field_SessionOptionsAppendExecutionProvider_TensorRT() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsAppendExecutionProvider_TensorRT) as usize + - ptr as usize + }, + 1272usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsAppendExecutionProvider_TensorRT) + ) + ); + } + test_field_SessionOptionsAppendExecutionProvider_TensorRT(); + fn test_field_SetCurrentGpuDeviceId() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetCurrentGpuDeviceId) as usize - ptr as usize + }, + 1280usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetCurrentGpuDeviceId) + ) + ); + } + test_field_SetCurrentGpuDeviceId(); + fn test_field_GetCurrentGpuDeviceId() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetCurrentGpuDeviceId) as usize - ptr as usize + }, + 1288usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetCurrentGpuDeviceId) + ) + ); + } + test_field_GetCurrentGpuDeviceId(); + fn test_field_KernelInfoGetAttributeArray_float() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelInfoGetAttributeArray_float) as usize + - ptr as usize + }, + 1296usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelInfoGetAttributeArray_float) + ) + ); + } + test_field_KernelInfoGetAttributeArray_float(); + fn test_field_KernelInfoGetAttributeArray_int64() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelInfoGetAttributeArray_int64) as usize + - ptr as usize + }, + 1304usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelInfoGetAttributeArray_int64) + ) + ); + } + test_field_KernelInfoGetAttributeArray_int64(); + fn test_field_CreateArenaCfgV2() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateArenaCfgV2) as usize - ptr as usize + }, + 1312usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateArenaCfgV2) + ) + ); + } + test_field_CreateArenaCfgV2(); + fn test_field_AddRunConfigEntry() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AddRunConfigEntry) as usize - ptr as usize + }, + 1320usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AddRunConfigEntry) + ) + ); + } + test_field_AddRunConfigEntry(); + fn test_field_CreatePrepackedWeightsContainer() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreatePrepackedWeightsContainer) as usize - ptr as usize + }, + 1328usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreatePrepackedWeightsContainer) + ) + ); + } + test_field_CreatePrepackedWeightsContainer(); + fn test_field_ReleasePrepackedWeightsContainer() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleasePrepackedWeightsContainer) as usize + - ptr as usize + }, + 1336usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleasePrepackedWeightsContainer) + ) + ); + } + test_field_ReleasePrepackedWeightsContainer(); + fn test_field_CreateSessionWithPrepackedWeightsContainer() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateSessionWithPrepackedWeightsContainer) as usize + - ptr as usize + }, + 1344usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateSessionWithPrepackedWeightsContainer) + ) + ); + } + test_field_CreateSessionWithPrepackedWeightsContainer(); + fn test_field_CreateSessionFromArrayWithPrepackedWeightsContainer() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateSessionFromArrayWithPrepackedWeightsContainer) + as usize + - ptr as usize + }, + 1352usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateSessionFromArrayWithPrepackedWeightsContainer) + ) + ); + } + test_field_CreateSessionFromArrayWithPrepackedWeightsContainer(); + fn test_field_SessionOptionsAppendExecutionProvider_TensorRT_V2() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsAppendExecutionProvider_TensorRT_V2) + as usize + - ptr as usize + }, + 1360usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsAppendExecutionProvider_TensorRT_V2) + ) + ); + } + test_field_SessionOptionsAppendExecutionProvider_TensorRT_V2(); + fn test_field_CreateTensorRTProviderOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateTensorRTProviderOptions) as usize - ptr as usize + }, + 1368usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateTensorRTProviderOptions) + ) + ); + } + test_field_CreateTensorRTProviderOptions(); + fn test_field_UpdateTensorRTProviderOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).UpdateTensorRTProviderOptions) as usize - ptr as usize + }, + 1376usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(UpdateTensorRTProviderOptions) + ) + ); + } + test_field_UpdateTensorRTProviderOptions(); + fn test_field_GetTensorRTProviderOptionsAsString() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetTensorRTProviderOptionsAsString) as usize + - ptr as usize + }, + 1384usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetTensorRTProviderOptionsAsString) + ) + ); + } + test_field_GetTensorRTProviderOptionsAsString(); + fn test_field_ReleaseTensorRTProviderOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseTensorRTProviderOptions) as usize - ptr as usize + }, + 1392usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseTensorRTProviderOptions) + ) + ); + } + test_field_ReleaseTensorRTProviderOptions(); + fn test_field_EnableOrtCustomOps() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).EnableOrtCustomOps) as usize - ptr as usize + }, + 1400usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(EnableOrtCustomOps) + ) + ); + } + test_field_EnableOrtCustomOps(); + fn test_field_RegisterAllocator() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RegisterAllocator) as usize - ptr as usize + }, + 1408usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RegisterAllocator) + ) + ); + } + test_field_RegisterAllocator(); + fn test_field_UnregisterAllocator() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).UnregisterAllocator) as usize - ptr as usize + }, + 1416usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(UnregisterAllocator) + ) + ); + } + test_field_UnregisterAllocator(); + fn test_field_IsSparseTensor() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).IsSparseTensor) as usize - ptr as usize + }, + 1424usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(IsSparseTensor) + ) + ); + } + test_field_IsSparseTensor(); + fn test_field_CreateSparseTensorAsOrtValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateSparseTensorAsOrtValue) as usize - ptr as usize + }, + 1432usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateSparseTensorAsOrtValue) + ) + ); + } + test_field_CreateSparseTensorAsOrtValue(); + fn test_field_FillSparseTensorCoo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).FillSparseTensorCoo) as usize - ptr as usize + }, + 1440usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(FillSparseTensorCoo) + ) + ); + } + test_field_FillSparseTensorCoo(); + fn test_field_FillSparseTensorCsr() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).FillSparseTensorCsr) as usize - ptr as usize + }, + 1448usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(FillSparseTensorCsr) + ) + ); + } + test_field_FillSparseTensorCsr(); + fn test_field_FillSparseTensorBlockSparse() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).FillSparseTensorBlockSparse) as usize - ptr as usize + }, + 1456usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(FillSparseTensorBlockSparse) + ) + ); + } + test_field_FillSparseTensorBlockSparse(); + fn test_field_CreateSparseTensorWithValuesAsOrtValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateSparseTensorWithValuesAsOrtValue) as usize + - ptr as usize + }, + 1464usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateSparseTensorWithValuesAsOrtValue) + ) + ); + } + test_field_CreateSparseTensorWithValuesAsOrtValue(); + fn test_field_UseCooIndices() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).UseCooIndices) as usize - ptr as usize + }, + 1472usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(UseCooIndices) + ) + ); + } + test_field_UseCooIndices(); + fn test_field_UseCsrIndices() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).UseCsrIndices) as usize - ptr as usize + }, + 1480usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(UseCsrIndices) + ) + ); + } + test_field_UseCsrIndices(); + fn test_field_UseBlockSparseIndices() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).UseBlockSparseIndices) as usize - ptr as usize + }, + 1488usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(UseBlockSparseIndices) + ) + ); + } + test_field_UseBlockSparseIndices(); + fn test_field_GetSparseTensorFormat() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetSparseTensorFormat) as usize - ptr as usize + }, + 1496usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetSparseTensorFormat) + ) + ); + } + test_field_GetSparseTensorFormat(); + fn test_field_GetSparseTensorValuesTypeAndShape() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetSparseTensorValuesTypeAndShape) as usize + - ptr as usize + }, + 1504usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetSparseTensorValuesTypeAndShape) + ) + ); + } + test_field_GetSparseTensorValuesTypeAndShape(); + fn test_field_GetSparseTensorValues() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetSparseTensorValues) as usize - ptr as usize + }, + 1512usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetSparseTensorValues) + ) + ); + } + test_field_GetSparseTensorValues(); + fn test_field_GetSparseTensorIndicesTypeShape() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetSparseTensorIndicesTypeShape) as usize - ptr as usize + }, + 1520usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetSparseTensorIndicesTypeShape) + ) + ); + } + test_field_GetSparseTensorIndicesTypeShape(); + fn test_field_GetSparseTensorIndices() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetSparseTensorIndices) as usize - ptr as usize + }, + 1528usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetSparseTensorIndices) + ) + ); + } + test_field_GetSparseTensorIndices(); + fn test_field_HasValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).HasValue) as usize - ptr as usize + }, + 1536usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(HasValue) + ) + ); + } + test_field_HasValue(); + fn test_field_KernelContext_GetGPUComputeStream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelContext_GetGPUComputeStream) as usize + - ptr as usize + }, + 1544usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelContext_GetGPUComputeStream) + ) + ); + } + test_field_KernelContext_GetGPUComputeStream(); + fn test_field_GetTensorMemoryInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetTensorMemoryInfo) as usize - ptr as usize + }, + 1552usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetTensorMemoryInfo) + ) + ); + } + test_field_GetTensorMemoryInfo(); + fn test_field_GetExecutionProviderApi() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetExecutionProviderApi) as usize - ptr as usize + }, + 1560usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetExecutionProviderApi) + ) + ); + } + test_field_GetExecutionProviderApi(); + fn test_field_SessionOptionsSetCustomCreateThreadFn() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsSetCustomCreateThreadFn) as usize + - ptr as usize + }, + 1568usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsSetCustomCreateThreadFn) + ) + ); + } + test_field_SessionOptionsSetCustomCreateThreadFn(); + fn test_field_SessionOptionsSetCustomThreadCreationOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsSetCustomThreadCreationOptions) as usize + - ptr as usize + }, + 1576usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsSetCustomThreadCreationOptions) + ) + ); + } + test_field_SessionOptionsSetCustomThreadCreationOptions(); + fn test_field_SessionOptionsSetCustomJoinThreadFn() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsSetCustomJoinThreadFn) as usize + - ptr as usize + }, + 1584usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsSetCustomJoinThreadFn) + ) + ); + } + test_field_SessionOptionsSetCustomJoinThreadFn(); + fn test_field_SetGlobalCustomCreateThreadFn() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetGlobalCustomCreateThreadFn) as usize - ptr as usize + }, + 1592usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetGlobalCustomCreateThreadFn) + ) + ); + } + test_field_SetGlobalCustomCreateThreadFn(); + fn test_field_SetGlobalCustomThreadCreationOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetGlobalCustomThreadCreationOptions) as usize + - ptr as usize + }, + 1600usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetGlobalCustomThreadCreationOptions) + ) + ); + } + test_field_SetGlobalCustomThreadCreationOptions(); + fn test_field_SetGlobalCustomJoinThreadFn() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetGlobalCustomJoinThreadFn) as usize - ptr as usize + }, + 1608usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetGlobalCustomJoinThreadFn) + ) + ); + } + test_field_SetGlobalCustomJoinThreadFn(); + fn test_field_SynchronizeBoundInputs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SynchronizeBoundInputs) as usize - ptr as usize + }, + 1616usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SynchronizeBoundInputs) + ) + ); + } + test_field_SynchronizeBoundInputs(); + fn test_field_SynchronizeBoundOutputs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SynchronizeBoundOutputs) as usize - ptr as usize + }, + 1624usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SynchronizeBoundOutputs) + ) + ); + } + test_field_SynchronizeBoundOutputs(); + fn test_field_SessionOptionsAppendExecutionProvider_CUDA_V2() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsAppendExecutionProvider_CUDA_V2) as usize + - ptr as usize + }, + 1632usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsAppendExecutionProvider_CUDA_V2) + ) + ); + } + test_field_SessionOptionsAppendExecutionProvider_CUDA_V2(); + fn test_field_CreateCUDAProviderOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateCUDAProviderOptions) as usize - ptr as usize + }, + 1640usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateCUDAProviderOptions) + ) + ); + } + test_field_CreateCUDAProviderOptions(); + fn test_field_UpdateCUDAProviderOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).UpdateCUDAProviderOptions) as usize - ptr as usize + }, + 1648usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(UpdateCUDAProviderOptions) + ) + ); + } + test_field_UpdateCUDAProviderOptions(); + fn test_field_GetCUDAProviderOptionsAsString() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetCUDAProviderOptionsAsString) as usize - ptr as usize + }, + 1656usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetCUDAProviderOptionsAsString) + ) + ); + } + test_field_GetCUDAProviderOptionsAsString(); + fn test_field_ReleaseCUDAProviderOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseCUDAProviderOptions) as usize - ptr as usize + }, + 1664usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseCUDAProviderOptions) + ) + ); + } + test_field_ReleaseCUDAProviderOptions(); + fn test_field_SessionOptionsAppendExecutionProvider_MIGraphX() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsAppendExecutionProvider_MIGraphX) as usize + - ptr as usize + }, + 1672usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsAppendExecutionProvider_MIGraphX) + ) + ); + } + test_field_SessionOptionsAppendExecutionProvider_MIGraphX(); } #[repr(u32)] #[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] @@ -10054,132 +9583,225 @@ fn bindgen_test_layout_OrtCustomOp() { 8usize, concat!("Alignment of ", stringify!(OrtCustomOp)) ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).version as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(version) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateKernel as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(CreateKernel) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetName as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetName) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetExecutionProviderType as *const _ as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetExecutionProviderType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetInputType as *const _ as usize }, - 32usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetInputType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetInputTypeCount as *const _ as usize }, - 40usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetInputTypeCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetOutputType as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetOutputType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetOutputTypeCount as *const _ as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetOutputTypeCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).KernelCompute as *const _ as usize }, - 64usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(KernelCompute) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).KernelDestroy as *const _ as usize }, - 72usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(KernelDestroy) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetInputCharacteristic as *const _ as usize - }, - 80usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetInputCharacteristic) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetOutputCharacteristic as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetOutputCharacteristic) - ) - ); + fn test_field_version() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).version) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(version) + ) + ); + } + test_field_version(); + fn test_field_CreateKernel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateKernel) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(CreateKernel) + ) + ); + } + test_field_CreateKernel(); + fn test_field_GetName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetName) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetName) + ) + ); + } + test_field_GetName(); + fn test_field_GetExecutionProviderType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetExecutionProviderType) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetExecutionProviderType) + ) + ); + } + test_field_GetExecutionProviderType(); + fn test_field_GetInputType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetInputType) as usize - ptr as usize + }, + 32usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetInputType) + ) + ); + } + test_field_GetInputType(); + fn test_field_GetInputTypeCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetInputTypeCount) as usize - ptr as usize + }, + 40usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetInputTypeCount) + ) + ); + } + test_field_GetInputTypeCount(); + fn test_field_GetOutputType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetOutputType) as usize - ptr as usize + }, + 48usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetOutputType) + ) + ); + } + test_field_GetOutputType(); + fn test_field_GetOutputTypeCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetOutputTypeCount) as usize - ptr as usize + }, + 56usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetOutputTypeCount) + ) + ); + } + test_field_GetOutputTypeCount(); + fn test_field_KernelCompute() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelCompute) as usize - ptr as usize + }, + 64usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(KernelCompute) + ) + ); + } + test_field_KernelCompute(); + fn test_field_KernelDestroy() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelDestroy) as usize - ptr as usize + }, + 72usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(KernelDestroy) + ) + ); + } + test_field_KernelDestroy(); + fn test_field_GetInputCharacteristic() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetInputCharacteristic) as usize - ptr as usize + }, + 80usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetInputCharacteristic) + ) + ); + } + test_field_GetInputCharacteristic(); + fn test_field_GetOutputCharacteristic() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetOutputCharacteristic) as usize - ptr as usize + }, + 88usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetOutputCharacteristic) + ) + ); + } + test_field_GetOutputCharacteristic(); +} +extern "C" { + pub fn OrtSessionOptionsAppendExecutionProvider_CUDA( + options: *mut OrtSessionOptions, + device_id: ::std::os::raw::c_int, + ) -> OrtStatusPtr; +} +extern "C" { + pub fn OrtSessionOptionsAppendExecutionProvider_MIGraphX( + options: *mut OrtSessionOptions, + device_id: ::std::os::raw::c_int, + ) -> OrtStatusPtr; +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __locale_data { + pub _address: u8, } -pub type __builtin_va_list = *mut ::std::os::raw::c_char; -pub type __uint128_t = u128; diff --git a/onnxruntime-sys/src/generated/macos/x86_64/bindings.rs b/onnxruntime-sys/src/generated/macos/x86_64/bindings.rs index 7acfb238..eb03cb17 100644 --- a/onnxruntime-sys/src/generated/macos/x86_64/bindings.rs +++ b/onnxruntime-sys/src/generated/macos/x86_64/bindings.rs @@ -1,15744 +1,9480 @@ -/* automatically generated by rust-bindgen 0.59.1 */ +/* automatically generated by rust-bindgen 0.60.1 */ -#[repr(C)] -#[derive(Copy, Clone, Debug, Default, Eq, Hash, Ord, PartialEq, PartialOrd)] -pub struct __BindgenBitfieldUnit { - storage: Storage, -} -impl __BindgenBitfieldUnit { - #[inline] - pub const fn new(storage: Storage) -> Self { - Self { storage } - } -} -impl __BindgenBitfieldUnit -where - Storage: AsRef<[u8]> + AsMut<[u8]>, -{ - #[inline] - pub fn get_bit(&self, index: usize) -> bool { - debug_assert!(index / 8 < self.storage.as_ref().len()); - let byte_index = index / 8; - let byte = self.storage.as_ref()[byte_index]; - let bit_index = if cfg!(target_endian = "big") { - 7 - (index % 8) - } else { - index % 8 - }; - let mask = 1 << bit_index; - byte & mask == mask - } - #[inline] - pub fn set_bit(&mut self, index: usize, val: bool) { - debug_assert!(index / 8 < self.storage.as_ref().len()); - let byte_index = index / 8; - let byte = &mut self.storage.as_mut()[byte_index]; - let bit_index = if cfg!(target_endian = "big") { - 7 - (index % 8) - } else { - index % 8 - }; - let mask = 1 << bit_index; - if val { - *byte |= mask; - } else { - *byte &= !mask; - } - } - #[inline] - pub fn get(&self, bit_offset: usize, bit_width: u8) -> u64 { - debug_assert!(bit_width <= 64); - debug_assert!(bit_offset / 8 < self.storage.as_ref().len()); - debug_assert!((bit_offset + (bit_width as usize)) / 8 <= self.storage.as_ref().len()); - let mut val = 0; - for i in 0..(bit_width as usize) { - if self.get_bit(i + bit_offset) { - let index = if cfg!(target_endian = "big") { - bit_width as usize - 1 - i - } else { - i - }; - val |= 1 << index; - } - } - val - } - #[inline] - pub fn set(&mut self, bit_offset: usize, bit_width: u8, val: u64) { - debug_assert!(bit_width <= 64); - debug_assert!(bit_offset / 8 < self.storage.as_ref().len()); - debug_assert!((bit_offset + (bit_width as usize)) / 8 <= self.storage.as_ref().len()); - for i in 0..(bit_width as usize) { - let mask = 1 << i; - let val_bit_is_set = val & mask == mask; - let index = if cfg!(target_endian = "big") { - bit_width as usize - 1 - i - } else { - i - }; - self.set_bit(index + bit_offset, val_bit_is_set); - } - } -} -pub const __API_TO_BE_DEPRECATED: u32 = 100000; -pub const __MAC_10_0: u32 = 1000; -pub const __MAC_10_1: u32 = 1010; -pub const __MAC_10_2: u32 = 1020; -pub const __MAC_10_3: u32 = 1030; -pub const __MAC_10_4: u32 = 1040; -pub const __MAC_10_5: u32 = 1050; -pub const __MAC_10_6: u32 = 1060; -pub const __MAC_10_7: u32 = 1070; -pub const __MAC_10_8: u32 = 1080; -pub const __MAC_10_9: u32 = 1090; -pub const __MAC_10_10: u32 = 101000; -pub const __MAC_10_10_2: u32 = 101002; -pub const __MAC_10_10_3: u32 = 101003; -pub const __MAC_10_11: u32 = 101100; -pub const __MAC_10_11_2: u32 = 101102; -pub const __MAC_10_11_3: u32 = 101103; -pub const __MAC_10_11_4: u32 = 101104; -pub const __MAC_10_12: u32 = 101200; -pub const __MAC_10_12_1: u32 = 101201; -pub const __MAC_10_12_2: u32 = 101202; -pub const __MAC_10_12_4: u32 = 101204; -pub const __MAC_10_13: u32 = 101300; -pub const __MAC_10_13_1: u32 = 101301; -pub const __MAC_10_13_2: u32 = 101302; -pub const __MAC_10_13_4: u32 = 101304; -pub const __MAC_10_14: u32 = 101400; -pub const __MAC_10_14_1: u32 = 101401; -pub const __MAC_10_14_4: u32 = 101404; -pub const __MAC_10_14_6: u32 = 101406; -pub const __MAC_10_15: u32 = 101500; -pub const __MAC_10_15_1: u32 = 101501; -pub const __MAC_10_15_4: u32 = 101504; -pub const __MAC_10_16: u32 = 101600; -pub const __MAC_11_0: u32 = 110000; -pub const __MAC_11_1: u32 = 110100; -pub const __IPHONE_2_0: u32 = 20000; -pub const __IPHONE_2_1: u32 = 20100; -pub const __IPHONE_2_2: u32 = 20200; -pub const __IPHONE_3_0: u32 = 30000; -pub const __IPHONE_3_1: u32 = 30100; -pub const __IPHONE_3_2: u32 = 30200; -pub const __IPHONE_4_0: u32 = 40000; -pub const __IPHONE_4_1: u32 = 40100; -pub const __IPHONE_4_2: u32 = 40200; -pub const __IPHONE_4_3: u32 = 40300; -pub const __IPHONE_5_0: u32 = 50000; -pub const __IPHONE_5_1: u32 = 50100; -pub const __IPHONE_6_0: u32 = 60000; -pub const __IPHONE_6_1: u32 = 60100; -pub const __IPHONE_7_0: u32 = 70000; -pub const __IPHONE_7_1: u32 = 70100; -pub const __IPHONE_8_0: u32 = 80000; -pub const __IPHONE_8_1: u32 = 80100; -pub const __IPHONE_8_2: u32 = 80200; -pub const __IPHONE_8_3: u32 = 80300; -pub const __IPHONE_8_4: u32 = 80400; -pub const __IPHONE_9_0: u32 = 90000; -pub const __IPHONE_9_1: u32 = 90100; -pub const __IPHONE_9_2: u32 = 90200; -pub const __IPHONE_9_3: u32 = 90300; -pub const __IPHONE_10_0: u32 = 100000; -pub const __IPHONE_10_1: u32 = 100100; -pub const __IPHONE_10_2: u32 = 100200; -pub const __IPHONE_10_3: u32 = 100300; -pub const __IPHONE_11_0: u32 = 110000; -pub const __IPHONE_11_1: u32 = 110100; -pub const __IPHONE_11_2: u32 = 110200; -pub const __IPHONE_11_3: u32 = 110300; -pub const __IPHONE_11_4: u32 = 110400; -pub const __IPHONE_12_0: u32 = 120000; -pub const __IPHONE_12_1: u32 = 120100; -pub const __IPHONE_12_2: u32 = 120200; -pub const __IPHONE_12_3: u32 = 120300; -pub const __IPHONE_12_4: u32 = 120400; -pub const __IPHONE_13_0: u32 = 130000; -pub const __IPHONE_13_1: u32 = 130100; -pub const __IPHONE_13_2: u32 = 130200; -pub const __IPHONE_13_3: u32 = 130300; -pub const __IPHONE_13_4: u32 = 130400; -pub const __IPHONE_13_5: u32 = 130500; -pub const __IPHONE_13_6: u32 = 130600; -pub const __IPHONE_13_7: u32 = 130700; -pub const __IPHONE_14_0: u32 = 140000; -pub const __IPHONE_14_1: u32 = 140100; -pub const __IPHONE_14_2: u32 = 140200; -pub const __IPHONE_14_3: u32 = 140300; -pub const __TVOS_9_0: u32 = 90000; -pub const __TVOS_9_1: u32 = 90100; -pub const __TVOS_9_2: u32 = 90200; -pub const __TVOS_10_0: u32 = 100000; -pub const __TVOS_10_0_1: u32 = 100001; -pub const __TVOS_10_1: u32 = 100100; -pub const __TVOS_10_2: u32 = 100200; -pub const __TVOS_11_0: u32 = 110000; -pub const __TVOS_11_1: u32 = 110100; -pub const __TVOS_11_2: u32 = 110200; -pub const __TVOS_11_3: u32 = 110300; -pub const __TVOS_11_4: u32 = 110400; -pub const __TVOS_12_0: u32 = 120000; -pub const __TVOS_12_1: u32 = 120100; -pub const __TVOS_12_2: u32 = 120200; -pub const __TVOS_12_3: u32 = 120300; -pub const __TVOS_12_4: u32 = 120400; -pub const __TVOS_13_0: u32 = 130000; -pub const __TVOS_13_2: u32 = 130200; -pub const __TVOS_13_3: u32 = 130300; -pub const __TVOS_13_4: u32 = 130400; -pub const __TVOS_14_0: u32 = 140000; -pub const __TVOS_14_1: u32 = 140100; -pub const __TVOS_14_2: u32 = 140200; -pub const __TVOS_14_3: u32 = 140300; -pub const __WATCHOS_1_0: u32 = 10000; -pub const __WATCHOS_2_0: u32 = 20000; -pub const __WATCHOS_2_1: u32 = 20100; -pub const __WATCHOS_2_2: u32 = 20200; -pub const __WATCHOS_3_0: u32 = 30000; -pub const __WATCHOS_3_1: u32 = 30100; -pub const __WATCHOS_3_1_1: u32 = 30101; -pub const __WATCHOS_3_2: u32 = 30200; -pub const __WATCHOS_4_0: u32 = 40000; -pub const __WATCHOS_4_1: u32 = 40100; -pub const __WATCHOS_4_2: u32 = 40200; -pub const __WATCHOS_4_3: u32 = 40300; -pub const __WATCHOS_5_0: u32 = 50000; -pub const __WATCHOS_5_1: u32 = 50100; -pub const __WATCHOS_5_2: u32 = 50200; -pub const __WATCHOS_5_3: u32 = 50300; -pub const __WATCHOS_6_0: u32 = 60000; -pub const __WATCHOS_6_1: u32 = 60100; -pub const __WATCHOS_6_2: u32 = 60200; -pub const __WATCHOS_7_0: u32 = 70000; -pub const __WATCHOS_7_1: u32 = 70100; -pub const __WATCHOS_7_2: u32 = 70200; -pub const MAC_OS_X_VERSION_10_0: u32 = 1000; -pub const MAC_OS_X_VERSION_10_1: u32 = 1010; -pub const MAC_OS_X_VERSION_10_2: u32 = 1020; -pub const MAC_OS_X_VERSION_10_3: u32 = 1030; -pub const MAC_OS_X_VERSION_10_4: u32 = 1040; -pub const MAC_OS_X_VERSION_10_5: u32 = 1050; -pub const MAC_OS_X_VERSION_10_6: u32 = 1060; -pub const MAC_OS_X_VERSION_10_7: u32 = 1070; -pub const MAC_OS_X_VERSION_10_8: u32 = 1080; -pub const MAC_OS_X_VERSION_10_9: u32 = 1090; -pub const MAC_OS_X_VERSION_10_10: u32 = 101000; -pub const MAC_OS_X_VERSION_10_10_2: u32 = 101002; -pub const MAC_OS_X_VERSION_10_10_3: u32 = 101003; -pub const MAC_OS_X_VERSION_10_11: u32 = 101100; -pub const MAC_OS_X_VERSION_10_11_2: u32 = 101102; -pub const MAC_OS_X_VERSION_10_11_3: u32 = 101103; -pub const MAC_OS_X_VERSION_10_11_4: u32 = 101104; -pub const MAC_OS_X_VERSION_10_12: u32 = 101200; -pub const MAC_OS_X_VERSION_10_12_1: u32 = 101201; -pub const MAC_OS_X_VERSION_10_12_2: u32 = 101202; -pub const MAC_OS_X_VERSION_10_12_4: u32 = 101204; -pub const MAC_OS_X_VERSION_10_13: u32 = 101300; -pub const MAC_OS_X_VERSION_10_13_1: u32 = 101301; -pub const MAC_OS_X_VERSION_10_13_2: u32 = 101302; -pub const MAC_OS_X_VERSION_10_13_4: u32 = 101304; -pub const MAC_OS_X_VERSION_10_14: u32 = 101400; -pub const MAC_OS_X_VERSION_10_14_1: u32 = 101401; -pub const MAC_OS_X_VERSION_10_14_4: u32 = 101404; -pub const MAC_OS_X_VERSION_10_14_6: u32 = 101406; -pub const MAC_OS_X_VERSION_10_15: u32 = 101500; -pub const MAC_OS_X_VERSION_10_15_1: u32 = 101501; -pub const MAC_OS_X_VERSION_10_16: u32 = 101600; -pub const MAC_OS_VERSION_11_0: u32 = 110000; -pub const __DRIVERKIT_19_0: u32 = 190000; -pub const __DRIVERKIT_20_0: u32 = 200000; -pub const __MAC_OS_X_VERSION_MAX_ALLOWED: u32 = 110100; -pub const __ENABLE_LEGACY_MAC_AVAILABILITY: u32 = 1; -pub const __DARWIN_ONLY_64_BIT_INO_T: u32 = 0; -pub const __DARWIN_ONLY_UNIX_CONFORMANCE: u32 = 1; -pub const __DARWIN_ONLY_VERS_1050: u32 = 0; -pub const __DARWIN_UNIX03: u32 = 1; -pub const __DARWIN_64_BIT_INO_T: u32 = 1; -pub const __DARWIN_VERS_1050: u32 = 1; -pub const __DARWIN_NON_CANCELABLE: u32 = 0; -pub const __DARWIN_SUF_64_BIT_INO_T: &'static [u8; 9usize] = b"$INODE64\0"; -pub const __DARWIN_SUF_1050: &'static [u8; 6usize] = b"$1050\0"; -pub const __DARWIN_SUF_EXTSN: &'static [u8; 14usize] = b"$DARWIN_EXTSN\0"; -pub const __DARWIN_C_ANSI: u32 = 4096; -pub const __DARWIN_C_FULL: u32 = 900000; -pub const __DARWIN_C_LEVEL: u32 = 900000; -pub const __STDC_WANT_LIB_EXT1__: u32 = 1; -pub const __DARWIN_NO_LONG_LONG: u32 = 0; -pub const _DARWIN_FEATURE_64_BIT_INODE: u32 = 1; -pub const _DARWIN_FEATURE_ONLY_UNIX_CONFORMANCE: u32 = 1; -pub const _DARWIN_FEATURE_UNIX_CONFORMANCE: u32 = 3; -pub const __PTHREAD_SIZE__: u32 = 8176; -pub const __PTHREAD_ATTR_SIZE__: u32 = 56; -pub const __PTHREAD_MUTEXATTR_SIZE__: u32 = 8; -pub const __PTHREAD_MUTEX_SIZE__: u32 = 56; -pub const __PTHREAD_CONDATTR_SIZE__: u32 = 8; -pub const __PTHREAD_COND_SIZE__: u32 = 40; -pub const __PTHREAD_ONCE_SIZE__: u32 = 8; -pub const __PTHREAD_RWLOCK_SIZE__: u32 = 192; -pub const __PTHREAD_RWLOCKATTR_SIZE__: u32 = 16; -pub const __DARWIN_WCHAR_MIN: i32 = -2147483648; -pub const _FORTIFY_SOURCE: u32 = 2; -pub const __DARWIN_NSIG: u32 = 32; -pub const NSIG: u32 = 32; -pub const _I386_SIGNAL_H_: u32 = 1; -pub const SIGHUP: u32 = 1; -pub const SIGINT: u32 = 2; -pub const SIGQUIT: u32 = 3; -pub const SIGILL: u32 = 4; -pub const SIGTRAP: u32 = 5; -pub const SIGABRT: u32 = 6; -pub const SIGIOT: u32 = 6; -pub const SIGEMT: u32 = 7; -pub const SIGFPE: u32 = 8; -pub const SIGKILL: u32 = 9; -pub const SIGBUS: u32 = 10; -pub const SIGSEGV: u32 = 11; -pub const SIGSYS: u32 = 12; -pub const SIGPIPE: u32 = 13; -pub const SIGALRM: u32 = 14; -pub const SIGTERM: u32 = 15; -pub const SIGURG: u32 = 16; -pub const SIGSTOP: u32 = 17; -pub const SIGTSTP: u32 = 18; -pub const SIGCONT: u32 = 19; -pub const SIGCHLD: u32 = 20; -pub const SIGTTIN: u32 = 21; -pub const SIGTTOU: u32 = 22; -pub const SIGIO: u32 = 23; -pub const SIGXCPU: u32 = 24; -pub const SIGXFSZ: u32 = 25; -pub const SIGVTALRM: u32 = 26; -pub const SIGPROF: u32 = 27; -pub const SIGWINCH: u32 = 28; -pub const SIGINFO: u32 = 29; -pub const SIGUSR1: u32 = 30; -pub const SIGUSR2: u32 = 31; -pub const FP_PREC_24B: u32 = 0; -pub const FP_PREC_53B: u32 = 2; -pub const FP_PREC_64B: u32 = 3; -pub const FP_RND_NEAR: u32 = 0; -pub const FP_RND_DOWN: u32 = 1; -pub const FP_RND_UP: u32 = 2; -pub const FP_CHOP: u32 = 3; -pub const FP_STATE_BYTES: u32 = 512; -pub const _X86_INSTRUCTION_STATE_MAX_INSN_BYTES: u32 = 2380; -pub const _X86_INSTRUCTION_STATE_CACHELINE_SIZE: u32 = 64; -pub const __LASTBRANCH_MAX: u32 = 32; -pub const SIGEV_NONE: u32 = 0; -pub const SIGEV_SIGNAL: u32 = 1; -pub const SIGEV_THREAD: u32 = 3; -pub const ILL_NOOP: u32 = 0; -pub const ILL_ILLOPC: u32 = 1; -pub const ILL_ILLTRP: u32 = 2; -pub const ILL_PRVOPC: u32 = 3; -pub const ILL_ILLOPN: u32 = 4; -pub const ILL_ILLADR: u32 = 5; -pub const ILL_PRVREG: u32 = 6; -pub const ILL_COPROC: u32 = 7; -pub const ILL_BADSTK: u32 = 8; -pub const FPE_NOOP: u32 = 0; -pub const FPE_FLTDIV: u32 = 1; -pub const FPE_FLTOVF: u32 = 2; -pub const FPE_FLTUND: u32 = 3; -pub const FPE_FLTRES: u32 = 4; -pub const FPE_FLTINV: u32 = 5; -pub const FPE_FLTSUB: u32 = 6; -pub const FPE_INTDIV: u32 = 7; -pub const FPE_INTOVF: u32 = 8; -pub const SEGV_NOOP: u32 = 0; -pub const SEGV_MAPERR: u32 = 1; -pub const SEGV_ACCERR: u32 = 2; -pub const BUS_NOOP: u32 = 0; -pub const BUS_ADRALN: u32 = 1; -pub const BUS_ADRERR: u32 = 2; -pub const BUS_OBJERR: u32 = 3; -pub const TRAP_BRKPT: u32 = 1; -pub const TRAP_TRACE: u32 = 2; -pub const CLD_NOOP: u32 = 0; -pub const CLD_EXITED: u32 = 1; -pub const CLD_KILLED: u32 = 2; -pub const CLD_DUMPED: u32 = 3; -pub const CLD_TRAPPED: u32 = 4; -pub const CLD_STOPPED: u32 = 5; -pub const CLD_CONTINUED: u32 = 6; -pub const POLL_IN: u32 = 1; -pub const POLL_OUT: u32 = 2; -pub const POLL_MSG: u32 = 3; -pub const POLL_ERR: u32 = 4; -pub const POLL_PRI: u32 = 5; -pub const POLL_HUP: u32 = 6; -pub const SA_ONSTACK: u32 = 1; -pub const SA_RESTART: u32 = 2; -pub const SA_RESETHAND: u32 = 4; -pub const SA_NOCLDSTOP: u32 = 8; -pub const SA_NODEFER: u32 = 16; -pub const SA_NOCLDWAIT: u32 = 32; -pub const SA_SIGINFO: u32 = 64; -pub const SA_USERTRAMP: u32 = 256; -pub const SA_64REGSET: u32 = 512; -pub const SA_USERSPACE_MASK: u32 = 127; -pub const SIG_BLOCK: u32 = 1; -pub const SIG_UNBLOCK: u32 = 2; -pub const SIG_SETMASK: u32 = 3; -pub const SI_USER: u32 = 65537; -pub const SI_QUEUE: u32 = 65538; -pub const SI_TIMER: u32 = 65539; -pub const SI_ASYNCIO: u32 = 65540; -pub const SI_MESGQ: u32 = 65541; -pub const SS_ONSTACK: u32 = 1; -pub const SS_DISABLE: u32 = 4; -pub const MINSIGSTKSZ: u32 = 32768; -pub const SIGSTKSZ: u32 = 131072; -pub const SV_ONSTACK: u32 = 1; -pub const SV_INTERRUPT: u32 = 2; -pub const SV_RESETHAND: u32 = 4; -pub const SV_NODEFER: u32 = 16; -pub const SV_NOCLDSTOP: u32 = 8; -pub const SV_SIGINFO: u32 = 64; +pub const _FEATURES_H: u32 = 1; +pub const _DEFAULT_SOURCE: u32 = 1; +pub const __GLIBC_USE_ISOC2X: u32 = 0; +pub const __USE_ISOC11: u32 = 1; +pub const __USE_ISOC99: u32 = 1; +pub const __USE_ISOC95: u32 = 1; +pub const __USE_POSIX_IMPLICITLY: u32 = 1; +pub const _POSIX_SOURCE: u32 = 1; +pub const _POSIX_C_SOURCE: u32 = 200809; +pub const __USE_POSIX: u32 = 1; +pub const __USE_POSIX2: u32 = 1; +pub const __USE_POSIX199309: u32 = 1; +pub const __USE_POSIX199506: u32 = 1; +pub const __USE_XOPEN2K: u32 = 1; +pub const __USE_XOPEN2K8: u32 = 1; +pub const _ATFILE_SOURCE: u32 = 1; +pub const __USE_MISC: u32 = 1; +pub const __USE_ATFILE: u32 = 1; +pub const __USE_FORTIFY_LEVEL: u32 = 0; +pub const __GLIBC_USE_DEPRECATED_GETS: u32 = 0; +pub const __GLIBC_USE_DEPRECATED_SCANF: u32 = 0; +pub const _STDC_PREDEF_H: u32 = 1; +pub const __STDC_IEC_559__: u32 = 1; +pub const __STDC_IEC_559_COMPLEX__: u32 = 1; +pub const __STDC_ISO_10646__: u32 = 201706; +pub const __GNU_LIBRARY__: u32 = 6; +pub const __GLIBC__: u32 = 2; +pub const __GLIBC_MINOR__: u32 = 31; +pub const _SYS_CDEFS_H: u32 = 1; +pub const __glibc_c99_flexarr_available: u32 = 1; pub const __WORDSIZE: u32 = 64; -pub const INT8_MAX: u32 = 127; -pub const INT16_MAX: u32 = 32767; -pub const INT32_MAX: u32 = 2147483647; -pub const INT64_MAX: u64 = 9223372036854775807; +pub const __WORDSIZE_TIME64_COMPAT32: u32 = 1; +pub const __SYSCALL_WORDSIZE: u32 = 64; +pub const __LONG_DOUBLE_USES_FLOAT128: u32 = 0; +pub const __HAVE_GENERIC_SELECTION: u32 = 1; +pub const __GLIBC_USE_LIB_EXT2: u32 = 0; +pub const __GLIBC_USE_IEC_60559_BFP_EXT: u32 = 0; +pub const __GLIBC_USE_IEC_60559_BFP_EXT_C2X: u32 = 0; +pub const __GLIBC_USE_IEC_60559_FUNCS_EXT: u32 = 0; +pub const __GLIBC_USE_IEC_60559_FUNCS_EXT_C2X: u32 = 0; +pub const __GLIBC_USE_IEC_60559_TYPES_EXT: u32 = 0; +pub const _STDLIB_H: u32 = 1; +pub const WNOHANG: u32 = 1; +pub const WUNTRACED: u32 = 2; +pub const WSTOPPED: u32 = 2; +pub const WEXITED: u32 = 4; +pub const WCONTINUED: u32 = 8; +pub const WNOWAIT: u32 = 16777216; +pub const __WNOTHREAD: u32 = 536870912; +pub const __WALL: u32 = 1073741824; +pub const __WCLONE: u32 = 2147483648; +pub const __ENUM_IDTYPE_T: u32 = 1; +pub const __W_CONTINUED: u32 = 65535; +pub const __WCOREFLAG: u32 = 128; +pub const __HAVE_FLOAT128: u32 = 0; +pub const __HAVE_DISTINCT_FLOAT128: u32 = 0; +pub const __HAVE_FLOAT64X: u32 = 1; +pub const __HAVE_FLOAT64X_LONG_DOUBLE: u32 = 1; +pub const __HAVE_FLOAT16: u32 = 0; +pub const __HAVE_FLOAT32: u32 = 1; +pub const __HAVE_FLOAT64: u32 = 1; +pub const __HAVE_FLOAT32X: u32 = 1; +pub const __HAVE_FLOAT128X: u32 = 0; +pub const __HAVE_DISTINCT_FLOAT16: u32 = 0; +pub const __HAVE_DISTINCT_FLOAT32: u32 = 0; +pub const __HAVE_DISTINCT_FLOAT64: u32 = 0; +pub const __HAVE_DISTINCT_FLOAT32X: u32 = 0; +pub const __HAVE_DISTINCT_FLOAT64X: u32 = 0; +pub const __HAVE_DISTINCT_FLOAT128X: u32 = 0; +pub const __HAVE_FLOATN_NOT_TYPEDEF: u32 = 0; +pub const __ldiv_t_defined: u32 = 1; +pub const __lldiv_t_defined: u32 = 1; +pub const RAND_MAX: u32 = 2147483647; +pub const EXIT_FAILURE: u32 = 1; +pub const EXIT_SUCCESS: u32 = 0; +pub const _SYS_TYPES_H: u32 = 1; +pub const _BITS_TYPES_H: u32 = 1; +pub const __TIMESIZE: u32 = 64; +pub const _BITS_TYPESIZES_H: u32 = 1; +pub const __OFF_T_MATCHES_OFF64_T: u32 = 1; +pub const __INO_T_MATCHES_INO64_T: u32 = 1; +pub const __RLIM_T_MATCHES_RLIM64_T: u32 = 1; +pub const __STATFS_MATCHES_STATFS64: u32 = 1; +pub const __FD_SETSIZE: u32 = 1024; +pub const _BITS_TIME64_H: u32 = 1; +pub const __clock_t_defined: u32 = 1; +pub const __clockid_t_defined: u32 = 1; +pub const __time_t_defined: u32 = 1; +pub const __timer_t_defined: u32 = 1; +pub const _BITS_STDINT_INTN_H: u32 = 1; +pub const __BIT_TYPES_DEFINED__: u32 = 1; +pub const _ENDIAN_H: u32 = 1; +pub const _BITS_ENDIAN_H: u32 = 1; +pub const __LITTLE_ENDIAN: u32 = 1234; +pub const __BIG_ENDIAN: u32 = 4321; +pub const __PDP_ENDIAN: u32 = 3412; +pub const _BITS_ENDIANNESS_H: u32 = 1; +pub const __BYTE_ORDER: u32 = 1234; +pub const __FLOAT_WORD_ORDER: u32 = 1234; +pub const LITTLE_ENDIAN: u32 = 1234; +pub const BIG_ENDIAN: u32 = 4321; +pub const PDP_ENDIAN: u32 = 3412; +pub const BYTE_ORDER: u32 = 1234; +pub const _BITS_BYTESWAP_H: u32 = 1; +pub const _BITS_UINTN_IDENTITY_H: u32 = 1; +pub const _SYS_SELECT_H: u32 = 1; +pub const __FD_ZERO_STOS: &[u8; 6usize] = b"stosq\0"; +pub const __sigset_t_defined: u32 = 1; +pub const __timeval_defined: u32 = 1; +pub const _STRUCT_TIMESPEC: u32 = 1; +pub const FD_SETSIZE: u32 = 1024; +pub const _BITS_PTHREADTYPES_COMMON_H: u32 = 1; +pub const _THREAD_SHARED_TYPES_H: u32 = 1; +pub const _BITS_PTHREADTYPES_ARCH_H: u32 = 1; +pub const __SIZEOF_PTHREAD_MUTEX_T: u32 = 40; +pub const __SIZEOF_PTHREAD_ATTR_T: u32 = 56; +pub const __SIZEOF_PTHREAD_RWLOCK_T: u32 = 56; +pub const __SIZEOF_PTHREAD_BARRIER_T: u32 = 32; +pub const __SIZEOF_PTHREAD_MUTEXATTR_T: u32 = 4; +pub const __SIZEOF_PTHREAD_COND_T: u32 = 48; +pub const __SIZEOF_PTHREAD_CONDATTR_T: u32 = 4; +pub const __SIZEOF_PTHREAD_RWLOCKATTR_T: u32 = 8; +pub const __SIZEOF_PTHREAD_BARRIERATTR_T: u32 = 4; +pub const _THREAD_MUTEX_INTERNAL_H: u32 = 1; +pub const __PTHREAD_MUTEX_HAVE_PREV: u32 = 1; +pub const __have_pthread_attr_t: u32 = 1; +pub const _ALLOCA_H: u32 = 1; +pub const _STDINT_H: u32 = 1; +pub const _BITS_WCHAR_H: u32 = 1; +pub const _BITS_STDINT_UINTN_H: u32 = 1; pub const INT8_MIN: i32 = -128; pub const INT16_MIN: i32 = -32768; pub const INT32_MIN: i32 = -2147483648; -pub const INT64_MIN: i64 = -9223372036854775808; +pub const INT8_MAX: u32 = 127; +pub const INT16_MAX: u32 = 32767; +pub const INT32_MAX: u32 = 2147483647; pub const UINT8_MAX: u32 = 255; pub const UINT16_MAX: u32 = 65535; pub const UINT32_MAX: u32 = 4294967295; -pub const UINT64_MAX: i32 = -1; pub const INT_LEAST8_MIN: i32 = -128; pub const INT_LEAST16_MIN: i32 = -32768; pub const INT_LEAST32_MIN: i32 = -2147483648; -pub const INT_LEAST64_MIN: i64 = -9223372036854775808; pub const INT_LEAST8_MAX: u32 = 127; pub const INT_LEAST16_MAX: u32 = 32767; pub const INT_LEAST32_MAX: u32 = 2147483647; -pub const INT_LEAST64_MAX: u64 = 9223372036854775807; pub const UINT_LEAST8_MAX: u32 = 255; pub const UINT_LEAST16_MAX: u32 = 65535; pub const UINT_LEAST32_MAX: u32 = 4294967295; -pub const UINT_LEAST64_MAX: i32 = -1; pub const INT_FAST8_MIN: i32 = -128; -pub const INT_FAST16_MIN: i32 = -32768; -pub const INT_FAST32_MIN: i32 = -2147483648; -pub const INT_FAST64_MIN: i64 = -9223372036854775808; +pub const INT_FAST16_MIN: i64 = -9223372036854775808; +pub const INT_FAST32_MIN: i64 = -9223372036854775808; pub const INT_FAST8_MAX: u32 = 127; -pub const INT_FAST16_MAX: u32 = 32767; -pub const INT_FAST32_MAX: u32 = 2147483647; -pub const INT_FAST64_MAX: u64 = 9223372036854775807; +pub const INT_FAST16_MAX: u64 = 9223372036854775807; +pub const INT_FAST32_MAX: u64 = 9223372036854775807; pub const UINT_FAST8_MAX: u32 = 255; -pub const UINT_FAST16_MAX: u32 = 65535; -pub const UINT_FAST32_MAX: u32 = 4294967295; -pub const UINT_FAST64_MAX: i32 = -1; -pub const INTPTR_MAX: u64 = 9223372036854775807; +pub const UINT_FAST16_MAX: i32 = -1; +pub const UINT_FAST32_MAX: i32 = -1; pub const INTPTR_MIN: i64 = -9223372036854775808; +pub const INTPTR_MAX: u64 = 9223372036854775807; pub const UINTPTR_MAX: i32 = -1; -pub const SIZE_MAX: i32 = -1; -pub const RSIZE_MAX: i32 = -1; -pub const WINT_MIN: i32 = -2147483648; -pub const WINT_MAX: u32 = 2147483647; +pub const PTRDIFF_MIN: i64 = -9223372036854775808; +pub const PTRDIFF_MAX: u64 = 9223372036854775807; pub const SIG_ATOMIC_MIN: i32 = -2147483648; pub const SIG_ATOMIC_MAX: u32 = 2147483647; -pub const PRIO_PROCESS: u32 = 0; -pub const PRIO_PGRP: u32 = 1; -pub const PRIO_USER: u32 = 2; -pub const PRIO_DARWIN_THREAD: u32 = 3; -pub const PRIO_DARWIN_PROCESS: u32 = 4; -pub const PRIO_MIN: i32 = -20; -pub const PRIO_MAX: u32 = 20; -pub const PRIO_DARWIN_BG: u32 = 4096; -pub const PRIO_DARWIN_NONUI: u32 = 4097; -pub const RUSAGE_SELF: u32 = 0; -pub const RUSAGE_CHILDREN: i32 = -1; -pub const RUSAGE_INFO_V0: u32 = 0; -pub const RUSAGE_INFO_V1: u32 = 1; -pub const RUSAGE_INFO_V2: u32 = 2; -pub const RUSAGE_INFO_V3: u32 = 3; -pub const RUSAGE_INFO_V4: u32 = 4; -pub const RUSAGE_INFO_V5: u32 = 5; -pub const RUSAGE_INFO_CURRENT: u32 = 5; -pub const RU_PROC_RUNS_RESLIDE: u32 = 1; -pub const RLIMIT_CPU: u32 = 0; -pub const RLIMIT_FSIZE: u32 = 1; -pub const RLIMIT_DATA: u32 = 2; -pub const RLIMIT_STACK: u32 = 3; -pub const RLIMIT_CORE: u32 = 4; -pub const RLIMIT_AS: u32 = 5; -pub const RLIMIT_RSS: u32 = 5; -pub const RLIMIT_MEMLOCK: u32 = 6; -pub const RLIMIT_NPROC: u32 = 7; -pub const RLIMIT_NOFILE: u32 = 8; -pub const RLIM_NLIMITS: u32 = 9; -pub const _RLIMIT_POSIX_FLAG: u32 = 4096; -pub const RLIMIT_WAKEUPS_MONITOR: u32 = 1; -pub const RLIMIT_CPU_USAGE_MONITOR: u32 = 2; -pub const RLIMIT_THREAD_CPULIMITS: u32 = 3; -pub const RLIMIT_FOOTPRINT_INTERVAL: u32 = 4; -pub const WAKEMON_ENABLE: u32 = 1; -pub const WAKEMON_DISABLE: u32 = 2; -pub const WAKEMON_GET_PARAMS: u32 = 4; -pub const WAKEMON_SET_DEFAULTS: u32 = 8; -pub const WAKEMON_MAKE_FATAL: u32 = 16; -pub const CPUMON_MAKE_FATAL: u32 = 4096; -pub const FOOTPRINT_INTERVAL_RESET: u32 = 1; -pub const IOPOL_TYPE_DISK: u32 = 0; -pub const IOPOL_TYPE_VFS_ATIME_UPDATES: u32 = 2; -pub const IOPOL_TYPE_VFS_MATERIALIZE_DATALESS_FILES: u32 = 3; -pub const IOPOL_TYPE_VFS_STATFS_NO_DATA_VOLUME: u32 = 4; -pub const IOPOL_TYPE_VFS_TRIGGER_RESOLVE: u32 = 5; -pub const IOPOL_TYPE_VFS_IGNORE_CONTENT_PROTECTION: u32 = 6; -pub const IOPOL_SCOPE_PROCESS: u32 = 0; -pub const IOPOL_SCOPE_THREAD: u32 = 1; -pub const IOPOL_SCOPE_DARWIN_BG: u32 = 2; -pub const IOPOL_DEFAULT: u32 = 0; -pub const IOPOL_IMPORTANT: u32 = 1; -pub const IOPOL_PASSIVE: u32 = 2; -pub const IOPOL_THROTTLE: u32 = 3; -pub const IOPOL_UTILITY: u32 = 4; -pub const IOPOL_STANDARD: u32 = 5; -pub const IOPOL_APPLICATION: u32 = 5; -pub const IOPOL_NORMAL: u32 = 1; -pub const IOPOL_ATIME_UPDATES_DEFAULT: u32 = 0; -pub const IOPOL_ATIME_UPDATES_OFF: u32 = 1; -pub const IOPOL_MATERIALIZE_DATALESS_FILES_DEFAULT: u32 = 0; -pub const IOPOL_MATERIALIZE_DATALESS_FILES_OFF: u32 = 1; -pub const IOPOL_MATERIALIZE_DATALESS_FILES_ON: u32 = 2; -pub const IOPOL_VFS_STATFS_NO_DATA_VOLUME_DEFAULT: u32 = 0; -pub const IOPOL_VFS_STATFS_FORCE_NO_DATA_VOLUME: u32 = 1; -pub const IOPOL_VFS_TRIGGER_RESOLVE_DEFAULT: u32 = 0; -pub const IOPOL_VFS_TRIGGER_RESOLVE_OFF: u32 = 1; -pub const IOPOL_VFS_CONTENT_PROTECTION_DEFAULT: u32 = 0; -pub const IOPOL_VFS_CONTENT_PROTECTION_IGNORE: u32 = 1; -pub const WNOHANG: u32 = 1; -pub const WUNTRACED: u32 = 2; -pub const WCOREFLAG: u32 = 128; -pub const _WSTOPPED: u32 = 127; -pub const WEXITED: u32 = 4; -pub const WSTOPPED: u32 = 8; -pub const WCONTINUED: u32 = 16; -pub const WNOWAIT: u32 = 32; -pub const WAIT_ANY: i32 = -1; -pub const WAIT_MYPGRP: u32 = 0; -pub const _QUAD_HIGHWORD: u32 = 1; -pub const _QUAD_LOWWORD: u32 = 0; -pub const __DARWIN_LITTLE_ENDIAN: u32 = 1234; -pub const __DARWIN_BIG_ENDIAN: u32 = 4321; -pub const __DARWIN_PDP_ENDIAN: u32 = 3412; -pub const __DARWIN_BYTE_ORDER: u32 = 1234; -pub const LITTLE_ENDIAN: u32 = 1234; -pub const BIG_ENDIAN: u32 = 4321; -pub const PDP_ENDIAN: u32 = 3412; -pub const BYTE_ORDER: u32 = 1234; -pub const EXIT_FAILURE: u32 = 1; -pub const EXIT_SUCCESS: u32 = 0; -pub const RAND_MAX: u32 = 2147483647; -pub const _USE_FORTIFY_LEVEL: u32 = 2; -pub const __HAS_FIXED_CHK_PROTOTYPES: u32 = 1; -pub const ORT_API_VERSION: u32 = 8; -pub type __int8_t = ::std::os::raw::c_schar; -pub type __uint8_t = ::std::os::raw::c_uchar; -pub type __int16_t = ::std::os::raw::c_short; -pub type __uint16_t = ::std::os::raw::c_ushort; -pub type __int32_t = ::std::os::raw::c_int; -pub type __uint32_t = ::std::os::raw::c_uint; -pub type __int64_t = ::std::os::raw::c_longlong; -pub type __uint64_t = ::std::os::raw::c_ulonglong; -pub type __darwin_intptr_t = ::std::os::raw::c_long; -pub type __darwin_natural_t = ::std::os::raw::c_uint; -pub type __darwin_ct_rune_t = ::std::os::raw::c_int; +pub const SIZE_MAX: i32 = -1; +pub const WINT_MIN: u32 = 0; +pub const WINT_MAX: u32 = 4294967295; +pub const _STRING_H: u32 = 1; +pub const _BITS_TYPES_LOCALE_T_H: u32 = 1; +pub const _BITS_TYPES___LOCALE_T_H: u32 = 1; +pub const _STRINGS_H: u32 = 1; +pub const ORT_API_VERSION: u32 = 11; +pub type wchar_t = ::std::os::raw::c_int; +#[repr(u32)] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum idtype_t { + P_ALL = 0, + P_PID = 1, + P_PGID = 2, +} +pub type _Float32 = f32; +pub type _Float64 = f64; +pub type _Float32x = f64; +pub type _Float64x = u128; #[repr(C)] -#[derive(Copy, Clone)] -pub union __mbstate_t { - pub __mbstate8: [::std::os::raw::c_char; 128usize], - pub _mbstateL: ::std::os::raw::c_longlong, +#[derive(Debug, Copy, Clone)] +pub struct div_t { + pub quot: ::std::os::raw::c_int, + pub rem: ::std::os::raw::c_int, } #[test] -fn bindgen_test_layout___mbstate_t() { - assert_eq!( - ::std::mem::size_of::<__mbstate_t>(), - 128usize, - concat!("Size of: ", stringify!(__mbstate_t)) - ); +fn bindgen_test_layout_div_t() { assert_eq!( - ::std::mem::align_of::<__mbstate_t>(), + ::std::mem::size_of::(), 8usize, - concat!("Alignment of ", stringify!(__mbstate_t)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__mbstate_t>())).__mbstate8 as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__mbstate_t), - "::", - stringify!(__mbstate8) - ) + concat!("Size of: ", stringify!(div_t)) ); assert_eq!( - unsafe { &(*(::std::ptr::null::<__mbstate_t>()))._mbstateL as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__mbstate_t), - "::", - stringify!(_mbstateL) - ) + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(div_t)) ); + fn test_field_quot() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).quot) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(div_t), + "::", + stringify!(quot) + ) + ); + } + test_field_quot(); + fn test_field_rem() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).rem) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(div_t), + "::", + stringify!(rem) + ) + ); + } + test_field_rem(); } -pub type __darwin_mbstate_t = __mbstate_t; -pub type __darwin_ptrdiff_t = ::std::os::raw::c_long; -pub type __darwin_size_t = ::std::os::raw::c_ulong; -pub type __darwin_va_list = __builtin_va_list; -pub type __darwin_wchar_t = ::std::os::raw::c_int; -pub type __darwin_rune_t = __darwin_wchar_t; -pub type __darwin_wint_t = ::std::os::raw::c_int; -pub type __darwin_clock_t = ::std::os::raw::c_ulong; -pub type __darwin_socklen_t = __uint32_t; -pub type __darwin_ssize_t = ::std::os::raw::c_long; -pub type __darwin_time_t = ::std::os::raw::c_long; -pub type __darwin_blkcnt_t = __int64_t; -pub type __darwin_blksize_t = __int32_t; -pub type __darwin_dev_t = __int32_t; -pub type __darwin_fsblkcnt_t = ::std::os::raw::c_uint; -pub type __darwin_fsfilcnt_t = ::std::os::raw::c_uint; -pub type __darwin_gid_t = __uint32_t; -pub type __darwin_id_t = __uint32_t; -pub type __darwin_ino64_t = __uint64_t; -pub type __darwin_ino_t = __darwin_ino64_t; -pub type __darwin_mach_port_name_t = __darwin_natural_t; -pub type __darwin_mach_port_t = __darwin_mach_port_name_t; -pub type __darwin_mode_t = __uint16_t; -pub type __darwin_off_t = __int64_t; -pub type __darwin_pid_t = __int32_t; -pub type __darwin_sigset_t = __uint32_t; -pub type __darwin_suseconds_t = __int32_t; -pub type __darwin_uid_t = __uint32_t; -pub type __darwin_useconds_t = __uint32_t; -pub type __darwin_uuid_t = [::std::os::raw::c_uchar; 16usize]; -pub type __darwin_uuid_string_t = [::std::os::raw::c_char; 37usize]; #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct __darwin_pthread_handler_rec { - pub __routine: ::std::option::Option, - pub __arg: *mut ::std::os::raw::c_void, - pub __next: *mut __darwin_pthread_handler_rec, +pub struct ldiv_t { + pub quot: ::std::os::raw::c_long, + pub rem: ::std::os::raw::c_long, } #[test] -fn bindgen_test_layout___darwin_pthread_handler_rec() { - assert_eq!( - ::std::mem::size_of::<__darwin_pthread_handler_rec>(), - 24usize, - concat!("Size of: ", stringify!(__darwin_pthread_handler_rec)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_pthread_handler_rec>(), - 8usize, - concat!("Alignment of ", stringify!(__darwin_pthread_handler_rec)) - ); +fn bindgen_test_layout_ldiv_t() { assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_pthread_handler_rec>())).__routine as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_pthread_handler_rec), - "::", - stringify!(__routine) - ) + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(ldiv_t)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_pthread_handler_rec>())).__arg as *const _ as usize - }, + ::std::mem::align_of::(), 8usize, - concat!( - "Offset of field: ", - stringify!(__darwin_pthread_handler_rec), - "::", - stringify!(__arg) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_pthread_handler_rec>())).__next as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_pthread_handler_rec), - "::", - stringify!(__next) - ) + concat!("Alignment of ", stringify!(ldiv_t)) ); + fn test_field_quot() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).quot) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(ldiv_t), + "::", + stringify!(quot) + ) + ); + } + test_field_quot(); + fn test_field_rem() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).rem) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(ldiv_t), + "::", + stringify!(rem) + ) + ); + } + test_field_rem(); } #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct _opaque_pthread_attr_t { - pub __sig: ::std::os::raw::c_long, - pub __opaque: [::std::os::raw::c_char; 56usize], +pub struct lldiv_t { + pub quot: ::std::os::raw::c_longlong, + pub rem: ::std::os::raw::c_longlong, } #[test] -fn bindgen_test_layout__opaque_pthread_attr_t() { - assert_eq!( - ::std::mem::size_of::<_opaque_pthread_attr_t>(), - 64usize, - concat!("Size of: ", stringify!(_opaque_pthread_attr_t)) - ); - assert_eq!( - ::std::mem::align_of::<_opaque_pthread_attr_t>(), - 8usize, - concat!("Alignment of ", stringify!(_opaque_pthread_attr_t)) - ); +fn bindgen_test_layout_lldiv_t() { assert_eq!( - unsafe { &(*(::std::ptr::null::<_opaque_pthread_attr_t>())).__sig as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_attr_t), - "::", - stringify!(__sig) - ) + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(lldiv_t)) ); assert_eq!( - unsafe { &(*(::std::ptr::null::<_opaque_pthread_attr_t>())).__opaque as *const _ as usize }, + ::std::mem::align_of::(), 8usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_attr_t), - "::", - stringify!(__opaque) - ) + concat!("Alignment of ", stringify!(lldiv_t)) ); + fn test_field_quot() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).quot) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(lldiv_t), + "::", + stringify!(quot) + ) + ); + } + test_field_quot(); + fn test_field_rem() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).rem) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(lldiv_t), + "::", + stringify!(rem) + ) + ); + } + test_field_rem(); +} +extern "C" { + pub fn __ctype_get_mb_cur_max() -> usize; +} +extern "C" { + pub fn atof(__nptr: *const ::std::os::raw::c_char) -> f64; +} +extern "C" { + pub fn atoi(__nptr: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn atol(__nptr: *const ::std::os::raw::c_char) -> ::std::os::raw::c_long; +} +extern "C" { + pub fn atoll(__nptr: *const ::std::os::raw::c_char) -> ::std::os::raw::c_longlong; +} +extern "C" { + pub fn strtod( + __nptr: *const ::std::os::raw::c_char, + __endptr: *mut *mut ::std::os::raw::c_char, + ) -> f64; +} +extern "C" { + pub fn strtof( + __nptr: *const ::std::os::raw::c_char, + __endptr: *mut *mut ::std::os::raw::c_char, + ) -> f32; +} +extern "C" { + pub fn strtold( + __nptr: *const ::std::os::raw::c_char, + __endptr: *mut *mut ::std::os::raw::c_char, + ) -> u128; +} +extern "C" { + pub fn strtol( + __nptr: *const ::std::os::raw::c_char, + __endptr: *mut *mut ::std::os::raw::c_char, + __base: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_long; +} +extern "C" { + pub fn strtoul( + __nptr: *const ::std::os::raw::c_char, + __endptr: *mut *mut ::std::os::raw::c_char, + __base: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_ulong; +} +extern "C" { + pub fn strtoq( + __nptr: *const ::std::os::raw::c_char, + __endptr: *mut *mut ::std::os::raw::c_char, + __base: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_longlong; +} +extern "C" { + pub fn strtouq( + __nptr: *const ::std::os::raw::c_char, + __endptr: *mut *mut ::std::os::raw::c_char, + __base: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_ulonglong; +} +extern "C" { + pub fn strtoll( + __nptr: *const ::std::os::raw::c_char, + __endptr: *mut *mut ::std::os::raw::c_char, + __base: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_longlong; +} +extern "C" { + pub fn strtoull( + __nptr: *const ::std::os::raw::c_char, + __endptr: *mut *mut ::std::os::raw::c_char, + __base: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_ulonglong; +} +extern "C" { + pub fn l64a(__n: ::std::os::raw::c_long) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn a64l(__s: *const ::std::os::raw::c_char) -> ::std::os::raw::c_long; } +pub type __u_char = ::std::os::raw::c_uchar; +pub type __u_short = ::std::os::raw::c_ushort; +pub type __u_int = ::std::os::raw::c_uint; +pub type __u_long = ::std::os::raw::c_ulong; +pub type __int8_t = ::std::os::raw::c_schar; +pub type __uint8_t = ::std::os::raw::c_uchar; +pub type __int16_t = ::std::os::raw::c_short; +pub type __uint16_t = ::std::os::raw::c_ushort; +pub type __int32_t = ::std::os::raw::c_int; +pub type __uint32_t = ::std::os::raw::c_uint; +pub type __int64_t = ::std::os::raw::c_long; +pub type __uint64_t = ::std::os::raw::c_ulong; +pub type __int_least8_t = __int8_t; +pub type __uint_least8_t = __uint8_t; +pub type __int_least16_t = __int16_t; +pub type __uint_least16_t = __uint16_t; +pub type __int_least32_t = __int32_t; +pub type __uint_least32_t = __uint32_t; +pub type __int_least64_t = __int64_t; +pub type __uint_least64_t = __uint64_t; +pub type __quad_t = ::std::os::raw::c_long; +pub type __u_quad_t = ::std::os::raw::c_ulong; +pub type __intmax_t = ::std::os::raw::c_long; +pub type __uintmax_t = ::std::os::raw::c_ulong; +pub type __dev_t = ::std::os::raw::c_ulong; +pub type __uid_t = ::std::os::raw::c_uint; +pub type __gid_t = ::std::os::raw::c_uint; +pub type __ino_t = ::std::os::raw::c_ulong; +pub type __ino64_t = ::std::os::raw::c_ulong; +pub type __mode_t = ::std::os::raw::c_uint; +pub type __nlink_t = ::std::os::raw::c_ulong; +pub type __off_t = ::std::os::raw::c_long; +pub type __off64_t = ::std::os::raw::c_long; +pub type __pid_t = ::std::os::raw::c_int; #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct _opaque_pthread_cond_t { - pub __sig: ::std::os::raw::c_long, - pub __opaque: [::std::os::raw::c_char; 40usize], +pub struct __fsid_t { + pub __val: [::std::os::raw::c_int; 2usize], } #[test] -fn bindgen_test_layout__opaque_pthread_cond_t() { - assert_eq!( - ::std::mem::size_of::<_opaque_pthread_cond_t>(), - 48usize, - concat!("Size of: ", stringify!(_opaque_pthread_cond_t)) - ); +fn bindgen_test_layout___fsid_t() { assert_eq!( - ::std::mem::align_of::<_opaque_pthread_cond_t>(), + ::std::mem::size_of::<__fsid_t>(), 8usize, - concat!("Alignment of ", stringify!(_opaque_pthread_cond_t)) + concat!("Size of: ", stringify!(__fsid_t)) ); assert_eq!( - unsafe { &(*(::std::ptr::null::<_opaque_pthread_cond_t>())).__sig as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_cond_t), - "::", - stringify!(__sig) - ) + ::std::mem::align_of::<__fsid_t>(), + 4usize, + concat!("Alignment of ", stringify!(__fsid_t)) + ); + fn test_field___val() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__fsid_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__val) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__fsid_t), + "::", + stringify!(__val) + ) + ); + } + test_field___val(); +} +pub type __clock_t = ::std::os::raw::c_long; +pub type __rlim_t = ::std::os::raw::c_ulong; +pub type __rlim64_t = ::std::os::raw::c_ulong; +pub type __id_t = ::std::os::raw::c_uint; +pub type __time_t = ::std::os::raw::c_long; +pub type __useconds_t = ::std::os::raw::c_uint; +pub type __suseconds_t = ::std::os::raw::c_long; +pub type __daddr_t = ::std::os::raw::c_int; +pub type __key_t = ::std::os::raw::c_int; +pub type __clockid_t = ::std::os::raw::c_int; +pub type __timer_t = *mut ::std::os::raw::c_void; +pub type __blksize_t = ::std::os::raw::c_long; +pub type __blkcnt_t = ::std::os::raw::c_long; +pub type __blkcnt64_t = ::std::os::raw::c_long; +pub type __fsblkcnt_t = ::std::os::raw::c_ulong; +pub type __fsblkcnt64_t = ::std::os::raw::c_ulong; +pub type __fsfilcnt_t = ::std::os::raw::c_ulong; +pub type __fsfilcnt64_t = ::std::os::raw::c_ulong; +pub type __fsword_t = ::std::os::raw::c_long; +pub type __ssize_t = ::std::os::raw::c_long; +pub type __syscall_slong_t = ::std::os::raw::c_long; +pub type __syscall_ulong_t = ::std::os::raw::c_ulong; +pub type __loff_t = __off64_t; +pub type __caddr_t = *mut ::std::os::raw::c_char; +pub type __intptr_t = ::std::os::raw::c_long; +pub type __socklen_t = ::std::os::raw::c_uint; +pub type __sig_atomic_t = ::std::os::raw::c_int; +pub type u_char = __u_char; +pub type u_short = __u_short; +pub type u_int = __u_int; +pub type u_long = __u_long; +pub type quad_t = __quad_t; +pub type u_quad_t = __u_quad_t; +pub type fsid_t = __fsid_t; +pub type loff_t = __loff_t; +pub type ino_t = __ino_t; +pub type dev_t = __dev_t; +pub type gid_t = __gid_t; +pub type mode_t = __mode_t; +pub type nlink_t = __nlink_t; +pub type uid_t = __uid_t; +pub type off_t = __off_t; +pub type pid_t = __pid_t; +pub type id_t = __id_t; +pub type daddr_t = __daddr_t; +pub type caddr_t = __caddr_t; +pub type key_t = __key_t; +pub type clock_t = __clock_t; +pub type clockid_t = __clockid_t; +pub type time_t = __time_t; +pub type timer_t = __timer_t; +pub type ulong = ::std::os::raw::c_ulong; +pub type ushort = ::std::os::raw::c_ushort; +pub type uint = ::std::os::raw::c_uint; +pub type u_int8_t = __uint8_t; +pub type u_int16_t = __uint16_t; +pub type u_int32_t = __uint32_t; +pub type u_int64_t = __uint64_t; +pub type register_t = ::std::os::raw::c_long; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __sigset_t { + pub __val: [::std::os::raw::c_ulong; 16usize], +} +#[test] +fn bindgen_test_layout___sigset_t() { + assert_eq!( + ::std::mem::size_of::<__sigset_t>(), + 128usize, + concat!("Size of: ", stringify!(__sigset_t)) ); assert_eq!( - unsafe { &(*(::std::ptr::null::<_opaque_pthread_cond_t>())).__opaque as *const _ as usize }, + ::std::mem::align_of::<__sigset_t>(), 8usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_cond_t), - "::", - stringify!(__opaque) - ) - ); + concat!("Alignment of ", stringify!(__sigset_t)) + ); + fn test_field___val() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__sigset_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__val) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__sigset_t), + "::", + stringify!(__val) + ) + ); + } + test_field___val(); } +pub type sigset_t = __sigset_t; #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct _opaque_pthread_condattr_t { - pub __sig: ::std::os::raw::c_long, - pub __opaque: [::std::os::raw::c_char; 8usize], +pub struct timeval { + pub tv_sec: __time_t, + pub tv_usec: __suseconds_t, } #[test] -fn bindgen_test_layout__opaque_pthread_condattr_t() { +fn bindgen_test_layout_timeval() { assert_eq!( - ::std::mem::size_of::<_opaque_pthread_condattr_t>(), + ::std::mem::size_of::(), 16usize, - concat!("Size of: ", stringify!(_opaque_pthread_condattr_t)) - ); - assert_eq!( - ::std::mem::align_of::<_opaque_pthread_condattr_t>(), - 8usize, - concat!("Alignment of ", stringify!(_opaque_pthread_condattr_t)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<_opaque_pthread_condattr_t>())).__sig as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_condattr_t), - "::", - stringify!(__sig) - ) + concat!("Size of: ", stringify!(timeval)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<_opaque_pthread_condattr_t>())).__opaque as *const _ as usize - }, + ::std::mem::align_of::(), 8usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_condattr_t), - "::", - stringify!(__opaque) - ) + concat!("Alignment of ", stringify!(timeval)) ); + fn test_field_tv_sec() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).tv_sec) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(timeval), + "::", + stringify!(tv_sec) + ) + ); + } + test_field_tv_sec(); + fn test_field_tv_usec() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).tv_usec) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(timeval), + "::", + stringify!(tv_usec) + ) + ); + } + test_field_tv_usec(); } #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct _opaque_pthread_mutex_t { - pub __sig: ::std::os::raw::c_long, - pub __opaque: [::std::os::raw::c_char; 56usize], +pub struct timespec { + pub tv_sec: __time_t, + pub tv_nsec: __syscall_slong_t, } #[test] -fn bindgen_test_layout__opaque_pthread_mutex_t() { +fn bindgen_test_layout_timespec() { assert_eq!( - ::std::mem::size_of::<_opaque_pthread_mutex_t>(), - 64usize, - concat!("Size of: ", stringify!(_opaque_pthread_mutex_t)) + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(timespec)) ); assert_eq!( - ::std::mem::align_of::<_opaque_pthread_mutex_t>(), + ::std::mem::align_of::(), 8usize, - concat!("Alignment of ", stringify!(_opaque_pthread_mutex_t)) - ); + concat!("Alignment of ", stringify!(timespec)) + ); + fn test_field_tv_sec() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).tv_sec) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(timespec), + "::", + stringify!(tv_sec) + ) + ); + } + test_field_tv_sec(); + fn test_field_tv_nsec() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).tv_nsec) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(timespec), + "::", + stringify!(tv_nsec) + ) + ); + } + test_field_tv_nsec(); +} +pub type suseconds_t = __suseconds_t; +pub type __fd_mask = ::std::os::raw::c_long; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct fd_set { + pub __fds_bits: [__fd_mask; 16usize], +} +#[test] +fn bindgen_test_layout_fd_set() { assert_eq!( - unsafe { &(*(::std::ptr::null::<_opaque_pthread_mutex_t>())).__sig as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_mutex_t), - "::", - stringify!(__sig) - ) + ::std::mem::size_of::(), + 128usize, + concat!("Size of: ", stringify!(fd_set)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<_opaque_pthread_mutex_t>())).__opaque as *const _ as usize - }, + ::std::mem::align_of::(), 8usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_mutex_t), - "::", - stringify!(__opaque) - ) - ); + concat!("Alignment of ", stringify!(fd_set)) + ); + fn test_field___fds_bits() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__fds_bits) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(fd_set), + "::", + stringify!(__fds_bits) + ) + ); + } + test_field___fds_bits(); +} +pub type fd_mask = __fd_mask; +extern "C" { + pub fn select( + __nfds: ::std::os::raw::c_int, + __readfds: *mut fd_set, + __writefds: *mut fd_set, + __exceptfds: *mut fd_set, + __timeout: *mut timeval, + ) -> ::std::os::raw::c_int; } +extern "C" { + pub fn pselect( + __nfds: ::std::os::raw::c_int, + __readfds: *mut fd_set, + __writefds: *mut fd_set, + __exceptfds: *mut fd_set, + __timeout: *const timespec, + __sigmask: *const __sigset_t, + ) -> ::std::os::raw::c_int; +} +pub type blksize_t = __blksize_t; +pub type blkcnt_t = __blkcnt_t; +pub type fsblkcnt_t = __fsblkcnt_t; +pub type fsfilcnt_t = __fsfilcnt_t; #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct _opaque_pthread_mutexattr_t { - pub __sig: ::std::os::raw::c_long, - pub __opaque: [::std::os::raw::c_char; 8usize], +pub struct __pthread_internal_list { + pub __prev: *mut __pthread_internal_list, + pub __next: *mut __pthread_internal_list, } #[test] -fn bindgen_test_layout__opaque_pthread_mutexattr_t() { +fn bindgen_test_layout___pthread_internal_list() { assert_eq!( - ::std::mem::size_of::<_opaque_pthread_mutexattr_t>(), + ::std::mem::size_of::<__pthread_internal_list>(), 16usize, - concat!("Size of: ", stringify!(_opaque_pthread_mutexattr_t)) + concat!("Size of: ", stringify!(__pthread_internal_list)) ); assert_eq!( - ::std::mem::align_of::<_opaque_pthread_mutexattr_t>(), + ::std::mem::align_of::<__pthread_internal_list>(), 8usize, - concat!("Alignment of ", stringify!(_opaque_pthread_mutexattr_t)) - ); + concat!("Alignment of ", stringify!(__pthread_internal_list)) + ); + fn test_field___prev() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_internal_list>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__prev) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__pthread_internal_list), + "::", + stringify!(__prev) + ) + ); + } + test_field___prev(); + fn test_field___next() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_internal_list>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__next) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__pthread_internal_list), + "::", + stringify!(__next) + ) + ); + } + test_field___next(); +} +pub type __pthread_list_t = __pthread_internal_list; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __pthread_internal_slist { + pub __next: *mut __pthread_internal_slist, +} +#[test] +fn bindgen_test_layout___pthread_internal_slist() { assert_eq!( - unsafe { - &(*(::std::ptr::null::<_opaque_pthread_mutexattr_t>())).__sig as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_mutexattr_t), - "::", - stringify!(__sig) - ) + ::std::mem::size_of::<__pthread_internal_slist>(), + 8usize, + concat!("Size of: ", stringify!(__pthread_internal_slist)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<_opaque_pthread_mutexattr_t>())).__opaque as *const _ as usize - }, + ::std::mem::align_of::<__pthread_internal_slist>(), 8usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_mutexattr_t), - "::", - stringify!(__opaque) - ) - ); + concat!("Alignment of ", stringify!(__pthread_internal_slist)) + ); + fn test_field___next() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_internal_slist>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__next) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__pthread_internal_slist), + "::", + stringify!(__next) + ) + ); + } + test_field___next(); } +pub type __pthread_slist_t = __pthread_internal_slist; #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct _opaque_pthread_once_t { - pub __sig: ::std::os::raw::c_long, - pub __opaque: [::std::os::raw::c_char; 8usize], +pub struct __pthread_mutex_s { + pub __lock: ::std::os::raw::c_int, + pub __count: ::std::os::raw::c_uint, + pub __owner: ::std::os::raw::c_int, + pub __nusers: ::std::os::raw::c_uint, + pub __kind: ::std::os::raw::c_int, + pub __spins: ::std::os::raw::c_short, + pub __elision: ::std::os::raw::c_short, + pub __list: __pthread_list_t, } #[test] -fn bindgen_test_layout__opaque_pthread_once_t() { +fn bindgen_test_layout___pthread_mutex_s() { assert_eq!( - ::std::mem::size_of::<_opaque_pthread_once_t>(), - 16usize, - concat!("Size of: ", stringify!(_opaque_pthread_once_t)) + ::std::mem::size_of::<__pthread_mutex_s>(), + 40usize, + concat!("Size of: ", stringify!(__pthread_mutex_s)) ); assert_eq!( - ::std::mem::align_of::<_opaque_pthread_once_t>(), + ::std::mem::align_of::<__pthread_mutex_s>(), 8usize, - concat!("Alignment of ", stringify!(_opaque_pthread_once_t)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_opaque_pthread_once_t>())).__sig as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_once_t), - "::", - stringify!(__sig) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_opaque_pthread_once_t>())).__opaque as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_once_t), - "::", - stringify!(__opaque) - ) - ); + concat!("Alignment of ", stringify!(__pthread_mutex_s)) + ); + fn test_field___lock() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_mutex_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__lock) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__pthread_mutex_s), + "::", + stringify!(__lock) + ) + ); + } + test_field___lock(); + fn test_field___count() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_mutex_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__count) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(__pthread_mutex_s), + "::", + stringify!(__count) + ) + ); + } + test_field___count(); + fn test_field___owner() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_mutex_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__owner) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__pthread_mutex_s), + "::", + stringify!(__owner) + ) + ); + } + test_field___owner(); + fn test_field___nusers() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_mutex_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__nusers) as usize - ptr as usize + }, + 12usize, + concat!( + "Offset of field: ", + stringify!(__pthread_mutex_s), + "::", + stringify!(__nusers) + ) + ); + } + test_field___nusers(); + fn test_field___kind() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_mutex_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__kind) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(__pthread_mutex_s), + "::", + stringify!(__kind) + ) + ); + } + test_field___kind(); + fn test_field___spins() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_mutex_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__spins) as usize - ptr as usize + }, + 20usize, + concat!( + "Offset of field: ", + stringify!(__pthread_mutex_s), + "::", + stringify!(__spins) + ) + ); + } + test_field___spins(); + fn test_field___elision() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_mutex_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__elision) as usize - ptr as usize + }, + 22usize, + concat!( + "Offset of field: ", + stringify!(__pthread_mutex_s), + "::", + stringify!(__elision) + ) + ); + } + test_field___elision(); + fn test_field___list() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_mutex_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__list) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(__pthread_mutex_s), + "::", + stringify!(__list) + ) + ); + } + test_field___list(); } #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct _opaque_pthread_rwlock_t { - pub __sig: ::std::os::raw::c_long, - pub __opaque: [::std::os::raw::c_char; 192usize], +pub struct __pthread_rwlock_arch_t { + pub __readers: ::std::os::raw::c_uint, + pub __writers: ::std::os::raw::c_uint, + pub __wrphase_futex: ::std::os::raw::c_uint, + pub __writers_futex: ::std::os::raw::c_uint, + pub __pad3: ::std::os::raw::c_uint, + pub __pad4: ::std::os::raw::c_uint, + pub __cur_writer: ::std::os::raw::c_int, + pub __shared: ::std::os::raw::c_int, + pub __rwelision: ::std::os::raw::c_schar, + pub __pad1: [::std::os::raw::c_uchar; 7usize], + pub __pad2: ::std::os::raw::c_ulong, + pub __flags: ::std::os::raw::c_uint, } #[test] -fn bindgen_test_layout__opaque_pthread_rwlock_t() { - assert_eq!( - ::std::mem::size_of::<_opaque_pthread_rwlock_t>(), - 200usize, - concat!("Size of: ", stringify!(_opaque_pthread_rwlock_t)) - ); +fn bindgen_test_layout___pthread_rwlock_arch_t() { assert_eq!( - ::std::mem::align_of::<_opaque_pthread_rwlock_t>(), - 8usize, - concat!("Alignment of ", stringify!(_opaque_pthread_rwlock_t)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_opaque_pthread_rwlock_t>())).__sig as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_rwlock_t), - "::", - stringify!(__sig) - ) + ::std::mem::size_of::<__pthread_rwlock_arch_t>(), + 56usize, + concat!("Size of: ", stringify!(__pthread_rwlock_arch_t)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<_opaque_pthread_rwlock_t>())).__opaque as *const _ as usize - }, + ::std::mem::align_of::<__pthread_rwlock_arch_t>(), 8usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_rwlock_t), - "::", - stringify!(__opaque) - ) - ); + concat!("Alignment of ", stringify!(__pthread_rwlock_arch_t)) + ); + fn test_field___readers() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_rwlock_arch_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__readers) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__pthread_rwlock_arch_t), + "::", + stringify!(__readers) + ) + ); + } + test_field___readers(); + fn test_field___writers() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_rwlock_arch_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__writers) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(__pthread_rwlock_arch_t), + "::", + stringify!(__writers) + ) + ); + } + test_field___writers(); + fn test_field___wrphase_futex() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_rwlock_arch_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__wrphase_futex) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__pthread_rwlock_arch_t), + "::", + stringify!(__wrphase_futex) + ) + ); + } + test_field___wrphase_futex(); + fn test_field___writers_futex() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_rwlock_arch_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__writers_futex) as usize - ptr as usize + }, + 12usize, + concat!( + "Offset of field: ", + stringify!(__pthread_rwlock_arch_t), + "::", + stringify!(__writers_futex) + ) + ); + } + test_field___writers_futex(); + fn test_field___pad3() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_rwlock_arch_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__pad3) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(__pthread_rwlock_arch_t), + "::", + stringify!(__pad3) + ) + ); + } + test_field___pad3(); + fn test_field___pad4() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_rwlock_arch_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__pad4) as usize - ptr as usize + }, + 20usize, + concat!( + "Offset of field: ", + stringify!(__pthread_rwlock_arch_t), + "::", + stringify!(__pad4) + ) + ); + } + test_field___pad4(); + fn test_field___cur_writer() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_rwlock_arch_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__cur_writer) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(__pthread_rwlock_arch_t), + "::", + stringify!(__cur_writer) + ) + ); + } + test_field___cur_writer(); + fn test_field___shared() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_rwlock_arch_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__shared) as usize - ptr as usize + }, + 28usize, + concat!( + "Offset of field: ", + stringify!(__pthread_rwlock_arch_t), + "::", + stringify!(__shared) + ) + ); + } + test_field___shared(); + fn test_field___rwelision() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_rwlock_arch_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__rwelision) as usize - ptr as usize + }, + 32usize, + concat!( + "Offset of field: ", + stringify!(__pthread_rwlock_arch_t), + "::", + stringify!(__rwelision) + ) + ); + } + test_field___rwelision(); + fn test_field___pad1() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_rwlock_arch_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__pad1) as usize - ptr as usize + }, + 33usize, + concat!( + "Offset of field: ", + stringify!(__pthread_rwlock_arch_t), + "::", + stringify!(__pad1) + ) + ); + } + test_field___pad1(); + fn test_field___pad2() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_rwlock_arch_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__pad2) as usize - ptr as usize + }, + 40usize, + concat!( + "Offset of field: ", + stringify!(__pthread_rwlock_arch_t), + "::", + stringify!(__pad2) + ) + ); + } + test_field___pad2(); + fn test_field___flags() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_rwlock_arch_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__flags) as usize - ptr as usize + }, + 48usize, + concat!( + "Offset of field: ", + stringify!(__pthread_rwlock_arch_t), + "::", + stringify!(__flags) + ) + ); + } + test_field___flags(); +} +#[repr(C)] +#[derive(Copy, Clone)] +pub struct __pthread_cond_s { + pub __bindgen_anon_1: __pthread_cond_s__bindgen_ty_1, + pub __bindgen_anon_2: __pthread_cond_s__bindgen_ty_2, + pub __g_refs: [::std::os::raw::c_uint; 2usize], + pub __g_size: [::std::os::raw::c_uint; 2usize], + pub __g1_orig_size: ::std::os::raw::c_uint, + pub __wrefs: ::std::os::raw::c_uint, + pub __g_signals: [::std::os::raw::c_uint; 2usize], +} +#[repr(C)] +#[derive(Copy, Clone)] +pub union __pthread_cond_s__bindgen_ty_1 { + pub __wseq: ::std::os::raw::c_ulonglong, + pub __wseq32: __pthread_cond_s__bindgen_ty_1__bindgen_ty_1, } #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct _opaque_pthread_rwlockattr_t { - pub __sig: ::std::os::raw::c_long, - pub __opaque: [::std::os::raw::c_char; 16usize], +pub struct __pthread_cond_s__bindgen_ty_1__bindgen_ty_1 { + pub __low: ::std::os::raw::c_uint, + pub __high: ::std::os::raw::c_uint, } #[test] -fn bindgen_test_layout__opaque_pthread_rwlockattr_t() { - assert_eq!( - ::std::mem::size_of::<_opaque_pthread_rwlockattr_t>(), - 24usize, - concat!("Size of: ", stringify!(_opaque_pthread_rwlockattr_t)) - ); +fn bindgen_test_layout___pthread_cond_s__bindgen_ty_1__bindgen_ty_1() { assert_eq!( - ::std::mem::align_of::<_opaque_pthread_rwlockattr_t>(), + ::std::mem::size_of::<__pthread_cond_s__bindgen_ty_1__bindgen_ty_1>(), 8usize, - concat!("Alignment of ", stringify!(_opaque_pthread_rwlockattr_t)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<_opaque_pthread_rwlockattr_t>())).__sig as *const _ as usize - }, - 0usize, concat!( - "Offset of field: ", - stringify!(_opaque_pthread_rwlockattr_t), - "::", - stringify!(__sig) + "Size of: ", + stringify!(__pthread_cond_s__bindgen_ty_1__bindgen_ty_1) ) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<_opaque_pthread_rwlockattr_t>())).__opaque as *const _ as usize - }, - 8usize, + ::std::mem::align_of::<__pthread_cond_s__bindgen_ty_1__bindgen_ty_1>(), + 4usize, concat!( - "Offset of field: ", - stringify!(_opaque_pthread_rwlockattr_t), - "::", - stringify!(__opaque) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct _opaque_pthread_t { - pub __sig: ::std::os::raw::c_long, - pub __cleanup_stack: *mut __darwin_pthread_handler_rec, - pub __opaque: [::std::os::raw::c_char; 8176usize], + "Alignment of ", + stringify!(__pthread_cond_s__bindgen_ty_1__bindgen_ty_1) + ) + ); + fn test_field___low() { + assert_eq!( + unsafe { + let uninit = + ::std::mem::MaybeUninit::<__pthread_cond_s__bindgen_ty_1__bindgen_ty_1>::uninit( + ); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__low) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(__low) + ) + ); + } + test_field___low(); + fn test_field___high() { + assert_eq!( + unsafe { + let uninit = + ::std::mem::MaybeUninit::<__pthread_cond_s__bindgen_ty_1__bindgen_ty_1>::uninit( + ); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__high) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s__bindgen_ty_1__bindgen_ty_1), + "::", + stringify!(__high) + ) + ); + } + test_field___high(); } #[test] -fn bindgen_test_layout__opaque_pthread_t() { - assert_eq!( - ::std::mem::size_of::<_opaque_pthread_t>(), - 8192usize, - concat!("Size of: ", stringify!(_opaque_pthread_t)) - ); +fn bindgen_test_layout___pthread_cond_s__bindgen_ty_1() { assert_eq!( - ::std::mem::align_of::<_opaque_pthread_t>(), + ::std::mem::size_of::<__pthread_cond_s__bindgen_ty_1>(), 8usize, - concat!("Alignment of ", stringify!(_opaque_pthread_t)) + concat!("Size of: ", stringify!(__pthread_cond_s__bindgen_ty_1)) ); assert_eq!( - unsafe { &(*(::std::ptr::null::<_opaque_pthread_t>())).__sig as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_t), - "::", - stringify!(__sig) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<_opaque_pthread_t>())).__cleanup_stack as *const _ as usize - }, + ::std::mem::align_of::<__pthread_cond_s__bindgen_ty_1>(), 8usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_t), - "::", - stringify!(__cleanup_stack) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_opaque_pthread_t>())).__opaque as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(_opaque_pthread_t), - "::", - stringify!(__opaque) - ) - ); + concat!("Alignment of ", stringify!(__pthread_cond_s__bindgen_ty_1)) + ); + fn test_field___wseq() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_cond_s__bindgen_ty_1>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__wseq) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s__bindgen_ty_1), + "::", + stringify!(__wseq) + ) + ); + } + test_field___wseq(); + fn test_field___wseq32() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_cond_s__bindgen_ty_1>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__wseq32) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s__bindgen_ty_1), + "::", + stringify!(__wseq32) + ) + ); + } + test_field___wseq32(); } -pub type __darwin_pthread_attr_t = _opaque_pthread_attr_t; -pub type __darwin_pthread_cond_t = _opaque_pthread_cond_t; -pub type __darwin_pthread_condattr_t = _opaque_pthread_condattr_t; -pub type __darwin_pthread_key_t = ::std::os::raw::c_ulong; -pub type __darwin_pthread_mutex_t = _opaque_pthread_mutex_t; -pub type __darwin_pthread_mutexattr_t = _opaque_pthread_mutexattr_t; -pub type __darwin_pthread_once_t = _opaque_pthread_once_t; -pub type __darwin_pthread_rwlock_t = _opaque_pthread_rwlock_t; -pub type __darwin_pthread_rwlockattr_t = _opaque_pthread_rwlockattr_t; -pub type __darwin_pthread_t = *mut _opaque_pthread_t; -pub type __darwin_nl_item = ::std::os::raw::c_int; -pub type __darwin_wctrans_t = ::std::os::raw::c_int; -pub type __darwin_wctype_t = __uint32_t; -#[repr(u32)] -#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum idtype_t { - P_ALL = 0, - P_PID = 1, - P_PGID = 2, +#[repr(C)] +#[derive(Copy, Clone)] +pub union __pthread_cond_s__bindgen_ty_2 { + pub __g1_start: ::std::os::raw::c_ulonglong, + pub __g1_start32: __pthread_cond_s__bindgen_ty_2__bindgen_ty_1, } -pub type pid_t = __darwin_pid_t; -pub type id_t = __darwin_id_t; -pub type sig_atomic_t = ::std::os::raw::c_int; -pub type u_int8_t = ::std::os::raw::c_uchar; -pub type u_int16_t = ::std::os::raw::c_ushort; -pub type u_int32_t = ::std::os::raw::c_uint; -pub type u_int64_t = ::std::os::raw::c_ulonglong; -pub type register_t = i64; -pub type user_addr_t = u_int64_t; -pub type user_size_t = u_int64_t; -pub type user_ssize_t = i64; -pub type user_long_t = i64; -pub type user_ulong_t = u_int64_t; -pub type user_time_t = i64; -pub type user_off_t = i64; -pub type syscall_arg_t = u_int64_t; #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct __darwin_i386_thread_state { - pub __eax: ::std::os::raw::c_uint, - pub __ebx: ::std::os::raw::c_uint, - pub __ecx: ::std::os::raw::c_uint, - pub __edx: ::std::os::raw::c_uint, - pub __edi: ::std::os::raw::c_uint, - pub __esi: ::std::os::raw::c_uint, - pub __ebp: ::std::os::raw::c_uint, - pub __esp: ::std::os::raw::c_uint, - pub __ss: ::std::os::raw::c_uint, - pub __eflags: ::std::os::raw::c_uint, - pub __eip: ::std::os::raw::c_uint, - pub __cs: ::std::os::raw::c_uint, - pub __ds: ::std::os::raw::c_uint, - pub __es: ::std::os::raw::c_uint, - pub __fs: ::std::os::raw::c_uint, - pub __gs: ::std::os::raw::c_uint, +pub struct __pthread_cond_s__bindgen_ty_2__bindgen_ty_1 { + pub __low: ::std::os::raw::c_uint, + pub __high: ::std::os::raw::c_uint, } #[test] -fn bindgen_test_layout___darwin_i386_thread_state() { - assert_eq!( - ::std::mem::size_of::<__darwin_i386_thread_state>(), - 64usize, - concat!("Size of: ", stringify!(__darwin_i386_thread_state)) - ); +fn bindgen_test_layout___pthread_cond_s__bindgen_ty_2__bindgen_ty_1() { assert_eq!( - ::std::mem::align_of::<__darwin_i386_thread_state>(), - 4usize, - concat!("Alignment of ", stringify!(__darwin_i386_thread_state)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_thread_state>())).__eax as *const _ as usize - }, - 0usize, + ::std::mem::size_of::<__pthread_cond_s__bindgen_ty_2__bindgen_ty_1>(), + 8usize, concat!( - "Offset of field: ", - stringify!(__darwin_i386_thread_state), - "::", - stringify!(__eax) + "Size of: ", + stringify!(__pthread_cond_s__bindgen_ty_2__bindgen_ty_1) ) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_thread_state>())).__ebx as *const _ as usize - }, + ::std::mem::align_of::<__pthread_cond_s__bindgen_ty_2__bindgen_ty_1>(), 4usize, concat!( - "Offset of field: ", - stringify!(__darwin_i386_thread_state), - "::", - stringify!(__ebx) - ) - ); + "Alignment of ", + stringify!(__pthread_cond_s__bindgen_ty_2__bindgen_ty_1) + ) + ); + fn test_field___low() { + assert_eq!( + unsafe { + let uninit = + ::std::mem::MaybeUninit::<__pthread_cond_s__bindgen_ty_2__bindgen_ty_1>::uninit( + ); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__low) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s__bindgen_ty_2__bindgen_ty_1), + "::", + stringify!(__low) + ) + ); + } + test_field___low(); + fn test_field___high() { + assert_eq!( + unsafe { + let uninit = + ::std::mem::MaybeUninit::<__pthread_cond_s__bindgen_ty_2__bindgen_ty_1>::uninit( + ); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__high) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s__bindgen_ty_2__bindgen_ty_1), + "::", + stringify!(__high) + ) + ); + } + test_field___high(); +} +#[test] +fn bindgen_test_layout___pthread_cond_s__bindgen_ty_2() { assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_thread_state>())).__ecx as *const _ as usize - }, + ::std::mem::size_of::<__pthread_cond_s__bindgen_ty_2>(), 8usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_thread_state), - "::", - stringify!(__ecx) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_thread_state>())).__edx as *const _ as usize - }, - 12usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_thread_state), - "::", - stringify!(__edx) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_thread_state>())).__edi as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_thread_state), - "::", - stringify!(__edi) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_thread_state>())).__esi as *const _ as usize - }, - 20usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_thread_state), - "::", - stringify!(__esi) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_thread_state>())).__ebp as *const _ as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_thread_state), - "::", - stringify!(__ebp) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_thread_state>())).__esp as *const _ as usize - }, - 28usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_thread_state), - "::", - stringify!(__esp) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_i386_thread_state>())).__ss as *const _ as usize }, - 32usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_thread_state), - "::", - stringify!(__ss) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_thread_state>())).__eflags as *const _ as usize - }, - 36usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_thread_state), - "::", - stringify!(__eflags) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_thread_state>())).__eip as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_thread_state), - "::", - stringify!(__eip) - ) + concat!("Size of: ", stringify!(__pthread_cond_s__bindgen_ty_2)) ); assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_i386_thread_state>())).__cs as *const _ as usize }, - 44usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_thread_state), - "::", - stringify!(__cs) - ) - ); + ::std::mem::align_of::<__pthread_cond_s__bindgen_ty_2>(), + 8usize, + concat!("Alignment of ", stringify!(__pthread_cond_s__bindgen_ty_2)) + ); + fn test_field___g1_start() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_cond_s__bindgen_ty_2>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__g1_start) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s__bindgen_ty_2), + "::", + stringify!(__g1_start) + ) + ); + } + test_field___g1_start(); + fn test_field___g1_start32() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_cond_s__bindgen_ty_2>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__g1_start32) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s__bindgen_ty_2), + "::", + stringify!(__g1_start32) + ) + ); + } + test_field___g1_start32(); +} +#[test] +fn bindgen_test_layout___pthread_cond_s() { assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_i386_thread_state>())).__ds as *const _ as usize }, + ::std::mem::size_of::<__pthread_cond_s>(), 48usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_thread_state), - "::", - stringify!(__ds) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_i386_thread_state>())).__es as *const _ as usize }, - 52usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_thread_state), - "::", - stringify!(__es) - ) + concat!("Size of: ", stringify!(__pthread_cond_s)) ); assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_i386_thread_state>())).__fs as *const _ as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_thread_state), - "::", - stringify!(__fs) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_i386_thread_state>())).__gs as *const _ as usize }, - 60usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_thread_state), - "::", - stringify!(__gs) - ) - ); + ::std::mem::align_of::<__pthread_cond_s>(), + 8usize, + concat!("Alignment of ", stringify!(__pthread_cond_s)) + ); + fn test_field___g_refs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_cond_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__g_refs) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s), + "::", + stringify!(__g_refs) + ) + ); + } + test_field___g_refs(); + fn test_field___g_size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_cond_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__g_size) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s), + "::", + stringify!(__g_size) + ) + ); + } + test_field___g_size(); + fn test_field___g1_orig_size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_cond_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__g1_orig_size) as usize - ptr as usize + }, + 32usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s), + "::", + stringify!(__g1_orig_size) + ) + ); + } + test_field___g1_orig_size(); + fn test_field___wrefs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_cond_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__wrefs) as usize - ptr as usize + }, + 36usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s), + "::", + stringify!(__wrefs) + ) + ); + } + test_field___wrefs(); + fn test_field___g_signals() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__pthread_cond_s>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__g_signals) as usize - ptr as usize + }, + 40usize, + concat!( + "Offset of field: ", + stringify!(__pthread_cond_s), + "::", + stringify!(__g_signals) + ) + ); + } + test_field___g_signals(); } +pub type pthread_t = ::std::os::raw::c_ulong; #[repr(C)] -#[repr(align(2))] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_fp_control { - pub _bitfield_align_1: [u8; 0], - pub _bitfield_1: __BindgenBitfieldUnit<[u8; 2usize]>, +#[derive(Copy, Clone)] +pub union pthread_mutexattr_t { + pub __size: [::std::os::raw::c_char; 4usize], + pub __align: ::std::os::raw::c_int, } #[test] -fn bindgen_test_layout___darwin_fp_control() { +fn bindgen_test_layout_pthread_mutexattr_t() { assert_eq!( - ::std::mem::size_of::<__darwin_fp_control>(), - 2usize, - concat!("Size of: ", stringify!(__darwin_fp_control)) + ::std::mem::size_of::(), + 4usize, + concat!("Size of: ", stringify!(pthread_mutexattr_t)) ); assert_eq!( - ::std::mem::align_of::<__darwin_fp_control>(), - 2usize, - concat!("Alignment of ", stringify!(__darwin_fp_control)) - ); + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pthread_mutexattr_t)) + ); + fn test_field___size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__size) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_mutexattr_t), + "::", + stringify!(__size) + ) + ); + } + test_field___size(); + fn test_field___align() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__align) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_mutexattr_t), + "::", + stringify!(__align) + ) + ); + } + test_field___align(); } -impl __darwin_fp_control { - #[inline] - pub fn __invalid(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u16) } - } - #[inline] - pub fn set___invalid(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(0usize, 1u8, val as u64) - } - } - #[inline] - pub fn __denorm(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 1u8) as u16) } - } - #[inline] - pub fn set___denorm(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(1usize, 1u8, val as u64) - } - } - #[inline] - pub fn __zdiv(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(2usize, 1u8) as u16) } - } - #[inline] - pub fn set___zdiv(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(2usize, 1u8, val as u64) - } - } - #[inline] - pub fn __ovrfl(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(3usize, 1u8) as u16) } - } - #[inline] - pub fn set___ovrfl(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(3usize, 1u8, val as u64) - } - } - #[inline] - pub fn __undfl(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(4usize, 1u8) as u16) } - } - #[inline] - pub fn set___undfl(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(4usize, 1u8, val as u64) - } - } - #[inline] - pub fn __precis(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(5usize, 1u8) as u16) } - } - #[inline] - pub fn set___precis(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(5usize, 1u8, val as u64) - } - } - #[inline] - pub fn __pc(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(8usize, 2u8) as u16) } - } - #[inline] - pub fn set___pc(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(8usize, 2u8, val as u64) - } - } - #[inline] - pub fn __rc(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(10usize, 2u8) as u16) } - } - #[inline] - pub fn set___rc(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(10usize, 2u8, val as u64) - } - } - #[inline] - pub fn new_bitfield_1( - __invalid: ::std::os::raw::c_ushort, - __denorm: ::std::os::raw::c_ushort, - __zdiv: ::std::os::raw::c_ushort, - __ovrfl: ::std::os::raw::c_ushort, - __undfl: ::std::os::raw::c_ushort, - __precis: ::std::os::raw::c_ushort, - __pc: ::std::os::raw::c_ushort, - __rc: ::std::os::raw::c_ushort, - ) -> __BindgenBitfieldUnit<[u8; 2usize]> { - let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 2usize]> = Default::default(); - __bindgen_bitfield_unit.set(0usize, 1u8, { - let __invalid: u16 = unsafe { ::std::mem::transmute(__invalid) }; - __invalid as u64 - }); - __bindgen_bitfield_unit.set(1usize, 1u8, { - let __denorm: u16 = unsafe { ::std::mem::transmute(__denorm) }; - __denorm as u64 - }); - __bindgen_bitfield_unit.set(2usize, 1u8, { - let __zdiv: u16 = unsafe { ::std::mem::transmute(__zdiv) }; - __zdiv as u64 - }); - __bindgen_bitfield_unit.set(3usize, 1u8, { - let __ovrfl: u16 = unsafe { ::std::mem::transmute(__ovrfl) }; - __ovrfl as u64 - }); - __bindgen_bitfield_unit.set(4usize, 1u8, { - let __undfl: u16 = unsafe { ::std::mem::transmute(__undfl) }; - __undfl as u64 - }); - __bindgen_bitfield_unit.set(5usize, 1u8, { - let __precis: u16 = unsafe { ::std::mem::transmute(__precis) }; - __precis as u64 - }); - __bindgen_bitfield_unit.set(8usize, 2u8, { - let __pc: u16 = unsafe { ::std::mem::transmute(__pc) }; - __pc as u64 - }); - __bindgen_bitfield_unit.set(10usize, 2u8, { - let __rc: u16 = unsafe { ::std::mem::transmute(__rc) }; - __rc as u64 - }); - __bindgen_bitfield_unit - } -} -pub type __darwin_fp_control_t = __darwin_fp_control; #[repr(C)] -#[repr(align(2))] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_fp_status { - pub _bitfield_align_1: [u8; 0], - pub _bitfield_1: __BindgenBitfieldUnit<[u8; 2usize]>, +#[derive(Copy, Clone)] +pub union pthread_condattr_t { + pub __size: [::std::os::raw::c_char; 4usize], + pub __align: ::std::os::raw::c_int, } #[test] -fn bindgen_test_layout___darwin_fp_status() { +fn bindgen_test_layout_pthread_condattr_t() { assert_eq!( - ::std::mem::size_of::<__darwin_fp_status>(), - 2usize, - concat!("Size of: ", stringify!(__darwin_fp_status)) + ::std::mem::size_of::(), + 4usize, + concat!("Size of: ", stringify!(pthread_condattr_t)) ); assert_eq!( - ::std::mem::align_of::<__darwin_fp_status>(), - 2usize, - concat!("Alignment of ", stringify!(__darwin_fp_status)) - ); + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(pthread_condattr_t)) + ); + fn test_field___size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__size) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_condattr_t), + "::", + stringify!(__size) + ) + ); + } + test_field___size(); + fn test_field___align() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__align) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_condattr_t), + "::", + stringify!(__align) + ) + ); + } + test_field___align(); } -impl __darwin_fp_status { - #[inline] - pub fn __invalid(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u16) } - } - #[inline] - pub fn set___invalid(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(0usize, 1u8, val as u64) - } - } - #[inline] - pub fn __denorm(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 1u8) as u16) } - } - #[inline] - pub fn set___denorm(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(1usize, 1u8, val as u64) - } - } - #[inline] - pub fn __zdiv(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(2usize, 1u8) as u16) } - } - #[inline] - pub fn set___zdiv(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(2usize, 1u8, val as u64) - } - } - #[inline] - pub fn __ovrfl(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(3usize, 1u8) as u16) } - } - #[inline] - pub fn set___ovrfl(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(3usize, 1u8, val as u64) - } - } - #[inline] - pub fn __undfl(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(4usize, 1u8) as u16) } - } - #[inline] - pub fn set___undfl(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(4usize, 1u8, val as u64) - } - } - #[inline] - pub fn __precis(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(5usize, 1u8) as u16) } - } - #[inline] - pub fn set___precis(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(5usize, 1u8, val as u64) - } - } - #[inline] - pub fn __stkflt(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(6usize, 1u8) as u16) } - } - #[inline] - pub fn set___stkflt(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(6usize, 1u8, val as u64) - } - } - #[inline] - pub fn __errsumm(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(7usize, 1u8) as u16) } - } - #[inline] - pub fn set___errsumm(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(7usize, 1u8, val as u64) - } - } - #[inline] - pub fn __c0(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(8usize, 1u8) as u16) } - } - #[inline] - pub fn set___c0(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(8usize, 1u8, val as u64) - } - } - #[inline] - pub fn __c1(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(9usize, 1u8) as u16) } - } - #[inline] - pub fn set___c1(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(9usize, 1u8, val as u64) - } - } - #[inline] - pub fn __c2(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(10usize, 1u8) as u16) } - } - #[inline] - pub fn set___c2(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(10usize, 1u8, val as u64) - } - } - #[inline] - pub fn __tos(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(11usize, 3u8) as u16) } - } - #[inline] - pub fn set___tos(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(11usize, 3u8, val as u64) - } - } - #[inline] - pub fn __c3(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(14usize, 1u8) as u16) } - } - #[inline] - pub fn set___c3(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(14usize, 1u8, val as u64) - } - } - #[inline] - pub fn __busy(&self) -> ::std::os::raw::c_ushort { - unsafe { ::std::mem::transmute(self._bitfield_1.get(15usize, 1u8) as u16) } - } - #[inline] - pub fn set___busy(&mut self, val: ::std::os::raw::c_ushort) { - unsafe { - let val: u16 = ::std::mem::transmute(val); - self._bitfield_1.set(15usize, 1u8, val as u64) - } - } - #[inline] - pub fn new_bitfield_1( - __invalid: ::std::os::raw::c_ushort, - __denorm: ::std::os::raw::c_ushort, - __zdiv: ::std::os::raw::c_ushort, - __ovrfl: ::std::os::raw::c_ushort, - __undfl: ::std::os::raw::c_ushort, - __precis: ::std::os::raw::c_ushort, - __stkflt: ::std::os::raw::c_ushort, - __errsumm: ::std::os::raw::c_ushort, - __c0: ::std::os::raw::c_ushort, - __c1: ::std::os::raw::c_ushort, - __c2: ::std::os::raw::c_ushort, - __tos: ::std::os::raw::c_ushort, - __c3: ::std::os::raw::c_ushort, - __busy: ::std::os::raw::c_ushort, - ) -> __BindgenBitfieldUnit<[u8; 2usize]> { - let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 2usize]> = Default::default(); - __bindgen_bitfield_unit.set(0usize, 1u8, { - let __invalid: u16 = unsafe { ::std::mem::transmute(__invalid) }; - __invalid as u64 - }); - __bindgen_bitfield_unit.set(1usize, 1u8, { - let __denorm: u16 = unsafe { ::std::mem::transmute(__denorm) }; - __denorm as u64 - }); - __bindgen_bitfield_unit.set(2usize, 1u8, { - let __zdiv: u16 = unsafe { ::std::mem::transmute(__zdiv) }; - __zdiv as u64 - }); - __bindgen_bitfield_unit.set(3usize, 1u8, { - let __ovrfl: u16 = unsafe { ::std::mem::transmute(__ovrfl) }; - __ovrfl as u64 - }); - __bindgen_bitfield_unit.set(4usize, 1u8, { - let __undfl: u16 = unsafe { ::std::mem::transmute(__undfl) }; - __undfl as u64 - }); - __bindgen_bitfield_unit.set(5usize, 1u8, { - let __precis: u16 = unsafe { ::std::mem::transmute(__precis) }; - __precis as u64 - }); - __bindgen_bitfield_unit.set(6usize, 1u8, { - let __stkflt: u16 = unsafe { ::std::mem::transmute(__stkflt) }; - __stkflt as u64 - }); - __bindgen_bitfield_unit.set(7usize, 1u8, { - let __errsumm: u16 = unsafe { ::std::mem::transmute(__errsumm) }; - __errsumm as u64 - }); - __bindgen_bitfield_unit.set(8usize, 1u8, { - let __c0: u16 = unsafe { ::std::mem::transmute(__c0) }; - __c0 as u64 - }); - __bindgen_bitfield_unit.set(9usize, 1u8, { - let __c1: u16 = unsafe { ::std::mem::transmute(__c1) }; - __c1 as u64 - }); - __bindgen_bitfield_unit.set(10usize, 1u8, { - let __c2: u16 = unsafe { ::std::mem::transmute(__c2) }; - __c2 as u64 - }); - __bindgen_bitfield_unit.set(11usize, 3u8, { - let __tos: u16 = unsafe { ::std::mem::transmute(__tos) }; - __tos as u64 - }); - __bindgen_bitfield_unit.set(14usize, 1u8, { - let __c3: u16 = unsafe { ::std::mem::transmute(__c3) }; - __c3 as u64 - }); - __bindgen_bitfield_unit.set(15usize, 1u8, { - let __busy: u16 = unsafe { ::std::mem::transmute(__busy) }; - __busy as u64 - }); - __bindgen_bitfield_unit - } -} -pub type __darwin_fp_status_t = __darwin_fp_status; +pub type pthread_key_t = ::std::os::raw::c_uint; +pub type pthread_once_t = ::std::os::raw::c_int; #[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_mmst_reg { - pub __mmst_reg: [::std::os::raw::c_char; 10usize], - pub __mmst_rsrv: [::std::os::raw::c_char; 6usize], +#[derive(Copy, Clone)] +pub union pthread_attr_t { + pub __size: [::std::os::raw::c_char; 56usize], + pub __align: ::std::os::raw::c_long, } #[test] -fn bindgen_test_layout___darwin_mmst_reg() { - assert_eq!( - ::std::mem::size_of::<__darwin_mmst_reg>(), - 16usize, - concat!("Size of: ", stringify!(__darwin_mmst_reg)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_mmst_reg>(), - 1usize, - concat!("Alignment of ", stringify!(__darwin_mmst_reg)) - ); +fn bindgen_test_layout_pthread_attr_t() { assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mmst_reg>())).__mmst_reg as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mmst_reg), - "::", - stringify!(__mmst_reg) - ) + ::std::mem::size_of::(), + 56usize, + concat!("Size of: ", stringify!(pthread_attr_t)) ); assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mmst_reg>())).__mmst_rsrv as *const _ as usize }, - 10usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mmst_reg), - "::", - stringify!(__mmst_rsrv) - ) - ); + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pthread_attr_t)) + ); + fn test_field___size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__size) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_attr_t), + "::", + stringify!(__size) + ) + ); + } + test_field___size(); + fn test_field___align() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__align) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_attr_t), + "::", + stringify!(__align) + ) + ); + } + test_field___align(); } #[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_xmm_reg { - pub __xmm_reg: [::std::os::raw::c_char; 16usize], +#[derive(Copy, Clone)] +pub union pthread_mutex_t { + pub __data: __pthread_mutex_s, + pub __size: [::std::os::raw::c_char; 40usize], + pub __align: ::std::os::raw::c_long, } #[test] -fn bindgen_test_layout___darwin_xmm_reg() { - assert_eq!( - ::std::mem::size_of::<__darwin_xmm_reg>(), - 16usize, - concat!("Size of: ", stringify!(__darwin_xmm_reg)) - ); +fn bindgen_test_layout_pthread_mutex_t() { assert_eq!( - ::std::mem::align_of::<__darwin_xmm_reg>(), - 1usize, - concat!("Alignment of ", stringify!(__darwin_xmm_reg)) + ::std::mem::size_of::(), + 40usize, + concat!("Size of: ", stringify!(pthread_mutex_t)) ); assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_xmm_reg>())).__xmm_reg as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_xmm_reg), - "::", - stringify!(__xmm_reg) - ) - ); + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pthread_mutex_t)) + ); + fn test_field___data() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__data) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_mutex_t), + "::", + stringify!(__data) + ) + ); + } + test_field___data(); + fn test_field___size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__size) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_mutex_t), + "::", + stringify!(__size) + ) + ); + } + test_field___size(); + fn test_field___align() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__align) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_mutex_t), + "::", + stringify!(__align) + ) + ); + } + test_field___align(); } #[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_ymm_reg { - pub __ymm_reg: [::std::os::raw::c_char; 32usize], +#[derive(Copy, Clone)] +pub union pthread_cond_t { + pub __data: __pthread_cond_s, + pub __size: [::std::os::raw::c_char; 48usize], + pub __align: ::std::os::raw::c_longlong, } #[test] -fn bindgen_test_layout___darwin_ymm_reg() { - assert_eq!( - ::std::mem::size_of::<__darwin_ymm_reg>(), - 32usize, - concat!("Size of: ", stringify!(__darwin_ymm_reg)) - ); +fn bindgen_test_layout_pthread_cond_t() { assert_eq!( - ::std::mem::align_of::<__darwin_ymm_reg>(), - 1usize, - concat!("Alignment of ", stringify!(__darwin_ymm_reg)) + ::std::mem::size_of::(), + 48usize, + concat!("Size of: ", stringify!(pthread_cond_t)) ); assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_ymm_reg>())).__ymm_reg as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_ymm_reg), - "::", - stringify!(__ymm_reg) - ) - ); + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pthread_cond_t)) + ); + fn test_field___data() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__data) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_cond_t), + "::", + stringify!(__data) + ) + ); + } + test_field___data(); + fn test_field___size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__size) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_cond_t), + "::", + stringify!(__size) + ) + ); + } + test_field___size(); + fn test_field___align() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__align) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_cond_t), + "::", + stringify!(__align) + ) + ); + } + test_field___align(); } #[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_zmm_reg { - pub __zmm_reg: [::std::os::raw::c_char; 64usize], +#[derive(Copy, Clone)] +pub union pthread_rwlock_t { + pub __data: __pthread_rwlock_arch_t, + pub __size: [::std::os::raw::c_char; 56usize], + pub __align: ::std::os::raw::c_long, } #[test] -fn bindgen_test_layout___darwin_zmm_reg() { - assert_eq!( - ::std::mem::size_of::<__darwin_zmm_reg>(), - 64usize, - concat!("Size of: ", stringify!(__darwin_zmm_reg)) - ); +fn bindgen_test_layout_pthread_rwlock_t() { assert_eq!( - ::std::mem::align_of::<__darwin_zmm_reg>(), - 1usize, - concat!("Alignment of ", stringify!(__darwin_zmm_reg)) + ::std::mem::size_of::(), + 56usize, + concat!("Size of: ", stringify!(pthread_rwlock_t)) ); assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_zmm_reg>())).__zmm_reg as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_zmm_reg), - "::", - stringify!(__zmm_reg) - ) - ); + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pthread_rwlock_t)) + ); + fn test_field___data() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__data) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_rwlock_t), + "::", + stringify!(__data) + ) + ); + } + test_field___data(); + fn test_field___size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__size) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_rwlock_t), + "::", + stringify!(__size) + ) + ); + } + test_field___size(); + fn test_field___align() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__align) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_rwlock_t), + "::", + stringify!(__align) + ) + ); + } + test_field___align(); } #[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_opmask_reg { - pub __opmask_reg: [::std::os::raw::c_char; 8usize], +#[derive(Copy, Clone)] +pub union pthread_rwlockattr_t { + pub __size: [::std::os::raw::c_char; 8usize], + pub __align: ::std::os::raw::c_long, } #[test] -fn bindgen_test_layout___darwin_opmask_reg() { +fn bindgen_test_layout_pthread_rwlockattr_t() { assert_eq!( - ::std::mem::size_of::<__darwin_opmask_reg>(), + ::std::mem::size_of::(), 8usize, - concat!("Size of: ", stringify!(__darwin_opmask_reg)) + concat!("Size of: ", stringify!(pthread_rwlockattr_t)) ); assert_eq!( - ::std::mem::align_of::<__darwin_opmask_reg>(), - 1usize, - concat!("Alignment of ", stringify!(__darwin_opmask_reg)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_opmask_reg>())).__opmask_reg as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_opmask_reg), - "::", - stringify!(__opmask_reg) - ) - ); + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(pthread_rwlockattr_t)) + ); + fn test_field___size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__size) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_rwlockattr_t), + "::", + stringify!(__size) + ) + ); + } + test_field___size(); + fn test_field___align() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__align) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_rwlockattr_t), + "::", + stringify!(__align) + ) + ); + } + test_field___align(); } +pub type pthread_spinlock_t = ::std::os::raw::c_int; #[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_i386_float_state { - pub __fpu_reserved: [::std::os::raw::c_int; 2usize], - pub __fpu_fcw: __darwin_fp_control, - pub __fpu_fsw: __darwin_fp_status, - pub __fpu_ftw: __uint8_t, - pub __fpu_rsrv1: __uint8_t, - pub __fpu_fop: __uint16_t, - pub __fpu_ip: __uint32_t, - pub __fpu_cs: __uint16_t, - pub __fpu_rsrv2: __uint16_t, - pub __fpu_dp: __uint32_t, - pub __fpu_ds: __uint16_t, - pub __fpu_rsrv3: __uint16_t, - pub __fpu_mxcsr: __uint32_t, - pub __fpu_mxcsrmask: __uint32_t, - pub __fpu_stmm0: __darwin_mmst_reg, - pub __fpu_stmm1: __darwin_mmst_reg, - pub __fpu_stmm2: __darwin_mmst_reg, - pub __fpu_stmm3: __darwin_mmst_reg, - pub __fpu_stmm4: __darwin_mmst_reg, - pub __fpu_stmm5: __darwin_mmst_reg, - pub __fpu_stmm6: __darwin_mmst_reg, - pub __fpu_stmm7: __darwin_mmst_reg, - pub __fpu_xmm0: __darwin_xmm_reg, - pub __fpu_xmm1: __darwin_xmm_reg, - pub __fpu_xmm2: __darwin_xmm_reg, - pub __fpu_xmm3: __darwin_xmm_reg, - pub __fpu_xmm4: __darwin_xmm_reg, - pub __fpu_xmm5: __darwin_xmm_reg, - pub __fpu_xmm6: __darwin_xmm_reg, - pub __fpu_xmm7: __darwin_xmm_reg, - pub __fpu_rsrv4: [::std::os::raw::c_char; 224usize], - pub __fpu_reserved1: ::std::os::raw::c_int, +#[derive(Copy, Clone)] +pub union pthread_barrier_t { + pub __size: [::std::os::raw::c_char; 32usize], + pub __align: ::std::os::raw::c_long, } #[test] -fn bindgen_test_layout___darwin_i386_float_state() { - assert_eq!( - ::std::mem::size_of::<__darwin_i386_float_state>(), - 524usize, - concat!("Size of: ", stringify!(__darwin_i386_float_state)) - ); +fn bindgen_test_layout_pthread_barrier_t() { assert_eq!( - ::std::mem::align_of::<__darwin_i386_float_state>(), - 4usize, - concat!("Alignment of ", stringify!(__darwin_i386_float_state)) + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(pthread_barrier_t)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_reserved as *const _ - as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_reserved) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_fcw as *const _ as usize - }, + ::std::mem::align_of::(), 8usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_fcw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_fsw as *const _ as usize - }, - 10usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_fsw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_ftw as *const _ as usize - }, - 12usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_ftw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_rsrv1 as *const _ as usize - }, - 13usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_rsrv1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_fop as *const _ as usize - }, - 14usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_fop) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_ip as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_ip) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_cs as *const _ as usize - }, - 20usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_cs) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_rsrv2 as *const _ as usize - }, - 22usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_rsrv2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_dp as *const _ as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_dp) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_ds as *const _ as usize - }, - 28usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_ds) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_rsrv3 as *const _ as usize - }, - 30usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_rsrv3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_mxcsr as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_mxcsr) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_mxcsrmask as *const _ - as usize - }, - 36usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_mxcsrmask) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_stmm0 as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_stmm0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_stmm1 as *const _ as usize - }, - 56usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_stmm1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_stmm2 as *const _ as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_stmm2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_stmm3 as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_stmm3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_stmm4 as *const _ as usize - }, - 104usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_stmm4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_stmm5 as *const _ as usize - }, - 120usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_stmm5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_stmm6 as *const _ as usize - }, - 136usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_stmm6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_stmm7 as *const _ as usize - }, - 152usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_stmm7) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_xmm0 as *const _ as usize - }, - 168usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_xmm0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_xmm1 as *const _ as usize - }, - 184usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_xmm1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_xmm2 as *const _ as usize - }, - 200usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_xmm2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_xmm3 as *const _ as usize - }, - 216usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_xmm3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_xmm4 as *const _ as usize - }, - 232usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_xmm4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_xmm5 as *const _ as usize - }, - 248usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_xmm5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_xmm6 as *const _ as usize - }, - 264usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_xmm6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_xmm7 as *const _ as usize - }, - 280usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_xmm7) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_rsrv4 as *const _ as usize - }, - 296usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_rsrv4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_float_state>())).__fpu_reserved1 as *const _ - as usize - }, - 520usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_float_state), - "::", - stringify!(__fpu_reserved1) - ) - ); + concat!("Alignment of ", stringify!(pthread_barrier_t)) + ); + fn test_field___size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__size) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_barrier_t), + "::", + stringify!(__size) + ) + ); + } + test_field___size(); + fn test_field___align() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__align) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_barrier_t), + "::", + stringify!(__align) + ) + ); + } + test_field___align(); } #[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_i386_avx_state { - pub __fpu_reserved: [::std::os::raw::c_int; 2usize], - pub __fpu_fcw: __darwin_fp_control, - pub __fpu_fsw: __darwin_fp_status, - pub __fpu_ftw: __uint8_t, - pub __fpu_rsrv1: __uint8_t, - pub __fpu_fop: __uint16_t, - pub __fpu_ip: __uint32_t, - pub __fpu_cs: __uint16_t, - pub __fpu_rsrv2: __uint16_t, - pub __fpu_dp: __uint32_t, - pub __fpu_ds: __uint16_t, - pub __fpu_rsrv3: __uint16_t, - pub __fpu_mxcsr: __uint32_t, - pub __fpu_mxcsrmask: __uint32_t, - pub __fpu_stmm0: __darwin_mmst_reg, - pub __fpu_stmm1: __darwin_mmst_reg, - pub __fpu_stmm2: __darwin_mmst_reg, - pub __fpu_stmm3: __darwin_mmst_reg, - pub __fpu_stmm4: __darwin_mmst_reg, - pub __fpu_stmm5: __darwin_mmst_reg, - pub __fpu_stmm6: __darwin_mmst_reg, - pub __fpu_stmm7: __darwin_mmst_reg, - pub __fpu_xmm0: __darwin_xmm_reg, - pub __fpu_xmm1: __darwin_xmm_reg, - pub __fpu_xmm2: __darwin_xmm_reg, - pub __fpu_xmm3: __darwin_xmm_reg, - pub __fpu_xmm4: __darwin_xmm_reg, - pub __fpu_xmm5: __darwin_xmm_reg, - pub __fpu_xmm6: __darwin_xmm_reg, - pub __fpu_xmm7: __darwin_xmm_reg, - pub __fpu_rsrv4: [::std::os::raw::c_char; 224usize], - pub __fpu_reserved1: ::std::os::raw::c_int, - pub __avx_reserved1: [::std::os::raw::c_char; 64usize], - pub __fpu_ymmh0: __darwin_xmm_reg, - pub __fpu_ymmh1: __darwin_xmm_reg, - pub __fpu_ymmh2: __darwin_xmm_reg, - pub __fpu_ymmh3: __darwin_xmm_reg, - pub __fpu_ymmh4: __darwin_xmm_reg, - pub __fpu_ymmh5: __darwin_xmm_reg, - pub __fpu_ymmh6: __darwin_xmm_reg, - pub __fpu_ymmh7: __darwin_xmm_reg, +#[derive(Copy, Clone)] +pub union pthread_barrierattr_t { + pub __size: [::std::os::raw::c_char; 4usize], + pub __align: ::std::os::raw::c_int, } #[test] -fn bindgen_test_layout___darwin_i386_avx_state() { +fn bindgen_test_layout_pthread_barrierattr_t() { assert_eq!( - ::std::mem::size_of::<__darwin_i386_avx_state>(), - 716usize, - concat!("Size of: ", stringify!(__darwin_i386_avx_state)) + ::std::mem::size_of::(), + 4usize, + concat!("Size of: ", stringify!(pthread_barrierattr_t)) ); assert_eq!( - ::std::mem::align_of::<__darwin_i386_avx_state>(), + ::std::mem::align_of::(), 4usize, - concat!("Alignment of ", stringify!(__darwin_i386_avx_state)) - ); + concat!("Alignment of ", stringify!(pthread_barrierattr_t)) + ); + fn test_field___size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__size) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_barrierattr_t), + "::", + stringify!(__size) + ) + ); + } + test_field___size(); + fn test_field___align() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__align) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(pthread_barrierattr_t), + "::", + stringify!(__align) + ) + ); + } + test_field___align(); +} +extern "C" { + pub fn random() -> ::std::os::raw::c_long; +} +extern "C" { + pub fn srandom(__seed: ::std::os::raw::c_uint); +} +extern "C" { + pub fn initstate( + __seed: ::std::os::raw::c_uint, + __statebuf: *mut ::std::os::raw::c_char, + __statelen: usize, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn setstate(__statebuf: *mut ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct random_data { + pub fptr: *mut i32, + pub rptr: *mut i32, + pub state: *mut i32, + pub rand_type: ::std::os::raw::c_int, + pub rand_deg: ::std::os::raw::c_int, + pub rand_sep: ::std::os::raw::c_int, + pub end_ptr: *mut i32, +} +#[test] +fn bindgen_test_layout_random_data() { assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_reserved as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_reserved) - ) + ::std::mem::size_of::(), + 48usize, + concat!("Size of: ", stringify!(random_data)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_fcw as *const _ as usize - }, + ::std::mem::align_of::(), 8usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_fcw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_fsw as *const _ as usize - }, - 10usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_fsw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_ftw as *const _ as usize - }, - 12usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_ftw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_rsrv1 as *const _ as usize - }, - 13usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_rsrv1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_fop as *const _ as usize - }, - 14usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_fop) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_ip as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_ip) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_cs as *const _ as usize - }, - 20usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_cs) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_rsrv2 as *const _ as usize - }, - 22usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_rsrv2) - ) - ); + concat!("Alignment of ", stringify!(random_data)) + ); + fn test_field_fptr() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).fptr) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(random_data), + "::", + stringify!(fptr) + ) + ); + } + test_field_fptr(); + fn test_field_rptr() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).rptr) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(random_data), + "::", + stringify!(rptr) + ) + ); + } + test_field_rptr(); + fn test_field_state() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).state) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(random_data), + "::", + stringify!(state) + ) + ); + } + test_field_state(); + fn test_field_rand_type() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).rand_type) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(random_data), + "::", + stringify!(rand_type) + ) + ); + } + test_field_rand_type(); + fn test_field_rand_deg() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).rand_deg) as usize - ptr as usize + }, + 28usize, + concat!( + "Offset of field: ", + stringify!(random_data), + "::", + stringify!(rand_deg) + ) + ); + } + test_field_rand_deg(); + fn test_field_rand_sep() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).rand_sep) as usize - ptr as usize + }, + 32usize, + concat!( + "Offset of field: ", + stringify!(random_data), + "::", + stringify!(rand_sep) + ) + ); + } + test_field_rand_sep(); + fn test_field_end_ptr() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).end_ptr) as usize - ptr as usize + }, + 40usize, + concat!( + "Offset of field: ", + stringify!(random_data), + "::", + stringify!(end_ptr) + ) + ); + } + test_field_end_ptr(); +} +extern "C" { + pub fn random_r(__buf: *mut random_data, __result: *mut i32) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn srandom_r( + __seed: ::std::os::raw::c_uint, + __buf: *mut random_data, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn initstate_r( + __seed: ::std::os::raw::c_uint, + __statebuf: *mut ::std::os::raw::c_char, + __statelen: usize, + __buf: *mut random_data, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn setstate_r( + __statebuf: *mut ::std::os::raw::c_char, + __buf: *mut random_data, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn rand() -> ::std::os::raw::c_int; +} +extern "C" { + pub fn srand(__seed: ::std::os::raw::c_uint); +} +extern "C" { + pub fn rand_r(__seed: *mut ::std::os::raw::c_uint) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn drand48() -> f64; +} +extern "C" { + pub fn erand48(__xsubi: *mut ::std::os::raw::c_ushort) -> f64; +} +extern "C" { + pub fn lrand48() -> ::std::os::raw::c_long; +} +extern "C" { + pub fn nrand48(__xsubi: *mut ::std::os::raw::c_ushort) -> ::std::os::raw::c_long; +} +extern "C" { + pub fn mrand48() -> ::std::os::raw::c_long; +} +extern "C" { + pub fn jrand48(__xsubi: *mut ::std::os::raw::c_ushort) -> ::std::os::raw::c_long; +} +extern "C" { + pub fn srand48(__seedval: ::std::os::raw::c_long); +} +extern "C" { + pub fn seed48(__seed16v: *mut ::std::os::raw::c_ushort) -> *mut ::std::os::raw::c_ushort; +} +extern "C" { + pub fn lcong48(__param: *mut ::std::os::raw::c_ushort); +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct drand48_data { + pub __x: [::std::os::raw::c_ushort; 3usize], + pub __old_x: [::std::os::raw::c_ushort; 3usize], + pub __c: ::std::os::raw::c_ushort, + pub __init: ::std::os::raw::c_ushort, + pub __a: ::std::os::raw::c_ulonglong, +} +#[test] +fn bindgen_test_layout_drand48_data() { assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_dp as *const _ as usize - }, + ::std::mem::size_of::(), 24usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_dp) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_ds as *const _ as usize - }, - 28usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_ds) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_rsrv3 as *const _ as usize - }, - 30usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_rsrv3) - ) + concat!("Size of: ", stringify!(drand48_data)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_mxcsr as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_mxcsr) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_mxcsrmask as *const _ as usize - }, - 36usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_mxcsrmask) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_stmm0 as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_stmm0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_stmm1 as *const _ as usize - }, - 56usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_stmm1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_stmm2 as *const _ as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_stmm2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_stmm3 as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_stmm3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_stmm4 as *const _ as usize - }, - 104usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_stmm4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_stmm5 as *const _ as usize - }, - 120usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_stmm5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_stmm6 as *const _ as usize - }, - 136usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_stmm6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_stmm7 as *const _ as usize - }, - 152usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_stmm7) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_xmm0 as *const _ as usize - }, - 168usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_xmm0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_xmm1 as *const _ as usize - }, - 184usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_xmm1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_xmm2 as *const _ as usize - }, - 200usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_xmm2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_xmm3 as *const _ as usize - }, - 216usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_xmm3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_xmm4 as *const _ as usize - }, - 232usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_xmm4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_xmm5 as *const _ as usize - }, - 248usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_xmm5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_xmm6 as *const _ as usize - }, - 264usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_xmm6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_xmm7 as *const _ as usize - }, - 280usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_xmm7) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_rsrv4 as *const _ as usize - }, - 296usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_rsrv4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_reserved1 as *const _ as usize - }, - 520usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_reserved1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__avx_reserved1 as *const _ as usize - }, - 524usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__avx_reserved1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_ymmh0 as *const _ as usize - }, - 588usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_ymmh0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_ymmh1 as *const _ as usize - }, - 604usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_ymmh1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_ymmh2 as *const _ as usize - }, - 620usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_ymmh2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_ymmh3 as *const _ as usize - }, - 636usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_ymmh3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_ymmh4 as *const _ as usize - }, - 652usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_ymmh4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_ymmh5 as *const _ as usize - }, - 668usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_ymmh5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_ymmh6 as *const _ as usize - }, - 684usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_ymmh6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx_state>())).__fpu_ymmh7 as *const _ as usize - }, - 700usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx_state), - "::", - stringify!(__fpu_ymmh7) - ) - ); + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(drand48_data)) + ); + fn test_field___x() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__x) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(drand48_data), + "::", + stringify!(__x) + ) + ); + } + test_field___x(); + fn test_field___old_x() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__old_x) as usize - ptr as usize + }, + 6usize, + concat!( + "Offset of field: ", + stringify!(drand48_data), + "::", + stringify!(__old_x) + ) + ); + } + test_field___old_x(); + fn test_field___c() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__c) as usize - ptr as usize + }, + 12usize, + concat!( + "Offset of field: ", + stringify!(drand48_data), + "::", + stringify!(__c) + ) + ); + } + test_field___c(); + fn test_field___init() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__init) as usize - ptr as usize + }, + 14usize, + concat!( + "Offset of field: ", + stringify!(drand48_data), + "::", + stringify!(__init) + ) + ); + } + test_field___init(); + fn test_field___a() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__a) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(drand48_data), + "::", + stringify!(__a) + ) + ); + } + test_field___a(); } -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_i386_avx512_state { - pub __fpu_reserved: [::std::os::raw::c_int; 2usize], - pub __fpu_fcw: __darwin_fp_control, - pub __fpu_fsw: __darwin_fp_status, - pub __fpu_ftw: __uint8_t, - pub __fpu_rsrv1: __uint8_t, - pub __fpu_fop: __uint16_t, - pub __fpu_ip: __uint32_t, - pub __fpu_cs: __uint16_t, - pub __fpu_rsrv2: __uint16_t, - pub __fpu_dp: __uint32_t, - pub __fpu_ds: __uint16_t, - pub __fpu_rsrv3: __uint16_t, - pub __fpu_mxcsr: __uint32_t, - pub __fpu_mxcsrmask: __uint32_t, - pub __fpu_stmm0: __darwin_mmst_reg, - pub __fpu_stmm1: __darwin_mmst_reg, - pub __fpu_stmm2: __darwin_mmst_reg, - pub __fpu_stmm3: __darwin_mmst_reg, - pub __fpu_stmm4: __darwin_mmst_reg, - pub __fpu_stmm5: __darwin_mmst_reg, - pub __fpu_stmm6: __darwin_mmst_reg, - pub __fpu_stmm7: __darwin_mmst_reg, - pub __fpu_xmm0: __darwin_xmm_reg, - pub __fpu_xmm1: __darwin_xmm_reg, - pub __fpu_xmm2: __darwin_xmm_reg, - pub __fpu_xmm3: __darwin_xmm_reg, - pub __fpu_xmm4: __darwin_xmm_reg, - pub __fpu_xmm5: __darwin_xmm_reg, - pub __fpu_xmm6: __darwin_xmm_reg, - pub __fpu_xmm7: __darwin_xmm_reg, - pub __fpu_rsrv4: [::std::os::raw::c_char; 224usize], - pub __fpu_reserved1: ::std::os::raw::c_int, - pub __avx_reserved1: [::std::os::raw::c_char; 64usize], - pub __fpu_ymmh0: __darwin_xmm_reg, - pub __fpu_ymmh1: __darwin_xmm_reg, - pub __fpu_ymmh2: __darwin_xmm_reg, - pub __fpu_ymmh3: __darwin_xmm_reg, - pub __fpu_ymmh4: __darwin_xmm_reg, - pub __fpu_ymmh5: __darwin_xmm_reg, - pub __fpu_ymmh6: __darwin_xmm_reg, - pub __fpu_ymmh7: __darwin_xmm_reg, - pub __fpu_k0: __darwin_opmask_reg, - pub __fpu_k1: __darwin_opmask_reg, - pub __fpu_k2: __darwin_opmask_reg, - pub __fpu_k3: __darwin_opmask_reg, - pub __fpu_k4: __darwin_opmask_reg, - pub __fpu_k5: __darwin_opmask_reg, - pub __fpu_k6: __darwin_opmask_reg, - pub __fpu_k7: __darwin_opmask_reg, - pub __fpu_zmmh0: __darwin_ymm_reg, - pub __fpu_zmmh1: __darwin_ymm_reg, - pub __fpu_zmmh2: __darwin_ymm_reg, - pub __fpu_zmmh3: __darwin_ymm_reg, - pub __fpu_zmmh4: __darwin_ymm_reg, - pub __fpu_zmmh5: __darwin_ymm_reg, - pub __fpu_zmmh6: __darwin_ymm_reg, - pub __fpu_zmmh7: __darwin_ymm_reg, +extern "C" { + pub fn drand48_r(__buffer: *mut drand48_data, __result: *mut f64) -> ::std::os::raw::c_int; } -#[test] -fn bindgen_test_layout___darwin_i386_avx512_state() { - assert_eq!( - ::std::mem::size_of::<__darwin_i386_avx512_state>(), - 1036usize, - concat!("Size of: ", stringify!(__darwin_i386_avx512_state)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_i386_avx512_state>(), - 4usize, - concat!("Alignment of ", stringify!(__darwin_i386_avx512_state)) +extern "C" { + pub fn erand48_r( + __xsubi: *mut ::std::os::raw::c_ushort, + __buffer: *mut drand48_data, + __result: *mut f64, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn lrand48_r( + __buffer: *mut drand48_data, + __result: *mut ::std::os::raw::c_long, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn nrand48_r( + __xsubi: *mut ::std::os::raw::c_ushort, + __buffer: *mut drand48_data, + __result: *mut ::std::os::raw::c_long, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn mrand48_r( + __buffer: *mut drand48_data, + __result: *mut ::std::os::raw::c_long, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn jrand48_r( + __xsubi: *mut ::std::os::raw::c_ushort, + __buffer: *mut drand48_data, + __result: *mut ::std::os::raw::c_long, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn srand48_r( + __seedval: ::std::os::raw::c_long, + __buffer: *mut drand48_data, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn seed48_r( + __seed16v: *mut ::std::os::raw::c_ushort, + __buffer: *mut drand48_data, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn lcong48_r( + __param: *mut ::std::os::raw::c_ushort, + __buffer: *mut drand48_data, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn malloc(__size: ::std::os::raw::c_ulong) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn calloc( + __nmemb: ::std::os::raw::c_ulong, + __size: ::std::os::raw::c_ulong, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn realloc( + __ptr: *mut ::std::os::raw::c_void, + __size: ::std::os::raw::c_ulong, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn reallocarray( + __ptr: *mut ::std::os::raw::c_void, + __nmemb: usize, + __size: usize, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn free(__ptr: *mut ::std::os::raw::c_void); +} +extern "C" { + pub fn alloca(__size: ::std::os::raw::c_ulong) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn valloc(__size: usize) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn posix_memalign( + __memptr: *mut *mut ::std::os::raw::c_void, + __alignment: usize, + __size: usize, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn aligned_alloc(__alignment: usize, __size: usize) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn abort(); +} +extern "C" { + pub fn atexit(__func: ::std::option::Option) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn at_quick_exit( + __func: ::std::option::Option, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn on_exit( + __func: ::std::option::Option< + unsafe extern "C" fn( + __status: ::std::os::raw::c_int, + __arg: *mut ::std::os::raw::c_void, + ), + >, + __arg: *mut ::std::os::raw::c_void, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn exit(__status: ::std::os::raw::c_int); +} +extern "C" { + pub fn quick_exit(__status: ::std::os::raw::c_int); +} +extern "C" { + pub fn _Exit(__status: ::std::os::raw::c_int); +} +extern "C" { + pub fn getenv(__name: *const ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn putenv(__string: *mut ::std::os::raw::c_char) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn setenv( + __name: *const ::std::os::raw::c_char, + __value: *const ::std::os::raw::c_char, + __replace: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn unsetenv(__name: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn clearenv() -> ::std::os::raw::c_int; +} +extern "C" { + pub fn mktemp(__template: *mut ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn mkstemp(__template: *mut ::std::os::raw::c_char) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn mkstemps( + __template: *mut ::std::os::raw::c_char, + __suffixlen: ::std::os::raw::c_int, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn mkdtemp(__template: *mut ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn system(__command: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn realpath( + __name: *const ::std::os::raw::c_char, + __resolved: *mut ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; +} +pub type __compar_fn_t = ::std::option::Option< + unsafe extern "C" fn( + arg1: *const ::std::os::raw::c_void, + arg2: *const ::std::os::raw::c_void, + ) -> ::std::os::raw::c_int, +>; +extern "C" { + pub fn bsearch( + __key: *const ::std::os::raw::c_void, + __base: *const ::std::os::raw::c_void, + __nmemb: usize, + __size: usize, + __compar: __compar_fn_t, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn qsort( + __base: *mut ::std::os::raw::c_void, + __nmemb: usize, + __size: usize, + __compar: __compar_fn_t, ); +} +extern "C" { + pub fn abs(__x: ::std::os::raw::c_int) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn labs(__x: ::std::os::raw::c_long) -> ::std::os::raw::c_long; +} +extern "C" { + pub fn llabs(__x: ::std::os::raw::c_longlong) -> ::std::os::raw::c_longlong; +} +extern "C" { + pub fn div(__numer: ::std::os::raw::c_int, __denom: ::std::os::raw::c_int) -> div_t; +} +extern "C" { + pub fn ldiv(__numer: ::std::os::raw::c_long, __denom: ::std::os::raw::c_long) -> ldiv_t; +} +extern "C" { + pub fn lldiv( + __numer: ::std::os::raw::c_longlong, + __denom: ::std::os::raw::c_longlong, + ) -> lldiv_t; +} +extern "C" { + pub fn ecvt( + __value: f64, + __ndigit: ::std::os::raw::c_int, + __decpt: *mut ::std::os::raw::c_int, + __sign: *mut ::std::os::raw::c_int, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn fcvt( + __value: f64, + __ndigit: ::std::os::raw::c_int, + __decpt: *mut ::std::os::raw::c_int, + __sign: *mut ::std::os::raw::c_int, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn gcvt( + __value: f64, + __ndigit: ::std::os::raw::c_int, + __buf: *mut ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn qecvt( + __value: u128, + __ndigit: ::std::os::raw::c_int, + __decpt: *mut ::std::os::raw::c_int, + __sign: *mut ::std::os::raw::c_int, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn qfcvt( + __value: u128, + __ndigit: ::std::os::raw::c_int, + __decpt: *mut ::std::os::raw::c_int, + __sign: *mut ::std::os::raw::c_int, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn qgcvt( + __value: u128, + __ndigit: ::std::os::raw::c_int, + __buf: *mut ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn ecvt_r( + __value: f64, + __ndigit: ::std::os::raw::c_int, + __decpt: *mut ::std::os::raw::c_int, + __sign: *mut ::std::os::raw::c_int, + __buf: *mut ::std::os::raw::c_char, + __len: usize, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn fcvt_r( + __value: f64, + __ndigit: ::std::os::raw::c_int, + __decpt: *mut ::std::os::raw::c_int, + __sign: *mut ::std::os::raw::c_int, + __buf: *mut ::std::os::raw::c_char, + __len: usize, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn qecvt_r( + __value: u128, + __ndigit: ::std::os::raw::c_int, + __decpt: *mut ::std::os::raw::c_int, + __sign: *mut ::std::os::raw::c_int, + __buf: *mut ::std::os::raw::c_char, + __len: usize, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn qfcvt_r( + __value: u128, + __ndigit: ::std::os::raw::c_int, + __decpt: *mut ::std::os::raw::c_int, + __sign: *mut ::std::os::raw::c_int, + __buf: *mut ::std::os::raw::c_char, + __len: usize, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn mblen(__s: *const ::std::os::raw::c_char, __n: usize) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn mbtowc( + __pwc: *mut wchar_t, + __s: *const ::std::os::raw::c_char, + __n: usize, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn wctomb(__s: *mut ::std::os::raw::c_char, __wchar: wchar_t) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn mbstowcs(__pwcs: *mut wchar_t, __s: *const ::std::os::raw::c_char, __n: usize) -> usize; +} +extern "C" { + pub fn wcstombs(__s: *mut ::std::os::raw::c_char, __pwcs: *const wchar_t, __n: usize) -> usize; +} +extern "C" { + pub fn rpmatch(__response: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn getsubopt( + __optionp: *mut *mut ::std::os::raw::c_char, + __tokens: *const *mut ::std::os::raw::c_char, + __valuep: *mut *mut ::std::os::raw::c_char, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn getloadavg(__loadavg: *mut f64, __nelem: ::std::os::raw::c_int) + -> ::std::os::raw::c_int; +} +pub type int_least8_t = __int_least8_t; +pub type int_least16_t = __int_least16_t; +pub type int_least32_t = __int_least32_t; +pub type int_least64_t = __int_least64_t; +pub type uint_least8_t = __uint_least8_t; +pub type uint_least16_t = __uint_least16_t; +pub type uint_least32_t = __uint_least32_t; +pub type uint_least64_t = __uint_least64_t; +pub type int_fast8_t = ::std::os::raw::c_schar; +pub type int_fast16_t = ::std::os::raw::c_long; +pub type int_fast32_t = ::std::os::raw::c_long; +pub type int_fast64_t = ::std::os::raw::c_long; +pub type uint_fast8_t = ::std::os::raw::c_uchar; +pub type uint_fast16_t = ::std::os::raw::c_ulong; +pub type uint_fast32_t = ::std::os::raw::c_ulong; +pub type uint_fast64_t = ::std::os::raw::c_ulong; +pub type intmax_t = __intmax_t; +pub type uintmax_t = __uintmax_t; +extern "C" { + pub fn memcpy( + __dest: *mut ::std::os::raw::c_void, + __src: *const ::std::os::raw::c_void, + __n: ::std::os::raw::c_ulong, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn memmove( + __dest: *mut ::std::os::raw::c_void, + __src: *const ::std::os::raw::c_void, + __n: ::std::os::raw::c_ulong, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn memccpy( + __dest: *mut ::std::os::raw::c_void, + __src: *const ::std::os::raw::c_void, + __c: ::std::os::raw::c_int, + __n: ::std::os::raw::c_ulong, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn memset( + __s: *mut ::std::os::raw::c_void, + __c: ::std::os::raw::c_int, + __n: ::std::os::raw::c_ulong, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn memcmp( + __s1: *const ::std::os::raw::c_void, + __s2: *const ::std::os::raw::c_void, + __n: ::std::os::raw::c_ulong, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn memchr( + __s: *const ::std::os::raw::c_void, + __c: ::std::os::raw::c_int, + __n: ::std::os::raw::c_ulong, + ) -> *mut ::std::os::raw::c_void; +} +extern "C" { + pub fn strcpy( + __dest: *mut ::std::os::raw::c_char, + __src: *const ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn strncpy( + __dest: *mut ::std::os::raw::c_char, + __src: *const ::std::os::raw::c_char, + __n: ::std::os::raw::c_ulong, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn strcat( + __dest: *mut ::std::os::raw::c_char, + __src: *const ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn strncat( + __dest: *mut ::std::os::raw::c_char, + __src: *const ::std::os::raw::c_char, + __n: ::std::os::raw::c_ulong, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn strcmp( + __s1: *const ::std::os::raw::c_char, + __s2: *const ::std::os::raw::c_char, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn strncmp( + __s1: *const ::std::os::raw::c_char, + __s2: *const ::std::os::raw::c_char, + __n: ::std::os::raw::c_ulong, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn strcoll( + __s1: *const ::std::os::raw::c_char, + __s2: *const ::std::os::raw::c_char, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn strxfrm( + __dest: *mut ::std::os::raw::c_char, + __src: *const ::std::os::raw::c_char, + __n: ::std::os::raw::c_ulong, + ) -> ::std::os::raw::c_ulong; +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __locale_struct { + pub __locales: [*mut __locale_data; 13usize], + pub __ctype_b: *const ::std::os::raw::c_ushort, + pub __ctype_tolower: *const ::std::os::raw::c_int, + pub __ctype_toupper: *const ::std::os::raw::c_int, + pub __names: [*const ::std::os::raw::c_char; 13usize], +} +#[test] +fn bindgen_test_layout___locale_struct() { assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_reserved as *const _ - as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_reserved) - ) + ::std::mem::size_of::<__locale_struct>(), + 232usize, + concat!("Size of: ", stringify!(__locale_struct)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_fcw as *const _ as usize - }, + ::std::mem::align_of::<__locale_struct>(), 8usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_fcw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_fsw as *const _ as usize - }, - 10usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_fsw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_ftw as *const _ as usize - }, - 12usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_ftw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_rsrv1 as *const _ as usize - }, - 13usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_rsrv1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_fop as *const _ as usize - }, - 14usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_fop) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_ip as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_ip) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_cs as *const _ as usize - }, - 20usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_cs) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_rsrv2 as *const _ as usize - }, - 22usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_rsrv2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_dp as *const _ as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_dp) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_ds as *const _ as usize - }, - 28usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_ds) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_rsrv3 as *const _ as usize - }, - 30usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_rsrv3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_mxcsr as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_mxcsr) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_mxcsrmask as *const _ - as usize - }, - 36usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_mxcsrmask) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_stmm0 as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_stmm0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_stmm1 as *const _ as usize - }, - 56usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_stmm1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_stmm2 as *const _ as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_stmm2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_stmm3 as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_stmm3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_stmm4 as *const _ as usize - }, - 104usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_stmm4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_stmm5 as *const _ as usize - }, - 120usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_stmm5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_stmm6 as *const _ as usize - }, - 136usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_stmm6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_stmm7 as *const _ as usize - }, - 152usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_stmm7) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_xmm0 as *const _ as usize - }, - 168usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_xmm0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_xmm1 as *const _ as usize - }, - 184usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_xmm1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_xmm2 as *const _ as usize - }, - 200usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_xmm2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_xmm3 as *const _ as usize - }, - 216usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_xmm3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_xmm4 as *const _ as usize - }, - 232usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_xmm4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_xmm5 as *const _ as usize - }, - 248usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_xmm5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_xmm6 as *const _ as usize - }, - 264usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_xmm6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_xmm7 as *const _ as usize - }, - 280usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_xmm7) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_rsrv4 as *const _ as usize - }, - 296usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_rsrv4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_reserved1 as *const _ - as usize - }, - 520usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_reserved1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__avx_reserved1 as *const _ - as usize - }, - 524usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__avx_reserved1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_ymmh0 as *const _ as usize - }, - 588usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_ymmh0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_ymmh1 as *const _ as usize - }, - 604usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_ymmh1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_ymmh2 as *const _ as usize - }, - 620usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_ymmh2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_ymmh3 as *const _ as usize - }, - 636usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_ymmh3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_ymmh4 as *const _ as usize - }, - 652usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_ymmh4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_ymmh5 as *const _ as usize - }, - 668usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_ymmh5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_ymmh6 as *const _ as usize - }, - 684usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_ymmh6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_ymmh7 as *const _ as usize - }, - 700usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_ymmh7) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_k0 as *const _ as usize - }, - 716usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_k0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_k1 as *const _ as usize - }, - 724usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_k1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_k2 as *const _ as usize - }, - 732usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_k2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_k3 as *const _ as usize - }, - 740usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_k3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_k4 as *const _ as usize - }, - 748usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_k4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_k5 as *const _ as usize - }, - 756usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_k5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_k6 as *const _ as usize - }, - 764usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_k6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_k7 as *const _ as usize - }, - 772usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_k7) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_zmmh0 as *const _ as usize - }, - 780usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_zmmh0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_zmmh1 as *const _ as usize - }, - 812usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_zmmh1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_zmmh2 as *const _ as usize - }, - 844usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_zmmh2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_zmmh3 as *const _ as usize - }, - 876usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_zmmh3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_zmmh4 as *const _ as usize - }, - 908usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_zmmh4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_zmmh5 as *const _ as usize - }, - 940usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_zmmh5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_zmmh6 as *const _ as usize - }, - 972usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_zmmh6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_avx512_state>())).__fpu_zmmh7 as *const _ as usize - }, - 1004usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_avx512_state), - "::", - stringify!(__fpu_zmmh7) - ) - ); + concat!("Alignment of ", stringify!(__locale_struct)) + ); + fn test_field___locales() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__locale_struct>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__locales) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__locale_struct), + "::", + stringify!(__locales) + ) + ); + } + test_field___locales(); + fn test_field___ctype_b() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__locale_struct>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__ctype_b) as usize - ptr as usize + }, + 104usize, + concat!( + "Offset of field: ", + stringify!(__locale_struct), + "::", + stringify!(__ctype_b) + ) + ); + } + test_field___ctype_b(); + fn test_field___ctype_tolower() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__locale_struct>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__ctype_tolower) as usize - ptr as usize + }, + 112usize, + concat!( + "Offset of field: ", + stringify!(__locale_struct), + "::", + stringify!(__ctype_tolower) + ) + ); + } + test_field___ctype_tolower(); + fn test_field___ctype_toupper() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__locale_struct>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__ctype_toupper) as usize - ptr as usize + }, + 120usize, + concat!( + "Offset of field: ", + stringify!(__locale_struct), + "::", + stringify!(__ctype_toupper) + ) + ); + } + test_field___ctype_toupper(); + fn test_field___names() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__locale_struct>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__names) as usize - ptr as usize + }, + 128usize, + concat!( + "Offset of field: ", + stringify!(__locale_struct), + "::", + stringify!(__names) + ) + ); + } + test_field___names(); } -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_i386_exception_state { - pub __trapno: __uint16_t, - pub __cpu: __uint16_t, - pub __err: __uint32_t, - pub __faultvaddr: __uint32_t, +pub type __locale_t = *mut __locale_struct; +pub type locale_t = __locale_t; +extern "C" { + pub fn strcoll_l( + __s1: *const ::std::os::raw::c_char, + __s2: *const ::std::os::raw::c_char, + __l: locale_t, + ) -> ::std::os::raw::c_int; } -#[test] -fn bindgen_test_layout___darwin_i386_exception_state() { - assert_eq!( - ::std::mem::size_of::<__darwin_i386_exception_state>(), - 12usize, - concat!("Size of: ", stringify!(__darwin_i386_exception_state)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_i386_exception_state>(), - 4usize, - concat!("Alignment of ", stringify!(__darwin_i386_exception_state)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_exception_state>())).__trapno as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_exception_state), - "::", - stringify!(__trapno) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_exception_state>())).__cpu as *const _ as usize - }, - 2usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_exception_state), - "::", - stringify!(__cpu) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_exception_state>())).__err as *const _ as usize - }, - 4usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_exception_state), - "::", - stringify!(__err) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_i386_exception_state>())).__faultvaddr as *const _ - as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__darwin_i386_exception_state), - "::", - stringify!(__faultvaddr) - ) - ); +extern "C" { + pub fn strxfrm_l( + __dest: *mut ::std::os::raw::c_char, + __src: *const ::std::os::raw::c_char, + __n: usize, + __l: locale_t, + ) -> usize; } -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_x86_debug_state32 { - pub __dr0: ::std::os::raw::c_uint, - pub __dr1: ::std::os::raw::c_uint, - pub __dr2: ::std::os::raw::c_uint, - pub __dr3: ::std::os::raw::c_uint, - pub __dr4: ::std::os::raw::c_uint, - pub __dr5: ::std::os::raw::c_uint, - pub __dr6: ::std::os::raw::c_uint, - pub __dr7: ::std::os::raw::c_uint, +extern "C" { + pub fn strdup(__s: *const ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; } -#[test] -fn bindgen_test_layout___darwin_x86_debug_state32() { - assert_eq!( - ::std::mem::size_of::<__darwin_x86_debug_state32>(), - 32usize, - concat!("Size of: ", stringify!(__darwin_x86_debug_state32)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_x86_debug_state32>(), - 4usize, - concat!("Alignment of ", stringify!(__darwin_x86_debug_state32)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_debug_state32>())).__dr0 as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_debug_state32), - "::", - stringify!(__dr0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_debug_state32>())).__dr1 as *const _ as usize - }, - 4usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_debug_state32), - "::", - stringify!(__dr1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_debug_state32>())).__dr2 as *const _ as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_debug_state32), - "::", - stringify!(__dr2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_debug_state32>())).__dr3 as *const _ as usize - }, - 12usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_debug_state32), - "::", - stringify!(__dr3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_debug_state32>())).__dr4 as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_debug_state32), - "::", - stringify!(__dr4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_debug_state32>())).__dr5 as *const _ as usize - }, - 20usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_debug_state32), - "::", - stringify!(__dr5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_debug_state32>())).__dr6 as *const _ as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_debug_state32), - "::", - stringify!(__dr6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_debug_state32>())).__dr7 as *const _ as usize - }, - 28usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_debug_state32), - "::", - stringify!(__dr7) - ) - ); +extern "C" { + pub fn strndup( + __string: *const ::std::os::raw::c_char, + __n: ::std::os::raw::c_ulong, + ) -> *mut ::std::os::raw::c_char; } -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __x86_instruction_state { - pub __insn_stream_valid_bytes: ::std::os::raw::c_int, - pub __insn_offset: ::std::os::raw::c_int, - pub __out_of_synch: ::std::os::raw::c_int, - pub __insn_bytes: [__uint8_t; 2380usize], - pub __insn_cacheline: [__uint8_t; 64usize], +extern "C" { + pub fn strchr( + __s: *const ::std::os::raw::c_char, + __c: ::std::os::raw::c_int, + ) -> *mut ::std::os::raw::c_char; } -#[test] -fn bindgen_test_layout___x86_instruction_state() { - assert_eq!( - ::std::mem::size_of::<__x86_instruction_state>(), - 2456usize, - concat!("Size of: ", stringify!(__x86_instruction_state)) - ); - assert_eq!( - ::std::mem::align_of::<__x86_instruction_state>(), - 4usize, - concat!("Alignment of ", stringify!(__x86_instruction_state)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__x86_instruction_state>())).__insn_stream_valid_bytes - as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__x86_instruction_state), - "::", - stringify!(__insn_stream_valid_bytes) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__x86_instruction_state>())).__insn_offset as *const _ as usize - }, - 4usize, - concat!( - "Offset of field: ", - stringify!(__x86_instruction_state), - "::", - stringify!(__insn_offset) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__x86_instruction_state>())).__out_of_synch as *const _ as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__x86_instruction_state), - "::", - stringify!(__out_of_synch) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__x86_instruction_state>())).__insn_bytes as *const _ as usize - }, - 12usize, - concat!( - "Offset of field: ", - stringify!(__x86_instruction_state), - "::", - stringify!(__insn_bytes) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__x86_instruction_state>())).__insn_cacheline as *const _ - as usize - }, - 2392usize, - concat!( - "Offset of field: ", - stringify!(__x86_instruction_state), - "::", - stringify!(__insn_cacheline) - ) - ); +extern "C" { + pub fn strrchr( + __s: *const ::std::os::raw::c_char, + __c: ::std::os::raw::c_int, + ) -> *mut ::std::os::raw::c_char; } -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __last_branch_record { - pub __from_ip: __uint64_t, - pub __to_ip: __uint64_t, - pub _bitfield_align_1: [u16; 0], - pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, - pub __bindgen_padding_0: u32, +extern "C" { + pub fn strcspn( + __s: *const ::std::os::raw::c_char, + __reject: *const ::std::os::raw::c_char, + ) -> ::std::os::raw::c_ulong; } -#[test] -fn bindgen_test_layout___last_branch_record() { - assert_eq!( - ::std::mem::size_of::<__last_branch_record>(), - 24usize, - concat!("Size of: ", stringify!(__last_branch_record)) - ); - assert_eq!( - ::std::mem::align_of::<__last_branch_record>(), - 8usize, - concat!("Alignment of ", stringify!(__last_branch_record)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__last_branch_record>())).__from_ip as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__last_branch_record), - "::", - stringify!(__from_ip) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__last_branch_record>())).__to_ip as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__last_branch_record), - "::", - stringify!(__to_ip) - ) - ); +extern "C" { + pub fn strspn( + __s: *const ::std::os::raw::c_char, + __accept: *const ::std::os::raw::c_char, + ) -> ::std::os::raw::c_ulong; } -impl __last_branch_record { - #[inline] - pub fn __mispredict(&self) -> __uint32_t { - unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u32) } - } - #[inline] - pub fn set___mispredict(&mut self, val: __uint32_t) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(0usize, 1u8, val as u64) - } - } - #[inline] - pub fn __tsx_abort(&self) -> __uint32_t { - unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 1u8) as u32) } - } - #[inline] - pub fn set___tsx_abort(&mut self, val: __uint32_t) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(1usize, 1u8, val as u64) - } - } - #[inline] - pub fn __in_tsx(&self) -> __uint32_t { - unsafe { ::std::mem::transmute(self._bitfield_1.get(2usize, 1u8) as u32) } - } - #[inline] - pub fn set___in_tsx(&mut self, val: __uint32_t) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(2usize, 1u8, val as u64) - } - } - #[inline] - pub fn __cycle_count(&self) -> __uint32_t { - unsafe { ::std::mem::transmute(self._bitfield_1.get(3usize, 16u8) as u32) } - } - #[inline] - pub fn set___cycle_count(&mut self, val: __uint32_t) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(3usize, 16u8, val as u64) - } - } - #[inline] - pub fn __reserved(&self) -> __uint32_t { - unsafe { ::std::mem::transmute(self._bitfield_1.get(19usize, 13u8) as u32) } - } - #[inline] - pub fn set___reserved(&mut self, val: __uint32_t) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(19usize, 13u8, val as u64) - } - } - #[inline] - pub fn new_bitfield_1( - __mispredict: __uint32_t, - __tsx_abort: __uint32_t, - __in_tsx: __uint32_t, - __cycle_count: __uint32_t, - __reserved: __uint32_t, - ) -> __BindgenBitfieldUnit<[u8; 4usize]> { - let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 4usize]> = Default::default(); - __bindgen_bitfield_unit.set(0usize, 1u8, { - let __mispredict: u32 = unsafe { ::std::mem::transmute(__mispredict) }; - __mispredict as u64 - }); - __bindgen_bitfield_unit.set(1usize, 1u8, { - let __tsx_abort: u32 = unsafe { ::std::mem::transmute(__tsx_abort) }; - __tsx_abort as u64 - }); - __bindgen_bitfield_unit.set(2usize, 1u8, { - let __in_tsx: u32 = unsafe { ::std::mem::transmute(__in_tsx) }; - __in_tsx as u64 - }); - __bindgen_bitfield_unit.set(3usize, 16u8, { - let __cycle_count: u32 = unsafe { ::std::mem::transmute(__cycle_count) }; - __cycle_count as u64 - }); - __bindgen_bitfield_unit.set(19usize, 13u8, { - let __reserved: u32 = unsafe { ::std::mem::transmute(__reserved) }; - __reserved as u64 - }); - __bindgen_bitfield_unit - } +extern "C" { + pub fn strpbrk( + __s: *const ::std::os::raw::c_char, + __accept: *const ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; } -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __last_branch_state { - pub __lbr_count: ::std::os::raw::c_int, - pub _bitfield_align_1: [u32; 0], - pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, - pub __lbrs: [__last_branch_record; 32usize], +extern "C" { + pub fn strstr( + __haystack: *const ::std::os::raw::c_char, + __needle: *const ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; } -#[test] -fn bindgen_test_layout___last_branch_state() { - assert_eq!( - ::std::mem::size_of::<__last_branch_state>(), - 776usize, - concat!("Size of: ", stringify!(__last_branch_state)) - ); - assert_eq!( - ::std::mem::align_of::<__last_branch_state>(), - 8usize, - concat!("Alignment of ", stringify!(__last_branch_state)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__last_branch_state>())).__lbr_count as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__last_branch_state), - "::", - stringify!(__lbr_count) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__last_branch_state>())).__lbrs as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__last_branch_state), - "::", - stringify!(__lbrs) - ) - ); +extern "C" { + pub fn strtok( + __s: *mut ::std::os::raw::c_char, + __delim: *const ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; } -impl __last_branch_state { - #[inline] - pub fn __lbr_supported_tsx(&self) -> __uint32_t { - unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u32) } - } - #[inline] - pub fn set___lbr_supported_tsx(&mut self, val: __uint32_t) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(0usize, 1u8, val as u64) - } - } - #[inline] - pub fn __lbr_supported_cycle_count(&self) -> __uint32_t { - unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 1u8) as u32) } - } - #[inline] - pub fn set___lbr_supported_cycle_count(&mut self, val: __uint32_t) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(1usize, 1u8, val as u64) - } - } - #[inline] - pub fn __reserved(&self) -> __uint32_t { - unsafe { ::std::mem::transmute(self._bitfield_1.get(2usize, 30u8) as u32) } - } - #[inline] - pub fn set___reserved(&mut self, val: __uint32_t) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(2usize, 30u8, val as u64) - } - } - #[inline] - pub fn new_bitfield_1( - __lbr_supported_tsx: __uint32_t, - __lbr_supported_cycle_count: __uint32_t, - __reserved: __uint32_t, - ) -> __BindgenBitfieldUnit<[u8; 4usize]> { - let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 4usize]> = Default::default(); - __bindgen_bitfield_unit.set(0usize, 1u8, { - let __lbr_supported_tsx: u32 = unsafe { ::std::mem::transmute(__lbr_supported_tsx) }; - __lbr_supported_tsx as u64 - }); - __bindgen_bitfield_unit.set(1usize, 1u8, { - let __lbr_supported_cycle_count: u32 = - unsafe { ::std::mem::transmute(__lbr_supported_cycle_count) }; - __lbr_supported_cycle_count as u64 - }); - __bindgen_bitfield_unit.set(2usize, 30u8, { - let __reserved: u32 = unsafe { ::std::mem::transmute(__reserved) }; - __reserved as u64 - }); - __bindgen_bitfield_unit - } +extern "C" { + pub fn __strtok_r( + __s: *mut ::std::os::raw::c_char, + __delim: *const ::std::os::raw::c_char, + __save_ptr: *mut *mut ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; } -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __x86_pagein_state { - pub __pagein_error: ::std::os::raw::c_int, +extern "C" { + pub fn strtok_r( + __s: *mut ::std::os::raw::c_char, + __delim: *const ::std::os::raw::c_char, + __save_ptr: *mut *mut ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; } -#[test] -fn bindgen_test_layout___x86_pagein_state() { - assert_eq!( - ::std::mem::size_of::<__x86_pagein_state>(), - 4usize, - concat!("Size of: ", stringify!(__x86_pagein_state)) - ); - assert_eq!( - ::std::mem::align_of::<__x86_pagein_state>(), - 4usize, - concat!("Alignment of ", stringify!(__x86_pagein_state)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__x86_pagein_state>())).__pagein_error as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__x86_pagein_state), - "::", - stringify!(__pagein_error) - ) - ); +extern "C" { + pub fn strlen(__s: *const ::std::os::raw::c_char) -> ::std::os::raw::c_ulong; } -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_x86_thread_state64 { - pub __rax: __uint64_t, - pub __rbx: __uint64_t, - pub __rcx: __uint64_t, - pub __rdx: __uint64_t, - pub __rdi: __uint64_t, - pub __rsi: __uint64_t, - pub __rbp: __uint64_t, - pub __rsp: __uint64_t, - pub __r8: __uint64_t, - pub __r9: __uint64_t, - pub __r10: __uint64_t, - pub __r11: __uint64_t, - pub __r12: __uint64_t, - pub __r13: __uint64_t, - pub __r14: __uint64_t, - pub __r15: __uint64_t, - pub __rip: __uint64_t, - pub __rflags: __uint64_t, - pub __cs: __uint64_t, - pub __fs: __uint64_t, - pub __gs: __uint64_t, +extern "C" { + pub fn strnlen(__string: *const ::std::os::raw::c_char, __maxlen: usize) -> usize; } -#[test] -fn bindgen_test_layout___darwin_x86_thread_state64() { - assert_eq!( - ::std::mem::size_of::<__darwin_x86_thread_state64>(), - 168usize, - concat!("Size of: ", stringify!(__darwin_x86_thread_state64)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_x86_thread_state64>(), - 8usize, - concat!("Alignment of ", stringify!(__darwin_x86_thread_state64)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__rax as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__rax) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__rbx as *const _ as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__rbx) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__rcx as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__rcx) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__rdx as *const _ as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__rdx) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__rdi as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__rdi) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__rsi as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__rsi) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__rbp as *const _ as usize - }, - 48usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__rbp) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__rsp as *const _ as usize - }, - 56usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__rsp) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__r8 as *const _ as usize - }, - 64usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__r8) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__r9 as *const _ as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__r9) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__r10 as *const _ as usize - }, - 80usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__r10) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__r11 as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__r11) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__r12 as *const _ as usize - }, - 96usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__r12) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__r13 as *const _ as usize - }, - 104usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__r13) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__r14 as *const _ as usize - }, - 112usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__r14) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__r15 as *const _ as usize - }, - 120usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__r15) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__rip as *const _ as usize - }, - 128usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__rip) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__rflags as *const _ as usize - }, - 136usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__rflags) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__cs as *const _ as usize - }, - 144usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__cs) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__fs as *const _ as usize - }, - 152usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__fs) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_state64>())).__gs as *const _ as usize - }, - 160usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_state64), - "::", - stringify!(__gs) - ) - ); +extern "C" { + pub fn strerror(__errnum: ::std::os::raw::c_int) -> *mut ::std::os::raw::c_char; } -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_x86_thread_full_state64 { - pub __ss64: __darwin_x86_thread_state64, - pub __ds: __uint64_t, - pub __es: __uint64_t, - pub __ss: __uint64_t, - pub __gsbase: __uint64_t, +extern "C" { + #[link_name = "\u{1}___xpg_strerror_r"] + pub fn strerror_r( + __errnum: ::std::os::raw::c_int, + __buf: *mut ::std::os::raw::c_char, + __buflen: usize, + ) -> ::std::os::raw::c_int; } -#[test] -fn bindgen_test_layout___darwin_x86_thread_full_state64() { - assert_eq!( - ::std::mem::size_of::<__darwin_x86_thread_full_state64>(), - 200usize, - concat!("Size of: ", stringify!(__darwin_x86_thread_full_state64)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_x86_thread_full_state64>(), - 8usize, - concat!( - "Alignment of ", - stringify!(__darwin_x86_thread_full_state64) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_full_state64>())).__ss64 as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_full_state64), - "::", - stringify!(__ss64) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_full_state64>())).__ds as *const _ as usize - }, - 168usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_full_state64), - "::", - stringify!(__ds) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_full_state64>())).__es as *const _ as usize - }, - 176usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_full_state64), - "::", - stringify!(__es) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_full_state64>())).__ss as *const _ as usize - }, - 184usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_full_state64), - "::", - stringify!(__ss) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_thread_full_state64>())).__gsbase as *const _ - as usize - }, - 192usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_thread_full_state64), - "::", - stringify!(__gsbase) - ) - ); +extern "C" { + pub fn strerror_l( + __errnum: ::std::os::raw::c_int, + __l: locale_t, + ) -> *mut ::std::os::raw::c_char; } -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_x86_float_state64 { - pub __fpu_reserved: [::std::os::raw::c_int; 2usize], - pub __fpu_fcw: __darwin_fp_control, - pub __fpu_fsw: __darwin_fp_status, - pub __fpu_ftw: __uint8_t, - pub __fpu_rsrv1: __uint8_t, - pub __fpu_fop: __uint16_t, - pub __fpu_ip: __uint32_t, - pub __fpu_cs: __uint16_t, - pub __fpu_rsrv2: __uint16_t, - pub __fpu_dp: __uint32_t, - pub __fpu_ds: __uint16_t, - pub __fpu_rsrv3: __uint16_t, - pub __fpu_mxcsr: __uint32_t, - pub __fpu_mxcsrmask: __uint32_t, - pub __fpu_stmm0: __darwin_mmst_reg, - pub __fpu_stmm1: __darwin_mmst_reg, - pub __fpu_stmm2: __darwin_mmst_reg, - pub __fpu_stmm3: __darwin_mmst_reg, - pub __fpu_stmm4: __darwin_mmst_reg, - pub __fpu_stmm5: __darwin_mmst_reg, - pub __fpu_stmm6: __darwin_mmst_reg, - pub __fpu_stmm7: __darwin_mmst_reg, - pub __fpu_xmm0: __darwin_xmm_reg, - pub __fpu_xmm1: __darwin_xmm_reg, - pub __fpu_xmm2: __darwin_xmm_reg, - pub __fpu_xmm3: __darwin_xmm_reg, - pub __fpu_xmm4: __darwin_xmm_reg, - pub __fpu_xmm5: __darwin_xmm_reg, - pub __fpu_xmm6: __darwin_xmm_reg, - pub __fpu_xmm7: __darwin_xmm_reg, - pub __fpu_xmm8: __darwin_xmm_reg, - pub __fpu_xmm9: __darwin_xmm_reg, - pub __fpu_xmm10: __darwin_xmm_reg, - pub __fpu_xmm11: __darwin_xmm_reg, - pub __fpu_xmm12: __darwin_xmm_reg, - pub __fpu_xmm13: __darwin_xmm_reg, - pub __fpu_xmm14: __darwin_xmm_reg, - pub __fpu_xmm15: __darwin_xmm_reg, - pub __fpu_rsrv4: [::std::os::raw::c_char; 96usize], - pub __fpu_reserved1: ::std::os::raw::c_int, +extern "C" { + pub fn bcmp( + __s1: *const ::std::os::raw::c_void, + __s2: *const ::std::os::raw::c_void, + __n: ::std::os::raw::c_ulong, + ) -> ::std::os::raw::c_int; } -#[test] -fn bindgen_test_layout___darwin_x86_float_state64() { - assert_eq!( - ::std::mem::size_of::<__darwin_x86_float_state64>(), - 524usize, - concat!("Size of: ", stringify!(__darwin_x86_float_state64)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_x86_float_state64>(), - 4usize, - concat!("Alignment of ", stringify!(__darwin_x86_float_state64)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_reserved as *const _ - as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_reserved) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_fcw as *const _ as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_fcw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_fsw as *const _ as usize - }, - 10usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_fsw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_ftw as *const _ as usize - }, - 12usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_ftw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_rsrv1 as *const _ as usize - }, - 13usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_rsrv1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_fop as *const _ as usize - }, - 14usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_fop) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_ip as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_ip) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_cs as *const _ as usize - }, - 20usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_cs) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_rsrv2 as *const _ as usize - }, - 22usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_rsrv2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_dp as *const _ as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_dp) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_ds as *const _ as usize - }, - 28usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_ds) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_rsrv3 as *const _ as usize - }, - 30usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_rsrv3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_mxcsr as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_mxcsr) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_mxcsrmask as *const _ - as usize - }, - 36usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_mxcsrmask) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_stmm0 as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_stmm0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_stmm1 as *const _ as usize - }, - 56usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_stmm1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_stmm2 as *const _ as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_stmm2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_stmm3 as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_stmm3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_stmm4 as *const _ as usize - }, - 104usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_stmm4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_stmm5 as *const _ as usize - }, - 120usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_stmm5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_stmm6 as *const _ as usize - }, - 136usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_stmm6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_stmm7 as *const _ as usize - }, - 152usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_stmm7) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_xmm0 as *const _ as usize - }, - 168usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_xmm0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_xmm1 as *const _ as usize - }, - 184usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_xmm1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_xmm2 as *const _ as usize - }, - 200usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_xmm2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_xmm3 as *const _ as usize - }, - 216usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_xmm3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_xmm4 as *const _ as usize - }, - 232usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_xmm4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_xmm5 as *const _ as usize - }, - 248usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_xmm5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_xmm6 as *const _ as usize - }, - 264usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_xmm6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_xmm7 as *const _ as usize - }, - 280usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_xmm7) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_xmm8 as *const _ as usize - }, - 296usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_xmm8) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_xmm9 as *const _ as usize - }, - 312usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_xmm9) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_xmm10 as *const _ as usize - }, - 328usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_xmm10) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_xmm11 as *const _ as usize - }, - 344usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_xmm11) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_xmm12 as *const _ as usize - }, - 360usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_xmm12) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_xmm13 as *const _ as usize - }, - 376usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_xmm13) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_xmm14 as *const _ as usize - }, - 392usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_xmm14) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_xmm15 as *const _ as usize - }, - 408usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_xmm15) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_rsrv4 as *const _ as usize - }, - 424usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_rsrv4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_float_state64>())).__fpu_reserved1 as *const _ - as usize - }, - 520usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_float_state64), - "::", - stringify!(__fpu_reserved1) - ) +extern "C" { + pub fn bcopy( + __src: *const ::std::os::raw::c_void, + __dest: *mut ::std::os::raw::c_void, + __n: usize, ); } -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_x86_avx_state64 { - pub __fpu_reserved: [::std::os::raw::c_int; 2usize], - pub __fpu_fcw: __darwin_fp_control, - pub __fpu_fsw: __darwin_fp_status, - pub __fpu_ftw: __uint8_t, - pub __fpu_rsrv1: __uint8_t, - pub __fpu_fop: __uint16_t, - pub __fpu_ip: __uint32_t, - pub __fpu_cs: __uint16_t, - pub __fpu_rsrv2: __uint16_t, - pub __fpu_dp: __uint32_t, - pub __fpu_ds: __uint16_t, - pub __fpu_rsrv3: __uint16_t, - pub __fpu_mxcsr: __uint32_t, - pub __fpu_mxcsrmask: __uint32_t, - pub __fpu_stmm0: __darwin_mmst_reg, - pub __fpu_stmm1: __darwin_mmst_reg, - pub __fpu_stmm2: __darwin_mmst_reg, - pub __fpu_stmm3: __darwin_mmst_reg, - pub __fpu_stmm4: __darwin_mmst_reg, - pub __fpu_stmm5: __darwin_mmst_reg, - pub __fpu_stmm6: __darwin_mmst_reg, - pub __fpu_stmm7: __darwin_mmst_reg, - pub __fpu_xmm0: __darwin_xmm_reg, - pub __fpu_xmm1: __darwin_xmm_reg, - pub __fpu_xmm2: __darwin_xmm_reg, - pub __fpu_xmm3: __darwin_xmm_reg, - pub __fpu_xmm4: __darwin_xmm_reg, - pub __fpu_xmm5: __darwin_xmm_reg, - pub __fpu_xmm6: __darwin_xmm_reg, - pub __fpu_xmm7: __darwin_xmm_reg, - pub __fpu_xmm8: __darwin_xmm_reg, - pub __fpu_xmm9: __darwin_xmm_reg, - pub __fpu_xmm10: __darwin_xmm_reg, - pub __fpu_xmm11: __darwin_xmm_reg, - pub __fpu_xmm12: __darwin_xmm_reg, - pub __fpu_xmm13: __darwin_xmm_reg, - pub __fpu_xmm14: __darwin_xmm_reg, - pub __fpu_xmm15: __darwin_xmm_reg, - pub __fpu_rsrv4: [::std::os::raw::c_char; 96usize], - pub __fpu_reserved1: ::std::os::raw::c_int, - pub __avx_reserved1: [::std::os::raw::c_char; 64usize], - pub __fpu_ymmh0: __darwin_xmm_reg, - pub __fpu_ymmh1: __darwin_xmm_reg, - pub __fpu_ymmh2: __darwin_xmm_reg, - pub __fpu_ymmh3: __darwin_xmm_reg, - pub __fpu_ymmh4: __darwin_xmm_reg, - pub __fpu_ymmh5: __darwin_xmm_reg, - pub __fpu_ymmh6: __darwin_xmm_reg, - pub __fpu_ymmh7: __darwin_xmm_reg, - pub __fpu_ymmh8: __darwin_xmm_reg, - pub __fpu_ymmh9: __darwin_xmm_reg, - pub __fpu_ymmh10: __darwin_xmm_reg, - pub __fpu_ymmh11: __darwin_xmm_reg, - pub __fpu_ymmh12: __darwin_xmm_reg, - pub __fpu_ymmh13: __darwin_xmm_reg, - pub __fpu_ymmh14: __darwin_xmm_reg, - pub __fpu_ymmh15: __darwin_xmm_reg, +extern "C" { + pub fn bzero(__s: *mut ::std::os::raw::c_void, __n: ::std::os::raw::c_ulong); } -#[test] -fn bindgen_test_layout___darwin_x86_avx_state64() { - assert_eq!( - ::std::mem::size_of::<__darwin_x86_avx_state64>(), - 844usize, - concat!("Size of: ", stringify!(__darwin_x86_avx_state64)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_x86_avx_state64>(), - 4usize, - concat!("Alignment of ", stringify!(__darwin_x86_avx_state64)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_reserved as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_reserved) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_fcw as *const _ as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_fcw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_fsw as *const _ as usize - }, - 10usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_fsw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ftw as *const _ as usize - }, - 12usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ftw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_rsrv1 as *const _ as usize - }, - 13usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_rsrv1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_fop as *const _ as usize - }, - 14usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_fop) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ip as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ip) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_cs as *const _ as usize - }, - 20usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_cs) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_rsrv2 as *const _ as usize - }, - 22usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_rsrv2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_dp as *const _ as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_dp) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ds as *const _ as usize - }, - 28usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ds) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_rsrv3 as *const _ as usize - }, - 30usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_rsrv3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_mxcsr as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_mxcsr) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_mxcsrmask as *const _ - as usize - }, - 36usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_mxcsrmask) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_stmm0 as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_stmm0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_stmm1 as *const _ as usize - }, - 56usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_stmm1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_stmm2 as *const _ as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_stmm2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_stmm3 as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_stmm3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_stmm4 as *const _ as usize - }, - 104usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_stmm4) - ) - ); +extern "C" { + pub fn index( + __s: *const ::std::os::raw::c_char, + __c: ::std::os::raw::c_int, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn rindex( + __s: *const ::std::os::raw::c_char, + __c: ::std::os::raw::c_int, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn ffs(__i: ::std::os::raw::c_int) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn ffsl(__l: ::std::os::raw::c_long) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn ffsll(__ll: ::std::os::raw::c_longlong) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn strcasecmp( + __s1: *const ::std::os::raw::c_char, + __s2: *const ::std::os::raw::c_char, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn strncasecmp( + __s1: *const ::std::os::raw::c_char, + __s2: *const ::std::os::raw::c_char, + __n: ::std::os::raw::c_ulong, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn strcasecmp_l( + __s1: *const ::std::os::raw::c_char, + __s2: *const ::std::os::raw::c_char, + __loc: locale_t, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn strncasecmp_l( + __s1: *const ::std::os::raw::c_char, + __s2: *const ::std::os::raw::c_char, + __n: usize, + __loc: locale_t, + ) -> ::std::os::raw::c_int; +} +extern "C" { + pub fn explicit_bzero(__s: *mut ::std::os::raw::c_void, __n: usize); +} +extern "C" { + pub fn strsep( + __stringp: *mut *mut ::std::os::raw::c_char, + __delim: *const ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn strsignal(__sig: ::std::os::raw::c_int) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn __stpcpy( + __dest: *mut ::std::os::raw::c_char, + __src: *const ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn stpcpy( + __dest: *mut ::std::os::raw::c_char, + __src: *const ::std::os::raw::c_char, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn __stpncpy( + __dest: *mut ::std::os::raw::c_char, + __src: *const ::std::os::raw::c_char, + __n: usize, + ) -> *mut ::std::os::raw::c_char; +} +extern "C" { + pub fn stpncpy( + __dest: *mut ::std::os::raw::c_char, + __src: *const ::std::os::raw::c_char, + __n: ::std::os::raw::c_ulong, + ) -> *mut ::std::os::raw::c_char; +} +#[repr(u32)] +#[doc = " Copied from TensorProto::DataType"] +#[doc = " Currently, Ort doesn't support complex64, complex128"] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum ONNXTensorElementDataType { + ONNX_TENSOR_ELEMENT_DATA_TYPE_UNDEFINED = 0, + ONNX_TENSOR_ELEMENT_DATA_TYPE_FLOAT = 1, + ONNX_TENSOR_ELEMENT_DATA_TYPE_UINT8 = 2, + ONNX_TENSOR_ELEMENT_DATA_TYPE_INT8 = 3, + ONNX_TENSOR_ELEMENT_DATA_TYPE_UINT16 = 4, + ONNX_TENSOR_ELEMENT_DATA_TYPE_INT16 = 5, + ONNX_TENSOR_ELEMENT_DATA_TYPE_INT32 = 6, + ONNX_TENSOR_ELEMENT_DATA_TYPE_INT64 = 7, + ONNX_TENSOR_ELEMENT_DATA_TYPE_STRING = 8, + ONNX_TENSOR_ELEMENT_DATA_TYPE_BOOL = 9, + ONNX_TENSOR_ELEMENT_DATA_TYPE_FLOAT16 = 10, + ONNX_TENSOR_ELEMENT_DATA_TYPE_DOUBLE = 11, + ONNX_TENSOR_ELEMENT_DATA_TYPE_UINT32 = 12, + ONNX_TENSOR_ELEMENT_DATA_TYPE_UINT64 = 13, + ONNX_TENSOR_ELEMENT_DATA_TYPE_COMPLEX64 = 14, + ONNX_TENSOR_ELEMENT_DATA_TYPE_COMPLEX128 = 15, + ONNX_TENSOR_ELEMENT_DATA_TYPE_BFLOAT16 = 16, +} +#[repr(u32)] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum ONNXType { + ONNX_TYPE_UNKNOWN = 0, + ONNX_TYPE_TENSOR = 1, + ONNX_TYPE_SEQUENCE = 2, + ONNX_TYPE_MAP = 3, + ONNX_TYPE_OPAQUE = 4, + ONNX_TYPE_SPARSETENSOR = 5, + ONNX_TYPE_OPTIONAL = 6, +} +#[repr(u32)] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum OrtSparseFormat { + ORT_SPARSE_UNDEFINED = 0, + ORT_SPARSE_COO = 1, + ORT_SPARSE_CSRC = 2, + ORT_SPARSE_BLOCK_SPARSE = 4, +} +#[repr(u32)] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum OrtSparseIndicesFormat { + ORT_SPARSE_COO_INDICES = 0, + ORT_SPARSE_CSR_INNER_INDICES = 1, + ORT_SPARSE_CSR_OUTER_INDICES = 2, + ORT_SPARSE_BLOCK_SPARSE_INDICES = 3, +} +#[repr(u32)] +#[doc = " \\brief Logging severity levels"] +#[doc = ""] +#[doc = " In typical API usage, specifying a logging severity level specifies the minimum severity of log messages to show."] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum OrtLoggingLevel { + #[doc = "< Verbose informational messages (least severe)."] + ORT_LOGGING_LEVEL_VERBOSE = 0, + #[doc = "< Informational messages."] + ORT_LOGGING_LEVEL_INFO = 1, + #[doc = "< Warning messages."] + ORT_LOGGING_LEVEL_WARNING = 2, + #[doc = "< Error messages."] + ORT_LOGGING_LEVEL_ERROR = 3, + #[doc = "< Fatal error messages (most severe)."] + ORT_LOGGING_LEVEL_FATAL = 4, +} +#[repr(u32)] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum OrtErrorCode { + ORT_OK = 0, + ORT_FAIL = 1, + ORT_INVALID_ARGUMENT = 2, + ORT_NO_SUCHFILE = 3, + ORT_NO_MODEL = 4, + ORT_ENGINE_ERROR = 5, + ORT_RUNTIME_EXCEPTION = 6, + ORT_INVALID_PROTOBUF = 7, + ORT_MODEL_LOADED = 8, + ORT_NOT_IMPLEMENTED = 9, + ORT_INVALID_GRAPH = 10, + ORT_EP_FAIL = 11, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtEnv { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtStatus { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtMemoryInfo { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtIoBinding { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtSession { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtValue { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtRunOptions { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtTypeInfo { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtTensorTypeAndShapeInfo { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtSessionOptions { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtCustomOpDomain { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtMapTypeInfo { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtSequenceTypeInfo { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtModelMetadata { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtThreadPoolParams { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtThreadingOptions { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtArenaCfg { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtPrepackedWeightsContainer { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtTensorRTProviderOptionsV2 { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtCUDAProviderOptionsV2 { + _unused: [u8; 0], +} +pub type OrtStatusPtr = *mut OrtStatus; +#[doc = " \\brief Memory allocation interface"] +#[doc = ""] +#[doc = " Structure of function pointers that defines a memory allocator. This can be created and filled in by the user for custom allocators."] +#[doc = ""] +#[doc = " When an allocator is passed to any function, be sure that the allocator object is not destroyed until the last allocated object using it is freed."] +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtAllocator { + #[doc = "< Must be initialized to ORT_API_VERSION"] + pub version: u32, + #[doc = "< Returns a pointer to an allocated block of `size` bytes"] + pub Alloc: ::std::option::Option< + unsafe extern "C" fn(this_: *mut OrtAllocator, size: usize) -> *mut ::std::os::raw::c_void, + >, + #[doc = "< Free a block of memory previously allocated with OrtAllocator::Alloc"] + pub Free: ::std::option::Option< + unsafe extern "C" fn(this_: *mut OrtAllocator, p: *mut ::std::os::raw::c_void), + >, + #[doc = "< Return a pointer to an ::OrtMemoryInfo that describes this allocator"] + pub Info: ::std::option::Option< + unsafe extern "C" fn(this_: *const OrtAllocator) -> *const OrtMemoryInfo, + >, +} +#[test] +fn bindgen_test_layout_OrtAllocator() { assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_stmm5 as *const _ as usize - }, - 120usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_stmm5) - ) + ::std::mem::size_of::(), + 32usize, + concat!("Size of: ", stringify!(OrtAllocator)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_stmm6 as *const _ as usize - }, - 136usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_stmm6) - ) + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(OrtAllocator)) ); + fn test_field_version() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).version) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtAllocator), + "::", + stringify!(version) + ) + ); + } + test_field_version(); + fn test_field_Alloc() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).Alloc) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtAllocator), + "::", + stringify!(Alloc) + ) + ); + } + test_field_Alloc(); + fn test_field_Free() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).Free) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(OrtAllocator), + "::", + stringify!(Free) + ) + ); + } + test_field_Free(); + fn test_field_Info() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).Info) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(OrtAllocator), + "::", + stringify!(Info) + ) + ); + } + test_field_Info(); +} +pub type OrtLoggingFunction = ::std::option::Option< + unsafe extern "C" fn( + param: *mut ::std::os::raw::c_void, + severity: OrtLoggingLevel, + category: *const ::std::os::raw::c_char, + logid: *const ::std::os::raw::c_char, + code_location: *const ::std::os::raw::c_char, + message: *const ::std::os::raw::c_char, + ), +>; +#[repr(u32)] +#[doc = " \\brief Graph optimization level"] +#[doc = ""] +#[doc = " Refer to https://www.onnxruntime.ai/docs/resources/graph-optimizations.html"] +#[doc = " for an in-depth understanding of Graph Optimizations"] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum GraphOptimizationLevel { + ORT_DISABLE_ALL = 0, + ORT_ENABLE_BASIC = 1, + ORT_ENABLE_EXTENDED = 2, + ORT_ENABLE_ALL = 99, +} +#[repr(u32)] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum ExecutionMode { + ORT_SEQUENTIAL = 0, + ORT_PARALLEL = 1, +} +#[repr(u32)] +#[doc = " \\brief Language projection identifiers"] +#[doc = " /see OrtApi::SetLanguageProjection"] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum OrtLanguageProjection { + ORT_PROJECTION_C = 0, + ORT_PROJECTION_CPLUSPLUS = 1, + ORT_PROJECTION_CSHARP = 2, + ORT_PROJECTION_PYTHON = 3, + ORT_PROJECTION_JAVA = 4, + ORT_PROJECTION_WINML = 5, + ORT_PROJECTION_NODEJS = 6, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtKernelInfo { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtKernelContext { + _unused: [u8; 0], +} +#[repr(i32)] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum OrtAllocatorType { + OrtInvalidAllocator = -1, + OrtDeviceAllocator = 0, + OrtArenaAllocator = 1, +} +impl OrtMemType { + pub const OrtMemTypeCPU: OrtMemType = OrtMemType::OrtMemTypeCPUOutput; +} +#[repr(i32)] +#[doc = " \\brief Memory types for allocated memory, execution provider specific types should be extended in each provider."] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum OrtMemType { + #[doc = "< Any CPU memory used by non-CPU execution provider"] + OrtMemTypeCPUInput = -2, + #[doc = "< CPU accessible memory outputted by non-CPU execution provider, i.e. CUDA_PINNED"] + OrtMemTypeCPUOutput = -1, + #[doc = "< The default allocator for execution provider"] + OrtMemTypeDefault = 0, +} +#[repr(u32)] +#[doc = " \\brief Algorithm to use for cuDNN Convolution Op"] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum OrtCudnnConvAlgoSearch { + OrtCudnnConvAlgoSearchExhaustive = 0, + OrtCudnnConvAlgoSearchHeuristic = 1, + OrtCudnnConvAlgoSearchDefault = 2, +} +#[doc = " \\brief CUDA Provider Options"] +#[doc = ""] +#[doc = " \\see OrtApi::SessionOptionsAppendExecutionProvider_CUDA"] +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtCUDAProviderOptions { + #[doc = " \\brief CUDA device Id"] + #[doc = " Defaults to 0."] + pub device_id: ::std::os::raw::c_int, + #[doc = " \\brief CUDA Convolution algorithm search configuration."] + #[doc = " See enum OrtCudnnConvAlgoSearch for more details."] + #[doc = " Defaults to OrtCudnnConvAlgoSearchExhaustive."] + pub cudnn_conv_algo_search: OrtCudnnConvAlgoSearch, + #[doc = " \\brief CUDA memory limit (To use all possible memory pass in maximum size_t)"] + #[doc = " Defaults to SIZE_MAX."] + #[doc = " \\note If a ::OrtArenaCfg has been applied, it will override this field"] + pub gpu_mem_limit: usize, + #[doc = " \\brief Strategy used to grow the memory arena"] + #[doc = " 0 = kNextPowerOfTwo
"] + #[doc = " 1 = kSameAsRequested
"] + #[doc = " Defaults to 0."] + #[doc = " \\note If a ::OrtArenaCfg has been applied, it will override this field"] + pub arena_extend_strategy: ::std::os::raw::c_int, + #[doc = " \\brief Flag indicating if copying needs to take place on the same stream as the compute stream in the CUDA EP"] + #[doc = " 0 = Use separate streams for copying and compute."] + #[doc = " 1 = Use the same stream for copying and compute."] + #[doc = " Defaults to 1."] + #[doc = " WARNING: Setting this to 0 may result in data races for some models."] + #[doc = " Please see issue #4829 for more details."] + pub do_copy_in_default_stream: ::std::os::raw::c_int, + #[doc = " \\brief Flag indicating if there is a user provided compute stream"] + #[doc = " Defaults to 0."] + pub has_user_compute_stream: ::std::os::raw::c_int, + #[doc = " \\brief User provided compute stream."] + #[doc = " If provided, please set `has_user_compute_stream` to 1."] + pub user_compute_stream: *mut ::std::os::raw::c_void, + #[doc = " \\brief CUDA memory arena configuration parameters"] + pub default_memory_arena_cfg: *mut OrtArenaCfg, +} +#[test] +fn bindgen_test_layout_OrtCUDAProviderOptions() { assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_stmm7 as *const _ as usize - }, - 152usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_stmm7) - ) + ::std::mem::size_of::(), + 48usize, + concat!("Size of: ", stringify!(OrtCUDAProviderOptions)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_xmm0 as *const _ as usize - }, - 168usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_xmm0) - ) + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(OrtCUDAProviderOptions)) ); + fn test_field_device_id() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).device_id) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(device_id) + ) + ); + } + test_field_device_id(); + fn test_field_cudnn_conv_algo_search() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).cudnn_conv_algo_search) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(cudnn_conv_algo_search) + ) + ); + } + test_field_cudnn_conv_algo_search(); + fn test_field_gpu_mem_limit() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).gpu_mem_limit) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(gpu_mem_limit) + ) + ); + } + test_field_gpu_mem_limit(); + fn test_field_arena_extend_strategy() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).arena_extend_strategy) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(arena_extend_strategy) + ) + ); + } + test_field_arena_extend_strategy(); + fn test_field_do_copy_in_default_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).do_copy_in_default_stream) as usize - ptr as usize + }, + 20usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(do_copy_in_default_stream) + ) + ); + } + test_field_do_copy_in_default_stream(); + fn test_field_has_user_compute_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).has_user_compute_stream) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(has_user_compute_stream) + ) + ); + } + test_field_has_user_compute_stream(); + fn test_field_user_compute_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).user_compute_stream) as usize - ptr as usize + }, + 32usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(user_compute_stream) + ) + ); + } + test_field_user_compute_stream(); + fn test_field_default_memory_arena_cfg() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).default_memory_arena_cfg) as usize - ptr as usize + }, + 40usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(default_memory_arena_cfg) + ) + ); + } + test_field_default_memory_arena_cfg(); +} +#[doc = " \\brief ROCM Provider Options"] +#[doc = ""] +#[doc = " \\see OrtApi::SessionOptionsAppendExecutionProvider_ROCM"] +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtROCMProviderOptions { + #[doc = " \\brief ROCM device Id"] + #[doc = " Defaults to 0."] + pub device_id: ::std::os::raw::c_int, + #[doc = " \\brief ROCM MIOpen Convolution algorithm exaustive search option."] + #[doc = " Defaults to 0 (false)."] + pub miopen_conv_exhaustive_search: ::std::os::raw::c_int, + #[doc = " \\brief ROCM memory limit (To use all possible memory pass in maximum size_t)"] + #[doc = " Defaults to SIZE_MAX."] + #[doc = " \\note If a ::OrtArenaCfg has been applied, it will override this field"] + pub gpu_mem_limit: usize, + #[doc = " \\brief Strategy used to grow the memory arena"] + #[doc = " 0 = kNextPowerOfTwo
"] + #[doc = " 1 = kSameAsRequested
"] + #[doc = " Defaults to 0."] + #[doc = " \\note If a ::OrtArenaCfg has been applied, it will override this field"] + pub arena_extend_strategy: ::std::os::raw::c_int, + #[doc = " \\brief Flag indicating if copying needs to take place on the same stream as the compute stream in the ROCM EP"] + #[doc = " 0 = Use separate streams for copying and compute."] + #[doc = " 1 = Use the same stream for copying and compute."] + #[doc = " Defaults to 1."] + #[doc = " WARNING: Setting this to 0 may result in data races for some models."] + #[doc = " Please see issue #4829 for more details."] + pub do_copy_in_default_stream: ::std::os::raw::c_int, + #[doc = " \\brief Flag indicating if there is a user provided compute stream"] + #[doc = " Defaults to 0."] + pub has_user_compute_stream: ::std::os::raw::c_int, + #[doc = " \\brief User provided compute stream."] + #[doc = " If provided, please set `has_user_compute_stream` to 1."] + pub user_compute_stream: *mut ::std::os::raw::c_void, + #[doc = " \\brief ROCM memory arena configuration parameters"] + pub default_memory_arena_cfg: *mut OrtArenaCfg, +} +#[test] +fn bindgen_test_layout_OrtROCMProviderOptions() { assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_xmm1 as *const _ as usize - }, - 184usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_xmm1) - ) + ::std::mem::size_of::(), + 48usize, + concat!("Size of: ", stringify!(OrtROCMProviderOptions)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_xmm2 as *const _ as usize - }, - 200usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_xmm2) - ) + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(OrtROCMProviderOptions)) ); + fn test_field_device_id() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).device_id) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(device_id) + ) + ); + } + test_field_device_id(); + fn test_field_miopen_conv_exhaustive_search() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).miopen_conv_exhaustive_search) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(miopen_conv_exhaustive_search) + ) + ); + } + test_field_miopen_conv_exhaustive_search(); + fn test_field_gpu_mem_limit() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).gpu_mem_limit) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(gpu_mem_limit) + ) + ); + } + test_field_gpu_mem_limit(); + fn test_field_arena_extend_strategy() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).arena_extend_strategy) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(arena_extend_strategy) + ) + ); + } + test_field_arena_extend_strategy(); + fn test_field_do_copy_in_default_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).do_copy_in_default_stream) as usize - ptr as usize + }, + 20usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(do_copy_in_default_stream) + ) + ); + } + test_field_do_copy_in_default_stream(); + fn test_field_has_user_compute_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).has_user_compute_stream) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(has_user_compute_stream) + ) + ); + } + test_field_has_user_compute_stream(); + fn test_field_user_compute_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).user_compute_stream) as usize - ptr as usize + }, + 32usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(user_compute_stream) + ) + ); + } + test_field_user_compute_stream(); + fn test_field_default_memory_arena_cfg() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).default_memory_arena_cfg) as usize - ptr as usize + }, + 40usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(default_memory_arena_cfg) + ) + ); + } + test_field_default_memory_arena_cfg(); +} +#[doc = " \\brief TensorRT Provider Options"] +#[doc = ""] +#[doc = " \\see OrtApi::SessionOptionsAppendExecutionProvider_TensorRT"] +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtTensorRTProviderOptions { + #[doc = "< CUDA device id (0 = default device)"] + pub device_id: ::std::os::raw::c_int, + pub has_user_compute_stream: ::std::os::raw::c_int, + pub user_compute_stream: *mut ::std::os::raw::c_void, + pub trt_max_partition_iterations: ::std::os::raw::c_int, + pub trt_min_subgraph_size: ::std::os::raw::c_int, + pub trt_max_workspace_size: usize, + pub trt_fp16_enable: ::std::os::raw::c_int, + pub trt_int8_enable: ::std::os::raw::c_int, + pub trt_int8_calibration_table_name: *const ::std::os::raw::c_char, + pub trt_int8_use_native_calibration_table: ::std::os::raw::c_int, + pub trt_dla_enable: ::std::os::raw::c_int, + pub trt_dla_core: ::std::os::raw::c_int, + pub trt_dump_subgraphs: ::std::os::raw::c_int, + pub trt_engine_cache_enable: ::std::os::raw::c_int, + pub trt_engine_cache_path: *const ::std::os::raw::c_char, + pub trt_engine_decryption_enable: ::std::os::raw::c_int, + pub trt_engine_decryption_lib_path: *const ::std::os::raw::c_char, + pub trt_force_sequential_engine_build: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_OrtTensorRTProviderOptions() { assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_xmm3 as *const _ as usize - }, - 216usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_xmm3) - ) + ::std::mem::size_of::(), + 104usize, + concat!("Size of: ", stringify!(OrtTensorRTProviderOptions)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_xmm4 as *const _ as usize - }, - 232usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_xmm4) - ) + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(OrtTensorRTProviderOptions)) ); + fn test_field_device_id() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).device_id) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(device_id) + ) + ); + } + test_field_device_id(); + fn test_field_has_user_compute_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).has_user_compute_stream) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(has_user_compute_stream) + ) + ); + } + test_field_has_user_compute_stream(); + fn test_field_user_compute_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).user_compute_stream) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(user_compute_stream) + ) + ); + } + test_field_user_compute_stream(); + fn test_field_trt_max_partition_iterations() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_max_partition_iterations) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_max_partition_iterations) + ) + ); + } + test_field_trt_max_partition_iterations(); + fn test_field_trt_min_subgraph_size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_min_subgraph_size) as usize - ptr as usize + }, + 20usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_min_subgraph_size) + ) + ); + } + test_field_trt_min_subgraph_size(); + fn test_field_trt_max_workspace_size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_max_workspace_size) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_max_workspace_size) + ) + ); + } + test_field_trt_max_workspace_size(); + fn test_field_trt_fp16_enable() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_fp16_enable) as usize - ptr as usize + }, + 32usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_fp16_enable) + ) + ); + } + test_field_trt_fp16_enable(); + fn test_field_trt_int8_enable() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_int8_enable) as usize - ptr as usize + }, + 36usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_int8_enable) + ) + ); + } + test_field_trt_int8_enable(); + fn test_field_trt_int8_calibration_table_name() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_int8_calibration_table_name) as usize - ptr as usize + }, + 40usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_int8_calibration_table_name) + ) + ); + } + test_field_trt_int8_calibration_table_name(); + fn test_field_trt_int8_use_native_calibration_table() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_int8_use_native_calibration_table) as usize + - ptr as usize + }, + 48usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_int8_use_native_calibration_table) + ) + ); + } + test_field_trt_int8_use_native_calibration_table(); + fn test_field_trt_dla_enable() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_dla_enable) as usize - ptr as usize + }, + 52usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_dla_enable) + ) + ); + } + test_field_trt_dla_enable(); + fn test_field_trt_dla_core() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_dla_core) as usize - ptr as usize + }, + 56usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_dla_core) + ) + ); + } + test_field_trt_dla_core(); + fn test_field_trt_dump_subgraphs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_dump_subgraphs) as usize - ptr as usize + }, + 60usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_dump_subgraphs) + ) + ); + } + test_field_trt_dump_subgraphs(); + fn test_field_trt_engine_cache_enable() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_engine_cache_enable) as usize - ptr as usize + }, + 64usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_engine_cache_enable) + ) + ); + } + test_field_trt_engine_cache_enable(); + fn test_field_trt_engine_cache_path() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_engine_cache_path) as usize - ptr as usize + }, + 72usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_engine_cache_path) + ) + ); + } + test_field_trt_engine_cache_path(); + fn test_field_trt_engine_decryption_enable() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_engine_decryption_enable) as usize - ptr as usize + }, + 80usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_engine_decryption_enable) + ) + ); + } + test_field_trt_engine_decryption_enable(); + fn test_field_trt_engine_decryption_lib_path() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_engine_decryption_lib_path) as usize - ptr as usize + }, + 88usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_engine_decryption_lib_path) + ) + ); + } + test_field_trt_engine_decryption_lib_path(); + fn test_field_trt_force_sequential_engine_build() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_force_sequential_engine_build) as usize + - ptr as usize + }, + 96usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_force_sequential_engine_build) + ) + ); + } + test_field_trt_force_sequential_engine_build(); +} +#[doc = " \\brief MIGraphX Provider Options"] +#[doc = ""] +#[doc = " \\see OrtApi::SessionOptionsAppendExecutionProvider_MIGraphX"] +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtMIGraphXProviderOptions { + pub device_id: ::std::os::raw::c_int, + pub migraphx_fp16_enable: ::std::os::raw::c_int, + pub migraphx_int8_enable: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_OrtMIGraphXProviderOptions() { assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_xmm5 as *const _ as usize - }, - 248usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_xmm5) - ) + ::std::mem::size_of::(), + 12usize, + concat!("Size of: ", stringify!(OrtMIGraphXProviderOptions)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_xmm6 as *const _ as usize - }, - 264usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_xmm6) - ) - ); + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(OrtMIGraphXProviderOptions)) + ); + fn test_field_device_id() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).device_id) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtMIGraphXProviderOptions), + "::", + stringify!(device_id) + ) + ); + } + test_field_device_id(); + fn test_field_migraphx_fp16_enable() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).migraphx_fp16_enable) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(OrtMIGraphXProviderOptions), + "::", + stringify!(migraphx_fp16_enable) + ) + ); + } + test_field_migraphx_fp16_enable(); + fn test_field_migraphx_int8_enable() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).migraphx_int8_enable) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtMIGraphXProviderOptions), + "::", + stringify!(migraphx_int8_enable) + ) + ); + } + test_field_migraphx_int8_enable(); +} +#[doc = " \\brief OpenVINO Provider Options"] +#[doc = ""] +#[doc = " \\see OrtApi::SessionOptionsAppendExecutionProvider_OpenVINO"] +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtOpenVINOProviderOptions { + #[doc = " \\brief Device type string"] + #[doc = ""] + #[doc = " Valid settings are one of: \"CPU_FP32\", \"GPU_FP32\", \"GPU_FP16\", \"MYRIAD_FP16\", \"VAD-M_FP16\" or \"VAD-F_FP32\""] + pub device_type: *const ::std::os::raw::c_char, + #[doc = "< 0 = disabled, nonzero = enabled"] + pub enable_vpu_fast_compile: ::std::os::raw::c_uchar, + pub device_id: *const ::std::os::raw::c_char, + #[doc = "< 0 = Use default number of threads"] + pub num_of_threads: usize, + #[doc = "< 0 = disabled, nonzero = enabled"] + pub use_compiled_network: ::std::os::raw::c_uchar, + pub blob_dump_path: *const ::std::os::raw::c_char, + pub context: *mut ::std::os::raw::c_void, +} +#[test] +fn bindgen_test_layout_OrtOpenVINOProviderOptions() { assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_xmm7 as *const _ as usize - }, - 280usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_xmm7) - ) + ::std::mem::size_of::(), + 56usize, + concat!("Size of: ", stringify!(OrtOpenVINOProviderOptions)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_xmm8 as *const _ as usize - }, - 296usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_xmm8) - ) + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(OrtOpenVINOProviderOptions)) ); + fn test_field_device_type() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).device_type) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtOpenVINOProviderOptions), + "::", + stringify!(device_type) + ) + ); + } + test_field_device_type(); + fn test_field_enable_vpu_fast_compile() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).enable_vpu_fast_compile) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtOpenVINOProviderOptions), + "::", + stringify!(enable_vpu_fast_compile) + ) + ); + } + test_field_enable_vpu_fast_compile(); + fn test_field_device_id() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).device_id) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(OrtOpenVINOProviderOptions), + "::", + stringify!(device_id) + ) + ); + } + test_field_device_id(); + fn test_field_num_of_threads() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).num_of_threads) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(OrtOpenVINOProviderOptions), + "::", + stringify!(num_of_threads) + ) + ); + } + test_field_num_of_threads(); + fn test_field_use_compiled_network() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).use_compiled_network) as usize - ptr as usize + }, + 32usize, + concat!( + "Offset of field: ", + stringify!(OrtOpenVINOProviderOptions), + "::", + stringify!(use_compiled_network) + ) + ); + } + test_field_use_compiled_network(); + fn test_field_blob_dump_path() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).blob_dump_path) as usize - ptr as usize + }, + 40usize, + concat!( + "Offset of field: ", + stringify!(OrtOpenVINOProviderOptions), + "::", + stringify!(blob_dump_path) + ) + ); + } + test_field_blob_dump_path(); + fn test_field_context() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).context) as usize - ptr as usize + }, + 48usize, + concat!( + "Offset of field: ", + stringify!(OrtOpenVINOProviderOptions), + "::", + stringify!(context) + ) + ); + } + test_field_context(); +} +#[doc = " \\brief The helper interface to get the right version of OrtApi"] +#[doc = ""] +#[doc = " Get a pointer to this structure through ::OrtGetApiBase"] +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtApiBase { + #[doc = " \\brief Get a pointer to the requested version of the ::OrtApi"] + #[doc = ""] + #[doc = " \\param[in] version Must be ::ORT_API_VERSION"] + #[doc = " \\return The ::OrtApi for the version requested, nullptr will be returned if this version is unsupported, for example when using a runtime"] + #[doc = " older than the version created with this header file."] + pub GetApi: ::std::option::Option *const OrtApi>, + #[doc = "< Returns a null terminated string of the version of the Onnxruntime library (eg: \"1.8.1\")"] + pub GetVersionString: + ::std::option::Option *const ::std::os::raw::c_char>, +} +#[test] +fn bindgen_test_layout_OrtApiBase() { assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_xmm9 as *const _ as usize - }, - 312usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_xmm9) - ) + ::std::mem::size_of::(), + 16usize, + concat!("Size of: ", stringify!(OrtApiBase)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_xmm10 as *const _ as usize - }, - 328usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_xmm10) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_xmm11 as *const _ as usize - }, - 344usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_xmm11) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_xmm12 as *const _ as usize - }, - 360usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_xmm12) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_xmm13 as *const _ as usize - }, - 376usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_xmm13) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_xmm14 as *const _ as usize - }, - 392usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_xmm14) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_xmm15 as *const _ as usize - }, - 408usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_xmm15) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_rsrv4 as *const _ as usize - }, - 424usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_rsrv4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_reserved1 as *const _ - as usize - }, - 520usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_reserved1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__avx_reserved1 as *const _ - as usize - }, - 524usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__avx_reserved1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ymmh0 as *const _ as usize - }, - 588usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ymmh0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ymmh1 as *const _ as usize - }, - 604usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ymmh1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ymmh2 as *const _ as usize - }, - 620usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ymmh2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ymmh3 as *const _ as usize - }, - 636usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ymmh3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ymmh4 as *const _ as usize - }, - 652usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ymmh4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ymmh5 as *const _ as usize - }, - 668usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ymmh5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ymmh6 as *const _ as usize - }, - 684usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ymmh6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ymmh7 as *const _ as usize - }, - 700usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ymmh7) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ymmh8 as *const _ as usize - }, - 716usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ymmh8) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ymmh9 as *const _ as usize - }, - 732usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ymmh9) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ymmh10 as *const _ as usize - }, - 748usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ymmh10) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ymmh11 as *const _ as usize - }, - 764usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ymmh11) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ymmh12 as *const _ as usize - }, - 780usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ymmh12) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ymmh13 as *const _ as usize - }, - 796usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ymmh13) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ymmh14 as *const _ as usize - }, - 812usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ymmh14) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx_state64>())).__fpu_ymmh15 as *const _ as usize - }, - 828usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx_state64), - "::", - stringify!(__fpu_ymmh15) - ) + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(OrtApiBase)) ); + fn test_field_GetApi() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetApi) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtApiBase), + "::", + stringify!(GetApi) + ) + ); + } + test_field_GetApi(); + fn test_field_GetVersionString() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetVersionString) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtApiBase), + "::", + stringify!(GetVersionString) + ) + ); + } + test_field_GetVersionString(); +} +extern "C" { + #[doc = " \\brief The Onnxruntime library's entry point to access the C API"] + #[doc = ""] + #[doc = " Call this to get the a pointer to an ::OrtApiBase"] + pub fn OrtGetApiBase() -> *const OrtApiBase; } +#[doc = " \\brief Thread work loop function"] +#[doc = ""] +#[doc = " Onnxruntime will provide the working loop on custom thread creation"] +#[doc = " Argument is an onnxruntime built-in type which will be provided when thread pool calls OrtCustomCreateThreadFn"] +pub type OrtThreadWorkerFn = + ::std::option::Option; #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct __darwin_x86_avx512_state64 { - pub __fpu_reserved: [::std::os::raw::c_int; 2usize], - pub __fpu_fcw: __darwin_fp_control, - pub __fpu_fsw: __darwin_fp_status, - pub __fpu_ftw: __uint8_t, - pub __fpu_rsrv1: __uint8_t, - pub __fpu_fop: __uint16_t, - pub __fpu_ip: __uint32_t, - pub __fpu_cs: __uint16_t, - pub __fpu_rsrv2: __uint16_t, - pub __fpu_dp: __uint32_t, - pub __fpu_ds: __uint16_t, - pub __fpu_rsrv3: __uint16_t, - pub __fpu_mxcsr: __uint32_t, - pub __fpu_mxcsrmask: __uint32_t, - pub __fpu_stmm0: __darwin_mmst_reg, - pub __fpu_stmm1: __darwin_mmst_reg, - pub __fpu_stmm2: __darwin_mmst_reg, - pub __fpu_stmm3: __darwin_mmst_reg, - pub __fpu_stmm4: __darwin_mmst_reg, - pub __fpu_stmm5: __darwin_mmst_reg, - pub __fpu_stmm6: __darwin_mmst_reg, - pub __fpu_stmm7: __darwin_mmst_reg, - pub __fpu_xmm0: __darwin_xmm_reg, - pub __fpu_xmm1: __darwin_xmm_reg, - pub __fpu_xmm2: __darwin_xmm_reg, - pub __fpu_xmm3: __darwin_xmm_reg, - pub __fpu_xmm4: __darwin_xmm_reg, - pub __fpu_xmm5: __darwin_xmm_reg, - pub __fpu_xmm6: __darwin_xmm_reg, - pub __fpu_xmm7: __darwin_xmm_reg, - pub __fpu_xmm8: __darwin_xmm_reg, - pub __fpu_xmm9: __darwin_xmm_reg, - pub __fpu_xmm10: __darwin_xmm_reg, - pub __fpu_xmm11: __darwin_xmm_reg, - pub __fpu_xmm12: __darwin_xmm_reg, - pub __fpu_xmm13: __darwin_xmm_reg, - pub __fpu_xmm14: __darwin_xmm_reg, - pub __fpu_xmm15: __darwin_xmm_reg, - pub __fpu_rsrv4: [::std::os::raw::c_char; 96usize], - pub __fpu_reserved1: ::std::os::raw::c_int, - pub __avx_reserved1: [::std::os::raw::c_char; 64usize], - pub __fpu_ymmh0: __darwin_xmm_reg, - pub __fpu_ymmh1: __darwin_xmm_reg, - pub __fpu_ymmh2: __darwin_xmm_reg, - pub __fpu_ymmh3: __darwin_xmm_reg, - pub __fpu_ymmh4: __darwin_xmm_reg, - pub __fpu_ymmh5: __darwin_xmm_reg, - pub __fpu_ymmh6: __darwin_xmm_reg, - pub __fpu_ymmh7: __darwin_xmm_reg, - pub __fpu_ymmh8: __darwin_xmm_reg, - pub __fpu_ymmh9: __darwin_xmm_reg, - pub __fpu_ymmh10: __darwin_xmm_reg, - pub __fpu_ymmh11: __darwin_xmm_reg, - pub __fpu_ymmh12: __darwin_xmm_reg, - pub __fpu_ymmh13: __darwin_xmm_reg, - pub __fpu_ymmh14: __darwin_xmm_reg, - pub __fpu_ymmh15: __darwin_xmm_reg, - pub __fpu_k0: __darwin_opmask_reg, - pub __fpu_k1: __darwin_opmask_reg, - pub __fpu_k2: __darwin_opmask_reg, - pub __fpu_k3: __darwin_opmask_reg, - pub __fpu_k4: __darwin_opmask_reg, - pub __fpu_k5: __darwin_opmask_reg, - pub __fpu_k6: __darwin_opmask_reg, - pub __fpu_k7: __darwin_opmask_reg, - pub __fpu_zmmh0: __darwin_ymm_reg, - pub __fpu_zmmh1: __darwin_ymm_reg, - pub __fpu_zmmh2: __darwin_ymm_reg, - pub __fpu_zmmh3: __darwin_ymm_reg, - pub __fpu_zmmh4: __darwin_ymm_reg, - pub __fpu_zmmh5: __darwin_ymm_reg, - pub __fpu_zmmh6: __darwin_ymm_reg, - pub __fpu_zmmh7: __darwin_ymm_reg, - pub __fpu_zmmh8: __darwin_ymm_reg, - pub __fpu_zmmh9: __darwin_ymm_reg, - pub __fpu_zmmh10: __darwin_ymm_reg, - pub __fpu_zmmh11: __darwin_ymm_reg, - pub __fpu_zmmh12: __darwin_ymm_reg, - pub __fpu_zmmh13: __darwin_ymm_reg, - pub __fpu_zmmh14: __darwin_ymm_reg, - pub __fpu_zmmh15: __darwin_ymm_reg, - pub __fpu_zmm16: __darwin_zmm_reg, - pub __fpu_zmm17: __darwin_zmm_reg, - pub __fpu_zmm18: __darwin_zmm_reg, - pub __fpu_zmm19: __darwin_zmm_reg, - pub __fpu_zmm20: __darwin_zmm_reg, - pub __fpu_zmm21: __darwin_zmm_reg, - pub __fpu_zmm22: __darwin_zmm_reg, - pub __fpu_zmm23: __darwin_zmm_reg, - pub __fpu_zmm24: __darwin_zmm_reg, - pub __fpu_zmm25: __darwin_zmm_reg, - pub __fpu_zmm26: __darwin_zmm_reg, - pub __fpu_zmm27: __darwin_zmm_reg, - pub __fpu_zmm28: __darwin_zmm_reg, - pub __fpu_zmm29: __darwin_zmm_reg, - pub __fpu_zmm30: __darwin_zmm_reg, - pub __fpu_zmm31: __darwin_zmm_reg, +pub struct OrtCustomHandleType { + pub __place_holder: ::std::os::raw::c_char, } #[test] -fn bindgen_test_layout___darwin_x86_avx512_state64() { - assert_eq!( - ::std::mem::size_of::<__darwin_x86_avx512_state64>(), - 2444usize, - concat!("Size of: ", stringify!(__darwin_x86_avx512_state64)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_x86_avx512_state64>(), - 4usize, - concat!("Alignment of ", stringify!(__darwin_x86_avx512_state64)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_reserved as *const _ - as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_reserved) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_fcw as *const _ as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_fcw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_fsw as *const _ as usize - }, - 10usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_fsw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ftw as *const _ as usize - }, - 12usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ftw) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_rsrv1 as *const _ as usize - }, - 13usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_rsrv1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_fop as *const _ as usize - }, - 14usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_fop) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ip as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ip) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_cs as *const _ as usize - }, - 20usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_cs) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_rsrv2 as *const _ as usize - }, - 22usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_rsrv2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_dp as *const _ as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_dp) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ds as *const _ as usize - }, - 28usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ds) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_rsrv3 as *const _ as usize - }, - 30usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_rsrv3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_mxcsr as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_mxcsr) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_mxcsrmask as *const _ - as usize - }, - 36usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_mxcsrmask) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_stmm0 as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_stmm0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_stmm1 as *const _ as usize - }, - 56usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_stmm1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_stmm2 as *const _ as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_stmm2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_stmm3 as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_stmm3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_stmm4 as *const _ as usize - }, - 104usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_stmm4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_stmm5 as *const _ as usize - }, - 120usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_stmm5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_stmm6 as *const _ as usize - }, - 136usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_stmm6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_stmm7 as *const _ as usize - }, - 152usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_stmm7) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_xmm0 as *const _ as usize - }, - 168usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_xmm0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_xmm1 as *const _ as usize - }, - 184usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_xmm1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_xmm2 as *const _ as usize - }, - 200usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_xmm2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_xmm3 as *const _ as usize - }, - 216usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_xmm3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_xmm4 as *const _ as usize - }, - 232usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_xmm4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_xmm5 as *const _ as usize - }, - 248usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_xmm5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_xmm6 as *const _ as usize - }, - 264usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_xmm6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_xmm7 as *const _ as usize - }, - 280usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_xmm7) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_xmm8 as *const _ as usize - }, - 296usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_xmm8) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_xmm9 as *const _ as usize - }, - 312usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_xmm9) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_xmm10 as *const _ as usize - }, - 328usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_xmm10) - ) - ); +fn bindgen_test_layout_OrtCustomHandleType() { assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_xmm11 as *const _ as usize - }, - 344usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_xmm11) - ) + ::std::mem::size_of::(), + 1usize, + concat!("Size of: ", stringify!(OrtCustomHandleType)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_xmm12 as *const _ as usize - }, - 360usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_xmm12) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_xmm13 as *const _ as usize - }, - 376usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_xmm13) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_xmm14 as *const _ as usize - }, - 392usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_xmm14) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_xmm15 as *const _ as usize - }, - 408usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_xmm15) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_rsrv4 as *const _ as usize - }, - 424usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_rsrv4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_reserved1 as *const _ - as usize - }, - 520usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_reserved1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__avx_reserved1 as *const _ - as usize - }, - 524usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__avx_reserved1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ymmh0 as *const _ as usize - }, - 588usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ymmh0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ymmh1 as *const _ as usize - }, - 604usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ymmh1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ymmh2 as *const _ as usize - }, - 620usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ymmh2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ymmh3 as *const _ as usize - }, - 636usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ymmh3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ymmh4 as *const _ as usize - }, - 652usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ymmh4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ymmh5 as *const _ as usize - }, - 668usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ymmh5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ymmh6 as *const _ as usize - }, - 684usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ymmh6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ymmh7 as *const _ as usize - }, - 700usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ymmh7) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ymmh8 as *const _ as usize - }, - 716usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ymmh8) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ymmh9 as *const _ as usize - }, - 732usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ymmh9) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ymmh10 as *const _ - as usize - }, - 748usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ymmh10) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ymmh11 as *const _ - as usize - }, - 764usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ymmh11) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ymmh12 as *const _ - as usize - }, - 780usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ymmh12) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ymmh13 as *const _ - as usize - }, - 796usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ymmh13) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ymmh14 as *const _ - as usize - }, - 812usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ymmh14) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_ymmh15 as *const _ - as usize - }, - 828usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_ymmh15) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_k0 as *const _ as usize - }, - 844usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_k0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_k1 as *const _ as usize - }, - 852usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_k1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_k2 as *const _ as usize - }, - 860usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_k2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_k3 as *const _ as usize - }, - 868usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_k3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_k4 as *const _ as usize - }, - 876usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_k4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_k5 as *const _ as usize - }, - 884usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_k5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_k6 as *const _ as usize - }, - 892usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_k6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_k7 as *const _ as usize - }, - 900usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_k7) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmmh0 as *const _ as usize - }, - 908usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmmh0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmmh1 as *const _ as usize - }, - 940usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmmh1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmmh2 as *const _ as usize - }, - 972usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmmh2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmmh3 as *const _ as usize - }, - 1004usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmmh3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmmh4 as *const _ as usize - }, - 1036usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmmh4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmmh5 as *const _ as usize - }, - 1068usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmmh5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmmh6 as *const _ as usize - }, - 1100usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmmh6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmmh7 as *const _ as usize - }, - 1132usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmmh7) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmmh8 as *const _ as usize - }, - 1164usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmmh8) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmmh9 as *const _ as usize - }, - 1196usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmmh9) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmmh10 as *const _ - as usize - }, - 1228usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmmh10) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmmh11 as *const _ - as usize - }, - 1260usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmmh11) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmmh12 as *const _ - as usize - }, - 1292usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmmh12) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmmh13 as *const _ - as usize - }, - 1324usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmmh13) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmmh14 as *const _ - as usize - }, - 1356usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmmh14) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmmh15 as *const _ - as usize - }, - 1388usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmmh15) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmm16 as *const _ as usize - }, - 1420usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmm16) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmm17 as *const _ as usize - }, - 1484usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmm17) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmm18 as *const _ as usize - }, - 1548usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmm18) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmm19 as *const _ as usize - }, - 1612usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmm19) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmm20 as *const _ as usize - }, - 1676usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmm20) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmm21 as *const _ as usize - }, - 1740usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmm21) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmm22 as *const _ as usize - }, - 1804usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmm22) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmm23 as *const _ as usize - }, - 1868usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmm23) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmm24 as *const _ as usize - }, - 1932usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmm24) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmm25 as *const _ as usize - }, - 1996usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmm25) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmm26 as *const _ as usize - }, - 2060usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmm26) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmm27 as *const _ as usize - }, - 2124usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmm27) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmm28 as *const _ as usize - }, - 2188usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmm28) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmm29 as *const _ as usize - }, - 2252usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmm29) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmm30 as *const _ as usize - }, - 2316usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmm30) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_avx512_state64>())).__fpu_zmm31 as *const _ as usize - }, - 2380usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_avx512_state64), - "::", - stringify!(__fpu_zmm31) - ) - ); -} + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(OrtCustomHandleType)) + ); + fn test_field___place_holder() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__place_holder) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomHandleType), + "::", + stringify!(__place_holder) + ) + ); + } + test_field___place_holder(); +} +pub type OrtCustomThreadHandle = *const OrtCustomHandleType; +#[doc = " \\brief Ort custom thread creation function"] +#[doc = ""] +#[doc = " The function should return a thread handle to be used in onnxruntime thread pools"] +#[doc = " Onnxruntime will throw exception on return value of nullptr or 0, indicating that the function failed to create a thread"] +pub type OrtCustomCreateThreadFn = ::std::option::Option< + unsafe extern "C" fn( + ort_custom_thread_creation_options: *mut ::std::os::raw::c_void, + ort_thread_worker_fn: OrtThreadWorkerFn, + ort_worker_fn_param: *mut ::std::os::raw::c_void, + ) -> OrtCustomThreadHandle, +>; +#[doc = " \\brief Custom thread join function"] +#[doc = ""] +#[doc = " Onnxruntime thread pool destructor will call the function to join a custom thread."] +#[doc = " Argument ort_custom_thread_handle is the value returned by OrtCustomCreateThreadFn"] +pub type OrtCustomJoinThreadFn = + ::std::option::Option; +#[doc = " \\brief The C API"] +#[doc = ""] +#[doc = " All C API functions are defined inside this structure as pointers to functions."] +#[doc = " Call OrtApiBase::GetApi to get a pointer to it"] +#[doc = ""] +#[doc = " \\nosubgrouping"] #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct __darwin_x86_exception_state64 { - pub __trapno: __uint16_t, - pub __cpu: __uint16_t, - pub __err: __uint32_t, - pub __faultvaddr: __uint64_t, -} -#[test] -fn bindgen_test_layout___darwin_x86_exception_state64() { - assert_eq!( - ::std::mem::size_of::<__darwin_x86_exception_state64>(), - 16usize, - concat!("Size of: ", stringify!(__darwin_x86_exception_state64)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_x86_exception_state64>(), - 8usize, - concat!("Alignment of ", stringify!(__darwin_x86_exception_state64)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_exception_state64>())).__trapno as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_exception_state64), - "::", - stringify!(__trapno) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_exception_state64>())).__cpu as *const _ as usize - }, - 2usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_exception_state64), - "::", - stringify!(__cpu) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_exception_state64>())).__err as *const _ as usize - }, - 4usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_exception_state64), - "::", - stringify!(__err) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_exception_state64>())).__faultvaddr as *const _ - as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_exception_state64), - "::", - stringify!(__faultvaddr) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_x86_debug_state64 { - pub __dr0: __uint64_t, - pub __dr1: __uint64_t, - pub __dr2: __uint64_t, - pub __dr3: __uint64_t, - pub __dr4: __uint64_t, - pub __dr5: __uint64_t, - pub __dr6: __uint64_t, - pub __dr7: __uint64_t, -} -#[test] -fn bindgen_test_layout___darwin_x86_debug_state64() { - assert_eq!( - ::std::mem::size_of::<__darwin_x86_debug_state64>(), - 64usize, - concat!("Size of: ", stringify!(__darwin_x86_debug_state64)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_x86_debug_state64>(), - 8usize, - concat!("Alignment of ", stringify!(__darwin_x86_debug_state64)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_debug_state64>())).__dr0 as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_debug_state64), - "::", - stringify!(__dr0) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_debug_state64>())).__dr1 as *const _ as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_debug_state64), - "::", - stringify!(__dr1) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_debug_state64>())).__dr2 as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_debug_state64), - "::", - stringify!(__dr2) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_debug_state64>())).__dr3 as *const _ as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_debug_state64), - "::", - stringify!(__dr3) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_debug_state64>())).__dr4 as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_debug_state64), - "::", - stringify!(__dr4) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_debug_state64>())).__dr5 as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_debug_state64), - "::", - stringify!(__dr5) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_debug_state64>())).__dr6 as *const _ as usize - }, - 48usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_debug_state64), - "::", - stringify!(__dr6) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_debug_state64>())).__dr7 as *const _ as usize - }, - 56usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_debug_state64), - "::", - stringify!(__dr7) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_x86_cpmu_state64 { - pub __ctrs: [__uint64_t; 16usize], -} -#[test] -fn bindgen_test_layout___darwin_x86_cpmu_state64() { - assert_eq!( - ::std::mem::size_of::<__darwin_x86_cpmu_state64>(), - 128usize, - concat!("Size of: ", stringify!(__darwin_x86_cpmu_state64)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_x86_cpmu_state64>(), - 8usize, - concat!("Alignment of ", stringify!(__darwin_x86_cpmu_state64)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_x86_cpmu_state64>())).__ctrs as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_x86_cpmu_state64), - "::", - stringify!(__ctrs) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_mcontext32 { - pub __es: __darwin_i386_exception_state, - pub __ss: __darwin_i386_thread_state, - pub __fs: __darwin_i386_float_state, -} -#[test] -fn bindgen_test_layout___darwin_mcontext32() { - assert_eq!( - ::std::mem::size_of::<__darwin_mcontext32>(), - 600usize, - concat!("Size of: ", stringify!(__darwin_mcontext32)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_mcontext32>(), - 4usize, - concat!("Alignment of ", stringify!(__darwin_mcontext32)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext32>())).__es as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext32), - "::", - stringify!(__es) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext32>())).__ss as *const _ as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext32), - "::", - stringify!(__ss) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext32>())).__fs as *const _ as usize }, - 76usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext32), - "::", - stringify!(__fs) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_mcontext_avx32 { - pub __es: __darwin_i386_exception_state, - pub __ss: __darwin_i386_thread_state, - pub __fs: __darwin_i386_avx_state, -} -#[test] -fn bindgen_test_layout___darwin_mcontext_avx32() { - assert_eq!( - ::std::mem::size_of::<__darwin_mcontext_avx32>(), - 792usize, - concat!("Size of: ", stringify!(__darwin_mcontext_avx32)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_mcontext_avx32>(), - 4usize, - concat!("Alignment of ", stringify!(__darwin_mcontext_avx32)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext_avx32>())).__es as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx32), - "::", - stringify!(__es) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext_avx32>())).__ss as *const _ as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx32), - "::", - stringify!(__ss) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext_avx32>())).__fs as *const _ as usize }, - 76usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx32), - "::", - stringify!(__fs) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_mcontext_avx512_32 { - pub __es: __darwin_i386_exception_state, - pub __ss: __darwin_i386_thread_state, - pub __fs: __darwin_i386_avx512_state, -} -#[test] -fn bindgen_test_layout___darwin_mcontext_avx512_32() { - assert_eq!( - ::std::mem::size_of::<__darwin_mcontext_avx512_32>(), - 1112usize, - concat!("Size of: ", stringify!(__darwin_mcontext_avx512_32)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_mcontext_avx512_32>(), - 4usize, - concat!("Alignment of ", stringify!(__darwin_mcontext_avx512_32)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_mcontext_avx512_32>())).__es as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx512_32), - "::", - stringify!(__es) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_mcontext_avx512_32>())).__ss as *const _ as usize - }, - 12usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx512_32), - "::", - stringify!(__ss) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_mcontext_avx512_32>())).__fs as *const _ as usize - }, - 76usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx512_32), - "::", - stringify!(__fs) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_mcontext64 { - pub __es: __darwin_x86_exception_state64, - pub __ss: __darwin_x86_thread_state64, - pub __fs: __darwin_x86_float_state64, -} -#[test] -fn bindgen_test_layout___darwin_mcontext64() { - assert_eq!( - ::std::mem::size_of::<__darwin_mcontext64>(), - 712usize, - concat!("Size of: ", stringify!(__darwin_mcontext64)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_mcontext64>(), - 8usize, - concat!("Alignment of ", stringify!(__darwin_mcontext64)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext64>())).__es as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext64), - "::", - stringify!(__es) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext64>())).__ss as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext64), - "::", - stringify!(__ss) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext64>())).__fs as *const _ as usize }, - 184usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext64), - "::", - stringify!(__fs) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_mcontext64_full { - pub __es: __darwin_x86_exception_state64, - pub __ss: __darwin_x86_thread_full_state64, - pub __fs: __darwin_x86_float_state64, -} -#[test] -fn bindgen_test_layout___darwin_mcontext64_full() { - assert_eq!( - ::std::mem::size_of::<__darwin_mcontext64_full>(), - 744usize, - concat!("Size of: ", stringify!(__darwin_mcontext64_full)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_mcontext64_full>(), - 8usize, - concat!("Alignment of ", stringify!(__darwin_mcontext64_full)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext64_full>())).__es as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext64_full), - "::", - stringify!(__es) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext64_full>())).__ss as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext64_full), - "::", - stringify!(__ss) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext64_full>())).__fs as *const _ as usize }, - 216usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext64_full), - "::", - stringify!(__fs) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_mcontext_avx64 { - pub __es: __darwin_x86_exception_state64, - pub __ss: __darwin_x86_thread_state64, - pub __fs: __darwin_x86_avx_state64, -} -#[test] -fn bindgen_test_layout___darwin_mcontext_avx64() { - assert_eq!( - ::std::mem::size_of::<__darwin_mcontext_avx64>(), - 1032usize, - concat!("Size of: ", stringify!(__darwin_mcontext_avx64)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_mcontext_avx64>(), - 8usize, - concat!("Alignment of ", stringify!(__darwin_mcontext_avx64)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext_avx64>())).__es as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx64), - "::", - stringify!(__es) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext_avx64>())).__ss as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx64), - "::", - stringify!(__ss) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_mcontext_avx64>())).__fs as *const _ as usize }, - 184usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx64), - "::", - stringify!(__fs) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_mcontext_avx64_full { - pub __es: __darwin_x86_exception_state64, - pub __ss: __darwin_x86_thread_full_state64, - pub __fs: __darwin_x86_avx_state64, -} -#[test] -fn bindgen_test_layout___darwin_mcontext_avx64_full() { - assert_eq!( - ::std::mem::size_of::<__darwin_mcontext_avx64_full>(), - 1064usize, - concat!("Size of: ", stringify!(__darwin_mcontext_avx64_full)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_mcontext_avx64_full>(), - 8usize, - concat!("Alignment of ", stringify!(__darwin_mcontext_avx64_full)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_mcontext_avx64_full>())).__es as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx64_full), - "::", - stringify!(__es) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_mcontext_avx64_full>())).__ss as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx64_full), - "::", - stringify!(__ss) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_mcontext_avx64_full>())).__fs as *const _ as usize - }, - 216usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx64_full), - "::", - stringify!(__fs) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_mcontext_avx512_64 { - pub __es: __darwin_x86_exception_state64, - pub __ss: __darwin_x86_thread_state64, - pub __fs: __darwin_x86_avx512_state64, -} -#[test] -fn bindgen_test_layout___darwin_mcontext_avx512_64() { - assert_eq!( - ::std::mem::size_of::<__darwin_mcontext_avx512_64>(), - 2632usize, - concat!("Size of: ", stringify!(__darwin_mcontext_avx512_64)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_mcontext_avx512_64>(), - 8usize, - concat!("Alignment of ", stringify!(__darwin_mcontext_avx512_64)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_mcontext_avx512_64>())).__es as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx512_64), - "::", - stringify!(__es) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_mcontext_avx512_64>())).__ss as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx512_64), - "::", - stringify!(__ss) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_mcontext_avx512_64>())).__fs as *const _ as usize - }, - 184usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx512_64), - "::", - stringify!(__fs) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_mcontext_avx512_64_full { - pub __es: __darwin_x86_exception_state64, - pub __ss: __darwin_x86_thread_full_state64, - pub __fs: __darwin_x86_avx512_state64, -} -#[test] -fn bindgen_test_layout___darwin_mcontext_avx512_64_full() { - assert_eq!( - ::std::mem::size_of::<__darwin_mcontext_avx512_64_full>(), - 2664usize, - concat!("Size of: ", stringify!(__darwin_mcontext_avx512_64_full)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_mcontext_avx512_64_full>(), - 8usize, - concat!( - "Alignment of ", - stringify!(__darwin_mcontext_avx512_64_full) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_mcontext_avx512_64_full>())).__es as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx512_64_full), - "::", - stringify!(__es) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_mcontext_avx512_64_full>())).__ss as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx512_64_full), - "::", - stringify!(__ss) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__darwin_mcontext_avx512_64_full>())).__fs as *const _ as usize - }, - 216usize, - concat!( - "Offset of field: ", - stringify!(__darwin_mcontext_avx512_64_full), - "::", - stringify!(__fs) - ) - ); -} -pub type mcontext_t = *mut __darwin_mcontext64; -pub type pthread_attr_t = __darwin_pthread_attr_t; -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_sigaltstack { - pub ss_sp: *mut ::std::os::raw::c_void, - pub ss_size: __darwin_size_t, - pub ss_flags: ::std::os::raw::c_int, -} -#[test] -fn bindgen_test_layout___darwin_sigaltstack() { - assert_eq!( - ::std::mem::size_of::<__darwin_sigaltstack>(), - 24usize, - concat!("Size of: ", stringify!(__darwin_sigaltstack)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_sigaltstack>(), - 8usize, - concat!("Alignment of ", stringify!(__darwin_sigaltstack)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_sigaltstack>())).ss_sp as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_sigaltstack), - "::", - stringify!(ss_sp) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_sigaltstack>())).ss_size as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__darwin_sigaltstack), - "::", - stringify!(ss_size) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_sigaltstack>())).ss_flags as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__darwin_sigaltstack), - "::", - stringify!(ss_flags) - ) - ); -} -pub type stack_t = __darwin_sigaltstack; -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct __darwin_ucontext { - pub uc_onstack: ::std::os::raw::c_int, - pub uc_sigmask: __darwin_sigset_t, - pub uc_stack: __darwin_sigaltstack, - pub uc_link: *mut __darwin_ucontext, - pub uc_mcsize: __darwin_size_t, - pub uc_mcontext: *mut __darwin_mcontext64, -} -#[test] -fn bindgen_test_layout___darwin_ucontext() { - assert_eq!( - ::std::mem::size_of::<__darwin_ucontext>(), - 56usize, - concat!("Size of: ", stringify!(__darwin_ucontext)) - ); - assert_eq!( - ::std::mem::align_of::<__darwin_ucontext>(), - 8usize, - concat!("Alignment of ", stringify!(__darwin_ucontext)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_ucontext>())).uc_onstack as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__darwin_ucontext), - "::", - stringify!(uc_onstack) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_ucontext>())).uc_sigmask as *const _ as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(__darwin_ucontext), - "::", - stringify!(uc_sigmask) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_ucontext>())).uc_stack as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__darwin_ucontext), - "::", - stringify!(uc_stack) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_ucontext>())).uc_link as *const _ as usize }, - 32usize, - concat!( - "Offset of field: ", - stringify!(__darwin_ucontext), - "::", - stringify!(uc_link) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_ucontext>())).uc_mcsize as *const _ as usize }, - 40usize, - concat!( - "Offset of field: ", - stringify!(__darwin_ucontext), - "::", - stringify!(uc_mcsize) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__darwin_ucontext>())).uc_mcontext as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(__darwin_ucontext), - "::", - stringify!(uc_mcontext) - ) - ); -} -pub type ucontext_t = __darwin_ucontext; -pub type sigset_t = __darwin_sigset_t; -pub type uid_t = __darwin_uid_t; -#[repr(C)] -#[derive(Copy, Clone)] -pub union sigval { - pub sival_int: ::std::os::raw::c_int, - pub sival_ptr: *mut ::std::os::raw::c_void, -} -#[test] -fn bindgen_test_layout_sigval() { - assert_eq!( - ::std::mem::size_of::(), - 8usize, - concat!("Size of: ", stringify!(sigval)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(sigval)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).sival_int as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(sigval), - "::", - stringify!(sival_int) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).sival_ptr as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(sigval), - "::", - stringify!(sival_ptr) - ) - ); -} -#[repr(C)] -#[derive(Copy, Clone)] -pub struct sigevent { - pub sigev_notify: ::std::os::raw::c_int, - pub sigev_signo: ::std::os::raw::c_int, - pub sigev_value: sigval, - pub sigev_notify_function: ::std::option::Option, - pub sigev_notify_attributes: *mut pthread_attr_t, -} -#[test] -fn bindgen_test_layout_sigevent() { - assert_eq!( - ::std::mem::size_of::(), - 32usize, - concat!("Size of: ", stringify!(sigevent)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(sigevent)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).sigev_notify as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(sigevent), - "::", - stringify!(sigev_notify) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).sigev_signo as *const _ as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(sigevent), - "::", - stringify!(sigev_signo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).sigev_value as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(sigevent), - "::", - stringify!(sigev_value) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).sigev_notify_function as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(sigevent), - "::", - stringify!(sigev_notify_function) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).sigev_notify_attributes as *const _ as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(sigevent), - "::", - stringify!(sigev_notify_attributes) - ) - ); -} -#[repr(C)] -#[derive(Copy, Clone)] -pub struct __siginfo { - pub si_signo: ::std::os::raw::c_int, - pub si_errno: ::std::os::raw::c_int, - pub si_code: ::std::os::raw::c_int, - pub si_pid: pid_t, - pub si_uid: uid_t, - pub si_status: ::std::os::raw::c_int, - pub si_addr: *mut ::std::os::raw::c_void, - pub si_value: sigval, - pub si_band: ::std::os::raw::c_long, - pub __pad: [::std::os::raw::c_ulong; 7usize], -} -#[test] -fn bindgen_test_layout___siginfo() { - assert_eq!( - ::std::mem::size_of::<__siginfo>(), - 104usize, - concat!("Size of: ", stringify!(__siginfo)) - ); - assert_eq!( - ::std::mem::align_of::<__siginfo>(), - 8usize, - concat!("Alignment of ", stringify!(__siginfo)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__siginfo>())).si_signo as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__siginfo), - "::", - stringify!(si_signo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__siginfo>())).si_errno as *const _ as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(__siginfo), - "::", - stringify!(si_errno) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__siginfo>())).si_code as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__siginfo), - "::", - stringify!(si_code) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__siginfo>())).si_pid as *const _ as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(__siginfo), - "::", - stringify!(si_pid) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__siginfo>())).si_uid as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__siginfo), - "::", - stringify!(si_uid) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__siginfo>())).si_status as *const _ as usize }, - 20usize, - concat!( - "Offset of field: ", - stringify!(__siginfo), - "::", - stringify!(si_status) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__siginfo>())).si_addr as *const _ as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(__siginfo), - "::", - stringify!(si_addr) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__siginfo>())).si_value as *const _ as usize }, - 32usize, - concat!( - "Offset of field: ", - stringify!(__siginfo), - "::", - stringify!(si_value) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__siginfo>())).si_band as *const _ as usize }, - 40usize, - concat!( - "Offset of field: ", - stringify!(__siginfo), - "::", - stringify!(si_band) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__siginfo>())).__pad as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(__siginfo), - "::", - stringify!(__pad) - ) - ); -} -pub type siginfo_t = __siginfo; -#[repr(C)] -#[derive(Copy, Clone)] -pub union __sigaction_u { - pub __sa_handler: ::std::option::Option, - pub __sa_sigaction: ::std::option::Option< - unsafe extern "C" fn( - arg1: ::std::os::raw::c_int, - arg2: *mut __siginfo, - arg3: *mut ::std::os::raw::c_void, - ), - >, -} -#[test] -fn bindgen_test_layout___sigaction_u() { - assert_eq!( - ::std::mem::size_of::<__sigaction_u>(), - 8usize, - concat!("Size of: ", stringify!(__sigaction_u)) - ); - assert_eq!( - ::std::mem::align_of::<__sigaction_u>(), - 8usize, - concat!("Alignment of ", stringify!(__sigaction_u)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__sigaction_u>())).__sa_handler as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__sigaction_u), - "::", - stringify!(__sa_handler) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__sigaction_u>())).__sa_sigaction as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__sigaction_u), - "::", - stringify!(__sa_sigaction) - ) - ); -} -#[repr(C)] -#[derive(Copy, Clone)] -pub struct __sigaction { - pub __sigaction_u: __sigaction_u, - pub sa_tramp: ::std::option::Option< - unsafe extern "C" fn( - arg1: *mut ::std::os::raw::c_void, - arg2: ::std::os::raw::c_int, - arg3: ::std::os::raw::c_int, - arg4: *mut siginfo_t, - arg5: *mut ::std::os::raw::c_void, - ), - >, - pub sa_mask: sigset_t, - pub sa_flags: ::std::os::raw::c_int, -} -#[test] -fn bindgen_test_layout___sigaction() { - assert_eq!( - ::std::mem::size_of::<__sigaction>(), - 24usize, - concat!("Size of: ", stringify!(__sigaction)) - ); - assert_eq!( - ::std::mem::align_of::<__sigaction>(), - 8usize, - concat!("Alignment of ", stringify!(__sigaction)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__sigaction>())).__sigaction_u as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__sigaction), - "::", - stringify!(__sigaction_u) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__sigaction>())).sa_tramp as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__sigaction), - "::", - stringify!(sa_tramp) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__sigaction>())).sa_mask as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__sigaction), - "::", - stringify!(sa_mask) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__sigaction>())).sa_flags as *const _ as usize }, - 20usize, - concat!( - "Offset of field: ", - stringify!(__sigaction), - "::", - stringify!(sa_flags) - ) - ); -} -#[repr(C)] -#[derive(Copy, Clone)] -pub struct sigaction { - pub __sigaction_u: __sigaction_u, - pub sa_mask: sigset_t, - pub sa_flags: ::std::os::raw::c_int, -} -#[test] -fn bindgen_test_layout_sigaction() { - assert_eq!( - ::std::mem::size_of::(), - 16usize, - concat!("Size of: ", stringify!(sigaction)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(sigaction)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).__sigaction_u as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(sigaction), - "::", - stringify!(__sigaction_u) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).sa_mask as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(sigaction), - "::", - stringify!(sa_mask) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).sa_flags as *const _ as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(sigaction), - "::", - stringify!(sa_flags) - ) - ); -} -pub type sig_t = ::std::option::Option; -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct sigvec { - pub sv_handler: ::std::option::Option, - pub sv_mask: ::std::os::raw::c_int, - pub sv_flags: ::std::os::raw::c_int, -} -#[test] -fn bindgen_test_layout_sigvec() { - assert_eq!( - ::std::mem::size_of::(), - 16usize, - concat!("Size of: ", stringify!(sigvec)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(sigvec)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).sv_handler as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(sigvec), - "::", - stringify!(sv_handler) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).sv_mask as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(sigvec), - "::", - stringify!(sv_mask) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).sv_flags as *const _ as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(sigvec), - "::", - stringify!(sv_flags) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct sigstack { - pub ss_sp: *mut ::std::os::raw::c_char, - pub ss_onstack: ::std::os::raw::c_int, -} -#[test] -fn bindgen_test_layout_sigstack() { - assert_eq!( - ::std::mem::size_of::(), - 16usize, - concat!("Size of: ", stringify!(sigstack)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(sigstack)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ss_sp as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(sigstack), - "::", - stringify!(ss_sp) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ss_onstack as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(sigstack), - "::", - stringify!(ss_onstack) - ) - ); -} -extern "C" { - pub fn signal( - arg1: ::std::os::raw::c_int, - arg2: ::std::option::Option, - ) -> ::std::option::Option< - unsafe extern "C" fn( - arg1: ::std::os::raw::c_int, - arg2: ::std::option::Option, - ), - >; -} -pub type int_least8_t = i8; -pub type int_least16_t = i16; -pub type int_least32_t = i32; -pub type int_least64_t = i64; -pub type uint_least8_t = u8; -pub type uint_least16_t = u16; -pub type uint_least32_t = u32; -pub type uint_least64_t = u64; -pub type int_fast8_t = i8; -pub type int_fast16_t = i16; -pub type int_fast32_t = i32; -pub type int_fast64_t = i64; -pub type uint_fast8_t = u8; -pub type uint_fast16_t = u16; -pub type uint_fast32_t = u32; -pub type uint_fast64_t = u64; -pub type intmax_t = ::std::os::raw::c_long; -pub type uintmax_t = ::std::os::raw::c_ulong; -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct timeval { - pub tv_sec: __darwin_time_t, - pub tv_usec: __darwin_suseconds_t, -} -#[test] -fn bindgen_test_layout_timeval() { - assert_eq!( - ::std::mem::size_of::(), - 16usize, - concat!("Size of: ", stringify!(timeval)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(timeval)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).tv_sec as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(timeval), - "::", - stringify!(tv_sec) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).tv_usec as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(timeval), - "::", - stringify!(tv_usec) - ) - ); -} -pub type rlim_t = __uint64_t; -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct rusage { - pub ru_utime: timeval, - pub ru_stime: timeval, - pub ru_maxrss: ::std::os::raw::c_long, - pub ru_ixrss: ::std::os::raw::c_long, - pub ru_idrss: ::std::os::raw::c_long, - pub ru_isrss: ::std::os::raw::c_long, - pub ru_minflt: ::std::os::raw::c_long, - pub ru_majflt: ::std::os::raw::c_long, - pub ru_nswap: ::std::os::raw::c_long, - pub ru_inblock: ::std::os::raw::c_long, - pub ru_oublock: ::std::os::raw::c_long, - pub ru_msgsnd: ::std::os::raw::c_long, - pub ru_msgrcv: ::std::os::raw::c_long, - pub ru_nsignals: ::std::os::raw::c_long, - pub ru_nvcsw: ::std::os::raw::c_long, - pub ru_nivcsw: ::std::os::raw::c_long, -} -#[test] -fn bindgen_test_layout_rusage() { - assert_eq!( - ::std::mem::size_of::(), - 144usize, - concat!("Size of: ", stringify!(rusage)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(rusage)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_utime as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_utime) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_stime as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_stime) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_maxrss as *const _ as usize }, - 32usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_maxrss) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_ixrss as *const _ as usize }, - 40usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_ixrss) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_idrss as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_idrss) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_isrss as *const _ as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_isrss) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_minflt as *const _ as usize }, - 64usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_minflt) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_majflt as *const _ as usize }, - 72usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_majflt) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_nswap as *const _ as usize }, - 80usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_nswap) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_inblock as *const _ as usize }, - 88usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_inblock) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_oublock as *const _ as usize }, - 96usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_oublock) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_msgsnd as *const _ as usize }, - 104usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_msgsnd) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_msgrcv as *const _ as usize }, - 112usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_msgrcv) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_nsignals as *const _ as usize }, - 120usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_nsignals) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_nvcsw as *const _ as usize }, - 128usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_nvcsw) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ru_nivcsw as *const _ as usize }, - 136usize, - concat!( - "Offset of field: ", - stringify!(rusage), - "::", - stringify!(ru_nivcsw) - ) - ); -} -pub type rusage_info_t = *mut ::std::os::raw::c_void; -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct rusage_info_v0 { - pub ri_uuid: [u8; 16usize], - pub ri_user_time: u64, - pub ri_system_time: u64, - pub ri_pkg_idle_wkups: u64, - pub ri_interrupt_wkups: u64, - pub ri_pageins: u64, - pub ri_wired_size: u64, - pub ri_resident_size: u64, - pub ri_phys_footprint: u64, - pub ri_proc_start_abstime: u64, - pub ri_proc_exit_abstime: u64, -} -#[test] -fn bindgen_test_layout_rusage_info_v0() { - assert_eq!( - ::std::mem::size_of::(), - 96usize, - concat!("Size of: ", stringify!(rusage_info_v0)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(rusage_info_v0)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_uuid as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v0), - "::", - stringify!(ri_uuid) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_user_time as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v0), - "::", - stringify!(ri_user_time) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_system_time as *const _ as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v0), - "::", - stringify!(ri_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_pkg_idle_wkups as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v0), - "::", - stringify!(ri_pkg_idle_wkups) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_interrupt_wkups as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v0), - "::", - stringify!(ri_interrupt_wkups) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_pageins as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v0), - "::", - stringify!(ri_pageins) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_wired_size as *const _ as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v0), - "::", - stringify!(ri_wired_size) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_resident_size as *const _ as usize }, - 64usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v0), - "::", - stringify!(ri_resident_size) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_phys_footprint as *const _ as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v0), - "::", - stringify!(ri_phys_footprint) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_start_abstime as *const _ as usize - }, - 80usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v0), - "::", - stringify!(ri_proc_start_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_exit_abstime as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v0), - "::", - stringify!(ri_proc_exit_abstime) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct rusage_info_v1 { - pub ri_uuid: [u8; 16usize], - pub ri_user_time: u64, - pub ri_system_time: u64, - pub ri_pkg_idle_wkups: u64, - pub ri_interrupt_wkups: u64, - pub ri_pageins: u64, - pub ri_wired_size: u64, - pub ri_resident_size: u64, - pub ri_phys_footprint: u64, - pub ri_proc_start_abstime: u64, - pub ri_proc_exit_abstime: u64, - pub ri_child_user_time: u64, - pub ri_child_system_time: u64, - pub ri_child_pkg_idle_wkups: u64, - pub ri_child_interrupt_wkups: u64, - pub ri_child_pageins: u64, - pub ri_child_elapsed_abstime: u64, -} -#[test] -fn bindgen_test_layout_rusage_info_v1() { - assert_eq!( - ::std::mem::size_of::(), - 144usize, - concat!("Size of: ", stringify!(rusage_info_v1)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(rusage_info_v1)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_uuid as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_uuid) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_user_time as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_user_time) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_system_time as *const _ as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_pkg_idle_wkups as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_pkg_idle_wkups) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_interrupt_wkups as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_interrupt_wkups) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_pageins as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_pageins) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_wired_size as *const _ as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_wired_size) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_resident_size as *const _ as usize }, - 64usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_resident_size) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_phys_footprint as *const _ as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_phys_footprint) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_start_abstime as *const _ as usize - }, - 80usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_proc_start_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_exit_abstime as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_proc_exit_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_user_time as *const _ as usize - }, - 96usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_child_user_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_system_time as *const _ as usize - }, - 104usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_child_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_pkg_idle_wkups as *const _ as usize - }, - 112usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_child_pkg_idle_wkups) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_interrupt_wkups as *const _ as usize - }, - 120usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_child_interrupt_wkups) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_child_pageins as *const _ as usize }, - 128usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_child_pageins) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_elapsed_abstime as *const _ as usize - }, - 136usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v1), - "::", - stringify!(ri_child_elapsed_abstime) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct rusage_info_v2 { - pub ri_uuid: [u8; 16usize], - pub ri_user_time: u64, - pub ri_system_time: u64, - pub ri_pkg_idle_wkups: u64, - pub ri_interrupt_wkups: u64, - pub ri_pageins: u64, - pub ri_wired_size: u64, - pub ri_resident_size: u64, - pub ri_phys_footprint: u64, - pub ri_proc_start_abstime: u64, - pub ri_proc_exit_abstime: u64, - pub ri_child_user_time: u64, - pub ri_child_system_time: u64, - pub ri_child_pkg_idle_wkups: u64, - pub ri_child_interrupt_wkups: u64, - pub ri_child_pageins: u64, - pub ri_child_elapsed_abstime: u64, - pub ri_diskio_bytesread: u64, - pub ri_diskio_byteswritten: u64, -} -#[test] -fn bindgen_test_layout_rusage_info_v2() { - assert_eq!( - ::std::mem::size_of::(), - 160usize, - concat!("Size of: ", stringify!(rusage_info_v2)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(rusage_info_v2)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_uuid as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_uuid) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_user_time as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_user_time) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_system_time as *const _ as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_pkg_idle_wkups as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_pkg_idle_wkups) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_interrupt_wkups as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_interrupt_wkups) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_pageins as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_pageins) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_wired_size as *const _ as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_wired_size) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_resident_size as *const _ as usize }, - 64usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_resident_size) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_phys_footprint as *const _ as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_phys_footprint) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_start_abstime as *const _ as usize - }, - 80usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_proc_start_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_exit_abstime as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_proc_exit_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_user_time as *const _ as usize - }, - 96usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_child_user_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_system_time as *const _ as usize - }, - 104usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_child_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_pkg_idle_wkups as *const _ as usize - }, - 112usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_child_pkg_idle_wkups) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_interrupt_wkups as *const _ as usize - }, - 120usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_child_interrupt_wkups) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_child_pageins as *const _ as usize }, - 128usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_child_pageins) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_elapsed_abstime as *const _ as usize - }, - 136usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_child_elapsed_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_diskio_bytesread as *const _ as usize - }, - 144usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_diskio_bytesread) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_diskio_byteswritten as *const _ as usize - }, - 152usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v2), - "::", - stringify!(ri_diskio_byteswritten) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct rusage_info_v3 { - pub ri_uuid: [u8; 16usize], - pub ri_user_time: u64, - pub ri_system_time: u64, - pub ri_pkg_idle_wkups: u64, - pub ri_interrupt_wkups: u64, - pub ri_pageins: u64, - pub ri_wired_size: u64, - pub ri_resident_size: u64, - pub ri_phys_footprint: u64, - pub ri_proc_start_abstime: u64, - pub ri_proc_exit_abstime: u64, - pub ri_child_user_time: u64, - pub ri_child_system_time: u64, - pub ri_child_pkg_idle_wkups: u64, - pub ri_child_interrupt_wkups: u64, - pub ri_child_pageins: u64, - pub ri_child_elapsed_abstime: u64, - pub ri_diskio_bytesread: u64, - pub ri_diskio_byteswritten: u64, - pub ri_cpu_time_qos_default: u64, - pub ri_cpu_time_qos_maintenance: u64, - pub ri_cpu_time_qos_background: u64, - pub ri_cpu_time_qos_utility: u64, - pub ri_cpu_time_qos_legacy: u64, - pub ri_cpu_time_qos_user_initiated: u64, - pub ri_cpu_time_qos_user_interactive: u64, - pub ri_billed_system_time: u64, - pub ri_serviced_system_time: u64, -} -#[test] -fn bindgen_test_layout_rusage_info_v3() { - assert_eq!( - ::std::mem::size_of::(), - 232usize, - concat!("Size of: ", stringify!(rusage_info_v3)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(rusage_info_v3)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_uuid as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_uuid) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_user_time as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_user_time) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_system_time as *const _ as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_pkg_idle_wkups as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_pkg_idle_wkups) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_interrupt_wkups as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_interrupt_wkups) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_pageins as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_pageins) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_wired_size as *const _ as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_wired_size) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_resident_size as *const _ as usize }, - 64usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_resident_size) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_phys_footprint as *const _ as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_phys_footprint) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_start_abstime as *const _ as usize - }, - 80usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_proc_start_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_exit_abstime as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_proc_exit_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_user_time as *const _ as usize - }, - 96usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_child_user_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_system_time as *const _ as usize - }, - 104usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_child_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_pkg_idle_wkups as *const _ as usize - }, - 112usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_child_pkg_idle_wkups) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_interrupt_wkups as *const _ as usize - }, - 120usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_child_interrupt_wkups) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_child_pageins as *const _ as usize }, - 128usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_child_pageins) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_elapsed_abstime as *const _ as usize - }, - 136usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_child_elapsed_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_diskio_bytesread as *const _ as usize - }, - 144usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_diskio_bytesread) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_diskio_byteswritten as *const _ as usize - }, - 152usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_diskio_byteswritten) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_default as *const _ as usize - }, - 160usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_cpu_time_qos_default) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_maintenance as *const _ - as usize - }, - 168usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_cpu_time_qos_maintenance) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_background as *const _ - as usize - }, - 176usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_cpu_time_qos_background) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_utility as *const _ as usize - }, - 184usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_cpu_time_qos_utility) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_legacy as *const _ as usize - }, - 192usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_cpu_time_qos_legacy) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_user_initiated as *const _ - as usize - }, - 200usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_cpu_time_qos_user_initiated) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_user_interactive as *const _ - as usize - }, - 208usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_cpu_time_qos_user_interactive) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_billed_system_time as *const _ as usize - }, - 216usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_billed_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_serviced_system_time as *const _ as usize - }, - 224usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v3), - "::", - stringify!(ri_serviced_system_time) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct rusage_info_v4 { - pub ri_uuid: [u8; 16usize], - pub ri_user_time: u64, - pub ri_system_time: u64, - pub ri_pkg_idle_wkups: u64, - pub ri_interrupt_wkups: u64, - pub ri_pageins: u64, - pub ri_wired_size: u64, - pub ri_resident_size: u64, - pub ri_phys_footprint: u64, - pub ri_proc_start_abstime: u64, - pub ri_proc_exit_abstime: u64, - pub ri_child_user_time: u64, - pub ri_child_system_time: u64, - pub ri_child_pkg_idle_wkups: u64, - pub ri_child_interrupt_wkups: u64, - pub ri_child_pageins: u64, - pub ri_child_elapsed_abstime: u64, - pub ri_diskio_bytesread: u64, - pub ri_diskio_byteswritten: u64, - pub ri_cpu_time_qos_default: u64, - pub ri_cpu_time_qos_maintenance: u64, - pub ri_cpu_time_qos_background: u64, - pub ri_cpu_time_qos_utility: u64, - pub ri_cpu_time_qos_legacy: u64, - pub ri_cpu_time_qos_user_initiated: u64, - pub ri_cpu_time_qos_user_interactive: u64, - pub ri_billed_system_time: u64, - pub ri_serviced_system_time: u64, - pub ri_logical_writes: u64, - pub ri_lifetime_max_phys_footprint: u64, - pub ri_instructions: u64, - pub ri_cycles: u64, - pub ri_billed_energy: u64, - pub ri_serviced_energy: u64, - pub ri_interval_max_phys_footprint: u64, - pub ri_runnable_time: u64, -} -#[test] -fn bindgen_test_layout_rusage_info_v4() { - assert_eq!( - ::std::mem::size_of::(), - 296usize, - concat!("Size of: ", stringify!(rusage_info_v4)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(rusage_info_v4)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_uuid as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_uuid) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_user_time as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_user_time) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_system_time as *const _ as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_pkg_idle_wkups as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_pkg_idle_wkups) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_interrupt_wkups as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_interrupt_wkups) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_pageins as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_pageins) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_wired_size as *const _ as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_wired_size) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_resident_size as *const _ as usize }, - 64usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_resident_size) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_phys_footprint as *const _ as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_phys_footprint) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_start_abstime as *const _ as usize - }, - 80usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_proc_start_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_exit_abstime as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_proc_exit_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_user_time as *const _ as usize - }, - 96usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_child_user_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_system_time as *const _ as usize - }, - 104usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_child_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_pkg_idle_wkups as *const _ as usize - }, - 112usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_child_pkg_idle_wkups) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_interrupt_wkups as *const _ as usize - }, - 120usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_child_interrupt_wkups) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_child_pageins as *const _ as usize }, - 128usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_child_pageins) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_elapsed_abstime as *const _ as usize - }, - 136usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_child_elapsed_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_diskio_bytesread as *const _ as usize - }, - 144usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_diskio_bytesread) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_diskio_byteswritten as *const _ as usize - }, - 152usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_diskio_byteswritten) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_default as *const _ as usize - }, - 160usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_cpu_time_qos_default) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_maintenance as *const _ - as usize - }, - 168usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_cpu_time_qos_maintenance) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_background as *const _ - as usize - }, - 176usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_cpu_time_qos_background) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_utility as *const _ as usize - }, - 184usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_cpu_time_qos_utility) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_legacy as *const _ as usize - }, - 192usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_cpu_time_qos_legacy) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_user_initiated as *const _ - as usize - }, - 200usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_cpu_time_qos_user_initiated) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_user_interactive as *const _ - as usize - }, - 208usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_cpu_time_qos_user_interactive) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_billed_system_time as *const _ as usize - }, - 216usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_billed_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_serviced_system_time as *const _ as usize - }, - 224usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_serviced_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_logical_writes as *const _ as usize - }, - 232usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_logical_writes) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_lifetime_max_phys_footprint as *const _ - as usize - }, - 240usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_lifetime_max_phys_footprint) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_instructions as *const _ as usize }, - 248usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_instructions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_cycles as *const _ as usize }, - 256usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_cycles) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_billed_energy as *const _ as usize }, - 264usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_billed_energy) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_serviced_energy as *const _ as usize - }, - 272usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_serviced_energy) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_interval_max_phys_footprint as *const _ - as usize - }, - 280usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_interval_max_phys_footprint) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_runnable_time as *const _ as usize }, - 288usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v4), - "::", - stringify!(ri_runnable_time) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct rusage_info_v5 { - pub ri_uuid: [u8; 16usize], - pub ri_user_time: u64, - pub ri_system_time: u64, - pub ri_pkg_idle_wkups: u64, - pub ri_interrupt_wkups: u64, - pub ri_pageins: u64, - pub ri_wired_size: u64, - pub ri_resident_size: u64, - pub ri_phys_footprint: u64, - pub ri_proc_start_abstime: u64, - pub ri_proc_exit_abstime: u64, - pub ri_child_user_time: u64, - pub ri_child_system_time: u64, - pub ri_child_pkg_idle_wkups: u64, - pub ri_child_interrupt_wkups: u64, - pub ri_child_pageins: u64, - pub ri_child_elapsed_abstime: u64, - pub ri_diskio_bytesread: u64, - pub ri_diskio_byteswritten: u64, - pub ri_cpu_time_qos_default: u64, - pub ri_cpu_time_qos_maintenance: u64, - pub ri_cpu_time_qos_background: u64, - pub ri_cpu_time_qos_utility: u64, - pub ri_cpu_time_qos_legacy: u64, - pub ri_cpu_time_qos_user_initiated: u64, - pub ri_cpu_time_qos_user_interactive: u64, - pub ri_billed_system_time: u64, - pub ri_serviced_system_time: u64, - pub ri_logical_writes: u64, - pub ri_lifetime_max_phys_footprint: u64, - pub ri_instructions: u64, - pub ri_cycles: u64, - pub ri_billed_energy: u64, - pub ri_serviced_energy: u64, - pub ri_interval_max_phys_footprint: u64, - pub ri_runnable_time: u64, - pub ri_flags: u64, -} -#[test] -fn bindgen_test_layout_rusage_info_v5() { - assert_eq!( - ::std::mem::size_of::(), - 304usize, - concat!("Size of: ", stringify!(rusage_info_v5)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(rusage_info_v5)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_uuid as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_uuid) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_user_time as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_user_time) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_system_time as *const _ as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_pkg_idle_wkups as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_pkg_idle_wkups) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_interrupt_wkups as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_interrupt_wkups) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_pageins as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_pageins) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_wired_size as *const _ as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_wired_size) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_resident_size as *const _ as usize }, - 64usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_resident_size) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_phys_footprint as *const _ as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_phys_footprint) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_start_abstime as *const _ as usize - }, - 80usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_proc_start_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_proc_exit_abstime as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_proc_exit_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_user_time as *const _ as usize - }, - 96usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_child_user_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_system_time as *const _ as usize - }, - 104usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_child_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_pkg_idle_wkups as *const _ as usize - }, - 112usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_child_pkg_idle_wkups) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_interrupt_wkups as *const _ as usize - }, - 120usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_child_interrupt_wkups) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_child_pageins as *const _ as usize }, - 128usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_child_pageins) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_child_elapsed_abstime as *const _ as usize - }, - 136usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_child_elapsed_abstime) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_diskio_bytesread as *const _ as usize - }, - 144usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_diskio_bytesread) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_diskio_byteswritten as *const _ as usize - }, - 152usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_diskio_byteswritten) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_default as *const _ as usize - }, - 160usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_cpu_time_qos_default) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_maintenance as *const _ - as usize - }, - 168usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_cpu_time_qos_maintenance) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_background as *const _ - as usize - }, - 176usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_cpu_time_qos_background) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_utility as *const _ as usize - }, - 184usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_cpu_time_qos_utility) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_legacy as *const _ as usize - }, - 192usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_cpu_time_qos_legacy) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_user_initiated as *const _ - as usize - }, - 200usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_cpu_time_qos_user_initiated) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_cpu_time_qos_user_interactive as *const _ - as usize - }, - 208usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_cpu_time_qos_user_interactive) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_billed_system_time as *const _ as usize - }, - 216usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_billed_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_serviced_system_time as *const _ as usize - }, - 224usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_serviced_system_time) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_logical_writes as *const _ as usize - }, - 232usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_logical_writes) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_lifetime_max_phys_footprint as *const _ - as usize - }, - 240usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_lifetime_max_phys_footprint) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_instructions as *const _ as usize }, - 248usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_instructions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_cycles as *const _ as usize }, - 256usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_cycles) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_billed_energy as *const _ as usize }, - 264usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_billed_energy) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_serviced_energy as *const _ as usize - }, - 272usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_serviced_energy) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ri_interval_max_phys_footprint as *const _ - as usize - }, - 280usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_interval_max_phys_footprint) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_runnable_time as *const _ as usize }, - 288usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_runnable_time) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ri_flags as *const _ as usize }, - 296usize, - concat!( - "Offset of field: ", - stringify!(rusage_info_v5), - "::", - stringify!(ri_flags) - ) - ); -} -pub type rusage_info_current = rusage_info_v5; -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct rlimit { - pub rlim_cur: rlim_t, - pub rlim_max: rlim_t, -} -#[test] -fn bindgen_test_layout_rlimit() { - assert_eq!( - ::std::mem::size_of::(), - 16usize, - concat!("Size of: ", stringify!(rlimit)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(rlimit)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).rlim_cur as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(rlimit), - "::", - stringify!(rlim_cur) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).rlim_max as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(rlimit), - "::", - stringify!(rlim_max) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct proc_rlimit_control_wakeupmon { - pub wm_flags: u32, - pub wm_rate: i32, -} -#[test] -fn bindgen_test_layout_proc_rlimit_control_wakeupmon() { - assert_eq!( - ::std::mem::size_of::(), - 8usize, - concat!("Size of: ", stringify!(proc_rlimit_control_wakeupmon)) - ); - assert_eq!( - ::std::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(proc_rlimit_control_wakeupmon)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).wm_flags as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(proc_rlimit_control_wakeupmon), - "::", - stringify!(wm_flags) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).wm_rate as *const _ as usize - }, - 4usize, - concat!( - "Offset of field: ", - stringify!(proc_rlimit_control_wakeupmon), - "::", - stringify!(wm_rate) - ) - ); -} -extern "C" { - pub fn getpriority(arg1: ::std::os::raw::c_int, arg2: id_t) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn getiopolicy_np( - arg1: ::std::os::raw::c_int, - arg2: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn getrlimit(arg1: ::std::os::raw::c_int, arg2: *mut rlimit) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn getrusage(arg1: ::std::os::raw::c_int, arg2: *mut rusage) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn setpriority( - arg1: ::std::os::raw::c_int, - arg2: id_t, - arg3: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn setiopolicy_np( - arg1: ::std::os::raw::c_int, - arg2: ::std::os::raw::c_int, - arg3: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn setrlimit(arg1: ::std::os::raw::c_int, arg2: *const rlimit) -> ::std::os::raw::c_int; -} -#[repr(C)] -#[derive(Copy, Clone)] -pub union wait { - pub w_status: ::std::os::raw::c_int, - pub w_T: wait__bindgen_ty_1, - pub w_S: wait__bindgen_ty_2, -} -#[repr(C)] -#[repr(align(4))] -#[derive(Debug, Copy, Clone)] -pub struct wait__bindgen_ty_1 { - pub _bitfield_align_1: [u16; 0], - pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, -} -#[test] -fn bindgen_test_layout_wait__bindgen_ty_1() { - assert_eq!( - ::std::mem::size_of::(), - 4usize, - concat!("Size of: ", stringify!(wait__bindgen_ty_1)) - ); - assert_eq!( - ::std::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(wait__bindgen_ty_1)) - ); -} -impl wait__bindgen_ty_1 { - #[inline] - pub fn w_Termsig(&self) -> ::std::os::raw::c_uint { - unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 7u8) as u32) } - } - #[inline] - pub fn set_w_Termsig(&mut self, val: ::std::os::raw::c_uint) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(0usize, 7u8, val as u64) - } - } - #[inline] - pub fn w_Coredump(&self) -> ::std::os::raw::c_uint { - unsafe { ::std::mem::transmute(self._bitfield_1.get(7usize, 1u8) as u32) } - } - #[inline] - pub fn set_w_Coredump(&mut self, val: ::std::os::raw::c_uint) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(7usize, 1u8, val as u64) - } - } - #[inline] - pub fn w_Retcode(&self) -> ::std::os::raw::c_uint { - unsafe { ::std::mem::transmute(self._bitfield_1.get(8usize, 8u8) as u32) } - } - #[inline] - pub fn set_w_Retcode(&mut self, val: ::std::os::raw::c_uint) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(8usize, 8u8, val as u64) - } - } - #[inline] - pub fn w_Filler(&self) -> ::std::os::raw::c_uint { - unsafe { ::std::mem::transmute(self._bitfield_1.get(16usize, 16u8) as u32) } - } - #[inline] - pub fn set_w_Filler(&mut self, val: ::std::os::raw::c_uint) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(16usize, 16u8, val as u64) - } - } - #[inline] - pub fn new_bitfield_1( - w_Termsig: ::std::os::raw::c_uint, - w_Coredump: ::std::os::raw::c_uint, - w_Retcode: ::std::os::raw::c_uint, - w_Filler: ::std::os::raw::c_uint, - ) -> __BindgenBitfieldUnit<[u8; 4usize]> { - let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 4usize]> = Default::default(); - __bindgen_bitfield_unit.set(0usize, 7u8, { - let w_Termsig: u32 = unsafe { ::std::mem::transmute(w_Termsig) }; - w_Termsig as u64 - }); - __bindgen_bitfield_unit.set(7usize, 1u8, { - let w_Coredump: u32 = unsafe { ::std::mem::transmute(w_Coredump) }; - w_Coredump as u64 - }); - __bindgen_bitfield_unit.set(8usize, 8u8, { - let w_Retcode: u32 = unsafe { ::std::mem::transmute(w_Retcode) }; - w_Retcode as u64 - }); - __bindgen_bitfield_unit.set(16usize, 16u8, { - let w_Filler: u32 = unsafe { ::std::mem::transmute(w_Filler) }; - w_Filler as u64 - }); - __bindgen_bitfield_unit - } -} -#[repr(C)] -#[repr(align(4))] -#[derive(Debug, Copy, Clone)] -pub struct wait__bindgen_ty_2 { - pub _bitfield_align_1: [u16; 0], - pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, -} -#[test] -fn bindgen_test_layout_wait__bindgen_ty_2() { - assert_eq!( - ::std::mem::size_of::(), - 4usize, - concat!("Size of: ", stringify!(wait__bindgen_ty_2)) - ); - assert_eq!( - ::std::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(wait__bindgen_ty_2)) - ); -} -impl wait__bindgen_ty_2 { - #[inline] - pub fn w_Stopval(&self) -> ::std::os::raw::c_uint { - unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 8u8) as u32) } - } - #[inline] - pub fn set_w_Stopval(&mut self, val: ::std::os::raw::c_uint) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(0usize, 8u8, val as u64) - } - } - #[inline] - pub fn w_Stopsig(&self) -> ::std::os::raw::c_uint { - unsafe { ::std::mem::transmute(self._bitfield_1.get(8usize, 8u8) as u32) } - } - #[inline] - pub fn set_w_Stopsig(&mut self, val: ::std::os::raw::c_uint) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(8usize, 8u8, val as u64) - } - } - #[inline] - pub fn w_Filler(&self) -> ::std::os::raw::c_uint { - unsafe { ::std::mem::transmute(self._bitfield_1.get(16usize, 16u8) as u32) } - } - #[inline] - pub fn set_w_Filler(&mut self, val: ::std::os::raw::c_uint) { - unsafe { - let val: u32 = ::std::mem::transmute(val); - self._bitfield_1.set(16usize, 16u8, val as u64) - } - } - #[inline] - pub fn new_bitfield_1( - w_Stopval: ::std::os::raw::c_uint, - w_Stopsig: ::std::os::raw::c_uint, - w_Filler: ::std::os::raw::c_uint, - ) -> __BindgenBitfieldUnit<[u8; 4usize]> { - let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 4usize]> = Default::default(); - __bindgen_bitfield_unit.set(0usize, 8u8, { - let w_Stopval: u32 = unsafe { ::std::mem::transmute(w_Stopval) }; - w_Stopval as u64 - }); - __bindgen_bitfield_unit.set(8usize, 8u8, { - let w_Stopsig: u32 = unsafe { ::std::mem::transmute(w_Stopsig) }; - w_Stopsig as u64 - }); - __bindgen_bitfield_unit.set(16usize, 16u8, { - let w_Filler: u32 = unsafe { ::std::mem::transmute(w_Filler) }; - w_Filler as u64 - }); - __bindgen_bitfield_unit - } -} -#[test] -fn bindgen_test_layout_wait() { - assert_eq!( - ::std::mem::size_of::(), - 4usize, - concat!("Size of: ", stringify!(wait)) - ); - assert_eq!( - ::std::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(wait)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).w_status as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(wait), - "::", - stringify!(w_status) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).w_T as *const _ as usize }, - 0usize, - concat!("Offset of field: ", stringify!(wait), "::", stringify!(w_T)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).w_S as *const _ as usize }, - 0usize, - concat!("Offset of field: ", stringify!(wait), "::", stringify!(w_S)) - ); -} -extern "C" { - pub fn wait(arg1: *mut ::std::os::raw::c_int) -> pid_t; -} -extern "C" { - pub fn waitpid( - arg1: pid_t, - arg2: *mut ::std::os::raw::c_int, - arg3: ::std::os::raw::c_int, - ) -> pid_t; -} -extern "C" { - pub fn waitid( - arg1: idtype_t, - arg2: id_t, - arg3: *mut siginfo_t, - arg4: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn wait3( - arg1: *mut ::std::os::raw::c_int, - arg2: ::std::os::raw::c_int, - arg3: *mut rusage, - ) -> pid_t; -} -extern "C" { - pub fn wait4( - arg1: pid_t, - arg2: *mut ::std::os::raw::c_int, - arg3: ::std::os::raw::c_int, - arg4: *mut rusage, - ) -> pid_t; -} -extern "C" { - pub fn alloca(arg1: ::std::os::raw::c_ulong) -> *mut ::std::os::raw::c_void; -} -pub type ct_rune_t = __darwin_ct_rune_t; -pub type rune_t = __darwin_rune_t; -pub type wchar_t = __darwin_wchar_t; -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct div_t { - pub quot: ::std::os::raw::c_int, - pub rem: ::std::os::raw::c_int, -} -#[test] -fn bindgen_test_layout_div_t() { - assert_eq!( - ::std::mem::size_of::(), - 8usize, - concat!("Size of: ", stringify!(div_t)) - ); - assert_eq!( - ::std::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(div_t)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).quot as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(div_t), - "::", - stringify!(quot) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).rem as *const _ as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(div_t), - "::", - stringify!(rem) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct ldiv_t { - pub quot: ::std::os::raw::c_long, - pub rem: ::std::os::raw::c_long, -} -#[test] -fn bindgen_test_layout_ldiv_t() { - assert_eq!( - ::std::mem::size_of::(), - 16usize, - concat!("Size of: ", stringify!(ldiv_t)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(ldiv_t)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).quot as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(ldiv_t), - "::", - stringify!(quot) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).rem as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(ldiv_t), - "::", - stringify!(rem) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct lldiv_t { - pub quot: ::std::os::raw::c_longlong, - pub rem: ::std::os::raw::c_longlong, -} -#[test] -fn bindgen_test_layout_lldiv_t() { - assert_eq!( - ::std::mem::size_of::(), - 16usize, - concat!("Size of: ", stringify!(lldiv_t)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(lldiv_t)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).quot as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(lldiv_t), - "::", - stringify!(quot) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).rem as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(lldiv_t), - "::", - stringify!(rem) - ) - ); -} -extern "C" { - pub static mut __mb_cur_max: ::std::os::raw::c_int; -} -extern "C" { - pub fn malloc(__size: ::std::os::raw::c_ulong) -> *mut ::std::os::raw::c_void; -} -extern "C" { - pub fn calloc( - __count: ::std::os::raw::c_ulong, - __size: ::std::os::raw::c_ulong, - ) -> *mut ::std::os::raw::c_void; -} -extern "C" { - pub fn free(arg1: *mut ::std::os::raw::c_void); -} -extern "C" { - pub fn realloc( - __ptr: *mut ::std::os::raw::c_void, - __size: ::std::os::raw::c_ulong, - ) -> *mut ::std::os::raw::c_void; -} -extern "C" { - pub fn valloc(arg1: usize) -> *mut ::std::os::raw::c_void; -} -extern "C" { - pub fn aligned_alloc(__alignment: usize, __size: usize) -> *mut ::std::os::raw::c_void; -} -extern "C" { - pub fn posix_memalign( - __memptr: *mut *mut ::std::os::raw::c_void, - __alignment: usize, - __size: usize, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn abort(); -} -extern "C" { - pub fn abs(arg1: ::std::os::raw::c_int) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn atexit(arg1: ::std::option::Option) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn atof(arg1: *const ::std::os::raw::c_char) -> f64; -} -extern "C" { - pub fn atoi(arg1: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn atol(arg1: *const ::std::os::raw::c_char) -> ::std::os::raw::c_long; -} -extern "C" { - pub fn atoll(arg1: *const ::std::os::raw::c_char) -> ::std::os::raw::c_longlong; -} -extern "C" { - pub fn bsearch( - __key: *const ::std::os::raw::c_void, - __base: *const ::std::os::raw::c_void, - __nel: usize, - __width: usize, - __compar: ::std::option::Option< - unsafe extern "C" fn( - arg1: *const ::std::os::raw::c_void, - arg2: *const ::std::os::raw::c_void, - ) -> ::std::os::raw::c_int, - >, - ) -> *mut ::std::os::raw::c_void; -} -extern "C" { - pub fn div(arg1: ::std::os::raw::c_int, arg2: ::std::os::raw::c_int) -> div_t; -} -extern "C" { - pub fn exit(arg1: ::std::os::raw::c_int); -} -extern "C" { - pub fn getenv(arg1: *const ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn labs(arg1: ::std::os::raw::c_long) -> ::std::os::raw::c_long; -} -extern "C" { - pub fn ldiv(arg1: ::std::os::raw::c_long, arg2: ::std::os::raw::c_long) -> ldiv_t; -} -extern "C" { - pub fn llabs(arg1: ::std::os::raw::c_longlong) -> ::std::os::raw::c_longlong; -} -extern "C" { - pub fn lldiv(arg1: ::std::os::raw::c_longlong, arg2: ::std::os::raw::c_longlong) -> lldiv_t; -} -extern "C" { - pub fn mblen(__s: *const ::std::os::raw::c_char, __n: usize) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn mbstowcs(arg1: *mut wchar_t, arg2: *const ::std::os::raw::c_char, arg3: usize) -> usize; -} -extern "C" { - pub fn mbtowc( - arg1: *mut wchar_t, - arg2: *const ::std::os::raw::c_char, - arg3: usize, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn qsort( - __base: *mut ::std::os::raw::c_void, - __nel: usize, - __width: usize, - __compar: ::std::option::Option< - unsafe extern "C" fn( - arg1: *const ::std::os::raw::c_void, - arg2: *const ::std::os::raw::c_void, - ) -> ::std::os::raw::c_int, - >, - ); -} -extern "C" { - pub fn rand() -> ::std::os::raw::c_int; -} -extern "C" { - pub fn srand(arg1: ::std::os::raw::c_uint); -} -extern "C" { - pub fn strtod( - arg1: *const ::std::os::raw::c_char, - arg2: *mut *mut ::std::os::raw::c_char, - ) -> f64; -} -extern "C" { - pub fn strtof( - arg1: *const ::std::os::raw::c_char, - arg2: *mut *mut ::std::os::raw::c_char, - ) -> f32; -} -extern "C" { - pub fn strtol( - __str: *const ::std::os::raw::c_char, - __endptr: *mut *mut ::std::os::raw::c_char, - __base: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_long; -} -extern "C" { - pub fn strtold( - arg1: *const ::std::os::raw::c_char, - arg2: *mut *mut ::std::os::raw::c_char, - ) -> u128; -} -extern "C" { - pub fn strtoll( - __str: *const ::std::os::raw::c_char, - __endptr: *mut *mut ::std::os::raw::c_char, - __base: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_longlong; -} -extern "C" { - pub fn strtoul( - __str: *const ::std::os::raw::c_char, - __endptr: *mut *mut ::std::os::raw::c_char, - __base: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_ulong; -} -extern "C" { - pub fn strtoull( - __str: *const ::std::os::raw::c_char, - __endptr: *mut *mut ::std::os::raw::c_char, - __base: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_ulonglong; -} -extern "C" { - pub fn system(arg1: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn wcstombs(arg1: *mut ::std::os::raw::c_char, arg2: *const wchar_t, arg3: usize) -> usize; -} -extern "C" { - pub fn wctomb(arg1: *mut ::std::os::raw::c_char, arg2: wchar_t) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn _Exit(arg1: ::std::os::raw::c_int); -} -extern "C" { - pub fn a64l(arg1: *const ::std::os::raw::c_char) -> ::std::os::raw::c_long; -} -extern "C" { - pub fn drand48() -> f64; -} -extern "C" { - pub fn ecvt( - arg1: f64, - arg2: ::std::os::raw::c_int, - arg3: *mut ::std::os::raw::c_int, - arg4: *mut ::std::os::raw::c_int, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn erand48(arg1: *mut ::std::os::raw::c_ushort) -> f64; -} -extern "C" { - pub fn fcvt( - arg1: f64, - arg2: ::std::os::raw::c_int, - arg3: *mut ::std::os::raw::c_int, - arg4: *mut ::std::os::raw::c_int, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn gcvt( - arg1: f64, - arg2: ::std::os::raw::c_int, - arg3: *mut ::std::os::raw::c_char, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn getsubopt( - arg1: *mut *mut ::std::os::raw::c_char, - arg2: *const *mut ::std::os::raw::c_char, - arg3: *mut *mut ::std::os::raw::c_char, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn grantpt(arg1: ::std::os::raw::c_int) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn initstate( - arg1: ::std::os::raw::c_uint, - arg2: *mut ::std::os::raw::c_char, - arg3: usize, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn jrand48(arg1: *mut ::std::os::raw::c_ushort) -> ::std::os::raw::c_long; -} -extern "C" { - pub fn l64a(arg1: ::std::os::raw::c_long) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn lcong48(arg1: *mut ::std::os::raw::c_ushort); -} -extern "C" { - pub fn lrand48() -> ::std::os::raw::c_long; -} -extern "C" { - pub fn mktemp(arg1: *mut ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn mkstemp(arg1: *mut ::std::os::raw::c_char) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn mrand48() -> ::std::os::raw::c_long; -} -extern "C" { - pub fn nrand48(arg1: *mut ::std::os::raw::c_ushort) -> ::std::os::raw::c_long; -} -extern "C" { - pub fn posix_openpt(arg1: ::std::os::raw::c_int) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn ptsname(arg1: ::std::os::raw::c_int) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn ptsname_r( - fildes: ::std::os::raw::c_int, - buffer: *mut ::std::os::raw::c_char, - buflen: usize, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn putenv(arg1: *mut ::std::os::raw::c_char) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn random() -> ::std::os::raw::c_long; -} -extern "C" { - pub fn rand_r(arg1: *mut ::std::os::raw::c_uint) -> ::std::os::raw::c_int; -} -extern "C" { - #[link_name = "\u{1}_realpath$DARWIN_EXTSN"] - pub fn realpath( - arg1: *const ::std::os::raw::c_char, - arg2: *mut ::std::os::raw::c_char, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn seed48(arg1: *mut ::std::os::raw::c_ushort) -> *mut ::std::os::raw::c_ushort; -} -extern "C" { - pub fn setenv( - __name: *const ::std::os::raw::c_char, - __value: *const ::std::os::raw::c_char, - __overwrite: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn setkey(arg1: *const ::std::os::raw::c_char); -} -extern "C" { - pub fn setstate(arg1: *const ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn srand48(arg1: ::std::os::raw::c_long); -} -extern "C" { - pub fn srandom(arg1: ::std::os::raw::c_uint); -} -extern "C" { - pub fn unlockpt(arg1: ::std::os::raw::c_int) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn unsetenv(arg1: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int; -} -pub type dev_t = __darwin_dev_t; -pub type mode_t = __darwin_mode_t; -extern "C" { - pub fn arc4random() -> u32; -} -extern "C" { - pub fn arc4random_addrandom(arg1: *mut ::std::os::raw::c_uchar, arg2: ::std::os::raw::c_int); -} -extern "C" { - pub fn arc4random_buf(__buf: *mut ::std::os::raw::c_void, __nbytes: usize); -} -extern "C" { - pub fn arc4random_stir(); -} -extern "C" { - pub fn arc4random_uniform(__upper_bound: u32) -> u32; -} -extern "C" { - pub fn atexit_b(arg1: *mut ::std::os::raw::c_void) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn bsearch_b( - __key: *const ::std::os::raw::c_void, - __base: *const ::std::os::raw::c_void, - __nel: usize, - __width: usize, - __compar: *mut ::std::os::raw::c_void, - ) -> *mut ::std::os::raw::c_void; -} -extern "C" { - pub fn cgetcap( - arg1: *mut ::std::os::raw::c_char, - arg2: *const ::std::os::raw::c_char, - arg3: ::std::os::raw::c_int, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn cgetclose() -> ::std::os::raw::c_int; -} -extern "C" { - pub fn cgetent( - arg1: *mut *mut ::std::os::raw::c_char, - arg2: *mut *mut ::std::os::raw::c_char, - arg3: *const ::std::os::raw::c_char, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn cgetfirst( - arg1: *mut *mut ::std::os::raw::c_char, - arg2: *mut *mut ::std::os::raw::c_char, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn cgetmatch( - arg1: *const ::std::os::raw::c_char, - arg2: *const ::std::os::raw::c_char, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn cgetnext( - arg1: *mut *mut ::std::os::raw::c_char, - arg2: *mut *mut ::std::os::raw::c_char, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn cgetnum( - arg1: *mut ::std::os::raw::c_char, - arg2: *const ::std::os::raw::c_char, - arg3: *mut ::std::os::raw::c_long, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn cgetset(arg1: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn cgetstr( - arg1: *mut ::std::os::raw::c_char, - arg2: *const ::std::os::raw::c_char, - arg3: *mut *mut ::std::os::raw::c_char, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn cgetustr( - arg1: *mut ::std::os::raw::c_char, - arg2: *const ::std::os::raw::c_char, - arg3: *mut *mut ::std::os::raw::c_char, - ) -> ::std::os::raw::c_int; -} -extern "C" { - #[link_name = "\u{1}_daemon$1050"] - pub fn daemon( - arg1: ::std::os::raw::c_int, - arg2: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn devname(arg1: dev_t, arg2: mode_t) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn devname_r( - arg1: dev_t, - arg2: mode_t, - buf: *mut ::std::os::raw::c_char, - len: ::std::os::raw::c_int, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn getbsize( - arg1: *mut ::std::os::raw::c_int, - arg2: *mut ::std::os::raw::c_long, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn getloadavg(arg1: *mut f64, arg2: ::std::os::raw::c_int) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn getprogname() -> *const ::std::os::raw::c_char; -} -extern "C" { - pub fn setprogname(arg1: *const ::std::os::raw::c_char); -} -extern "C" { - pub fn heapsort( - __base: *mut ::std::os::raw::c_void, - __nel: usize, - __width: usize, - __compar: ::std::option::Option< - unsafe extern "C" fn( - arg1: *const ::std::os::raw::c_void, - arg2: *const ::std::os::raw::c_void, - ) -> ::std::os::raw::c_int, - >, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn heapsort_b( - __base: *mut ::std::os::raw::c_void, - __nel: usize, - __width: usize, - __compar: *mut ::std::os::raw::c_void, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn mergesort( - __base: *mut ::std::os::raw::c_void, - __nel: usize, - __width: usize, - __compar: ::std::option::Option< - unsafe extern "C" fn( - arg1: *const ::std::os::raw::c_void, - arg2: *const ::std::os::raw::c_void, - ) -> ::std::os::raw::c_int, - >, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn mergesort_b( - __base: *mut ::std::os::raw::c_void, - __nel: usize, - __width: usize, - __compar: *mut ::std::os::raw::c_void, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn psort( - __base: *mut ::std::os::raw::c_void, - __nel: usize, - __width: usize, - __compar: ::std::option::Option< - unsafe extern "C" fn( - arg1: *const ::std::os::raw::c_void, - arg2: *const ::std::os::raw::c_void, - ) -> ::std::os::raw::c_int, - >, - ); -} -extern "C" { - pub fn psort_b( - __base: *mut ::std::os::raw::c_void, - __nel: usize, - __width: usize, - __compar: *mut ::std::os::raw::c_void, - ); -} -extern "C" { - pub fn psort_r( - __base: *mut ::std::os::raw::c_void, - __nel: usize, - __width: usize, - arg1: *mut ::std::os::raw::c_void, - __compar: ::std::option::Option< - unsafe extern "C" fn( - arg1: *mut ::std::os::raw::c_void, - arg2: *const ::std::os::raw::c_void, - arg3: *const ::std::os::raw::c_void, - ) -> ::std::os::raw::c_int, - >, - ); -} -extern "C" { - pub fn qsort_b( - __base: *mut ::std::os::raw::c_void, - __nel: usize, - __width: usize, - __compar: *mut ::std::os::raw::c_void, - ); -} -extern "C" { - pub fn qsort_r( - __base: *mut ::std::os::raw::c_void, - __nel: usize, - __width: usize, - arg1: *mut ::std::os::raw::c_void, - __compar: ::std::option::Option< - unsafe extern "C" fn( - arg1: *mut ::std::os::raw::c_void, - arg2: *const ::std::os::raw::c_void, - arg3: *const ::std::os::raw::c_void, - ) -> ::std::os::raw::c_int, - >, - ); -} -extern "C" { - pub fn radixsort( - __base: *mut *const ::std::os::raw::c_uchar, - __nel: ::std::os::raw::c_int, - __table: *const ::std::os::raw::c_uchar, - __endbyte: ::std::os::raw::c_uint, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn rpmatch(arg1: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn sradixsort( - __base: *mut *const ::std::os::raw::c_uchar, - __nel: ::std::os::raw::c_int, - __table: *const ::std::os::raw::c_uchar, - __endbyte: ::std::os::raw::c_uint, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn sranddev(); -} -extern "C" { - pub fn srandomdev(); -} -extern "C" { - pub fn reallocf( - __ptr: *mut ::std::os::raw::c_void, - __size: usize, - ) -> *mut ::std::os::raw::c_void; -} -extern "C" { - pub fn strtonum( - __numstr: *const ::std::os::raw::c_char, - __minval: ::std::os::raw::c_longlong, - __maxval: ::std::os::raw::c_longlong, - __errstrp: *mut *const ::std::os::raw::c_char, - ) -> ::std::os::raw::c_longlong; -} -extern "C" { - pub fn strtoq( - __str: *const ::std::os::raw::c_char, - __endptr: *mut *mut ::std::os::raw::c_char, - __base: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_longlong; -} -extern "C" { - pub fn strtouq( - __str: *const ::std::os::raw::c_char, - __endptr: *mut *mut ::std::os::raw::c_char, - __base: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_ulonglong; -} -extern "C" { - pub static mut suboptarg: *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn memchr( - __s: *const ::std::os::raw::c_void, - __c: ::std::os::raw::c_int, - __n: ::std::os::raw::c_ulong, - ) -> *mut ::std::os::raw::c_void; -} -extern "C" { - pub fn memcmp( - __s1: *const ::std::os::raw::c_void, - __s2: *const ::std::os::raw::c_void, - __n: ::std::os::raw::c_ulong, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn memcpy( - __dst: *mut ::std::os::raw::c_void, - __src: *const ::std::os::raw::c_void, - __n: ::std::os::raw::c_ulong, - ) -> *mut ::std::os::raw::c_void; -} -extern "C" { - pub fn memmove( - __dst: *mut ::std::os::raw::c_void, - __src: *const ::std::os::raw::c_void, - __len: ::std::os::raw::c_ulong, - ) -> *mut ::std::os::raw::c_void; -} -extern "C" { - pub fn memset( - __b: *mut ::std::os::raw::c_void, - __c: ::std::os::raw::c_int, - __len: ::std::os::raw::c_ulong, - ) -> *mut ::std::os::raw::c_void; -} -extern "C" { - pub fn strcat( - __s1: *mut ::std::os::raw::c_char, - __s2: *const ::std::os::raw::c_char, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strchr( - __s: *const ::std::os::raw::c_char, - __c: ::std::os::raw::c_int, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strcmp( - __s1: *const ::std::os::raw::c_char, - __s2: *const ::std::os::raw::c_char, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn strcoll( - __s1: *const ::std::os::raw::c_char, - __s2: *const ::std::os::raw::c_char, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn strcpy( - __dst: *mut ::std::os::raw::c_char, - __src: *const ::std::os::raw::c_char, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strcspn( - __s: *const ::std::os::raw::c_char, - __charset: *const ::std::os::raw::c_char, - ) -> ::std::os::raw::c_ulong; -} -extern "C" { - pub fn strerror(__errnum: ::std::os::raw::c_int) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strlen(__s: *const ::std::os::raw::c_char) -> ::std::os::raw::c_ulong; -} -extern "C" { - pub fn strncat( - __s1: *mut ::std::os::raw::c_char, - __s2: *const ::std::os::raw::c_char, - __n: ::std::os::raw::c_ulong, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strncmp( - __s1: *const ::std::os::raw::c_char, - __s2: *const ::std::os::raw::c_char, - __n: ::std::os::raw::c_ulong, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn strncpy( - __dst: *mut ::std::os::raw::c_char, - __src: *const ::std::os::raw::c_char, - __n: ::std::os::raw::c_ulong, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strpbrk( - __s: *const ::std::os::raw::c_char, - __charset: *const ::std::os::raw::c_char, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strrchr( - __s: *const ::std::os::raw::c_char, - __c: ::std::os::raw::c_int, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strspn( - __s: *const ::std::os::raw::c_char, - __charset: *const ::std::os::raw::c_char, - ) -> ::std::os::raw::c_ulong; -} -extern "C" { - pub fn strstr( - __big: *const ::std::os::raw::c_char, - __little: *const ::std::os::raw::c_char, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strtok( - __str: *mut ::std::os::raw::c_char, - __sep: *const ::std::os::raw::c_char, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strxfrm( - __s1: *mut ::std::os::raw::c_char, - __s2: *const ::std::os::raw::c_char, - __n: ::std::os::raw::c_ulong, - ) -> ::std::os::raw::c_ulong; -} -extern "C" { - pub fn strtok_r( - __str: *mut ::std::os::raw::c_char, - __sep: *const ::std::os::raw::c_char, - __lasts: *mut *mut ::std::os::raw::c_char, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strerror_r( - __errnum: ::std::os::raw::c_int, - __strerrbuf: *mut ::std::os::raw::c_char, - __buflen: usize, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn strdup(__s1: *const ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn memccpy( - __dst: *mut ::std::os::raw::c_void, - __src: *const ::std::os::raw::c_void, - __c: ::std::os::raw::c_int, - __n: ::std::os::raw::c_ulong, - ) -> *mut ::std::os::raw::c_void; -} -extern "C" { - pub fn stpcpy( - __dst: *mut ::std::os::raw::c_char, - __src: *const ::std::os::raw::c_char, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn stpncpy( - __dst: *mut ::std::os::raw::c_char, - __src: *const ::std::os::raw::c_char, - __n: ::std::os::raw::c_ulong, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strndup( - __s1: *const ::std::os::raw::c_char, - __n: ::std::os::raw::c_ulong, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strnlen(__s1: *const ::std::os::raw::c_char, __n: usize) -> usize; -} -extern "C" { - pub fn strsignal(__sig: ::std::os::raw::c_int) -> *mut ::std::os::raw::c_char; -} -pub type rsize_t = __darwin_size_t; -pub type errno_t = ::std::os::raw::c_int; -extern "C" { - pub fn memset_s( - __s: *mut ::std::os::raw::c_void, - __smax: rsize_t, - __c: ::std::os::raw::c_int, - __n: rsize_t, - ) -> errno_t; -} -extern "C" { - pub fn memmem( - __big: *const ::std::os::raw::c_void, - __big_len: usize, - __little: *const ::std::os::raw::c_void, - __little_len: usize, - ) -> *mut ::std::os::raw::c_void; -} -extern "C" { - pub fn memset_pattern4( - __b: *mut ::std::os::raw::c_void, - __pattern4: *const ::std::os::raw::c_void, - __len: usize, - ); -} -extern "C" { - pub fn memset_pattern8( - __b: *mut ::std::os::raw::c_void, - __pattern8: *const ::std::os::raw::c_void, - __len: usize, - ); -} -extern "C" { - pub fn memset_pattern16( - __b: *mut ::std::os::raw::c_void, - __pattern16: *const ::std::os::raw::c_void, - __len: usize, - ); -} -extern "C" { - pub fn strcasestr( - __big: *const ::std::os::raw::c_char, - __little: *const ::std::os::raw::c_char, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strnstr( - __big: *const ::std::os::raw::c_char, - __little: *const ::std::os::raw::c_char, - __len: usize, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn strlcat( - __dst: *mut ::std::os::raw::c_char, - __source: *const ::std::os::raw::c_char, - __size: ::std::os::raw::c_ulong, - ) -> ::std::os::raw::c_ulong; -} -extern "C" { - pub fn strlcpy( - __dst: *mut ::std::os::raw::c_char, - __source: *const ::std::os::raw::c_char, - __size: ::std::os::raw::c_ulong, - ) -> ::std::os::raw::c_ulong; -} -extern "C" { - pub fn strmode(__mode: ::std::os::raw::c_int, __bp: *mut ::std::os::raw::c_char); -} -extern "C" { - pub fn strsep( - __stringp: *mut *mut ::std::os::raw::c_char, - __delim: *const ::std::os::raw::c_char, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn swab( - arg1: *const ::std::os::raw::c_void, - arg2: *mut ::std::os::raw::c_void, - arg3: isize, - ); -} -extern "C" { - pub fn timingsafe_bcmp( - __b1: *const ::std::os::raw::c_void, - __b2: *const ::std::os::raw::c_void, - __len: usize, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn strsignal_r( - __sig: ::std::os::raw::c_int, - __strsignalbuf: *mut ::std::os::raw::c_char, - __buflen: usize, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn bcmp( - arg1: *const ::std::os::raw::c_void, - arg2: *const ::std::os::raw::c_void, - arg3: ::std::os::raw::c_ulong, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn bcopy( - arg1: *const ::std::os::raw::c_void, - arg2: *mut ::std::os::raw::c_void, - arg3: usize, - ); -} -extern "C" { - pub fn bzero(arg1: *mut ::std::os::raw::c_void, arg2: ::std::os::raw::c_ulong); -} -extern "C" { - pub fn index( - arg1: *const ::std::os::raw::c_char, - arg2: ::std::os::raw::c_int, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn rindex( - arg1: *const ::std::os::raw::c_char, - arg2: ::std::os::raw::c_int, - ) -> *mut ::std::os::raw::c_char; -} -extern "C" { - pub fn ffs(arg1: ::std::os::raw::c_int) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn strcasecmp( - arg1: *const ::std::os::raw::c_char, - arg2: *const ::std::os::raw::c_char, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn strncasecmp( - arg1: *const ::std::os::raw::c_char, - arg2: *const ::std::os::raw::c_char, - arg3: ::std::os::raw::c_ulong, - ) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn ffsl(arg1: ::std::os::raw::c_long) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn ffsll(arg1: ::std::os::raw::c_longlong) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn fls(arg1: ::std::os::raw::c_int) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn flsl(arg1: ::std::os::raw::c_long) -> ::std::os::raw::c_int; -} -extern "C" { - pub fn flsll(arg1: ::std::os::raw::c_longlong) -> ::std::os::raw::c_int; -} -#[repr(u32)] -#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum ONNXTensorElementDataType { - ONNX_TENSOR_ELEMENT_DATA_TYPE_UNDEFINED = 0, - ONNX_TENSOR_ELEMENT_DATA_TYPE_FLOAT = 1, - ONNX_TENSOR_ELEMENT_DATA_TYPE_UINT8 = 2, - ONNX_TENSOR_ELEMENT_DATA_TYPE_INT8 = 3, - ONNX_TENSOR_ELEMENT_DATA_TYPE_UINT16 = 4, - ONNX_TENSOR_ELEMENT_DATA_TYPE_INT16 = 5, - ONNX_TENSOR_ELEMENT_DATA_TYPE_INT32 = 6, - ONNX_TENSOR_ELEMENT_DATA_TYPE_INT64 = 7, - ONNX_TENSOR_ELEMENT_DATA_TYPE_STRING = 8, - ONNX_TENSOR_ELEMENT_DATA_TYPE_BOOL = 9, - ONNX_TENSOR_ELEMENT_DATA_TYPE_FLOAT16 = 10, - ONNX_TENSOR_ELEMENT_DATA_TYPE_DOUBLE = 11, - ONNX_TENSOR_ELEMENT_DATA_TYPE_UINT32 = 12, - ONNX_TENSOR_ELEMENT_DATA_TYPE_UINT64 = 13, - ONNX_TENSOR_ELEMENT_DATA_TYPE_COMPLEX64 = 14, - ONNX_TENSOR_ELEMENT_DATA_TYPE_COMPLEX128 = 15, - ONNX_TENSOR_ELEMENT_DATA_TYPE_BFLOAT16 = 16, -} -#[repr(u32)] -#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum ONNXType { - ONNX_TYPE_UNKNOWN = 0, - ONNX_TYPE_TENSOR = 1, - ONNX_TYPE_SEQUENCE = 2, - ONNX_TYPE_MAP = 3, - ONNX_TYPE_OPAQUE = 4, - ONNX_TYPE_SPARSETENSOR = 5, -} -#[repr(u32)] -#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum OrtLoggingLevel { - ORT_LOGGING_LEVEL_VERBOSE = 0, - ORT_LOGGING_LEVEL_INFO = 1, - ORT_LOGGING_LEVEL_WARNING = 2, - ORT_LOGGING_LEVEL_ERROR = 3, - ORT_LOGGING_LEVEL_FATAL = 4, -} -#[repr(u32)] -#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum OrtErrorCode { - ORT_OK = 0, - ORT_FAIL = 1, - ORT_INVALID_ARGUMENT = 2, - ORT_NO_SUCHFILE = 3, - ORT_NO_MODEL = 4, - ORT_ENGINE_ERROR = 5, - ORT_RUNTIME_EXCEPTION = 6, - ORT_INVALID_PROTOBUF = 7, - ORT_MODEL_LOADED = 8, - ORT_NOT_IMPLEMENTED = 9, - ORT_INVALID_GRAPH = 10, - ORT_EP_FAIL = 11, -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtEnv { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtStatus { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtMemoryInfo { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtIoBinding { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtSession { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtValue { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtRunOptions { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtTypeInfo { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtTensorTypeAndShapeInfo { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtSessionOptions { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtCustomOpDomain { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtMapTypeInfo { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtSequenceTypeInfo { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtModelMetadata { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtThreadPoolParams { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtThreadingOptions { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtArenaCfg { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtPrepackedWeightsContainer { - _unused: [u8; 0], -} -pub type OrtStatusPtr = *mut OrtStatus; -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtAllocator { - pub version: u32, - pub Alloc: ::std::option::Option< - unsafe extern "C" fn(this_: *mut OrtAllocator, size: usize) -> *mut ::std::os::raw::c_void, - >, - pub Free: ::std::option::Option< - unsafe extern "C" fn(this_: *mut OrtAllocator, p: *mut ::std::os::raw::c_void), - >, - pub Info: ::std::option::Option< - unsafe extern "C" fn(this_: *const OrtAllocator) -> *const OrtMemoryInfo, - >, -} -#[test] -fn bindgen_test_layout_OrtAllocator() { - assert_eq!( - ::std::mem::size_of::(), - 32usize, - concat!("Size of: ", stringify!(OrtAllocator)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(OrtAllocator)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).version as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtAllocator), - "::", - stringify!(version) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).Alloc as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtAllocator), - "::", - stringify!(Alloc) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).Free as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(OrtAllocator), - "::", - stringify!(Free) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).Info as *const _ as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(OrtAllocator), - "::", - stringify!(Info) - ) - ); -} -pub type OrtLoggingFunction = ::std::option::Option< - unsafe extern "C" fn( - param: *mut ::std::os::raw::c_void, - severity: OrtLoggingLevel, - category: *const ::std::os::raw::c_char, - logid: *const ::std::os::raw::c_char, - code_location: *const ::std::os::raw::c_char, - message: *const ::std::os::raw::c_char, - ), ->; -#[repr(u32)] -#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum GraphOptimizationLevel { - ORT_DISABLE_ALL = 0, - ORT_ENABLE_BASIC = 1, - ORT_ENABLE_EXTENDED = 2, - ORT_ENABLE_ALL = 99, -} -#[repr(u32)] -#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum ExecutionMode { - ORT_SEQUENTIAL = 0, - ORT_PARALLEL = 1, -} -#[repr(u32)] -#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum OrtLanguageProjection { - ORT_PROJECTION_C = 0, - ORT_PROJECTION_CPLUSPLUS = 1, - ORT_PROJECTION_CSHARP = 2, - ORT_PROJECTION_PYTHON = 3, - ORT_PROJECTION_JAVA = 4, - ORT_PROJECTION_WINML = 5, - ORT_PROJECTION_NODEJS = 6, -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtKernelInfo { - _unused: [u8; 0], -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtKernelContext { - _unused: [u8; 0], -} -#[repr(i32)] -#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum OrtAllocatorType { - Invalid = -1, - OrtDeviceAllocator = 0, - OrtArenaAllocator = 1, -} -impl OrtMemType { - pub const OrtMemTypeCPU: OrtMemType = OrtMemType::OrtMemTypeCPUOutput; -} -#[repr(i32)] -#[doc = " memory types for allocator, exec provider specific types should be extended in each provider"] -#[doc = " Whenever this struct is updated, please also update the MakeKey function in onnxruntime/core/framework/execution_provider.cc"] -#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum OrtMemType { - OrtMemTypeCPUInput = -2, - OrtMemTypeCPUOutput = -1, - OrtMemTypeDefault = 0, -} -#[repr(u32)] -#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] -pub enum OrtCudnnConvAlgoSearch { - EXHAUSTIVE = 0, - HEURISTIC = 1, - DEFAULT = 2, -} -#[doc = " "] -#[doc = " Options for the CUDA provider that are passed to SessionOptionsAppendExecutionProvider_CUDA"] -#[doc = " "] -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtCUDAProviderOptions { - pub device_id: ::std::os::raw::c_int, - pub cudnn_conv_algo_search: OrtCudnnConvAlgoSearch, - pub gpu_mem_limit: usize, - pub arena_extend_strategy: ::std::os::raw::c_int, - pub do_copy_in_default_stream: ::std::os::raw::c_int, - pub has_user_compute_stream: ::std::os::raw::c_int, - pub user_compute_stream: *mut ::std::os::raw::c_void, - pub default_memory_arena_cfg: *mut OrtArenaCfg, -} -#[test] -fn bindgen_test_layout_OrtCUDAProviderOptions() { - assert_eq!( - ::std::mem::size_of::(), - 48usize, - concat!("Size of: ", stringify!(OrtCUDAProviderOptions)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(OrtCUDAProviderOptions)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).device_id as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(device_id) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).cudnn_conv_algo_search as *const _ - as usize - }, - 4usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(cudnn_conv_algo_search) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).gpu_mem_limit as *const _ as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(gpu_mem_limit) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).arena_extend_strategy as *const _ - as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(arena_extend_strategy) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).do_copy_in_default_stream as *const _ - as usize - }, - 20usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(do_copy_in_default_stream) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).has_user_compute_stream as *const _ - as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(has_user_compute_stream) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).user_compute_stream as *const _ - as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(user_compute_stream) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).default_memory_arena_cfg as *const _ - as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(default_memory_arena_cfg) - ) - ); -} -#[doc = " "] -#[doc = " Options for the ROCM provider that are passed to SessionOptionsAppendExecutionProvider_ROCM"] -#[doc = " "] -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtROCMProviderOptions { - pub device_id: ::std::os::raw::c_int, - pub miopen_conv_exhaustive_search: ::std::os::raw::c_int, - pub gpu_mem_limit: usize, - pub arena_extend_strategy: ::std::os::raw::c_int, -} -#[test] -fn bindgen_test_layout_OrtROCMProviderOptions() { - assert_eq!( - ::std::mem::size_of::(), - 24usize, - concat!("Size of: ", stringify!(OrtROCMProviderOptions)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(OrtROCMProviderOptions)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).device_id as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtROCMProviderOptions), - "::", - stringify!(device_id) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).miopen_conv_exhaustive_search - as *const _ as usize - }, - 4usize, - concat!( - "Offset of field: ", - stringify!(OrtROCMProviderOptions), - "::", - stringify!(miopen_conv_exhaustive_search) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).gpu_mem_limit as *const _ as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtROCMProviderOptions), - "::", - stringify!(gpu_mem_limit) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).arena_extend_strategy as *const _ - as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(OrtROCMProviderOptions), - "::", - stringify!(arena_extend_strategy) - ) - ); -} -#[doc = " "] -#[doc = " Options for the TensorRT provider that are passed to SessionOptionsAppendExecutionProvider_TensorRT"] -#[doc = " "] -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtTensorRTProviderOptions { - pub device_id: ::std::os::raw::c_int, - pub has_user_compute_stream: ::std::os::raw::c_int, - pub user_compute_stream: *mut ::std::os::raw::c_void, - pub trt_max_partition_iterations: ::std::os::raw::c_int, - pub trt_min_subgraph_size: ::std::os::raw::c_int, - pub trt_max_workspace_size: usize, - pub trt_fp16_enable: ::std::os::raw::c_int, - pub trt_int8_enable: ::std::os::raw::c_int, - pub trt_int8_calibration_table_name: *const ::std::os::raw::c_char, - pub trt_int8_use_native_calibration_table: ::std::os::raw::c_int, - pub trt_dla_enable: ::std::os::raw::c_int, - pub trt_dla_core: ::std::os::raw::c_int, - pub trt_dump_subgraphs: ::std::os::raw::c_int, - pub trt_engine_cache_enable: ::std::os::raw::c_int, - pub trt_engine_cache_path: *const ::std::os::raw::c_char, - pub trt_engine_decryption_enable: ::std::os::raw::c_int, - pub trt_engine_decryption_lib_path: *const ::std::os::raw::c_char, - pub trt_force_sequential_engine_build: ::std::os::raw::c_int, -} -#[test] -fn bindgen_test_layout_OrtTensorRTProviderOptions() { - assert_eq!( - ::std::mem::size_of::(), - 104usize, - concat!("Size of: ", stringify!(OrtTensorRTProviderOptions)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(OrtTensorRTProviderOptions)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).device_id as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(device_id) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).has_user_compute_stream - as *const _ as usize - }, - 4usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(has_user_compute_stream) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).user_compute_stream as *const _ - as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(user_compute_stream) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_max_partition_iterations - as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_max_partition_iterations) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_min_subgraph_size as *const _ - as usize - }, - 20usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_min_subgraph_size) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_max_workspace_size - as *const _ as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_max_workspace_size) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_fp16_enable as *const _ - as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_fp16_enable) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_int8_enable as *const _ - as usize - }, - 36usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_int8_enable) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_int8_calibration_table_name - as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_int8_calibration_table_name) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())) - .trt_int8_use_native_calibration_table as *const _ as usize - }, - 48usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_int8_use_native_calibration_table) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_dla_enable as *const _ - as usize - }, - 52usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_dla_enable) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_dla_core as *const _ as usize - }, - 56usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_dla_core) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_dump_subgraphs as *const _ - as usize - }, - 60usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_dump_subgraphs) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_engine_cache_enable - as *const _ as usize - }, - 64usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_engine_cache_enable) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_engine_cache_path as *const _ - as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_engine_cache_path) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_engine_decryption_enable - as *const _ as usize - }, - 80usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_engine_decryption_enable) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_engine_decryption_lib_path - as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_engine_decryption_lib_path) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_force_sequential_engine_build - as *const _ as usize - }, - 96usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_force_sequential_engine_build) - ) - ); -} -#[doc = " "] -#[doc = " Options for the OpenVINO provider that are passed to SessionOptionsAppendExecutionProvider_OpenVINO"] -#[doc = " "] -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtOpenVINOProviderOptions { - pub device_type: *const ::std::os::raw::c_char, - pub enable_vpu_fast_compile: ::std::os::raw::c_uchar, - pub device_id: *const ::std::os::raw::c_char, - pub num_of_threads: usize, - pub use_compiled_network: ::std::os::raw::c_uchar, - pub blob_dump_path: *const ::std::os::raw::c_char, -} -#[test] -fn bindgen_test_layout_OrtOpenVINOProviderOptions() { - assert_eq!( - ::std::mem::size_of::(), - 48usize, - concat!("Size of: ", stringify!(OrtOpenVINOProviderOptions)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(OrtOpenVINOProviderOptions)) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).device_type as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtOpenVINOProviderOptions), - "::", - stringify!(device_type) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).enable_vpu_fast_compile - as *const _ as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtOpenVINOProviderOptions), - "::", - stringify!(enable_vpu_fast_compile) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).device_id as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(OrtOpenVINOProviderOptions), - "::", - stringify!(device_id) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).num_of_threads as *const _ - as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(OrtOpenVINOProviderOptions), - "::", - stringify!(num_of_threads) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).use_compiled_network as *const _ - as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(OrtOpenVINOProviderOptions), - "::", - stringify!(use_compiled_network) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).blob_dump_path as *const _ - as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(OrtOpenVINOProviderOptions), - "::", - stringify!(blob_dump_path) - ) - ); -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtApiBase { - pub GetApi: ::std::option::Option *const OrtApi>, - pub GetVersionString: - ::std::option::Option *const ::std::os::raw::c_char>, -} -#[test] -fn bindgen_test_layout_OrtApiBase() { - assert_eq!( - ::std::mem::size_of::(), - 16usize, - concat!("Size of: ", stringify!(OrtApiBase)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(OrtApiBase)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetApi as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtApiBase), - "::", - stringify!(GetApi) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetVersionString as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtApiBase), - "::", - stringify!(GetVersionString) - ) - ); -} -extern "C" { - pub fn OrtGetApiBase() -> *const OrtApiBase; -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct OrtApi { - #[doc = " \\param msg A null-terminated string. Its content will be copied into the newly created OrtStatus"] - pub CreateStatus: ::std::option::Option< - unsafe extern "C" fn( - code: OrtErrorCode, - msg: *const ::std::os::raw::c_char, - ) -> *mut OrtStatus, - >, - pub GetErrorCode: - ::std::option::Option OrtErrorCode>, - #[doc = " \\param status must not be NULL"] - #[doc = " \\return The error message inside the `status`. Do not free the returned value."] - pub GetErrorMessage: ::std::option::Option< - unsafe extern "C" fn(status: *const OrtStatus) -> *const ::std::os::raw::c_char, - >, - pub CreateEnv: ::std::option::Option< - unsafe extern "C" fn( - logging_level: OrtLoggingLevel, - logid: *const ::std::os::raw::c_char, - out: *mut *mut OrtEnv, - ) -> OrtStatusPtr, - >, - pub CreateEnvWithCustomLogger: ::std::option::Option< - unsafe extern "C" fn( - logging_function: OrtLoggingFunction, - logger_param: *mut ::std::os::raw::c_void, - logging_level: OrtLoggingLevel, - logid: *const ::std::os::raw::c_char, - out: *mut *mut OrtEnv, - ) -> OrtStatusPtr, - >, - pub EnableTelemetryEvents: - ::std::option::Option OrtStatusPtr>, - pub DisableTelemetryEvents: - ::std::option::Option OrtStatusPtr>, - pub CreateSession: ::std::option::Option< - unsafe extern "C" fn( - env: *const OrtEnv, - model_path: *const ::std::os::raw::c_char, - options: *const OrtSessionOptions, - out: *mut *mut OrtSession, - ) -> OrtStatusPtr, - >, - pub CreateSessionFromArray: ::std::option::Option< - unsafe extern "C" fn( - env: *const OrtEnv, - model_data: *const ::std::os::raw::c_void, - model_data_length: usize, - options: *const OrtSessionOptions, - out: *mut *mut OrtSession, - ) -> OrtStatusPtr, - >, - pub Run: ::std::option::Option< - unsafe extern "C" fn( - sess: *mut OrtSession, - run_options: *const OrtRunOptions, - input_names: *const *const ::std::os::raw::c_char, - input: *const *const OrtValue, - input_len: usize, - output_names1: *const *const ::std::os::raw::c_char, - output_names_len: usize, - output: *mut *mut OrtValue, - ) -> OrtStatusPtr, - >, - pub CreateSessionOptions: ::std::option::Option< - unsafe extern "C" fn(options: *mut *mut OrtSessionOptions) -> OrtStatusPtr, - >, - pub SetOptimizedModelFilePath: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - optimized_model_filepath: *const ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub CloneSessionOptions: ::std::option::Option< - unsafe extern "C" fn( - in_options: *const OrtSessionOptions, - out_options: *mut *mut OrtSessionOptions, - ) -> OrtStatusPtr, - >, - pub SetSessionExecutionMode: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - execution_mode: ExecutionMode, - ) -> OrtStatusPtr, - >, - pub EnableProfiling: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - profile_file_prefix: *const ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub DisableProfiling: ::std::option::Option< - unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, - >, - pub EnableMemPattern: ::std::option::Option< - unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, - >, - pub DisableMemPattern: ::std::option::Option< - unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, - >, - pub EnableCpuMemArena: ::std::option::Option< - unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, - >, - pub DisableCpuMemArena: ::std::option::Option< - unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, - >, - pub SetSessionLogId: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - logid: *const ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub SetSessionLogVerbosityLevel: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - session_log_verbosity_level: ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub SetSessionLogSeverityLevel: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - session_log_severity_level: ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub SetSessionGraphOptimizationLevel: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - graph_optimization_level: GraphOptimizationLevel, - ) -> OrtStatusPtr, - >, - pub SetIntraOpNumThreads: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - intra_op_num_threads: ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub SetInterOpNumThreads: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - inter_op_num_threads: ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub CreateCustomOpDomain: ::std::option::Option< - unsafe extern "C" fn( - domain: *const ::std::os::raw::c_char, - out: *mut *mut OrtCustomOpDomain, - ) -> OrtStatusPtr, - >, - pub CustomOpDomain_Add: ::std::option::Option< - unsafe extern "C" fn( - custom_op_domain: *mut OrtCustomOpDomain, - op: *const OrtCustomOp, - ) -> OrtStatusPtr, - >, - pub AddCustomOpDomain: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - custom_op_domain: *mut OrtCustomOpDomain, - ) -> OrtStatusPtr, - >, - pub RegisterCustomOpsLibrary: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - library_path: *const ::std::os::raw::c_char, - library_handle: *mut *mut ::std::os::raw::c_void, - ) -> OrtStatusPtr, - >, - pub SessionGetInputCount: ::std::option::Option< - unsafe extern "C" fn(sess: *const OrtSession, out: *mut usize) -> OrtStatusPtr, - >, - pub SessionGetOutputCount: ::std::option::Option< - unsafe extern "C" fn(sess: *const OrtSession, out: *mut usize) -> OrtStatusPtr, - >, - pub SessionGetOverridableInitializerCount: ::std::option::Option< - unsafe extern "C" fn(sess: *const OrtSession, out: *mut usize) -> OrtStatusPtr, - >, - pub SessionGetInputTypeInfo: ::std::option::Option< - unsafe extern "C" fn( - sess: *const OrtSession, - index: usize, - type_info: *mut *mut OrtTypeInfo, - ) -> OrtStatusPtr, - >, - pub SessionGetOutputTypeInfo: ::std::option::Option< - unsafe extern "C" fn( - sess: *const OrtSession, - index: usize, - type_info: *mut *mut OrtTypeInfo, - ) -> OrtStatusPtr, - >, - pub SessionGetOverridableInitializerTypeInfo: ::std::option::Option< - unsafe extern "C" fn( - sess: *const OrtSession, - index: usize, - type_info: *mut *mut OrtTypeInfo, - ) -> OrtStatusPtr, - >, - pub SessionGetInputName: ::std::option::Option< - unsafe extern "C" fn( - sess: *const OrtSession, - index: usize, - allocator: *mut OrtAllocator, - value: *mut *mut ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub SessionGetOutputName: ::std::option::Option< - unsafe extern "C" fn( - sess: *const OrtSession, - index: usize, - allocator: *mut OrtAllocator, - value: *mut *mut ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub SessionGetOverridableInitializerName: ::std::option::Option< - unsafe extern "C" fn( - sess: *const OrtSession, - index: usize, - allocator: *mut OrtAllocator, - value: *mut *mut ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub CreateRunOptions: - ::std::option::Option OrtStatusPtr>, - pub RunOptionsSetRunLogVerbosityLevel: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtRunOptions, - value: ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub RunOptionsSetRunLogSeverityLevel: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtRunOptions, - value: ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub RunOptionsSetRunTag: ::std::option::Option< - unsafe extern "C" fn( - arg1: *mut OrtRunOptions, - run_tag: *const ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub RunOptionsGetRunLogVerbosityLevel: ::std::option::Option< - unsafe extern "C" fn( - options: *const OrtRunOptions, - out: *mut ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub RunOptionsGetRunLogSeverityLevel: ::std::option::Option< - unsafe extern "C" fn( - options: *const OrtRunOptions, - out: *mut ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub RunOptionsGetRunTag: ::std::option::Option< - unsafe extern "C" fn( - arg1: *const OrtRunOptions, - out: *mut *const ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub RunOptionsSetTerminate: - ::std::option::Option OrtStatusPtr>, - pub RunOptionsUnsetTerminate: - ::std::option::Option OrtStatusPtr>, - pub CreateTensorAsOrtValue: ::std::option::Option< - unsafe extern "C" fn( - allocator: *mut OrtAllocator, - shape: *const i64, - shape_len: usize, - type_: ONNXTensorElementDataType, - out: *mut *mut OrtValue, - ) -> OrtStatusPtr, - >, - pub CreateTensorWithDataAsOrtValue: ::std::option::Option< - unsafe extern "C" fn( - info: *const OrtMemoryInfo, - p_data: *mut ::std::os::raw::c_void, - p_data_len: usize, - shape: *const i64, - shape_len: usize, - type_: ONNXTensorElementDataType, - out: *mut *mut OrtValue, - ) -> OrtStatusPtr, - >, - pub IsTensor: ::std::option::Option< - unsafe extern "C" fn( - value: *const OrtValue, - out: *mut ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub GetTensorMutableData: ::std::option::Option< - unsafe extern "C" fn( - value: *mut OrtValue, - out: *mut *mut ::std::os::raw::c_void, - ) -> OrtStatusPtr, - >, - pub FillStringTensor: ::std::option::Option< - unsafe extern "C" fn( - value: *mut OrtValue, - s: *const *const ::std::os::raw::c_char, - s_len: usize, - ) -> OrtStatusPtr, - >, - pub GetStringTensorDataLength: ::std::option::Option< - unsafe extern "C" fn(value: *const OrtValue, len: *mut usize) -> OrtStatusPtr, - >, - pub GetStringTensorContent: ::std::option::Option< - unsafe extern "C" fn( - value: *const OrtValue, - s: *mut ::std::os::raw::c_void, - s_len: usize, - offsets: *mut usize, - offsets_len: usize, - ) -> OrtStatusPtr, - >, - pub CastTypeInfoToTensorInfo: ::std::option::Option< - unsafe extern "C" fn( - arg1: *const OrtTypeInfo, - out: *mut *const OrtTensorTypeAndShapeInfo, - ) -> OrtStatusPtr, - >, - pub GetOnnxTypeFromTypeInfo: ::std::option::Option< - unsafe extern "C" fn(arg1: *const OrtTypeInfo, out: *mut ONNXType) -> OrtStatusPtr, - >, - pub CreateTensorTypeAndShapeInfo: ::std::option::Option< - unsafe extern "C" fn(out: *mut *mut OrtTensorTypeAndShapeInfo) -> OrtStatusPtr, - >, - pub SetTensorElementType: ::std::option::Option< - unsafe extern "C" fn( - arg1: *mut OrtTensorTypeAndShapeInfo, - type_: ONNXTensorElementDataType, - ) -> OrtStatusPtr, - >, - pub SetDimensions: ::std::option::Option< - unsafe extern "C" fn( - info: *mut OrtTensorTypeAndShapeInfo, - dim_values: *const i64, - dim_count: usize, - ) -> OrtStatusPtr, - >, - pub GetTensorElementType: ::std::option::Option< - unsafe extern "C" fn( - arg1: *const OrtTensorTypeAndShapeInfo, - out: *mut ONNXTensorElementDataType, - ) -> OrtStatusPtr, - >, - pub GetDimensionsCount: ::std::option::Option< - unsafe extern "C" fn( - info: *const OrtTensorTypeAndShapeInfo, - out: *mut usize, - ) -> OrtStatusPtr, - >, - pub GetDimensions: ::std::option::Option< - unsafe extern "C" fn( - info: *const OrtTensorTypeAndShapeInfo, - dim_values: *mut i64, - dim_values_length: usize, - ) -> OrtStatusPtr, - >, - pub GetSymbolicDimensions: ::std::option::Option< - unsafe extern "C" fn( - info: *const OrtTensorTypeAndShapeInfo, - dim_params: *mut *const ::std::os::raw::c_char, - dim_params_length: usize, - ) -> OrtStatusPtr, - >, - pub GetTensorShapeElementCount: ::std::option::Option< - unsafe extern "C" fn( - info: *const OrtTensorTypeAndShapeInfo, - out: *mut usize, - ) -> OrtStatusPtr, - >, - pub GetTensorTypeAndShape: ::std::option::Option< - unsafe extern "C" fn( - value: *const OrtValue, - out: *mut *mut OrtTensorTypeAndShapeInfo, - ) -> OrtStatusPtr, - >, - pub GetTypeInfo: ::std::option::Option< - unsafe extern "C" fn(value: *const OrtValue, out: *mut *mut OrtTypeInfo) -> OrtStatusPtr, - >, - pub GetValueType: ::std::option::Option< - unsafe extern "C" fn(value: *const OrtValue, out: *mut ONNXType) -> OrtStatusPtr, - >, - pub CreateMemoryInfo: ::std::option::Option< - unsafe extern "C" fn( - name1: *const ::std::os::raw::c_char, - type_: OrtAllocatorType, - id1: ::std::os::raw::c_int, - mem_type1: OrtMemType, - out: *mut *mut OrtMemoryInfo, - ) -> OrtStatusPtr, - >, - pub CreateCpuMemoryInfo: ::std::option::Option< - unsafe extern "C" fn( - type_: OrtAllocatorType, - mem_type1: OrtMemType, - out: *mut *mut OrtMemoryInfo, - ) -> OrtStatusPtr, - >, - pub CompareMemoryInfo: ::std::option::Option< - unsafe extern "C" fn( - info1: *const OrtMemoryInfo, - info2: *const OrtMemoryInfo, - out: *mut ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub MemoryInfoGetName: ::std::option::Option< - unsafe extern "C" fn( - ptr: *const OrtMemoryInfo, - out: *mut *const ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub MemoryInfoGetId: ::std::option::Option< - unsafe extern "C" fn( - ptr: *const OrtMemoryInfo, - out: *mut ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub MemoryInfoGetMemType: ::std::option::Option< - unsafe extern "C" fn(ptr: *const OrtMemoryInfo, out: *mut OrtMemType) -> OrtStatusPtr, - >, - pub MemoryInfoGetType: ::std::option::Option< - unsafe extern "C" fn(ptr: *const OrtMemoryInfo, out: *mut OrtAllocatorType) -> OrtStatusPtr, - >, - pub AllocatorAlloc: ::std::option::Option< - unsafe extern "C" fn( - ptr: *mut OrtAllocator, - size: usize, - out: *mut *mut ::std::os::raw::c_void, - ) -> OrtStatusPtr, - >, - pub AllocatorFree: ::std::option::Option< - unsafe extern "C" fn( - ptr: *mut OrtAllocator, - p: *mut ::std::os::raw::c_void, - ) -> OrtStatusPtr, - >, - pub AllocatorGetInfo: ::std::option::Option< - unsafe extern "C" fn( - ptr: *const OrtAllocator, - out: *mut *const OrtMemoryInfo, - ) -> OrtStatusPtr, - >, - pub GetAllocatorWithDefaultOptions: - ::std::option::Option OrtStatusPtr>, - pub AddFreeDimensionOverride: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - dim_denotation: *const ::std::os::raw::c_char, - dim_value: i64, - ) -> OrtStatusPtr, - >, - pub GetValue: ::std::option::Option< - unsafe extern "C" fn( - value: *const OrtValue, - index: ::std::os::raw::c_int, - allocator: *mut OrtAllocator, - out: *mut *mut OrtValue, - ) -> OrtStatusPtr, - >, - pub GetValueCount: ::std::option::Option< - unsafe extern "C" fn(value: *const OrtValue, out: *mut usize) -> OrtStatusPtr, - >, - pub CreateValue: ::std::option::Option< - unsafe extern "C" fn( - in_: *const *const OrtValue, - num_values: usize, - value_type: ONNXType, - out: *mut *mut OrtValue, - ) -> OrtStatusPtr, - >, - pub CreateOpaqueValue: ::std::option::Option< - unsafe extern "C" fn( - domain_name: *const ::std::os::raw::c_char, - type_name: *const ::std::os::raw::c_char, - data_container: *const ::std::os::raw::c_void, - data_container_size: usize, - out: *mut *mut OrtValue, - ) -> OrtStatusPtr, - >, - pub GetOpaqueValue: ::std::option::Option< - unsafe extern "C" fn( - domain_name: *const ::std::os::raw::c_char, - type_name: *const ::std::os::raw::c_char, - in_: *const OrtValue, - data_container: *mut ::std::os::raw::c_void, - data_container_size: usize, - ) -> OrtStatusPtr, - >, - pub KernelInfoGetAttribute_float: ::std::option::Option< - unsafe extern "C" fn( - info: *const OrtKernelInfo, - name: *const ::std::os::raw::c_char, - out: *mut f32, - ) -> OrtStatusPtr, - >, - pub KernelInfoGetAttribute_int64: ::std::option::Option< - unsafe extern "C" fn( - info: *const OrtKernelInfo, - name: *const ::std::os::raw::c_char, - out: *mut i64, - ) -> OrtStatusPtr, - >, - pub KernelInfoGetAttribute_string: ::std::option::Option< - unsafe extern "C" fn( - info: *const OrtKernelInfo, - name: *const ::std::os::raw::c_char, - out: *mut ::std::os::raw::c_char, - size: *mut usize, - ) -> OrtStatusPtr, - >, - pub KernelContext_GetInputCount: ::std::option::Option< - unsafe extern "C" fn(context: *const OrtKernelContext, out: *mut usize) -> OrtStatusPtr, - >, - pub KernelContext_GetOutputCount: ::std::option::Option< - unsafe extern "C" fn(context: *const OrtKernelContext, out: *mut usize) -> OrtStatusPtr, - >, - pub KernelContext_GetInput: ::std::option::Option< - unsafe extern "C" fn( - context: *const OrtKernelContext, - index: usize, - out: *mut *const OrtValue, - ) -> OrtStatusPtr, - >, - pub KernelContext_GetOutput: ::std::option::Option< - unsafe extern "C" fn( - context: *mut OrtKernelContext, - index: usize, - dim_values: *const i64, - dim_count: usize, - out: *mut *mut OrtValue, - ) -> OrtStatusPtr, - >, - pub ReleaseEnv: ::std::option::Option, - pub ReleaseStatus: ::std::option::Option, - pub ReleaseMemoryInfo: ::std::option::Option, - pub ReleaseSession: ::std::option::Option, - pub ReleaseValue: ::std::option::Option, - pub ReleaseRunOptions: ::std::option::Option, - pub ReleaseTypeInfo: ::std::option::Option, - pub ReleaseTensorTypeAndShapeInfo: - ::std::option::Option, - pub ReleaseSessionOptions: - ::std::option::Option, - pub ReleaseCustomOpDomain: - ::std::option::Option, - pub GetDenotationFromTypeInfo: ::std::option::Option< - unsafe extern "C" fn( - arg1: *const OrtTypeInfo, - denotation: *mut *const ::std::os::raw::c_char, - len: *mut usize, - ) -> OrtStatusPtr, - >, - pub CastTypeInfoToMapTypeInfo: ::std::option::Option< - unsafe extern "C" fn( - type_info: *const OrtTypeInfo, - out: *mut *const OrtMapTypeInfo, - ) -> OrtStatusPtr, - >, - pub CastTypeInfoToSequenceTypeInfo: ::std::option::Option< - unsafe extern "C" fn( - type_info: *const OrtTypeInfo, - out: *mut *const OrtSequenceTypeInfo, - ) -> OrtStatusPtr, - >, - pub GetMapKeyType: ::std::option::Option< - unsafe extern "C" fn( - map_type_info: *const OrtMapTypeInfo, - out: *mut ONNXTensorElementDataType, - ) -> OrtStatusPtr, - >, - pub GetMapValueType: ::std::option::Option< - unsafe extern "C" fn( - map_type_info: *const OrtMapTypeInfo, - type_info: *mut *mut OrtTypeInfo, - ) -> OrtStatusPtr, - >, - pub GetSequenceElementType: ::std::option::Option< - unsafe extern "C" fn( - sequence_type_info: *const OrtSequenceTypeInfo, - type_info: *mut *mut OrtTypeInfo, - ) -> OrtStatusPtr, - >, - pub ReleaseMapTypeInfo: ::std::option::Option, - pub ReleaseSequenceTypeInfo: - ::std::option::Option, - pub SessionEndProfiling: ::std::option::Option< - unsafe extern "C" fn( - sess: *mut OrtSession, - allocator: *mut OrtAllocator, - out: *mut *mut ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub SessionGetModelMetadata: ::std::option::Option< - unsafe extern "C" fn( - sess: *const OrtSession, - out: *mut *mut OrtModelMetadata, - ) -> OrtStatusPtr, - >, - pub ModelMetadataGetProducerName: ::std::option::Option< - unsafe extern "C" fn( - model_metadata: *const OrtModelMetadata, - allocator: *mut OrtAllocator, - value: *mut *mut ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub ModelMetadataGetGraphName: ::std::option::Option< - unsafe extern "C" fn( - model_metadata: *const OrtModelMetadata, - allocator: *mut OrtAllocator, - value: *mut *mut ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub ModelMetadataGetDomain: ::std::option::Option< - unsafe extern "C" fn( - model_metadata: *const OrtModelMetadata, - allocator: *mut OrtAllocator, - value: *mut *mut ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub ModelMetadataGetDescription: ::std::option::Option< - unsafe extern "C" fn( - model_metadata: *const OrtModelMetadata, - allocator: *mut OrtAllocator, - value: *mut *mut ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub ModelMetadataLookupCustomMetadataMap: ::std::option::Option< - unsafe extern "C" fn( - model_metadata: *const OrtModelMetadata, - allocator: *mut OrtAllocator, - key: *const ::std::os::raw::c_char, - value: *mut *mut ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub ModelMetadataGetVersion: ::std::option::Option< - unsafe extern "C" fn( - model_metadata: *const OrtModelMetadata, - value: *mut i64, - ) -> OrtStatusPtr, - >, - pub ReleaseModelMetadata: - ::std::option::Option, - pub CreateEnvWithGlobalThreadPools: ::std::option::Option< - unsafe extern "C" fn( - logging_level: OrtLoggingLevel, - logid: *const ::std::os::raw::c_char, - t_options: *const OrtThreadingOptions, - out: *mut *mut OrtEnv, - ) -> OrtStatusPtr, - >, - pub DisablePerSessionThreads: ::std::option::Option< - unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, - >, - pub CreateThreadingOptions: ::std::option::Option< - unsafe extern "C" fn(out: *mut *mut OrtThreadingOptions) -> OrtStatusPtr, - >, - pub ReleaseThreadingOptions: - ::std::option::Option, - pub ModelMetadataGetCustomMetadataMapKeys: ::std::option::Option< - unsafe extern "C" fn( - model_metadata: *const OrtModelMetadata, - allocator: *mut OrtAllocator, - keys: *mut *mut *mut ::std::os::raw::c_char, - num_keys: *mut i64, - ) -> OrtStatusPtr, - >, - pub AddFreeDimensionOverrideByName: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - dim_name: *const ::std::os::raw::c_char, - dim_value: i64, - ) -> OrtStatusPtr, - >, - pub GetAvailableProviders: ::std::option::Option< - unsafe extern "C" fn( - out_ptr: *mut *mut *mut ::std::os::raw::c_char, - provider_length: *mut ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub ReleaseAvailableProviders: ::std::option::Option< - unsafe extern "C" fn( - ptr: *mut *mut ::std::os::raw::c_char, - providers_length: ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub GetStringTensorElementLength: ::std::option::Option< - unsafe extern "C" fn(value: *const OrtValue, index: usize, out: *mut usize) -> OrtStatusPtr, - >, - pub GetStringTensorElement: ::std::option::Option< - unsafe extern "C" fn( - value: *const OrtValue, - s_len: usize, - index: usize, - s: *mut ::std::os::raw::c_void, - ) -> OrtStatusPtr, - >, - pub FillStringTensorElement: ::std::option::Option< - unsafe extern "C" fn( - value: *mut OrtValue, - s: *const ::std::os::raw::c_char, - index: usize, - ) -> OrtStatusPtr, - >, - pub AddSessionConfigEntry: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - config_key: *const ::std::os::raw::c_char, - config_value: *const ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub CreateAllocator: ::std::option::Option< - unsafe extern "C" fn( - sess: *const OrtSession, - mem_info: *const OrtMemoryInfo, - out: *mut *mut OrtAllocator, - ) -> OrtStatusPtr, - >, - pub ReleaseAllocator: ::std::option::Option, - pub RunWithBinding: ::std::option::Option< - unsafe extern "C" fn( - sess: *mut OrtSession, - run_options: *const OrtRunOptions, - binding_ptr: *const OrtIoBinding, - ) -> OrtStatusPtr, - >, - pub CreateIoBinding: ::std::option::Option< - unsafe extern "C" fn(sess: *mut OrtSession, out: *mut *mut OrtIoBinding) -> OrtStatusPtr, - >, - pub ReleaseIoBinding: ::std::option::Option, - pub BindInput: ::std::option::Option< - unsafe extern "C" fn( - binding_ptr: *mut OrtIoBinding, - name: *const ::std::os::raw::c_char, - val_ptr: *const OrtValue, - ) -> OrtStatusPtr, - >, - pub BindOutput: ::std::option::Option< - unsafe extern "C" fn( - binding_ptr: *mut OrtIoBinding, - name: *const ::std::os::raw::c_char, - val_ptr: *const OrtValue, - ) -> OrtStatusPtr, - >, - pub BindOutputToDevice: ::std::option::Option< - unsafe extern "C" fn( - binding_ptr: *mut OrtIoBinding, - name: *const ::std::os::raw::c_char, - val_ptr: *const OrtMemoryInfo, - ) -> OrtStatusPtr, - >, - pub GetBoundOutputNames: ::std::option::Option< - unsafe extern "C" fn( - binding_ptr: *const OrtIoBinding, - allocator: *mut OrtAllocator, - buffer: *mut *mut ::std::os::raw::c_char, - lengths: *mut *mut usize, - count: *mut usize, - ) -> OrtStatusPtr, - >, - pub GetBoundOutputValues: ::std::option::Option< - unsafe extern "C" fn( - binding_ptr: *const OrtIoBinding, - allocator: *mut OrtAllocator, - output: *mut *mut *mut OrtValue, - output_count: *mut usize, - ) -> OrtStatusPtr, - >, - #[doc = " Clears any previously specified bindings for inputs/outputs"] - pub ClearBoundInputs: - ::std::option::Option, - pub ClearBoundOutputs: - ::std::option::Option, - pub TensorAt: ::std::option::Option< - unsafe extern "C" fn( - value: *mut OrtValue, - location_values: *const i64, - location_values_count: usize, - out: *mut *mut ::std::os::raw::c_void, - ) -> OrtStatusPtr, - >, - pub CreateAndRegisterAllocator: ::std::option::Option< - unsafe extern "C" fn( - env: *mut OrtEnv, - mem_info: *const OrtMemoryInfo, - arena_cfg: *const OrtArenaCfg, - ) -> OrtStatusPtr, - >, - pub SetLanguageProjection: ::std::option::Option< - unsafe extern "C" fn( - ort_env: *const OrtEnv, - projection: OrtLanguageProjection, - ) -> OrtStatusPtr, - >, - pub SessionGetProfilingStartTimeNs: ::std::option::Option< - unsafe extern "C" fn(sess: *const OrtSession, out: *mut u64) -> OrtStatusPtr, - >, - pub SetGlobalIntraOpNumThreads: ::std::option::Option< - unsafe extern "C" fn( - tp_options: *mut OrtThreadingOptions, - intra_op_num_threads: ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub SetGlobalInterOpNumThreads: ::std::option::Option< - unsafe extern "C" fn( - tp_options: *mut OrtThreadingOptions, - inter_op_num_threads: ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub SetGlobalSpinControl: ::std::option::Option< - unsafe extern "C" fn( - tp_options: *mut OrtThreadingOptions, - allow_spinning: ::std::os::raw::c_int, - ) -> OrtStatusPtr, - >, - pub AddInitializer: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - name: *const ::std::os::raw::c_char, - val: *const OrtValue, - ) -> OrtStatusPtr, - >, - pub CreateEnvWithCustomLoggerAndGlobalThreadPools: ::std::option::Option< - unsafe extern "C" fn( - logging_function: OrtLoggingFunction, - logger_param: *mut ::std::os::raw::c_void, - logging_level: OrtLoggingLevel, - logid: *const ::std::os::raw::c_char, - tp_options: *const OrtThreadingOptions, - out: *mut *mut OrtEnv, - ) -> OrtStatusPtr, - >, - pub SessionOptionsAppendExecutionProvider_CUDA: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - cuda_options: *const OrtCUDAProviderOptions, - ) -> OrtStatusPtr, - >, - pub SessionOptionsAppendExecutionProvider_ROCM: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - rocm_options: *const OrtROCMProviderOptions, - ) -> OrtStatusPtr, - >, - pub SessionOptionsAppendExecutionProvider_OpenVINO: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - provider_options: *const OrtOpenVINOProviderOptions, - ) -> OrtStatusPtr, - >, - pub SetGlobalDenormalAsZero: ::std::option::Option< - unsafe extern "C" fn(tp_options: *mut OrtThreadingOptions) -> OrtStatusPtr, - >, - pub CreateArenaCfg: ::std::option::Option< - unsafe extern "C" fn( - max_mem: usize, - arena_extend_strategy: ::std::os::raw::c_int, - initial_chunk_size_bytes: ::std::os::raw::c_int, - max_dead_bytes_per_chunk: ::std::os::raw::c_int, - out: *mut *mut OrtArenaCfg, - ) -> OrtStatusPtr, - >, - pub ReleaseArenaCfg: ::std::option::Option, - pub ModelMetadataGetGraphDescription: ::std::option::Option< - unsafe extern "C" fn( - model_metadata: *const OrtModelMetadata, - allocator: *mut OrtAllocator, - value: *mut *mut ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub SessionOptionsAppendExecutionProvider_TensorRT: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtSessionOptions, - tensorrt_options: *const OrtTensorRTProviderOptions, - ) -> OrtStatusPtr, - >, - pub SetCurrentGpuDeviceId: ::std::option::Option< - unsafe extern "C" fn(device_id: ::std::os::raw::c_int) -> OrtStatusPtr, - >, - pub GetCurrentGpuDeviceId: ::std::option::Option< - unsafe extern "C" fn(device_id: *mut ::std::os::raw::c_int) -> OrtStatusPtr, - >, - pub KernelInfoGetAttributeArray_float: ::std::option::Option< - unsafe extern "C" fn( - info: *const OrtKernelInfo, - name: *const ::std::os::raw::c_char, - out: *mut f32, - size: *mut usize, - ) -> OrtStatusPtr, - >, - pub KernelInfoGetAttributeArray_int64: ::std::option::Option< - unsafe extern "C" fn( - info: *const OrtKernelInfo, - name: *const ::std::os::raw::c_char, - out: *mut i64, - size: *mut usize, - ) -> OrtStatusPtr, - >, - pub CreateArenaCfgV2: ::std::option::Option< - unsafe extern "C" fn( - arena_config_keys: *const *const ::std::os::raw::c_char, - arena_config_values: *const usize, - num_keys: usize, - out: *mut *mut OrtArenaCfg, - ) -> OrtStatusPtr, - >, - pub AddRunConfigEntry: ::std::option::Option< - unsafe extern "C" fn( - options: *mut OrtRunOptions, - config_key: *const ::std::os::raw::c_char, - config_value: *const ::std::os::raw::c_char, - ) -> OrtStatusPtr, - >, - pub CreatePrepackedWeightsContainer: ::std::option::Option< - unsafe extern "C" fn(out: *mut *mut OrtPrepackedWeightsContainer) -> OrtStatusPtr, - >, - pub ReleasePrepackedWeightsContainer: - ::std::option::Option, - pub CreateSessionWithPrepackedWeightsContainer: ::std::option::Option< - unsafe extern "C" fn( - env: *const OrtEnv, - model_path: *const ::std::os::raw::c_char, - options: *const OrtSessionOptions, - prepacked_weights_container: *mut OrtPrepackedWeightsContainer, - out: *mut *mut OrtSession, - ) -> OrtStatusPtr, - >, - pub CreateSessionFromArrayWithPrepackedWeightsContainer: ::std::option::Option< - unsafe extern "C" fn( - env: *const OrtEnv, - model_data: *const ::std::os::raw::c_void, - model_data_length: usize, - options: *const OrtSessionOptions, - prepacked_weights_container: *mut OrtPrepackedWeightsContainer, - out: *mut *mut OrtSession, - ) -> OrtStatusPtr, - >, -} -#[test] -fn bindgen_test_layout_OrtApi() { - assert_eq!( - ::std::mem::size_of::(), - 1360usize, - concat!("Size of: ", stringify!(OrtApi)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(OrtApi)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateStatus as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateStatus) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetErrorCode as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetErrorCode) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetErrorMessage as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetErrorMessage) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateEnv as *const _ as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateEnv) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateEnvWithCustomLogger as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateEnvWithCustomLogger) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).EnableTelemetryEvents as *const _ as usize }, - 40usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(EnableTelemetryEvents) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).DisableTelemetryEvents as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(DisableTelemetryEvents) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateSession as *const _ as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateSession) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateSessionFromArray as *const _ as usize }, - 64usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateSessionFromArray) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).Run as *const _ as usize }, - 72usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(Run) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateSessionOptions as *const _ as usize }, - 80usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateSessionOptions) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SetOptimizedModelFilePath as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetOptimizedModelFilePath) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CloneSessionOptions as *const _ as usize }, - 96usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CloneSessionOptions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetSessionExecutionMode as *const _ as usize }, - 104usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetSessionExecutionMode) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).EnableProfiling as *const _ as usize }, - 112usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(EnableProfiling) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).DisableProfiling as *const _ as usize }, - 120usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(DisableProfiling) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).EnableMemPattern as *const _ as usize }, - 128usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(EnableMemPattern) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).DisableMemPattern as *const _ as usize }, - 136usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(DisableMemPattern) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).EnableCpuMemArena as *const _ as usize }, - 144usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(EnableCpuMemArena) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).DisableCpuMemArena as *const _ as usize }, - 152usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(DisableCpuMemArena) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetSessionLogId as *const _ as usize }, - 160usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetSessionLogId) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SetSessionLogVerbosityLevel as *const _ as usize - }, - 168usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetSessionLogVerbosityLevel) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SetSessionLogSeverityLevel as *const _ as usize - }, - 176usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetSessionLogSeverityLevel) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SetSessionGraphOptimizationLevel as *const _ as usize - }, - 184usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetSessionGraphOptimizationLevel) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetIntraOpNumThreads as *const _ as usize }, - 192usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetIntraOpNumThreads) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetInterOpNumThreads as *const _ as usize }, - 200usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetInterOpNumThreads) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateCustomOpDomain as *const _ as usize }, - 208usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateCustomOpDomain) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CustomOpDomain_Add as *const _ as usize }, - 216usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CustomOpDomain_Add) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AddCustomOpDomain as *const _ as usize }, - 224usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AddCustomOpDomain) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).RegisterCustomOpsLibrary as *const _ as usize }, - 232usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RegisterCustomOpsLibrary) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionGetInputCount as *const _ as usize }, - 240usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetInputCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionGetOutputCount as *const _ as usize }, - 248usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetOutputCount) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionGetOverridableInitializerCount as *const _ - as usize - }, - 256usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetOverridableInitializerCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionGetInputTypeInfo as *const _ as usize }, - 264usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetInputTypeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionGetOutputTypeInfo as *const _ as usize }, - 272usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetOutputTypeInfo) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionGetOverridableInitializerTypeInfo as *const _ - as usize - }, - 280usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetOverridableInitializerTypeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionGetInputName as *const _ as usize }, - 288usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetInputName) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionGetOutputName as *const _ as usize }, - 296usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetOutputName) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionGetOverridableInitializerName as *const _ - as usize - }, - 304usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetOverridableInitializerName) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateRunOptions as *const _ as usize }, - 312usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateRunOptions) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).RunOptionsSetRunLogVerbosityLevel as *const _ - as usize - }, - 320usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsSetRunLogVerbosityLevel) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).RunOptionsSetRunLogSeverityLevel as *const _ as usize - }, - 328usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsSetRunLogSeverityLevel) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).RunOptionsSetRunTag as *const _ as usize }, - 336usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsSetRunTag) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).RunOptionsGetRunLogVerbosityLevel as *const _ - as usize - }, - 344usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsGetRunLogVerbosityLevel) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).RunOptionsGetRunLogSeverityLevel as *const _ as usize - }, - 352usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsGetRunLogSeverityLevel) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).RunOptionsGetRunTag as *const _ as usize }, - 360usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsGetRunTag) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).RunOptionsSetTerminate as *const _ as usize }, - 368usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsSetTerminate) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).RunOptionsUnsetTerminate as *const _ as usize }, - 376usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsUnsetTerminate) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateTensorAsOrtValue as *const _ as usize }, - 384usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateTensorAsOrtValue) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateTensorWithDataAsOrtValue as *const _ as usize - }, - 392usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateTensorWithDataAsOrtValue) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).IsTensor as *const _ as usize }, - 400usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(IsTensor) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetTensorMutableData as *const _ as usize }, - 408usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetTensorMutableData) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).FillStringTensor as *const _ as usize }, - 416usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(FillStringTensor) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetStringTensorDataLength as *const _ as usize - }, - 424usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetStringTensorDataLength) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetStringTensorContent as *const _ as usize }, - 432usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetStringTensorContent) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CastTypeInfoToTensorInfo as *const _ as usize }, - 440usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CastTypeInfoToTensorInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetOnnxTypeFromTypeInfo as *const _ as usize }, - 448usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetOnnxTypeFromTypeInfo) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateTensorTypeAndShapeInfo as *const _ as usize - }, - 456usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateTensorTypeAndShapeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetTensorElementType as *const _ as usize }, - 464usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetTensorElementType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetDimensions as *const _ as usize }, - 472usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetDimensions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetTensorElementType as *const _ as usize }, - 480usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetTensorElementType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetDimensionsCount as *const _ as usize }, - 488usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetDimensionsCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetDimensions as *const _ as usize }, - 496usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetDimensions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetSymbolicDimensions as *const _ as usize }, - 504usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetSymbolicDimensions) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetTensorShapeElementCount as *const _ as usize - }, - 512usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetTensorShapeElementCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetTensorTypeAndShape as *const _ as usize }, - 520usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetTensorTypeAndShape) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetTypeInfo as *const _ as usize }, - 528usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetTypeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetValueType as *const _ as usize }, - 536usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetValueType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateMemoryInfo as *const _ as usize }, - 544usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateMemoryInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateCpuMemoryInfo as *const _ as usize }, - 552usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateCpuMemoryInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CompareMemoryInfo as *const _ as usize }, - 560usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CompareMemoryInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).MemoryInfoGetName as *const _ as usize }, - 568usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(MemoryInfoGetName) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).MemoryInfoGetId as *const _ as usize }, - 576usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(MemoryInfoGetId) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).MemoryInfoGetMemType as *const _ as usize }, - 584usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(MemoryInfoGetMemType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).MemoryInfoGetType as *const _ as usize }, - 592usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(MemoryInfoGetType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AllocatorAlloc as *const _ as usize }, - 600usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AllocatorAlloc) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AllocatorFree as *const _ as usize }, - 608usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AllocatorFree) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AllocatorGetInfo as *const _ as usize }, - 616usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AllocatorGetInfo) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetAllocatorWithDefaultOptions as *const _ as usize - }, - 624usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetAllocatorWithDefaultOptions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AddFreeDimensionOverride as *const _ as usize }, - 632usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AddFreeDimensionOverride) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetValue as *const _ as usize }, - 640usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetValue) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetValueCount as *const _ as usize }, - 648usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetValueCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateValue as *const _ as usize }, - 656usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateValue) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateOpaqueValue as *const _ as usize }, - 664usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateOpaqueValue) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetOpaqueValue as *const _ as usize }, - 672usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetOpaqueValue) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).KernelInfoGetAttribute_float as *const _ as usize - }, - 680usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelInfoGetAttribute_float) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).KernelInfoGetAttribute_int64 as *const _ as usize - }, - 688usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelInfoGetAttribute_int64) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).KernelInfoGetAttribute_string as *const _ as usize - }, - 696usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelInfoGetAttribute_string) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).KernelContext_GetInputCount as *const _ as usize - }, - 704usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelContext_GetInputCount) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).KernelContext_GetOutputCount as *const _ as usize - }, - 712usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelContext_GetOutputCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).KernelContext_GetInput as *const _ as usize }, - 720usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelContext_GetInput) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).KernelContext_GetOutput as *const _ as usize }, - 728usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelContext_GetOutput) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseEnv as *const _ as usize }, - 736usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseEnv) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseStatus as *const _ as usize }, - 744usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseStatus) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseMemoryInfo as *const _ as usize }, - 752usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseMemoryInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseSession as *const _ as usize }, - 760usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseSession) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseValue as *const _ as usize }, - 768usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseValue) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseRunOptions as *const _ as usize }, - 776usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseRunOptions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseTypeInfo as *const _ as usize }, - 784usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseTypeInfo) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ReleaseTensorTypeAndShapeInfo as *const _ as usize - }, - 792usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseTensorTypeAndShapeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseSessionOptions as *const _ as usize }, - 800usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseSessionOptions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseCustomOpDomain as *const _ as usize }, - 808usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseCustomOpDomain) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetDenotationFromTypeInfo as *const _ as usize - }, - 816usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetDenotationFromTypeInfo) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CastTypeInfoToMapTypeInfo as *const _ as usize - }, - 824usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CastTypeInfoToMapTypeInfo) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CastTypeInfoToSequenceTypeInfo as *const _ as usize - }, - 832usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CastTypeInfoToSequenceTypeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetMapKeyType as *const _ as usize }, - 840usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetMapKeyType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetMapValueType as *const _ as usize }, - 848usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetMapValueType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetSequenceElementType as *const _ as usize }, - 856usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetSequenceElementType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseMapTypeInfo as *const _ as usize }, - 864usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseMapTypeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseSequenceTypeInfo as *const _ as usize }, - 872usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseSequenceTypeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionEndProfiling as *const _ as usize }, - 880usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionEndProfiling) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionGetModelMetadata as *const _ as usize }, - 888usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetModelMetadata) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ModelMetadataGetProducerName as *const _ as usize - }, - 896usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataGetProducerName) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ModelMetadataGetGraphName as *const _ as usize - }, - 904usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataGetGraphName) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ModelMetadataGetDomain as *const _ as usize }, - 912usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataGetDomain) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ModelMetadataGetDescription as *const _ as usize - }, - 920usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataGetDescription) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ModelMetadataLookupCustomMetadataMap as *const _ - as usize - }, - 928usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataLookupCustomMetadataMap) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ModelMetadataGetVersion as *const _ as usize }, - 936usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataGetVersion) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseModelMetadata as *const _ as usize }, - 944usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseModelMetadata) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateEnvWithGlobalThreadPools as *const _ as usize - }, - 952usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateEnvWithGlobalThreadPools) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).DisablePerSessionThreads as *const _ as usize }, - 960usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(DisablePerSessionThreads) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateThreadingOptions as *const _ as usize }, - 968usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateThreadingOptions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseThreadingOptions as *const _ as usize }, - 976usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseThreadingOptions) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ModelMetadataGetCustomMetadataMapKeys as *const _ - as usize - }, - 984usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataGetCustomMetadataMapKeys) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).AddFreeDimensionOverrideByName as *const _ as usize - }, - 992usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AddFreeDimensionOverrideByName) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetAvailableProviders as *const _ as usize }, - 1000usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetAvailableProviders) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ReleaseAvailableProviders as *const _ as usize - }, - 1008usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseAvailableProviders) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetStringTensorElementLength as *const _ as usize - }, - 1016usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetStringTensorElementLength) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetStringTensorElement as *const _ as usize }, - 1024usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetStringTensorElement) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).FillStringTensorElement as *const _ as usize }, - 1032usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(FillStringTensorElement) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AddSessionConfigEntry as *const _ as usize }, - 1040usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AddSessionConfigEntry) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateAllocator as *const _ as usize }, - 1048usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateAllocator) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseAllocator as *const _ as usize }, - 1056usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseAllocator) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).RunWithBinding as *const _ as usize }, - 1064usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunWithBinding) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateIoBinding as *const _ as usize }, - 1072usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateIoBinding) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseIoBinding as *const _ as usize }, - 1080usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseIoBinding) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).BindInput as *const _ as usize }, - 1088usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(BindInput) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).BindOutput as *const _ as usize }, - 1096usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(BindOutput) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).BindOutputToDevice as *const _ as usize }, - 1104usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(BindOutputToDevice) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetBoundOutputNames as *const _ as usize }, - 1112usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetBoundOutputNames) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetBoundOutputValues as *const _ as usize }, - 1120usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetBoundOutputValues) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ClearBoundInputs as *const _ as usize }, - 1128usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ClearBoundInputs) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ClearBoundOutputs as *const _ as usize }, - 1136usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ClearBoundOutputs) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).TensorAt as *const _ as usize }, - 1144usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(TensorAt) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateAndRegisterAllocator as *const _ as usize - }, - 1152usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateAndRegisterAllocator) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetLanguageProjection as *const _ as usize }, - 1160usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetLanguageProjection) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionGetProfilingStartTimeNs as *const _ as usize - }, - 1168usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetProfilingStartTimeNs) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SetGlobalIntraOpNumThreads as *const _ as usize - }, - 1176usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetGlobalIntraOpNumThreads) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SetGlobalInterOpNumThreads as *const _ as usize - }, - 1184usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetGlobalInterOpNumThreads) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetGlobalSpinControl as *const _ as usize }, - 1192usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetGlobalSpinControl) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AddInitializer as *const _ as usize }, - 1200usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AddInitializer) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateEnvWithCustomLoggerAndGlobalThreadPools - as *const _ as usize - }, - 1208usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateEnvWithCustomLoggerAndGlobalThreadPools) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionOptionsAppendExecutionProvider_CUDA - as *const _ as usize - }, - 1216usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionOptionsAppendExecutionProvider_CUDA) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionOptionsAppendExecutionProvider_ROCM - as *const _ as usize - }, - 1224usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionOptionsAppendExecutionProvider_ROCM) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionOptionsAppendExecutionProvider_OpenVINO - as *const _ as usize - }, - 1232usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionOptionsAppendExecutionProvider_OpenVINO) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetGlobalDenormalAsZero as *const _ as usize }, - 1240usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetGlobalDenormalAsZero) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateArenaCfg as *const _ as usize }, - 1248usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateArenaCfg) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseArenaCfg as *const _ as usize }, - 1256usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseArenaCfg) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ModelMetadataGetGraphDescription as *const _ as usize - }, - 1264usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataGetGraphDescription) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionOptionsAppendExecutionProvider_TensorRT - as *const _ as usize - }, - 1272usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionOptionsAppendExecutionProvider_TensorRT) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetCurrentGpuDeviceId as *const _ as usize }, - 1280usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetCurrentGpuDeviceId) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetCurrentGpuDeviceId as *const _ as usize }, - 1288usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetCurrentGpuDeviceId) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).KernelInfoGetAttributeArray_float as *const _ - as usize - }, - 1296usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelInfoGetAttributeArray_float) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).KernelInfoGetAttributeArray_int64 as *const _ - as usize - }, - 1304usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelInfoGetAttributeArray_int64) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateArenaCfgV2 as *const _ as usize }, - 1312usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateArenaCfgV2) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AddRunConfigEntry as *const _ as usize }, - 1320usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AddRunConfigEntry) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreatePrepackedWeightsContainer as *const _ as usize - }, - 1328usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreatePrepackedWeightsContainer) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ReleasePrepackedWeightsContainer as *const _ as usize - }, - 1336usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleasePrepackedWeightsContainer) - ) - ); +pub struct OrtApi { + #[doc = " \\brief Create an OrtStatus from a null terminated string"] + #[doc = ""] + #[doc = " \\param[in] code"] + #[doc = " \\param[in] msg A null-terminated string. Its contents will be copied."] + #[doc = " \\return A new OrtStatus object, must be destroyed with OrtApi::ReleaseStatus"] + pub CreateStatus: ::std::option::Option< + unsafe extern "C" fn( + code: OrtErrorCode, + msg: *const ::std::os::raw::c_char, + ) -> *mut OrtStatus, + >, + #[doc = " \\brief Get OrtErrorCode from OrtStatus"] + #[doc = ""] + #[doc = " \\param[in] status"] + #[doc = " \\return OrtErrorCode that \\p status was created with"] + pub GetErrorCode: + ::std::option::Option OrtErrorCode>, + #[doc = " \\brief Get error string from OrtStatus"] + #[doc = ""] + #[doc = " \\param[in] status"] + #[doc = " \\return The error message inside the `status`. Do not free the returned value."] + pub GetErrorMessage: ::std::option::Option< + unsafe extern "C" fn(status: *const OrtStatus) -> *const ::std::os::raw::c_char, + >, + pub CreateEnv: ::std::option::Option< + unsafe extern "C" fn( + log_severity_level: OrtLoggingLevel, + logid: *const ::std::os::raw::c_char, + out: *mut *mut OrtEnv, + ) -> OrtStatusPtr, + >, + pub CreateEnvWithCustomLogger: ::std::option::Option< + unsafe extern "C" fn( + logging_function: OrtLoggingFunction, + logger_param: *mut ::std::os::raw::c_void, + log_severity_level: OrtLoggingLevel, + logid: *const ::std::os::raw::c_char, + out: *mut *mut OrtEnv, + ) -> OrtStatusPtr, + >, + pub EnableTelemetryEvents: + ::std::option::Option OrtStatusPtr>, + pub DisableTelemetryEvents: + ::std::option::Option OrtStatusPtr>, + pub CreateSession: ::std::option::Option< + unsafe extern "C" fn( + env: *const OrtEnv, + model_path: *const ::std::os::raw::c_char, + options: *const OrtSessionOptions, + out: *mut *mut OrtSession, + ) -> OrtStatusPtr, + >, + pub CreateSessionFromArray: ::std::option::Option< + unsafe extern "C" fn( + env: *const OrtEnv, + model_data: *const ::std::os::raw::c_void, + model_data_length: usize, + options: *const OrtSessionOptions, + out: *mut *mut OrtSession, + ) -> OrtStatusPtr, + >, + pub Run: ::std::option::Option< + unsafe extern "C" fn( + session: *mut OrtSession, + run_options: *const OrtRunOptions, + input_names: *const *const ::std::os::raw::c_char, + inputs: *const *const OrtValue, + input_len: usize, + output_names: *const *const ::std::os::raw::c_char, + output_names_len: usize, + outputs: *mut *mut OrtValue, + ) -> OrtStatusPtr, + >, + pub CreateSessionOptions: ::std::option::Option< + unsafe extern "C" fn(options: *mut *mut OrtSessionOptions) -> OrtStatusPtr, + >, + pub SetOptimizedModelFilePath: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + optimized_model_filepath: *const ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub CloneSessionOptions: ::std::option::Option< + unsafe extern "C" fn( + in_options: *const OrtSessionOptions, + out_options: *mut *mut OrtSessionOptions, + ) -> OrtStatusPtr, + >, + pub SetSessionExecutionMode: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + execution_mode: ExecutionMode, + ) -> OrtStatusPtr, + >, + pub EnableProfiling: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + profile_file_prefix: *const ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub DisableProfiling: ::std::option::Option< + unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, + >, + pub EnableMemPattern: ::std::option::Option< + unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, + >, + pub DisableMemPattern: ::std::option::Option< + unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, + >, + pub EnableCpuMemArena: ::std::option::Option< + unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, + >, + pub DisableCpuMemArena: ::std::option::Option< + unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, + >, + pub SetSessionLogId: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + logid: *const ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub SetSessionLogVerbosityLevel: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + session_log_verbosity_level: ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub SetSessionLogSeverityLevel: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + session_log_severity_level: ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub SetSessionGraphOptimizationLevel: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + graph_optimization_level: GraphOptimizationLevel, + ) -> OrtStatusPtr, + >, + pub SetIntraOpNumThreads: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + intra_op_num_threads: ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub SetInterOpNumThreads: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + inter_op_num_threads: ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub CreateCustomOpDomain: ::std::option::Option< + unsafe extern "C" fn( + domain: *const ::std::os::raw::c_char, + out: *mut *mut OrtCustomOpDomain, + ) -> OrtStatusPtr, + >, + pub CustomOpDomain_Add: ::std::option::Option< + unsafe extern "C" fn( + custom_op_domain: *mut OrtCustomOpDomain, + op: *const OrtCustomOp, + ) -> OrtStatusPtr, + >, + pub AddCustomOpDomain: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + custom_op_domain: *mut OrtCustomOpDomain, + ) -> OrtStatusPtr, + >, + pub RegisterCustomOpsLibrary: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + library_path: *const ::std::os::raw::c_char, + library_handle: *mut *mut ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub SessionGetInputCount: ::std::option::Option< + unsafe extern "C" fn(session: *const OrtSession, out: *mut usize) -> OrtStatusPtr, + >, + pub SessionGetOutputCount: ::std::option::Option< + unsafe extern "C" fn(session: *const OrtSession, out: *mut usize) -> OrtStatusPtr, + >, + pub SessionGetOverridableInitializerCount: ::std::option::Option< + unsafe extern "C" fn(session: *const OrtSession, out: *mut usize) -> OrtStatusPtr, + >, + pub SessionGetInputTypeInfo: ::std::option::Option< + unsafe extern "C" fn( + session: *const OrtSession, + index: usize, + type_info: *mut *mut OrtTypeInfo, + ) -> OrtStatusPtr, + >, + pub SessionGetOutputTypeInfo: ::std::option::Option< + unsafe extern "C" fn( + session: *const OrtSession, + index: usize, + type_info: *mut *mut OrtTypeInfo, + ) -> OrtStatusPtr, + >, + pub SessionGetOverridableInitializerTypeInfo: ::std::option::Option< + unsafe extern "C" fn( + session: *const OrtSession, + index: usize, + type_info: *mut *mut OrtTypeInfo, + ) -> OrtStatusPtr, + >, + pub SessionGetInputName: ::std::option::Option< + unsafe extern "C" fn( + session: *const OrtSession, + index: usize, + allocator: *mut OrtAllocator, + value: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub SessionGetOutputName: ::std::option::Option< + unsafe extern "C" fn( + session: *const OrtSession, + index: usize, + allocator: *mut OrtAllocator, + value: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub SessionGetOverridableInitializerName: ::std::option::Option< + unsafe extern "C" fn( + session: *const OrtSession, + index: usize, + allocator: *mut OrtAllocator, + value: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub CreateRunOptions: + ::std::option::Option OrtStatusPtr>, + pub RunOptionsSetRunLogVerbosityLevel: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtRunOptions, + log_verbosity_level: ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub RunOptionsSetRunLogSeverityLevel: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtRunOptions, + log_severity_level: ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub RunOptionsSetRunTag: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtRunOptions, + run_tag: *const ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub RunOptionsGetRunLogVerbosityLevel: ::std::option::Option< + unsafe extern "C" fn( + options: *const OrtRunOptions, + log_verbosity_level: *mut ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub RunOptionsGetRunLogSeverityLevel: ::std::option::Option< + unsafe extern "C" fn( + options: *const OrtRunOptions, + log_severity_level: *mut ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub RunOptionsGetRunTag: ::std::option::Option< + unsafe extern "C" fn( + options: *const OrtRunOptions, + run_tag: *mut *const ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub RunOptionsSetTerminate: + ::std::option::Option OrtStatusPtr>, + pub RunOptionsUnsetTerminate: + ::std::option::Option OrtStatusPtr>, + pub CreateTensorAsOrtValue: ::std::option::Option< + unsafe extern "C" fn( + allocator: *mut OrtAllocator, + shape: *const i64, + shape_len: usize, + type_: ONNXTensorElementDataType, + out: *mut *mut OrtValue, + ) -> OrtStatusPtr, + >, + pub CreateTensorWithDataAsOrtValue: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtMemoryInfo, + p_data: *mut ::std::os::raw::c_void, + p_data_len: usize, + shape: *const i64, + shape_len: usize, + type_: ONNXTensorElementDataType, + out: *mut *mut OrtValue, + ) -> OrtStatusPtr, + >, + pub IsTensor: ::std::option::Option< + unsafe extern "C" fn( + value: *const OrtValue, + out: *mut ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub GetTensorMutableData: ::std::option::Option< + unsafe extern "C" fn( + value: *mut OrtValue, + out: *mut *mut ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub FillStringTensor: ::std::option::Option< + unsafe extern "C" fn( + value: *mut OrtValue, + s: *const *const ::std::os::raw::c_char, + s_len: usize, + ) -> OrtStatusPtr, + >, + pub GetStringTensorDataLength: ::std::option::Option< + unsafe extern "C" fn(value: *const OrtValue, len: *mut usize) -> OrtStatusPtr, + >, + pub GetStringTensorContent: ::std::option::Option< + unsafe extern "C" fn( + value: *const OrtValue, + s: *mut ::std::os::raw::c_void, + s_len: usize, + offsets: *mut usize, + offsets_len: usize, + ) -> OrtStatusPtr, + >, + pub CastTypeInfoToTensorInfo: ::std::option::Option< + unsafe extern "C" fn( + type_info: *const OrtTypeInfo, + out: *mut *const OrtTensorTypeAndShapeInfo, + ) -> OrtStatusPtr, + >, + pub GetOnnxTypeFromTypeInfo: ::std::option::Option< + unsafe extern "C" fn(type_info: *const OrtTypeInfo, out: *mut ONNXType) -> OrtStatusPtr, + >, + pub CreateTensorTypeAndShapeInfo: ::std::option::Option< + unsafe extern "C" fn(out: *mut *mut OrtTensorTypeAndShapeInfo) -> OrtStatusPtr, + >, + pub SetTensorElementType: ::std::option::Option< + unsafe extern "C" fn( + info: *mut OrtTensorTypeAndShapeInfo, + type_: ONNXTensorElementDataType, + ) -> OrtStatusPtr, + >, + pub SetDimensions: ::std::option::Option< + unsafe extern "C" fn( + info: *mut OrtTensorTypeAndShapeInfo, + dim_values: *const i64, + dim_count: usize, + ) -> OrtStatusPtr, + >, + pub GetTensorElementType: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtTensorTypeAndShapeInfo, + out: *mut ONNXTensorElementDataType, + ) -> OrtStatusPtr, + >, + pub GetDimensionsCount: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtTensorTypeAndShapeInfo, + out: *mut usize, + ) -> OrtStatusPtr, + >, + pub GetDimensions: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtTensorTypeAndShapeInfo, + dim_values: *mut i64, + dim_values_length: usize, + ) -> OrtStatusPtr, + >, + pub GetSymbolicDimensions: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtTensorTypeAndShapeInfo, + dim_params: *mut *const ::std::os::raw::c_char, + dim_params_length: usize, + ) -> OrtStatusPtr, + >, + pub GetTensorShapeElementCount: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtTensorTypeAndShapeInfo, + out: *mut usize, + ) -> OrtStatusPtr, + >, + pub GetTensorTypeAndShape: ::std::option::Option< + unsafe extern "C" fn( + value: *const OrtValue, + out: *mut *mut OrtTensorTypeAndShapeInfo, + ) -> OrtStatusPtr, + >, + pub GetTypeInfo: ::std::option::Option< + unsafe extern "C" fn(value: *const OrtValue, out: *mut *mut OrtTypeInfo) -> OrtStatusPtr, + >, + pub GetValueType: ::std::option::Option< + unsafe extern "C" fn(value: *const OrtValue, out: *mut ONNXType) -> OrtStatusPtr, + >, + pub CreateMemoryInfo: ::std::option::Option< + unsafe extern "C" fn( + name: *const ::std::os::raw::c_char, + type_: OrtAllocatorType, + id: ::std::os::raw::c_int, + mem_type: OrtMemType, + out: *mut *mut OrtMemoryInfo, + ) -> OrtStatusPtr, + >, + pub CreateCpuMemoryInfo: ::std::option::Option< + unsafe extern "C" fn( + type_: OrtAllocatorType, + mem_type: OrtMemType, + out: *mut *mut OrtMemoryInfo, + ) -> OrtStatusPtr, + >, + pub CompareMemoryInfo: ::std::option::Option< + unsafe extern "C" fn( + info1: *const OrtMemoryInfo, + info2: *const OrtMemoryInfo, + out: *mut ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub MemoryInfoGetName: ::std::option::Option< + unsafe extern "C" fn( + ptr: *const OrtMemoryInfo, + out: *mut *const ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub MemoryInfoGetId: ::std::option::Option< + unsafe extern "C" fn( + ptr: *const OrtMemoryInfo, + out: *mut ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub MemoryInfoGetMemType: ::std::option::Option< + unsafe extern "C" fn(ptr: *const OrtMemoryInfo, out: *mut OrtMemType) -> OrtStatusPtr, + >, + pub MemoryInfoGetType: ::std::option::Option< + unsafe extern "C" fn(ptr: *const OrtMemoryInfo, out: *mut OrtAllocatorType) -> OrtStatusPtr, + >, + pub AllocatorAlloc: ::std::option::Option< + unsafe extern "C" fn( + ort_allocator: *mut OrtAllocator, + size: usize, + out: *mut *mut ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub AllocatorFree: ::std::option::Option< + unsafe extern "C" fn( + ort_allocator: *mut OrtAllocator, + p: *mut ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub AllocatorGetInfo: ::std::option::Option< + unsafe extern "C" fn( + ort_allocator: *const OrtAllocator, + out: *mut *const OrtMemoryInfo, + ) -> OrtStatusPtr, + >, + pub GetAllocatorWithDefaultOptions: + ::std::option::Option OrtStatusPtr>, + pub AddFreeDimensionOverride: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + dim_denotation: *const ::std::os::raw::c_char, + dim_value: i64, + ) -> OrtStatusPtr, + >, + pub GetValue: ::std::option::Option< + unsafe extern "C" fn( + value: *const OrtValue, + index: ::std::os::raw::c_int, + allocator: *mut OrtAllocator, + out: *mut *mut OrtValue, + ) -> OrtStatusPtr, + >, + pub GetValueCount: ::std::option::Option< + unsafe extern "C" fn(value: *const OrtValue, out: *mut usize) -> OrtStatusPtr, + >, + pub CreateValue: ::std::option::Option< + unsafe extern "C" fn( + in_: *const *const OrtValue, + num_values: usize, + value_type: ONNXType, + out: *mut *mut OrtValue, + ) -> OrtStatusPtr, + >, + pub CreateOpaqueValue: ::std::option::Option< + unsafe extern "C" fn( + domain_name: *const ::std::os::raw::c_char, + type_name: *const ::std::os::raw::c_char, + data_container: *const ::std::os::raw::c_void, + data_container_size: usize, + out: *mut *mut OrtValue, + ) -> OrtStatusPtr, + >, + pub GetOpaqueValue: ::std::option::Option< + unsafe extern "C" fn( + domain_name: *const ::std::os::raw::c_char, + type_name: *const ::std::os::raw::c_char, + in_: *const OrtValue, + data_container: *mut ::std::os::raw::c_void, + data_container_size: usize, + ) -> OrtStatusPtr, + >, + pub KernelInfoGetAttribute_float: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtKernelInfo, + name: *const ::std::os::raw::c_char, + out: *mut f32, + ) -> OrtStatusPtr, + >, + pub KernelInfoGetAttribute_int64: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtKernelInfo, + name: *const ::std::os::raw::c_char, + out: *mut i64, + ) -> OrtStatusPtr, + >, + pub KernelInfoGetAttribute_string: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtKernelInfo, + name: *const ::std::os::raw::c_char, + out: *mut ::std::os::raw::c_char, + size: *mut usize, + ) -> OrtStatusPtr, + >, + pub KernelContext_GetInputCount: ::std::option::Option< + unsafe extern "C" fn(context: *const OrtKernelContext, out: *mut usize) -> OrtStatusPtr, + >, + pub KernelContext_GetOutputCount: ::std::option::Option< + unsafe extern "C" fn(context: *const OrtKernelContext, out: *mut usize) -> OrtStatusPtr, + >, + pub KernelContext_GetInput: ::std::option::Option< + unsafe extern "C" fn( + context: *const OrtKernelContext, + index: usize, + out: *mut *const OrtValue, + ) -> OrtStatusPtr, + >, + pub KernelContext_GetOutput: ::std::option::Option< + unsafe extern "C" fn( + context: *mut OrtKernelContext, + index: usize, + dim_values: *const i64, + dim_count: usize, + out: *mut *mut OrtValue, + ) -> OrtStatusPtr, + >, + pub ReleaseEnv: ::std::option::Option, + pub ReleaseStatus: ::std::option::Option, + pub ReleaseMemoryInfo: ::std::option::Option, + pub ReleaseSession: ::std::option::Option, + pub ReleaseValue: ::std::option::Option, + pub ReleaseRunOptions: ::std::option::Option, + pub ReleaseTypeInfo: ::std::option::Option, + pub ReleaseTensorTypeAndShapeInfo: + ::std::option::Option, + pub ReleaseSessionOptions: + ::std::option::Option, + pub ReleaseCustomOpDomain: + ::std::option::Option, + pub GetDenotationFromTypeInfo: ::std::option::Option< + unsafe extern "C" fn( + type_info: *const OrtTypeInfo, + denotation: *mut *const ::std::os::raw::c_char, + len: *mut usize, + ) -> OrtStatusPtr, + >, + pub CastTypeInfoToMapTypeInfo: ::std::option::Option< + unsafe extern "C" fn( + type_info: *const OrtTypeInfo, + out: *mut *const OrtMapTypeInfo, + ) -> OrtStatusPtr, + >, + pub CastTypeInfoToSequenceTypeInfo: ::std::option::Option< + unsafe extern "C" fn( + type_info: *const OrtTypeInfo, + out: *mut *const OrtSequenceTypeInfo, + ) -> OrtStatusPtr, + >, + pub GetMapKeyType: ::std::option::Option< + unsafe extern "C" fn( + map_type_info: *const OrtMapTypeInfo, + out: *mut ONNXTensorElementDataType, + ) -> OrtStatusPtr, + >, + pub GetMapValueType: ::std::option::Option< + unsafe extern "C" fn( + map_type_info: *const OrtMapTypeInfo, + type_info: *mut *mut OrtTypeInfo, + ) -> OrtStatusPtr, + >, + pub GetSequenceElementType: ::std::option::Option< + unsafe extern "C" fn( + sequence_type_info: *const OrtSequenceTypeInfo, + type_info: *mut *mut OrtTypeInfo, + ) -> OrtStatusPtr, + >, + pub ReleaseMapTypeInfo: ::std::option::Option, + pub ReleaseSequenceTypeInfo: + ::std::option::Option, + pub SessionEndProfiling: ::std::option::Option< + unsafe extern "C" fn( + session: *mut OrtSession, + allocator: *mut OrtAllocator, + out: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub SessionGetModelMetadata: ::std::option::Option< + unsafe extern "C" fn( + session: *const OrtSession, + out: *mut *mut OrtModelMetadata, + ) -> OrtStatusPtr, + >, + pub ModelMetadataGetProducerName: ::std::option::Option< + unsafe extern "C" fn( + model_metadata: *const OrtModelMetadata, + allocator: *mut OrtAllocator, + value: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub ModelMetadataGetGraphName: ::std::option::Option< + unsafe extern "C" fn( + model_metadata: *const OrtModelMetadata, + allocator: *mut OrtAllocator, + value: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub ModelMetadataGetDomain: ::std::option::Option< + unsafe extern "C" fn( + model_metadata: *const OrtModelMetadata, + allocator: *mut OrtAllocator, + value: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub ModelMetadataGetDescription: ::std::option::Option< + unsafe extern "C" fn( + model_metadata: *const OrtModelMetadata, + allocator: *mut OrtAllocator, + value: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub ModelMetadataLookupCustomMetadataMap: ::std::option::Option< + unsafe extern "C" fn( + model_metadata: *const OrtModelMetadata, + allocator: *mut OrtAllocator, + key: *const ::std::os::raw::c_char, + value: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub ModelMetadataGetVersion: ::std::option::Option< + unsafe extern "C" fn( + model_metadata: *const OrtModelMetadata, + value: *mut i64, + ) -> OrtStatusPtr, + >, + pub ReleaseModelMetadata: + ::std::option::Option, + pub CreateEnvWithGlobalThreadPools: ::std::option::Option< + unsafe extern "C" fn( + log_severity_level: OrtLoggingLevel, + logid: *const ::std::os::raw::c_char, + tp_options: *const OrtThreadingOptions, + out: *mut *mut OrtEnv, + ) -> OrtStatusPtr, + >, + pub DisablePerSessionThreads: ::std::option::Option< + unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, + >, + pub CreateThreadingOptions: ::std::option::Option< + unsafe extern "C" fn(out: *mut *mut OrtThreadingOptions) -> OrtStatusPtr, + >, + pub ReleaseThreadingOptions: + ::std::option::Option, + pub ModelMetadataGetCustomMetadataMapKeys: ::std::option::Option< + unsafe extern "C" fn( + model_metadata: *const OrtModelMetadata, + allocator: *mut OrtAllocator, + keys: *mut *mut *mut ::std::os::raw::c_char, + num_keys: *mut i64, + ) -> OrtStatusPtr, + >, + pub AddFreeDimensionOverrideByName: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + dim_name: *const ::std::os::raw::c_char, + dim_value: i64, + ) -> OrtStatusPtr, + >, + pub GetAvailableProviders: ::std::option::Option< + unsafe extern "C" fn( + out_ptr: *mut *mut *mut ::std::os::raw::c_char, + provider_length: *mut ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub ReleaseAvailableProviders: ::std::option::Option< + unsafe extern "C" fn( + ptr: *mut *mut ::std::os::raw::c_char, + providers_length: ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub GetStringTensorElementLength: ::std::option::Option< + unsafe extern "C" fn(value: *const OrtValue, index: usize, out: *mut usize) -> OrtStatusPtr, + >, + pub GetStringTensorElement: ::std::option::Option< + unsafe extern "C" fn( + value: *const OrtValue, + s_len: usize, + index: usize, + s: *mut ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub FillStringTensorElement: ::std::option::Option< + unsafe extern "C" fn( + value: *mut OrtValue, + s: *const ::std::os::raw::c_char, + index: usize, + ) -> OrtStatusPtr, + >, + pub AddSessionConfigEntry: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + config_key: *const ::std::os::raw::c_char, + config_value: *const ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub CreateAllocator: ::std::option::Option< + unsafe extern "C" fn( + session: *const OrtSession, + mem_info: *const OrtMemoryInfo, + out: *mut *mut OrtAllocator, + ) -> OrtStatusPtr, + >, + pub ReleaseAllocator: ::std::option::Option, + pub RunWithBinding: ::std::option::Option< + unsafe extern "C" fn( + session: *mut OrtSession, + run_options: *const OrtRunOptions, + binding_ptr: *const OrtIoBinding, + ) -> OrtStatusPtr, + >, + pub CreateIoBinding: ::std::option::Option< + unsafe extern "C" fn(session: *mut OrtSession, out: *mut *mut OrtIoBinding) -> OrtStatusPtr, + >, + pub ReleaseIoBinding: ::std::option::Option, + pub BindInput: ::std::option::Option< + unsafe extern "C" fn( + binding_ptr: *mut OrtIoBinding, + name: *const ::std::os::raw::c_char, + val_ptr: *const OrtValue, + ) -> OrtStatusPtr, + >, + pub BindOutput: ::std::option::Option< + unsafe extern "C" fn( + binding_ptr: *mut OrtIoBinding, + name: *const ::std::os::raw::c_char, + val_ptr: *const OrtValue, + ) -> OrtStatusPtr, + >, + pub BindOutputToDevice: ::std::option::Option< + unsafe extern "C" fn( + binding_ptr: *mut OrtIoBinding, + name: *const ::std::os::raw::c_char, + mem_info_ptr: *const OrtMemoryInfo, + ) -> OrtStatusPtr, + >, + pub GetBoundOutputNames: ::std::option::Option< + unsafe extern "C" fn( + binding_ptr: *const OrtIoBinding, + allocator: *mut OrtAllocator, + buffer: *mut *mut ::std::os::raw::c_char, + lengths: *mut *mut usize, + count: *mut usize, + ) -> OrtStatusPtr, + >, + pub GetBoundOutputValues: ::std::option::Option< + unsafe extern "C" fn( + binding_ptr: *const OrtIoBinding, + allocator: *mut OrtAllocator, + output: *mut *mut *mut OrtValue, + output_count: *mut usize, + ) -> OrtStatusPtr, + >, + #[doc = " \\brief Clears any previously set Inputs for an ::OrtIoBinding"] + pub ClearBoundInputs: + ::std::option::Option, + #[doc = " \\brief Clears any previously set Outputs for an ::OrtIoBinding"] + pub ClearBoundOutputs: + ::std::option::Option, + pub TensorAt: ::std::option::Option< + unsafe extern "C" fn( + value: *mut OrtValue, + location_values: *const i64, + location_values_count: usize, + out: *mut *mut ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub CreateAndRegisterAllocator: ::std::option::Option< + unsafe extern "C" fn( + env: *mut OrtEnv, + mem_info: *const OrtMemoryInfo, + arena_cfg: *const OrtArenaCfg, + ) -> OrtStatusPtr, + >, + pub SetLanguageProjection: ::std::option::Option< + unsafe extern "C" fn( + ort_env: *const OrtEnv, + projection: OrtLanguageProjection, + ) -> OrtStatusPtr, + >, + pub SessionGetProfilingStartTimeNs: ::std::option::Option< + unsafe extern "C" fn(session: *const OrtSession, out: *mut u64) -> OrtStatusPtr, + >, + pub SetGlobalIntraOpNumThreads: ::std::option::Option< + unsafe extern "C" fn( + tp_options: *mut OrtThreadingOptions, + intra_op_num_threads: ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub SetGlobalInterOpNumThreads: ::std::option::Option< + unsafe extern "C" fn( + tp_options: *mut OrtThreadingOptions, + inter_op_num_threads: ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub SetGlobalSpinControl: ::std::option::Option< + unsafe extern "C" fn( + tp_options: *mut OrtThreadingOptions, + allow_spinning: ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub AddInitializer: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + name: *const ::std::os::raw::c_char, + val: *const OrtValue, + ) -> OrtStatusPtr, + >, + pub CreateEnvWithCustomLoggerAndGlobalThreadPools: ::std::option::Option< + unsafe extern "C" fn( + logging_function: OrtLoggingFunction, + logger_param: *mut ::std::os::raw::c_void, + log_severity_level: OrtLoggingLevel, + logid: *const ::std::os::raw::c_char, + tp_options: *const OrtThreadingOptions, + out: *mut *mut OrtEnv, + ) -> OrtStatusPtr, + >, + pub SessionOptionsAppendExecutionProvider_CUDA: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + cuda_options: *const OrtCUDAProviderOptions, + ) -> OrtStatusPtr, + >, + pub SessionOptionsAppendExecutionProvider_ROCM: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + rocm_options: *const OrtROCMProviderOptions, + ) -> OrtStatusPtr, + >, + pub SessionOptionsAppendExecutionProvider_OpenVINO: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + provider_options: *const OrtOpenVINOProviderOptions, + ) -> OrtStatusPtr, + >, + pub SetGlobalDenormalAsZero: ::std::option::Option< + unsafe extern "C" fn(tp_options: *mut OrtThreadingOptions) -> OrtStatusPtr, + >, + pub CreateArenaCfg: ::std::option::Option< + unsafe extern "C" fn( + max_mem: usize, + arena_extend_strategy: ::std::os::raw::c_int, + initial_chunk_size_bytes: ::std::os::raw::c_int, + max_dead_bytes_per_chunk: ::std::os::raw::c_int, + out: *mut *mut OrtArenaCfg, + ) -> OrtStatusPtr, + >, + pub ReleaseArenaCfg: ::std::option::Option, + pub ModelMetadataGetGraphDescription: ::std::option::Option< + unsafe extern "C" fn( + model_metadata: *const OrtModelMetadata, + allocator: *mut OrtAllocator, + value: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub SessionOptionsAppendExecutionProvider_TensorRT: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + tensorrt_options: *const OrtTensorRTProviderOptions, + ) -> OrtStatusPtr, + >, + pub SetCurrentGpuDeviceId: ::std::option::Option< + unsafe extern "C" fn(device_id: ::std::os::raw::c_int) -> OrtStatusPtr, + >, + pub GetCurrentGpuDeviceId: ::std::option::Option< + unsafe extern "C" fn(device_id: *mut ::std::os::raw::c_int) -> OrtStatusPtr, + >, + pub KernelInfoGetAttributeArray_float: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtKernelInfo, + name: *const ::std::os::raw::c_char, + out: *mut f32, + size: *mut usize, + ) -> OrtStatusPtr, + >, + pub KernelInfoGetAttributeArray_int64: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtKernelInfo, + name: *const ::std::os::raw::c_char, + out: *mut i64, + size: *mut usize, + ) -> OrtStatusPtr, + >, + pub CreateArenaCfgV2: ::std::option::Option< + unsafe extern "C" fn( + arena_config_keys: *const *const ::std::os::raw::c_char, + arena_config_values: *const usize, + num_keys: usize, + out: *mut *mut OrtArenaCfg, + ) -> OrtStatusPtr, + >, + pub AddRunConfigEntry: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtRunOptions, + config_key: *const ::std::os::raw::c_char, + config_value: *const ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + pub CreatePrepackedWeightsContainer: ::std::option::Option< + unsafe extern "C" fn(out: *mut *mut OrtPrepackedWeightsContainer) -> OrtStatusPtr, + >, + pub ReleasePrepackedWeightsContainer: + ::std::option::Option, + pub CreateSessionWithPrepackedWeightsContainer: ::std::option::Option< + unsafe extern "C" fn( + env: *const OrtEnv, + model_path: *const ::std::os::raw::c_char, + options: *const OrtSessionOptions, + prepacked_weights_container: *mut OrtPrepackedWeightsContainer, + out: *mut *mut OrtSession, + ) -> OrtStatusPtr, + >, + pub CreateSessionFromArrayWithPrepackedWeightsContainer: ::std::option::Option< + unsafe extern "C" fn( + env: *const OrtEnv, + model_data: *const ::std::os::raw::c_void, + model_data_length: usize, + options: *const OrtSessionOptions, + prepacked_weights_container: *mut OrtPrepackedWeightsContainer, + out: *mut *mut OrtSession, + ) -> OrtStatusPtr, + >, + pub SessionOptionsAppendExecutionProvider_TensorRT_V2: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + tensorrt_options: *const OrtTensorRTProviderOptionsV2, + ) -> OrtStatusPtr, + >, + pub CreateTensorRTProviderOptions: ::std::option::Option< + unsafe extern "C" fn(out: *mut *mut OrtTensorRTProviderOptionsV2) -> OrtStatusPtr, + >, + pub UpdateTensorRTProviderOptions: ::std::option::Option< + unsafe extern "C" fn( + tensorrt_options: *mut OrtTensorRTProviderOptionsV2, + provider_options_keys: *const *const ::std::os::raw::c_char, + provider_options_values: *const *const ::std::os::raw::c_char, + num_keys: usize, + ) -> OrtStatusPtr, + >, + pub GetTensorRTProviderOptionsAsString: ::std::option::Option< + unsafe extern "C" fn( + tensorrt_options: *const OrtTensorRTProviderOptionsV2, + allocator: *mut OrtAllocator, + ptr: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + #[doc = " \\brief Release an ::OrtTensorRTProviderOptionsV2"] + #[doc = ""] + #[doc = " \\note This is an exception in the naming convention of other Release* functions, as the name of the method does not have the V2 suffix, but the type does"] + pub ReleaseTensorRTProviderOptions: + ::std::option::Option, + pub EnableOrtCustomOps: ::std::option::Option< + unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, + >, + pub RegisterAllocator: ::std::option::Option< + unsafe extern "C" fn(env: *mut OrtEnv, allocator: *mut OrtAllocator) -> OrtStatusPtr, + >, + pub UnregisterAllocator: ::std::option::Option< + unsafe extern "C" fn(env: *mut OrtEnv, mem_info: *const OrtMemoryInfo) -> OrtStatusPtr, + >, + pub IsSparseTensor: ::std::option::Option< + unsafe extern "C" fn( + value: *const OrtValue, + out: *mut ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub CreateSparseTensorAsOrtValue: ::std::option::Option< + unsafe extern "C" fn( + allocator: *mut OrtAllocator, + dense_shape: *const i64, + dense_shape_len: usize, + type_: ONNXTensorElementDataType, + out: *mut *mut OrtValue, + ) -> OrtStatusPtr, + >, + pub FillSparseTensorCoo: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *mut OrtValue, + data_mem_info: *const OrtMemoryInfo, + values_shape: *const i64, + values_shape_len: usize, + values: *const ::std::os::raw::c_void, + indices_data: *const i64, + indices_num: usize, + ) -> OrtStatusPtr, + >, + pub FillSparseTensorCsr: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *mut OrtValue, + data_mem_info: *const OrtMemoryInfo, + values_shape: *const i64, + values_shape_len: usize, + values: *const ::std::os::raw::c_void, + inner_indices_data: *const i64, + inner_indices_num: usize, + outer_indices_data: *const i64, + outer_indices_num: usize, + ) -> OrtStatusPtr, + >, + pub FillSparseTensorBlockSparse: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *mut OrtValue, + data_mem_info: *const OrtMemoryInfo, + values_shape: *const i64, + values_shape_len: usize, + values: *const ::std::os::raw::c_void, + indices_shape_data: *const i64, + indices_shape_len: usize, + indices_data: *const i32, + ) -> OrtStatusPtr, + >, + pub CreateSparseTensorWithValuesAsOrtValue: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtMemoryInfo, + p_data: *mut ::std::os::raw::c_void, + dense_shape: *const i64, + dense_shape_len: usize, + values_shape: *const i64, + values_shape_len: usize, + type_: ONNXTensorElementDataType, + out: *mut *mut OrtValue, + ) -> OrtStatusPtr, + >, + pub UseCooIndices: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *mut OrtValue, + indices_data: *mut i64, + indices_num: usize, + ) -> OrtStatusPtr, + >, + pub UseCsrIndices: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *mut OrtValue, + inner_data: *mut i64, + inner_num: usize, + outer_data: *mut i64, + outer_num: usize, + ) -> OrtStatusPtr, + >, + pub UseBlockSparseIndices: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *mut OrtValue, + indices_shape: *const i64, + indices_shape_len: usize, + indices_data: *mut i32, + ) -> OrtStatusPtr, + >, + pub GetSparseTensorFormat: ::std::option::Option< + unsafe extern "C" fn(ort_value: *const OrtValue, out: *mut OrtSparseFormat) -> OrtStatusPtr, + >, + pub GetSparseTensorValuesTypeAndShape: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *const OrtValue, + out: *mut *mut OrtTensorTypeAndShapeInfo, + ) -> OrtStatusPtr, + >, + pub GetSparseTensorValues: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *const OrtValue, + out: *mut *const ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub GetSparseTensorIndicesTypeShape: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *const OrtValue, + indices_format: OrtSparseIndicesFormat, + out: *mut *mut OrtTensorTypeAndShapeInfo, + ) -> OrtStatusPtr, + >, + pub GetSparseTensorIndices: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *const OrtValue, + indices_format: OrtSparseIndicesFormat, + num_indices: *mut usize, + indices: *mut *const ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub HasValue: ::std::option::Option< + unsafe extern "C" fn( + value: *const OrtValue, + out: *mut ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub KernelContext_GetGPUComputeStream: ::std::option::Option< + unsafe extern "C" fn( + context: *const OrtKernelContext, + out: *mut *mut ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub GetTensorMemoryInfo: ::std::option::Option< + unsafe extern "C" fn( + value: *const OrtValue, + mem_info: *mut *const OrtMemoryInfo, + ) -> OrtStatusPtr, + >, + pub GetExecutionProviderApi: ::std::option::Option< + unsafe extern "C" fn( + provider_name: *const ::std::os::raw::c_char, + version: u32, + provider_api: *mut *const ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub SessionOptionsSetCustomCreateThreadFn: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + ort_custom_create_thread_fn: OrtCustomCreateThreadFn, + ) -> OrtStatusPtr, + >, + pub SessionOptionsSetCustomThreadCreationOptions: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + ort_custom_thread_creation_options: *mut ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub SessionOptionsSetCustomJoinThreadFn: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + ort_custom_join_thread_fn: OrtCustomJoinThreadFn, + ) -> OrtStatusPtr, + >, + pub SetGlobalCustomCreateThreadFn: ::std::option::Option< + unsafe extern "C" fn( + tp_options: *mut OrtThreadingOptions, + ort_custom_create_thread_fn: OrtCustomCreateThreadFn, + ) -> OrtStatusPtr, + >, + pub SetGlobalCustomThreadCreationOptions: ::std::option::Option< + unsafe extern "C" fn( + tp_options: *mut OrtThreadingOptions, + ort_custom_thread_creation_options: *mut ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub SetGlobalCustomJoinThreadFn: ::std::option::Option< + unsafe extern "C" fn( + tp_options: *mut OrtThreadingOptions, + ort_custom_join_thread_fn: OrtCustomJoinThreadFn, + ) -> OrtStatusPtr, + >, + pub SynchronizeBoundInputs: + ::std::option::Option OrtStatusPtr>, + pub SynchronizeBoundOutputs: + ::std::option::Option OrtStatusPtr>, + pub SessionOptionsAppendExecutionProvider_CUDA_V2: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + cuda_options: *const OrtCUDAProviderOptionsV2, + ) -> OrtStatusPtr, + >, + pub CreateCUDAProviderOptions: ::std::option::Option< + unsafe extern "C" fn(out: *mut *mut OrtCUDAProviderOptionsV2) -> OrtStatusPtr, + >, + pub UpdateCUDAProviderOptions: ::std::option::Option< + unsafe extern "C" fn( + cuda_options: *mut OrtCUDAProviderOptionsV2, + provider_options_keys: *const *const ::std::os::raw::c_char, + provider_options_values: *const *const ::std::os::raw::c_char, + num_keys: usize, + ) -> OrtStatusPtr, + >, + pub GetCUDAProviderOptionsAsString: ::std::option::Option< + unsafe extern "C" fn( + cuda_options: *const OrtCUDAProviderOptionsV2, + allocator: *mut OrtAllocator, + ptr: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + #[doc = " \\brief Release an ::OrtCUDAProviderOptionsV2"] + #[doc = ""] + #[doc = " \\note This is an exception in the naming convention of other Release* functions, as the name of the method does not have the V2 suffix, but the type does"] + #[doc = ""] + #[doc = " \\since Version 1.11."] + pub ReleaseCUDAProviderOptions: + ::std::option::Option, + pub SessionOptionsAppendExecutionProvider_MIGraphX: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + migraphx_options: *const OrtMIGraphXProviderOptions, + ) -> OrtStatusPtr, + >, +} +#[test] +fn bindgen_test_layout_OrtApi() { assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateSessionWithPrepackedWeightsContainer - as *const _ as usize - }, - 1344usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateSessionWithPrepackedWeightsContainer) - ) + ::std::mem::size_of::(), + 1680usize, + concat!("Size of: ", stringify!(OrtApi)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateSessionFromArrayWithPrepackedWeightsContainer - as *const _ as usize - }, - 1352usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateSessionFromArrayWithPrepackedWeightsContainer) - ) + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(OrtApi)) ); + fn test_field_CreateStatus() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateStatus) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateStatus) + ) + ); + } + test_field_CreateStatus(); + fn test_field_GetErrorCode() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetErrorCode) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetErrorCode) + ) + ); + } + test_field_GetErrorCode(); + fn test_field_GetErrorMessage() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetErrorMessage) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetErrorMessage) + ) + ); + } + test_field_GetErrorMessage(); + fn test_field_CreateEnv() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateEnv) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateEnv) + ) + ); + } + test_field_CreateEnv(); + fn test_field_CreateEnvWithCustomLogger() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateEnvWithCustomLogger) as usize - ptr as usize + }, + 32usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateEnvWithCustomLogger) + ) + ); + } + test_field_CreateEnvWithCustomLogger(); + fn test_field_EnableTelemetryEvents() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).EnableTelemetryEvents) as usize - ptr as usize + }, + 40usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(EnableTelemetryEvents) + ) + ); + } + test_field_EnableTelemetryEvents(); + fn test_field_DisableTelemetryEvents() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).DisableTelemetryEvents) as usize - ptr as usize + }, + 48usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(DisableTelemetryEvents) + ) + ); + } + test_field_DisableTelemetryEvents(); + fn test_field_CreateSession() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateSession) as usize - ptr as usize + }, + 56usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateSession) + ) + ); + } + test_field_CreateSession(); + fn test_field_CreateSessionFromArray() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateSessionFromArray) as usize - ptr as usize + }, + 64usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateSessionFromArray) + ) + ); + } + test_field_CreateSessionFromArray(); + fn test_field_Run() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).Run) as usize - ptr as usize + }, + 72usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(Run) + ) + ); + } + test_field_Run(); + fn test_field_CreateSessionOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateSessionOptions) as usize - ptr as usize + }, + 80usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateSessionOptions) + ) + ); + } + test_field_CreateSessionOptions(); + fn test_field_SetOptimizedModelFilePath() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetOptimizedModelFilePath) as usize - ptr as usize + }, + 88usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetOptimizedModelFilePath) + ) + ); + } + test_field_SetOptimizedModelFilePath(); + fn test_field_CloneSessionOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CloneSessionOptions) as usize - ptr as usize + }, + 96usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CloneSessionOptions) + ) + ); + } + test_field_CloneSessionOptions(); + fn test_field_SetSessionExecutionMode() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetSessionExecutionMode) as usize - ptr as usize + }, + 104usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetSessionExecutionMode) + ) + ); + } + test_field_SetSessionExecutionMode(); + fn test_field_EnableProfiling() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).EnableProfiling) as usize - ptr as usize + }, + 112usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(EnableProfiling) + ) + ); + } + test_field_EnableProfiling(); + fn test_field_DisableProfiling() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).DisableProfiling) as usize - ptr as usize + }, + 120usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(DisableProfiling) + ) + ); + } + test_field_DisableProfiling(); + fn test_field_EnableMemPattern() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).EnableMemPattern) as usize - ptr as usize + }, + 128usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(EnableMemPattern) + ) + ); + } + test_field_EnableMemPattern(); + fn test_field_DisableMemPattern() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).DisableMemPattern) as usize - ptr as usize + }, + 136usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(DisableMemPattern) + ) + ); + } + test_field_DisableMemPattern(); + fn test_field_EnableCpuMemArena() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).EnableCpuMemArena) as usize - ptr as usize + }, + 144usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(EnableCpuMemArena) + ) + ); + } + test_field_EnableCpuMemArena(); + fn test_field_DisableCpuMemArena() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).DisableCpuMemArena) as usize - ptr as usize + }, + 152usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(DisableCpuMemArena) + ) + ); + } + test_field_DisableCpuMemArena(); + fn test_field_SetSessionLogId() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetSessionLogId) as usize - ptr as usize + }, + 160usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetSessionLogId) + ) + ); + } + test_field_SetSessionLogId(); + fn test_field_SetSessionLogVerbosityLevel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetSessionLogVerbosityLevel) as usize - ptr as usize + }, + 168usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetSessionLogVerbosityLevel) + ) + ); + } + test_field_SetSessionLogVerbosityLevel(); + fn test_field_SetSessionLogSeverityLevel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetSessionLogSeverityLevel) as usize - ptr as usize + }, + 176usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetSessionLogSeverityLevel) + ) + ); + } + test_field_SetSessionLogSeverityLevel(); + fn test_field_SetSessionGraphOptimizationLevel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetSessionGraphOptimizationLevel) as usize + - ptr as usize + }, + 184usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetSessionGraphOptimizationLevel) + ) + ); + } + test_field_SetSessionGraphOptimizationLevel(); + fn test_field_SetIntraOpNumThreads() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetIntraOpNumThreads) as usize - ptr as usize + }, + 192usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetIntraOpNumThreads) + ) + ); + } + test_field_SetIntraOpNumThreads(); + fn test_field_SetInterOpNumThreads() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetInterOpNumThreads) as usize - ptr as usize + }, + 200usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetInterOpNumThreads) + ) + ); + } + test_field_SetInterOpNumThreads(); + fn test_field_CreateCustomOpDomain() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateCustomOpDomain) as usize - ptr as usize + }, + 208usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateCustomOpDomain) + ) + ); + } + test_field_CreateCustomOpDomain(); + fn test_field_CustomOpDomain_Add() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CustomOpDomain_Add) as usize - ptr as usize + }, + 216usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CustomOpDomain_Add) + ) + ); + } + test_field_CustomOpDomain_Add(); + fn test_field_AddCustomOpDomain() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AddCustomOpDomain) as usize - ptr as usize + }, + 224usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AddCustomOpDomain) + ) + ); + } + test_field_AddCustomOpDomain(); + fn test_field_RegisterCustomOpsLibrary() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RegisterCustomOpsLibrary) as usize - ptr as usize + }, + 232usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RegisterCustomOpsLibrary) + ) + ); + } + test_field_RegisterCustomOpsLibrary(); + fn test_field_SessionGetInputCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetInputCount) as usize - ptr as usize + }, + 240usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetInputCount) + ) + ); + } + test_field_SessionGetInputCount(); + fn test_field_SessionGetOutputCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetOutputCount) as usize - ptr as usize + }, + 248usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetOutputCount) + ) + ); + } + test_field_SessionGetOutputCount(); + fn test_field_SessionGetOverridableInitializerCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetOverridableInitializerCount) as usize + - ptr as usize + }, + 256usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetOverridableInitializerCount) + ) + ); + } + test_field_SessionGetOverridableInitializerCount(); + fn test_field_SessionGetInputTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetInputTypeInfo) as usize - ptr as usize + }, + 264usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetInputTypeInfo) + ) + ); + } + test_field_SessionGetInputTypeInfo(); + fn test_field_SessionGetOutputTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetOutputTypeInfo) as usize - ptr as usize + }, + 272usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetOutputTypeInfo) + ) + ); + } + test_field_SessionGetOutputTypeInfo(); + fn test_field_SessionGetOverridableInitializerTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetOverridableInitializerTypeInfo) as usize + - ptr as usize + }, + 280usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetOverridableInitializerTypeInfo) + ) + ); + } + test_field_SessionGetOverridableInitializerTypeInfo(); + fn test_field_SessionGetInputName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetInputName) as usize - ptr as usize + }, + 288usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetInputName) + ) + ); + } + test_field_SessionGetInputName(); + fn test_field_SessionGetOutputName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetOutputName) as usize - ptr as usize + }, + 296usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetOutputName) + ) + ); + } + test_field_SessionGetOutputName(); + fn test_field_SessionGetOverridableInitializerName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetOverridableInitializerName) as usize + - ptr as usize + }, + 304usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetOverridableInitializerName) + ) + ); + } + test_field_SessionGetOverridableInitializerName(); + fn test_field_CreateRunOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateRunOptions) as usize - ptr as usize + }, + 312usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateRunOptions) + ) + ); + } + test_field_CreateRunOptions(); + fn test_field_RunOptionsSetRunLogVerbosityLevel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsSetRunLogVerbosityLevel) as usize + - ptr as usize + }, + 320usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsSetRunLogVerbosityLevel) + ) + ); + } + test_field_RunOptionsSetRunLogVerbosityLevel(); + fn test_field_RunOptionsSetRunLogSeverityLevel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsSetRunLogSeverityLevel) as usize + - ptr as usize + }, + 328usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsSetRunLogSeverityLevel) + ) + ); + } + test_field_RunOptionsSetRunLogSeverityLevel(); + fn test_field_RunOptionsSetRunTag() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsSetRunTag) as usize - ptr as usize + }, + 336usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsSetRunTag) + ) + ); + } + test_field_RunOptionsSetRunTag(); + fn test_field_RunOptionsGetRunLogVerbosityLevel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsGetRunLogVerbosityLevel) as usize + - ptr as usize + }, + 344usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsGetRunLogVerbosityLevel) + ) + ); + } + test_field_RunOptionsGetRunLogVerbosityLevel(); + fn test_field_RunOptionsGetRunLogSeverityLevel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsGetRunLogSeverityLevel) as usize + - ptr as usize + }, + 352usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsGetRunLogSeverityLevel) + ) + ); + } + test_field_RunOptionsGetRunLogSeverityLevel(); + fn test_field_RunOptionsGetRunTag() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsGetRunTag) as usize - ptr as usize + }, + 360usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsGetRunTag) + ) + ); + } + test_field_RunOptionsGetRunTag(); + fn test_field_RunOptionsSetTerminate() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsSetTerminate) as usize - ptr as usize + }, + 368usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsSetTerminate) + ) + ); + } + test_field_RunOptionsSetTerminate(); + fn test_field_RunOptionsUnsetTerminate() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsUnsetTerminate) as usize - ptr as usize + }, + 376usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsUnsetTerminate) + ) + ); + } + test_field_RunOptionsUnsetTerminate(); + fn test_field_CreateTensorAsOrtValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateTensorAsOrtValue) as usize - ptr as usize + }, + 384usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateTensorAsOrtValue) + ) + ); + } + test_field_CreateTensorAsOrtValue(); + fn test_field_CreateTensorWithDataAsOrtValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateTensorWithDataAsOrtValue) as usize - ptr as usize + }, + 392usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateTensorWithDataAsOrtValue) + ) + ); + } + test_field_CreateTensorWithDataAsOrtValue(); + fn test_field_IsTensor() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).IsTensor) as usize - ptr as usize + }, + 400usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(IsTensor) + ) + ); + } + test_field_IsTensor(); + fn test_field_GetTensorMutableData() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetTensorMutableData) as usize - ptr as usize + }, + 408usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetTensorMutableData) + ) + ); + } + test_field_GetTensorMutableData(); + fn test_field_FillStringTensor() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).FillStringTensor) as usize - ptr as usize + }, + 416usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(FillStringTensor) + ) + ); + } + test_field_FillStringTensor(); + fn test_field_GetStringTensorDataLength() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetStringTensorDataLength) as usize - ptr as usize + }, + 424usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetStringTensorDataLength) + ) + ); + } + test_field_GetStringTensorDataLength(); + fn test_field_GetStringTensorContent() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetStringTensorContent) as usize - ptr as usize + }, + 432usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetStringTensorContent) + ) + ); + } + test_field_GetStringTensorContent(); + fn test_field_CastTypeInfoToTensorInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CastTypeInfoToTensorInfo) as usize - ptr as usize + }, + 440usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CastTypeInfoToTensorInfo) + ) + ); + } + test_field_CastTypeInfoToTensorInfo(); + fn test_field_GetOnnxTypeFromTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetOnnxTypeFromTypeInfo) as usize - ptr as usize + }, + 448usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetOnnxTypeFromTypeInfo) + ) + ); + } + test_field_GetOnnxTypeFromTypeInfo(); + fn test_field_CreateTensorTypeAndShapeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateTensorTypeAndShapeInfo) as usize - ptr as usize + }, + 456usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateTensorTypeAndShapeInfo) + ) + ); + } + test_field_CreateTensorTypeAndShapeInfo(); + fn test_field_SetTensorElementType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetTensorElementType) as usize - ptr as usize + }, + 464usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetTensorElementType) + ) + ); + } + test_field_SetTensorElementType(); + fn test_field_SetDimensions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetDimensions) as usize - ptr as usize + }, + 472usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetDimensions) + ) + ); + } + test_field_SetDimensions(); + fn test_field_GetTensorElementType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetTensorElementType) as usize - ptr as usize + }, + 480usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetTensorElementType) + ) + ); + } + test_field_GetTensorElementType(); + fn test_field_GetDimensionsCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetDimensionsCount) as usize - ptr as usize + }, + 488usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetDimensionsCount) + ) + ); + } + test_field_GetDimensionsCount(); + fn test_field_GetDimensions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetDimensions) as usize - ptr as usize + }, + 496usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetDimensions) + ) + ); + } + test_field_GetDimensions(); + fn test_field_GetSymbolicDimensions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetSymbolicDimensions) as usize - ptr as usize + }, + 504usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetSymbolicDimensions) + ) + ); + } + test_field_GetSymbolicDimensions(); + fn test_field_GetTensorShapeElementCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetTensorShapeElementCount) as usize - ptr as usize + }, + 512usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetTensorShapeElementCount) + ) + ); + } + test_field_GetTensorShapeElementCount(); + fn test_field_GetTensorTypeAndShape() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetTensorTypeAndShape) as usize - ptr as usize + }, + 520usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetTensorTypeAndShape) + ) + ); + } + test_field_GetTensorTypeAndShape(); + fn test_field_GetTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetTypeInfo) as usize - ptr as usize + }, + 528usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetTypeInfo) + ) + ); + } + test_field_GetTypeInfo(); + fn test_field_GetValueType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetValueType) as usize - ptr as usize + }, + 536usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetValueType) + ) + ); + } + test_field_GetValueType(); + fn test_field_CreateMemoryInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateMemoryInfo) as usize - ptr as usize + }, + 544usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateMemoryInfo) + ) + ); + } + test_field_CreateMemoryInfo(); + fn test_field_CreateCpuMemoryInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateCpuMemoryInfo) as usize - ptr as usize + }, + 552usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateCpuMemoryInfo) + ) + ); + } + test_field_CreateCpuMemoryInfo(); + fn test_field_CompareMemoryInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CompareMemoryInfo) as usize - ptr as usize + }, + 560usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CompareMemoryInfo) + ) + ); + } + test_field_CompareMemoryInfo(); + fn test_field_MemoryInfoGetName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).MemoryInfoGetName) as usize - ptr as usize + }, + 568usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(MemoryInfoGetName) + ) + ); + } + test_field_MemoryInfoGetName(); + fn test_field_MemoryInfoGetId() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).MemoryInfoGetId) as usize - ptr as usize + }, + 576usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(MemoryInfoGetId) + ) + ); + } + test_field_MemoryInfoGetId(); + fn test_field_MemoryInfoGetMemType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).MemoryInfoGetMemType) as usize - ptr as usize + }, + 584usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(MemoryInfoGetMemType) + ) + ); + } + test_field_MemoryInfoGetMemType(); + fn test_field_MemoryInfoGetType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).MemoryInfoGetType) as usize - ptr as usize + }, + 592usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(MemoryInfoGetType) + ) + ); + } + test_field_MemoryInfoGetType(); + fn test_field_AllocatorAlloc() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AllocatorAlloc) as usize - ptr as usize + }, + 600usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AllocatorAlloc) + ) + ); + } + test_field_AllocatorAlloc(); + fn test_field_AllocatorFree() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AllocatorFree) as usize - ptr as usize + }, + 608usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AllocatorFree) + ) + ); + } + test_field_AllocatorFree(); + fn test_field_AllocatorGetInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AllocatorGetInfo) as usize - ptr as usize + }, + 616usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AllocatorGetInfo) + ) + ); + } + test_field_AllocatorGetInfo(); + fn test_field_GetAllocatorWithDefaultOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetAllocatorWithDefaultOptions) as usize - ptr as usize + }, + 624usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetAllocatorWithDefaultOptions) + ) + ); + } + test_field_GetAllocatorWithDefaultOptions(); + fn test_field_AddFreeDimensionOverride() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AddFreeDimensionOverride) as usize - ptr as usize + }, + 632usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AddFreeDimensionOverride) + ) + ); + } + test_field_AddFreeDimensionOverride(); + fn test_field_GetValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetValue) as usize - ptr as usize + }, + 640usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetValue) + ) + ); + } + test_field_GetValue(); + fn test_field_GetValueCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetValueCount) as usize - ptr as usize + }, + 648usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetValueCount) + ) + ); + } + test_field_GetValueCount(); + fn test_field_CreateValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateValue) as usize - ptr as usize + }, + 656usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateValue) + ) + ); + } + test_field_CreateValue(); + fn test_field_CreateOpaqueValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateOpaqueValue) as usize - ptr as usize + }, + 664usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateOpaqueValue) + ) + ); + } + test_field_CreateOpaqueValue(); + fn test_field_GetOpaqueValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetOpaqueValue) as usize - ptr as usize + }, + 672usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetOpaqueValue) + ) + ); + } + test_field_GetOpaqueValue(); + fn test_field_KernelInfoGetAttribute_float() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelInfoGetAttribute_float) as usize - ptr as usize + }, + 680usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelInfoGetAttribute_float) + ) + ); + } + test_field_KernelInfoGetAttribute_float(); + fn test_field_KernelInfoGetAttribute_int64() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelInfoGetAttribute_int64) as usize - ptr as usize + }, + 688usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelInfoGetAttribute_int64) + ) + ); + } + test_field_KernelInfoGetAttribute_int64(); + fn test_field_KernelInfoGetAttribute_string() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelInfoGetAttribute_string) as usize - ptr as usize + }, + 696usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelInfoGetAttribute_string) + ) + ); + } + test_field_KernelInfoGetAttribute_string(); + fn test_field_KernelContext_GetInputCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelContext_GetInputCount) as usize - ptr as usize + }, + 704usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelContext_GetInputCount) + ) + ); + } + test_field_KernelContext_GetInputCount(); + fn test_field_KernelContext_GetOutputCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelContext_GetOutputCount) as usize - ptr as usize + }, + 712usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelContext_GetOutputCount) + ) + ); + } + test_field_KernelContext_GetOutputCount(); + fn test_field_KernelContext_GetInput() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelContext_GetInput) as usize - ptr as usize + }, + 720usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelContext_GetInput) + ) + ); + } + test_field_KernelContext_GetInput(); + fn test_field_KernelContext_GetOutput() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelContext_GetOutput) as usize - ptr as usize + }, + 728usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelContext_GetOutput) + ) + ); + } + test_field_KernelContext_GetOutput(); + fn test_field_ReleaseEnv() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseEnv) as usize - ptr as usize + }, + 736usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseEnv) + ) + ); + } + test_field_ReleaseEnv(); + fn test_field_ReleaseStatus() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseStatus) as usize - ptr as usize + }, + 744usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseStatus) + ) + ); + } + test_field_ReleaseStatus(); + fn test_field_ReleaseMemoryInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseMemoryInfo) as usize - ptr as usize + }, + 752usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseMemoryInfo) + ) + ); + } + test_field_ReleaseMemoryInfo(); + fn test_field_ReleaseSession() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseSession) as usize - ptr as usize + }, + 760usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseSession) + ) + ); + } + test_field_ReleaseSession(); + fn test_field_ReleaseValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseValue) as usize - ptr as usize + }, + 768usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseValue) + ) + ); + } + test_field_ReleaseValue(); + fn test_field_ReleaseRunOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseRunOptions) as usize - ptr as usize + }, + 776usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseRunOptions) + ) + ); + } + test_field_ReleaseRunOptions(); + fn test_field_ReleaseTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseTypeInfo) as usize - ptr as usize + }, + 784usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseTypeInfo) + ) + ); + } + test_field_ReleaseTypeInfo(); + fn test_field_ReleaseTensorTypeAndShapeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseTensorTypeAndShapeInfo) as usize - ptr as usize + }, + 792usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseTensorTypeAndShapeInfo) + ) + ); + } + test_field_ReleaseTensorTypeAndShapeInfo(); + fn test_field_ReleaseSessionOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseSessionOptions) as usize - ptr as usize + }, + 800usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseSessionOptions) + ) + ); + } + test_field_ReleaseSessionOptions(); + fn test_field_ReleaseCustomOpDomain() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseCustomOpDomain) as usize - ptr as usize + }, + 808usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseCustomOpDomain) + ) + ); + } + test_field_ReleaseCustomOpDomain(); + fn test_field_GetDenotationFromTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetDenotationFromTypeInfo) as usize - ptr as usize + }, + 816usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetDenotationFromTypeInfo) + ) + ); + } + test_field_GetDenotationFromTypeInfo(); + fn test_field_CastTypeInfoToMapTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CastTypeInfoToMapTypeInfo) as usize - ptr as usize + }, + 824usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CastTypeInfoToMapTypeInfo) + ) + ); + } + test_field_CastTypeInfoToMapTypeInfo(); + fn test_field_CastTypeInfoToSequenceTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CastTypeInfoToSequenceTypeInfo) as usize - ptr as usize + }, + 832usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CastTypeInfoToSequenceTypeInfo) + ) + ); + } + test_field_CastTypeInfoToSequenceTypeInfo(); + fn test_field_GetMapKeyType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetMapKeyType) as usize - ptr as usize + }, + 840usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetMapKeyType) + ) + ); + } + test_field_GetMapKeyType(); + fn test_field_GetMapValueType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetMapValueType) as usize - ptr as usize + }, + 848usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetMapValueType) + ) + ); + } + test_field_GetMapValueType(); + fn test_field_GetSequenceElementType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetSequenceElementType) as usize - ptr as usize + }, + 856usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetSequenceElementType) + ) + ); + } + test_field_GetSequenceElementType(); + fn test_field_ReleaseMapTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseMapTypeInfo) as usize - ptr as usize + }, + 864usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseMapTypeInfo) + ) + ); + } + test_field_ReleaseMapTypeInfo(); + fn test_field_ReleaseSequenceTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseSequenceTypeInfo) as usize - ptr as usize + }, + 872usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseSequenceTypeInfo) + ) + ); + } + test_field_ReleaseSequenceTypeInfo(); + fn test_field_SessionEndProfiling() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionEndProfiling) as usize - ptr as usize + }, + 880usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionEndProfiling) + ) + ); + } + test_field_SessionEndProfiling(); + fn test_field_SessionGetModelMetadata() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetModelMetadata) as usize - ptr as usize + }, + 888usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetModelMetadata) + ) + ); + } + test_field_SessionGetModelMetadata(); + fn test_field_ModelMetadataGetProducerName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataGetProducerName) as usize - ptr as usize + }, + 896usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataGetProducerName) + ) + ); + } + test_field_ModelMetadataGetProducerName(); + fn test_field_ModelMetadataGetGraphName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataGetGraphName) as usize - ptr as usize + }, + 904usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataGetGraphName) + ) + ); + } + test_field_ModelMetadataGetGraphName(); + fn test_field_ModelMetadataGetDomain() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataGetDomain) as usize - ptr as usize + }, + 912usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataGetDomain) + ) + ); + } + test_field_ModelMetadataGetDomain(); + fn test_field_ModelMetadataGetDescription() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataGetDescription) as usize - ptr as usize + }, + 920usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataGetDescription) + ) + ); + } + test_field_ModelMetadataGetDescription(); + fn test_field_ModelMetadataLookupCustomMetadataMap() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataLookupCustomMetadataMap) as usize + - ptr as usize + }, + 928usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataLookupCustomMetadataMap) + ) + ); + } + test_field_ModelMetadataLookupCustomMetadataMap(); + fn test_field_ModelMetadataGetVersion() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataGetVersion) as usize - ptr as usize + }, + 936usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataGetVersion) + ) + ); + } + test_field_ModelMetadataGetVersion(); + fn test_field_ReleaseModelMetadata() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseModelMetadata) as usize - ptr as usize + }, + 944usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseModelMetadata) + ) + ); + } + test_field_ReleaseModelMetadata(); + fn test_field_CreateEnvWithGlobalThreadPools() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateEnvWithGlobalThreadPools) as usize - ptr as usize + }, + 952usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateEnvWithGlobalThreadPools) + ) + ); + } + test_field_CreateEnvWithGlobalThreadPools(); + fn test_field_DisablePerSessionThreads() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).DisablePerSessionThreads) as usize - ptr as usize + }, + 960usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(DisablePerSessionThreads) + ) + ); + } + test_field_DisablePerSessionThreads(); + fn test_field_CreateThreadingOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateThreadingOptions) as usize - ptr as usize + }, + 968usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateThreadingOptions) + ) + ); + } + test_field_CreateThreadingOptions(); + fn test_field_ReleaseThreadingOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseThreadingOptions) as usize - ptr as usize + }, + 976usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseThreadingOptions) + ) + ); + } + test_field_ReleaseThreadingOptions(); + fn test_field_ModelMetadataGetCustomMetadataMapKeys() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataGetCustomMetadataMapKeys) as usize + - ptr as usize + }, + 984usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataGetCustomMetadataMapKeys) + ) + ); + } + test_field_ModelMetadataGetCustomMetadataMapKeys(); + fn test_field_AddFreeDimensionOverrideByName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AddFreeDimensionOverrideByName) as usize - ptr as usize + }, + 992usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AddFreeDimensionOverrideByName) + ) + ); + } + test_field_AddFreeDimensionOverrideByName(); + fn test_field_GetAvailableProviders() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetAvailableProviders) as usize - ptr as usize + }, + 1000usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetAvailableProviders) + ) + ); + } + test_field_GetAvailableProviders(); + fn test_field_ReleaseAvailableProviders() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseAvailableProviders) as usize - ptr as usize + }, + 1008usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseAvailableProviders) + ) + ); + } + test_field_ReleaseAvailableProviders(); + fn test_field_GetStringTensorElementLength() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetStringTensorElementLength) as usize - ptr as usize + }, + 1016usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetStringTensorElementLength) + ) + ); + } + test_field_GetStringTensorElementLength(); + fn test_field_GetStringTensorElement() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetStringTensorElement) as usize - ptr as usize + }, + 1024usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetStringTensorElement) + ) + ); + } + test_field_GetStringTensorElement(); + fn test_field_FillStringTensorElement() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).FillStringTensorElement) as usize - ptr as usize + }, + 1032usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(FillStringTensorElement) + ) + ); + } + test_field_FillStringTensorElement(); + fn test_field_AddSessionConfigEntry() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AddSessionConfigEntry) as usize - ptr as usize + }, + 1040usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AddSessionConfigEntry) + ) + ); + } + test_field_AddSessionConfigEntry(); + fn test_field_CreateAllocator() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateAllocator) as usize - ptr as usize + }, + 1048usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateAllocator) + ) + ); + } + test_field_CreateAllocator(); + fn test_field_ReleaseAllocator() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseAllocator) as usize - ptr as usize + }, + 1056usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseAllocator) + ) + ); + } + test_field_ReleaseAllocator(); + fn test_field_RunWithBinding() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunWithBinding) as usize - ptr as usize + }, + 1064usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunWithBinding) + ) + ); + } + test_field_RunWithBinding(); + fn test_field_CreateIoBinding() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateIoBinding) as usize - ptr as usize + }, + 1072usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateIoBinding) + ) + ); + } + test_field_CreateIoBinding(); + fn test_field_ReleaseIoBinding() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseIoBinding) as usize - ptr as usize + }, + 1080usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseIoBinding) + ) + ); + } + test_field_ReleaseIoBinding(); + fn test_field_BindInput() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).BindInput) as usize - ptr as usize + }, + 1088usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(BindInput) + ) + ); + } + test_field_BindInput(); + fn test_field_BindOutput() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).BindOutput) as usize - ptr as usize + }, + 1096usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(BindOutput) + ) + ); + } + test_field_BindOutput(); + fn test_field_BindOutputToDevice() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).BindOutputToDevice) as usize - ptr as usize + }, + 1104usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(BindOutputToDevice) + ) + ); + } + test_field_BindOutputToDevice(); + fn test_field_GetBoundOutputNames() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetBoundOutputNames) as usize - ptr as usize + }, + 1112usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetBoundOutputNames) + ) + ); + } + test_field_GetBoundOutputNames(); + fn test_field_GetBoundOutputValues() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetBoundOutputValues) as usize - ptr as usize + }, + 1120usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetBoundOutputValues) + ) + ); + } + test_field_GetBoundOutputValues(); + fn test_field_ClearBoundInputs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ClearBoundInputs) as usize - ptr as usize + }, + 1128usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ClearBoundInputs) + ) + ); + } + test_field_ClearBoundInputs(); + fn test_field_ClearBoundOutputs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ClearBoundOutputs) as usize - ptr as usize + }, + 1136usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ClearBoundOutputs) + ) + ); + } + test_field_ClearBoundOutputs(); + fn test_field_TensorAt() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).TensorAt) as usize - ptr as usize + }, + 1144usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(TensorAt) + ) + ); + } + test_field_TensorAt(); + fn test_field_CreateAndRegisterAllocator() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateAndRegisterAllocator) as usize - ptr as usize + }, + 1152usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateAndRegisterAllocator) + ) + ); + } + test_field_CreateAndRegisterAllocator(); + fn test_field_SetLanguageProjection() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetLanguageProjection) as usize - ptr as usize + }, + 1160usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetLanguageProjection) + ) + ); + } + test_field_SetLanguageProjection(); + fn test_field_SessionGetProfilingStartTimeNs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetProfilingStartTimeNs) as usize - ptr as usize + }, + 1168usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetProfilingStartTimeNs) + ) + ); + } + test_field_SessionGetProfilingStartTimeNs(); + fn test_field_SetGlobalIntraOpNumThreads() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetGlobalIntraOpNumThreads) as usize - ptr as usize + }, + 1176usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetGlobalIntraOpNumThreads) + ) + ); + } + test_field_SetGlobalIntraOpNumThreads(); + fn test_field_SetGlobalInterOpNumThreads() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetGlobalInterOpNumThreads) as usize - ptr as usize + }, + 1184usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetGlobalInterOpNumThreads) + ) + ); + } + test_field_SetGlobalInterOpNumThreads(); + fn test_field_SetGlobalSpinControl() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetGlobalSpinControl) as usize - ptr as usize + }, + 1192usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetGlobalSpinControl) + ) + ); + } + test_field_SetGlobalSpinControl(); + fn test_field_AddInitializer() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AddInitializer) as usize - ptr as usize + }, + 1200usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AddInitializer) + ) + ); + } + test_field_AddInitializer(); + fn test_field_CreateEnvWithCustomLoggerAndGlobalThreadPools() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateEnvWithCustomLoggerAndGlobalThreadPools) as usize + - ptr as usize + }, + 1208usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateEnvWithCustomLoggerAndGlobalThreadPools) + ) + ); + } + test_field_CreateEnvWithCustomLoggerAndGlobalThreadPools(); + fn test_field_SessionOptionsAppendExecutionProvider_CUDA() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsAppendExecutionProvider_CUDA) as usize + - ptr as usize + }, + 1216usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsAppendExecutionProvider_CUDA) + ) + ); + } + test_field_SessionOptionsAppendExecutionProvider_CUDA(); + fn test_field_SessionOptionsAppendExecutionProvider_ROCM() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsAppendExecutionProvider_ROCM) as usize + - ptr as usize + }, + 1224usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsAppendExecutionProvider_ROCM) + ) + ); + } + test_field_SessionOptionsAppendExecutionProvider_ROCM(); + fn test_field_SessionOptionsAppendExecutionProvider_OpenVINO() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsAppendExecutionProvider_OpenVINO) as usize + - ptr as usize + }, + 1232usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsAppendExecutionProvider_OpenVINO) + ) + ); + } + test_field_SessionOptionsAppendExecutionProvider_OpenVINO(); + fn test_field_SetGlobalDenormalAsZero() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetGlobalDenormalAsZero) as usize - ptr as usize + }, + 1240usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetGlobalDenormalAsZero) + ) + ); + } + test_field_SetGlobalDenormalAsZero(); + fn test_field_CreateArenaCfg() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateArenaCfg) as usize - ptr as usize + }, + 1248usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateArenaCfg) + ) + ); + } + test_field_CreateArenaCfg(); + fn test_field_ReleaseArenaCfg() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseArenaCfg) as usize - ptr as usize + }, + 1256usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseArenaCfg) + ) + ); + } + test_field_ReleaseArenaCfg(); + fn test_field_ModelMetadataGetGraphDescription() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataGetGraphDescription) as usize + - ptr as usize + }, + 1264usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataGetGraphDescription) + ) + ); + } + test_field_ModelMetadataGetGraphDescription(); + fn test_field_SessionOptionsAppendExecutionProvider_TensorRT() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsAppendExecutionProvider_TensorRT) as usize + - ptr as usize + }, + 1272usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsAppendExecutionProvider_TensorRT) + ) + ); + } + test_field_SessionOptionsAppendExecutionProvider_TensorRT(); + fn test_field_SetCurrentGpuDeviceId() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetCurrentGpuDeviceId) as usize - ptr as usize + }, + 1280usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetCurrentGpuDeviceId) + ) + ); + } + test_field_SetCurrentGpuDeviceId(); + fn test_field_GetCurrentGpuDeviceId() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetCurrentGpuDeviceId) as usize - ptr as usize + }, + 1288usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetCurrentGpuDeviceId) + ) + ); + } + test_field_GetCurrentGpuDeviceId(); + fn test_field_KernelInfoGetAttributeArray_float() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelInfoGetAttributeArray_float) as usize + - ptr as usize + }, + 1296usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelInfoGetAttributeArray_float) + ) + ); + } + test_field_KernelInfoGetAttributeArray_float(); + fn test_field_KernelInfoGetAttributeArray_int64() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelInfoGetAttributeArray_int64) as usize + - ptr as usize + }, + 1304usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelInfoGetAttributeArray_int64) + ) + ); + } + test_field_KernelInfoGetAttributeArray_int64(); + fn test_field_CreateArenaCfgV2() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateArenaCfgV2) as usize - ptr as usize + }, + 1312usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateArenaCfgV2) + ) + ); + } + test_field_CreateArenaCfgV2(); + fn test_field_AddRunConfigEntry() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AddRunConfigEntry) as usize - ptr as usize + }, + 1320usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AddRunConfigEntry) + ) + ); + } + test_field_AddRunConfigEntry(); + fn test_field_CreatePrepackedWeightsContainer() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreatePrepackedWeightsContainer) as usize - ptr as usize + }, + 1328usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreatePrepackedWeightsContainer) + ) + ); + } + test_field_CreatePrepackedWeightsContainer(); + fn test_field_ReleasePrepackedWeightsContainer() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleasePrepackedWeightsContainer) as usize + - ptr as usize + }, + 1336usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleasePrepackedWeightsContainer) + ) + ); + } + test_field_ReleasePrepackedWeightsContainer(); + fn test_field_CreateSessionWithPrepackedWeightsContainer() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateSessionWithPrepackedWeightsContainer) as usize + - ptr as usize + }, + 1344usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateSessionWithPrepackedWeightsContainer) + ) + ); + } + test_field_CreateSessionWithPrepackedWeightsContainer(); + fn test_field_CreateSessionFromArrayWithPrepackedWeightsContainer() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateSessionFromArrayWithPrepackedWeightsContainer) + as usize + - ptr as usize + }, + 1352usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateSessionFromArrayWithPrepackedWeightsContainer) + ) + ); + } + test_field_CreateSessionFromArrayWithPrepackedWeightsContainer(); + fn test_field_SessionOptionsAppendExecutionProvider_TensorRT_V2() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsAppendExecutionProvider_TensorRT_V2) + as usize + - ptr as usize + }, + 1360usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsAppendExecutionProvider_TensorRT_V2) + ) + ); + } + test_field_SessionOptionsAppendExecutionProvider_TensorRT_V2(); + fn test_field_CreateTensorRTProviderOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateTensorRTProviderOptions) as usize - ptr as usize + }, + 1368usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateTensorRTProviderOptions) + ) + ); + } + test_field_CreateTensorRTProviderOptions(); + fn test_field_UpdateTensorRTProviderOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).UpdateTensorRTProviderOptions) as usize - ptr as usize + }, + 1376usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(UpdateTensorRTProviderOptions) + ) + ); + } + test_field_UpdateTensorRTProviderOptions(); + fn test_field_GetTensorRTProviderOptionsAsString() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetTensorRTProviderOptionsAsString) as usize + - ptr as usize + }, + 1384usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetTensorRTProviderOptionsAsString) + ) + ); + } + test_field_GetTensorRTProviderOptionsAsString(); + fn test_field_ReleaseTensorRTProviderOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseTensorRTProviderOptions) as usize - ptr as usize + }, + 1392usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseTensorRTProviderOptions) + ) + ); + } + test_field_ReleaseTensorRTProviderOptions(); + fn test_field_EnableOrtCustomOps() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).EnableOrtCustomOps) as usize - ptr as usize + }, + 1400usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(EnableOrtCustomOps) + ) + ); + } + test_field_EnableOrtCustomOps(); + fn test_field_RegisterAllocator() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RegisterAllocator) as usize - ptr as usize + }, + 1408usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RegisterAllocator) + ) + ); + } + test_field_RegisterAllocator(); + fn test_field_UnregisterAllocator() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).UnregisterAllocator) as usize - ptr as usize + }, + 1416usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(UnregisterAllocator) + ) + ); + } + test_field_UnregisterAllocator(); + fn test_field_IsSparseTensor() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).IsSparseTensor) as usize - ptr as usize + }, + 1424usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(IsSparseTensor) + ) + ); + } + test_field_IsSparseTensor(); + fn test_field_CreateSparseTensorAsOrtValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateSparseTensorAsOrtValue) as usize - ptr as usize + }, + 1432usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateSparseTensorAsOrtValue) + ) + ); + } + test_field_CreateSparseTensorAsOrtValue(); + fn test_field_FillSparseTensorCoo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).FillSparseTensorCoo) as usize - ptr as usize + }, + 1440usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(FillSparseTensorCoo) + ) + ); + } + test_field_FillSparseTensorCoo(); + fn test_field_FillSparseTensorCsr() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).FillSparseTensorCsr) as usize - ptr as usize + }, + 1448usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(FillSparseTensorCsr) + ) + ); + } + test_field_FillSparseTensorCsr(); + fn test_field_FillSparseTensorBlockSparse() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).FillSparseTensorBlockSparse) as usize - ptr as usize + }, + 1456usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(FillSparseTensorBlockSparse) + ) + ); + } + test_field_FillSparseTensorBlockSparse(); + fn test_field_CreateSparseTensorWithValuesAsOrtValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateSparseTensorWithValuesAsOrtValue) as usize + - ptr as usize + }, + 1464usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateSparseTensorWithValuesAsOrtValue) + ) + ); + } + test_field_CreateSparseTensorWithValuesAsOrtValue(); + fn test_field_UseCooIndices() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).UseCooIndices) as usize - ptr as usize + }, + 1472usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(UseCooIndices) + ) + ); + } + test_field_UseCooIndices(); + fn test_field_UseCsrIndices() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).UseCsrIndices) as usize - ptr as usize + }, + 1480usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(UseCsrIndices) + ) + ); + } + test_field_UseCsrIndices(); + fn test_field_UseBlockSparseIndices() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).UseBlockSparseIndices) as usize - ptr as usize + }, + 1488usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(UseBlockSparseIndices) + ) + ); + } + test_field_UseBlockSparseIndices(); + fn test_field_GetSparseTensorFormat() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetSparseTensorFormat) as usize - ptr as usize + }, + 1496usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetSparseTensorFormat) + ) + ); + } + test_field_GetSparseTensorFormat(); + fn test_field_GetSparseTensorValuesTypeAndShape() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetSparseTensorValuesTypeAndShape) as usize + - ptr as usize + }, + 1504usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetSparseTensorValuesTypeAndShape) + ) + ); + } + test_field_GetSparseTensorValuesTypeAndShape(); + fn test_field_GetSparseTensorValues() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetSparseTensorValues) as usize - ptr as usize + }, + 1512usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetSparseTensorValues) + ) + ); + } + test_field_GetSparseTensorValues(); + fn test_field_GetSparseTensorIndicesTypeShape() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetSparseTensorIndicesTypeShape) as usize - ptr as usize + }, + 1520usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetSparseTensorIndicesTypeShape) + ) + ); + } + test_field_GetSparseTensorIndicesTypeShape(); + fn test_field_GetSparseTensorIndices() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetSparseTensorIndices) as usize - ptr as usize + }, + 1528usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetSparseTensorIndices) + ) + ); + } + test_field_GetSparseTensorIndices(); + fn test_field_HasValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).HasValue) as usize - ptr as usize + }, + 1536usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(HasValue) + ) + ); + } + test_field_HasValue(); + fn test_field_KernelContext_GetGPUComputeStream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelContext_GetGPUComputeStream) as usize + - ptr as usize + }, + 1544usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelContext_GetGPUComputeStream) + ) + ); + } + test_field_KernelContext_GetGPUComputeStream(); + fn test_field_GetTensorMemoryInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetTensorMemoryInfo) as usize - ptr as usize + }, + 1552usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetTensorMemoryInfo) + ) + ); + } + test_field_GetTensorMemoryInfo(); + fn test_field_GetExecutionProviderApi() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetExecutionProviderApi) as usize - ptr as usize + }, + 1560usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetExecutionProviderApi) + ) + ); + } + test_field_GetExecutionProviderApi(); + fn test_field_SessionOptionsSetCustomCreateThreadFn() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsSetCustomCreateThreadFn) as usize + - ptr as usize + }, + 1568usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsSetCustomCreateThreadFn) + ) + ); + } + test_field_SessionOptionsSetCustomCreateThreadFn(); + fn test_field_SessionOptionsSetCustomThreadCreationOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsSetCustomThreadCreationOptions) as usize + - ptr as usize + }, + 1576usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsSetCustomThreadCreationOptions) + ) + ); + } + test_field_SessionOptionsSetCustomThreadCreationOptions(); + fn test_field_SessionOptionsSetCustomJoinThreadFn() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsSetCustomJoinThreadFn) as usize + - ptr as usize + }, + 1584usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsSetCustomJoinThreadFn) + ) + ); + } + test_field_SessionOptionsSetCustomJoinThreadFn(); + fn test_field_SetGlobalCustomCreateThreadFn() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetGlobalCustomCreateThreadFn) as usize - ptr as usize + }, + 1592usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetGlobalCustomCreateThreadFn) + ) + ); + } + test_field_SetGlobalCustomCreateThreadFn(); + fn test_field_SetGlobalCustomThreadCreationOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetGlobalCustomThreadCreationOptions) as usize + - ptr as usize + }, + 1600usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetGlobalCustomThreadCreationOptions) + ) + ); + } + test_field_SetGlobalCustomThreadCreationOptions(); + fn test_field_SetGlobalCustomJoinThreadFn() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetGlobalCustomJoinThreadFn) as usize - ptr as usize + }, + 1608usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetGlobalCustomJoinThreadFn) + ) + ); + } + test_field_SetGlobalCustomJoinThreadFn(); + fn test_field_SynchronizeBoundInputs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SynchronizeBoundInputs) as usize - ptr as usize + }, + 1616usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SynchronizeBoundInputs) + ) + ); + } + test_field_SynchronizeBoundInputs(); + fn test_field_SynchronizeBoundOutputs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SynchronizeBoundOutputs) as usize - ptr as usize + }, + 1624usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SynchronizeBoundOutputs) + ) + ); + } + test_field_SynchronizeBoundOutputs(); + fn test_field_SessionOptionsAppendExecutionProvider_CUDA_V2() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsAppendExecutionProvider_CUDA_V2) as usize + - ptr as usize + }, + 1632usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsAppendExecutionProvider_CUDA_V2) + ) + ); + } + test_field_SessionOptionsAppendExecutionProvider_CUDA_V2(); + fn test_field_CreateCUDAProviderOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateCUDAProviderOptions) as usize - ptr as usize + }, + 1640usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateCUDAProviderOptions) + ) + ); + } + test_field_CreateCUDAProviderOptions(); + fn test_field_UpdateCUDAProviderOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).UpdateCUDAProviderOptions) as usize - ptr as usize + }, + 1648usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(UpdateCUDAProviderOptions) + ) + ); + } + test_field_UpdateCUDAProviderOptions(); + fn test_field_GetCUDAProviderOptionsAsString() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetCUDAProviderOptionsAsString) as usize - ptr as usize + }, + 1656usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetCUDAProviderOptionsAsString) + ) + ); + } + test_field_GetCUDAProviderOptionsAsString(); + fn test_field_ReleaseCUDAProviderOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseCUDAProviderOptions) as usize - ptr as usize + }, + 1664usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseCUDAProviderOptions) + ) + ); + } + test_field_ReleaseCUDAProviderOptions(); + fn test_field_SessionOptionsAppendExecutionProvider_MIGraphX() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsAppendExecutionProvider_MIGraphX) as usize + - ptr as usize + }, + 1672usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsAppendExecutionProvider_MIGraphX) + ) + ); + } + test_field_SessionOptionsAppendExecutionProvider_MIGraphX(); } #[repr(u32)] #[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] @@ -15806,192 +9542,225 @@ fn bindgen_test_layout_OrtCustomOp() { 8usize, concat!("Alignment of ", stringify!(OrtCustomOp)) ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).version as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(version) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateKernel as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(CreateKernel) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetName as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetName) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetExecutionProviderType as *const _ as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetExecutionProviderType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetInputType as *const _ as usize }, - 32usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetInputType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetInputTypeCount as *const _ as usize }, - 40usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetInputTypeCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetOutputType as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetOutputType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetOutputTypeCount as *const _ as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetOutputTypeCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).KernelCompute as *const _ as usize }, - 64usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(KernelCompute) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).KernelDestroy as *const _ as usize }, - 72usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(KernelDestroy) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetInputCharacteristic as *const _ as usize - }, - 80usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetInputCharacteristic) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetOutputCharacteristic as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetOutputCharacteristic) - ) - ); + fn test_field_version() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).version) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(version) + ) + ); + } + test_field_version(); + fn test_field_CreateKernel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateKernel) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(CreateKernel) + ) + ); + } + test_field_CreateKernel(); + fn test_field_GetName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetName) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetName) + ) + ); + } + test_field_GetName(); + fn test_field_GetExecutionProviderType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetExecutionProviderType) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetExecutionProviderType) + ) + ); + } + test_field_GetExecutionProviderType(); + fn test_field_GetInputType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetInputType) as usize - ptr as usize + }, + 32usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetInputType) + ) + ); + } + test_field_GetInputType(); + fn test_field_GetInputTypeCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetInputTypeCount) as usize - ptr as usize + }, + 40usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetInputTypeCount) + ) + ); + } + test_field_GetInputTypeCount(); + fn test_field_GetOutputType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetOutputType) as usize - ptr as usize + }, + 48usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetOutputType) + ) + ); + } + test_field_GetOutputType(); + fn test_field_GetOutputTypeCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetOutputTypeCount) as usize - ptr as usize + }, + 56usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetOutputTypeCount) + ) + ); + } + test_field_GetOutputTypeCount(); + fn test_field_KernelCompute() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelCompute) as usize - ptr as usize + }, + 64usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(KernelCompute) + ) + ); + } + test_field_KernelCompute(); + fn test_field_KernelDestroy() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelDestroy) as usize - ptr as usize + }, + 72usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(KernelDestroy) + ) + ); + } + test_field_KernelDestroy(); + fn test_field_GetInputCharacteristic() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetInputCharacteristic) as usize - ptr as usize + }, + 80usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetInputCharacteristic) + ) + ); + } + test_field_GetInputCharacteristic(); + fn test_field_GetOutputCharacteristic() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetOutputCharacteristic) as usize - ptr as usize + }, + 88usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetOutputCharacteristic) + ) + ); + } + test_field_GetOutputCharacteristic(); +} +extern "C" { + pub fn OrtSessionOptionsAppendExecutionProvider_CUDA( + options: *mut OrtSessionOptions, + device_id: ::std::os::raw::c_int, + ) -> OrtStatusPtr; +} +extern "C" { + pub fn OrtSessionOptionsAppendExecutionProvider_MIGraphX( + options: *mut OrtSessionOptions, + device_id: ::std::os::raw::c_int, + ) -> OrtStatusPtr; } -pub type __builtin_va_list = [__va_list_tag; 1usize]; #[repr(C)] #[derive(Debug, Copy, Clone)] -pub struct __va_list_tag { - pub gp_offset: ::std::os::raw::c_uint, - pub fp_offset: ::std::os::raw::c_uint, - pub overflow_arg_area: *mut ::std::os::raw::c_void, - pub reg_save_area: *mut ::std::os::raw::c_void, -} -#[test] -fn bindgen_test_layout___va_list_tag() { - assert_eq!( - ::std::mem::size_of::<__va_list_tag>(), - 24usize, - concat!("Size of: ", stringify!(__va_list_tag)) - ); - assert_eq!( - ::std::mem::align_of::<__va_list_tag>(), - 8usize, - concat!("Alignment of ", stringify!(__va_list_tag)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__va_list_tag>())).gp_offset as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__va_list_tag), - "::", - stringify!(gp_offset) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__va_list_tag>())).fp_offset as *const _ as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(__va_list_tag), - "::", - stringify!(fp_offset) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__va_list_tag>())).overflow_arg_area as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__va_list_tag), - "::", - stringify!(overflow_arg_area) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__va_list_tag>())).reg_save_area as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(__va_list_tag), - "::", - stringify!(reg_save_area) - ) - ); +pub struct __locale_data { + pub _address: u8, } diff --git a/onnxruntime-sys/src/generated/windows/x86/bindings.rs b/onnxruntime-sys/src/generated/windows/x86/bindings.rs index 53dfca67..228b94dd 100644 --- a/onnxruntime-sys/src/generated/windows/x86/bindings.rs +++ b/onnxruntime-sys/src/generated/windows/x86/bindings.rs @@ -1,4 +1,4 @@ -/* automatically generated by rust-bindgen 0.59.1 */ +/* automatically generated by rust-bindgen 0.60.1 */ pub const _VCRT_COMPILER_PREPROCESSOR: u32 = 1; pub const _SAL_VERSION: u32 = 20; @@ -165,7 +165,7 @@ pub const ETIMEDOUT: u32 = 138; pub const ETXTBSY: u32 = 139; pub const EWOULDBLOCK: u32 = 140; pub const _NLSCMPERROR: u32 = 2147483647; -pub const ORT_API_VERSION: u32 = 8; +pub const ORT_API_VERSION: u32 = 11; pub const __SAL_H_FULL_VER: u32 = 140050727; pub const __SPECSTRINGS_STRICT_LEVEL: u32 = 1; pub const __drv_typeConst: u32 = 0; @@ -227,44 +227,57 @@ fn bindgen_test_layout___crt_locale_data_public() { 4usize, concat!("Alignment of ", stringify!(__crt_locale_data_public)) ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__crt_locale_data_public>()))._locale_pctype as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__crt_locale_data_public), - "::", - stringify!(_locale_pctype) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__crt_locale_data_public>()))._locale_mb_cur_max as *const _ - as usize - }, - 4usize, - concat!( - "Offset of field: ", - stringify!(__crt_locale_data_public), - "::", - stringify!(_locale_mb_cur_max) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__crt_locale_data_public>()))._locale_lc_codepage as *const _ - as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__crt_locale_data_public), - "::", - stringify!(_locale_lc_codepage) - ) - ); + fn test_field__locale_pctype() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__crt_locale_data_public>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr)._locale_pctype) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__crt_locale_data_public), + "::", + stringify!(_locale_pctype) + ) + ); + } + test_field__locale_pctype(); + fn test_field__locale_mb_cur_max() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__crt_locale_data_public>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr)._locale_mb_cur_max) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(__crt_locale_data_public), + "::", + stringify!(_locale_mb_cur_max) + ) + ); + } + test_field__locale_mb_cur_max(); + fn test_field__locale_lc_codepage() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__crt_locale_data_public>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr)._locale_lc_codepage) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__crt_locale_data_public), + "::", + stringify!(_locale_lc_codepage) + ) + ); + } + test_field__locale_lc_codepage(); } #[repr(C)] #[derive(Debug, Copy, Clone)] @@ -284,26 +297,40 @@ fn bindgen_test_layout___crt_locale_pointers() { 4usize, concat!("Alignment of ", stringify!(__crt_locale_pointers)) ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__crt_locale_pointers>())).locinfo as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__crt_locale_pointers), - "::", - stringify!(locinfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__crt_locale_pointers>())).mbcinfo as *const _ as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(__crt_locale_pointers), - "::", - stringify!(mbcinfo) - ) - ); + fn test_field_locinfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__crt_locale_pointers>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).locinfo) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__crt_locale_pointers), + "::", + stringify!(locinfo) + ) + ); + } + test_field_locinfo(); + fn test_field_mbcinfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__crt_locale_pointers>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).mbcinfo) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(__crt_locale_pointers), + "::", + stringify!(mbcinfo) + ) + ); + } + test_field_mbcinfo(); } pub type _locale_t = *mut __crt_locale_pointers; #[repr(C)] @@ -325,36 +352,57 @@ fn bindgen_test_layout__Mbstatet() { 4usize, concat!("Alignment of ", stringify!(_Mbstatet)) ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_Mbstatet>()))._Wchar as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_Mbstatet), - "::", - stringify!(_Wchar) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_Mbstatet>()))._Byte as *const _ as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(_Mbstatet), - "::", - stringify!(_Byte) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_Mbstatet>()))._State as *const _ as usize }, - 6usize, - concat!( - "Offset of field: ", - stringify!(_Mbstatet), - "::", - stringify!(_State) - ) - ); + fn test_field__Wchar() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<_Mbstatet>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr)._Wchar) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(_Mbstatet), + "::", + stringify!(_Wchar) + ) + ); + } + test_field__Wchar(); + fn test_field__Byte() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<_Mbstatet>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr)._Byte) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(_Mbstatet), + "::", + stringify!(_Byte) + ) + ); + } + test_field__Byte(); + fn test_field__State() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<_Mbstatet>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr)._State) as usize - ptr as usize + }, + 6usize, + concat!( + "Offset of field: ", + stringify!(_Mbstatet), + "::", + stringify!(_State) + ) + ); + } + test_field__State(); } pub type mbstate_t = _Mbstatet; pub type time_t = __time64_t; @@ -473,7 +521,21 @@ extern "C" { _Alignment: usize, ) -> *mut ::std::os::raw::c_void; } -pub type max_align_t = f64; +extern "C" { + pub fn _errno() -> *mut ::std::os::raw::c_int; +} +extern "C" { + pub fn _set_errno(_Value: ::std::os::raw::c_int) -> errno_t; +} +extern "C" { + pub fn _get_errno(_Value: *mut ::std::os::raw::c_int) -> errno_t; +} +extern "C" { + pub fn __threadid() -> ::std::os::raw::c_ulong; +} +extern "C" { + pub fn __threadhandle() -> usize; +} pub type _CoreCrtSecureSearchSortCompareFunction = ::std::option::Option< unsafe extern "C" fn( arg1: *mut ::std::os::raw::c_void, @@ -972,15 +1034,6 @@ extern "C" { extern "C" { pub fn _set_error_mode(_Mode: ::std::os::raw::c_int) -> ::std::os::raw::c_int; } -extern "C" { - pub fn _errno() -> *mut ::std::os::raw::c_int; -} -extern "C" { - pub fn _set_errno(_Value: ::std::os::raw::c_int) -> errno_t; -} -extern "C" { - pub fn _get_errno(_Value: *mut ::std::os::raw::c_int) -> errno_t; -} extern "C" { pub fn __doserrno() -> *mut ::std::os::raw::c_ulong; } @@ -1038,26 +1091,40 @@ fn bindgen_test_layout__div_t() { 4usize, concat!("Alignment of ", stringify!(_div_t)) ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_div_t>())).quot as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_div_t), - "::", - stringify!(quot) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_div_t>())).rem as *const _ as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(_div_t), - "::", - stringify!(rem) - ) - ); + fn test_field_quot() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<_div_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).quot) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(_div_t), + "::", + stringify!(quot) + ) + ); + } + test_field_quot(); + fn test_field_rem() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<_div_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).rem) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(_div_t), + "::", + stringify!(rem) + ) + ); + } + test_field_rem(); } pub type div_t = _div_t; #[repr(C)] @@ -1078,26 +1145,40 @@ fn bindgen_test_layout__ldiv_t() { 4usize, concat!("Alignment of ", stringify!(_ldiv_t)) ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_ldiv_t>())).quot as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_ldiv_t), - "::", - stringify!(quot) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_ldiv_t>())).rem as *const _ as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(_ldiv_t), - "::", - stringify!(rem) - ) - ); + fn test_field_quot() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<_ldiv_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).quot) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(_ldiv_t), + "::", + stringify!(quot) + ) + ); + } + test_field_quot(); + fn test_field_rem() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<_ldiv_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).rem) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(_ldiv_t), + "::", + stringify!(rem) + ) + ); + } + test_field_rem(); } pub type ldiv_t = _ldiv_t; #[repr(C)] @@ -1118,26 +1199,40 @@ fn bindgen_test_layout__lldiv_t() { 8usize, concat!("Alignment of ", stringify!(_lldiv_t)) ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_lldiv_t>())).quot as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_lldiv_t), - "::", - stringify!(quot) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_lldiv_t>())).rem as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(_lldiv_t), - "::", - stringify!(rem) - ) - ); + fn test_field_quot() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<_lldiv_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).quot) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(_lldiv_t), + "::", + stringify!(quot) + ) + ); + } + test_field_quot(); + fn test_field_rem() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<_lldiv_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).rem) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(_lldiv_t), + "::", + stringify!(rem) + ) + ); + } + test_field_rem(); } pub type lldiv_t = _lldiv_t; extern "C" { @@ -1233,16 +1328,23 @@ fn bindgen_test_layout__LDOUBLE() { 1usize, concat!("Alignment of ", stringify!(_LDOUBLE)) ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_LDOUBLE>())).ld as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_LDOUBLE), - "::", - stringify!(ld) - ) - ); + fn test_field_ld() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<_LDOUBLE>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ld) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(_LDOUBLE), + "::", + stringify!(ld) + ) + ); + } + test_field_ld(); } #[repr(C)] #[derive(Debug, Copy, Clone)] @@ -1261,16 +1363,23 @@ fn bindgen_test_layout__CRT_DOUBLE() { 8usize, concat!("Alignment of ", stringify!(_CRT_DOUBLE)) ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_CRT_DOUBLE>())).x as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_CRT_DOUBLE), - "::", - stringify!(x) - ) - ); + fn test_field_x() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<_CRT_DOUBLE>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).x) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(_CRT_DOUBLE), + "::", + stringify!(x) + ) + ); + } + test_field_x(); } #[repr(C)] #[derive(Debug, Copy, Clone)] @@ -1289,16 +1398,23 @@ fn bindgen_test_layout__CRT_FLOAT() { 4usize, concat!("Alignment of ", stringify!(_CRT_FLOAT)) ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_CRT_FLOAT>())).f as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_CRT_FLOAT), - "::", - stringify!(f) - ) - ); + fn test_field_f() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<_CRT_FLOAT>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).f) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(_CRT_FLOAT), + "::", + stringify!(f) + ) + ); + } + test_field_f(); } #[repr(C)] #[derive(Debug, Copy, Clone)] @@ -1317,16 +1433,23 @@ fn bindgen_test_layout__LONGDOUBLE() { 8usize, concat!("Alignment of ", stringify!(_LONGDOUBLE)) ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_LONGDOUBLE>())).x as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_LONGDOUBLE), - "::", - stringify!(x) - ) - ); + fn test_field_x() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<_LONGDOUBLE>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).x) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(_LONGDOUBLE), + "::", + stringify!(x) + ) + ); + } + test_field_x(); } #[repr(C)] #[derive(Debug, Copy, Clone)] @@ -1345,16 +1468,23 @@ fn bindgen_test_layout__LDBL12() { 1usize, concat!("Alignment of ", stringify!(_LDBL12)) ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_LDBL12>())).ld12 as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_LDBL12), - "::", - stringify!(ld12) - ) - ); + fn test_field_ld12() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<_LDBL12>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ld12) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(_LDBL12), + "::", + stringify!(ld12) + ) + ); + } + test_field_ld12(); } extern "C" { pub fn atof(_String: *const ::std::os::raw::c_char) -> f64; @@ -2756,6 +2886,8 @@ extern "C" { pub fn strupr(_String: *mut ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; } #[repr(i32)] +#[doc = " Copied from TensorProto::DataType"] +#[doc = " Currently, Ort doesn't support complex64, complex128"] #[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] pub enum ONNXTensorElementDataType { ONNX_TENSOR_ELEMENT_DATA_TYPE_UNDEFINED = 0, @@ -2785,14 +2917,39 @@ pub enum ONNXType { ONNX_TYPE_MAP = 3, ONNX_TYPE_OPAQUE = 4, ONNX_TYPE_SPARSETENSOR = 5, + ONNX_TYPE_OPTIONAL = 6, +} +#[repr(i32)] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum OrtSparseFormat { + ORT_SPARSE_UNDEFINED = 0, + ORT_SPARSE_COO = 1, + ORT_SPARSE_CSRC = 2, + ORT_SPARSE_BLOCK_SPARSE = 4, +} +#[repr(i32)] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum OrtSparseIndicesFormat { + ORT_SPARSE_COO_INDICES = 0, + ORT_SPARSE_CSR_INNER_INDICES = 1, + ORT_SPARSE_CSR_OUTER_INDICES = 2, + ORT_SPARSE_BLOCK_SPARSE_INDICES = 3, } #[repr(i32)] +#[doc = " \\brief Logging severity levels"] +#[doc = ""] +#[doc = " In typical API usage, specifying a logging severity level specifies the minimum severity of log messages to show."] #[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] pub enum OrtLoggingLevel { + #[doc = "< Verbose informational messages (least severe)."] ORT_LOGGING_LEVEL_VERBOSE = 0, + #[doc = "< Informational messages."] ORT_LOGGING_LEVEL_INFO = 1, + #[doc = "< Warning messages."] ORT_LOGGING_LEVEL_WARNING = 2, + #[doc = "< Error messages."] ORT_LOGGING_LEVEL_ERROR = 3, + #[doc = "< Fatal error messages (most severe)."] ORT_LOGGING_LEVEL_FATAL = 4, } #[repr(i32)] @@ -2901,20 +3058,39 @@ pub struct OrtArenaCfg { pub struct OrtPrepackedWeightsContainer { _unused: [u8; 0], } +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtTensorRTProviderOptionsV2 { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtCUDAProviderOptionsV2 { + _unused: [u8; 0], +} pub type OrtStatusPtr = *mut OrtStatus; +#[doc = " \\brief Memory allocation interface"] +#[doc = ""] +#[doc = " Structure of function pointers that defines a memory allocator. This can be created and filled in by the user for custom allocators."] +#[doc = ""] +#[doc = " When an allocator is passed to any function, be sure that the allocator object is not destroyed until the last allocated object using it is freed."] #[repr(C)] #[derive(Copy, Clone)] pub struct OrtAllocator { + #[doc = "< Must be initialized to ORT_API_VERSION"] pub version: u32, + #[doc = "< Returns a pointer to an allocated block of `size` bytes"] pub Alloc: ::std::option::Option< unsafe extern "stdcall" fn( this_: *mut OrtAllocator, size: usize, ) -> *mut ::std::os::raw::c_void, >, + #[doc = "< Free a block of memory previously allocated with OrtAllocator::Alloc"] pub Free: ::std::option::Option< unsafe extern "stdcall" fn(this_: *mut OrtAllocator, p: *mut ::std::os::raw::c_void), >, + #[doc = "< Return a pointer to an ::OrtMemoryInfo that describes this allocator"] pub Info: ::std::option::Option< unsafe extern "stdcall" fn(this_: *const OrtAllocator) -> *const OrtMemoryInfo, >, @@ -2931,46 +3107,74 @@ fn bindgen_test_layout_OrtAllocator() { 4usize, concat!("Alignment of ", stringify!(OrtAllocator)) ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).version as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtAllocator), - "::", - stringify!(version) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).Alloc as *const _ as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(OrtAllocator), - "::", - stringify!(Alloc) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).Free as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtAllocator), - "::", - stringify!(Free) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).Info as *const _ as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(OrtAllocator), - "::", - stringify!(Info) - ) - ); + fn test_field_version() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).version) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtAllocator), + "::", + stringify!(version) + ) + ); + } + test_field_version(); + fn test_field_Alloc() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).Alloc) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(OrtAllocator), + "::", + stringify!(Alloc) + ) + ); + } + test_field_Alloc(); + fn test_field_Free() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).Free) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtAllocator), + "::", + stringify!(Free) + ) + ); + } + test_field_Free(); + fn test_field_Info() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).Info) as usize - ptr as usize + }, + 12usize, + concat!( + "Offset of field: ", + stringify!(OrtAllocator), + "::", + stringify!(Info) + ) + ); + } + test_field_Info(); } pub type OrtLoggingFunction = ::std::option::Option< unsafe extern "stdcall" fn( @@ -2983,6 +3187,10 @@ pub type OrtLoggingFunction = ::std::option::Option< ), >; #[repr(i32)] +#[doc = " \\brief Graph optimization level"] +#[doc = ""] +#[doc = " Refer to https://www.onnxruntime.ai/docs/resources/graph-optimizations.html"] +#[doc = " for an in-depth understanding of Graph Optimizations"] #[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] pub enum GraphOptimizationLevel { ORT_DISABLE_ALL = 0, @@ -2997,6 +3205,8 @@ pub enum ExecutionMode { ORT_PARALLEL = 1, } #[repr(i32)] +#[doc = " \\brief Language projection identifiers"] +#[doc = " /see OrtApi::SetLanguageProjection"] #[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] pub enum OrtLanguageProjection { ORT_PROJECTION_C = 0, @@ -3020,7 +3230,7 @@ pub struct OrtKernelContext { #[repr(i32)] #[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] pub enum OrtAllocatorType { - Invalid = -1, + OrtInvalidAllocator = -1, OrtDeviceAllocator = 0, OrtArenaAllocator = 1, } @@ -3028,34 +3238,61 @@ impl OrtMemType { pub const OrtMemTypeCPU: OrtMemType = OrtMemType::OrtMemTypeCPUOutput; } #[repr(i32)] -#[doc = " memory types for allocator, exec provider specific types should be extended in each provider"] -#[doc = " Whenever this struct is updated, please also update the MakeKey function in onnxruntime/core/framework/execution_provider.cc"] +#[doc = " \\brief Memory types for allocated memory, execution provider specific types should be extended in each provider."] #[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] pub enum OrtMemType { + #[doc = "< Any CPU memory used by non-CPU execution provider"] OrtMemTypeCPUInput = -2, + #[doc = "< CPU accessible memory outputted by non-CPU execution provider, i.e. CUDA_PINNED"] OrtMemTypeCPUOutput = -1, + #[doc = "< The default allocator for execution provider"] OrtMemTypeDefault = 0, } #[repr(i32)] +#[doc = " \\brief Algorithm to use for cuDNN Convolution Op"] #[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] pub enum OrtCudnnConvAlgoSearch { - EXHAUSTIVE = 0, - HEURISTIC = 1, - DEFAULT = 2, + OrtCudnnConvAlgoSearchExhaustive = 0, + OrtCudnnConvAlgoSearchHeuristic = 1, + OrtCudnnConvAlgoSearchDefault = 2, } -#[doc = " "] -#[doc = " Options for the CUDA provider that are passed to SessionOptionsAppendExecutionProvider_CUDA"] -#[doc = " "] +#[doc = " \\brief CUDA Provider Options"] +#[doc = ""] +#[doc = " \\see OrtApi::SessionOptionsAppendExecutionProvider_CUDA"] #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct OrtCUDAProviderOptions { + #[doc = " \\brief CUDA device Id"] + #[doc = " Defaults to 0."] pub device_id: ::std::os::raw::c_int, + #[doc = " \\brief CUDA Convolution algorithm search configuration."] + #[doc = " See enum OrtCudnnConvAlgoSearch for more details."] + #[doc = " Defaults to OrtCudnnConvAlgoSearchExhaustive."] pub cudnn_conv_algo_search: OrtCudnnConvAlgoSearch, + #[doc = " \\brief CUDA memory limit (To use all possible memory pass in maximum size_t)"] + #[doc = " Defaults to SIZE_MAX."] + #[doc = " \\note If a ::OrtArenaCfg has been applied, it will override this field"] pub gpu_mem_limit: usize, + #[doc = " \\brief Strategy used to grow the memory arena"] + #[doc = " 0 = kNextPowerOfTwo
"] + #[doc = " 1 = kSameAsRequested
"] + #[doc = " Defaults to 0."] + #[doc = " \\note If a ::OrtArenaCfg has been applied, it will override this field"] pub arena_extend_strategy: ::std::os::raw::c_int, + #[doc = " \\brief Flag indicating if copying needs to take place on the same stream as the compute stream in the CUDA EP"] + #[doc = " 0 = Use separate streams for copying and compute."] + #[doc = " 1 = Use the same stream for copying and compute."] + #[doc = " Defaults to 1."] + #[doc = " WARNING: Setting this to 0 may result in data races for some models."] + #[doc = " Please see issue #4829 for more details."] pub do_copy_in_default_stream: ::std::os::raw::c_int, + #[doc = " \\brief Flag indicating if there is a user provided compute stream"] + #[doc = " Defaults to 0."] pub has_user_compute_stream: ::std::os::raw::c_int, + #[doc = " \\brief User provided compute stream."] + #[doc = " If provided, please set `has_user_compute_stream` to 1."] pub user_compute_stream: *mut ::std::os::raw::c_void, + #[doc = " \\brief CUDA memory arena configuration parameters"] pub default_memory_arena_cfg: *mut OrtArenaCfg, } #[test] @@ -3070,125 +3307,186 @@ fn bindgen_test_layout_OrtCUDAProviderOptions() { 4usize, concat!("Alignment of ", stringify!(OrtCUDAProviderOptions)) ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).device_id as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(device_id) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).cudnn_conv_algo_search as *const _ - as usize - }, - 4usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(cudnn_conv_algo_search) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).gpu_mem_limit as *const _ as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(gpu_mem_limit) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).arena_extend_strategy as *const _ - as usize - }, - 12usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(arena_extend_strategy) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).do_copy_in_default_stream as *const _ - as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(do_copy_in_default_stream) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).has_user_compute_stream as *const _ - as usize - }, - 20usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(has_user_compute_stream) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).user_compute_stream as *const _ - as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(user_compute_stream) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).default_memory_arena_cfg as *const _ - as usize - }, - 28usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(default_memory_arena_cfg) - ) - ); -} -#[doc = " "] -#[doc = " Options for the ROCM provider that are passed to SessionOptionsAppendExecutionProvider_ROCM"] -#[doc = " "] + fn test_field_device_id() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).device_id) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(device_id) + ) + ); + } + test_field_device_id(); + fn test_field_cudnn_conv_algo_search() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).cudnn_conv_algo_search) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(cudnn_conv_algo_search) + ) + ); + } + test_field_cudnn_conv_algo_search(); + fn test_field_gpu_mem_limit() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).gpu_mem_limit) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(gpu_mem_limit) + ) + ); + } + test_field_gpu_mem_limit(); + fn test_field_arena_extend_strategy() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).arena_extend_strategy) as usize - ptr as usize + }, + 12usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(arena_extend_strategy) + ) + ); + } + test_field_arena_extend_strategy(); + fn test_field_do_copy_in_default_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).do_copy_in_default_stream) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(do_copy_in_default_stream) + ) + ); + } + test_field_do_copy_in_default_stream(); + fn test_field_has_user_compute_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).has_user_compute_stream) as usize - ptr as usize + }, + 20usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(has_user_compute_stream) + ) + ); + } + test_field_has_user_compute_stream(); + fn test_field_user_compute_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).user_compute_stream) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(user_compute_stream) + ) + ); + } + test_field_user_compute_stream(); + fn test_field_default_memory_arena_cfg() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).default_memory_arena_cfg) as usize - ptr as usize + }, + 28usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(default_memory_arena_cfg) + ) + ); + } + test_field_default_memory_arena_cfg(); +} +#[doc = " \\brief ROCM Provider Options"] +#[doc = ""] +#[doc = " \\see OrtApi::SessionOptionsAppendExecutionProvider_ROCM"] #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct OrtROCMProviderOptions { + #[doc = " \\brief ROCM device Id"] + #[doc = " Defaults to 0."] pub device_id: ::std::os::raw::c_int, + #[doc = " \\brief ROCM MIOpen Convolution algorithm exaustive search option."] + #[doc = " Defaults to 0 (false)."] pub miopen_conv_exhaustive_search: ::std::os::raw::c_int, + #[doc = " \\brief ROCM memory limit (To use all possible memory pass in maximum size_t)"] + #[doc = " Defaults to SIZE_MAX."] + #[doc = " \\note If a ::OrtArenaCfg has been applied, it will override this field"] pub gpu_mem_limit: usize, + #[doc = " \\brief Strategy used to grow the memory arena"] + #[doc = " 0 = kNextPowerOfTwo
"] + #[doc = " 1 = kSameAsRequested
"] + #[doc = " Defaults to 0."] + #[doc = " \\note If a ::OrtArenaCfg has been applied, it will override this field"] pub arena_extend_strategy: ::std::os::raw::c_int, + #[doc = " \\brief Flag indicating if copying needs to take place on the same stream as the compute stream in the ROCM EP"] + #[doc = " 0 = Use separate streams for copying and compute."] + #[doc = " 1 = Use the same stream for copying and compute."] + #[doc = " Defaults to 1."] + #[doc = " WARNING: Setting this to 0 may result in data races for some models."] + #[doc = " Please see issue #4829 for more details."] + pub do_copy_in_default_stream: ::std::os::raw::c_int, + #[doc = " \\brief Flag indicating if there is a user provided compute stream"] + #[doc = " Defaults to 0."] + pub has_user_compute_stream: ::std::os::raw::c_int, + #[doc = " \\brief User provided compute stream."] + #[doc = " If provided, please set `has_user_compute_stream` to 1."] + pub user_compute_stream: *mut ::std::os::raw::c_void, + #[doc = " \\brief ROCM memory arena configuration parameters"] + pub default_memory_arena_cfg: *mut OrtArenaCfg, } #[test] fn bindgen_test_layout_OrtROCMProviderOptions() { assert_eq!( ::std::mem::size_of::(), - 16usize, + 32usize, concat!("Size of: ", stringify!(OrtROCMProviderOptions)) ); assert_eq!( @@ -3196,63 +3494,150 @@ fn bindgen_test_layout_OrtROCMProviderOptions() { 4usize, concat!("Alignment of ", stringify!(OrtROCMProviderOptions)) ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).device_id as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtROCMProviderOptions), - "::", - stringify!(device_id) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).miopen_conv_exhaustive_search - as *const _ as usize - }, - 4usize, - concat!( - "Offset of field: ", - stringify!(OrtROCMProviderOptions), - "::", - stringify!(miopen_conv_exhaustive_search) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).gpu_mem_limit as *const _ as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtROCMProviderOptions), - "::", - stringify!(gpu_mem_limit) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).arena_extend_strategy as *const _ - as usize - }, - 12usize, - concat!( - "Offset of field: ", - stringify!(OrtROCMProviderOptions), - "::", - stringify!(arena_extend_strategy) - ) - ); -} -#[doc = " "] -#[doc = " Options for the TensorRT provider that are passed to SessionOptionsAppendExecutionProvider_TensorRT"] -#[doc = " "] + fn test_field_device_id() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).device_id) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(device_id) + ) + ); + } + test_field_device_id(); + fn test_field_miopen_conv_exhaustive_search() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).miopen_conv_exhaustive_search) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(miopen_conv_exhaustive_search) + ) + ); + } + test_field_miopen_conv_exhaustive_search(); + fn test_field_gpu_mem_limit() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).gpu_mem_limit) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(gpu_mem_limit) + ) + ); + } + test_field_gpu_mem_limit(); + fn test_field_arena_extend_strategy() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).arena_extend_strategy) as usize - ptr as usize + }, + 12usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(arena_extend_strategy) + ) + ); + } + test_field_arena_extend_strategy(); + fn test_field_do_copy_in_default_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).do_copy_in_default_stream) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(do_copy_in_default_stream) + ) + ); + } + test_field_do_copy_in_default_stream(); + fn test_field_has_user_compute_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).has_user_compute_stream) as usize - ptr as usize + }, + 20usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(has_user_compute_stream) + ) + ); + } + test_field_has_user_compute_stream(); + fn test_field_user_compute_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).user_compute_stream) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(user_compute_stream) + ) + ); + } + test_field_user_compute_stream(); + fn test_field_default_memory_arena_cfg() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).default_memory_arena_cfg) as usize - ptr as usize + }, + 28usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(default_memory_arena_cfg) + ) + ); + } + test_field_default_memory_arena_cfg(); +} +#[doc = " \\brief TensorRT Provider Options"] +#[doc = ""] +#[doc = " \\see OrtApi::SessionOptionsAppendExecutionProvider_TensorRT"] #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct OrtTensorRTProviderOptions { + #[doc = "< CUDA device id (0 = default device)"] pub device_id: ::std::os::raw::c_int, pub has_user_compute_stream: ::std::os::raw::c_int, pub user_compute_stream: *mut ::std::os::raw::c_void, @@ -3284,257 +3669,414 @@ fn bindgen_test_layout_OrtTensorRTProviderOptions() { 4usize, concat!("Alignment of ", stringify!(OrtTensorRTProviderOptions)) ); + fn test_field_device_id() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).device_id) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(device_id) + ) + ); + } + test_field_device_id(); + fn test_field_has_user_compute_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).has_user_compute_stream) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(has_user_compute_stream) + ) + ); + } + test_field_has_user_compute_stream(); + fn test_field_user_compute_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).user_compute_stream) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(user_compute_stream) + ) + ); + } + test_field_user_compute_stream(); + fn test_field_trt_max_partition_iterations() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_max_partition_iterations) as usize - ptr as usize + }, + 12usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_max_partition_iterations) + ) + ); + } + test_field_trt_max_partition_iterations(); + fn test_field_trt_min_subgraph_size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_min_subgraph_size) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_min_subgraph_size) + ) + ); + } + test_field_trt_min_subgraph_size(); + fn test_field_trt_max_workspace_size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_max_workspace_size) as usize - ptr as usize + }, + 20usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_max_workspace_size) + ) + ); + } + test_field_trt_max_workspace_size(); + fn test_field_trt_fp16_enable() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_fp16_enable) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_fp16_enable) + ) + ); + } + test_field_trt_fp16_enable(); + fn test_field_trt_int8_enable() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_int8_enable) as usize - ptr as usize + }, + 28usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_int8_enable) + ) + ); + } + test_field_trt_int8_enable(); + fn test_field_trt_int8_calibration_table_name() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_int8_calibration_table_name) as usize - ptr as usize + }, + 32usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_int8_calibration_table_name) + ) + ); + } + test_field_trt_int8_calibration_table_name(); + fn test_field_trt_int8_use_native_calibration_table() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_int8_use_native_calibration_table) as usize + - ptr as usize + }, + 36usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_int8_use_native_calibration_table) + ) + ); + } + test_field_trt_int8_use_native_calibration_table(); + fn test_field_trt_dla_enable() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_dla_enable) as usize - ptr as usize + }, + 40usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_dla_enable) + ) + ); + } + test_field_trt_dla_enable(); + fn test_field_trt_dla_core() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_dla_core) as usize - ptr as usize + }, + 44usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_dla_core) + ) + ); + } + test_field_trt_dla_core(); + fn test_field_trt_dump_subgraphs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_dump_subgraphs) as usize - ptr as usize + }, + 48usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_dump_subgraphs) + ) + ); + } + test_field_trt_dump_subgraphs(); + fn test_field_trt_engine_cache_enable() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_engine_cache_enable) as usize - ptr as usize + }, + 52usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_engine_cache_enable) + ) + ); + } + test_field_trt_engine_cache_enable(); + fn test_field_trt_engine_cache_path() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_engine_cache_path) as usize - ptr as usize + }, + 56usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_engine_cache_path) + ) + ); + } + test_field_trt_engine_cache_path(); + fn test_field_trt_engine_decryption_enable() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_engine_decryption_enable) as usize - ptr as usize + }, + 60usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_engine_decryption_enable) + ) + ); + } + test_field_trt_engine_decryption_enable(); + fn test_field_trt_engine_decryption_lib_path() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_engine_decryption_lib_path) as usize - ptr as usize + }, + 64usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_engine_decryption_lib_path) + ) + ); + } + test_field_trt_engine_decryption_lib_path(); + fn test_field_trt_force_sequential_engine_build() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_force_sequential_engine_build) as usize + - ptr as usize + }, + 68usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_force_sequential_engine_build) + ) + ); + } + test_field_trt_force_sequential_engine_build(); +} +#[doc = " \\brief MIGraphX Provider Options"] +#[doc = ""] +#[doc = " \\see OrtApi::SessionOptionsAppendExecutionProvider_MIGraphX"] +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtMIGraphXProviderOptions { + pub device_id: ::std::os::raw::c_int, + pub migraphx_fp16_enable: ::std::os::raw::c_int, + pub migraphx_int8_enable: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_OrtMIGraphXProviderOptions() { assert_eq!( - unsafe { - &(*(::std::ptr::null::())).device_id as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(device_id) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).has_user_compute_stream - as *const _ as usize - }, - 4usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(has_user_compute_stream) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).user_compute_stream as *const _ - as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(user_compute_stream) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_max_partition_iterations - as *const _ as usize - }, + ::std::mem::size_of::(), 12usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_max_partition_iterations) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_min_subgraph_size as *const _ - as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_min_subgraph_size) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_max_workspace_size - as *const _ as usize - }, - 20usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_max_workspace_size) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_fp16_enable as *const _ - as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_fp16_enable) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_int8_enable as *const _ - as usize - }, - 28usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_int8_enable) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_int8_calibration_table_name - as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_int8_calibration_table_name) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())) - .trt_int8_use_native_calibration_table as *const _ as usize - }, - 36usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_int8_use_native_calibration_table) - ) + concat!("Size of: ", stringify!(OrtMIGraphXProviderOptions)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_dla_enable as *const _ - as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_dla_enable) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_dla_core as *const _ as usize - }, - 44usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_dla_core) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_dump_subgraphs as *const _ - as usize - }, - 48usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_dump_subgraphs) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_engine_cache_enable - as *const _ as usize - }, - 52usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_engine_cache_enable) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_engine_cache_path as *const _ - as usize - }, - 56usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_engine_cache_path) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_engine_decryption_enable - as *const _ as usize - }, - 60usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_engine_decryption_enable) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_engine_decryption_lib_path - as *const _ as usize - }, - 64usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_engine_decryption_lib_path) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_force_sequential_engine_build - as *const _ as usize - }, - 68usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_force_sequential_engine_build) - ) - ); -} -#[doc = " "] -#[doc = " Options for the OpenVINO provider that are passed to SessionOptionsAppendExecutionProvider_OpenVINO"] -#[doc = " "] + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(OrtMIGraphXProviderOptions)) + ); + fn test_field_device_id() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).device_id) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtMIGraphXProviderOptions), + "::", + stringify!(device_id) + ) + ); + } + test_field_device_id(); + fn test_field_migraphx_fp16_enable() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).migraphx_fp16_enable) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(OrtMIGraphXProviderOptions), + "::", + stringify!(migraphx_fp16_enable) + ) + ); + } + test_field_migraphx_fp16_enable(); + fn test_field_migraphx_int8_enable() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).migraphx_int8_enable) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtMIGraphXProviderOptions), + "::", + stringify!(migraphx_int8_enable) + ) + ); + } + test_field_migraphx_int8_enable(); +} +#[doc = " \\brief OpenVINO Provider Options"] +#[doc = ""] +#[doc = " \\see OrtApi::SessionOptionsAppendExecutionProvider_OpenVINO"] #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct OrtOpenVINOProviderOptions { + #[doc = " \\brief Device type string"] + #[doc = ""] + #[doc = " Valid settings are one of: \"CPU_FP32\", \"GPU_FP32\", \"GPU_FP16\", \"MYRIAD_FP16\", \"VAD-M_FP16\" or \"VAD-F_FP32\""] pub device_type: *const ::std::os::raw::c_char, + #[doc = "< 0 = disabled, nonzero = enabled"] pub enable_vpu_fast_compile: ::std::os::raw::c_uchar, pub device_id: *const ::std::os::raw::c_char, + #[doc = "< 0 = Use default number of threads"] pub num_of_threads: usize, + #[doc = "< 0 = disabled, nonzero = enabled"] pub use_compiled_network: ::std::os::raw::c_uchar, pub blob_dump_path: *const ::std::os::raw::c_char, + pub context: *mut ::std::os::raw::c_void, } #[test] fn bindgen_test_layout_OrtOpenVINOProviderOptions() { assert_eq!( ::std::mem::size_of::(), - 24usize, + 28usize, concat!("Size of: ", stringify!(OrtOpenVINOProviderOptions)) ); assert_eq!( @@ -3542,87 +4084,139 @@ fn bindgen_test_layout_OrtOpenVINOProviderOptions() { 4usize, concat!("Alignment of ", stringify!(OrtOpenVINOProviderOptions)) ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).device_type as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtOpenVINOProviderOptions), - "::", - stringify!(device_type) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).enable_vpu_fast_compile - as *const _ as usize - }, - 4usize, - concat!( - "Offset of field: ", - stringify!(OrtOpenVINOProviderOptions), - "::", - stringify!(enable_vpu_fast_compile) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).device_id as *const _ as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtOpenVINOProviderOptions), - "::", - stringify!(device_id) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).num_of_threads as *const _ - as usize - }, - 12usize, - concat!( - "Offset of field: ", - stringify!(OrtOpenVINOProviderOptions), - "::", - stringify!(num_of_threads) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).use_compiled_network as *const _ - as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(OrtOpenVINOProviderOptions), - "::", - stringify!(use_compiled_network) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).blob_dump_path as *const _ - as usize - }, - 20usize, - concat!( - "Offset of field: ", - stringify!(OrtOpenVINOProviderOptions), - "::", - stringify!(blob_dump_path) - ) - ); -} + fn test_field_device_type() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).device_type) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtOpenVINOProviderOptions), + "::", + stringify!(device_type) + ) + ); + } + test_field_device_type(); + fn test_field_enable_vpu_fast_compile() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).enable_vpu_fast_compile) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(OrtOpenVINOProviderOptions), + "::", + stringify!(enable_vpu_fast_compile) + ) + ); + } + test_field_enable_vpu_fast_compile(); + fn test_field_device_id() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).device_id) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtOpenVINOProviderOptions), + "::", + stringify!(device_id) + ) + ); + } + test_field_device_id(); + fn test_field_num_of_threads() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).num_of_threads) as usize - ptr as usize + }, + 12usize, + concat!( + "Offset of field: ", + stringify!(OrtOpenVINOProviderOptions), + "::", + stringify!(num_of_threads) + ) + ); + } + test_field_num_of_threads(); + fn test_field_use_compiled_network() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).use_compiled_network) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(OrtOpenVINOProviderOptions), + "::", + stringify!(use_compiled_network) + ) + ); + } + test_field_use_compiled_network(); + fn test_field_blob_dump_path() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).blob_dump_path) as usize - ptr as usize + }, + 20usize, + concat!( + "Offset of field: ", + stringify!(OrtOpenVINOProviderOptions), + "::", + stringify!(blob_dump_path) + ) + ); + } + test_field_blob_dump_path(); + fn test_field_context() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).context) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(OrtOpenVINOProviderOptions), + "::", + stringify!(context) + ) + ); + } + test_field_context(); +} +#[doc = " \\brief The helper interface to get the right version of OrtApi"] +#[doc = ""] +#[doc = " Get a pointer to this structure through ::OrtGetApiBase"] #[repr(C)] #[derive(Copy, Clone)] pub struct OrtApiBase { + #[doc = " \\brief Get a pointer to the requested version of the ::OrtApi"] + #[doc = ""] + #[doc = " \\param[in] version Must be ::ORT_API_VERSION"] + #[doc = " \\return The ::OrtApi for the version requested, nullptr will be returned if this version is unsupported, for example when using a runtime"] + #[doc = " older than the version created with this header file."] pub GetApi: ::std::option::Option *const OrtApi>, + #[doc = "< Returns a null terminated string of the version of the Onnxruntime library (eg: \"1.8.1\")"] pub GetVersionString: ::std::option::Option *const ::std::os::raw::c_char>, } @@ -3638,50 +4232,142 @@ fn bindgen_test_layout_OrtApiBase() { 4usize, concat!("Alignment of ", stringify!(OrtApiBase)) ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetApi as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtApiBase), - "::", - stringify!(GetApi) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetVersionString as *const _ as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(OrtApiBase), - "::", - stringify!(GetVersionString) - ) - ); + fn test_field_GetApi() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetApi) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtApiBase), + "::", + stringify!(GetApi) + ) + ); + } + test_field_GetApi(); + fn test_field_GetVersionString() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetVersionString) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(OrtApiBase), + "::", + stringify!(GetVersionString) + ) + ); + } + test_field_GetVersionString(); } extern "stdcall" { + #[doc = " \\brief The Onnxruntime library's entry point to access the C API"] + #[doc = ""] + #[doc = " Call this to get the a pointer to an ::OrtApiBase"] pub fn OrtGetApiBase() -> *const OrtApiBase; } +#[doc = " \\brief Thread work loop function"] +#[doc = ""] +#[doc = " Onnxruntime will provide the working loop on custom thread creation"] +#[doc = " Argument is an onnxruntime built-in type which will be provided when thread pool calls OrtCustomCreateThreadFn"] +pub type OrtThreadWorkerFn = + ::std::option::Option; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtCustomHandleType { + pub __place_holder: ::std::os::raw::c_char, +} +#[test] +fn bindgen_test_layout_OrtCustomHandleType() { + assert_eq!( + ::std::mem::size_of::(), + 1usize, + concat!("Size of: ", stringify!(OrtCustomHandleType)) + ); + assert_eq!( + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(OrtCustomHandleType)) + ); + fn test_field___place_holder() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__place_holder) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomHandleType), + "::", + stringify!(__place_holder) + ) + ); + } + test_field___place_holder(); +} +pub type OrtCustomThreadHandle = *const OrtCustomHandleType; +#[doc = " \\brief Ort custom thread creation function"] +#[doc = ""] +#[doc = " The function should return a thread handle to be used in onnxruntime thread pools"] +#[doc = " Onnxruntime will throw exception on return value of nullptr or 0, indicating that the function failed to create a thread"] +pub type OrtCustomCreateThreadFn = ::std::option::Option< + unsafe extern "C" fn( + ort_custom_thread_creation_options: *mut ::std::os::raw::c_void, + ort_thread_worker_fn: OrtThreadWorkerFn, + ort_worker_fn_param: *mut ::std::os::raw::c_void, + ) -> OrtCustomThreadHandle, +>; +#[doc = " \\brief Custom thread join function"] +#[doc = ""] +#[doc = " Onnxruntime thread pool destructor will call the function to join a custom thread."] +#[doc = " Argument ort_custom_thread_handle is the value returned by OrtCustomCreateThreadFn"] +pub type OrtCustomJoinThreadFn = + ::std::option::Option; +#[doc = " \\brief The C API"] +#[doc = ""] +#[doc = " All C API functions are defined inside this structure as pointers to functions."] +#[doc = " Call OrtApiBase::GetApi to get a pointer to it"] +#[doc = ""] +#[doc = " \\nosubgrouping"] #[repr(C)] #[derive(Copy, Clone)] pub struct OrtApi { - #[doc = " \\param msg A null-terminated string. Its content will be copied into the newly created OrtStatus"] + #[doc = " \\brief Create an OrtStatus from a null terminated string"] + #[doc = ""] + #[doc = " \\param[in] code"] + #[doc = " \\param[in] msg A null-terminated string. Its contents will be copied."] + #[doc = " \\return A new OrtStatus object, must be destroyed with OrtApi::ReleaseStatus"] pub CreateStatus: ::std::option::Option< unsafe extern "stdcall" fn( code: OrtErrorCode, msg: *const ::std::os::raw::c_char, ) -> *mut OrtStatus, >, + #[doc = " \\brief Get OrtErrorCode from OrtStatus"] + #[doc = ""] + #[doc = " \\param[in] status"] + #[doc = " \\return OrtErrorCode that \\p status was created with"] pub GetErrorCode: ::std::option::Option OrtErrorCode>, - #[doc = " \\param status must not be NULL"] + #[doc = " \\brief Get error string from OrtStatus"] + #[doc = ""] + #[doc = " \\param[in] status"] #[doc = " \\return The error message inside the `status`. Do not free the returned value."] pub GetErrorMessage: ::std::option::Option< unsafe extern "stdcall" fn(status: *const OrtStatus) -> *const ::std::os::raw::c_char, >, pub CreateEnv: ::std::option::Option< unsafe extern "stdcall" fn( - logging_level: OrtLoggingLevel, + log_severity_level: OrtLoggingLevel, logid: *const ::std::os::raw::c_char, out: *mut *mut OrtEnv, ) -> OrtStatusPtr, @@ -3690,7 +4376,7 @@ pub struct OrtApi { unsafe extern "stdcall" fn( logging_function: OrtLoggingFunction, logger_param: *mut ::std::os::raw::c_void, - logging_level: OrtLoggingLevel, + log_severity_level: OrtLoggingLevel, logid: *const ::std::os::raw::c_char, out: *mut *mut OrtEnv, ) -> OrtStatusPtr, @@ -3718,14 +4404,14 @@ pub struct OrtApi { >, pub Run: ::std::option::Option< unsafe extern "stdcall" fn( - sess: *mut OrtSession, + session: *mut OrtSession, run_options: *const OrtRunOptions, input_names: *const *const ::std::os::raw::c_char, - input: *const *const OrtValue, + inputs: *const *const OrtValue, input_len: usize, - output_names1: *const *const ::std::os::raw::c_char, + output_names: *const *const ::std::os::raw::c_char, output_names_len: usize, - output: *mut *mut OrtValue, + outputs: *mut *mut OrtValue, ) -> OrtStatusPtr, >, pub CreateSessionOptions: ::std::option::Option< @@ -3832,38 +4518,38 @@ pub struct OrtApi { ) -> OrtStatusPtr, >, pub SessionGetInputCount: ::std::option::Option< - unsafe extern "stdcall" fn(sess: *const OrtSession, out: *mut usize) -> OrtStatusPtr, + unsafe extern "stdcall" fn(session: *const OrtSession, out: *mut usize) -> OrtStatusPtr, >, pub SessionGetOutputCount: ::std::option::Option< - unsafe extern "stdcall" fn(sess: *const OrtSession, out: *mut usize) -> OrtStatusPtr, + unsafe extern "stdcall" fn(session: *const OrtSession, out: *mut usize) -> OrtStatusPtr, >, pub SessionGetOverridableInitializerCount: ::std::option::Option< - unsafe extern "stdcall" fn(sess: *const OrtSession, out: *mut usize) -> OrtStatusPtr, + unsafe extern "stdcall" fn(session: *const OrtSession, out: *mut usize) -> OrtStatusPtr, >, pub SessionGetInputTypeInfo: ::std::option::Option< unsafe extern "stdcall" fn( - sess: *const OrtSession, + session: *const OrtSession, index: usize, type_info: *mut *mut OrtTypeInfo, ) -> OrtStatusPtr, >, pub SessionGetOutputTypeInfo: ::std::option::Option< unsafe extern "stdcall" fn( - sess: *const OrtSession, + session: *const OrtSession, index: usize, type_info: *mut *mut OrtTypeInfo, ) -> OrtStatusPtr, >, pub SessionGetOverridableInitializerTypeInfo: ::std::option::Option< unsafe extern "stdcall" fn( - sess: *const OrtSession, + session: *const OrtSession, index: usize, type_info: *mut *mut OrtTypeInfo, ) -> OrtStatusPtr, >, pub SessionGetInputName: ::std::option::Option< unsafe extern "stdcall" fn( - sess: *const OrtSession, + session: *const OrtSession, index: usize, allocator: *mut OrtAllocator, value: *mut *mut ::std::os::raw::c_char, @@ -3871,7 +4557,7 @@ pub struct OrtApi { >, pub SessionGetOutputName: ::std::option::Option< unsafe extern "stdcall" fn( - sess: *const OrtSession, + session: *const OrtSession, index: usize, allocator: *mut OrtAllocator, value: *mut *mut ::std::os::raw::c_char, @@ -3879,7 +4565,7 @@ pub struct OrtApi { >, pub SessionGetOverridableInitializerName: ::std::option::Option< unsafe extern "stdcall" fn( - sess: *const OrtSession, + session: *const OrtSession, index: usize, allocator: *mut OrtAllocator, value: *mut *mut ::std::os::raw::c_char, @@ -3891,37 +4577,37 @@ pub struct OrtApi { pub RunOptionsSetRunLogVerbosityLevel: ::std::option::Option< unsafe extern "stdcall" fn( options: *mut OrtRunOptions, - value: ::std::os::raw::c_int, + log_verbosity_level: ::std::os::raw::c_int, ) -> OrtStatusPtr, >, pub RunOptionsSetRunLogSeverityLevel: ::std::option::Option< unsafe extern "stdcall" fn( options: *mut OrtRunOptions, - value: ::std::os::raw::c_int, + log_severity_level: ::std::os::raw::c_int, ) -> OrtStatusPtr, >, pub RunOptionsSetRunTag: ::std::option::Option< unsafe extern "stdcall" fn( - arg1: *mut OrtRunOptions, + options: *mut OrtRunOptions, run_tag: *const ::std::os::raw::c_char, ) -> OrtStatusPtr, >, pub RunOptionsGetRunLogVerbosityLevel: ::std::option::Option< unsafe extern "stdcall" fn( options: *const OrtRunOptions, - out: *mut ::std::os::raw::c_int, + log_verbosity_level: *mut ::std::os::raw::c_int, ) -> OrtStatusPtr, >, pub RunOptionsGetRunLogSeverityLevel: ::std::option::Option< unsafe extern "stdcall" fn( options: *const OrtRunOptions, - out: *mut ::std::os::raw::c_int, + log_severity_level: *mut ::std::os::raw::c_int, ) -> OrtStatusPtr, >, pub RunOptionsGetRunTag: ::std::option::Option< unsafe extern "stdcall" fn( - arg1: *const OrtRunOptions, - out: *mut *const ::std::os::raw::c_char, + options: *const OrtRunOptions, + run_tag: *mut *const ::std::os::raw::c_char, ) -> OrtStatusPtr, >, pub RunOptionsSetTerminate: ::std::option::Option< @@ -3983,19 +4669,22 @@ pub struct OrtApi { >, pub CastTypeInfoToTensorInfo: ::std::option::Option< unsafe extern "stdcall" fn( - arg1: *const OrtTypeInfo, + type_info: *const OrtTypeInfo, out: *mut *const OrtTensorTypeAndShapeInfo, ) -> OrtStatusPtr, >, pub GetOnnxTypeFromTypeInfo: ::std::option::Option< - unsafe extern "stdcall" fn(arg1: *const OrtTypeInfo, out: *mut ONNXType) -> OrtStatusPtr, + unsafe extern "stdcall" fn( + type_info: *const OrtTypeInfo, + out: *mut ONNXType, + ) -> OrtStatusPtr, >, pub CreateTensorTypeAndShapeInfo: ::std::option::Option< unsafe extern "stdcall" fn(out: *mut *mut OrtTensorTypeAndShapeInfo) -> OrtStatusPtr, >, pub SetTensorElementType: ::std::option::Option< unsafe extern "stdcall" fn( - arg1: *mut OrtTensorTypeAndShapeInfo, + info: *mut OrtTensorTypeAndShapeInfo, type_: ONNXTensorElementDataType, ) -> OrtStatusPtr, >, @@ -4008,7 +4697,7 @@ pub struct OrtApi { >, pub GetTensorElementType: ::std::option::Option< unsafe extern "stdcall" fn( - arg1: *const OrtTensorTypeAndShapeInfo, + info: *const OrtTensorTypeAndShapeInfo, out: *mut ONNXTensorElementDataType, ) -> OrtStatusPtr, >, @@ -4055,17 +4744,17 @@ pub struct OrtApi { >, pub CreateMemoryInfo: ::std::option::Option< unsafe extern "stdcall" fn( - name1: *const ::std::os::raw::c_char, + name: *const ::std::os::raw::c_char, type_: OrtAllocatorType, - id1: ::std::os::raw::c_int, - mem_type1: OrtMemType, + id: ::std::os::raw::c_int, + mem_type: OrtMemType, out: *mut *mut OrtMemoryInfo, ) -> OrtStatusPtr, >, pub CreateCpuMemoryInfo: ::std::option::Option< unsafe extern "stdcall" fn( type_: OrtAllocatorType, - mem_type1: OrtMemType, + mem_type: OrtMemType, out: *mut *mut OrtMemoryInfo, ) -> OrtStatusPtr, >, @@ -4099,20 +4788,20 @@ pub struct OrtApi { >, pub AllocatorAlloc: ::std::option::Option< unsafe extern "stdcall" fn( - ptr: *mut OrtAllocator, + ort_allocator: *mut OrtAllocator, size: usize, out: *mut *mut ::std::os::raw::c_void, ) -> OrtStatusPtr, >, pub AllocatorFree: ::std::option::Option< unsafe extern "stdcall" fn( - ptr: *mut OrtAllocator, + ort_allocator: *mut OrtAllocator, p: *mut ::std::os::raw::c_void, ) -> OrtStatusPtr, >, pub AllocatorGetInfo: ::std::option::Option< unsafe extern "stdcall" fn( - ptr: *const OrtAllocator, + ort_allocator: *const OrtAllocator, out: *mut *const OrtMemoryInfo, ) -> OrtStatusPtr, >, @@ -4230,7 +4919,7 @@ pub struct OrtApi { ::std::option::Option, pub GetDenotationFromTypeInfo: ::std::option::Option< unsafe extern "stdcall" fn( - arg1: *const OrtTypeInfo, + type_info: *const OrtTypeInfo, denotation: *mut *const ::std::os::raw::c_char, len: *mut usize, ) -> OrtStatusPtr, @@ -4271,14 +4960,14 @@ pub struct OrtApi { ::std::option::Option, pub SessionEndProfiling: ::std::option::Option< unsafe extern "stdcall" fn( - sess: *mut OrtSession, + session: *mut OrtSession, allocator: *mut OrtAllocator, out: *mut *mut ::std::os::raw::c_char, ) -> OrtStatusPtr, >, pub SessionGetModelMetadata: ::std::option::Option< unsafe extern "stdcall" fn( - sess: *const OrtSession, + session: *const OrtSession, out: *mut *mut OrtModelMetadata, ) -> OrtStatusPtr, >, @@ -4328,9 +5017,9 @@ pub struct OrtApi { ::std::option::Option, pub CreateEnvWithGlobalThreadPools: ::std::option::Option< unsafe extern "stdcall" fn( - logging_level: OrtLoggingLevel, + log_severity_level: OrtLoggingLevel, logid: *const ::std::os::raw::c_char, - t_options: *const OrtThreadingOptions, + tp_options: *const OrtThreadingOptions, out: *mut *mut OrtEnv, ) -> OrtStatusPtr, >, @@ -4400,7 +5089,7 @@ pub struct OrtApi { >, pub CreateAllocator: ::std::option::Option< unsafe extern "stdcall" fn( - sess: *const OrtSession, + session: *const OrtSession, mem_info: *const OrtMemoryInfo, out: *mut *mut OrtAllocator, ) -> OrtStatusPtr, @@ -4409,14 +5098,14 @@ pub struct OrtApi { ::std::option::Option, pub RunWithBinding: ::std::option::Option< unsafe extern "stdcall" fn( - sess: *mut OrtSession, + session: *mut OrtSession, run_options: *const OrtRunOptions, binding_ptr: *const OrtIoBinding, ) -> OrtStatusPtr, >, pub CreateIoBinding: ::std::option::Option< unsafe extern "stdcall" fn( - sess: *mut OrtSession, + session: *mut OrtSession, out: *mut *mut OrtIoBinding, ) -> OrtStatusPtr, >, @@ -4440,7 +5129,7 @@ pub struct OrtApi { unsafe extern "stdcall" fn( binding_ptr: *mut OrtIoBinding, name: *const ::std::os::raw::c_char, - val_ptr: *const OrtMemoryInfo, + mem_info_ptr: *const OrtMemoryInfo, ) -> OrtStatusPtr, >, pub GetBoundOutputNames: ::std::option::Option< @@ -4460,9 +5149,10 @@ pub struct OrtApi { output_count: *mut usize, ) -> OrtStatusPtr, >, - #[doc = " Clears any previously specified bindings for inputs/outputs"] + #[doc = " \\brief Clears any previously set Inputs for an ::OrtIoBinding"] pub ClearBoundInputs: ::std::option::Option, + #[doc = " \\brief Clears any previously set Outputs for an ::OrtIoBinding"] pub ClearBoundOutputs: ::std::option::Option, pub TensorAt: ::std::option::Option< @@ -4487,7 +5177,7 @@ pub struct OrtApi { ) -> OrtStatusPtr, >, pub SessionGetProfilingStartTimeNs: ::std::option::Option< - unsafe extern "stdcall" fn(sess: *const OrtSession, out: *mut u64) -> OrtStatusPtr, + unsafe extern "stdcall" fn(session: *const OrtSession, out: *mut u64) -> OrtStatusPtr, >, pub SetGlobalIntraOpNumThreads: ::std::option::Option< unsafe extern "stdcall" fn( @@ -4518,7 +5208,7 @@ pub struct OrtApi { unsafe extern "stdcall" fn( logging_function: OrtLoggingFunction, logger_param: *mut ::std::os::raw::c_void, - logging_level: OrtLoggingLevel, + log_severity_level: OrtLoggingLevel, logid: *const ::std::os::raw::c_char, tp_options: *const OrtThreadingOptions, out: *mut *mut OrtEnv, @@ -4629,1837 +5319,3888 @@ pub struct OrtApi { out: *mut *mut OrtSession, ) -> OrtStatusPtr, >, -} -#[test] -fn bindgen_test_layout_OrtApi() { - assert_eq!( - ::std::mem::size_of::(), - 680usize, - concat!("Size of: ", stringify!(OrtApi)) - ); - assert_eq!( - ::std::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(OrtApi)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateStatus as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateStatus) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetErrorCode as *const _ as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetErrorCode) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetErrorMessage as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetErrorMessage) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateEnv as *const _ as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateEnv) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateEnvWithCustomLogger as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateEnvWithCustomLogger) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).EnableTelemetryEvents as *const _ as usize }, - 20usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(EnableTelemetryEvents) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).DisableTelemetryEvents as *const _ as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(DisableTelemetryEvents) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateSession as *const _ as usize }, - 28usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateSession) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateSessionFromArray as *const _ as usize }, - 32usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateSessionFromArray) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).Run as *const _ as usize }, - 36usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(Run) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateSessionOptions as *const _ as usize }, - 40usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateSessionOptions) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SetOptimizedModelFilePath as *const _ as usize - }, - 44usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetOptimizedModelFilePath) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CloneSessionOptions as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CloneSessionOptions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetSessionExecutionMode as *const _ as usize }, - 52usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetSessionExecutionMode) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).EnableProfiling as *const _ as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(EnableProfiling) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).DisableProfiling as *const _ as usize }, - 60usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(DisableProfiling) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).EnableMemPattern as *const _ as usize }, - 64usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(EnableMemPattern) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).DisableMemPattern as *const _ as usize }, - 68usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(DisableMemPattern) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).EnableCpuMemArena as *const _ as usize }, - 72usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(EnableCpuMemArena) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).DisableCpuMemArena as *const _ as usize }, - 76usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(DisableCpuMemArena) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetSessionLogId as *const _ as usize }, - 80usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetSessionLogId) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SetSessionLogVerbosityLevel as *const _ as usize - }, - 84usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetSessionLogVerbosityLevel) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SetSessionLogSeverityLevel as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetSessionLogSeverityLevel) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SetSessionGraphOptimizationLevel as *const _ as usize - }, - 92usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetSessionGraphOptimizationLevel) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetIntraOpNumThreads as *const _ as usize }, - 96usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetIntraOpNumThreads) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetInterOpNumThreads as *const _ as usize }, - 100usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetInterOpNumThreads) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateCustomOpDomain as *const _ as usize }, - 104usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateCustomOpDomain) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CustomOpDomain_Add as *const _ as usize }, - 108usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CustomOpDomain_Add) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AddCustomOpDomain as *const _ as usize }, - 112usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AddCustomOpDomain) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).RegisterCustomOpsLibrary as *const _ as usize }, - 116usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RegisterCustomOpsLibrary) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionGetInputCount as *const _ as usize }, - 120usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetInputCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionGetOutputCount as *const _ as usize }, - 124usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetOutputCount) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionGetOverridableInitializerCount as *const _ - as usize - }, - 128usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetOverridableInitializerCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionGetInputTypeInfo as *const _ as usize }, - 132usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetInputTypeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionGetOutputTypeInfo as *const _ as usize }, - 136usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetOutputTypeInfo) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionGetOverridableInitializerTypeInfo as *const _ - as usize - }, - 140usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetOverridableInitializerTypeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionGetInputName as *const _ as usize }, - 144usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetInputName) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionGetOutputName as *const _ as usize }, - 148usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetOutputName) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionGetOverridableInitializerName as *const _ - as usize - }, - 152usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetOverridableInitializerName) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateRunOptions as *const _ as usize }, - 156usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateRunOptions) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).RunOptionsSetRunLogVerbosityLevel as *const _ - as usize - }, - 160usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsSetRunLogVerbosityLevel) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).RunOptionsSetRunLogSeverityLevel as *const _ as usize - }, - 164usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsSetRunLogSeverityLevel) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).RunOptionsSetRunTag as *const _ as usize }, - 168usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsSetRunTag) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).RunOptionsGetRunLogVerbosityLevel as *const _ - as usize - }, - 172usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsGetRunLogVerbosityLevel) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).RunOptionsGetRunLogSeverityLevel as *const _ as usize - }, - 176usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsGetRunLogSeverityLevel) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).RunOptionsGetRunTag as *const _ as usize }, - 180usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsGetRunTag) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).RunOptionsSetTerminate as *const _ as usize }, - 184usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsSetTerminate) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).RunOptionsUnsetTerminate as *const _ as usize }, - 188usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsUnsetTerminate) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateTensorAsOrtValue as *const _ as usize }, - 192usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateTensorAsOrtValue) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateTensorWithDataAsOrtValue as *const _ as usize - }, - 196usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateTensorWithDataAsOrtValue) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).IsTensor as *const _ as usize }, - 200usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(IsTensor) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetTensorMutableData as *const _ as usize }, - 204usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetTensorMutableData) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).FillStringTensor as *const _ as usize }, - 208usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(FillStringTensor) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetStringTensorDataLength as *const _ as usize - }, - 212usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetStringTensorDataLength) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetStringTensorContent as *const _ as usize }, - 216usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetStringTensorContent) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CastTypeInfoToTensorInfo as *const _ as usize }, - 220usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CastTypeInfoToTensorInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetOnnxTypeFromTypeInfo as *const _ as usize }, - 224usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetOnnxTypeFromTypeInfo) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateTensorTypeAndShapeInfo as *const _ as usize - }, - 228usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateTensorTypeAndShapeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetTensorElementType as *const _ as usize }, - 232usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetTensorElementType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetDimensions as *const _ as usize }, - 236usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetDimensions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetTensorElementType as *const _ as usize }, - 240usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetTensorElementType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetDimensionsCount as *const _ as usize }, - 244usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetDimensionsCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetDimensions as *const _ as usize }, - 248usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetDimensions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetSymbolicDimensions as *const _ as usize }, - 252usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetSymbolicDimensions) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetTensorShapeElementCount as *const _ as usize - }, - 256usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetTensorShapeElementCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetTensorTypeAndShape as *const _ as usize }, - 260usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetTensorTypeAndShape) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetTypeInfo as *const _ as usize }, - 264usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetTypeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetValueType as *const _ as usize }, - 268usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetValueType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateMemoryInfo as *const _ as usize }, - 272usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateMemoryInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateCpuMemoryInfo as *const _ as usize }, - 276usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateCpuMemoryInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CompareMemoryInfo as *const _ as usize }, - 280usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CompareMemoryInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).MemoryInfoGetName as *const _ as usize }, - 284usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(MemoryInfoGetName) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).MemoryInfoGetId as *const _ as usize }, - 288usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(MemoryInfoGetId) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).MemoryInfoGetMemType as *const _ as usize }, - 292usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(MemoryInfoGetMemType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).MemoryInfoGetType as *const _ as usize }, - 296usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(MemoryInfoGetType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AllocatorAlloc as *const _ as usize }, - 300usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AllocatorAlloc) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AllocatorFree as *const _ as usize }, - 304usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AllocatorFree) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AllocatorGetInfo as *const _ as usize }, - 308usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AllocatorGetInfo) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetAllocatorWithDefaultOptions as *const _ as usize - }, - 312usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetAllocatorWithDefaultOptions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AddFreeDimensionOverride as *const _ as usize }, - 316usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AddFreeDimensionOverride) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetValue as *const _ as usize }, - 320usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetValue) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetValueCount as *const _ as usize }, - 324usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetValueCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateValue as *const _ as usize }, - 328usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateValue) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateOpaqueValue as *const _ as usize }, - 332usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateOpaqueValue) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetOpaqueValue as *const _ as usize }, - 336usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetOpaqueValue) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).KernelInfoGetAttribute_float as *const _ as usize - }, - 340usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelInfoGetAttribute_float) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).KernelInfoGetAttribute_int64 as *const _ as usize - }, - 344usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelInfoGetAttribute_int64) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).KernelInfoGetAttribute_string as *const _ as usize - }, - 348usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelInfoGetAttribute_string) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).KernelContext_GetInputCount as *const _ as usize - }, - 352usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelContext_GetInputCount) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).KernelContext_GetOutputCount as *const _ as usize - }, - 356usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelContext_GetOutputCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).KernelContext_GetInput as *const _ as usize }, - 360usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelContext_GetInput) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).KernelContext_GetOutput as *const _ as usize }, - 364usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelContext_GetOutput) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseEnv as *const _ as usize }, - 368usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseEnv) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseStatus as *const _ as usize }, - 372usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseStatus) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseMemoryInfo as *const _ as usize }, - 376usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseMemoryInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseSession as *const _ as usize }, - 380usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseSession) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseValue as *const _ as usize }, - 384usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseValue) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseRunOptions as *const _ as usize }, - 388usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseRunOptions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseTypeInfo as *const _ as usize }, - 392usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseTypeInfo) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ReleaseTensorTypeAndShapeInfo as *const _ as usize - }, - 396usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseTensorTypeAndShapeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseSessionOptions as *const _ as usize }, - 400usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseSessionOptions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseCustomOpDomain as *const _ as usize }, - 404usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseCustomOpDomain) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetDenotationFromTypeInfo as *const _ as usize - }, - 408usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetDenotationFromTypeInfo) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CastTypeInfoToMapTypeInfo as *const _ as usize - }, - 412usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CastTypeInfoToMapTypeInfo) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CastTypeInfoToSequenceTypeInfo as *const _ as usize - }, - 416usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CastTypeInfoToSequenceTypeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetMapKeyType as *const _ as usize }, - 420usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetMapKeyType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetMapValueType as *const _ as usize }, - 424usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetMapValueType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetSequenceElementType as *const _ as usize }, - 428usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetSequenceElementType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseMapTypeInfo as *const _ as usize }, - 432usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseMapTypeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseSequenceTypeInfo as *const _ as usize }, - 436usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseSequenceTypeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionEndProfiling as *const _ as usize }, - 440usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionEndProfiling) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionGetModelMetadata as *const _ as usize }, - 444usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetModelMetadata) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ModelMetadataGetProducerName as *const _ as usize - }, - 448usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataGetProducerName) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ModelMetadataGetGraphName as *const _ as usize - }, - 452usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataGetGraphName) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ModelMetadataGetDomain as *const _ as usize }, - 456usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataGetDomain) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ModelMetadataGetDescription as *const _ as usize - }, - 460usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataGetDescription) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ModelMetadataLookupCustomMetadataMap as *const _ - as usize - }, - 464usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataLookupCustomMetadataMap) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ModelMetadataGetVersion as *const _ as usize }, - 468usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataGetVersion) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseModelMetadata as *const _ as usize }, - 472usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseModelMetadata) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateEnvWithGlobalThreadPools as *const _ as usize - }, - 476usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateEnvWithGlobalThreadPools) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).DisablePerSessionThreads as *const _ as usize }, - 480usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(DisablePerSessionThreads) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateThreadingOptions as *const _ as usize }, - 484usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateThreadingOptions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseThreadingOptions as *const _ as usize }, - 488usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseThreadingOptions) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ModelMetadataGetCustomMetadataMapKeys as *const _ - as usize - }, - 492usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataGetCustomMetadataMapKeys) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).AddFreeDimensionOverrideByName as *const _ as usize - }, - 496usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AddFreeDimensionOverrideByName) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetAvailableProviders as *const _ as usize }, - 500usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetAvailableProviders) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ReleaseAvailableProviders as *const _ as usize - }, - 504usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseAvailableProviders) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetStringTensorElementLength as *const _ as usize - }, - 508usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetStringTensorElementLength) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetStringTensorElement as *const _ as usize }, - 512usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetStringTensorElement) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).FillStringTensorElement as *const _ as usize }, - 516usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(FillStringTensorElement) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AddSessionConfigEntry as *const _ as usize }, - 520usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AddSessionConfigEntry) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateAllocator as *const _ as usize }, - 524usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateAllocator) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseAllocator as *const _ as usize }, - 528usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseAllocator) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).RunWithBinding as *const _ as usize }, - 532usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunWithBinding) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateIoBinding as *const _ as usize }, - 536usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateIoBinding) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseIoBinding as *const _ as usize }, - 540usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseIoBinding) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).BindInput as *const _ as usize }, - 544usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(BindInput) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).BindOutput as *const _ as usize }, - 548usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(BindOutput) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).BindOutputToDevice as *const _ as usize }, - 552usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(BindOutputToDevice) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetBoundOutputNames as *const _ as usize }, - 556usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetBoundOutputNames) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetBoundOutputValues as *const _ as usize }, - 560usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetBoundOutputValues) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ClearBoundInputs as *const _ as usize }, - 564usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ClearBoundInputs) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ClearBoundOutputs as *const _ as usize }, - 568usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ClearBoundOutputs) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).TensorAt as *const _ as usize }, - 572usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(TensorAt) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateAndRegisterAllocator as *const _ as usize - }, - 576usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateAndRegisterAllocator) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetLanguageProjection as *const _ as usize }, - 580usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetLanguageProjection) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionGetProfilingStartTimeNs as *const _ as usize - }, - 584usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetProfilingStartTimeNs) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SetGlobalIntraOpNumThreads as *const _ as usize - }, - 588usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetGlobalIntraOpNumThreads) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SetGlobalInterOpNumThreads as *const _ as usize - }, - 592usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetGlobalInterOpNumThreads) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetGlobalSpinControl as *const _ as usize }, - 596usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetGlobalSpinControl) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AddInitializer as *const _ as usize }, - 600usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AddInitializer) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateEnvWithCustomLoggerAndGlobalThreadPools - as *const _ as usize - }, - 604usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateEnvWithCustomLoggerAndGlobalThreadPools) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionOptionsAppendExecutionProvider_CUDA - as *const _ as usize - }, - 608usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionOptionsAppendExecutionProvider_CUDA) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionOptionsAppendExecutionProvider_ROCM - as *const _ as usize - }, - 612usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionOptionsAppendExecutionProvider_ROCM) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionOptionsAppendExecutionProvider_OpenVINO - as *const _ as usize - }, - 616usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionOptionsAppendExecutionProvider_OpenVINO) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetGlobalDenormalAsZero as *const _ as usize }, - 620usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetGlobalDenormalAsZero) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateArenaCfg as *const _ as usize }, - 624usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateArenaCfg) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseArenaCfg as *const _ as usize }, - 628usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseArenaCfg) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ModelMetadataGetGraphDescription as *const _ as usize - }, - 632usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataGetGraphDescription) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionOptionsAppendExecutionProvider_TensorRT - as *const _ as usize - }, - 636usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionOptionsAppendExecutionProvider_TensorRT) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetCurrentGpuDeviceId as *const _ as usize }, - 640usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetCurrentGpuDeviceId) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetCurrentGpuDeviceId as *const _ as usize }, - 644usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetCurrentGpuDeviceId) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).KernelInfoGetAttributeArray_float as *const _ - as usize - }, - 648usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelInfoGetAttributeArray_float) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).KernelInfoGetAttributeArray_int64 as *const _ - as usize - }, - 652usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelInfoGetAttributeArray_int64) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateArenaCfgV2 as *const _ as usize }, - 656usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateArenaCfgV2) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AddRunConfigEntry as *const _ as usize }, - 660usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AddRunConfigEntry) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreatePrepackedWeightsContainer as *const _ as usize - }, - 664usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreatePrepackedWeightsContainer) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ReleasePrepackedWeightsContainer as *const _ as usize - }, - 668usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleasePrepackedWeightsContainer) - ) - ); + pub SessionOptionsAppendExecutionProvider_TensorRT_V2: ::std::option::Option< + unsafe extern "stdcall" fn( + options: *mut OrtSessionOptions, + tensorrt_options: *const OrtTensorRTProviderOptionsV2, + ) -> OrtStatusPtr, + >, + pub CreateTensorRTProviderOptions: ::std::option::Option< + unsafe extern "stdcall" fn(out: *mut *mut OrtTensorRTProviderOptionsV2) -> OrtStatusPtr, + >, + pub UpdateTensorRTProviderOptions: ::std::option::Option< + unsafe extern "stdcall" fn( + tensorrt_options: *mut OrtTensorRTProviderOptionsV2, + provider_options_keys: *const *const ::std::os::raw::c_char, + provider_options_values: *const *const ::std::os::raw::c_char, + num_keys: usize, + ) -> OrtStatusPtr, + >, + pub GetTensorRTProviderOptionsAsString: ::std::option::Option< + unsafe extern "stdcall" fn( + tensorrt_options: *const OrtTensorRTProviderOptionsV2, + allocator: *mut OrtAllocator, + ptr: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + #[doc = " \\brief Release an ::OrtTensorRTProviderOptionsV2"] + #[doc = ""] + #[doc = " \\note This is an exception in the naming convention of other Release* functions, as the name of the method does not have the V2 suffix, but the type does"] + pub ReleaseTensorRTProviderOptions: + ::std::option::Option, + pub EnableOrtCustomOps: ::std::option::Option< + unsafe extern "stdcall" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, + >, + pub RegisterAllocator: ::std::option::Option< + unsafe extern "stdcall" fn(env: *mut OrtEnv, allocator: *mut OrtAllocator) -> OrtStatusPtr, + >, + pub UnregisterAllocator: ::std::option::Option< + unsafe extern "stdcall" fn( + env: *mut OrtEnv, + mem_info: *const OrtMemoryInfo, + ) -> OrtStatusPtr, + >, + pub IsSparseTensor: ::std::option::Option< + unsafe extern "stdcall" fn( + value: *const OrtValue, + out: *mut ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub CreateSparseTensorAsOrtValue: ::std::option::Option< + unsafe extern "stdcall" fn( + allocator: *mut OrtAllocator, + dense_shape: *const i64, + dense_shape_len: usize, + type_: ONNXTensorElementDataType, + out: *mut *mut OrtValue, + ) -> OrtStatusPtr, + >, + pub FillSparseTensorCoo: ::std::option::Option< + unsafe extern "stdcall" fn( + ort_value: *mut OrtValue, + data_mem_info: *const OrtMemoryInfo, + values_shape: *const i64, + values_shape_len: usize, + values: *const ::std::os::raw::c_void, + indices_data: *const i64, + indices_num: usize, + ) -> OrtStatusPtr, + >, + pub FillSparseTensorCsr: ::std::option::Option< + unsafe extern "stdcall" fn( + ort_value: *mut OrtValue, + data_mem_info: *const OrtMemoryInfo, + values_shape: *const i64, + values_shape_len: usize, + values: *const ::std::os::raw::c_void, + inner_indices_data: *const i64, + inner_indices_num: usize, + outer_indices_data: *const i64, + outer_indices_num: usize, + ) -> OrtStatusPtr, + >, + pub FillSparseTensorBlockSparse: ::std::option::Option< + unsafe extern "stdcall" fn( + ort_value: *mut OrtValue, + data_mem_info: *const OrtMemoryInfo, + values_shape: *const i64, + values_shape_len: usize, + values: *const ::std::os::raw::c_void, + indices_shape_data: *const i64, + indices_shape_len: usize, + indices_data: *const i32, + ) -> OrtStatusPtr, + >, + pub CreateSparseTensorWithValuesAsOrtValue: ::std::option::Option< + unsafe extern "stdcall" fn( + info: *const OrtMemoryInfo, + p_data: *mut ::std::os::raw::c_void, + dense_shape: *const i64, + dense_shape_len: usize, + values_shape: *const i64, + values_shape_len: usize, + type_: ONNXTensorElementDataType, + out: *mut *mut OrtValue, + ) -> OrtStatusPtr, + >, + pub UseCooIndices: ::std::option::Option< + unsafe extern "stdcall" fn( + ort_value: *mut OrtValue, + indices_data: *mut i64, + indices_num: usize, + ) -> OrtStatusPtr, + >, + pub UseCsrIndices: ::std::option::Option< + unsafe extern "stdcall" fn( + ort_value: *mut OrtValue, + inner_data: *mut i64, + inner_num: usize, + outer_data: *mut i64, + outer_num: usize, + ) -> OrtStatusPtr, + >, + pub UseBlockSparseIndices: ::std::option::Option< + unsafe extern "stdcall" fn( + ort_value: *mut OrtValue, + indices_shape: *const i64, + indices_shape_len: usize, + indices_data: *mut i32, + ) -> OrtStatusPtr, + >, + pub GetSparseTensorFormat: ::std::option::Option< + unsafe extern "stdcall" fn( + ort_value: *const OrtValue, + out: *mut OrtSparseFormat, + ) -> OrtStatusPtr, + >, + pub GetSparseTensorValuesTypeAndShape: ::std::option::Option< + unsafe extern "stdcall" fn( + ort_value: *const OrtValue, + out: *mut *mut OrtTensorTypeAndShapeInfo, + ) -> OrtStatusPtr, + >, + pub GetSparseTensorValues: ::std::option::Option< + unsafe extern "stdcall" fn( + ort_value: *const OrtValue, + out: *mut *const ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub GetSparseTensorIndicesTypeShape: ::std::option::Option< + unsafe extern "stdcall" fn( + ort_value: *const OrtValue, + indices_format: OrtSparseIndicesFormat, + out: *mut *mut OrtTensorTypeAndShapeInfo, + ) -> OrtStatusPtr, + >, + pub GetSparseTensorIndices: ::std::option::Option< + unsafe extern "stdcall" fn( + ort_value: *const OrtValue, + indices_format: OrtSparseIndicesFormat, + num_indices: *mut usize, + indices: *mut *const ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub HasValue: ::std::option::Option< + unsafe extern "stdcall" fn( + value: *const OrtValue, + out: *mut ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub KernelContext_GetGPUComputeStream: ::std::option::Option< + unsafe extern "stdcall" fn( + context: *const OrtKernelContext, + out: *mut *mut ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub GetTensorMemoryInfo: ::std::option::Option< + unsafe extern "stdcall" fn( + value: *const OrtValue, + mem_info: *mut *const OrtMemoryInfo, + ) -> OrtStatusPtr, + >, + pub GetExecutionProviderApi: ::std::option::Option< + unsafe extern "stdcall" fn( + provider_name: *const ::std::os::raw::c_char, + version: u32, + provider_api: *mut *const ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub SessionOptionsSetCustomCreateThreadFn: ::std::option::Option< + unsafe extern "stdcall" fn( + options: *mut OrtSessionOptions, + ort_custom_create_thread_fn: OrtCustomCreateThreadFn, + ) -> OrtStatusPtr, + >, + pub SessionOptionsSetCustomThreadCreationOptions: ::std::option::Option< + unsafe extern "stdcall" fn( + options: *mut OrtSessionOptions, + ort_custom_thread_creation_options: *mut ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub SessionOptionsSetCustomJoinThreadFn: ::std::option::Option< + unsafe extern "stdcall" fn( + options: *mut OrtSessionOptions, + ort_custom_join_thread_fn: OrtCustomJoinThreadFn, + ) -> OrtStatusPtr, + >, + pub SetGlobalCustomCreateThreadFn: ::std::option::Option< + unsafe extern "stdcall" fn( + tp_options: *mut OrtThreadingOptions, + ort_custom_create_thread_fn: OrtCustomCreateThreadFn, + ) -> OrtStatusPtr, + >, + pub SetGlobalCustomThreadCreationOptions: ::std::option::Option< + unsafe extern "stdcall" fn( + tp_options: *mut OrtThreadingOptions, + ort_custom_thread_creation_options: *mut ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub SetGlobalCustomJoinThreadFn: ::std::option::Option< + unsafe extern "stdcall" fn( + tp_options: *mut OrtThreadingOptions, + ort_custom_join_thread_fn: OrtCustomJoinThreadFn, + ) -> OrtStatusPtr, + >, + pub SynchronizeBoundInputs: ::std::option::Option< + unsafe extern "stdcall" fn(binding_ptr: *mut OrtIoBinding) -> OrtStatusPtr, + >, + pub SynchronizeBoundOutputs: ::std::option::Option< + unsafe extern "stdcall" fn(binding_ptr: *mut OrtIoBinding) -> OrtStatusPtr, + >, + pub SessionOptionsAppendExecutionProvider_CUDA_V2: ::std::option::Option< + unsafe extern "stdcall" fn( + options: *mut OrtSessionOptions, + cuda_options: *const OrtCUDAProviderOptionsV2, + ) -> OrtStatusPtr, + >, + pub CreateCUDAProviderOptions: ::std::option::Option< + unsafe extern "stdcall" fn(out: *mut *mut OrtCUDAProviderOptionsV2) -> OrtStatusPtr, + >, + pub UpdateCUDAProviderOptions: ::std::option::Option< + unsafe extern "stdcall" fn( + cuda_options: *mut OrtCUDAProviderOptionsV2, + provider_options_keys: *const *const ::std::os::raw::c_char, + provider_options_values: *const *const ::std::os::raw::c_char, + num_keys: usize, + ) -> OrtStatusPtr, + >, + pub GetCUDAProviderOptionsAsString: ::std::option::Option< + unsafe extern "stdcall" fn( + cuda_options: *const OrtCUDAProviderOptionsV2, + allocator: *mut OrtAllocator, + ptr: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + #[doc = " \\brief Release an ::OrtCUDAProviderOptionsV2"] + #[doc = ""] + #[doc = " \\note This is an exception in the naming convention of other Release* functions, as the name of the method does not have the V2 suffix, but the type does"] + #[doc = ""] + #[doc = " \\since Version 1.11."] + pub ReleaseCUDAProviderOptions: + ::std::option::Option, + pub SessionOptionsAppendExecutionProvider_MIGraphX: ::std::option::Option< + unsafe extern "stdcall" fn( + options: *mut OrtSessionOptions, + migraphx_options: *const OrtMIGraphXProviderOptions, + ) -> OrtStatusPtr, + >, +} +#[test] +fn bindgen_test_layout_OrtApi() { assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateSessionWithPrepackedWeightsContainer - as *const _ as usize - }, - 672usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateSessionWithPrepackedWeightsContainer) - ) + ::std::mem::size_of::(), + 840usize, + concat!("Size of: ", stringify!(OrtApi)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateSessionFromArrayWithPrepackedWeightsContainer - as *const _ as usize - }, - 676usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateSessionFromArrayWithPrepackedWeightsContainer) - ) + ::std::mem::align_of::(), + 4usize, + concat!("Alignment of ", stringify!(OrtApi)) ); + fn test_field_CreateStatus() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateStatus) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateStatus) + ) + ); + } + test_field_CreateStatus(); + fn test_field_GetErrorCode() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetErrorCode) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetErrorCode) + ) + ); + } + test_field_GetErrorCode(); + fn test_field_GetErrorMessage() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetErrorMessage) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetErrorMessage) + ) + ); + } + test_field_GetErrorMessage(); + fn test_field_CreateEnv() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateEnv) as usize - ptr as usize + }, + 12usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateEnv) + ) + ); + } + test_field_CreateEnv(); + fn test_field_CreateEnvWithCustomLogger() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateEnvWithCustomLogger) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateEnvWithCustomLogger) + ) + ); + } + test_field_CreateEnvWithCustomLogger(); + fn test_field_EnableTelemetryEvents() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).EnableTelemetryEvents) as usize - ptr as usize + }, + 20usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(EnableTelemetryEvents) + ) + ); + } + test_field_EnableTelemetryEvents(); + fn test_field_DisableTelemetryEvents() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).DisableTelemetryEvents) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(DisableTelemetryEvents) + ) + ); + } + test_field_DisableTelemetryEvents(); + fn test_field_CreateSession() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateSession) as usize - ptr as usize + }, + 28usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateSession) + ) + ); + } + test_field_CreateSession(); + fn test_field_CreateSessionFromArray() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateSessionFromArray) as usize - ptr as usize + }, + 32usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateSessionFromArray) + ) + ); + } + test_field_CreateSessionFromArray(); + fn test_field_Run() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).Run) as usize - ptr as usize + }, + 36usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(Run) + ) + ); + } + test_field_Run(); + fn test_field_CreateSessionOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateSessionOptions) as usize - ptr as usize + }, + 40usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateSessionOptions) + ) + ); + } + test_field_CreateSessionOptions(); + fn test_field_SetOptimizedModelFilePath() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetOptimizedModelFilePath) as usize - ptr as usize + }, + 44usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetOptimizedModelFilePath) + ) + ); + } + test_field_SetOptimizedModelFilePath(); + fn test_field_CloneSessionOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CloneSessionOptions) as usize - ptr as usize + }, + 48usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CloneSessionOptions) + ) + ); + } + test_field_CloneSessionOptions(); + fn test_field_SetSessionExecutionMode() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetSessionExecutionMode) as usize - ptr as usize + }, + 52usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetSessionExecutionMode) + ) + ); + } + test_field_SetSessionExecutionMode(); + fn test_field_EnableProfiling() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).EnableProfiling) as usize - ptr as usize + }, + 56usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(EnableProfiling) + ) + ); + } + test_field_EnableProfiling(); + fn test_field_DisableProfiling() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).DisableProfiling) as usize - ptr as usize + }, + 60usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(DisableProfiling) + ) + ); + } + test_field_DisableProfiling(); + fn test_field_EnableMemPattern() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).EnableMemPattern) as usize - ptr as usize + }, + 64usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(EnableMemPattern) + ) + ); + } + test_field_EnableMemPattern(); + fn test_field_DisableMemPattern() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).DisableMemPattern) as usize - ptr as usize + }, + 68usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(DisableMemPattern) + ) + ); + } + test_field_DisableMemPattern(); + fn test_field_EnableCpuMemArena() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).EnableCpuMemArena) as usize - ptr as usize + }, + 72usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(EnableCpuMemArena) + ) + ); + } + test_field_EnableCpuMemArena(); + fn test_field_DisableCpuMemArena() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).DisableCpuMemArena) as usize - ptr as usize + }, + 76usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(DisableCpuMemArena) + ) + ); + } + test_field_DisableCpuMemArena(); + fn test_field_SetSessionLogId() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetSessionLogId) as usize - ptr as usize + }, + 80usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetSessionLogId) + ) + ); + } + test_field_SetSessionLogId(); + fn test_field_SetSessionLogVerbosityLevel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetSessionLogVerbosityLevel) as usize - ptr as usize + }, + 84usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetSessionLogVerbosityLevel) + ) + ); + } + test_field_SetSessionLogVerbosityLevel(); + fn test_field_SetSessionLogSeverityLevel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetSessionLogSeverityLevel) as usize - ptr as usize + }, + 88usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetSessionLogSeverityLevel) + ) + ); + } + test_field_SetSessionLogSeverityLevel(); + fn test_field_SetSessionGraphOptimizationLevel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetSessionGraphOptimizationLevel) as usize + - ptr as usize + }, + 92usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetSessionGraphOptimizationLevel) + ) + ); + } + test_field_SetSessionGraphOptimizationLevel(); + fn test_field_SetIntraOpNumThreads() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetIntraOpNumThreads) as usize - ptr as usize + }, + 96usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetIntraOpNumThreads) + ) + ); + } + test_field_SetIntraOpNumThreads(); + fn test_field_SetInterOpNumThreads() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetInterOpNumThreads) as usize - ptr as usize + }, + 100usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetInterOpNumThreads) + ) + ); + } + test_field_SetInterOpNumThreads(); + fn test_field_CreateCustomOpDomain() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateCustomOpDomain) as usize - ptr as usize + }, + 104usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateCustomOpDomain) + ) + ); + } + test_field_CreateCustomOpDomain(); + fn test_field_CustomOpDomain_Add() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CustomOpDomain_Add) as usize - ptr as usize + }, + 108usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CustomOpDomain_Add) + ) + ); + } + test_field_CustomOpDomain_Add(); + fn test_field_AddCustomOpDomain() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AddCustomOpDomain) as usize - ptr as usize + }, + 112usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AddCustomOpDomain) + ) + ); + } + test_field_AddCustomOpDomain(); + fn test_field_RegisterCustomOpsLibrary() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RegisterCustomOpsLibrary) as usize - ptr as usize + }, + 116usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RegisterCustomOpsLibrary) + ) + ); + } + test_field_RegisterCustomOpsLibrary(); + fn test_field_SessionGetInputCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetInputCount) as usize - ptr as usize + }, + 120usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetInputCount) + ) + ); + } + test_field_SessionGetInputCount(); + fn test_field_SessionGetOutputCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetOutputCount) as usize - ptr as usize + }, + 124usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetOutputCount) + ) + ); + } + test_field_SessionGetOutputCount(); + fn test_field_SessionGetOverridableInitializerCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetOverridableInitializerCount) as usize + - ptr as usize + }, + 128usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetOverridableInitializerCount) + ) + ); + } + test_field_SessionGetOverridableInitializerCount(); + fn test_field_SessionGetInputTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetInputTypeInfo) as usize - ptr as usize + }, + 132usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetInputTypeInfo) + ) + ); + } + test_field_SessionGetInputTypeInfo(); + fn test_field_SessionGetOutputTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetOutputTypeInfo) as usize - ptr as usize + }, + 136usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetOutputTypeInfo) + ) + ); + } + test_field_SessionGetOutputTypeInfo(); + fn test_field_SessionGetOverridableInitializerTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetOverridableInitializerTypeInfo) as usize + - ptr as usize + }, + 140usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetOverridableInitializerTypeInfo) + ) + ); + } + test_field_SessionGetOverridableInitializerTypeInfo(); + fn test_field_SessionGetInputName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetInputName) as usize - ptr as usize + }, + 144usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetInputName) + ) + ); + } + test_field_SessionGetInputName(); + fn test_field_SessionGetOutputName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetOutputName) as usize - ptr as usize + }, + 148usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetOutputName) + ) + ); + } + test_field_SessionGetOutputName(); + fn test_field_SessionGetOverridableInitializerName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetOverridableInitializerName) as usize + - ptr as usize + }, + 152usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetOverridableInitializerName) + ) + ); + } + test_field_SessionGetOverridableInitializerName(); + fn test_field_CreateRunOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateRunOptions) as usize - ptr as usize + }, + 156usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateRunOptions) + ) + ); + } + test_field_CreateRunOptions(); + fn test_field_RunOptionsSetRunLogVerbosityLevel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsSetRunLogVerbosityLevel) as usize + - ptr as usize + }, + 160usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsSetRunLogVerbosityLevel) + ) + ); + } + test_field_RunOptionsSetRunLogVerbosityLevel(); + fn test_field_RunOptionsSetRunLogSeverityLevel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsSetRunLogSeverityLevel) as usize + - ptr as usize + }, + 164usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsSetRunLogSeverityLevel) + ) + ); + } + test_field_RunOptionsSetRunLogSeverityLevel(); + fn test_field_RunOptionsSetRunTag() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsSetRunTag) as usize - ptr as usize + }, + 168usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsSetRunTag) + ) + ); + } + test_field_RunOptionsSetRunTag(); + fn test_field_RunOptionsGetRunLogVerbosityLevel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsGetRunLogVerbosityLevel) as usize + - ptr as usize + }, + 172usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsGetRunLogVerbosityLevel) + ) + ); + } + test_field_RunOptionsGetRunLogVerbosityLevel(); + fn test_field_RunOptionsGetRunLogSeverityLevel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsGetRunLogSeverityLevel) as usize + - ptr as usize + }, + 176usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsGetRunLogSeverityLevel) + ) + ); + } + test_field_RunOptionsGetRunLogSeverityLevel(); + fn test_field_RunOptionsGetRunTag() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsGetRunTag) as usize - ptr as usize + }, + 180usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsGetRunTag) + ) + ); + } + test_field_RunOptionsGetRunTag(); + fn test_field_RunOptionsSetTerminate() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsSetTerminate) as usize - ptr as usize + }, + 184usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsSetTerminate) + ) + ); + } + test_field_RunOptionsSetTerminate(); + fn test_field_RunOptionsUnsetTerminate() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsUnsetTerminate) as usize - ptr as usize + }, + 188usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsUnsetTerminate) + ) + ); + } + test_field_RunOptionsUnsetTerminate(); + fn test_field_CreateTensorAsOrtValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateTensorAsOrtValue) as usize - ptr as usize + }, + 192usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateTensorAsOrtValue) + ) + ); + } + test_field_CreateTensorAsOrtValue(); + fn test_field_CreateTensorWithDataAsOrtValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateTensorWithDataAsOrtValue) as usize - ptr as usize + }, + 196usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateTensorWithDataAsOrtValue) + ) + ); + } + test_field_CreateTensorWithDataAsOrtValue(); + fn test_field_IsTensor() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).IsTensor) as usize - ptr as usize + }, + 200usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(IsTensor) + ) + ); + } + test_field_IsTensor(); + fn test_field_GetTensorMutableData() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetTensorMutableData) as usize - ptr as usize + }, + 204usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetTensorMutableData) + ) + ); + } + test_field_GetTensorMutableData(); + fn test_field_FillStringTensor() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).FillStringTensor) as usize - ptr as usize + }, + 208usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(FillStringTensor) + ) + ); + } + test_field_FillStringTensor(); + fn test_field_GetStringTensorDataLength() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetStringTensorDataLength) as usize - ptr as usize + }, + 212usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetStringTensorDataLength) + ) + ); + } + test_field_GetStringTensorDataLength(); + fn test_field_GetStringTensorContent() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetStringTensorContent) as usize - ptr as usize + }, + 216usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetStringTensorContent) + ) + ); + } + test_field_GetStringTensorContent(); + fn test_field_CastTypeInfoToTensorInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CastTypeInfoToTensorInfo) as usize - ptr as usize + }, + 220usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CastTypeInfoToTensorInfo) + ) + ); + } + test_field_CastTypeInfoToTensorInfo(); + fn test_field_GetOnnxTypeFromTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetOnnxTypeFromTypeInfo) as usize - ptr as usize + }, + 224usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetOnnxTypeFromTypeInfo) + ) + ); + } + test_field_GetOnnxTypeFromTypeInfo(); + fn test_field_CreateTensorTypeAndShapeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateTensorTypeAndShapeInfo) as usize - ptr as usize + }, + 228usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateTensorTypeAndShapeInfo) + ) + ); + } + test_field_CreateTensorTypeAndShapeInfo(); + fn test_field_SetTensorElementType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetTensorElementType) as usize - ptr as usize + }, + 232usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetTensorElementType) + ) + ); + } + test_field_SetTensorElementType(); + fn test_field_SetDimensions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetDimensions) as usize - ptr as usize + }, + 236usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetDimensions) + ) + ); + } + test_field_SetDimensions(); + fn test_field_GetTensorElementType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetTensorElementType) as usize - ptr as usize + }, + 240usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetTensorElementType) + ) + ); + } + test_field_GetTensorElementType(); + fn test_field_GetDimensionsCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetDimensionsCount) as usize - ptr as usize + }, + 244usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetDimensionsCount) + ) + ); + } + test_field_GetDimensionsCount(); + fn test_field_GetDimensions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetDimensions) as usize - ptr as usize + }, + 248usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetDimensions) + ) + ); + } + test_field_GetDimensions(); + fn test_field_GetSymbolicDimensions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetSymbolicDimensions) as usize - ptr as usize + }, + 252usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetSymbolicDimensions) + ) + ); + } + test_field_GetSymbolicDimensions(); + fn test_field_GetTensorShapeElementCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetTensorShapeElementCount) as usize - ptr as usize + }, + 256usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetTensorShapeElementCount) + ) + ); + } + test_field_GetTensorShapeElementCount(); + fn test_field_GetTensorTypeAndShape() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetTensorTypeAndShape) as usize - ptr as usize + }, + 260usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetTensorTypeAndShape) + ) + ); + } + test_field_GetTensorTypeAndShape(); + fn test_field_GetTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetTypeInfo) as usize - ptr as usize + }, + 264usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetTypeInfo) + ) + ); + } + test_field_GetTypeInfo(); + fn test_field_GetValueType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetValueType) as usize - ptr as usize + }, + 268usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetValueType) + ) + ); + } + test_field_GetValueType(); + fn test_field_CreateMemoryInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateMemoryInfo) as usize - ptr as usize + }, + 272usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateMemoryInfo) + ) + ); + } + test_field_CreateMemoryInfo(); + fn test_field_CreateCpuMemoryInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateCpuMemoryInfo) as usize - ptr as usize + }, + 276usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateCpuMemoryInfo) + ) + ); + } + test_field_CreateCpuMemoryInfo(); + fn test_field_CompareMemoryInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CompareMemoryInfo) as usize - ptr as usize + }, + 280usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CompareMemoryInfo) + ) + ); + } + test_field_CompareMemoryInfo(); + fn test_field_MemoryInfoGetName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).MemoryInfoGetName) as usize - ptr as usize + }, + 284usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(MemoryInfoGetName) + ) + ); + } + test_field_MemoryInfoGetName(); + fn test_field_MemoryInfoGetId() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).MemoryInfoGetId) as usize - ptr as usize + }, + 288usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(MemoryInfoGetId) + ) + ); + } + test_field_MemoryInfoGetId(); + fn test_field_MemoryInfoGetMemType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).MemoryInfoGetMemType) as usize - ptr as usize + }, + 292usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(MemoryInfoGetMemType) + ) + ); + } + test_field_MemoryInfoGetMemType(); + fn test_field_MemoryInfoGetType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).MemoryInfoGetType) as usize - ptr as usize + }, + 296usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(MemoryInfoGetType) + ) + ); + } + test_field_MemoryInfoGetType(); + fn test_field_AllocatorAlloc() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AllocatorAlloc) as usize - ptr as usize + }, + 300usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AllocatorAlloc) + ) + ); + } + test_field_AllocatorAlloc(); + fn test_field_AllocatorFree() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AllocatorFree) as usize - ptr as usize + }, + 304usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AllocatorFree) + ) + ); + } + test_field_AllocatorFree(); + fn test_field_AllocatorGetInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AllocatorGetInfo) as usize - ptr as usize + }, + 308usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AllocatorGetInfo) + ) + ); + } + test_field_AllocatorGetInfo(); + fn test_field_GetAllocatorWithDefaultOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetAllocatorWithDefaultOptions) as usize - ptr as usize + }, + 312usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetAllocatorWithDefaultOptions) + ) + ); + } + test_field_GetAllocatorWithDefaultOptions(); + fn test_field_AddFreeDimensionOverride() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AddFreeDimensionOverride) as usize - ptr as usize + }, + 316usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AddFreeDimensionOverride) + ) + ); + } + test_field_AddFreeDimensionOverride(); + fn test_field_GetValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetValue) as usize - ptr as usize + }, + 320usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetValue) + ) + ); + } + test_field_GetValue(); + fn test_field_GetValueCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetValueCount) as usize - ptr as usize + }, + 324usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetValueCount) + ) + ); + } + test_field_GetValueCount(); + fn test_field_CreateValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateValue) as usize - ptr as usize + }, + 328usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateValue) + ) + ); + } + test_field_CreateValue(); + fn test_field_CreateOpaqueValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateOpaqueValue) as usize - ptr as usize + }, + 332usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateOpaqueValue) + ) + ); + } + test_field_CreateOpaqueValue(); + fn test_field_GetOpaqueValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetOpaqueValue) as usize - ptr as usize + }, + 336usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetOpaqueValue) + ) + ); + } + test_field_GetOpaqueValue(); + fn test_field_KernelInfoGetAttribute_float() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelInfoGetAttribute_float) as usize - ptr as usize + }, + 340usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelInfoGetAttribute_float) + ) + ); + } + test_field_KernelInfoGetAttribute_float(); + fn test_field_KernelInfoGetAttribute_int64() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelInfoGetAttribute_int64) as usize - ptr as usize + }, + 344usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelInfoGetAttribute_int64) + ) + ); + } + test_field_KernelInfoGetAttribute_int64(); + fn test_field_KernelInfoGetAttribute_string() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelInfoGetAttribute_string) as usize - ptr as usize + }, + 348usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelInfoGetAttribute_string) + ) + ); + } + test_field_KernelInfoGetAttribute_string(); + fn test_field_KernelContext_GetInputCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelContext_GetInputCount) as usize - ptr as usize + }, + 352usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelContext_GetInputCount) + ) + ); + } + test_field_KernelContext_GetInputCount(); + fn test_field_KernelContext_GetOutputCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelContext_GetOutputCount) as usize - ptr as usize + }, + 356usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelContext_GetOutputCount) + ) + ); + } + test_field_KernelContext_GetOutputCount(); + fn test_field_KernelContext_GetInput() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelContext_GetInput) as usize - ptr as usize + }, + 360usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelContext_GetInput) + ) + ); + } + test_field_KernelContext_GetInput(); + fn test_field_KernelContext_GetOutput() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelContext_GetOutput) as usize - ptr as usize + }, + 364usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelContext_GetOutput) + ) + ); + } + test_field_KernelContext_GetOutput(); + fn test_field_ReleaseEnv() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseEnv) as usize - ptr as usize + }, + 368usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseEnv) + ) + ); + } + test_field_ReleaseEnv(); + fn test_field_ReleaseStatus() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseStatus) as usize - ptr as usize + }, + 372usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseStatus) + ) + ); + } + test_field_ReleaseStatus(); + fn test_field_ReleaseMemoryInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseMemoryInfo) as usize - ptr as usize + }, + 376usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseMemoryInfo) + ) + ); + } + test_field_ReleaseMemoryInfo(); + fn test_field_ReleaseSession() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseSession) as usize - ptr as usize + }, + 380usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseSession) + ) + ); + } + test_field_ReleaseSession(); + fn test_field_ReleaseValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseValue) as usize - ptr as usize + }, + 384usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseValue) + ) + ); + } + test_field_ReleaseValue(); + fn test_field_ReleaseRunOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseRunOptions) as usize - ptr as usize + }, + 388usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseRunOptions) + ) + ); + } + test_field_ReleaseRunOptions(); + fn test_field_ReleaseTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseTypeInfo) as usize - ptr as usize + }, + 392usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseTypeInfo) + ) + ); + } + test_field_ReleaseTypeInfo(); + fn test_field_ReleaseTensorTypeAndShapeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseTensorTypeAndShapeInfo) as usize - ptr as usize + }, + 396usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseTensorTypeAndShapeInfo) + ) + ); + } + test_field_ReleaseTensorTypeAndShapeInfo(); + fn test_field_ReleaseSessionOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseSessionOptions) as usize - ptr as usize + }, + 400usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseSessionOptions) + ) + ); + } + test_field_ReleaseSessionOptions(); + fn test_field_ReleaseCustomOpDomain() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseCustomOpDomain) as usize - ptr as usize + }, + 404usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseCustomOpDomain) + ) + ); + } + test_field_ReleaseCustomOpDomain(); + fn test_field_GetDenotationFromTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetDenotationFromTypeInfo) as usize - ptr as usize + }, + 408usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetDenotationFromTypeInfo) + ) + ); + } + test_field_GetDenotationFromTypeInfo(); + fn test_field_CastTypeInfoToMapTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CastTypeInfoToMapTypeInfo) as usize - ptr as usize + }, + 412usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CastTypeInfoToMapTypeInfo) + ) + ); + } + test_field_CastTypeInfoToMapTypeInfo(); + fn test_field_CastTypeInfoToSequenceTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CastTypeInfoToSequenceTypeInfo) as usize - ptr as usize + }, + 416usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CastTypeInfoToSequenceTypeInfo) + ) + ); + } + test_field_CastTypeInfoToSequenceTypeInfo(); + fn test_field_GetMapKeyType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetMapKeyType) as usize - ptr as usize + }, + 420usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetMapKeyType) + ) + ); + } + test_field_GetMapKeyType(); + fn test_field_GetMapValueType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetMapValueType) as usize - ptr as usize + }, + 424usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetMapValueType) + ) + ); + } + test_field_GetMapValueType(); + fn test_field_GetSequenceElementType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetSequenceElementType) as usize - ptr as usize + }, + 428usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetSequenceElementType) + ) + ); + } + test_field_GetSequenceElementType(); + fn test_field_ReleaseMapTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseMapTypeInfo) as usize - ptr as usize + }, + 432usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseMapTypeInfo) + ) + ); + } + test_field_ReleaseMapTypeInfo(); + fn test_field_ReleaseSequenceTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseSequenceTypeInfo) as usize - ptr as usize + }, + 436usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseSequenceTypeInfo) + ) + ); + } + test_field_ReleaseSequenceTypeInfo(); + fn test_field_SessionEndProfiling() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionEndProfiling) as usize - ptr as usize + }, + 440usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionEndProfiling) + ) + ); + } + test_field_SessionEndProfiling(); + fn test_field_SessionGetModelMetadata() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetModelMetadata) as usize - ptr as usize + }, + 444usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetModelMetadata) + ) + ); + } + test_field_SessionGetModelMetadata(); + fn test_field_ModelMetadataGetProducerName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataGetProducerName) as usize - ptr as usize + }, + 448usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataGetProducerName) + ) + ); + } + test_field_ModelMetadataGetProducerName(); + fn test_field_ModelMetadataGetGraphName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataGetGraphName) as usize - ptr as usize + }, + 452usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataGetGraphName) + ) + ); + } + test_field_ModelMetadataGetGraphName(); + fn test_field_ModelMetadataGetDomain() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataGetDomain) as usize - ptr as usize + }, + 456usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataGetDomain) + ) + ); + } + test_field_ModelMetadataGetDomain(); + fn test_field_ModelMetadataGetDescription() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataGetDescription) as usize - ptr as usize + }, + 460usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataGetDescription) + ) + ); + } + test_field_ModelMetadataGetDescription(); + fn test_field_ModelMetadataLookupCustomMetadataMap() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataLookupCustomMetadataMap) as usize + - ptr as usize + }, + 464usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataLookupCustomMetadataMap) + ) + ); + } + test_field_ModelMetadataLookupCustomMetadataMap(); + fn test_field_ModelMetadataGetVersion() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataGetVersion) as usize - ptr as usize + }, + 468usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataGetVersion) + ) + ); + } + test_field_ModelMetadataGetVersion(); + fn test_field_ReleaseModelMetadata() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseModelMetadata) as usize - ptr as usize + }, + 472usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseModelMetadata) + ) + ); + } + test_field_ReleaseModelMetadata(); + fn test_field_CreateEnvWithGlobalThreadPools() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateEnvWithGlobalThreadPools) as usize - ptr as usize + }, + 476usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateEnvWithGlobalThreadPools) + ) + ); + } + test_field_CreateEnvWithGlobalThreadPools(); + fn test_field_DisablePerSessionThreads() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).DisablePerSessionThreads) as usize - ptr as usize + }, + 480usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(DisablePerSessionThreads) + ) + ); + } + test_field_DisablePerSessionThreads(); + fn test_field_CreateThreadingOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateThreadingOptions) as usize - ptr as usize + }, + 484usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateThreadingOptions) + ) + ); + } + test_field_CreateThreadingOptions(); + fn test_field_ReleaseThreadingOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseThreadingOptions) as usize - ptr as usize + }, + 488usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseThreadingOptions) + ) + ); + } + test_field_ReleaseThreadingOptions(); + fn test_field_ModelMetadataGetCustomMetadataMapKeys() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataGetCustomMetadataMapKeys) as usize + - ptr as usize + }, + 492usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataGetCustomMetadataMapKeys) + ) + ); + } + test_field_ModelMetadataGetCustomMetadataMapKeys(); + fn test_field_AddFreeDimensionOverrideByName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AddFreeDimensionOverrideByName) as usize - ptr as usize + }, + 496usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AddFreeDimensionOverrideByName) + ) + ); + } + test_field_AddFreeDimensionOverrideByName(); + fn test_field_GetAvailableProviders() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetAvailableProviders) as usize - ptr as usize + }, + 500usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetAvailableProviders) + ) + ); + } + test_field_GetAvailableProviders(); + fn test_field_ReleaseAvailableProviders() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseAvailableProviders) as usize - ptr as usize + }, + 504usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseAvailableProviders) + ) + ); + } + test_field_ReleaseAvailableProviders(); + fn test_field_GetStringTensorElementLength() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetStringTensorElementLength) as usize - ptr as usize + }, + 508usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetStringTensorElementLength) + ) + ); + } + test_field_GetStringTensorElementLength(); + fn test_field_GetStringTensorElement() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetStringTensorElement) as usize - ptr as usize + }, + 512usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetStringTensorElement) + ) + ); + } + test_field_GetStringTensorElement(); + fn test_field_FillStringTensorElement() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).FillStringTensorElement) as usize - ptr as usize + }, + 516usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(FillStringTensorElement) + ) + ); + } + test_field_FillStringTensorElement(); + fn test_field_AddSessionConfigEntry() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AddSessionConfigEntry) as usize - ptr as usize + }, + 520usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AddSessionConfigEntry) + ) + ); + } + test_field_AddSessionConfigEntry(); + fn test_field_CreateAllocator() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateAllocator) as usize - ptr as usize + }, + 524usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateAllocator) + ) + ); + } + test_field_CreateAllocator(); + fn test_field_ReleaseAllocator() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseAllocator) as usize - ptr as usize + }, + 528usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseAllocator) + ) + ); + } + test_field_ReleaseAllocator(); + fn test_field_RunWithBinding() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunWithBinding) as usize - ptr as usize + }, + 532usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunWithBinding) + ) + ); + } + test_field_RunWithBinding(); + fn test_field_CreateIoBinding() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateIoBinding) as usize - ptr as usize + }, + 536usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateIoBinding) + ) + ); + } + test_field_CreateIoBinding(); + fn test_field_ReleaseIoBinding() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseIoBinding) as usize - ptr as usize + }, + 540usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseIoBinding) + ) + ); + } + test_field_ReleaseIoBinding(); + fn test_field_BindInput() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).BindInput) as usize - ptr as usize + }, + 544usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(BindInput) + ) + ); + } + test_field_BindInput(); + fn test_field_BindOutput() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).BindOutput) as usize - ptr as usize + }, + 548usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(BindOutput) + ) + ); + } + test_field_BindOutput(); + fn test_field_BindOutputToDevice() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).BindOutputToDevice) as usize - ptr as usize + }, + 552usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(BindOutputToDevice) + ) + ); + } + test_field_BindOutputToDevice(); + fn test_field_GetBoundOutputNames() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetBoundOutputNames) as usize - ptr as usize + }, + 556usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetBoundOutputNames) + ) + ); + } + test_field_GetBoundOutputNames(); + fn test_field_GetBoundOutputValues() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetBoundOutputValues) as usize - ptr as usize + }, + 560usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetBoundOutputValues) + ) + ); + } + test_field_GetBoundOutputValues(); + fn test_field_ClearBoundInputs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ClearBoundInputs) as usize - ptr as usize + }, + 564usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ClearBoundInputs) + ) + ); + } + test_field_ClearBoundInputs(); + fn test_field_ClearBoundOutputs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ClearBoundOutputs) as usize - ptr as usize + }, + 568usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ClearBoundOutputs) + ) + ); + } + test_field_ClearBoundOutputs(); + fn test_field_TensorAt() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).TensorAt) as usize - ptr as usize + }, + 572usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(TensorAt) + ) + ); + } + test_field_TensorAt(); + fn test_field_CreateAndRegisterAllocator() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateAndRegisterAllocator) as usize - ptr as usize + }, + 576usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateAndRegisterAllocator) + ) + ); + } + test_field_CreateAndRegisterAllocator(); + fn test_field_SetLanguageProjection() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetLanguageProjection) as usize - ptr as usize + }, + 580usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetLanguageProjection) + ) + ); + } + test_field_SetLanguageProjection(); + fn test_field_SessionGetProfilingStartTimeNs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetProfilingStartTimeNs) as usize - ptr as usize + }, + 584usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetProfilingStartTimeNs) + ) + ); + } + test_field_SessionGetProfilingStartTimeNs(); + fn test_field_SetGlobalIntraOpNumThreads() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetGlobalIntraOpNumThreads) as usize - ptr as usize + }, + 588usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetGlobalIntraOpNumThreads) + ) + ); + } + test_field_SetGlobalIntraOpNumThreads(); + fn test_field_SetGlobalInterOpNumThreads() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetGlobalInterOpNumThreads) as usize - ptr as usize + }, + 592usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetGlobalInterOpNumThreads) + ) + ); + } + test_field_SetGlobalInterOpNumThreads(); + fn test_field_SetGlobalSpinControl() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetGlobalSpinControl) as usize - ptr as usize + }, + 596usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetGlobalSpinControl) + ) + ); + } + test_field_SetGlobalSpinControl(); + fn test_field_AddInitializer() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AddInitializer) as usize - ptr as usize + }, + 600usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AddInitializer) + ) + ); + } + test_field_AddInitializer(); + fn test_field_CreateEnvWithCustomLoggerAndGlobalThreadPools() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateEnvWithCustomLoggerAndGlobalThreadPools) as usize + - ptr as usize + }, + 604usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateEnvWithCustomLoggerAndGlobalThreadPools) + ) + ); + } + test_field_CreateEnvWithCustomLoggerAndGlobalThreadPools(); + fn test_field_SessionOptionsAppendExecutionProvider_CUDA() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsAppendExecutionProvider_CUDA) as usize + - ptr as usize + }, + 608usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsAppendExecutionProvider_CUDA) + ) + ); + } + test_field_SessionOptionsAppendExecutionProvider_CUDA(); + fn test_field_SessionOptionsAppendExecutionProvider_ROCM() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsAppendExecutionProvider_ROCM) as usize + - ptr as usize + }, + 612usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsAppendExecutionProvider_ROCM) + ) + ); + } + test_field_SessionOptionsAppendExecutionProvider_ROCM(); + fn test_field_SessionOptionsAppendExecutionProvider_OpenVINO() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsAppendExecutionProvider_OpenVINO) as usize + - ptr as usize + }, + 616usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsAppendExecutionProvider_OpenVINO) + ) + ); + } + test_field_SessionOptionsAppendExecutionProvider_OpenVINO(); + fn test_field_SetGlobalDenormalAsZero() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetGlobalDenormalAsZero) as usize - ptr as usize + }, + 620usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetGlobalDenormalAsZero) + ) + ); + } + test_field_SetGlobalDenormalAsZero(); + fn test_field_CreateArenaCfg() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateArenaCfg) as usize - ptr as usize + }, + 624usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateArenaCfg) + ) + ); + } + test_field_CreateArenaCfg(); + fn test_field_ReleaseArenaCfg() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseArenaCfg) as usize - ptr as usize + }, + 628usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseArenaCfg) + ) + ); + } + test_field_ReleaseArenaCfg(); + fn test_field_ModelMetadataGetGraphDescription() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataGetGraphDescription) as usize + - ptr as usize + }, + 632usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataGetGraphDescription) + ) + ); + } + test_field_ModelMetadataGetGraphDescription(); + fn test_field_SessionOptionsAppendExecutionProvider_TensorRT() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsAppendExecutionProvider_TensorRT) as usize + - ptr as usize + }, + 636usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsAppendExecutionProvider_TensorRT) + ) + ); + } + test_field_SessionOptionsAppendExecutionProvider_TensorRT(); + fn test_field_SetCurrentGpuDeviceId() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetCurrentGpuDeviceId) as usize - ptr as usize + }, + 640usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetCurrentGpuDeviceId) + ) + ); + } + test_field_SetCurrentGpuDeviceId(); + fn test_field_GetCurrentGpuDeviceId() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetCurrentGpuDeviceId) as usize - ptr as usize + }, + 644usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetCurrentGpuDeviceId) + ) + ); + } + test_field_GetCurrentGpuDeviceId(); + fn test_field_KernelInfoGetAttributeArray_float() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelInfoGetAttributeArray_float) as usize + - ptr as usize + }, + 648usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelInfoGetAttributeArray_float) + ) + ); + } + test_field_KernelInfoGetAttributeArray_float(); + fn test_field_KernelInfoGetAttributeArray_int64() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelInfoGetAttributeArray_int64) as usize + - ptr as usize + }, + 652usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelInfoGetAttributeArray_int64) + ) + ); + } + test_field_KernelInfoGetAttributeArray_int64(); + fn test_field_CreateArenaCfgV2() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateArenaCfgV2) as usize - ptr as usize + }, + 656usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateArenaCfgV2) + ) + ); + } + test_field_CreateArenaCfgV2(); + fn test_field_AddRunConfigEntry() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AddRunConfigEntry) as usize - ptr as usize + }, + 660usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AddRunConfigEntry) + ) + ); + } + test_field_AddRunConfigEntry(); + fn test_field_CreatePrepackedWeightsContainer() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreatePrepackedWeightsContainer) as usize - ptr as usize + }, + 664usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreatePrepackedWeightsContainer) + ) + ); + } + test_field_CreatePrepackedWeightsContainer(); + fn test_field_ReleasePrepackedWeightsContainer() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleasePrepackedWeightsContainer) as usize + - ptr as usize + }, + 668usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleasePrepackedWeightsContainer) + ) + ); + } + test_field_ReleasePrepackedWeightsContainer(); + fn test_field_CreateSessionWithPrepackedWeightsContainer() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateSessionWithPrepackedWeightsContainer) as usize + - ptr as usize + }, + 672usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateSessionWithPrepackedWeightsContainer) + ) + ); + } + test_field_CreateSessionWithPrepackedWeightsContainer(); + fn test_field_CreateSessionFromArrayWithPrepackedWeightsContainer() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateSessionFromArrayWithPrepackedWeightsContainer) + as usize + - ptr as usize + }, + 676usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateSessionFromArrayWithPrepackedWeightsContainer) + ) + ); + } + test_field_CreateSessionFromArrayWithPrepackedWeightsContainer(); + fn test_field_SessionOptionsAppendExecutionProvider_TensorRT_V2() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsAppendExecutionProvider_TensorRT_V2) + as usize + - ptr as usize + }, + 680usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsAppendExecutionProvider_TensorRT_V2) + ) + ); + } + test_field_SessionOptionsAppendExecutionProvider_TensorRT_V2(); + fn test_field_CreateTensorRTProviderOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateTensorRTProviderOptions) as usize - ptr as usize + }, + 684usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateTensorRTProviderOptions) + ) + ); + } + test_field_CreateTensorRTProviderOptions(); + fn test_field_UpdateTensorRTProviderOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).UpdateTensorRTProviderOptions) as usize - ptr as usize + }, + 688usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(UpdateTensorRTProviderOptions) + ) + ); + } + test_field_UpdateTensorRTProviderOptions(); + fn test_field_GetTensorRTProviderOptionsAsString() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetTensorRTProviderOptionsAsString) as usize + - ptr as usize + }, + 692usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetTensorRTProviderOptionsAsString) + ) + ); + } + test_field_GetTensorRTProviderOptionsAsString(); + fn test_field_ReleaseTensorRTProviderOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseTensorRTProviderOptions) as usize - ptr as usize + }, + 696usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseTensorRTProviderOptions) + ) + ); + } + test_field_ReleaseTensorRTProviderOptions(); + fn test_field_EnableOrtCustomOps() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).EnableOrtCustomOps) as usize - ptr as usize + }, + 700usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(EnableOrtCustomOps) + ) + ); + } + test_field_EnableOrtCustomOps(); + fn test_field_RegisterAllocator() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RegisterAllocator) as usize - ptr as usize + }, + 704usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RegisterAllocator) + ) + ); + } + test_field_RegisterAllocator(); + fn test_field_UnregisterAllocator() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).UnregisterAllocator) as usize - ptr as usize + }, + 708usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(UnregisterAllocator) + ) + ); + } + test_field_UnregisterAllocator(); + fn test_field_IsSparseTensor() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).IsSparseTensor) as usize - ptr as usize + }, + 712usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(IsSparseTensor) + ) + ); + } + test_field_IsSparseTensor(); + fn test_field_CreateSparseTensorAsOrtValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateSparseTensorAsOrtValue) as usize - ptr as usize + }, + 716usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateSparseTensorAsOrtValue) + ) + ); + } + test_field_CreateSparseTensorAsOrtValue(); + fn test_field_FillSparseTensorCoo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).FillSparseTensorCoo) as usize - ptr as usize + }, + 720usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(FillSparseTensorCoo) + ) + ); + } + test_field_FillSparseTensorCoo(); + fn test_field_FillSparseTensorCsr() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).FillSparseTensorCsr) as usize - ptr as usize + }, + 724usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(FillSparseTensorCsr) + ) + ); + } + test_field_FillSparseTensorCsr(); + fn test_field_FillSparseTensorBlockSparse() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).FillSparseTensorBlockSparse) as usize - ptr as usize + }, + 728usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(FillSparseTensorBlockSparse) + ) + ); + } + test_field_FillSparseTensorBlockSparse(); + fn test_field_CreateSparseTensorWithValuesAsOrtValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateSparseTensorWithValuesAsOrtValue) as usize + - ptr as usize + }, + 732usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateSparseTensorWithValuesAsOrtValue) + ) + ); + } + test_field_CreateSparseTensorWithValuesAsOrtValue(); + fn test_field_UseCooIndices() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).UseCooIndices) as usize - ptr as usize + }, + 736usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(UseCooIndices) + ) + ); + } + test_field_UseCooIndices(); + fn test_field_UseCsrIndices() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).UseCsrIndices) as usize - ptr as usize + }, + 740usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(UseCsrIndices) + ) + ); + } + test_field_UseCsrIndices(); + fn test_field_UseBlockSparseIndices() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).UseBlockSparseIndices) as usize - ptr as usize + }, + 744usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(UseBlockSparseIndices) + ) + ); + } + test_field_UseBlockSparseIndices(); + fn test_field_GetSparseTensorFormat() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetSparseTensorFormat) as usize - ptr as usize + }, + 748usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetSparseTensorFormat) + ) + ); + } + test_field_GetSparseTensorFormat(); + fn test_field_GetSparseTensorValuesTypeAndShape() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetSparseTensorValuesTypeAndShape) as usize + - ptr as usize + }, + 752usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetSparseTensorValuesTypeAndShape) + ) + ); + } + test_field_GetSparseTensorValuesTypeAndShape(); + fn test_field_GetSparseTensorValues() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetSparseTensorValues) as usize - ptr as usize + }, + 756usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetSparseTensorValues) + ) + ); + } + test_field_GetSparseTensorValues(); + fn test_field_GetSparseTensorIndicesTypeShape() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetSparseTensorIndicesTypeShape) as usize - ptr as usize + }, + 760usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetSparseTensorIndicesTypeShape) + ) + ); + } + test_field_GetSparseTensorIndicesTypeShape(); + fn test_field_GetSparseTensorIndices() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetSparseTensorIndices) as usize - ptr as usize + }, + 764usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetSparseTensorIndices) + ) + ); + } + test_field_GetSparseTensorIndices(); + fn test_field_HasValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).HasValue) as usize - ptr as usize + }, + 768usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(HasValue) + ) + ); + } + test_field_HasValue(); + fn test_field_KernelContext_GetGPUComputeStream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelContext_GetGPUComputeStream) as usize + - ptr as usize + }, + 772usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelContext_GetGPUComputeStream) + ) + ); + } + test_field_KernelContext_GetGPUComputeStream(); + fn test_field_GetTensorMemoryInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetTensorMemoryInfo) as usize - ptr as usize + }, + 776usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetTensorMemoryInfo) + ) + ); + } + test_field_GetTensorMemoryInfo(); + fn test_field_GetExecutionProviderApi() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetExecutionProviderApi) as usize - ptr as usize + }, + 780usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetExecutionProviderApi) + ) + ); + } + test_field_GetExecutionProviderApi(); + fn test_field_SessionOptionsSetCustomCreateThreadFn() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsSetCustomCreateThreadFn) as usize + - ptr as usize + }, + 784usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsSetCustomCreateThreadFn) + ) + ); + } + test_field_SessionOptionsSetCustomCreateThreadFn(); + fn test_field_SessionOptionsSetCustomThreadCreationOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsSetCustomThreadCreationOptions) as usize + - ptr as usize + }, + 788usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsSetCustomThreadCreationOptions) + ) + ); + } + test_field_SessionOptionsSetCustomThreadCreationOptions(); + fn test_field_SessionOptionsSetCustomJoinThreadFn() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsSetCustomJoinThreadFn) as usize + - ptr as usize + }, + 792usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsSetCustomJoinThreadFn) + ) + ); + } + test_field_SessionOptionsSetCustomJoinThreadFn(); + fn test_field_SetGlobalCustomCreateThreadFn() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetGlobalCustomCreateThreadFn) as usize - ptr as usize + }, + 796usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetGlobalCustomCreateThreadFn) + ) + ); + } + test_field_SetGlobalCustomCreateThreadFn(); + fn test_field_SetGlobalCustomThreadCreationOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetGlobalCustomThreadCreationOptions) as usize + - ptr as usize + }, + 800usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetGlobalCustomThreadCreationOptions) + ) + ); + } + test_field_SetGlobalCustomThreadCreationOptions(); + fn test_field_SetGlobalCustomJoinThreadFn() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetGlobalCustomJoinThreadFn) as usize - ptr as usize + }, + 804usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetGlobalCustomJoinThreadFn) + ) + ); + } + test_field_SetGlobalCustomJoinThreadFn(); + fn test_field_SynchronizeBoundInputs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SynchronizeBoundInputs) as usize - ptr as usize + }, + 808usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SynchronizeBoundInputs) + ) + ); + } + test_field_SynchronizeBoundInputs(); + fn test_field_SynchronizeBoundOutputs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SynchronizeBoundOutputs) as usize - ptr as usize + }, + 812usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SynchronizeBoundOutputs) + ) + ); + } + test_field_SynchronizeBoundOutputs(); + fn test_field_SessionOptionsAppendExecutionProvider_CUDA_V2() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsAppendExecutionProvider_CUDA_V2) as usize + - ptr as usize + }, + 816usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsAppendExecutionProvider_CUDA_V2) + ) + ); + } + test_field_SessionOptionsAppendExecutionProvider_CUDA_V2(); + fn test_field_CreateCUDAProviderOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateCUDAProviderOptions) as usize - ptr as usize + }, + 820usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateCUDAProviderOptions) + ) + ); + } + test_field_CreateCUDAProviderOptions(); + fn test_field_UpdateCUDAProviderOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).UpdateCUDAProviderOptions) as usize - ptr as usize + }, + 824usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(UpdateCUDAProviderOptions) + ) + ); + } + test_field_UpdateCUDAProviderOptions(); + fn test_field_GetCUDAProviderOptionsAsString() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetCUDAProviderOptionsAsString) as usize - ptr as usize + }, + 828usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetCUDAProviderOptionsAsString) + ) + ); + } + test_field_GetCUDAProviderOptionsAsString(); + fn test_field_ReleaseCUDAProviderOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseCUDAProviderOptions) as usize - ptr as usize + }, + 832usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseCUDAProviderOptions) + ) + ); + } + test_field_ReleaseCUDAProviderOptions(); + fn test_field_SessionOptionsAppendExecutionProvider_MIGraphX() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsAppendExecutionProvider_MIGraphX) as usize + - ptr as usize + }, + 836usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsAppendExecutionProvider_MIGraphX) + ) + ); + } + test_field_SessionOptionsAppendExecutionProvider_MIGraphX(); } #[repr(i32)] #[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] @@ -6533,132 +9274,222 @@ fn bindgen_test_layout_OrtCustomOp() { 4usize, concat!("Alignment of ", stringify!(OrtCustomOp)) ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).version as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(version) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateKernel as *const _ as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(CreateKernel) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetName as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetName) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetExecutionProviderType as *const _ as usize - }, - 12usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetExecutionProviderType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetInputType as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetInputType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetInputTypeCount as *const _ as usize }, - 20usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetInputTypeCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetOutputType as *const _ as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetOutputType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetOutputTypeCount as *const _ as usize }, - 28usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetOutputTypeCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).KernelCompute as *const _ as usize }, - 32usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(KernelCompute) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).KernelDestroy as *const _ as usize }, - 36usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(KernelDestroy) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetInputCharacteristic as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetInputCharacteristic) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetOutputCharacteristic as *const _ as usize - }, - 44usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetOutputCharacteristic) - ) - ); + fn test_field_version() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).version) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(version) + ) + ); + } + test_field_version(); + fn test_field_CreateKernel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateKernel) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(CreateKernel) + ) + ); + } + test_field_CreateKernel(); + fn test_field_GetName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetName) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetName) + ) + ); + } + test_field_GetName(); + fn test_field_GetExecutionProviderType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetExecutionProviderType) as usize - ptr as usize + }, + 12usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetExecutionProviderType) + ) + ); + } + test_field_GetExecutionProviderType(); + fn test_field_GetInputType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetInputType) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetInputType) + ) + ); + } + test_field_GetInputType(); + fn test_field_GetInputTypeCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetInputTypeCount) as usize - ptr as usize + }, + 20usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetInputTypeCount) + ) + ); + } + test_field_GetInputTypeCount(); + fn test_field_GetOutputType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetOutputType) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetOutputType) + ) + ); + } + test_field_GetOutputType(); + fn test_field_GetOutputTypeCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetOutputTypeCount) as usize - ptr as usize + }, + 28usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetOutputTypeCount) + ) + ); + } + test_field_GetOutputTypeCount(); + fn test_field_KernelCompute() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelCompute) as usize - ptr as usize + }, + 32usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(KernelCompute) + ) + ); + } + test_field_KernelCompute(); + fn test_field_KernelDestroy() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelDestroy) as usize - ptr as usize + }, + 36usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(KernelDestroy) + ) + ); + } + test_field_KernelDestroy(); + fn test_field_GetInputCharacteristic() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetInputCharacteristic) as usize - ptr as usize + }, + 40usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetInputCharacteristic) + ) + ); + } + test_field_GetInputCharacteristic(); + fn test_field_GetOutputCharacteristic() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetOutputCharacteristic) as usize - ptr as usize + }, + 44usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetOutputCharacteristic) + ) + ); + } + test_field_GetOutputCharacteristic(); +} +extern "stdcall" { + pub fn OrtSessionOptionsAppendExecutionProvider_CUDA( + options: *mut OrtSessionOptions, + device_id: ::std::os::raw::c_int, + ) -> OrtStatusPtr; +} +extern "stdcall" { + pub fn OrtSessionOptionsAppendExecutionProvider_MIGraphX( + options: *mut OrtSessionOptions, + device_id: ::std::os::raw::c_int, + ) -> OrtStatusPtr; } #[repr(C)] #[derive(Debug, Copy, Clone)] diff --git a/onnxruntime-sys/src/generated/windows/x86_64/bindings.rs b/onnxruntime-sys/src/generated/windows/x86_64/bindings.rs index 000bf5f4..e54e5a10 100644 --- a/onnxruntime-sys/src/generated/windows/x86_64/bindings.rs +++ b/onnxruntime-sys/src/generated/windows/x86_64/bindings.rs @@ -1,4 +1,4 @@ -/* automatically generated by rust-bindgen 0.59.1 */ +/* automatically generated by rust-bindgen 0.60.1 */ pub const _VCRT_COMPILER_PREPROCESSOR: u32 = 1; pub const _SAL_VERSION: u32 = 20; @@ -165,7 +165,7 @@ pub const ETIMEDOUT: u32 = 138; pub const ETXTBSY: u32 = 139; pub const EWOULDBLOCK: u32 = 140; pub const _NLSCMPERROR: u32 = 2147483647; -pub const ORT_API_VERSION: u32 = 8; +pub const ORT_API_VERSION: u32 = 11; pub const __SAL_H_FULL_VER: u32 = 140050727; pub const __SPECSTRINGS_STRICT_LEVEL: u32 = 1; pub const __drv_typeConst: u32 = 0; @@ -230,44 +230,57 @@ fn bindgen_test_layout___crt_locale_data_public() { 8usize, concat!("Alignment of ", stringify!(__crt_locale_data_public)) ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__crt_locale_data_public>()))._locale_pctype as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__crt_locale_data_public), - "::", - stringify!(_locale_pctype) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__crt_locale_data_public>()))._locale_mb_cur_max as *const _ - as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__crt_locale_data_public), - "::", - stringify!(_locale_mb_cur_max) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::<__crt_locale_data_public>()))._locale_lc_codepage as *const _ - as usize - }, - 12usize, - concat!( - "Offset of field: ", - stringify!(__crt_locale_data_public), - "::", - stringify!(_locale_lc_codepage) - ) - ); + fn test_field__locale_pctype() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__crt_locale_data_public>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr)._locale_pctype) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__crt_locale_data_public), + "::", + stringify!(_locale_pctype) + ) + ); + } + test_field__locale_pctype(); + fn test_field__locale_mb_cur_max() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__crt_locale_data_public>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr)._locale_mb_cur_max) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__crt_locale_data_public), + "::", + stringify!(_locale_mb_cur_max) + ) + ); + } + test_field__locale_mb_cur_max(); + fn test_field__locale_lc_codepage() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__crt_locale_data_public>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr)._locale_lc_codepage) as usize - ptr as usize + }, + 12usize, + concat!( + "Offset of field: ", + stringify!(__crt_locale_data_public), + "::", + stringify!(_locale_lc_codepage) + ) + ); + } + test_field__locale_lc_codepage(); } #[repr(C)] #[derive(Debug, Copy, Clone)] @@ -287,26 +300,40 @@ fn bindgen_test_layout___crt_locale_pointers() { 8usize, concat!("Alignment of ", stringify!(__crt_locale_pointers)) ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__crt_locale_pointers>())).locinfo as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(__crt_locale_pointers), - "::", - stringify!(locinfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<__crt_locale_pointers>())).mbcinfo as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(__crt_locale_pointers), - "::", - stringify!(mbcinfo) - ) - ); + fn test_field_locinfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__crt_locale_pointers>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).locinfo) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(__crt_locale_pointers), + "::", + stringify!(locinfo) + ) + ); + } + test_field_locinfo(); + fn test_field_mbcinfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<__crt_locale_pointers>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).mbcinfo) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(__crt_locale_pointers), + "::", + stringify!(mbcinfo) + ) + ); + } + test_field_mbcinfo(); } pub type _locale_t = *mut __crt_locale_pointers; #[repr(C)] @@ -328,36 +355,57 @@ fn bindgen_test_layout__Mbstatet() { 4usize, concat!("Alignment of ", stringify!(_Mbstatet)) ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_Mbstatet>()))._Wchar as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_Mbstatet), - "::", - stringify!(_Wchar) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_Mbstatet>()))._Byte as *const _ as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(_Mbstatet), - "::", - stringify!(_Byte) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_Mbstatet>()))._State as *const _ as usize }, - 6usize, - concat!( - "Offset of field: ", - stringify!(_Mbstatet), - "::", - stringify!(_State) - ) - ); + fn test_field__Wchar() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<_Mbstatet>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr)._Wchar) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(_Mbstatet), + "::", + stringify!(_Wchar) + ) + ); + } + test_field__Wchar(); + fn test_field__Byte() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<_Mbstatet>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr)._Byte) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(_Mbstatet), + "::", + stringify!(_Byte) + ) + ); + } + test_field__Byte(); + fn test_field__State() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<_Mbstatet>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr)._State) as usize - ptr as usize + }, + 6usize, + concat!( + "Offset of field: ", + stringify!(_Mbstatet), + "::", + stringify!(_State) + ) + ); + } + test_field__State(); } pub type mbstate_t = _Mbstatet; pub type time_t = __time64_t; @@ -476,7 +524,21 @@ extern "C" { _Alignment: usize, ) -> *mut ::std::os::raw::c_void; } -pub type max_align_t = f64; +extern "C" { + pub fn _errno() -> *mut ::std::os::raw::c_int; +} +extern "C" { + pub fn _set_errno(_Value: ::std::os::raw::c_int) -> errno_t; +} +extern "C" { + pub fn _get_errno(_Value: *mut ::std::os::raw::c_int) -> errno_t; +} +extern "C" { + pub fn __threadid() -> ::std::os::raw::c_ulong; +} +extern "C" { + pub fn __threadhandle() -> usize; +} pub type _CoreCrtSecureSearchSortCompareFunction = ::std::option::Option< unsafe extern "C" fn( arg1: *mut ::std::os::raw::c_void, @@ -975,15 +1037,6 @@ extern "C" { extern "C" { pub fn _set_error_mode(_Mode: ::std::os::raw::c_int) -> ::std::os::raw::c_int; } -extern "C" { - pub fn _errno() -> *mut ::std::os::raw::c_int; -} -extern "C" { - pub fn _set_errno(_Value: ::std::os::raw::c_int) -> errno_t; -} -extern "C" { - pub fn _get_errno(_Value: *mut ::std::os::raw::c_int) -> errno_t; -} extern "C" { pub fn __doserrno() -> *mut ::std::os::raw::c_ulong; } @@ -1041,26 +1094,40 @@ fn bindgen_test_layout__div_t() { 4usize, concat!("Alignment of ", stringify!(_div_t)) ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_div_t>())).quot as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_div_t), - "::", - stringify!(quot) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_div_t>())).rem as *const _ as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(_div_t), - "::", - stringify!(rem) - ) - ); + fn test_field_quot() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<_div_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).quot) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(_div_t), + "::", + stringify!(quot) + ) + ); + } + test_field_quot(); + fn test_field_rem() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<_div_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).rem) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(_div_t), + "::", + stringify!(rem) + ) + ); + } + test_field_rem(); } pub type div_t = _div_t; #[repr(C)] @@ -1081,26 +1148,40 @@ fn bindgen_test_layout__ldiv_t() { 4usize, concat!("Alignment of ", stringify!(_ldiv_t)) ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_ldiv_t>())).quot as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_ldiv_t), - "::", - stringify!(quot) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_ldiv_t>())).rem as *const _ as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(_ldiv_t), - "::", - stringify!(rem) - ) - ); + fn test_field_quot() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<_ldiv_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).quot) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(_ldiv_t), + "::", + stringify!(quot) + ) + ); + } + test_field_quot(); + fn test_field_rem() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<_ldiv_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).rem) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(_ldiv_t), + "::", + stringify!(rem) + ) + ); + } + test_field_rem(); } pub type ldiv_t = _ldiv_t; #[repr(C)] @@ -1121,26 +1202,40 @@ fn bindgen_test_layout__lldiv_t() { 8usize, concat!("Alignment of ", stringify!(_lldiv_t)) ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_lldiv_t>())).quot as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_lldiv_t), - "::", - stringify!(quot) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_lldiv_t>())).rem as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(_lldiv_t), - "::", - stringify!(rem) - ) - ); + fn test_field_quot() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<_lldiv_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).quot) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(_lldiv_t), + "::", + stringify!(quot) + ) + ); + } + test_field_quot(); + fn test_field_rem() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<_lldiv_t>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).rem) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(_lldiv_t), + "::", + stringify!(rem) + ) + ); + } + test_field_rem(); } pub type lldiv_t = _lldiv_t; extern "C" { @@ -1236,16 +1331,23 @@ fn bindgen_test_layout__LDOUBLE() { 1usize, concat!("Alignment of ", stringify!(_LDOUBLE)) ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_LDOUBLE>())).ld as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_LDOUBLE), - "::", - stringify!(ld) - ) - ); + fn test_field_ld() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<_LDOUBLE>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ld) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(_LDOUBLE), + "::", + stringify!(ld) + ) + ); + } + test_field_ld(); } #[repr(C)] #[derive(Debug, Copy, Clone)] @@ -1264,16 +1366,23 @@ fn bindgen_test_layout__CRT_DOUBLE() { 8usize, concat!("Alignment of ", stringify!(_CRT_DOUBLE)) ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_CRT_DOUBLE>())).x as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_CRT_DOUBLE), - "::", - stringify!(x) - ) - ); + fn test_field_x() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<_CRT_DOUBLE>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).x) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(_CRT_DOUBLE), + "::", + stringify!(x) + ) + ); + } + test_field_x(); } #[repr(C)] #[derive(Debug, Copy, Clone)] @@ -1292,16 +1401,23 @@ fn bindgen_test_layout__CRT_FLOAT() { 4usize, concat!("Alignment of ", stringify!(_CRT_FLOAT)) ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_CRT_FLOAT>())).f as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_CRT_FLOAT), - "::", - stringify!(f) - ) - ); + fn test_field_f() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<_CRT_FLOAT>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).f) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(_CRT_FLOAT), + "::", + stringify!(f) + ) + ); + } + test_field_f(); } #[repr(C)] #[derive(Debug, Copy, Clone)] @@ -1320,16 +1436,23 @@ fn bindgen_test_layout__LONGDOUBLE() { 8usize, concat!("Alignment of ", stringify!(_LONGDOUBLE)) ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_LONGDOUBLE>())).x as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_LONGDOUBLE), - "::", - stringify!(x) - ) - ); + fn test_field_x() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<_LONGDOUBLE>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).x) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(_LONGDOUBLE), + "::", + stringify!(x) + ) + ); + } + test_field_x(); } #[repr(C)] #[derive(Debug, Copy, Clone)] @@ -1348,16 +1471,23 @@ fn bindgen_test_layout__LDBL12() { 1usize, concat!("Alignment of ", stringify!(_LDBL12)) ); - assert_eq!( - unsafe { &(*(::std::ptr::null::<_LDBL12>())).ld12 as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(_LDBL12), - "::", - stringify!(ld12) - ) - ); + fn test_field_ld12() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::<_LDBL12>::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ld12) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(_LDBL12), + "::", + stringify!(ld12) + ) + ); + } + test_field_ld12(); } extern "C" { pub fn atof(_String: *const ::std::os::raw::c_char) -> f64; @@ -2759,6 +2889,8 @@ extern "C" { pub fn strupr(_String: *mut ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char; } #[repr(i32)] +#[doc = " Copied from TensorProto::DataType"] +#[doc = " Currently, Ort doesn't support complex64, complex128"] #[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] pub enum ONNXTensorElementDataType { ONNX_TENSOR_ELEMENT_DATA_TYPE_UNDEFINED = 0, @@ -2788,14 +2920,39 @@ pub enum ONNXType { ONNX_TYPE_MAP = 3, ONNX_TYPE_OPAQUE = 4, ONNX_TYPE_SPARSETENSOR = 5, + ONNX_TYPE_OPTIONAL = 6, +} +#[repr(i32)] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum OrtSparseFormat { + ORT_SPARSE_UNDEFINED = 0, + ORT_SPARSE_COO = 1, + ORT_SPARSE_CSRC = 2, + ORT_SPARSE_BLOCK_SPARSE = 4, +} +#[repr(i32)] +#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] +pub enum OrtSparseIndicesFormat { + ORT_SPARSE_COO_INDICES = 0, + ORT_SPARSE_CSR_INNER_INDICES = 1, + ORT_SPARSE_CSR_OUTER_INDICES = 2, + ORT_SPARSE_BLOCK_SPARSE_INDICES = 3, } #[repr(i32)] +#[doc = " \\brief Logging severity levels"] +#[doc = ""] +#[doc = " In typical API usage, specifying a logging severity level specifies the minimum severity of log messages to show."] #[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] pub enum OrtLoggingLevel { + #[doc = "< Verbose informational messages (least severe)."] ORT_LOGGING_LEVEL_VERBOSE = 0, + #[doc = "< Informational messages."] ORT_LOGGING_LEVEL_INFO = 1, + #[doc = "< Warning messages."] ORT_LOGGING_LEVEL_WARNING = 2, + #[doc = "< Error messages."] ORT_LOGGING_LEVEL_ERROR = 3, + #[doc = "< Fatal error messages (most severe)."] ORT_LOGGING_LEVEL_FATAL = 4, } #[repr(i32)] @@ -2904,17 +3061,36 @@ pub struct OrtArenaCfg { pub struct OrtPrepackedWeightsContainer { _unused: [u8; 0], } +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtTensorRTProviderOptionsV2 { + _unused: [u8; 0], +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtCUDAProviderOptionsV2 { + _unused: [u8; 0], +} pub type OrtStatusPtr = *mut OrtStatus; +#[doc = " \\brief Memory allocation interface"] +#[doc = ""] +#[doc = " Structure of function pointers that defines a memory allocator. This can be created and filled in by the user for custom allocators."] +#[doc = ""] +#[doc = " When an allocator is passed to any function, be sure that the allocator object is not destroyed until the last allocated object using it is freed."] #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct OrtAllocator { + #[doc = "< Must be initialized to ORT_API_VERSION"] pub version: u32, + #[doc = "< Returns a pointer to an allocated block of `size` bytes"] pub Alloc: ::std::option::Option< unsafe extern "C" fn(this_: *mut OrtAllocator, size: usize) -> *mut ::std::os::raw::c_void, >, + #[doc = "< Free a block of memory previously allocated with OrtAllocator::Alloc"] pub Free: ::std::option::Option< unsafe extern "C" fn(this_: *mut OrtAllocator, p: *mut ::std::os::raw::c_void), >, + #[doc = "< Return a pointer to an ::OrtMemoryInfo that describes this allocator"] pub Info: ::std::option::Option< unsafe extern "C" fn(this_: *const OrtAllocator) -> *const OrtMemoryInfo, >, @@ -2931,46 +3107,74 @@ fn bindgen_test_layout_OrtAllocator() { 8usize, concat!("Alignment of ", stringify!(OrtAllocator)) ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).version as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtAllocator), - "::", - stringify!(version) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).Alloc as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtAllocator), - "::", - stringify!(Alloc) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).Free as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(OrtAllocator), - "::", - stringify!(Free) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).Info as *const _ as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(OrtAllocator), - "::", - stringify!(Info) - ) - ); + fn test_field_version() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).version) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtAllocator), + "::", + stringify!(version) + ) + ); + } + test_field_version(); + fn test_field_Alloc() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).Alloc) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtAllocator), + "::", + stringify!(Alloc) + ) + ); + } + test_field_Alloc(); + fn test_field_Free() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).Free) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(OrtAllocator), + "::", + stringify!(Free) + ) + ); + } + test_field_Free(); + fn test_field_Info() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).Info) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(OrtAllocator), + "::", + stringify!(Info) + ) + ); + } + test_field_Info(); } pub type OrtLoggingFunction = ::std::option::Option< unsafe extern "C" fn( @@ -2983,6 +3187,10 @@ pub type OrtLoggingFunction = ::std::option::Option< ), >; #[repr(i32)] +#[doc = " \\brief Graph optimization level"] +#[doc = ""] +#[doc = " Refer to https://www.onnxruntime.ai/docs/resources/graph-optimizations.html"] +#[doc = " for an in-depth understanding of Graph Optimizations"] #[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] pub enum GraphOptimizationLevel { ORT_DISABLE_ALL = 0, @@ -2997,6 +3205,8 @@ pub enum ExecutionMode { ORT_PARALLEL = 1, } #[repr(i32)] +#[doc = " \\brief Language projection identifiers"] +#[doc = " /see OrtApi::SetLanguageProjection"] #[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] pub enum OrtLanguageProjection { ORT_PROJECTION_C = 0, @@ -3020,7 +3230,7 @@ pub struct OrtKernelContext { #[repr(i32)] #[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] pub enum OrtAllocatorType { - Invalid = -1, + OrtInvalidAllocator = -1, OrtDeviceAllocator = 0, OrtArenaAllocator = 1, } @@ -3028,34 +3238,61 @@ impl OrtMemType { pub const OrtMemTypeCPU: OrtMemType = OrtMemType::OrtMemTypeCPUOutput; } #[repr(i32)] -#[doc = " memory types for allocator, exec provider specific types should be extended in each provider"] -#[doc = " Whenever this struct is updated, please also update the MakeKey function in onnxruntime/core/framework/execution_provider.cc"] +#[doc = " \\brief Memory types for allocated memory, execution provider specific types should be extended in each provider."] #[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] pub enum OrtMemType { + #[doc = "< Any CPU memory used by non-CPU execution provider"] OrtMemTypeCPUInput = -2, + #[doc = "< CPU accessible memory outputted by non-CPU execution provider, i.e. CUDA_PINNED"] OrtMemTypeCPUOutput = -1, + #[doc = "< The default allocator for execution provider"] OrtMemTypeDefault = 0, } #[repr(i32)] +#[doc = " \\brief Algorithm to use for cuDNN Convolution Op"] #[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] pub enum OrtCudnnConvAlgoSearch { - EXHAUSTIVE = 0, - HEURISTIC = 1, - DEFAULT = 2, + OrtCudnnConvAlgoSearchExhaustive = 0, + OrtCudnnConvAlgoSearchHeuristic = 1, + OrtCudnnConvAlgoSearchDefault = 2, } -#[doc = " "] -#[doc = " Options for the CUDA provider that are passed to SessionOptionsAppendExecutionProvider_CUDA"] -#[doc = " "] +#[doc = " \\brief CUDA Provider Options"] +#[doc = ""] +#[doc = " \\see OrtApi::SessionOptionsAppendExecutionProvider_CUDA"] #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct OrtCUDAProviderOptions { + #[doc = " \\brief CUDA device Id"] + #[doc = " Defaults to 0."] pub device_id: ::std::os::raw::c_int, + #[doc = " \\brief CUDA Convolution algorithm search configuration."] + #[doc = " See enum OrtCudnnConvAlgoSearch for more details."] + #[doc = " Defaults to OrtCudnnConvAlgoSearchExhaustive."] pub cudnn_conv_algo_search: OrtCudnnConvAlgoSearch, + #[doc = " \\brief CUDA memory limit (To use all possible memory pass in maximum size_t)"] + #[doc = " Defaults to SIZE_MAX."] + #[doc = " \\note If a ::OrtArenaCfg has been applied, it will override this field"] pub gpu_mem_limit: usize, + #[doc = " \\brief Strategy used to grow the memory arena"] + #[doc = " 0 = kNextPowerOfTwo
"] + #[doc = " 1 = kSameAsRequested
"] + #[doc = " Defaults to 0."] + #[doc = " \\note If a ::OrtArenaCfg has been applied, it will override this field"] pub arena_extend_strategy: ::std::os::raw::c_int, + #[doc = " \\brief Flag indicating if copying needs to take place on the same stream as the compute stream in the CUDA EP"] + #[doc = " 0 = Use separate streams for copying and compute."] + #[doc = " 1 = Use the same stream for copying and compute."] + #[doc = " Defaults to 1."] + #[doc = " WARNING: Setting this to 0 may result in data races for some models."] + #[doc = " Please see issue #4829 for more details."] pub do_copy_in_default_stream: ::std::os::raw::c_int, + #[doc = " \\brief Flag indicating if there is a user provided compute stream"] + #[doc = " Defaults to 0."] pub has_user_compute_stream: ::std::os::raw::c_int, + #[doc = " \\brief User provided compute stream."] + #[doc = " If provided, please set `has_user_compute_stream` to 1."] pub user_compute_stream: *mut ::std::os::raw::c_void, + #[doc = " \\brief CUDA memory arena configuration parameters"] pub default_memory_arena_cfg: *mut OrtArenaCfg, } #[test] @@ -3070,125 +3307,186 @@ fn bindgen_test_layout_OrtCUDAProviderOptions() { 8usize, concat!("Alignment of ", stringify!(OrtCUDAProviderOptions)) ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).device_id as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(device_id) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).cudnn_conv_algo_search as *const _ - as usize - }, - 4usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(cudnn_conv_algo_search) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).gpu_mem_limit as *const _ as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(gpu_mem_limit) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).arena_extend_strategy as *const _ - as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(arena_extend_strategy) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).do_copy_in_default_stream as *const _ - as usize - }, - 20usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(do_copy_in_default_stream) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).has_user_compute_stream as *const _ - as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(has_user_compute_stream) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).user_compute_stream as *const _ - as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(user_compute_stream) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).default_memory_arena_cfg as *const _ - as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(OrtCUDAProviderOptions), - "::", - stringify!(default_memory_arena_cfg) - ) - ); -} -#[doc = " "] -#[doc = " Options for the ROCM provider that are passed to SessionOptionsAppendExecutionProvider_ROCM"] -#[doc = " "] + fn test_field_device_id() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).device_id) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(device_id) + ) + ); + } + test_field_device_id(); + fn test_field_cudnn_conv_algo_search() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).cudnn_conv_algo_search) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(cudnn_conv_algo_search) + ) + ); + } + test_field_cudnn_conv_algo_search(); + fn test_field_gpu_mem_limit() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).gpu_mem_limit) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(gpu_mem_limit) + ) + ); + } + test_field_gpu_mem_limit(); + fn test_field_arena_extend_strategy() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).arena_extend_strategy) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(arena_extend_strategy) + ) + ); + } + test_field_arena_extend_strategy(); + fn test_field_do_copy_in_default_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).do_copy_in_default_stream) as usize - ptr as usize + }, + 20usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(do_copy_in_default_stream) + ) + ); + } + test_field_do_copy_in_default_stream(); + fn test_field_has_user_compute_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).has_user_compute_stream) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(has_user_compute_stream) + ) + ); + } + test_field_has_user_compute_stream(); + fn test_field_user_compute_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).user_compute_stream) as usize - ptr as usize + }, + 32usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(user_compute_stream) + ) + ); + } + test_field_user_compute_stream(); + fn test_field_default_memory_arena_cfg() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).default_memory_arena_cfg) as usize - ptr as usize + }, + 40usize, + concat!( + "Offset of field: ", + stringify!(OrtCUDAProviderOptions), + "::", + stringify!(default_memory_arena_cfg) + ) + ); + } + test_field_default_memory_arena_cfg(); +} +#[doc = " \\brief ROCM Provider Options"] +#[doc = ""] +#[doc = " \\see OrtApi::SessionOptionsAppendExecutionProvider_ROCM"] #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct OrtROCMProviderOptions { + #[doc = " \\brief ROCM device Id"] + #[doc = " Defaults to 0."] pub device_id: ::std::os::raw::c_int, + #[doc = " \\brief ROCM MIOpen Convolution algorithm exaustive search option."] + #[doc = " Defaults to 0 (false)."] pub miopen_conv_exhaustive_search: ::std::os::raw::c_int, + #[doc = " \\brief ROCM memory limit (To use all possible memory pass in maximum size_t)"] + #[doc = " Defaults to SIZE_MAX."] + #[doc = " \\note If a ::OrtArenaCfg has been applied, it will override this field"] pub gpu_mem_limit: usize, + #[doc = " \\brief Strategy used to grow the memory arena"] + #[doc = " 0 = kNextPowerOfTwo
"] + #[doc = " 1 = kSameAsRequested
"] + #[doc = " Defaults to 0."] + #[doc = " \\note If a ::OrtArenaCfg has been applied, it will override this field"] pub arena_extend_strategy: ::std::os::raw::c_int, + #[doc = " \\brief Flag indicating if copying needs to take place on the same stream as the compute stream in the ROCM EP"] + #[doc = " 0 = Use separate streams for copying and compute."] + #[doc = " 1 = Use the same stream for copying and compute."] + #[doc = " Defaults to 1."] + #[doc = " WARNING: Setting this to 0 may result in data races for some models."] + #[doc = " Please see issue #4829 for more details."] + pub do_copy_in_default_stream: ::std::os::raw::c_int, + #[doc = " \\brief Flag indicating if there is a user provided compute stream"] + #[doc = " Defaults to 0."] + pub has_user_compute_stream: ::std::os::raw::c_int, + #[doc = " \\brief User provided compute stream."] + #[doc = " If provided, please set `has_user_compute_stream` to 1."] + pub user_compute_stream: *mut ::std::os::raw::c_void, + #[doc = " \\brief ROCM memory arena configuration parameters"] + pub default_memory_arena_cfg: *mut OrtArenaCfg, } #[test] fn bindgen_test_layout_OrtROCMProviderOptions() { assert_eq!( ::std::mem::size_of::(), - 24usize, + 48usize, concat!("Size of: ", stringify!(OrtROCMProviderOptions)) ); assert_eq!( @@ -3196,63 +3494,150 @@ fn bindgen_test_layout_OrtROCMProviderOptions() { 8usize, concat!("Alignment of ", stringify!(OrtROCMProviderOptions)) ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).device_id as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtROCMProviderOptions), - "::", - stringify!(device_id) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).miopen_conv_exhaustive_search - as *const _ as usize - }, - 4usize, - concat!( - "Offset of field: ", - stringify!(OrtROCMProviderOptions), - "::", - stringify!(miopen_conv_exhaustive_search) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).gpu_mem_limit as *const _ as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtROCMProviderOptions), - "::", - stringify!(gpu_mem_limit) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).arena_extend_strategy as *const _ - as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(OrtROCMProviderOptions), - "::", - stringify!(arena_extend_strategy) - ) - ); -} -#[doc = " "] -#[doc = " Options for the TensorRT provider that are passed to SessionOptionsAppendExecutionProvider_TensorRT"] -#[doc = " "] + fn test_field_device_id() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).device_id) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(device_id) + ) + ); + } + test_field_device_id(); + fn test_field_miopen_conv_exhaustive_search() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).miopen_conv_exhaustive_search) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(miopen_conv_exhaustive_search) + ) + ); + } + test_field_miopen_conv_exhaustive_search(); + fn test_field_gpu_mem_limit() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).gpu_mem_limit) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(gpu_mem_limit) + ) + ); + } + test_field_gpu_mem_limit(); + fn test_field_arena_extend_strategy() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).arena_extend_strategy) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(arena_extend_strategy) + ) + ); + } + test_field_arena_extend_strategy(); + fn test_field_do_copy_in_default_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).do_copy_in_default_stream) as usize - ptr as usize + }, + 20usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(do_copy_in_default_stream) + ) + ); + } + test_field_do_copy_in_default_stream(); + fn test_field_has_user_compute_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).has_user_compute_stream) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(has_user_compute_stream) + ) + ); + } + test_field_has_user_compute_stream(); + fn test_field_user_compute_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).user_compute_stream) as usize - ptr as usize + }, + 32usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(user_compute_stream) + ) + ); + } + test_field_user_compute_stream(); + fn test_field_default_memory_arena_cfg() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).default_memory_arena_cfg) as usize - ptr as usize + }, + 40usize, + concat!( + "Offset of field: ", + stringify!(OrtROCMProviderOptions), + "::", + stringify!(default_memory_arena_cfg) + ) + ); + } + test_field_default_memory_arena_cfg(); +} +#[doc = " \\brief TensorRT Provider Options"] +#[doc = ""] +#[doc = " \\see OrtApi::SessionOptionsAppendExecutionProvider_TensorRT"] #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct OrtTensorRTProviderOptions { + #[doc = "< CUDA device id (0 = default device)"] pub device_id: ::std::os::raw::c_int, pub has_user_compute_stream: ::std::os::raw::c_int, pub user_compute_stream: *mut ::std::os::raw::c_void, @@ -3284,257 +3669,414 @@ fn bindgen_test_layout_OrtTensorRTProviderOptions() { 8usize, concat!("Alignment of ", stringify!(OrtTensorRTProviderOptions)) ); + fn test_field_device_id() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).device_id) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(device_id) + ) + ); + } + test_field_device_id(); + fn test_field_has_user_compute_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).has_user_compute_stream) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(has_user_compute_stream) + ) + ); + } + test_field_has_user_compute_stream(); + fn test_field_user_compute_stream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).user_compute_stream) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(user_compute_stream) + ) + ); + } + test_field_user_compute_stream(); + fn test_field_trt_max_partition_iterations() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_max_partition_iterations) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_max_partition_iterations) + ) + ); + } + test_field_trt_max_partition_iterations(); + fn test_field_trt_min_subgraph_size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_min_subgraph_size) as usize - ptr as usize + }, + 20usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_min_subgraph_size) + ) + ); + } + test_field_trt_min_subgraph_size(); + fn test_field_trt_max_workspace_size() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_max_workspace_size) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_max_workspace_size) + ) + ); + } + test_field_trt_max_workspace_size(); + fn test_field_trt_fp16_enable() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_fp16_enable) as usize - ptr as usize + }, + 32usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_fp16_enable) + ) + ); + } + test_field_trt_fp16_enable(); + fn test_field_trt_int8_enable() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_int8_enable) as usize - ptr as usize + }, + 36usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_int8_enable) + ) + ); + } + test_field_trt_int8_enable(); + fn test_field_trt_int8_calibration_table_name() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_int8_calibration_table_name) as usize - ptr as usize + }, + 40usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_int8_calibration_table_name) + ) + ); + } + test_field_trt_int8_calibration_table_name(); + fn test_field_trt_int8_use_native_calibration_table() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_int8_use_native_calibration_table) as usize + - ptr as usize + }, + 48usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_int8_use_native_calibration_table) + ) + ); + } + test_field_trt_int8_use_native_calibration_table(); + fn test_field_trt_dla_enable() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_dla_enable) as usize - ptr as usize + }, + 52usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_dla_enable) + ) + ); + } + test_field_trt_dla_enable(); + fn test_field_trt_dla_core() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_dla_core) as usize - ptr as usize + }, + 56usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_dla_core) + ) + ); + } + test_field_trt_dla_core(); + fn test_field_trt_dump_subgraphs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_dump_subgraphs) as usize - ptr as usize + }, + 60usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_dump_subgraphs) + ) + ); + } + test_field_trt_dump_subgraphs(); + fn test_field_trt_engine_cache_enable() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_engine_cache_enable) as usize - ptr as usize + }, + 64usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_engine_cache_enable) + ) + ); + } + test_field_trt_engine_cache_enable(); + fn test_field_trt_engine_cache_path() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_engine_cache_path) as usize - ptr as usize + }, + 72usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_engine_cache_path) + ) + ); + } + test_field_trt_engine_cache_path(); + fn test_field_trt_engine_decryption_enable() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_engine_decryption_enable) as usize - ptr as usize + }, + 80usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_engine_decryption_enable) + ) + ); + } + test_field_trt_engine_decryption_enable(); + fn test_field_trt_engine_decryption_lib_path() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_engine_decryption_lib_path) as usize - ptr as usize + }, + 88usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_engine_decryption_lib_path) + ) + ); + } + test_field_trt_engine_decryption_lib_path(); + fn test_field_trt_force_sequential_engine_build() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).trt_force_sequential_engine_build) as usize + - ptr as usize + }, + 96usize, + concat!( + "Offset of field: ", + stringify!(OrtTensorRTProviderOptions), + "::", + stringify!(trt_force_sequential_engine_build) + ) + ); + } + test_field_trt_force_sequential_engine_build(); +} +#[doc = " \\brief MIGraphX Provider Options"] +#[doc = ""] +#[doc = " \\see OrtApi::SessionOptionsAppendExecutionProvider_MIGraphX"] +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtMIGraphXProviderOptions { + pub device_id: ::std::os::raw::c_int, + pub migraphx_fp16_enable: ::std::os::raw::c_int, + pub migraphx_int8_enable: ::std::os::raw::c_int, +} +#[test] +fn bindgen_test_layout_OrtMIGraphXProviderOptions() { assert_eq!( - unsafe { - &(*(::std::ptr::null::())).device_id as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(device_id) - ) + ::std::mem::size_of::(), + 12usize, + concat!("Size of: ", stringify!(OrtMIGraphXProviderOptions)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::())).has_user_compute_stream - as *const _ as usize - }, + ::std::mem::align_of::(), 4usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(has_user_compute_stream) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).user_compute_stream as *const _ - as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(user_compute_stream) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_max_partition_iterations - as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_max_partition_iterations) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_min_subgraph_size as *const _ - as usize - }, - 20usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_min_subgraph_size) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_max_workspace_size - as *const _ as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_max_workspace_size) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_fp16_enable as *const _ - as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_fp16_enable) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_int8_enable as *const _ - as usize - }, - 36usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_int8_enable) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_int8_calibration_table_name - as *const _ as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_int8_calibration_table_name) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())) - .trt_int8_use_native_calibration_table as *const _ as usize - }, - 48usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_int8_use_native_calibration_table) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_dla_enable as *const _ - as usize - }, - 52usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_dla_enable) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_dla_core as *const _ as usize - }, - 56usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_dla_core) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_dump_subgraphs as *const _ - as usize - }, - 60usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_dump_subgraphs) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_engine_cache_enable - as *const _ as usize - }, - 64usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_engine_cache_enable) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_engine_cache_path as *const _ - as usize - }, - 72usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_engine_cache_path) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_engine_decryption_enable - as *const _ as usize - }, - 80usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_engine_decryption_enable) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_engine_decryption_lib_path - as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_engine_decryption_lib_path) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).trt_force_sequential_engine_build - as *const _ as usize - }, - 96usize, - concat!( - "Offset of field: ", - stringify!(OrtTensorRTProviderOptions), - "::", - stringify!(trt_force_sequential_engine_build) - ) - ); -} -#[doc = " "] -#[doc = " Options for the OpenVINO provider that are passed to SessionOptionsAppendExecutionProvider_OpenVINO"] -#[doc = " "] + concat!("Alignment of ", stringify!(OrtMIGraphXProviderOptions)) + ); + fn test_field_device_id() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).device_id) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtMIGraphXProviderOptions), + "::", + stringify!(device_id) + ) + ); + } + test_field_device_id(); + fn test_field_migraphx_fp16_enable() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).migraphx_fp16_enable) as usize - ptr as usize + }, + 4usize, + concat!( + "Offset of field: ", + stringify!(OrtMIGraphXProviderOptions), + "::", + stringify!(migraphx_fp16_enable) + ) + ); + } + test_field_migraphx_fp16_enable(); + fn test_field_migraphx_int8_enable() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).migraphx_int8_enable) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtMIGraphXProviderOptions), + "::", + stringify!(migraphx_int8_enable) + ) + ); + } + test_field_migraphx_int8_enable(); +} +#[doc = " \\brief OpenVINO Provider Options"] +#[doc = ""] +#[doc = " \\see OrtApi::SessionOptionsAppendExecutionProvider_OpenVINO"] #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct OrtOpenVINOProviderOptions { + #[doc = " \\brief Device type string"] + #[doc = ""] + #[doc = " Valid settings are one of: \"CPU_FP32\", \"GPU_FP32\", \"GPU_FP16\", \"MYRIAD_FP16\", \"VAD-M_FP16\" or \"VAD-F_FP32\""] pub device_type: *const ::std::os::raw::c_char, + #[doc = "< 0 = disabled, nonzero = enabled"] pub enable_vpu_fast_compile: ::std::os::raw::c_uchar, pub device_id: *const ::std::os::raw::c_char, + #[doc = "< 0 = Use default number of threads"] pub num_of_threads: usize, + #[doc = "< 0 = disabled, nonzero = enabled"] pub use_compiled_network: ::std::os::raw::c_uchar, pub blob_dump_path: *const ::std::os::raw::c_char, + pub context: *mut ::std::os::raw::c_void, } #[test] fn bindgen_test_layout_OrtOpenVINOProviderOptions() { assert_eq!( ::std::mem::size_of::(), - 48usize, + 56usize, concat!("Size of: ", stringify!(OrtOpenVINOProviderOptions)) ); assert_eq!( @@ -3542,87 +4084,139 @@ fn bindgen_test_layout_OrtOpenVINOProviderOptions() { 8usize, concat!("Alignment of ", stringify!(OrtOpenVINOProviderOptions)) ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).device_type as *const _ as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtOpenVINOProviderOptions), - "::", - stringify!(device_type) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).enable_vpu_fast_compile - as *const _ as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtOpenVINOProviderOptions), - "::", - stringify!(enable_vpu_fast_compile) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).device_id as *const _ as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(OrtOpenVINOProviderOptions), - "::", - stringify!(device_id) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).num_of_threads as *const _ - as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(OrtOpenVINOProviderOptions), - "::", - stringify!(num_of_threads) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).use_compiled_network as *const _ - as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(OrtOpenVINOProviderOptions), - "::", - stringify!(use_compiled_network) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).blob_dump_path as *const _ - as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(OrtOpenVINOProviderOptions), - "::", - stringify!(blob_dump_path) - ) - ); -} + fn test_field_device_type() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).device_type) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtOpenVINOProviderOptions), + "::", + stringify!(device_type) + ) + ); + } + test_field_device_type(); + fn test_field_enable_vpu_fast_compile() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).enable_vpu_fast_compile) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtOpenVINOProviderOptions), + "::", + stringify!(enable_vpu_fast_compile) + ) + ); + } + test_field_enable_vpu_fast_compile(); + fn test_field_device_id() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).device_id) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(OrtOpenVINOProviderOptions), + "::", + stringify!(device_id) + ) + ); + } + test_field_device_id(); + fn test_field_num_of_threads() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).num_of_threads) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(OrtOpenVINOProviderOptions), + "::", + stringify!(num_of_threads) + ) + ); + } + test_field_num_of_threads(); + fn test_field_use_compiled_network() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).use_compiled_network) as usize - ptr as usize + }, + 32usize, + concat!( + "Offset of field: ", + stringify!(OrtOpenVINOProviderOptions), + "::", + stringify!(use_compiled_network) + ) + ); + } + test_field_use_compiled_network(); + fn test_field_blob_dump_path() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).blob_dump_path) as usize - ptr as usize + }, + 40usize, + concat!( + "Offset of field: ", + stringify!(OrtOpenVINOProviderOptions), + "::", + stringify!(blob_dump_path) + ) + ); + } + test_field_blob_dump_path(); + fn test_field_context() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).context) as usize - ptr as usize + }, + 48usize, + concat!( + "Offset of field: ", + stringify!(OrtOpenVINOProviderOptions), + "::", + stringify!(context) + ) + ); + } + test_field_context(); +} +#[doc = " \\brief The helper interface to get the right version of OrtApi"] +#[doc = ""] +#[doc = " Get a pointer to this structure through ::OrtGetApiBase"] #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct OrtApiBase { + #[doc = " \\brief Get a pointer to the requested version of the ::OrtApi"] + #[doc = ""] + #[doc = " \\param[in] version Must be ::ORT_API_VERSION"] + #[doc = " \\return The ::OrtApi for the version requested, nullptr will be returned if this version is unsupported, for example when using a runtime"] + #[doc = " older than the version created with this header file."] pub GetApi: ::std::option::Option *const OrtApi>, + #[doc = "< Returns a null terminated string of the version of the Onnxruntime library (eg: \"1.8.1\")"] pub GetVersionString: ::std::option::Option *const ::std::os::raw::c_char>, } @@ -3638,50 +4232,142 @@ fn bindgen_test_layout_OrtApiBase() { 8usize, concat!("Alignment of ", stringify!(OrtApiBase)) ); + fn test_field_GetApi() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetApi) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtApiBase), + "::", + stringify!(GetApi) + ) + ); + } + test_field_GetApi(); + fn test_field_GetVersionString() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetVersionString) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtApiBase), + "::", + stringify!(GetVersionString) + ) + ); + } + test_field_GetVersionString(); +} +extern "C" { + #[doc = " \\brief The Onnxruntime library's entry point to access the C API"] + #[doc = ""] + #[doc = " Call this to get the a pointer to an ::OrtApiBase"] + pub fn OrtGetApiBase() -> *const OrtApiBase; +} +#[doc = " \\brief Thread work loop function"] +#[doc = ""] +#[doc = " Onnxruntime will provide the working loop on custom thread creation"] +#[doc = " Argument is an onnxruntime built-in type which will be provided when thread pool calls OrtCustomCreateThreadFn"] +pub type OrtThreadWorkerFn = + ::std::option::Option; +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct OrtCustomHandleType { + pub __place_holder: ::std::os::raw::c_char, +} +#[test] +fn bindgen_test_layout_OrtCustomHandleType() { assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetApi as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtApiBase), - "::", - stringify!(GetApi) - ) + ::std::mem::size_of::(), + 1usize, + concat!("Size of: ", stringify!(OrtCustomHandleType)) ); assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetVersionString as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtApiBase), - "::", - stringify!(GetVersionString) - ) - ); -} -extern "C" { - pub fn OrtGetApiBase() -> *const OrtApiBase; -} + ::std::mem::align_of::(), + 1usize, + concat!("Alignment of ", stringify!(OrtCustomHandleType)) + ); + fn test_field___place_holder() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).__place_holder) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomHandleType), + "::", + stringify!(__place_holder) + ) + ); + } + test_field___place_holder(); +} +pub type OrtCustomThreadHandle = *const OrtCustomHandleType; +#[doc = " \\brief Ort custom thread creation function"] +#[doc = ""] +#[doc = " The function should return a thread handle to be used in onnxruntime thread pools"] +#[doc = " Onnxruntime will throw exception on return value of nullptr or 0, indicating that the function failed to create a thread"] +pub type OrtCustomCreateThreadFn = ::std::option::Option< + unsafe extern "C" fn( + ort_custom_thread_creation_options: *mut ::std::os::raw::c_void, + ort_thread_worker_fn: OrtThreadWorkerFn, + ort_worker_fn_param: *mut ::std::os::raw::c_void, + ) -> OrtCustomThreadHandle, +>; +#[doc = " \\brief Custom thread join function"] +#[doc = ""] +#[doc = " Onnxruntime thread pool destructor will call the function to join a custom thread."] +#[doc = " Argument ort_custom_thread_handle is the value returned by OrtCustomCreateThreadFn"] +pub type OrtCustomJoinThreadFn = + ::std::option::Option; +#[doc = " \\brief The C API"] +#[doc = ""] +#[doc = " All C API functions are defined inside this structure as pointers to functions."] +#[doc = " Call OrtApiBase::GetApi to get a pointer to it"] +#[doc = ""] +#[doc = " \\nosubgrouping"] #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct OrtApi { - #[doc = " \\param msg A null-terminated string. Its content will be copied into the newly created OrtStatus"] + #[doc = " \\brief Create an OrtStatus from a null terminated string"] + #[doc = ""] + #[doc = " \\param[in] code"] + #[doc = " \\param[in] msg A null-terminated string. Its contents will be copied."] + #[doc = " \\return A new OrtStatus object, must be destroyed with OrtApi::ReleaseStatus"] pub CreateStatus: ::std::option::Option< unsafe extern "C" fn( code: OrtErrorCode, msg: *const ::std::os::raw::c_char, ) -> *mut OrtStatus, >, + #[doc = " \\brief Get OrtErrorCode from OrtStatus"] + #[doc = ""] + #[doc = " \\param[in] status"] + #[doc = " \\return OrtErrorCode that \\p status was created with"] pub GetErrorCode: ::std::option::Option OrtErrorCode>, - #[doc = " \\param status must not be NULL"] + #[doc = " \\brief Get error string from OrtStatus"] + #[doc = ""] + #[doc = " \\param[in] status"] #[doc = " \\return The error message inside the `status`. Do not free the returned value."] pub GetErrorMessage: ::std::option::Option< unsafe extern "C" fn(status: *const OrtStatus) -> *const ::std::os::raw::c_char, >, pub CreateEnv: ::std::option::Option< unsafe extern "C" fn( - logging_level: OrtLoggingLevel, + log_severity_level: OrtLoggingLevel, logid: *const ::std::os::raw::c_char, out: *mut *mut OrtEnv, ) -> OrtStatusPtr, @@ -3690,7 +4376,7 @@ pub struct OrtApi { unsafe extern "C" fn( logging_function: OrtLoggingFunction, logger_param: *mut ::std::os::raw::c_void, - logging_level: OrtLoggingLevel, + log_severity_level: OrtLoggingLevel, logid: *const ::std::os::raw::c_char, out: *mut *mut OrtEnv, ) -> OrtStatusPtr, @@ -3718,14 +4404,14 @@ pub struct OrtApi { >, pub Run: ::std::option::Option< unsafe extern "C" fn( - sess: *mut OrtSession, + session: *mut OrtSession, run_options: *const OrtRunOptions, input_names: *const *const ::std::os::raw::c_char, - input: *const *const OrtValue, + inputs: *const *const OrtValue, input_len: usize, - output_names1: *const *const ::std::os::raw::c_char, + output_names: *const *const ::std::os::raw::c_char, output_names_len: usize, - output: *mut *mut OrtValue, + outputs: *mut *mut OrtValue, ) -> OrtStatusPtr, >, pub CreateSessionOptions: ::std::option::Option< @@ -3832,38 +4518,38 @@ pub struct OrtApi { ) -> OrtStatusPtr, >, pub SessionGetInputCount: ::std::option::Option< - unsafe extern "C" fn(sess: *const OrtSession, out: *mut usize) -> OrtStatusPtr, + unsafe extern "C" fn(session: *const OrtSession, out: *mut usize) -> OrtStatusPtr, >, pub SessionGetOutputCount: ::std::option::Option< - unsafe extern "C" fn(sess: *const OrtSession, out: *mut usize) -> OrtStatusPtr, + unsafe extern "C" fn(session: *const OrtSession, out: *mut usize) -> OrtStatusPtr, >, pub SessionGetOverridableInitializerCount: ::std::option::Option< - unsafe extern "C" fn(sess: *const OrtSession, out: *mut usize) -> OrtStatusPtr, + unsafe extern "C" fn(session: *const OrtSession, out: *mut usize) -> OrtStatusPtr, >, pub SessionGetInputTypeInfo: ::std::option::Option< unsafe extern "C" fn( - sess: *const OrtSession, + session: *const OrtSession, index: usize, type_info: *mut *mut OrtTypeInfo, ) -> OrtStatusPtr, >, pub SessionGetOutputTypeInfo: ::std::option::Option< unsafe extern "C" fn( - sess: *const OrtSession, + session: *const OrtSession, index: usize, type_info: *mut *mut OrtTypeInfo, ) -> OrtStatusPtr, >, pub SessionGetOverridableInitializerTypeInfo: ::std::option::Option< unsafe extern "C" fn( - sess: *const OrtSession, + session: *const OrtSession, index: usize, type_info: *mut *mut OrtTypeInfo, ) -> OrtStatusPtr, >, pub SessionGetInputName: ::std::option::Option< unsafe extern "C" fn( - sess: *const OrtSession, + session: *const OrtSession, index: usize, allocator: *mut OrtAllocator, value: *mut *mut ::std::os::raw::c_char, @@ -3871,7 +4557,7 @@ pub struct OrtApi { >, pub SessionGetOutputName: ::std::option::Option< unsafe extern "C" fn( - sess: *const OrtSession, + session: *const OrtSession, index: usize, allocator: *mut OrtAllocator, value: *mut *mut ::std::os::raw::c_char, @@ -3879,7 +4565,7 @@ pub struct OrtApi { >, pub SessionGetOverridableInitializerName: ::std::option::Option< unsafe extern "C" fn( - sess: *const OrtSession, + session: *const OrtSession, index: usize, allocator: *mut OrtAllocator, value: *mut *mut ::std::os::raw::c_char, @@ -3890,37 +4576,37 @@ pub struct OrtApi { pub RunOptionsSetRunLogVerbosityLevel: ::std::option::Option< unsafe extern "C" fn( options: *mut OrtRunOptions, - value: ::std::os::raw::c_int, + log_verbosity_level: ::std::os::raw::c_int, ) -> OrtStatusPtr, >, pub RunOptionsSetRunLogSeverityLevel: ::std::option::Option< unsafe extern "C" fn( options: *mut OrtRunOptions, - value: ::std::os::raw::c_int, + log_severity_level: ::std::os::raw::c_int, ) -> OrtStatusPtr, >, pub RunOptionsSetRunTag: ::std::option::Option< unsafe extern "C" fn( - arg1: *mut OrtRunOptions, + options: *mut OrtRunOptions, run_tag: *const ::std::os::raw::c_char, ) -> OrtStatusPtr, >, pub RunOptionsGetRunLogVerbosityLevel: ::std::option::Option< unsafe extern "C" fn( options: *const OrtRunOptions, - out: *mut ::std::os::raw::c_int, + log_verbosity_level: *mut ::std::os::raw::c_int, ) -> OrtStatusPtr, >, pub RunOptionsGetRunLogSeverityLevel: ::std::option::Option< unsafe extern "C" fn( options: *const OrtRunOptions, - out: *mut ::std::os::raw::c_int, + log_severity_level: *mut ::std::os::raw::c_int, ) -> OrtStatusPtr, >, pub RunOptionsGetRunTag: ::std::option::Option< unsafe extern "C" fn( - arg1: *const OrtRunOptions, - out: *mut *const ::std::os::raw::c_char, + options: *const OrtRunOptions, + run_tag: *mut *const ::std::os::raw::c_char, ) -> OrtStatusPtr, >, pub RunOptionsSetTerminate: @@ -3980,19 +4666,19 @@ pub struct OrtApi { >, pub CastTypeInfoToTensorInfo: ::std::option::Option< unsafe extern "C" fn( - arg1: *const OrtTypeInfo, + type_info: *const OrtTypeInfo, out: *mut *const OrtTensorTypeAndShapeInfo, ) -> OrtStatusPtr, >, pub GetOnnxTypeFromTypeInfo: ::std::option::Option< - unsafe extern "C" fn(arg1: *const OrtTypeInfo, out: *mut ONNXType) -> OrtStatusPtr, + unsafe extern "C" fn(type_info: *const OrtTypeInfo, out: *mut ONNXType) -> OrtStatusPtr, >, pub CreateTensorTypeAndShapeInfo: ::std::option::Option< unsafe extern "C" fn(out: *mut *mut OrtTensorTypeAndShapeInfo) -> OrtStatusPtr, >, pub SetTensorElementType: ::std::option::Option< unsafe extern "C" fn( - arg1: *mut OrtTensorTypeAndShapeInfo, + info: *mut OrtTensorTypeAndShapeInfo, type_: ONNXTensorElementDataType, ) -> OrtStatusPtr, >, @@ -4005,7 +4691,7 @@ pub struct OrtApi { >, pub GetTensorElementType: ::std::option::Option< unsafe extern "C" fn( - arg1: *const OrtTensorTypeAndShapeInfo, + info: *const OrtTensorTypeAndShapeInfo, out: *mut ONNXTensorElementDataType, ) -> OrtStatusPtr, >, @@ -4049,17 +4735,17 @@ pub struct OrtApi { >, pub CreateMemoryInfo: ::std::option::Option< unsafe extern "C" fn( - name1: *const ::std::os::raw::c_char, + name: *const ::std::os::raw::c_char, type_: OrtAllocatorType, - id1: ::std::os::raw::c_int, - mem_type1: OrtMemType, + id: ::std::os::raw::c_int, + mem_type: OrtMemType, out: *mut *mut OrtMemoryInfo, ) -> OrtStatusPtr, >, pub CreateCpuMemoryInfo: ::std::option::Option< unsafe extern "C" fn( type_: OrtAllocatorType, - mem_type1: OrtMemType, + mem_type: OrtMemType, out: *mut *mut OrtMemoryInfo, ) -> OrtStatusPtr, >, @@ -4090,20 +4776,20 @@ pub struct OrtApi { >, pub AllocatorAlloc: ::std::option::Option< unsafe extern "C" fn( - ptr: *mut OrtAllocator, + ort_allocator: *mut OrtAllocator, size: usize, out: *mut *mut ::std::os::raw::c_void, ) -> OrtStatusPtr, >, pub AllocatorFree: ::std::option::Option< unsafe extern "C" fn( - ptr: *mut OrtAllocator, + ort_allocator: *mut OrtAllocator, p: *mut ::std::os::raw::c_void, ) -> OrtStatusPtr, >, pub AllocatorGetInfo: ::std::option::Option< unsafe extern "C" fn( - ptr: *const OrtAllocator, + ort_allocator: *const OrtAllocator, out: *mut *const OrtMemoryInfo, ) -> OrtStatusPtr, >, @@ -4212,7 +4898,7 @@ pub struct OrtApi { ::std::option::Option, pub GetDenotationFromTypeInfo: ::std::option::Option< unsafe extern "C" fn( - arg1: *const OrtTypeInfo, + type_info: *const OrtTypeInfo, denotation: *mut *const ::std::os::raw::c_char, len: *mut usize, ) -> OrtStatusPtr, @@ -4252,14 +4938,14 @@ pub struct OrtApi { ::std::option::Option, pub SessionEndProfiling: ::std::option::Option< unsafe extern "C" fn( - sess: *mut OrtSession, + session: *mut OrtSession, allocator: *mut OrtAllocator, out: *mut *mut ::std::os::raw::c_char, ) -> OrtStatusPtr, >, pub SessionGetModelMetadata: ::std::option::Option< unsafe extern "C" fn( - sess: *const OrtSession, + session: *const OrtSession, out: *mut *mut OrtModelMetadata, ) -> OrtStatusPtr, >, @@ -4309,9 +4995,9 @@ pub struct OrtApi { ::std::option::Option, pub CreateEnvWithGlobalThreadPools: ::std::option::Option< unsafe extern "C" fn( - logging_level: OrtLoggingLevel, + log_severity_level: OrtLoggingLevel, logid: *const ::std::os::raw::c_char, - t_options: *const OrtThreadingOptions, + tp_options: *const OrtThreadingOptions, out: *mut *mut OrtEnv, ) -> OrtStatusPtr, >, @@ -4377,7 +5063,7 @@ pub struct OrtApi { >, pub CreateAllocator: ::std::option::Option< unsafe extern "C" fn( - sess: *const OrtSession, + session: *const OrtSession, mem_info: *const OrtMemoryInfo, out: *mut *mut OrtAllocator, ) -> OrtStatusPtr, @@ -4385,13 +5071,13 @@ pub struct OrtApi { pub ReleaseAllocator: ::std::option::Option, pub RunWithBinding: ::std::option::Option< unsafe extern "C" fn( - sess: *mut OrtSession, + session: *mut OrtSession, run_options: *const OrtRunOptions, binding_ptr: *const OrtIoBinding, ) -> OrtStatusPtr, >, pub CreateIoBinding: ::std::option::Option< - unsafe extern "C" fn(sess: *mut OrtSession, out: *mut *mut OrtIoBinding) -> OrtStatusPtr, + unsafe extern "C" fn(session: *mut OrtSession, out: *mut *mut OrtIoBinding) -> OrtStatusPtr, >, pub ReleaseIoBinding: ::std::option::Option, pub BindInput: ::std::option::Option< @@ -4412,7 +5098,7 @@ pub struct OrtApi { unsafe extern "C" fn( binding_ptr: *mut OrtIoBinding, name: *const ::std::os::raw::c_char, - val_ptr: *const OrtMemoryInfo, + mem_info_ptr: *const OrtMemoryInfo, ) -> OrtStatusPtr, >, pub GetBoundOutputNames: ::std::option::Option< @@ -4432,9 +5118,10 @@ pub struct OrtApi { output_count: *mut usize, ) -> OrtStatusPtr, >, - #[doc = " Clears any previously specified bindings for inputs/outputs"] + #[doc = " \\brief Clears any previously set Inputs for an ::OrtIoBinding"] pub ClearBoundInputs: ::std::option::Option, + #[doc = " \\brief Clears any previously set Outputs for an ::OrtIoBinding"] pub ClearBoundOutputs: ::std::option::Option, pub TensorAt: ::std::option::Option< @@ -4459,7 +5146,7 @@ pub struct OrtApi { ) -> OrtStatusPtr, >, pub SessionGetProfilingStartTimeNs: ::std::option::Option< - unsafe extern "C" fn(sess: *const OrtSession, out: *mut u64) -> OrtStatusPtr, + unsafe extern "C" fn(session: *const OrtSession, out: *mut u64) -> OrtStatusPtr, >, pub SetGlobalIntraOpNumThreads: ::std::option::Option< unsafe extern "C" fn( @@ -4490,7 +5177,7 @@ pub struct OrtApi { unsafe extern "C" fn( logging_function: OrtLoggingFunction, logger_param: *mut ::std::os::raw::c_void, - logging_level: OrtLoggingLevel, + log_severity_level: OrtLoggingLevel, logid: *const ::std::os::raw::c_char, tp_options: *const OrtThreadingOptions, out: *mut *mut OrtEnv, @@ -4601,1837 +5288,3880 @@ pub struct OrtApi { out: *mut *mut OrtSession, ) -> OrtStatusPtr, >, -} -#[test] -fn bindgen_test_layout_OrtApi() { - assert_eq!( - ::std::mem::size_of::(), - 1360usize, - concat!("Size of: ", stringify!(OrtApi)) - ); - assert_eq!( - ::std::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(OrtApi)) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateStatus as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateStatus) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetErrorCode as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetErrorCode) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetErrorMessage as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetErrorMessage) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateEnv as *const _ as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateEnv) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateEnvWithCustomLogger as *const _ as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateEnvWithCustomLogger) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).EnableTelemetryEvents as *const _ as usize }, - 40usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(EnableTelemetryEvents) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).DisableTelemetryEvents as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(DisableTelemetryEvents) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateSession as *const _ as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateSession) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateSessionFromArray as *const _ as usize }, - 64usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateSessionFromArray) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).Run as *const _ as usize }, - 72usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(Run) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateSessionOptions as *const _ as usize }, - 80usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateSessionOptions) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SetOptimizedModelFilePath as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetOptimizedModelFilePath) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CloneSessionOptions as *const _ as usize }, - 96usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CloneSessionOptions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetSessionExecutionMode as *const _ as usize }, - 104usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetSessionExecutionMode) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).EnableProfiling as *const _ as usize }, - 112usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(EnableProfiling) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).DisableProfiling as *const _ as usize }, - 120usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(DisableProfiling) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).EnableMemPattern as *const _ as usize }, - 128usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(EnableMemPattern) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).DisableMemPattern as *const _ as usize }, - 136usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(DisableMemPattern) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).EnableCpuMemArena as *const _ as usize }, - 144usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(EnableCpuMemArena) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).DisableCpuMemArena as *const _ as usize }, - 152usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(DisableCpuMemArena) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetSessionLogId as *const _ as usize }, - 160usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetSessionLogId) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SetSessionLogVerbosityLevel as *const _ as usize - }, - 168usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetSessionLogVerbosityLevel) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SetSessionLogSeverityLevel as *const _ as usize - }, - 176usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetSessionLogSeverityLevel) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SetSessionGraphOptimizationLevel as *const _ as usize - }, - 184usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetSessionGraphOptimizationLevel) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetIntraOpNumThreads as *const _ as usize }, - 192usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetIntraOpNumThreads) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetInterOpNumThreads as *const _ as usize }, - 200usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetInterOpNumThreads) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateCustomOpDomain as *const _ as usize }, - 208usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateCustomOpDomain) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CustomOpDomain_Add as *const _ as usize }, - 216usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CustomOpDomain_Add) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AddCustomOpDomain as *const _ as usize }, - 224usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AddCustomOpDomain) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).RegisterCustomOpsLibrary as *const _ as usize }, - 232usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RegisterCustomOpsLibrary) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionGetInputCount as *const _ as usize }, - 240usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetInputCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionGetOutputCount as *const _ as usize }, - 248usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetOutputCount) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionGetOverridableInitializerCount as *const _ - as usize - }, - 256usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetOverridableInitializerCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionGetInputTypeInfo as *const _ as usize }, - 264usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetInputTypeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionGetOutputTypeInfo as *const _ as usize }, - 272usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetOutputTypeInfo) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionGetOverridableInitializerTypeInfo as *const _ - as usize - }, - 280usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetOverridableInitializerTypeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionGetInputName as *const _ as usize }, - 288usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetInputName) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionGetOutputName as *const _ as usize }, - 296usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetOutputName) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionGetOverridableInitializerName as *const _ - as usize - }, - 304usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetOverridableInitializerName) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateRunOptions as *const _ as usize }, - 312usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateRunOptions) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).RunOptionsSetRunLogVerbosityLevel as *const _ - as usize - }, - 320usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsSetRunLogVerbosityLevel) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).RunOptionsSetRunLogSeverityLevel as *const _ as usize - }, - 328usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsSetRunLogSeverityLevel) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).RunOptionsSetRunTag as *const _ as usize }, - 336usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsSetRunTag) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).RunOptionsGetRunLogVerbosityLevel as *const _ - as usize - }, - 344usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsGetRunLogVerbosityLevel) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).RunOptionsGetRunLogSeverityLevel as *const _ as usize - }, - 352usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsGetRunLogSeverityLevel) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).RunOptionsGetRunTag as *const _ as usize }, - 360usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsGetRunTag) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).RunOptionsSetTerminate as *const _ as usize }, - 368usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsSetTerminate) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).RunOptionsUnsetTerminate as *const _ as usize }, - 376usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunOptionsUnsetTerminate) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateTensorAsOrtValue as *const _ as usize }, - 384usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateTensorAsOrtValue) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateTensorWithDataAsOrtValue as *const _ as usize - }, - 392usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateTensorWithDataAsOrtValue) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).IsTensor as *const _ as usize }, - 400usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(IsTensor) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetTensorMutableData as *const _ as usize }, - 408usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetTensorMutableData) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).FillStringTensor as *const _ as usize }, - 416usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(FillStringTensor) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetStringTensorDataLength as *const _ as usize - }, - 424usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetStringTensorDataLength) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetStringTensorContent as *const _ as usize }, - 432usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetStringTensorContent) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CastTypeInfoToTensorInfo as *const _ as usize }, - 440usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CastTypeInfoToTensorInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetOnnxTypeFromTypeInfo as *const _ as usize }, - 448usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetOnnxTypeFromTypeInfo) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateTensorTypeAndShapeInfo as *const _ as usize - }, - 456usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateTensorTypeAndShapeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetTensorElementType as *const _ as usize }, - 464usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetTensorElementType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetDimensions as *const _ as usize }, - 472usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetDimensions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetTensorElementType as *const _ as usize }, - 480usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetTensorElementType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetDimensionsCount as *const _ as usize }, - 488usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetDimensionsCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetDimensions as *const _ as usize }, - 496usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetDimensions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetSymbolicDimensions as *const _ as usize }, - 504usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetSymbolicDimensions) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetTensorShapeElementCount as *const _ as usize - }, - 512usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetTensorShapeElementCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetTensorTypeAndShape as *const _ as usize }, - 520usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetTensorTypeAndShape) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetTypeInfo as *const _ as usize }, - 528usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetTypeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetValueType as *const _ as usize }, - 536usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetValueType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateMemoryInfo as *const _ as usize }, - 544usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateMemoryInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateCpuMemoryInfo as *const _ as usize }, - 552usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateCpuMemoryInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CompareMemoryInfo as *const _ as usize }, - 560usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CompareMemoryInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).MemoryInfoGetName as *const _ as usize }, - 568usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(MemoryInfoGetName) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).MemoryInfoGetId as *const _ as usize }, - 576usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(MemoryInfoGetId) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).MemoryInfoGetMemType as *const _ as usize }, - 584usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(MemoryInfoGetMemType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).MemoryInfoGetType as *const _ as usize }, - 592usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(MemoryInfoGetType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AllocatorAlloc as *const _ as usize }, - 600usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AllocatorAlloc) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AllocatorFree as *const _ as usize }, - 608usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AllocatorFree) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AllocatorGetInfo as *const _ as usize }, - 616usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AllocatorGetInfo) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetAllocatorWithDefaultOptions as *const _ as usize - }, - 624usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetAllocatorWithDefaultOptions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AddFreeDimensionOverride as *const _ as usize }, - 632usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AddFreeDimensionOverride) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetValue as *const _ as usize }, - 640usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetValue) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetValueCount as *const _ as usize }, - 648usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetValueCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateValue as *const _ as usize }, - 656usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateValue) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateOpaqueValue as *const _ as usize }, - 664usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateOpaqueValue) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetOpaqueValue as *const _ as usize }, - 672usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetOpaqueValue) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).KernelInfoGetAttribute_float as *const _ as usize - }, - 680usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelInfoGetAttribute_float) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).KernelInfoGetAttribute_int64 as *const _ as usize - }, - 688usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelInfoGetAttribute_int64) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).KernelInfoGetAttribute_string as *const _ as usize - }, - 696usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelInfoGetAttribute_string) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).KernelContext_GetInputCount as *const _ as usize - }, - 704usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelContext_GetInputCount) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).KernelContext_GetOutputCount as *const _ as usize - }, - 712usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelContext_GetOutputCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).KernelContext_GetInput as *const _ as usize }, - 720usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelContext_GetInput) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).KernelContext_GetOutput as *const _ as usize }, - 728usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelContext_GetOutput) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseEnv as *const _ as usize }, - 736usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseEnv) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseStatus as *const _ as usize }, - 744usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseStatus) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseMemoryInfo as *const _ as usize }, - 752usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseMemoryInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseSession as *const _ as usize }, - 760usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseSession) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseValue as *const _ as usize }, - 768usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseValue) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseRunOptions as *const _ as usize }, - 776usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseRunOptions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseTypeInfo as *const _ as usize }, - 784usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseTypeInfo) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ReleaseTensorTypeAndShapeInfo as *const _ as usize - }, - 792usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseTensorTypeAndShapeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseSessionOptions as *const _ as usize }, - 800usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseSessionOptions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseCustomOpDomain as *const _ as usize }, - 808usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseCustomOpDomain) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetDenotationFromTypeInfo as *const _ as usize - }, - 816usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetDenotationFromTypeInfo) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CastTypeInfoToMapTypeInfo as *const _ as usize - }, - 824usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CastTypeInfoToMapTypeInfo) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CastTypeInfoToSequenceTypeInfo as *const _ as usize - }, - 832usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CastTypeInfoToSequenceTypeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetMapKeyType as *const _ as usize }, - 840usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetMapKeyType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetMapValueType as *const _ as usize }, - 848usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetMapValueType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetSequenceElementType as *const _ as usize }, - 856usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetSequenceElementType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseMapTypeInfo as *const _ as usize }, - 864usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseMapTypeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseSequenceTypeInfo as *const _ as usize }, - 872usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseSequenceTypeInfo) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionEndProfiling as *const _ as usize }, - 880usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionEndProfiling) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SessionGetModelMetadata as *const _ as usize }, - 888usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetModelMetadata) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ModelMetadataGetProducerName as *const _ as usize - }, - 896usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataGetProducerName) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ModelMetadataGetGraphName as *const _ as usize - }, - 904usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataGetGraphName) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ModelMetadataGetDomain as *const _ as usize }, - 912usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataGetDomain) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ModelMetadataGetDescription as *const _ as usize - }, - 920usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataGetDescription) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ModelMetadataLookupCustomMetadataMap as *const _ - as usize - }, - 928usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataLookupCustomMetadataMap) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ModelMetadataGetVersion as *const _ as usize }, - 936usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataGetVersion) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseModelMetadata as *const _ as usize }, - 944usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseModelMetadata) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateEnvWithGlobalThreadPools as *const _ as usize - }, - 952usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateEnvWithGlobalThreadPools) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).DisablePerSessionThreads as *const _ as usize }, - 960usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(DisablePerSessionThreads) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateThreadingOptions as *const _ as usize }, - 968usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateThreadingOptions) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseThreadingOptions as *const _ as usize }, - 976usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseThreadingOptions) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ModelMetadataGetCustomMetadataMapKeys as *const _ - as usize - }, - 984usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataGetCustomMetadataMapKeys) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).AddFreeDimensionOverrideByName as *const _ as usize - }, - 992usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AddFreeDimensionOverrideByName) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetAvailableProviders as *const _ as usize }, - 1000usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetAvailableProviders) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ReleaseAvailableProviders as *const _ as usize - }, - 1008usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseAvailableProviders) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetStringTensorElementLength as *const _ as usize - }, - 1016usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetStringTensorElementLength) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetStringTensorElement as *const _ as usize }, - 1024usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetStringTensorElement) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).FillStringTensorElement as *const _ as usize }, - 1032usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(FillStringTensorElement) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AddSessionConfigEntry as *const _ as usize }, - 1040usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AddSessionConfigEntry) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateAllocator as *const _ as usize }, - 1048usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateAllocator) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseAllocator as *const _ as usize }, - 1056usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseAllocator) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).RunWithBinding as *const _ as usize }, - 1064usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(RunWithBinding) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateIoBinding as *const _ as usize }, - 1072usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateIoBinding) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseIoBinding as *const _ as usize }, - 1080usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseIoBinding) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).BindInput as *const _ as usize }, - 1088usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(BindInput) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).BindOutput as *const _ as usize }, - 1096usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(BindOutput) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).BindOutputToDevice as *const _ as usize }, - 1104usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(BindOutputToDevice) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetBoundOutputNames as *const _ as usize }, - 1112usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetBoundOutputNames) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetBoundOutputValues as *const _ as usize }, - 1120usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetBoundOutputValues) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ClearBoundInputs as *const _ as usize }, - 1128usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ClearBoundInputs) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ClearBoundOutputs as *const _ as usize }, - 1136usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ClearBoundOutputs) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).TensorAt as *const _ as usize }, - 1144usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(TensorAt) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateAndRegisterAllocator as *const _ as usize - }, - 1152usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateAndRegisterAllocator) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetLanguageProjection as *const _ as usize }, - 1160usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetLanguageProjection) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionGetProfilingStartTimeNs as *const _ as usize - }, - 1168usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionGetProfilingStartTimeNs) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SetGlobalIntraOpNumThreads as *const _ as usize - }, - 1176usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetGlobalIntraOpNumThreads) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SetGlobalInterOpNumThreads as *const _ as usize - }, - 1184usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetGlobalInterOpNumThreads) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetGlobalSpinControl as *const _ as usize }, - 1192usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetGlobalSpinControl) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AddInitializer as *const _ as usize }, - 1200usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AddInitializer) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateEnvWithCustomLoggerAndGlobalThreadPools - as *const _ as usize - }, - 1208usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateEnvWithCustomLoggerAndGlobalThreadPools) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionOptionsAppendExecutionProvider_CUDA - as *const _ as usize - }, - 1216usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionOptionsAppendExecutionProvider_CUDA) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionOptionsAppendExecutionProvider_ROCM - as *const _ as usize - }, - 1224usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionOptionsAppendExecutionProvider_ROCM) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionOptionsAppendExecutionProvider_OpenVINO - as *const _ as usize - }, - 1232usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionOptionsAppendExecutionProvider_OpenVINO) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetGlobalDenormalAsZero as *const _ as usize }, - 1240usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetGlobalDenormalAsZero) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateArenaCfg as *const _ as usize }, - 1248usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateArenaCfg) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).ReleaseArenaCfg as *const _ as usize }, - 1256usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleaseArenaCfg) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ModelMetadataGetGraphDescription as *const _ as usize - }, - 1264usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ModelMetadataGetGraphDescription) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).SessionOptionsAppendExecutionProvider_TensorRT - as *const _ as usize - }, - 1272usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SessionOptionsAppendExecutionProvider_TensorRT) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).SetCurrentGpuDeviceId as *const _ as usize }, - 1280usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(SetCurrentGpuDeviceId) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetCurrentGpuDeviceId as *const _ as usize }, - 1288usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(GetCurrentGpuDeviceId) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).KernelInfoGetAttributeArray_float as *const _ - as usize - }, - 1296usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelInfoGetAttributeArray_float) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).KernelInfoGetAttributeArray_int64 as *const _ - as usize - }, - 1304usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(KernelInfoGetAttributeArray_int64) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateArenaCfgV2 as *const _ as usize }, - 1312usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateArenaCfgV2) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).AddRunConfigEntry as *const _ as usize }, - 1320usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(AddRunConfigEntry) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreatePrepackedWeightsContainer as *const _ as usize - }, - 1328usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreatePrepackedWeightsContainer) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).ReleasePrepackedWeightsContainer as *const _ as usize - }, - 1336usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(ReleasePrepackedWeightsContainer) - ) - ); + pub SessionOptionsAppendExecutionProvider_TensorRT_V2: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + tensorrt_options: *const OrtTensorRTProviderOptionsV2, + ) -> OrtStatusPtr, + >, + pub CreateTensorRTProviderOptions: ::std::option::Option< + unsafe extern "C" fn(out: *mut *mut OrtTensorRTProviderOptionsV2) -> OrtStatusPtr, + >, + pub UpdateTensorRTProviderOptions: ::std::option::Option< + unsafe extern "C" fn( + tensorrt_options: *mut OrtTensorRTProviderOptionsV2, + provider_options_keys: *const *const ::std::os::raw::c_char, + provider_options_values: *const *const ::std::os::raw::c_char, + num_keys: usize, + ) -> OrtStatusPtr, + >, + pub GetTensorRTProviderOptionsAsString: ::std::option::Option< + unsafe extern "C" fn( + tensorrt_options: *const OrtTensorRTProviderOptionsV2, + allocator: *mut OrtAllocator, + ptr: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + #[doc = " \\brief Release an ::OrtTensorRTProviderOptionsV2"] + #[doc = ""] + #[doc = " \\note This is an exception in the naming convention of other Release* functions, as the name of the method does not have the V2 suffix, but the type does"] + pub ReleaseTensorRTProviderOptions: + ::std::option::Option, + pub EnableOrtCustomOps: ::std::option::Option< + unsafe extern "C" fn(options: *mut OrtSessionOptions) -> OrtStatusPtr, + >, + pub RegisterAllocator: ::std::option::Option< + unsafe extern "C" fn(env: *mut OrtEnv, allocator: *mut OrtAllocator) -> OrtStatusPtr, + >, + pub UnregisterAllocator: ::std::option::Option< + unsafe extern "C" fn(env: *mut OrtEnv, mem_info: *const OrtMemoryInfo) -> OrtStatusPtr, + >, + pub IsSparseTensor: ::std::option::Option< + unsafe extern "C" fn( + value: *const OrtValue, + out: *mut ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub CreateSparseTensorAsOrtValue: ::std::option::Option< + unsafe extern "C" fn( + allocator: *mut OrtAllocator, + dense_shape: *const i64, + dense_shape_len: usize, + type_: ONNXTensorElementDataType, + out: *mut *mut OrtValue, + ) -> OrtStatusPtr, + >, + pub FillSparseTensorCoo: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *mut OrtValue, + data_mem_info: *const OrtMemoryInfo, + values_shape: *const i64, + values_shape_len: usize, + values: *const ::std::os::raw::c_void, + indices_data: *const i64, + indices_num: usize, + ) -> OrtStatusPtr, + >, + pub FillSparseTensorCsr: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *mut OrtValue, + data_mem_info: *const OrtMemoryInfo, + values_shape: *const i64, + values_shape_len: usize, + values: *const ::std::os::raw::c_void, + inner_indices_data: *const i64, + inner_indices_num: usize, + outer_indices_data: *const i64, + outer_indices_num: usize, + ) -> OrtStatusPtr, + >, + pub FillSparseTensorBlockSparse: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *mut OrtValue, + data_mem_info: *const OrtMemoryInfo, + values_shape: *const i64, + values_shape_len: usize, + values: *const ::std::os::raw::c_void, + indices_shape_data: *const i64, + indices_shape_len: usize, + indices_data: *const i32, + ) -> OrtStatusPtr, + >, + pub CreateSparseTensorWithValuesAsOrtValue: ::std::option::Option< + unsafe extern "C" fn( + info: *const OrtMemoryInfo, + p_data: *mut ::std::os::raw::c_void, + dense_shape: *const i64, + dense_shape_len: usize, + values_shape: *const i64, + values_shape_len: usize, + type_: ONNXTensorElementDataType, + out: *mut *mut OrtValue, + ) -> OrtStatusPtr, + >, + pub UseCooIndices: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *mut OrtValue, + indices_data: *mut i64, + indices_num: usize, + ) -> OrtStatusPtr, + >, + pub UseCsrIndices: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *mut OrtValue, + inner_data: *mut i64, + inner_num: usize, + outer_data: *mut i64, + outer_num: usize, + ) -> OrtStatusPtr, + >, + pub UseBlockSparseIndices: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *mut OrtValue, + indices_shape: *const i64, + indices_shape_len: usize, + indices_data: *mut i32, + ) -> OrtStatusPtr, + >, + pub GetSparseTensorFormat: ::std::option::Option< + unsafe extern "C" fn(ort_value: *const OrtValue, out: *mut OrtSparseFormat) -> OrtStatusPtr, + >, + pub GetSparseTensorValuesTypeAndShape: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *const OrtValue, + out: *mut *mut OrtTensorTypeAndShapeInfo, + ) -> OrtStatusPtr, + >, + pub GetSparseTensorValues: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *const OrtValue, + out: *mut *const ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub GetSparseTensorIndicesTypeShape: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *const OrtValue, + indices_format: OrtSparseIndicesFormat, + out: *mut *mut OrtTensorTypeAndShapeInfo, + ) -> OrtStatusPtr, + >, + pub GetSparseTensorIndices: ::std::option::Option< + unsafe extern "C" fn( + ort_value: *const OrtValue, + indices_format: OrtSparseIndicesFormat, + num_indices: *mut usize, + indices: *mut *const ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub HasValue: ::std::option::Option< + unsafe extern "C" fn( + value: *const OrtValue, + out: *mut ::std::os::raw::c_int, + ) -> OrtStatusPtr, + >, + pub KernelContext_GetGPUComputeStream: ::std::option::Option< + unsafe extern "C" fn( + context: *const OrtKernelContext, + out: *mut *mut ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub GetTensorMemoryInfo: ::std::option::Option< + unsafe extern "C" fn( + value: *const OrtValue, + mem_info: *mut *const OrtMemoryInfo, + ) -> OrtStatusPtr, + >, + pub GetExecutionProviderApi: ::std::option::Option< + unsafe extern "C" fn( + provider_name: *const ::std::os::raw::c_char, + version: u32, + provider_api: *mut *const ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub SessionOptionsSetCustomCreateThreadFn: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + ort_custom_create_thread_fn: OrtCustomCreateThreadFn, + ) -> OrtStatusPtr, + >, + pub SessionOptionsSetCustomThreadCreationOptions: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + ort_custom_thread_creation_options: *mut ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub SessionOptionsSetCustomJoinThreadFn: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + ort_custom_join_thread_fn: OrtCustomJoinThreadFn, + ) -> OrtStatusPtr, + >, + pub SetGlobalCustomCreateThreadFn: ::std::option::Option< + unsafe extern "C" fn( + tp_options: *mut OrtThreadingOptions, + ort_custom_create_thread_fn: OrtCustomCreateThreadFn, + ) -> OrtStatusPtr, + >, + pub SetGlobalCustomThreadCreationOptions: ::std::option::Option< + unsafe extern "C" fn( + tp_options: *mut OrtThreadingOptions, + ort_custom_thread_creation_options: *mut ::std::os::raw::c_void, + ) -> OrtStatusPtr, + >, + pub SetGlobalCustomJoinThreadFn: ::std::option::Option< + unsafe extern "C" fn( + tp_options: *mut OrtThreadingOptions, + ort_custom_join_thread_fn: OrtCustomJoinThreadFn, + ) -> OrtStatusPtr, + >, + pub SynchronizeBoundInputs: + ::std::option::Option OrtStatusPtr>, + pub SynchronizeBoundOutputs: + ::std::option::Option OrtStatusPtr>, + pub SessionOptionsAppendExecutionProvider_CUDA_V2: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + cuda_options: *const OrtCUDAProviderOptionsV2, + ) -> OrtStatusPtr, + >, + pub CreateCUDAProviderOptions: ::std::option::Option< + unsafe extern "C" fn(out: *mut *mut OrtCUDAProviderOptionsV2) -> OrtStatusPtr, + >, + pub UpdateCUDAProviderOptions: ::std::option::Option< + unsafe extern "C" fn( + cuda_options: *mut OrtCUDAProviderOptionsV2, + provider_options_keys: *const *const ::std::os::raw::c_char, + provider_options_values: *const *const ::std::os::raw::c_char, + num_keys: usize, + ) -> OrtStatusPtr, + >, + pub GetCUDAProviderOptionsAsString: ::std::option::Option< + unsafe extern "C" fn( + cuda_options: *const OrtCUDAProviderOptionsV2, + allocator: *mut OrtAllocator, + ptr: *mut *mut ::std::os::raw::c_char, + ) -> OrtStatusPtr, + >, + #[doc = " \\brief Release an ::OrtCUDAProviderOptionsV2"] + #[doc = ""] + #[doc = " \\note This is an exception in the naming convention of other Release* functions, as the name of the method does not have the V2 suffix, but the type does"] + #[doc = ""] + #[doc = " \\since Version 1.11."] + pub ReleaseCUDAProviderOptions: + ::std::option::Option, + pub SessionOptionsAppendExecutionProvider_MIGraphX: ::std::option::Option< + unsafe extern "C" fn( + options: *mut OrtSessionOptions, + migraphx_options: *const OrtMIGraphXProviderOptions, + ) -> OrtStatusPtr, + >, +} +#[test] +fn bindgen_test_layout_OrtApi() { assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateSessionWithPrepackedWeightsContainer - as *const _ as usize - }, - 1344usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateSessionWithPrepackedWeightsContainer) - ) + ::std::mem::size_of::(), + 1680usize, + concat!("Size of: ", stringify!(OrtApi)) ); assert_eq!( - unsafe { - &(*(::std::ptr::null::())).CreateSessionFromArrayWithPrepackedWeightsContainer - as *const _ as usize - }, - 1352usize, - concat!( - "Offset of field: ", - stringify!(OrtApi), - "::", - stringify!(CreateSessionFromArrayWithPrepackedWeightsContainer) - ) + ::std::mem::align_of::(), + 8usize, + concat!("Alignment of ", stringify!(OrtApi)) ); + fn test_field_CreateStatus() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateStatus) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateStatus) + ) + ); + } + test_field_CreateStatus(); + fn test_field_GetErrorCode() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetErrorCode) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetErrorCode) + ) + ); + } + test_field_GetErrorCode(); + fn test_field_GetErrorMessage() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetErrorMessage) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetErrorMessage) + ) + ); + } + test_field_GetErrorMessage(); + fn test_field_CreateEnv() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateEnv) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateEnv) + ) + ); + } + test_field_CreateEnv(); + fn test_field_CreateEnvWithCustomLogger() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateEnvWithCustomLogger) as usize - ptr as usize + }, + 32usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateEnvWithCustomLogger) + ) + ); + } + test_field_CreateEnvWithCustomLogger(); + fn test_field_EnableTelemetryEvents() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).EnableTelemetryEvents) as usize - ptr as usize + }, + 40usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(EnableTelemetryEvents) + ) + ); + } + test_field_EnableTelemetryEvents(); + fn test_field_DisableTelemetryEvents() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).DisableTelemetryEvents) as usize - ptr as usize + }, + 48usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(DisableTelemetryEvents) + ) + ); + } + test_field_DisableTelemetryEvents(); + fn test_field_CreateSession() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateSession) as usize - ptr as usize + }, + 56usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateSession) + ) + ); + } + test_field_CreateSession(); + fn test_field_CreateSessionFromArray() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateSessionFromArray) as usize - ptr as usize + }, + 64usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateSessionFromArray) + ) + ); + } + test_field_CreateSessionFromArray(); + fn test_field_Run() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).Run) as usize - ptr as usize + }, + 72usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(Run) + ) + ); + } + test_field_Run(); + fn test_field_CreateSessionOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateSessionOptions) as usize - ptr as usize + }, + 80usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateSessionOptions) + ) + ); + } + test_field_CreateSessionOptions(); + fn test_field_SetOptimizedModelFilePath() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetOptimizedModelFilePath) as usize - ptr as usize + }, + 88usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetOptimizedModelFilePath) + ) + ); + } + test_field_SetOptimizedModelFilePath(); + fn test_field_CloneSessionOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CloneSessionOptions) as usize - ptr as usize + }, + 96usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CloneSessionOptions) + ) + ); + } + test_field_CloneSessionOptions(); + fn test_field_SetSessionExecutionMode() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetSessionExecutionMode) as usize - ptr as usize + }, + 104usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetSessionExecutionMode) + ) + ); + } + test_field_SetSessionExecutionMode(); + fn test_field_EnableProfiling() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).EnableProfiling) as usize - ptr as usize + }, + 112usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(EnableProfiling) + ) + ); + } + test_field_EnableProfiling(); + fn test_field_DisableProfiling() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).DisableProfiling) as usize - ptr as usize + }, + 120usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(DisableProfiling) + ) + ); + } + test_field_DisableProfiling(); + fn test_field_EnableMemPattern() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).EnableMemPattern) as usize - ptr as usize + }, + 128usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(EnableMemPattern) + ) + ); + } + test_field_EnableMemPattern(); + fn test_field_DisableMemPattern() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).DisableMemPattern) as usize - ptr as usize + }, + 136usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(DisableMemPattern) + ) + ); + } + test_field_DisableMemPattern(); + fn test_field_EnableCpuMemArena() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).EnableCpuMemArena) as usize - ptr as usize + }, + 144usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(EnableCpuMemArena) + ) + ); + } + test_field_EnableCpuMemArena(); + fn test_field_DisableCpuMemArena() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).DisableCpuMemArena) as usize - ptr as usize + }, + 152usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(DisableCpuMemArena) + ) + ); + } + test_field_DisableCpuMemArena(); + fn test_field_SetSessionLogId() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetSessionLogId) as usize - ptr as usize + }, + 160usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetSessionLogId) + ) + ); + } + test_field_SetSessionLogId(); + fn test_field_SetSessionLogVerbosityLevel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetSessionLogVerbosityLevel) as usize - ptr as usize + }, + 168usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetSessionLogVerbosityLevel) + ) + ); + } + test_field_SetSessionLogVerbosityLevel(); + fn test_field_SetSessionLogSeverityLevel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetSessionLogSeverityLevel) as usize - ptr as usize + }, + 176usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetSessionLogSeverityLevel) + ) + ); + } + test_field_SetSessionLogSeverityLevel(); + fn test_field_SetSessionGraphOptimizationLevel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetSessionGraphOptimizationLevel) as usize + - ptr as usize + }, + 184usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetSessionGraphOptimizationLevel) + ) + ); + } + test_field_SetSessionGraphOptimizationLevel(); + fn test_field_SetIntraOpNumThreads() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetIntraOpNumThreads) as usize - ptr as usize + }, + 192usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetIntraOpNumThreads) + ) + ); + } + test_field_SetIntraOpNumThreads(); + fn test_field_SetInterOpNumThreads() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetInterOpNumThreads) as usize - ptr as usize + }, + 200usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetInterOpNumThreads) + ) + ); + } + test_field_SetInterOpNumThreads(); + fn test_field_CreateCustomOpDomain() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateCustomOpDomain) as usize - ptr as usize + }, + 208usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateCustomOpDomain) + ) + ); + } + test_field_CreateCustomOpDomain(); + fn test_field_CustomOpDomain_Add() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CustomOpDomain_Add) as usize - ptr as usize + }, + 216usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CustomOpDomain_Add) + ) + ); + } + test_field_CustomOpDomain_Add(); + fn test_field_AddCustomOpDomain() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AddCustomOpDomain) as usize - ptr as usize + }, + 224usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AddCustomOpDomain) + ) + ); + } + test_field_AddCustomOpDomain(); + fn test_field_RegisterCustomOpsLibrary() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RegisterCustomOpsLibrary) as usize - ptr as usize + }, + 232usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RegisterCustomOpsLibrary) + ) + ); + } + test_field_RegisterCustomOpsLibrary(); + fn test_field_SessionGetInputCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetInputCount) as usize - ptr as usize + }, + 240usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetInputCount) + ) + ); + } + test_field_SessionGetInputCount(); + fn test_field_SessionGetOutputCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetOutputCount) as usize - ptr as usize + }, + 248usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetOutputCount) + ) + ); + } + test_field_SessionGetOutputCount(); + fn test_field_SessionGetOverridableInitializerCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetOverridableInitializerCount) as usize + - ptr as usize + }, + 256usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetOverridableInitializerCount) + ) + ); + } + test_field_SessionGetOverridableInitializerCount(); + fn test_field_SessionGetInputTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetInputTypeInfo) as usize - ptr as usize + }, + 264usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetInputTypeInfo) + ) + ); + } + test_field_SessionGetInputTypeInfo(); + fn test_field_SessionGetOutputTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetOutputTypeInfo) as usize - ptr as usize + }, + 272usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetOutputTypeInfo) + ) + ); + } + test_field_SessionGetOutputTypeInfo(); + fn test_field_SessionGetOverridableInitializerTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetOverridableInitializerTypeInfo) as usize + - ptr as usize + }, + 280usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetOverridableInitializerTypeInfo) + ) + ); + } + test_field_SessionGetOverridableInitializerTypeInfo(); + fn test_field_SessionGetInputName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetInputName) as usize - ptr as usize + }, + 288usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetInputName) + ) + ); + } + test_field_SessionGetInputName(); + fn test_field_SessionGetOutputName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetOutputName) as usize - ptr as usize + }, + 296usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetOutputName) + ) + ); + } + test_field_SessionGetOutputName(); + fn test_field_SessionGetOverridableInitializerName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetOverridableInitializerName) as usize + - ptr as usize + }, + 304usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetOverridableInitializerName) + ) + ); + } + test_field_SessionGetOverridableInitializerName(); + fn test_field_CreateRunOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateRunOptions) as usize - ptr as usize + }, + 312usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateRunOptions) + ) + ); + } + test_field_CreateRunOptions(); + fn test_field_RunOptionsSetRunLogVerbosityLevel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsSetRunLogVerbosityLevel) as usize + - ptr as usize + }, + 320usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsSetRunLogVerbosityLevel) + ) + ); + } + test_field_RunOptionsSetRunLogVerbosityLevel(); + fn test_field_RunOptionsSetRunLogSeverityLevel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsSetRunLogSeverityLevel) as usize + - ptr as usize + }, + 328usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsSetRunLogSeverityLevel) + ) + ); + } + test_field_RunOptionsSetRunLogSeverityLevel(); + fn test_field_RunOptionsSetRunTag() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsSetRunTag) as usize - ptr as usize + }, + 336usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsSetRunTag) + ) + ); + } + test_field_RunOptionsSetRunTag(); + fn test_field_RunOptionsGetRunLogVerbosityLevel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsGetRunLogVerbosityLevel) as usize + - ptr as usize + }, + 344usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsGetRunLogVerbosityLevel) + ) + ); + } + test_field_RunOptionsGetRunLogVerbosityLevel(); + fn test_field_RunOptionsGetRunLogSeverityLevel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsGetRunLogSeverityLevel) as usize + - ptr as usize + }, + 352usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsGetRunLogSeverityLevel) + ) + ); + } + test_field_RunOptionsGetRunLogSeverityLevel(); + fn test_field_RunOptionsGetRunTag() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsGetRunTag) as usize - ptr as usize + }, + 360usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsGetRunTag) + ) + ); + } + test_field_RunOptionsGetRunTag(); + fn test_field_RunOptionsSetTerminate() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsSetTerminate) as usize - ptr as usize + }, + 368usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsSetTerminate) + ) + ); + } + test_field_RunOptionsSetTerminate(); + fn test_field_RunOptionsUnsetTerminate() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunOptionsUnsetTerminate) as usize - ptr as usize + }, + 376usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunOptionsUnsetTerminate) + ) + ); + } + test_field_RunOptionsUnsetTerminate(); + fn test_field_CreateTensorAsOrtValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateTensorAsOrtValue) as usize - ptr as usize + }, + 384usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateTensorAsOrtValue) + ) + ); + } + test_field_CreateTensorAsOrtValue(); + fn test_field_CreateTensorWithDataAsOrtValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateTensorWithDataAsOrtValue) as usize - ptr as usize + }, + 392usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateTensorWithDataAsOrtValue) + ) + ); + } + test_field_CreateTensorWithDataAsOrtValue(); + fn test_field_IsTensor() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).IsTensor) as usize - ptr as usize + }, + 400usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(IsTensor) + ) + ); + } + test_field_IsTensor(); + fn test_field_GetTensorMutableData() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetTensorMutableData) as usize - ptr as usize + }, + 408usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetTensorMutableData) + ) + ); + } + test_field_GetTensorMutableData(); + fn test_field_FillStringTensor() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).FillStringTensor) as usize - ptr as usize + }, + 416usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(FillStringTensor) + ) + ); + } + test_field_FillStringTensor(); + fn test_field_GetStringTensorDataLength() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetStringTensorDataLength) as usize - ptr as usize + }, + 424usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetStringTensorDataLength) + ) + ); + } + test_field_GetStringTensorDataLength(); + fn test_field_GetStringTensorContent() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetStringTensorContent) as usize - ptr as usize + }, + 432usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetStringTensorContent) + ) + ); + } + test_field_GetStringTensorContent(); + fn test_field_CastTypeInfoToTensorInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CastTypeInfoToTensorInfo) as usize - ptr as usize + }, + 440usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CastTypeInfoToTensorInfo) + ) + ); + } + test_field_CastTypeInfoToTensorInfo(); + fn test_field_GetOnnxTypeFromTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetOnnxTypeFromTypeInfo) as usize - ptr as usize + }, + 448usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetOnnxTypeFromTypeInfo) + ) + ); + } + test_field_GetOnnxTypeFromTypeInfo(); + fn test_field_CreateTensorTypeAndShapeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateTensorTypeAndShapeInfo) as usize - ptr as usize + }, + 456usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateTensorTypeAndShapeInfo) + ) + ); + } + test_field_CreateTensorTypeAndShapeInfo(); + fn test_field_SetTensorElementType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetTensorElementType) as usize - ptr as usize + }, + 464usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetTensorElementType) + ) + ); + } + test_field_SetTensorElementType(); + fn test_field_SetDimensions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetDimensions) as usize - ptr as usize + }, + 472usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetDimensions) + ) + ); + } + test_field_SetDimensions(); + fn test_field_GetTensorElementType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetTensorElementType) as usize - ptr as usize + }, + 480usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetTensorElementType) + ) + ); + } + test_field_GetTensorElementType(); + fn test_field_GetDimensionsCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetDimensionsCount) as usize - ptr as usize + }, + 488usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetDimensionsCount) + ) + ); + } + test_field_GetDimensionsCount(); + fn test_field_GetDimensions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetDimensions) as usize - ptr as usize + }, + 496usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetDimensions) + ) + ); + } + test_field_GetDimensions(); + fn test_field_GetSymbolicDimensions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetSymbolicDimensions) as usize - ptr as usize + }, + 504usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetSymbolicDimensions) + ) + ); + } + test_field_GetSymbolicDimensions(); + fn test_field_GetTensorShapeElementCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetTensorShapeElementCount) as usize - ptr as usize + }, + 512usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetTensorShapeElementCount) + ) + ); + } + test_field_GetTensorShapeElementCount(); + fn test_field_GetTensorTypeAndShape() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetTensorTypeAndShape) as usize - ptr as usize + }, + 520usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetTensorTypeAndShape) + ) + ); + } + test_field_GetTensorTypeAndShape(); + fn test_field_GetTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetTypeInfo) as usize - ptr as usize + }, + 528usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetTypeInfo) + ) + ); + } + test_field_GetTypeInfo(); + fn test_field_GetValueType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetValueType) as usize - ptr as usize + }, + 536usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetValueType) + ) + ); + } + test_field_GetValueType(); + fn test_field_CreateMemoryInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateMemoryInfo) as usize - ptr as usize + }, + 544usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateMemoryInfo) + ) + ); + } + test_field_CreateMemoryInfo(); + fn test_field_CreateCpuMemoryInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateCpuMemoryInfo) as usize - ptr as usize + }, + 552usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateCpuMemoryInfo) + ) + ); + } + test_field_CreateCpuMemoryInfo(); + fn test_field_CompareMemoryInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CompareMemoryInfo) as usize - ptr as usize + }, + 560usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CompareMemoryInfo) + ) + ); + } + test_field_CompareMemoryInfo(); + fn test_field_MemoryInfoGetName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).MemoryInfoGetName) as usize - ptr as usize + }, + 568usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(MemoryInfoGetName) + ) + ); + } + test_field_MemoryInfoGetName(); + fn test_field_MemoryInfoGetId() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).MemoryInfoGetId) as usize - ptr as usize + }, + 576usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(MemoryInfoGetId) + ) + ); + } + test_field_MemoryInfoGetId(); + fn test_field_MemoryInfoGetMemType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).MemoryInfoGetMemType) as usize - ptr as usize + }, + 584usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(MemoryInfoGetMemType) + ) + ); + } + test_field_MemoryInfoGetMemType(); + fn test_field_MemoryInfoGetType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).MemoryInfoGetType) as usize - ptr as usize + }, + 592usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(MemoryInfoGetType) + ) + ); + } + test_field_MemoryInfoGetType(); + fn test_field_AllocatorAlloc() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AllocatorAlloc) as usize - ptr as usize + }, + 600usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AllocatorAlloc) + ) + ); + } + test_field_AllocatorAlloc(); + fn test_field_AllocatorFree() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AllocatorFree) as usize - ptr as usize + }, + 608usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AllocatorFree) + ) + ); + } + test_field_AllocatorFree(); + fn test_field_AllocatorGetInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AllocatorGetInfo) as usize - ptr as usize + }, + 616usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AllocatorGetInfo) + ) + ); + } + test_field_AllocatorGetInfo(); + fn test_field_GetAllocatorWithDefaultOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetAllocatorWithDefaultOptions) as usize - ptr as usize + }, + 624usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetAllocatorWithDefaultOptions) + ) + ); + } + test_field_GetAllocatorWithDefaultOptions(); + fn test_field_AddFreeDimensionOverride() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AddFreeDimensionOverride) as usize - ptr as usize + }, + 632usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AddFreeDimensionOverride) + ) + ); + } + test_field_AddFreeDimensionOverride(); + fn test_field_GetValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetValue) as usize - ptr as usize + }, + 640usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetValue) + ) + ); + } + test_field_GetValue(); + fn test_field_GetValueCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetValueCount) as usize - ptr as usize + }, + 648usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetValueCount) + ) + ); + } + test_field_GetValueCount(); + fn test_field_CreateValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateValue) as usize - ptr as usize + }, + 656usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateValue) + ) + ); + } + test_field_CreateValue(); + fn test_field_CreateOpaqueValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateOpaqueValue) as usize - ptr as usize + }, + 664usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateOpaqueValue) + ) + ); + } + test_field_CreateOpaqueValue(); + fn test_field_GetOpaqueValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetOpaqueValue) as usize - ptr as usize + }, + 672usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetOpaqueValue) + ) + ); + } + test_field_GetOpaqueValue(); + fn test_field_KernelInfoGetAttribute_float() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelInfoGetAttribute_float) as usize - ptr as usize + }, + 680usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelInfoGetAttribute_float) + ) + ); + } + test_field_KernelInfoGetAttribute_float(); + fn test_field_KernelInfoGetAttribute_int64() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelInfoGetAttribute_int64) as usize - ptr as usize + }, + 688usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelInfoGetAttribute_int64) + ) + ); + } + test_field_KernelInfoGetAttribute_int64(); + fn test_field_KernelInfoGetAttribute_string() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelInfoGetAttribute_string) as usize - ptr as usize + }, + 696usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelInfoGetAttribute_string) + ) + ); + } + test_field_KernelInfoGetAttribute_string(); + fn test_field_KernelContext_GetInputCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelContext_GetInputCount) as usize - ptr as usize + }, + 704usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelContext_GetInputCount) + ) + ); + } + test_field_KernelContext_GetInputCount(); + fn test_field_KernelContext_GetOutputCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelContext_GetOutputCount) as usize - ptr as usize + }, + 712usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelContext_GetOutputCount) + ) + ); + } + test_field_KernelContext_GetOutputCount(); + fn test_field_KernelContext_GetInput() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelContext_GetInput) as usize - ptr as usize + }, + 720usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelContext_GetInput) + ) + ); + } + test_field_KernelContext_GetInput(); + fn test_field_KernelContext_GetOutput() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelContext_GetOutput) as usize - ptr as usize + }, + 728usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelContext_GetOutput) + ) + ); + } + test_field_KernelContext_GetOutput(); + fn test_field_ReleaseEnv() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseEnv) as usize - ptr as usize + }, + 736usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseEnv) + ) + ); + } + test_field_ReleaseEnv(); + fn test_field_ReleaseStatus() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseStatus) as usize - ptr as usize + }, + 744usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseStatus) + ) + ); + } + test_field_ReleaseStatus(); + fn test_field_ReleaseMemoryInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseMemoryInfo) as usize - ptr as usize + }, + 752usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseMemoryInfo) + ) + ); + } + test_field_ReleaseMemoryInfo(); + fn test_field_ReleaseSession() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseSession) as usize - ptr as usize + }, + 760usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseSession) + ) + ); + } + test_field_ReleaseSession(); + fn test_field_ReleaseValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseValue) as usize - ptr as usize + }, + 768usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseValue) + ) + ); + } + test_field_ReleaseValue(); + fn test_field_ReleaseRunOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseRunOptions) as usize - ptr as usize + }, + 776usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseRunOptions) + ) + ); + } + test_field_ReleaseRunOptions(); + fn test_field_ReleaseTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseTypeInfo) as usize - ptr as usize + }, + 784usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseTypeInfo) + ) + ); + } + test_field_ReleaseTypeInfo(); + fn test_field_ReleaseTensorTypeAndShapeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseTensorTypeAndShapeInfo) as usize - ptr as usize + }, + 792usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseTensorTypeAndShapeInfo) + ) + ); + } + test_field_ReleaseTensorTypeAndShapeInfo(); + fn test_field_ReleaseSessionOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseSessionOptions) as usize - ptr as usize + }, + 800usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseSessionOptions) + ) + ); + } + test_field_ReleaseSessionOptions(); + fn test_field_ReleaseCustomOpDomain() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseCustomOpDomain) as usize - ptr as usize + }, + 808usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseCustomOpDomain) + ) + ); + } + test_field_ReleaseCustomOpDomain(); + fn test_field_GetDenotationFromTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetDenotationFromTypeInfo) as usize - ptr as usize + }, + 816usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetDenotationFromTypeInfo) + ) + ); + } + test_field_GetDenotationFromTypeInfo(); + fn test_field_CastTypeInfoToMapTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CastTypeInfoToMapTypeInfo) as usize - ptr as usize + }, + 824usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CastTypeInfoToMapTypeInfo) + ) + ); + } + test_field_CastTypeInfoToMapTypeInfo(); + fn test_field_CastTypeInfoToSequenceTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CastTypeInfoToSequenceTypeInfo) as usize - ptr as usize + }, + 832usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CastTypeInfoToSequenceTypeInfo) + ) + ); + } + test_field_CastTypeInfoToSequenceTypeInfo(); + fn test_field_GetMapKeyType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetMapKeyType) as usize - ptr as usize + }, + 840usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetMapKeyType) + ) + ); + } + test_field_GetMapKeyType(); + fn test_field_GetMapValueType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetMapValueType) as usize - ptr as usize + }, + 848usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetMapValueType) + ) + ); + } + test_field_GetMapValueType(); + fn test_field_GetSequenceElementType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetSequenceElementType) as usize - ptr as usize + }, + 856usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetSequenceElementType) + ) + ); + } + test_field_GetSequenceElementType(); + fn test_field_ReleaseMapTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseMapTypeInfo) as usize - ptr as usize + }, + 864usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseMapTypeInfo) + ) + ); + } + test_field_ReleaseMapTypeInfo(); + fn test_field_ReleaseSequenceTypeInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseSequenceTypeInfo) as usize - ptr as usize + }, + 872usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseSequenceTypeInfo) + ) + ); + } + test_field_ReleaseSequenceTypeInfo(); + fn test_field_SessionEndProfiling() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionEndProfiling) as usize - ptr as usize + }, + 880usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionEndProfiling) + ) + ); + } + test_field_SessionEndProfiling(); + fn test_field_SessionGetModelMetadata() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetModelMetadata) as usize - ptr as usize + }, + 888usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetModelMetadata) + ) + ); + } + test_field_SessionGetModelMetadata(); + fn test_field_ModelMetadataGetProducerName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataGetProducerName) as usize - ptr as usize + }, + 896usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataGetProducerName) + ) + ); + } + test_field_ModelMetadataGetProducerName(); + fn test_field_ModelMetadataGetGraphName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataGetGraphName) as usize - ptr as usize + }, + 904usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataGetGraphName) + ) + ); + } + test_field_ModelMetadataGetGraphName(); + fn test_field_ModelMetadataGetDomain() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataGetDomain) as usize - ptr as usize + }, + 912usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataGetDomain) + ) + ); + } + test_field_ModelMetadataGetDomain(); + fn test_field_ModelMetadataGetDescription() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataGetDescription) as usize - ptr as usize + }, + 920usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataGetDescription) + ) + ); + } + test_field_ModelMetadataGetDescription(); + fn test_field_ModelMetadataLookupCustomMetadataMap() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataLookupCustomMetadataMap) as usize + - ptr as usize + }, + 928usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataLookupCustomMetadataMap) + ) + ); + } + test_field_ModelMetadataLookupCustomMetadataMap(); + fn test_field_ModelMetadataGetVersion() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataGetVersion) as usize - ptr as usize + }, + 936usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataGetVersion) + ) + ); + } + test_field_ModelMetadataGetVersion(); + fn test_field_ReleaseModelMetadata() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseModelMetadata) as usize - ptr as usize + }, + 944usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseModelMetadata) + ) + ); + } + test_field_ReleaseModelMetadata(); + fn test_field_CreateEnvWithGlobalThreadPools() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateEnvWithGlobalThreadPools) as usize - ptr as usize + }, + 952usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateEnvWithGlobalThreadPools) + ) + ); + } + test_field_CreateEnvWithGlobalThreadPools(); + fn test_field_DisablePerSessionThreads() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).DisablePerSessionThreads) as usize - ptr as usize + }, + 960usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(DisablePerSessionThreads) + ) + ); + } + test_field_DisablePerSessionThreads(); + fn test_field_CreateThreadingOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateThreadingOptions) as usize - ptr as usize + }, + 968usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateThreadingOptions) + ) + ); + } + test_field_CreateThreadingOptions(); + fn test_field_ReleaseThreadingOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseThreadingOptions) as usize - ptr as usize + }, + 976usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseThreadingOptions) + ) + ); + } + test_field_ReleaseThreadingOptions(); + fn test_field_ModelMetadataGetCustomMetadataMapKeys() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataGetCustomMetadataMapKeys) as usize + - ptr as usize + }, + 984usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataGetCustomMetadataMapKeys) + ) + ); + } + test_field_ModelMetadataGetCustomMetadataMapKeys(); + fn test_field_AddFreeDimensionOverrideByName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AddFreeDimensionOverrideByName) as usize - ptr as usize + }, + 992usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AddFreeDimensionOverrideByName) + ) + ); + } + test_field_AddFreeDimensionOverrideByName(); + fn test_field_GetAvailableProviders() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetAvailableProviders) as usize - ptr as usize + }, + 1000usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetAvailableProviders) + ) + ); + } + test_field_GetAvailableProviders(); + fn test_field_ReleaseAvailableProviders() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseAvailableProviders) as usize - ptr as usize + }, + 1008usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseAvailableProviders) + ) + ); + } + test_field_ReleaseAvailableProviders(); + fn test_field_GetStringTensorElementLength() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetStringTensorElementLength) as usize - ptr as usize + }, + 1016usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetStringTensorElementLength) + ) + ); + } + test_field_GetStringTensorElementLength(); + fn test_field_GetStringTensorElement() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetStringTensorElement) as usize - ptr as usize + }, + 1024usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetStringTensorElement) + ) + ); + } + test_field_GetStringTensorElement(); + fn test_field_FillStringTensorElement() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).FillStringTensorElement) as usize - ptr as usize + }, + 1032usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(FillStringTensorElement) + ) + ); + } + test_field_FillStringTensorElement(); + fn test_field_AddSessionConfigEntry() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AddSessionConfigEntry) as usize - ptr as usize + }, + 1040usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AddSessionConfigEntry) + ) + ); + } + test_field_AddSessionConfigEntry(); + fn test_field_CreateAllocator() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateAllocator) as usize - ptr as usize + }, + 1048usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateAllocator) + ) + ); + } + test_field_CreateAllocator(); + fn test_field_ReleaseAllocator() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseAllocator) as usize - ptr as usize + }, + 1056usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseAllocator) + ) + ); + } + test_field_ReleaseAllocator(); + fn test_field_RunWithBinding() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RunWithBinding) as usize - ptr as usize + }, + 1064usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RunWithBinding) + ) + ); + } + test_field_RunWithBinding(); + fn test_field_CreateIoBinding() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateIoBinding) as usize - ptr as usize + }, + 1072usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateIoBinding) + ) + ); + } + test_field_CreateIoBinding(); + fn test_field_ReleaseIoBinding() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseIoBinding) as usize - ptr as usize + }, + 1080usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseIoBinding) + ) + ); + } + test_field_ReleaseIoBinding(); + fn test_field_BindInput() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).BindInput) as usize - ptr as usize + }, + 1088usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(BindInput) + ) + ); + } + test_field_BindInput(); + fn test_field_BindOutput() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).BindOutput) as usize - ptr as usize + }, + 1096usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(BindOutput) + ) + ); + } + test_field_BindOutput(); + fn test_field_BindOutputToDevice() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).BindOutputToDevice) as usize - ptr as usize + }, + 1104usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(BindOutputToDevice) + ) + ); + } + test_field_BindOutputToDevice(); + fn test_field_GetBoundOutputNames() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetBoundOutputNames) as usize - ptr as usize + }, + 1112usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetBoundOutputNames) + ) + ); + } + test_field_GetBoundOutputNames(); + fn test_field_GetBoundOutputValues() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetBoundOutputValues) as usize - ptr as usize + }, + 1120usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetBoundOutputValues) + ) + ); + } + test_field_GetBoundOutputValues(); + fn test_field_ClearBoundInputs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ClearBoundInputs) as usize - ptr as usize + }, + 1128usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ClearBoundInputs) + ) + ); + } + test_field_ClearBoundInputs(); + fn test_field_ClearBoundOutputs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ClearBoundOutputs) as usize - ptr as usize + }, + 1136usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ClearBoundOutputs) + ) + ); + } + test_field_ClearBoundOutputs(); + fn test_field_TensorAt() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).TensorAt) as usize - ptr as usize + }, + 1144usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(TensorAt) + ) + ); + } + test_field_TensorAt(); + fn test_field_CreateAndRegisterAllocator() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateAndRegisterAllocator) as usize - ptr as usize + }, + 1152usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateAndRegisterAllocator) + ) + ); + } + test_field_CreateAndRegisterAllocator(); + fn test_field_SetLanguageProjection() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetLanguageProjection) as usize - ptr as usize + }, + 1160usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetLanguageProjection) + ) + ); + } + test_field_SetLanguageProjection(); + fn test_field_SessionGetProfilingStartTimeNs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionGetProfilingStartTimeNs) as usize - ptr as usize + }, + 1168usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionGetProfilingStartTimeNs) + ) + ); + } + test_field_SessionGetProfilingStartTimeNs(); + fn test_field_SetGlobalIntraOpNumThreads() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetGlobalIntraOpNumThreads) as usize - ptr as usize + }, + 1176usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetGlobalIntraOpNumThreads) + ) + ); + } + test_field_SetGlobalIntraOpNumThreads(); + fn test_field_SetGlobalInterOpNumThreads() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetGlobalInterOpNumThreads) as usize - ptr as usize + }, + 1184usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetGlobalInterOpNumThreads) + ) + ); + } + test_field_SetGlobalInterOpNumThreads(); + fn test_field_SetGlobalSpinControl() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetGlobalSpinControl) as usize - ptr as usize + }, + 1192usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetGlobalSpinControl) + ) + ); + } + test_field_SetGlobalSpinControl(); + fn test_field_AddInitializer() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AddInitializer) as usize - ptr as usize + }, + 1200usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AddInitializer) + ) + ); + } + test_field_AddInitializer(); + fn test_field_CreateEnvWithCustomLoggerAndGlobalThreadPools() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateEnvWithCustomLoggerAndGlobalThreadPools) as usize + - ptr as usize + }, + 1208usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateEnvWithCustomLoggerAndGlobalThreadPools) + ) + ); + } + test_field_CreateEnvWithCustomLoggerAndGlobalThreadPools(); + fn test_field_SessionOptionsAppendExecutionProvider_CUDA() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsAppendExecutionProvider_CUDA) as usize + - ptr as usize + }, + 1216usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsAppendExecutionProvider_CUDA) + ) + ); + } + test_field_SessionOptionsAppendExecutionProvider_CUDA(); + fn test_field_SessionOptionsAppendExecutionProvider_ROCM() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsAppendExecutionProvider_ROCM) as usize + - ptr as usize + }, + 1224usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsAppendExecutionProvider_ROCM) + ) + ); + } + test_field_SessionOptionsAppendExecutionProvider_ROCM(); + fn test_field_SessionOptionsAppendExecutionProvider_OpenVINO() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsAppendExecutionProvider_OpenVINO) as usize + - ptr as usize + }, + 1232usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsAppendExecutionProvider_OpenVINO) + ) + ); + } + test_field_SessionOptionsAppendExecutionProvider_OpenVINO(); + fn test_field_SetGlobalDenormalAsZero() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetGlobalDenormalAsZero) as usize - ptr as usize + }, + 1240usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetGlobalDenormalAsZero) + ) + ); + } + test_field_SetGlobalDenormalAsZero(); + fn test_field_CreateArenaCfg() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateArenaCfg) as usize - ptr as usize + }, + 1248usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateArenaCfg) + ) + ); + } + test_field_CreateArenaCfg(); + fn test_field_ReleaseArenaCfg() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseArenaCfg) as usize - ptr as usize + }, + 1256usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseArenaCfg) + ) + ); + } + test_field_ReleaseArenaCfg(); + fn test_field_ModelMetadataGetGraphDescription() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ModelMetadataGetGraphDescription) as usize + - ptr as usize + }, + 1264usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ModelMetadataGetGraphDescription) + ) + ); + } + test_field_ModelMetadataGetGraphDescription(); + fn test_field_SessionOptionsAppendExecutionProvider_TensorRT() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsAppendExecutionProvider_TensorRT) as usize + - ptr as usize + }, + 1272usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsAppendExecutionProvider_TensorRT) + ) + ); + } + test_field_SessionOptionsAppendExecutionProvider_TensorRT(); + fn test_field_SetCurrentGpuDeviceId() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetCurrentGpuDeviceId) as usize - ptr as usize + }, + 1280usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetCurrentGpuDeviceId) + ) + ); + } + test_field_SetCurrentGpuDeviceId(); + fn test_field_GetCurrentGpuDeviceId() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetCurrentGpuDeviceId) as usize - ptr as usize + }, + 1288usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetCurrentGpuDeviceId) + ) + ); + } + test_field_GetCurrentGpuDeviceId(); + fn test_field_KernelInfoGetAttributeArray_float() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelInfoGetAttributeArray_float) as usize + - ptr as usize + }, + 1296usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelInfoGetAttributeArray_float) + ) + ); + } + test_field_KernelInfoGetAttributeArray_float(); + fn test_field_KernelInfoGetAttributeArray_int64() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelInfoGetAttributeArray_int64) as usize + - ptr as usize + }, + 1304usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelInfoGetAttributeArray_int64) + ) + ); + } + test_field_KernelInfoGetAttributeArray_int64(); + fn test_field_CreateArenaCfgV2() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateArenaCfgV2) as usize - ptr as usize + }, + 1312usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateArenaCfgV2) + ) + ); + } + test_field_CreateArenaCfgV2(); + fn test_field_AddRunConfigEntry() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).AddRunConfigEntry) as usize - ptr as usize + }, + 1320usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(AddRunConfigEntry) + ) + ); + } + test_field_AddRunConfigEntry(); + fn test_field_CreatePrepackedWeightsContainer() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreatePrepackedWeightsContainer) as usize - ptr as usize + }, + 1328usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreatePrepackedWeightsContainer) + ) + ); + } + test_field_CreatePrepackedWeightsContainer(); + fn test_field_ReleasePrepackedWeightsContainer() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleasePrepackedWeightsContainer) as usize + - ptr as usize + }, + 1336usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleasePrepackedWeightsContainer) + ) + ); + } + test_field_ReleasePrepackedWeightsContainer(); + fn test_field_CreateSessionWithPrepackedWeightsContainer() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateSessionWithPrepackedWeightsContainer) as usize + - ptr as usize + }, + 1344usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateSessionWithPrepackedWeightsContainer) + ) + ); + } + test_field_CreateSessionWithPrepackedWeightsContainer(); + fn test_field_CreateSessionFromArrayWithPrepackedWeightsContainer() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateSessionFromArrayWithPrepackedWeightsContainer) + as usize + - ptr as usize + }, + 1352usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateSessionFromArrayWithPrepackedWeightsContainer) + ) + ); + } + test_field_CreateSessionFromArrayWithPrepackedWeightsContainer(); + fn test_field_SessionOptionsAppendExecutionProvider_TensorRT_V2() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsAppendExecutionProvider_TensorRT_V2) + as usize + - ptr as usize + }, + 1360usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsAppendExecutionProvider_TensorRT_V2) + ) + ); + } + test_field_SessionOptionsAppendExecutionProvider_TensorRT_V2(); + fn test_field_CreateTensorRTProviderOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateTensorRTProviderOptions) as usize - ptr as usize + }, + 1368usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateTensorRTProviderOptions) + ) + ); + } + test_field_CreateTensorRTProviderOptions(); + fn test_field_UpdateTensorRTProviderOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).UpdateTensorRTProviderOptions) as usize - ptr as usize + }, + 1376usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(UpdateTensorRTProviderOptions) + ) + ); + } + test_field_UpdateTensorRTProviderOptions(); + fn test_field_GetTensorRTProviderOptionsAsString() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetTensorRTProviderOptionsAsString) as usize + - ptr as usize + }, + 1384usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetTensorRTProviderOptionsAsString) + ) + ); + } + test_field_GetTensorRTProviderOptionsAsString(); + fn test_field_ReleaseTensorRTProviderOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseTensorRTProviderOptions) as usize - ptr as usize + }, + 1392usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseTensorRTProviderOptions) + ) + ); + } + test_field_ReleaseTensorRTProviderOptions(); + fn test_field_EnableOrtCustomOps() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).EnableOrtCustomOps) as usize - ptr as usize + }, + 1400usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(EnableOrtCustomOps) + ) + ); + } + test_field_EnableOrtCustomOps(); + fn test_field_RegisterAllocator() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).RegisterAllocator) as usize - ptr as usize + }, + 1408usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(RegisterAllocator) + ) + ); + } + test_field_RegisterAllocator(); + fn test_field_UnregisterAllocator() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).UnregisterAllocator) as usize - ptr as usize + }, + 1416usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(UnregisterAllocator) + ) + ); + } + test_field_UnregisterAllocator(); + fn test_field_IsSparseTensor() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).IsSparseTensor) as usize - ptr as usize + }, + 1424usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(IsSparseTensor) + ) + ); + } + test_field_IsSparseTensor(); + fn test_field_CreateSparseTensorAsOrtValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateSparseTensorAsOrtValue) as usize - ptr as usize + }, + 1432usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateSparseTensorAsOrtValue) + ) + ); + } + test_field_CreateSparseTensorAsOrtValue(); + fn test_field_FillSparseTensorCoo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).FillSparseTensorCoo) as usize - ptr as usize + }, + 1440usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(FillSparseTensorCoo) + ) + ); + } + test_field_FillSparseTensorCoo(); + fn test_field_FillSparseTensorCsr() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).FillSparseTensorCsr) as usize - ptr as usize + }, + 1448usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(FillSparseTensorCsr) + ) + ); + } + test_field_FillSparseTensorCsr(); + fn test_field_FillSparseTensorBlockSparse() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).FillSparseTensorBlockSparse) as usize - ptr as usize + }, + 1456usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(FillSparseTensorBlockSparse) + ) + ); + } + test_field_FillSparseTensorBlockSparse(); + fn test_field_CreateSparseTensorWithValuesAsOrtValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateSparseTensorWithValuesAsOrtValue) as usize + - ptr as usize + }, + 1464usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateSparseTensorWithValuesAsOrtValue) + ) + ); + } + test_field_CreateSparseTensorWithValuesAsOrtValue(); + fn test_field_UseCooIndices() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).UseCooIndices) as usize - ptr as usize + }, + 1472usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(UseCooIndices) + ) + ); + } + test_field_UseCooIndices(); + fn test_field_UseCsrIndices() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).UseCsrIndices) as usize - ptr as usize + }, + 1480usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(UseCsrIndices) + ) + ); + } + test_field_UseCsrIndices(); + fn test_field_UseBlockSparseIndices() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).UseBlockSparseIndices) as usize - ptr as usize + }, + 1488usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(UseBlockSparseIndices) + ) + ); + } + test_field_UseBlockSparseIndices(); + fn test_field_GetSparseTensorFormat() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetSparseTensorFormat) as usize - ptr as usize + }, + 1496usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetSparseTensorFormat) + ) + ); + } + test_field_GetSparseTensorFormat(); + fn test_field_GetSparseTensorValuesTypeAndShape() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetSparseTensorValuesTypeAndShape) as usize + - ptr as usize + }, + 1504usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetSparseTensorValuesTypeAndShape) + ) + ); + } + test_field_GetSparseTensorValuesTypeAndShape(); + fn test_field_GetSparseTensorValues() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetSparseTensorValues) as usize - ptr as usize + }, + 1512usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetSparseTensorValues) + ) + ); + } + test_field_GetSparseTensorValues(); + fn test_field_GetSparseTensorIndicesTypeShape() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetSparseTensorIndicesTypeShape) as usize - ptr as usize + }, + 1520usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetSparseTensorIndicesTypeShape) + ) + ); + } + test_field_GetSparseTensorIndicesTypeShape(); + fn test_field_GetSparseTensorIndices() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetSparseTensorIndices) as usize - ptr as usize + }, + 1528usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetSparseTensorIndices) + ) + ); + } + test_field_GetSparseTensorIndices(); + fn test_field_HasValue() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).HasValue) as usize - ptr as usize + }, + 1536usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(HasValue) + ) + ); + } + test_field_HasValue(); + fn test_field_KernelContext_GetGPUComputeStream() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelContext_GetGPUComputeStream) as usize + - ptr as usize + }, + 1544usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(KernelContext_GetGPUComputeStream) + ) + ); + } + test_field_KernelContext_GetGPUComputeStream(); + fn test_field_GetTensorMemoryInfo() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetTensorMemoryInfo) as usize - ptr as usize + }, + 1552usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetTensorMemoryInfo) + ) + ); + } + test_field_GetTensorMemoryInfo(); + fn test_field_GetExecutionProviderApi() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetExecutionProviderApi) as usize - ptr as usize + }, + 1560usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetExecutionProviderApi) + ) + ); + } + test_field_GetExecutionProviderApi(); + fn test_field_SessionOptionsSetCustomCreateThreadFn() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsSetCustomCreateThreadFn) as usize + - ptr as usize + }, + 1568usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsSetCustomCreateThreadFn) + ) + ); + } + test_field_SessionOptionsSetCustomCreateThreadFn(); + fn test_field_SessionOptionsSetCustomThreadCreationOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsSetCustomThreadCreationOptions) as usize + - ptr as usize + }, + 1576usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsSetCustomThreadCreationOptions) + ) + ); + } + test_field_SessionOptionsSetCustomThreadCreationOptions(); + fn test_field_SessionOptionsSetCustomJoinThreadFn() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsSetCustomJoinThreadFn) as usize + - ptr as usize + }, + 1584usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsSetCustomJoinThreadFn) + ) + ); + } + test_field_SessionOptionsSetCustomJoinThreadFn(); + fn test_field_SetGlobalCustomCreateThreadFn() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetGlobalCustomCreateThreadFn) as usize - ptr as usize + }, + 1592usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetGlobalCustomCreateThreadFn) + ) + ); + } + test_field_SetGlobalCustomCreateThreadFn(); + fn test_field_SetGlobalCustomThreadCreationOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetGlobalCustomThreadCreationOptions) as usize + - ptr as usize + }, + 1600usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetGlobalCustomThreadCreationOptions) + ) + ); + } + test_field_SetGlobalCustomThreadCreationOptions(); + fn test_field_SetGlobalCustomJoinThreadFn() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SetGlobalCustomJoinThreadFn) as usize - ptr as usize + }, + 1608usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SetGlobalCustomJoinThreadFn) + ) + ); + } + test_field_SetGlobalCustomJoinThreadFn(); + fn test_field_SynchronizeBoundInputs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SynchronizeBoundInputs) as usize - ptr as usize + }, + 1616usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SynchronizeBoundInputs) + ) + ); + } + test_field_SynchronizeBoundInputs(); + fn test_field_SynchronizeBoundOutputs() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SynchronizeBoundOutputs) as usize - ptr as usize + }, + 1624usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SynchronizeBoundOutputs) + ) + ); + } + test_field_SynchronizeBoundOutputs(); + fn test_field_SessionOptionsAppendExecutionProvider_CUDA_V2() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsAppendExecutionProvider_CUDA_V2) as usize + - ptr as usize + }, + 1632usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsAppendExecutionProvider_CUDA_V2) + ) + ); + } + test_field_SessionOptionsAppendExecutionProvider_CUDA_V2(); + fn test_field_CreateCUDAProviderOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateCUDAProviderOptions) as usize - ptr as usize + }, + 1640usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(CreateCUDAProviderOptions) + ) + ); + } + test_field_CreateCUDAProviderOptions(); + fn test_field_UpdateCUDAProviderOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).UpdateCUDAProviderOptions) as usize - ptr as usize + }, + 1648usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(UpdateCUDAProviderOptions) + ) + ); + } + test_field_UpdateCUDAProviderOptions(); + fn test_field_GetCUDAProviderOptionsAsString() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetCUDAProviderOptionsAsString) as usize - ptr as usize + }, + 1656usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(GetCUDAProviderOptionsAsString) + ) + ); + } + test_field_GetCUDAProviderOptionsAsString(); + fn test_field_ReleaseCUDAProviderOptions() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).ReleaseCUDAProviderOptions) as usize - ptr as usize + }, + 1664usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(ReleaseCUDAProviderOptions) + ) + ); + } + test_field_ReleaseCUDAProviderOptions(); + fn test_field_SessionOptionsAppendExecutionProvider_MIGraphX() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).SessionOptionsAppendExecutionProvider_MIGraphX) as usize + - ptr as usize + }, + 1672usize, + concat!( + "Offset of field: ", + stringify!(OrtApi), + "::", + stringify!(SessionOptionsAppendExecutionProvider_MIGraphX) + ) + ); + } + test_field_SessionOptionsAppendExecutionProvider_MIGraphX(); } #[repr(i32)] #[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] @@ -6499,132 +9229,222 @@ fn bindgen_test_layout_OrtCustomOp() { 8usize, concat!("Alignment of ", stringify!(OrtCustomOp)) ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).version as *const _ as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(version) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).CreateKernel as *const _ as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(CreateKernel) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetName as *const _ as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetName) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetExecutionProviderType as *const _ as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetExecutionProviderType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetInputType as *const _ as usize }, - 32usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetInputType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetInputTypeCount as *const _ as usize }, - 40usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetInputTypeCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetOutputType as *const _ as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetOutputType) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).GetOutputTypeCount as *const _ as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetOutputTypeCount) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).KernelCompute as *const _ as usize }, - 64usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(KernelCompute) - ) - ); - assert_eq!( - unsafe { &(*(::std::ptr::null::())).KernelDestroy as *const _ as usize }, - 72usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(KernelDestroy) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetInputCharacteristic as *const _ as usize - }, - 80usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetInputCharacteristic) - ) - ); - assert_eq!( - unsafe { - &(*(::std::ptr::null::())).GetOutputCharacteristic as *const _ as usize - }, - 88usize, - concat!( - "Offset of field: ", - stringify!(OrtCustomOp), - "::", - stringify!(GetOutputCharacteristic) - ) - ); + fn test_field_version() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).version) as usize - ptr as usize + }, + 0usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(version) + ) + ); + } + test_field_version(); + fn test_field_CreateKernel() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).CreateKernel) as usize - ptr as usize + }, + 8usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(CreateKernel) + ) + ); + } + test_field_CreateKernel(); + fn test_field_GetName() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetName) as usize - ptr as usize + }, + 16usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetName) + ) + ); + } + test_field_GetName(); + fn test_field_GetExecutionProviderType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetExecutionProviderType) as usize - ptr as usize + }, + 24usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetExecutionProviderType) + ) + ); + } + test_field_GetExecutionProviderType(); + fn test_field_GetInputType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetInputType) as usize - ptr as usize + }, + 32usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetInputType) + ) + ); + } + test_field_GetInputType(); + fn test_field_GetInputTypeCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetInputTypeCount) as usize - ptr as usize + }, + 40usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetInputTypeCount) + ) + ); + } + test_field_GetInputTypeCount(); + fn test_field_GetOutputType() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetOutputType) as usize - ptr as usize + }, + 48usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetOutputType) + ) + ); + } + test_field_GetOutputType(); + fn test_field_GetOutputTypeCount() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetOutputTypeCount) as usize - ptr as usize + }, + 56usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetOutputTypeCount) + ) + ); + } + test_field_GetOutputTypeCount(); + fn test_field_KernelCompute() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelCompute) as usize - ptr as usize + }, + 64usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(KernelCompute) + ) + ); + } + test_field_KernelCompute(); + fn test_field_KernelDestroy() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).KernelDestroy) as usize - ptr as usize + }, + 72usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(KernelDestroy) + ) + ); + } + test_field_KernelDestroy(); + fn test_field_GetInputCharacteristic() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetInputCharacteristic) as usize - ptr as usize + }, + 80usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetInputCharacteristic) + ) + ); + } + test_field_GetInputCharacteristic(); + fn test_field_GetOutputCharacteristic() { + assert_eq!( + unsafe { + let uninit = ::std::mem::MaybeUninit::::uninit(); + let ptr = uninit.as_ptr(); + ::std::ptr::addr_of!((*ptr).GetOutputCharacteristic) as usize - ptr as usize + }, + 88usize, + concat!( + "Offset of field: ", + stringify!(OrtCustomOp), + "::", + stringify!(GetOutputCharacteristic) + ) + ); + } + test_field_GetOutputCharacteristic(); +} +extern "C" { + pub fn OrtSessionOptionsAppendExecutionProvider_CUDA( + options: *mut OrtSessionOptions, + device_id: ::std::os::raw::c_int, + ) -> OrtStatusPtr; +} +extern "C" { + pub fn OrtSessionOptionsAppendExecutionProvider_MIGraphX( + options: *mut OrtSessionOptions, + device_id: ::std::os::raw::c_int, + ) -> OrtStatusPtr; } #[repr(C)] #[derive(Debug, Copy, Clone)] diff --git a/onnxruntime-sys/src/lib.rs b/onnxruntime-sys/src/lib.rs index 62941a6b..6ad81cd4 100644 --- a/onnxruntime-sys/src/lib.rs +++ b/onnxruntime-sys/src/lib.rs @@ -5,8 +5,6 @@ #![allow(clippy::all)] #![allow(improper_ctypes)] -#[allow(clippy::all)] - include!(concat!( env!("CARGO_MANIFEST_DIR"), "/src/generated/bindings.rs" diff --git a/onnxruntime/Cargo.toml b/onnxruntime/Cargo.toml index 8dd12d00..73712b7c 100644 --- a/onnxruntime/Cargo.toml +++ b/onnxruntime/Cargo.toml @@ -31,7 +31,7 @@ ureq = { version = "2.1", optional = true } [dev-dependencies] image = "0.23" -test-env-log = { version = "0.2", default-features = false, features = ["trace"] } +test-log = { version = "0.2", default-features = false, features = ["trace"] } tracing-subscriber = "0.2" ureq = "2.1" diff --git a/onnxruntime/examples/sample.rs b/onnxruntime/examples/sample.rs index d16d08da..ac15c1bf 100644 --- a/onnxruntime/examples/sample.rs +++ b/onnxruntime/examples/sample.rs @@ -38,7 +38,7 @@ fn run() -> Result<(), Error> { // NOTE: The example uses SqueezeNet 1.0 (ONNX version: 1.3, Opset version: 8), // _not_ SqueezeNet 1.1 as downloaded by '.with_model_downloaded(ImageClassification::SqueezeNet)' // Obtain it with: - // curl -LO "https://github.com/onnx/models/raw/master/vision/classification/squeezenet/model/squeezenet1.0-8.onnx" + // curl -LO "https://github.com/onnx/models/raw/main/vision/classification/squeezenet/model/squeezenet1.0-8.onnx" .with_model_from_file("squeezenet1.0-8.onnx")?; let input0_shape: Vec = session.inputs[0].dimensions().map(|d| d.unwrap()).collect(); diff --git a/onnxruntime/src/download/language/machine_comprehension.rs b/onnxruntime/src/download/language/machine_comprehension.rs index a32d0076..76143aac 100644 --- a/onnxruntime/src/download/language/machine_comprehension.rs +++ b/onnxruntime/src/download/language/machine_comprehension.rs @@ -18,13 +18,13 @@ pub enum MachineComprehension { /// /// > This model is a neural network for answering a query about a given context paragraph. /// - /// Source: [https://github.com/onnx/models/tree/master/text/machine_comprehension/bidirectional_attention_flow](https://github.com/onnx/models/tree/master/text/machine_comprehension/bidirectional_attention_flow) + /// Source: [https://github.com/onnx/models/tree/main/text/machine_comprehension/bidirectional_attention_flow](https://github.com/onnx/models/tree/main/text/machine_comprehension/bidirectional_attention_flow) /// /// Variant downloaded: ONNX Version 1.4 with Opset Version 9. BiDAF, /// Answers questions based on the context of the given input paragraph. /// - /// Source: [https://github.com/onnx/models/tree/master/text/machine_comprehension/bert-squad](https://github.com/onnx/models/tree/master/text/machine_comprehension/bert-squad) + /// Source: [https://github.com/onnx/models/tree/main/text/machine_comprehension/bert-squad](https://github.com/onnx/models/tree/main/text/machine_comprehension/bert-squad) /// /// Variant downloaded: ONNX Version 1.5 with Opset Version 10. BERTSquad, @@ -32,11 +32,11 @@ pub enum MachineComprehension { /// /// > Transformer-based language model for text generation. /// - /// Source: [https://github.com/onnx/models/tree/master/text/machine_comprehension/roberta](https://github.com/onnx/models/tree/master/text/machine_comprehension/roberta) + /// Source: [https://github.com/onnx/models/tree/main/text/machine_comprehension/roberta](https://github.com/onnx/models/tree/main/text/machine_comprehension/roberta) RoBERTa(RoBERTa), /// Large transformer-based language model that given a sequence of words within some text, predicts the next word. /// - /// Source: [https://github.com/onnx/models/tree/master/text/machine_comprehension/gpt-2](https://github.com/onnx/models/tree/master/text/machine_comprehension/gpt-2) + /// Source: [https://github.com/onnx/models/tree/main/text/machine_comprehension/gpt-2](https://github.com/onnx/models/tree/main/text/machine_comprehension/gpt-2) GPT2(GPT2), } @@ -44,7 +44,7 @@ pub enum MachineComprehension { /// /// > Transformer-based language model for text generation. /// -/// Source: [https://github.com/onnx/models/tree/master/text/machine_comprehension/roberta](https://github.com/onnx/models/tree/master/text/machine_comprehension/roberta) +/// Source: [https://github.com/onnx/models/tree/main/text/machine_comprehension/roberta](https://github.com/onnx/models/tree/main/text/machine_comprehension/roberta) #[derive(Debug, Clone)] pub enum RoBERTa { /// Variant with input is a sequence of words as a string. Example: "Text to encode: Hello, World" @@ -61,7 +61,7 @@ pub enum RoBERTa { /// /// > Transformer-based language model for text generation. /// -/// Source: [https://github.com/onnx/models/tree/master/text/machine_comprehension/gpt-2](https://github.com/onnx/models/tree/master/text/machine_comprehension/gpt-2) +/// Source: [https://github.com/onnx/models/tree/main/text/machine_comprehension/gpt-2](https://github.com/onnx/models/tree/main/text/machine_comprehension/gpt-2) /// /// Variant downloaded: ONNX Version 1.6 with Opset Version 10. #[derive(Debug, Clone)] @@ -70,7 +70,7 @@ pub enum GPT2 { GPT2, /// GPT2 + script changes /// - /// See [https://github.com/onnx/models/blob/master/text/machine_comprehension/gpt-2/dependencies/GPT2-export.py](https://github.com/onnx/models/blob/master/text/machine_comprehension/gpt-2/dependencies/GPT2-export.py) + /// See [https://github.com/onnx/models/blob/main/text/machine_comprehension/gpt-2/dependencies/GPT2-export.py](https://github.com/onnx/models/blob/main/text/machine_comprehension/gpt-2/dependencies/GPT2-export.py) /// for the script changes. GPT2LmHead, } @@ -78,8 +78,8 @@ pub enum GPT2 { impl ModelUrl for MachineComprehension { fn fetch_url(&self) -> &'static str { match self { - MachineComprehension::BiDAF => "https://github.com/onnx/models/raw/master/text/machine_comprehension/bidirectional_attention_flow/model/bidaf-9.onnx", - MachineComprehension::BERTSquad => "https://github.com/onnx/models/raw/master/text/machine_comprehension/bert-squad/model/bertsquad-10.onnx", + MachineComprehension::BiDAF => "https://github.com/onnx/models/raw/main/text/machine_comprehension/bidirectional_attention_flow/model/bidaf-9.onnx", + MachineComprehension::BERTSquad => "https://github.com/onnx/models/raw/main/text/machine_comprehension/bert-squad/model/bertsquad-10.onnx", MachineComprehension::RoBERTa(variant) => variant.fetch_url(), MachineComprehension::GPT2(variant) => variant.fetch_url(), } @@ -89,8 +89,8 @@ impl ModelUrl for MachineComprehension { impl ModelUrl for RoBERTa { fn fetch_url(&self) -> &'static str { match self { - RoBERTa::RoBERTaBase => "https://github.com/onnx/models/raw/master/text/machine_comprehension/roberta/model/roberta-base-11.onnx", - RoBERTa::RoBERTaSequenceClassification => "https://github.com/onnx/models/raw/master/text/machine_comprehension/roberta/model/roberta-sequence-classification-9.onnx", + RoBERTa::RoBERTaBase => "https://github.com/onnx/models/raw/main/text/machine_comprehension/roberta/model/roberta-base-11.onnx", + RoBERTa::RoBERTaSequenceClassification => "https://github.com/onnx/models/raw/main/text/machine_comprehension/roberta/model/roberta-sequence-classification-9.onnx", } } } @@ -98,8 +98,8 @@ impl ModelUrl for RoBERTa { impl ModelUrl for GPT2 { fn fetch_url(&self) -> &'static str { match self { - GPT2::GPT2 => "https://github.com/onnx/models/raw/master/text/machine_comprehension/gpt-2/model/gpt2-10.onnx", - GPT2::GPT2LmHead => "https://github.com/onnx/models/raw/master/text/machine_comprehension/gpt-2/model/gpt2-lm-head-10.onnx", + GPT2::GPT2 => "https://github.com/onnx/models/raw/main/text/machine_comprehension/gpt-2/model/gpt2-10.onnx", + GPT2::GPT2LmHead => "https://github.com/onnx/models/raw/main/text/machine_comprehension/gpt-2/model/gpt2-lm-head-10.onnx", } } } diff --git a/onnxruntime/src/download/vision/body_face_gesture_analysis.rs b/onnxruntime/src/download/vision/body_face_gesture_analysis.rs index 9823caaf..1916f857 100644 --- a/onnxruntime/src/download/vision/body_face_gesture_analysis.rs +++ b/onnxruntime/src/download/vision/body_face_gesture_analysis.rs @@ -15,13 +15,13 @@ pub enum BodyFaceGestureAnalysis { /// A CNN based model for face recognition which learns discriminative features of faces and produces /// embeddings for input face images. /// - /// Source: [https://github.com/onnx/models/tree/master/vision/body_analysis/arcface](https://github.com/onnx/models/tree/master/vision/body_analysis/arcface) + /// Source: [https://github.com/onnx/models/tree/main/vision/body_analysis/arcface](https://github.com/onnx/models/tree/main/vision/body_analysis/arcface) /// /// Variant downloaded: ONNX Version 1.3 with Opset Version 8. ArcFace, /// Deep CNN for emotion recognition trained on images of faces. /// - /// Source: [https://github.com/onnx/models/tree/master/vision/body_analysis/emotion_ferplus](https://github.com/onnx/models/tree/master/vision/body_analysis/emotion_ferplus) + /// Source: [https://github.com/onnx/models/tree/main/vision/body_analysis/emotion_ferplus](https://github.com/onnx/models/tree/main/vision/body_analysis/emotion_ferplus) /// /// Variant downloaded: ONNX Version 1.3 with Opset Version 8. EmotionFerPlus, @@ -30,8 +30,8 @@ pub enum BodyFaceGestureAnalysis { impl ModelUrl for BodyFaceGestureAnalysis { fn fetch_url(&self) -> &'static str { match self { - BodyFaceGestureAnalysis::ArcFace => "https://github.com/onnx/models/raw/master/vision/body_analysis/arcface/model/arcfaceresnet100-8.onnx", - BodyFaceGestureAnalysis::EmotionFerPlus => "https://github.com/onnx/models/raw/master/vision/body_analysis/emotion_ferplus/model/emotion-ferplus-8.onnx", + BodyFaceGestureAnalysis::ArcFace => "https://github.com/onnx/models/raw/main/vision/body_analysis/arcface/model/arcfaceresnet100-8.onnx", + BodyFaceGestureAnalysis::EmotionFerPlus => "https://github.com/onnx/models/raw/main/vision/body_analysis/emotion_ferplus/model/emotion-ferplus-8.onnx", } } } diff --git a/onnxruntime/src/download/vision/domain_based_image_classification.rs b/onnxruntime/src/download/vision/domain_based_image_classification.rs index 2ab837cd..78387bf1 100644 --- a/onnxruntime/src/download/vision/domain_based_image_classification.rs +++ b/onnxruntime/src/download/vision/domain_based_image_classification.rs @@ -9,7 +9,7 @@ use crate::download::{vision::Vision, AvailableOnnxModel, ModelUrl}; pub enum DomainBasedImageClassification { /// Handwritten digits prediction using CNN /// - /// Source: [https://github.com/onnx/models/tree/master/vision/classification/mnist](https://github.com/onnx/models/tree/master/vision/classification/mnist) + /// Source: [https://github.com/onnx/models/tree/main/vision/classification/mnist](https://github.com/onnx/models/tree/main/vision/classification/mnist) /// /// Variant downloaded: ONNX Version 1.3 with Opset Version 8. Mnist, @@ -18,7 +18,7 @@ pub enum DomainBasedImageClassification { impl ModelUrl for DomainBasedImageClassification { fn fetch_url(&self) -> &'static str { match self { - DomainBasedImageClassification::Mnist => "https://github.com/onnx/models/raw/master/vision/classification/mnist/model/mnist-8.onnx", + DomainBasedImageClassification::Mnist => "https://github.com/onnx/models/raw/main/vision/classification/mnist/model/mnist-8.onnx", } } } diff --git a/onnxruntime/src/download/vision/image_classification.rs b/onnxruntime/src/download/vision/image_classification.rs index cbb33c2a..7806a755 100644 --- a/onnxruntime/src/download/vision/image_classification.rs +++ b/onnxruntime/src/download/vision/image_classification.rs @@ -22,7 +22,7 @@ pub enum ImageClassification { /// > contains images from 1000 classes. MobileNet models are also very efficient in terms of speed and /// > size and hence are ideal for embedded and mobile applications. /// - /// Source: [https://github.com/onnx/models/tree/master/vision/classification/mobilenet](https://github.com/onnx/models/tree/master/vision/classification/mobilenet) + /// Source: [https://github.com/onnx/models/tree/main/vision/classification/mobilenet](https://github.com/onnx/models/tree/main/vision/classification/mobilenet) /// /// Variant downloaded: ONNX Version 1.2.1 with Opset Version 7. MobileNet, @@ -31,7 +31,7 @@ pub enum ImageClassification { /// > ResNet models provide very high accuracies with affordable model sizes. They are ideal for cases when /// > high accuracy of classification is required. /// - /// Source: [https://github.com/onnx/models/tree/master/vision/classification/resnet](https://github.com/onnx/models/tree/master/vision/classification/resnet) + /// Source: [https://github.com/onnx/models/tree/main/vision/classification/resnet](https://github.com/onnx/models/tree/main/vision/classification/resnet) ResNet(ResNet), /// A small CNN with AlexNet level accuracy on ImageNet with 50x fewer parameters. /// @@ -40,7 +40,7 @@ pub enum ImageClassification { /// > export a new model from the cloud to an autonomous car and more feasible to deploy on FPGAs and other /// > hardware with limited memory. /// - /// Source: [https://github.com/onnx/models/tree/master/vision/classification/squeezenet](https://github.com/onnx/models/tree/master/vision/classification/squeezenet) + /// Source: [https://github.com/onnx/models/tree/main/vision/classification/squeezenet](https://github.com/onnx/models/tree/main/vision/classification/squeezenet) /// /// Variant downloaded: SqueezeNet v1.1, ONNX Version 1.2.1 with Opset Version 7. SqueezeNet, @@ -49,23 +49,23 @@ pub enum ImageClassification { /// > VGG models provide very high accuracies but at the cost of increased model sizes. They are ideal for /// > cases when high accuracy of classification is essential and there are limited constraints on model sizes. /// - /// Source: [https://github.com/onnx/models/tree/master/vision/classification/vgg](https://github.com/onnx/models/tree/master/vision/classification/vgg) + /// Source: [https://github.com/onnx/models/tree/main/vision/classification/vgg](https://github.com/onnx/models/tree/main/vision/classification/vgg) Vgg(Vgg), /// Convolutional neural network for classification, which competed in the ImageNet Large Scale Visual Recognition Challenge in 2012. /// - /// Source: [https://github.com/onnx/models/tree/master/vision/classification/alexnet](https://github.com/onnx/models/tree/master/vision/classification/alexnet) + /// Source: [https://github.com/onnx/models/tree/main/vision/classification/alexnet](https://github.com/onnx/models/tree/main/vision/classification/alexnet) /// /// Variant downloaded: ONNX Version 1.4 with Opset Version 9. AlexNet, /// Convolutional neural network for classification, which competed in the ImageNet Large Scale Visual Recognition Challenge in 2014. /// - /// Source: [https://github.com/onnx/models/tree/master/vision/classification/inception_and_googlenet/googlenet](https://github.com/onnx/models/tree/master/vision/classification/inception_and_googlenet/googlenet) + /// Source: [https://github.com/onnx/models/tree/main/vision/classification/inception_and_googlenet/googlenet](https://github.com/onnx/models/tree/main/vision/classification/inception_and_googlenet/googlenet) /// /// Variant downloaded: ONNX Version 1.4 with Opset Version 9. GoogleNet, /// Variant of AlexNet, it's the name of a convolutional neural network for classification, which competed in the ImageNet Large Scale Visual Recognition Challenge in 2012. /// - /// Source: [https://github.com/onnx/models/tree/master/vision/classification/caffenet](https://github.com/onnx/models/tree/master/vision/classification/caffenet) + /// Source: [https://github.com/onnx/models/tree/main/vision/classification/caffenet](https://github.com/onnx/models/tree/main/vision/classification/caffenet) /// /// Variant downloaded: ONNX Version 1.4 with Opset Version 9. CaffeNet, @@ -73,13 +73,13 @@ pub enum ImageClassification { /// /// > This model was made by transplanting the R-CNN SVM classifiers into a fc-rcnn classification layer. /// - /// Source: [https://github.com/onnx/models/tree/master/vision/classification/rcnn_ilsvrc13](https://github.com/onnx/models/tree/master/vision/classification/rcnn_ilsvrc13) + /// Source: [https://github.com/onnx/models/tree/main/vision/classification/rcnn_ilsvrc13](https://github.com/onnx/models/tree/main/vision/classification/rcnn_ilsvrc13) /// /// Variant downloaded: ONNX Version 1.4 with Opset Version 9. RcnnIlsvrc13, /// Convolutional neural network for classification. /// - /// Source: [https://github.com/onnx/models/tree/master/vision/classification/rcnn_ilsvrc13](https://github.com/onnx/models/tree/master/vision/classification/rcnn_ilsvrc13) + /// Source: [https://github.com/onnx/models/tree/main/vision/classification/rcnn_ilsvrc13](https://github.com/onnx/models/tree/main/vision/classification/rcnn_ilsvrc13) /// /// Variant downloaded: ONNX Version 1.4 with Opset Version 9. DenseNet121, @@ -87,19 +87,19 @@ pub enum ImageClassification { Inception(InceptionVersion), /// Computationally efficient CNN architecture designed specifically for mobile devices with very limited computing power. /// - /// Source: [https://github.com/onnx/models/tree/master/vision/classification/shufflenet](https://github.com/onnx/models/tree/master/vision/classification/shufflenet) + /// Source: [https://github.com/onnx/models/tree/main/vision/classification/shufflenet](https://github.com/onnx/models/tree/main/vision/classification/shufflenet) ShuffleNet(ShuffleNetVersion), /// Deep convolutional networks for classification. /// /// > This model's 4th layer has 512 maps instead of 1024 maps mentioned in the paper. /// - /// Source: [https://github.com/onnx/models/tree/master/vision/classification/zfnet-512](https://github.com/onnx/models/tree/master/vision/classification/zfnet-512) + /// Source: [https://github.com/onnx/models/tree/main/vision/classification/zfnet-512](https://github.com/onnx/models/tree/main/vision/classification/zfnet-512) ZFNet512, /// Image classification model that achieves state-of-the-art accuracy. /// /// > It is designed to run on mobile CPU, GPU, and EdgeTPU devices, allowing for applications on mobile and loT, where computational resources are limited. /// - /// Source: [https://github.com/onnx/models/tree/master/vision/classification/efficientnet-lite4](https://github.com/onnx/models/tree/master/vision/classification/efficientnet-lite4) + /// Source: [https://github.com/onnx/models/tree/main/vision/classification/efficientnet-lite4](https://github.com/onnx/models/tree/main/vision/classification/efficientnet-lite4) /// /// Variant downloaded: ONNX Version 1.7.0 with Opset Version 11. EfficientNetLite4, @@ -110,13 +110,13 @@ pub enum ImageClassification { pub enum InceptionVersion { /// Google's Inception v1 /// - /// Source: [https://github.com/onnx/models/tree/master/vision/classification/inception_and_googlenet/inception_v1](https://github.com/onnx/models/tree/master/vision/classification/inception_and_googlenet/inception_v1) + /// Source: [https://github.com/onnx/models/tree/main/vision/classification/inception_and_googlenet/inception_v1](https://github.com/onnx/models/tree/main/vision/classification/inception_and_googlenet/inception_v1) /// /// Variant downloaded: ONNX Version 1.4 with Opset Version 9. V1, /// Google's Inception v2 /// - /// Source: [https://github.com/onnx/models/tree/master/vision/classification/inception_and_googlenet/inception_v2](https://github.com/onnx/models/tree/master/vision/classification/inception_and_googlenet/inception_v2) + /// Source: [https://github.com/onnx/models/tree/main/vision/classification/inception_and_googlenet/inception_v2](https://github.com/onnx/models/tree/main/vision/classification/inception_and_googlenet/inception_v2) /// /// Variant downloaded: ONNX Version 1.4 with Opset Version 9. V2, @@ -124,7 +124,7 @@ pub enum InceptionVersion { /// ResNet /// -/// Source: [https://github.com/onnx/models/tree/master/vision/classification/resnet](https://github.com/onnx/models/tree/master/vision/classification/resnet) +/// Source: [https://github.com/onnx/models/tree/main/vision/classification/resnet](https://github.com/onnx/models/tree/main/vision/classification/resnet) #[derive(Debug, Clone)] pub enum ResNet { /// ResNet v1 @@ -134,7 +134,7 @@ pub enum ResNet { } /// ResNet v1 /// -/// Source: [https://github.com/onnx/models/tree/master/vision/classification/resnet](https://github.com/onnx/models/tree/master/vision/classification/resnet) +/// Source: [https://github.com/onnx/models/tree/main/vision/classification/resnet](https://github.com/onnx/models/tree/main/vision/classification/resnet) #[derive(Debug, Clone)] pub enum ResNetV1 { /// ResNet18 @@ -160,7 +160,7 @@ pub enum ResNetV1 { } /// ResNet v2 /// -/// Source: [https://github.com/onnx/models/tree/master/vision/classification/resnet](https://github.com/onnx/models/tree/master/vision/classification/resnet) +/// Source: [https://github.com/onnx/models/tree/main/vision/classification/resnet](https://github.com/onnx/models/tree/main/vision/classification/resnet) #[derive(Debug, Clone)] pub enum ResNetV2 { /// ResNet18 @@ -187,7 +187,7 @@ pub enum ResNetV2 { /// ResNet /// -/// Source: [https://github.com/onnx/models/tree/master/vision/classification/resnet](https://github.com/onnx/models/tree/master/vision/classification/resnet) +/// Source: [https://github.com/onnx/models/tree/main/vision/classification/resnet](https://github.com/onnx/models/tree/main/vision/classification/resnet) #[derive(Debug, Clone)] pub enum Vgg { /// VGG with 16 convolutional layers @@ -214,16 +214,16 @@ pub enum Vgg { /// Computationally efficient CNN architecture designed specifically for mobile devices with very limited computing power. /// -/// Source: [https://github.com/onnx/models/tree/master/vision/classification/shufflenet](https://github.com/onnx/models/tree/master/vision/classification/shufflenet) +/// Source: [https://github.com/onnx/models/tree/main/vision/classification/shufflenet](https://github.com/onnx/models/tree/main/vision/classification/shufflenet) #[derive(Debug, Clone)] pub enum ShuffleNetVersion { - /// Source: [https://github.com/onnx/models/tree/master/vision/classification/shufflenet](https://github.com/onnx/models/tree/master/vision/classification/shufflenet) + /// Source: [https://github.com/onnx/models/tree/main/vision/classification/shufflenet](https://github.com/onnx/models/tree/main/vision/classification/shufflenet) /// /// Variant downloaded: ONNX Version 1.4 with Opset Version 9. V1, /// ShuffleNetV2 is an improved architecture that is the state-of-the-art in terms of speed and accuracy tradeoff used for image classification. /// - /// Source: [https://github.com/onnx/models/tree/master/vision/classification/shufflenet](https://github.com/onnx/models/tree/master/vision/classification/shufflenet) + /// Source: [https://github.com/onnx/models/tree/main/vision/classification/shufflenet](https://github.com/onnx/models/tree/main/vision/classification/shufflenet) /// /// Variant downloaded: ONNX Version 1.6 with Opset Version 10. V2, @@ -232,19 +232,19 @@ pub enum ShuffleNetVersion { impl ModelUrl for ImageClassification { fn fetch_url(&self) -> &'static str { match self { - ImageClassification::MobileNet => "https://github.com/onnx/models/raw/master/vision/classification/mobilenet/model/mobilenetv2-7.onnx", - ImageClassification::SqueezeNet => "https://github.com/onnx/models/raw/master/vision/classification/squeezenet/model/squeezenet1.1-7.onnx", + ImageClassification::MobileNet => "https://github.com/onnx/models/raw/main/vision/classification/mobilenet/model/mobilenetv2-7.onnx", + ImageClassification::SqueezeNet => "https://github.com/onnx/models/raw/main/vision/classification/squeezenet/model/squeezenet1.1-7.onnx", ImageClassification::Inception(version) => version.fetch_url(), ImageClassification::ResNet(version) => version.fetch_url(), ImageClassification::Vgg(variant) => variant.fetch_url(), - ImageClassification::AlexNet => "https://github.com/onnx/models/raw/master/vision/classification/alexnet/model/bvlcalexnet-9.onnx", - ImageClassification::GoogleNet => "https://github.com/onnx/models/raw/master/vision/classification/inception_and_googlenet/googlenet/model/googlenet-9.onnx", - ImageClassification::CaffeNet => "https://github.com/onnx/models/raw/master/vision/classification/caffenet/model/caffenet-9.onnx", - ImageClassification::RcnnIlsvrc13 => "https://github.com/onnx/models/raw/master/vision/classification/rcnn_ilsvrc13/model/rcnn-ilsvrc13-9.onnx", - ImageClassification::DenseNet121 => "https://github.com/onnx/models/raw/master/vision/classification/densenet-121/model/densenet-9.onnx", + ImageClassification::AlexNet => "https://github.com/onnx/models/raw/main/vision/classification/alexnet/model/bvlcalexnet-9.onnx", + ImageClassification::GoogleNet => "https://github.com/onnx/models/raw/main/vision/classification/inception_and_googlenet/googlenet/model/googlenet-9.onnx", + ImageClassification::CaffeNet => "https://github.com/onnx/models/raw/main/vision/classification/caffenet/model/caffenet-9.onnx", + ImageClassification::RcnnIlsvrc13 => "https://github.com/onnx/models/raw/main/vision/classification/rcnn_ilsvrc13/model/rcnn-ilsvrc13-9.onnx", + ImageClassification::DenseNet121 => "https://github.com/onnx/models/raw/main/vision/classification/densenet-121/model/densenet-9.onnx", ImageClassification::ShuffleNet(version) => version.fetch_url(), - ImageClassification::ZFNet512 => "https://github.com/onnx/models/raw/master/vision/classification/zfnet-512/model/zfnet512-9.onnx", - ImageClassification::EfficientNetLite4 => "https://github.com/onnx/models/raw/master/vision/classification/efficientnet-lite4/model/efficientnet-lite4.onnx" + ImageClassification::ZFNet512 => "https://github.com/onnx/models/raw/main/vision/classification/zfnet-512/model/zfnet512-9.onnx", + ImageClassification::EfficientNetLite4 => "https://github.com/onnx/models/raw/main/vision/classification/efficientnet-lite4/model/efficientnet-lite4.onnx" } } } @@ -252,8 +252,8 @@ impl ModelUrl for ImageClassification { impl ModelUrl for InceptionVersion { fn fetch_url(&self) -> &'static str { match self { - InceptionVersion::V1 => "https://github.com/onnx/models/raw/master/vision/classification/inception_and_googlenet/inception_v1/model/inception-v1-9.onnx", - InceptionVersion::V2 => "https://github.com/onnx/models/raw/master/vision/classification/inception_and_googlenet/inception_v2/model/inception-v2-9.onnx", + InceptionVersion::V1 => "https://github.com/onnx/models/raw/main/vision/classification/inception_and_googlenet/inception_v1/model/inception-v1-9.onnx", + InceptionVersion::V2 => "https://github.com/onnx/models/raw/main/vision/classification/inception_and_googlenet/inception_v2/model/inception-v2-9.onnx", } } } @@ -270,11 +270,11 @@ impl ModelUrl for ResNet { impl ModelUrl for ResNetV1 { fn fetch_url(&self) -> &'static str { match self { - ResNetV1::ResNet18 => "https://github.com/onnx/models/raw/master/vision/classification/resnet/model/resnet18-v1-7.onnx", - ResNetV1::ResNet34 => "https://github.com/onnx/models/raw/master/vision/classification/resnet/model/resnet34-v1-7.onnx", - ResNetV1::ResNet50 => "https://github.com/onnx/models/raw/master/vision/classification/resnet/model/resnet50-v1-7.onnx", - ResNetV1::ResNet101 => "https://github.com/onnx/models/raw/master/vision/classification/resnet/model/resnet101-v1-7.onnx", - ResNetV1::ResNet152 => "https://github.com/onnx/models/raw/master/vision/classification/resnet/model/resnet152-v1-7.onnx", + ResNetV1::ResNet18 => "https://github.com/onnx/models/raw/main/vision/classification/resnet/model/resnet18-v1-7.onnx", + ResNetV1::ResNet34 => "https://github.com/onnx/models/raw/main/vision/classification/resnet/model/resnet34-v1-7.onnx", + ResNetV1::ResNet50 => "https://github.com/onnx/models/raw/main/vision/classification/resnet/model/resnet50-v1-7.onnx", + ResNetV1::ResNet101 => "https://github.com/onnx/models/raw/main/vision/classification/resnet/model/resnet101-v1-7.onnx", + ResNetV1::ResNet152 => "https://github.com/onnx/models/raw/main/vision/classification/resnet/model/resnet152-v1-7.onnx", } } } @@ -282,11 +282,11 @@ impl ModelUrl for ResNetV1 { impl ModelUrl for ResNetV2 { fn fetch_url(&self) -> &'static str { match self { - ResNetV2::ResNet18 => "https://github.com/onnx/models/raw/master/vision/classification/resnet/model/resnet18-v2-7.onnx", - ResNetV2::ResNet34 => "https://github.com/onnx/models/raw/master/vision/classification/resnet/model/resnet34-v2-7.onnx", - ResNetV2::ResNet50 => "https://github.com/onnx/models/raw/master/vision/classification/resnet/model/resnet50-v2-7.onnx", - ResNetV2::ResNet101 => "https://github.com/onnx/models/raw/master/vision/classification/resnet/model/resnet101-v2-7.onnx", - ResNetV2::ResNet152 => "https://github.com/onnx/models/raw/master/vision/classification/resnet/model/resnet152-v2-7.onnx", + ResNetV2::ResNet18 => "https://github.com/onnx/models/raw/main/vision/classification/resnet/model/resnet18-v2-7.onnx", + ResNetV2::ResNet34 => "https://github.com/onnx/models/raw/main/vision/classification/resnet/model/resnet34-v2-7.onnx", + ResNetV2::ResNet50 => "https://github.com/onnx/models/raw/main/vision/classification/resnet/model/resnet50-v2-7.onnx", + ResNetV2::ResNet101 => "https://github.com/onnx/models/raw/main/vision/classification/resnet/model/resnet101-v2-7.onnx", + ResNetV2::ResNet152 => "https://github.com/onnx/models/raw/main/vision/classification/resnet/model/resnet152-v2-7.onnx", } } } @@ -294,10 +294,10 @@ impl ModelUrl for ResNetV2 { impl ModelUrl for Vgg { fn fetch_url(&self) -> &'static str { match self { - Vgg::Vgg16 => "https://github.com/onnx/models/raw/master/vision/classification/vgg/model/vgg16-7.onnx", - Vgg::Vgg16Bn => "https://github.com/onnx/models/raw/master/vision/classification/vgg/model/vgg16-bn-7.onnx", - Vgg::Vgg19 => "https://github.com/onnx/models/raw/master/vision/classification/vgg/model/vgg19-7.onnx", - Vgg::Vgg19Bn => "https://github.com/onnx/models/raw/master/vision/classification/vgg/model/vgg19-bn-7.onnx", + Vgg::Vgg16 => "https://github.com/onnx/models/raw/main/vision/classification/vgg/model/vgg16-7.onnx", + Vgg::Vgg16Bn => "https://github.com/onnx/models/raw/main/vision/classification/vgg/model/vgg16-bn-7.onnx", + Vgg::Vgg19 => "https://github.com/onnx/models/raw/main/vision/classification/vgg/model/vgg19-7.onnx", + Vgg::Vgg19Bn => "https://github.com/onnx/models/raw/main/vision/classification/vgg/model/vgg19-bn-7.onnx", } } } @@ -305,8 +305,8 @@ impl ModelUrl for Vgg { impl ModelUrl for ShuffleNetVersion { fn fetch_url(&self) -> &'static str { match self { - ShuffleNetVersion::V1 => "https://github.com/onnx/models/raw/master/vision/classification/shufflenet/model/shufflenet-9.onnx", - ShuffleNetVersion::V2 => "https://github.com/onnx/models/raw/master/vision/classification/shufflenet/model/shufflenet-v2-10.onnx", + ShuffleNetVersion::V1 => "https://github.com/onnx/models/raw/main/vision/classification/shufflenet/model/shufflenet-9.onnx", + ShuffleNetVersion::V2 => "https://github.com/onnx/models/raw/main/vision/classification/shufflenet/model/shufflenet-v2-10.onnx", } } } diff --git a/onnxruntime/src/download/vision/image_manipulation.rs b/onnxruntime/src/download/vision/image_manipulation.rs index 23b659ac..4a67e429 100644 --- a/onnxruntime/src/download/vision/image_manipulation.rs +++ b/onnxruntime/src/download/vision/image_manipulation.rs @@ -17,7 +17,7 @@ pub enum ImageManipulation { /// > The Super Resolution machine learning model sharpens and upscales the input image to refine the /// > details and improve quality. /// - /// Source: [https://github.com/onnx/models/tree/master/vision/super_resolution/sub_pixel_cnn_2016](https://github.com/onnx/models/tree/master/vision/super_resolution/sub_pixel_cnn_2016) + /// Source: [https://github.com/onnx/models/tree/main/vision/super_resolution/sub_pixel_cnn_2016](https://github.com/onnx/models/tree/main/vision/super_resolution/sub_pixel_cnn_2016) /// /// Variant downloaded: ONNX Version 1.5 with Opset Version 10. SuperResolution, @@ -25,15 +25,15 @@ pub enum ImageManipulation { /// /// > This artistic style transfer model mixes the content of an image with the style of another image. /// > Examples of the styles can be seen - /// > [in this PyTorch example](https://github.com/pytorch/examples/tree/master/fast_neural_style#models). + /// > [in this PyTorch example](https://github.com/pytorch/examples/tree/main/fast_neural_style#models). /// - /// Source: [https://github.com/onnx/models/tree/master/vision/style_transfer/fast_neural_style](https://github.com/onnx/models/tree/master/vision/style_transfer/fast_neural_style) + /// Source: [https://github.com/onnx/models/tree/main/vision/style_transfer/fast_neural_style](https://github.com/onnx/models/tree/main/vision/style_transfer/fast_neural_style) FastNeuralStyleTransfer(FastNeuralStyleTransferStyle), } /// Fast Neural Style Transfer Style /// -/// Source: [https://github.com/onnx/models/tree/master/vision/style_transfer/fast_neural_style](https://github.com/onnx/models/tree/master/vision/style_transfer/fast_neural_style) +/// Source: [https://github.com/onnx/models/tree/main/vision/style_transfer/fast_neural_style](https://github.com/onnx/models/tree/main/vision/style_transfer/fast_neural_style) /// /// Variant downloaded: ONNX Version 1.4 with Opset Version 9. #[derive(Debug, Clone)] @@ -53,7 +53,7 @@ pub enum FastNeuralStyleTransferStyle { impl ModelUrl for ImageManipulation { fn fetch_url(&self) -> &'static str { match self { - ImageManipulation::SuperResolution => "https://github.com/onnx/models/raw/master/vision/super_resolution/sub_pixel_cnn_2016/model/super-resolution-10.onnx", + ImageManipulation::SuperResolution => "https://github.com/onnx/models/raw/main/vision/super_resolution/sub_pixel_cnn_2016/model/super-resolution-10.onnx", ImageManipulation::FastNeuralStyleTransfer(style) => style.fetch_url(), } } @@ -62,11 +62,11 @@ impl ModelUrl for ImageManipulation { impl ModelUrl for FastNeuralStyleTransferStyle { fn fetch_url(&self) -> &'static str { match self { - FastNeuralStyleTransferStyle::Mosaic => "https://github.com/onnx/models/raw/master/vision/style_transfer/fast_neural_style/model/mosaic-9.onnx", - FastNeuralStyleTransferStyle::Candy => "https://github.com/onnx/models/raw/master/vision/style_transfer/fast_neural_style/model/candy-9.onnx", - FastNeuralStyleTransferStyle::RainPrincess => "https://github.com/onnx/models/raw/master/vision/style_transfer/fast_neural_style/model/rain-princess-9.onnx", - FastNeuralStyleTransferStyle::Udnie => "https://github.com/onnx/models/raw/master/vision/style_transfer/fast_neural_style/model/udnie-9.onnx", - FastNeuralStyleTransferStyle::Pointilism => "https://github.com/onnx/models/raw/master/vision/style_transfer/fast_neural_style/model/pointilism-9.onnx", + FastNeuralStyleTransferStyle::Mosaic => "https://github.com/onnx/models/raw/main/vision/style_transfer/fast_neural_style/model/mosaic-9.onnx", + FastNeuralStyleTransferStyle::Candy => "https://github.com/onnx/models/raw/main/vision/style_transfer/fast_neural_style/model/candy-9.onnx", + FastNeuralStyleTransferStyle::RainPrincess => "https://github.com/onnx/models/raw/main/vision/style_transfer/fast_neural_style/model/rain-princess-9.onnx", + FastNeuralStyleTransferStyle::Udnie => "https://github.com/onnx/models/raw/main/vision/style_transfer/fast_neural_style/model/udnie-9.onnx", + FastNeuralStyleTransferStyle::Pointilism => "https://github.com/onnx/models/raw/main/vision/style_transfer/fast_neural_style/model/pointilism-9.onnx", } } } diff --git a/onnxruntime/src/download/vision/object_detection_image_segmentation.rs b/onnxruntime/src/download/vision/object_detection_image_segmentation.rs index 05a94348..ff95154c 100644 --- a/onnxruntime/src/download/vision/object_detection_image_segmentation.rs +++ b/onnxruntime/src/download/vision/object_detection_image_segmentation.rs @@ -84,18 +84,18 @@ pub enum ObjectDetectionImageSegmentation { impl ModelUrl for ObjectDetectionImageSegmentation { fn fetch_url(&self) -> &'static str { match self { - ObjectDetectionImageSegmentation::TinyYoloV2 => "https://github.com/onnx/models/raw/master/vision/object_detection_segmentation/tiny-yolov2/model/tinyyolov2-8.onnx", - ObjectDetectionImageSegmentation::Ssd => "https://github.com/onnx/models/raw/master/vision/object_detection_segmentation/ssd/model/ssd-10.onnx", - ObjectDetectionImageSegmentation::SSDMobileNetV1 => "https://github.com/onnx/models/raw/master/vision/object_detection_segmentation/ssd-mobilenetv1/model/ssd_mobilenet_v1_10.onnx", - ObjectDetectionImageSegmentation::FasterRcnn => "https://github.com/onnx/models/raw/master/vision/object_detection_segmentation/faster-rcnn/model/FasterRCNN-10.onnx", - ObjectDetectionImageSegmentation::MaskRcnn => "https://github.com/onnx/models/raw/master/vision/object_detection_segmentation/mask-rcnn/model/MaskRCNN-10.onnx", - ObjectDetectionImageSegmentation::RetinaNet => "https://github.com/onnx/models/raw/master/vision/object_detection_segmentation/retinanet/model/retinanet-9.onnx", - ObjectDetectionImageSegmentation::YoloV2 => "https://github.com/onnx/models/raw/master/vision/object_detection_segmentation/yolov2/model/yolov2-voc-8.onnx", - ObjectDetectionImageSegmentation::YoloV2Coco => "https://github.com/onnx/models/raw/master/vision/object_detection_segmentation/yolov2-coco/model/yolov2-coco-9.onnx", - ObjectDetectionImageSegmentation::YoloV3 => "https://github.com/onnx/models/raw/master/vision/object_detection_segmentation/yolov3/model/yolov3-10.onnx", - ObjectDetectionImageSegmentation::TinyYoloV3 => "https://github.com/onnx/models/raw/master/vision/object_detection_segmentation/tiny-yolov3/model/tiny-yolov3-11.onnx", - ObjectDetectionImageSegmentation::YoloV4 => "https://github.com/onnx/models/raw/master/vision/object_detection_segmentation/yolov4/model/yolov4.onnx", - ObjectDetectionImageSegmentation::Duc => "https://github.com/onnx/models/raw/master/vision/object_detection_segmentation/duc/model/ResNet101-DUC-7.onnx", + ObjectDetectionImageSegmentation::TinyYoloV2 => "https://github.com/onnx/models/raw/main/vision/object_detection_segmentation/tiny-yolov2/model/tinyyolov2-8.onnx", + ObjectDetectionImageSegmentation::Ssd => "https://github.com/onnx/models/raw/main/vision/object_detection_segmentation/ssd/model/ssd-10.onnx", + ObjectDetectionImageSegmentation::SSDMobileNetV1 => "https://github.com/onnx/models/raw/main/vision/object_detection_segmentation/ssd-mobilenetv1/model/ssd_mobilenet_v1_10.onnx", + ObjectDetectionImageSegmentation::FasterRcnn => "https://github.com/onnx/models/raw/main/vision/object_detection_segmentation/faster-rcnn/model/FasterRCNN-10.onnx", + ObjectDetectionImageSegmentation::MaskRcnn => "https://github.com/onnx/models/raw/main/vision/object_detection_segmentation/mask-rcnn/model/MaskRCNN-10.onnx", + ObjectDetectionImageSegmentation::RetinaNet => "https://github.com/onnx/models/raw/main/vision/object_detection_segmentation/retinanet/model/retinanet-9.onnx", + ObjectDetectionImageSegmentation::YoloV2 => "https://github.com/onnx/models/raw/main/vision/object_detection_segmentation/yolov2/model/yolov2-voc-8.onnx", + ObjectDetectionImageSegmentation::YoloV2Coco => "https://github.com/onnx/models/raw/main/vision/object_detection_segmentation/yolov2-coco/model/yolov2-coco-9.onnx", + ObjectDetectionImageSegmentation::YoloV3 => "https://github.com/onnx/models/raw/main/vision/object_detection_segmentation/yolov3/model/yolov3-10.onnx", + ObjectDetectionImageSegmentation::TinyYoloV3 => "https://github.com/onnx/models/raw/main/vision/object_detection_segmentation/tiny-yolov3/model/tiny-yolov3-11.onnx", + ObjectDetectionImageSegmentation::YoloV4 => "https://github.com/onnx/models/raw/main/vision/object_detection_segmentation/yolov4/model/yolov4.onnx", + ObjectDetectionImageSegmentation::Duc => "https://github.com/onnx/models/raw/main/vision/object_detection_segmentation/duc/model/ResNet101-DUC-7.onnx", } } } diff --git a/onnxruntime/src/environment.rs b/onnxruntime/src/environment.rs index 088f65e9..0f31194b 100644 --- a/onnxruntime/src/environment.rs +++ b/onnxruntime/src/environment.rs @@ -243,7 +243,7 @@ impl EnvBuilder { mod tests { use super::*; use std::sync::{RwLock, RwLockWriteGuard}; - use test_env_log::test; + use test_log::test; impl G_ENV { fn is_initialized(&self) -> bool { diff --git a/onnxruntime/src/lib.rs b/onnxruntime/src/lib.rs index 7ad71db4..a43c2c18 100644 --- a/onnxruntime/src/lib.rs +++ b/onnxruntime/src/lib.rs @@ -9,7 +9,7 @@ //! //! > ONNX Runtime is a cross-platform, high performance ML inferencing and training accelerator. //! -//! The (highly) unsafe [C API](https://github.com/microsoft/onnxruntime/blob/master/include/onnxruntime/core/session/onnxruntime_c_api.h) +//! The (highly) unsafe [C API](https://github.com/microsoft/onnxruntime/blob/main/include/onnxruntime/core/session/onnxruntime_c_api.h) //! is wrapped using bindgen as [`onnxruntime-sys`](https://crates.io/crates/onnxruntime-sys). //! //! The unsafe bindings are wrapped in this crate to expose a safe API. @@ -21,7 +21,7 @@ //! The C++ example that uses the C API //! ([`C_Api_Sample.cpp`](https://github.com/microsoft/onnxruntime/blob/v1.3.1/csharp/test/Microsoft.ML.OnnxRuntime.EndToEndTests.Capi/C_Api_Sample.cpp)) //! was ported to -//! [`onnxruntime`](https://github.com/nbigaouette/onnxruntime-rs/blob/master/onnxruntime/examples/sample.rs). +//! [`onnxruntime`](https://github.com/nbigaouette/onnxruntime-rs/blob/main/onnxruntime/examples/sample.rs). //! //! First, an environment must be created using and [`EnvBuilder`](environment/struct.EnvBuilder.html): //! @@ -112,7 +112,7 @@ to download. //! The outputs are of type [`OrtOwnedTensor`](tensor/ort_owned_tensor/struct.OrtOwnedTensor.html)s inside a vector, //! with the same length as the inputs. //! -//! See the [`sample.rs`](https://github.com/nbigaouette/onnxruntime-rs/blob/master/onnxruntime/examples/sample.rs) +//! See the [`sample.rs`](https://github.com/nbigaouette/onnxruntime-rs/blob/main/onnxruntime/examples/sample.rs) //! example for more details. use std::sync::{atomic::AtomicPtr, Arc, Mutex}; @@ -316,7 +316,7 @@ impl From for sys::OrtLoggingLevel { /// Optimization level performed by ONNX Runtime of the loaded graph /// -/// See the [official documentation](https://github.com/microsoft/onnxruntime/blob/master/docs/ONNX_Runtime_Graph_Optimizations.md) +/// See the [official documentation](https://github.com/microsoft/onnxruntime/blob/main/docs/ONNX_Runtime_Graph_Optimizations.md) /// for more information on the different optimization levels. #[derive(Debug)] #[cfg_attr(not(windows), repr(u32))] diff --git a/onnxruntime/src/memory.rs b/onnxruntime/src/memory.rs index 1c8fa42f..cf987322 100644 --- a/onnxruntime/src/memory.rs +++ b/onnxruntime/src/memory.rs @@ -52,7 +52,7 @@ impl Drop for MemoryInfo { #[cfg(test)] mod tests { use super::*; - use test_env_log::test; + use test_log::test; #[test] fn memory_info_constructor_destructor() { diff --git a/onnxruntime/src/session.rs b/onnxruntime/src/session.rs index 9a846c01..757c759a 100644 --- a/onnxruntime/src/session.rs +++ b/onnxruntime/src/session.rs @@ -295,6 +295,7 @@ impl<'a> SessionBuilder<'a> { /// Type storing the session information, built from an [`Environment`](environment/struct.Environment.html) #[derive(Debug)] +#[allow(dead_code)] // This is to fix a Clippy warning of `env` not being read. pub struct Session<'a> { env: &'a Environment, session_ptr: *mut sys::OrtSession, diff --git a/onnxruntime/src/tensor/ndarray_tensor.rs b/onnxruntime/src/tensor/ndarray_tensor.rs index 3fac6e95..400405d5 100644 --- a/onnxruntime/src/tensor/ndarray_tensor.rs +++ b/onnxruntime/src/tensor/ndarray_tensor.rs @@ -57,7 +57,7 @@ where mod tests { use super::*; use ndarray::{arr1, arr2, arr3}; - use test_env_log::test; + use test_log::test; #[test] fn softmax_1d() { diff --git a/onnxruntime/src/tensor/ort_owned_tensor.rs b/onnxruntime/src/tensor/ort_owned_tensor.rs index 80415b5c..fe45b362 100644 --- a/onnxruntime/src/tensor/ort_owned_tensor.rs +++ b/onnxruntime/src/tensor/ort_owned_tensor.rs @@ -23,6 +23,7 @@ use crate::{ /// `OrtOwnedTensor` implements the [`std::deref::Deref`](#impl-Deref) trait for ergonomic access to /// the underlying [`ndarray::ArrayView`](https://docs.rs/ndarray/latest/ndarray/type.ArrayView.html). #[derive(Debug)] +#[allow(dead_code)] // This is to appease clippy as `memory_info` is not read. pub struct OrtOwnedTensor<'t, 'm, T, D> where T: TypeToTensorElementDataType + Debug + Clone, diff --git a/onnxruntime/src/tensor/ort_tensor.rs b/onnxruntime/src/tensor/ort_tensor.rs index a0542aff..66fc6372 100644 --- a/onnxruntime/src/tensor/ort_tensor.rs +++ b/onnxruntime/src/tensor/ort_tensor.rs @@ -23,6 +23,7 @@ use crate::{ /// **NOTE**: The type is not meant to be used directly, use an [`ndarray::Array`](https://docs.rs/ndarray/latest/ndarray/type.Array.html) /// instead. #[derive(Debug)] +#[allow(dead_code)] // This is required to appease clipply as `memory_info` is not read from. pub struct OrtTensor<'t, T, D> where T: TypeToTensorElementDataType + Debug + Clone, @@ -198,7 +199,7 @@ mod tests { use crate::{AllocatorType, MemType}; use ndarray::{arr0, arr1, arr2, arr3}; use std::ptr; - use test_env_log::test; + use test_log::test; #[test] fn orttensor_from_array_0d_i32() { diff --git a/onnxruntime/tests/integration_tests.rs b/onnxruntime/tests/integration_tests.rs index 37136dbb..ea670c6f 100644 --- a/onnxruntime/tests/integration_tests.rs +++ b/onnxruntime/tests/integration_tests.rs @@ -13,7 +13,7 @@ mod download { use image::{imageops::FilterType, ImageBuffer, Luma, Pixel, Rgb}; use ndarray::s; - use test_env_log::test; + use test_log::test; use onnxruntime::{ download::vision::{DomainBasedImageClassification, ImageClassification}, @@ -72,7 +72,7 @@ mod download { // # x==0 --> left // # y==0 --> top - // See https://github.com/onnx/models/blob/master/vision/classification/imagenet_inference.ipynb + // See https://github.com/onnx/models/blob/main/vision/classification/imagenet_inference.ipynb // for pre-processing image. // WARNING: Note order of declaration of arguments: (_,c,j,i) let mut array = ndarray::Array::from_shape_fn((1, 3, 224, 224), |(_, c, j, i)| {