pathrex-sys 0.1.0

Native FFI bindings for SuiteSparse:GraphBLAS and LAGraph used by the pathrex crate.
Documentation
/* automatically generated by rust-bindgen 0.71.1 */

pub const LAGRAPH_MSG_LEN: u32 = 256;
pub type __off_t = ::std::os::raw::c_long;
pub type __off64_t = ::std::os::raw::c_long;
pub type FILE = _IO_FILE;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _IO_marker {
    _unused: [u8; 0],
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _IO_codecvt {
    _unused: [u8; 0],
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _IO_wide_data {
    _unused: [u8; 0],
}
pub type _IO_lock_t = ::std::os::raw::c_void;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _IO_FILE {
    pub _flags: ::std::os::raw::c_int,
    pub _IO_read_ptr: *mut ::std::os::raw::c_char,
    pub _IO_read_end: *mut ::std::os::raw::c_char,
    pub _IO_read_base: *mut ::std::os::raw::c_char,
    pub _IO_write_base: *mut ::std::os::raw::c_char,
    pub _IO_write_ptr: *mut ::std::os::raw::c_char,
    pub _IO_write_end: *mut ::std::os::raw::c_char,
    pub _IO_buf_base: *mut ::std::os::raw::c_char,
    pub _IO_buf_end: *mut ::std::os::raw::c_char,
    pub _IO_save_base: *mut ::std::os::raw::c_char,
    pub _IO_backup_base: *mut ::std::os::raw::c_char,
    pub _IO_save_end: *mut ::std::os::raw::c_char,
    pub _markers: *mut _IO_marker,
    pub _chain: *mut _IO_FILE,
    pub _fileno: ::std::os::raw::c_int,
    pub _flags2: ::std::os::raw::c_int,
    pub _old_offset: __off_t,
    pub _cur_column: ::std::os::raw::c_ushort,
    pub _vtable_offset: ::std::os::raw::c_schar,
    pub _shortbuf: [::std::os::raw::c_char; 1usize],
    pub _lock: *mut _IO_lock_t,
    pub _offset: __off64_t,
    pub _codecvt: *mut _IO_codecvt,
    pub _wide_data: *mut _IO_wide_data,
    pub _freeres_list: *mut _IO_FILE,
    pub _freeres_buf: *mut ::std::os::raw::c_void,
    pub __pad5: usize,
    pub _mode: ::std::os::raw::c_int,
    pub _unused2: [::std::os::raw::c_char; 20usize],
}
pub type GrB_Index = u64;
#[repr(i32)]
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)]
pub enum GrB_Info {
    GrB_SUCCESS = 0,
    GrB_NO_VALUE = 1,
    GxB_EXHAUSTED = 7089,
    GrB_UNINITIALIZED_OBJECT = -1,
    GrB_NULL_POINTER = -2,
    GrB_INVALID_VALUE = -3,
    GrB_INVALID_INDEX = -4,
    GrB_DOMAIN_MISMATCH = -5,
    GrB_DIMENSION_MISMATCH = -6,
    GrB_OUTPUT_NOT_EMPTY = -7,
    GrB_NOT_IMPLEMENTED = -8,
    GrB_ALREADY_SET = -9,
    GrB_PANIC = -101,
    GrB_OUT_OF_MEMORY = -102,
    GrB_INSUFFICIENT_SPACE = -103,
    GrB_INVALID_OBJECT = -104,
    GrB_INDEX_OUT_OF_BOUNDS = -105,
    GrB_EMPTY_OBJECT = -106,
    GxB_JIT_ERROR = -7001,
    GxB_GPU_ERROR = -7002,
    GxB_OUTPUT_IS_READONLY = -7003,
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct GB_Descriptor_opaque {
    _unused: [u8; 0],
}
pub type GrB_Descriptor = *mut GB_Descriptor_opaque;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct GB_Type_opaque {
    _unused: [u8; 0],
}
pub type GrB_Type = *mut GB_Type_opaque;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct GB_BinaryOp_opaque {
    _unused: [u8; 0],
}
pub type GrB_BinaryOp = *mut GB_BinaryOp_opaque;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct GB_Semiring_opaque {
    _unused: [u8; 0],
}
pub type GrB_Semiring = *mut GB_Semiring_opaque;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct GB_Scalar_opaque {
    _unused: [u8; 0],
}
pub type GrB_Scalar = *mut GB_Scalar_opaque;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct GB_Vector_opaque {
    _unused: [u8; 0],
}
pub type GrB_Vector = *mut GB_Vector_opaque;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct GB_Matrix_opaque {
    _unused: [u8; 0],
}
pub type GrB_Matrix = *mut GB_Matrix_opaque;
unsafe extern "C" {
    pub static mut GrB_BOOL: GrB_Type;
}
unsafe extern "C" {
    pub static mut GrB_LOR: GrB_BinaryOp;
}
unsafe extern "C" {
    pub static mut GrB_LOR_LAND_SEMIRING_BOOL: GrB_Semiring;
}
unsafe extern "C" {
    pub fn GrB_Vector_new(v: *mut GrB_Vector, type_: GrB_Type, n: GrB_Index) -> GrB_Info;
}
unsafe extern "C" {
    pub fn GrB_Vector_nvals(nvals: *mut GrB_Index, v: GrB_Vector) -> GrB_Info;
}
unsafe extern "C" {
    pub fn GrB_Vector_setElement_BOOL(w: GrB_Vector, x: bool, i: GrB_Index) -> GrB_Info;
}
unsafe extern "C" {
    pub fn GrB_Vector_extractTuples_BOOL(
        I_: *mut GrB_Index,
        X: *mut bool,
        nvals: *mut GrB_Index,
        V: GrB_Vector,
    ) -> GrB_Info;
}
unsafe extern "C" {
    pub fn GrB_Matrix_new(
        A: *mut GrB_Matrix,
        type_: GrB_Type,
        nrows: GrB_Index,
        ncols: GrB_Index,
    ) -> GrB_Info;
}
unsafe extern "C" {
    pub fn GrB_Matrix_dup(C: *mut GrB_Matrix, A: GrB_Matrix) -> GrB_Info;
}
unsafe extern "C" {
    pub fn GrB_Matrix_nvals(nvals: *mut GrB_Index, A: GrB_Matrix) -> GrB_Info;
}
unsafe extern "C" {
    pub fn GrB_Matrix_build_BOOL(
        C: GrB_Matrix,
        I_: *const GrB_Index,
        J: *const GrB_Index,
        X: *const bool,
        nvals: GrB_Index,
        dup: GrB_BinaryOp,
    ) -> GrB_Info;
}
unsafe extern "C" {
    pub fn GrB_Matrix_extractElement_BOOL(
        x: *mut bool,
        A: GrB_Matrix,
        i: GrB_Index,
        j: GrB_Index,
    ) -> GrB_Info;
}
unsafe extern "C" {
    pub fn GrB_vxm(
        w: GrB_Vector,
        mask: GrB_Vector,
        accum: GrB_BinaryOp,
        semiring: GrB_Semiring,
        u: GrB_Vector,
        A: GrB_Matrix,
        desc: GrB_Descriptor,
    ) -> GrB_Info;
}
unsafe extern "C" {
    pub fn GrB_Vector_free(object: *mut GrB_Vector) -> GrB_Info;
}
unsafe extern "C" {
    pub fn GrB_Matrix_free(object: *mut GrB_Matrix) -> GrB_Info;
}
#[repr(i32)]
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)]
pub enum LAGraph_Kind {
    LAGraph_ADJACENCY_UNDIRECTED = 0,
    LAGraph_ADJACENCY_DIRECTED = 1,
    LAGraph_KIND_UNKNOWN = -1,
}
#[repr(i32)]
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)]
pub enum LAGraph_Boolean {
    LAGraph_FALSE = 0,
    LAGraph_TRUE = 1,
    LAGraph_BOOLEAN_UNKNOWN = -1,
}
#[repr(i32)]
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)]
pub enum LAGraph_State {
    LAGraph_VALUE = 0,
    LAGraph_BOUND = 1,
    LAGraph_STATE_UNKNOWN = -1,
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct LAGraph_Graph_struct {
    pub A: GrB_Matrix,
    pub kind: LAGraph_Kind,
    pub AT: GrB_Matrix,
    pub out_degree: GrB_Vector,
    pub in_degree: GrB_Vector,
    pub is_symmetric_structure: LAGraph_Boolean,
    pub nself_edges: i64,
    pub emin: GrB_Scalar,
    pub emin_state: LAGraph_State,
    pub emax: GrB_Scalar,
    pub emax_state: LAGraph_State,
}
pub type LAGraph_Graph = *mut LAGraph_Graph_struct;
unsafe extern "C" {
    pub fn LAGraph_Init(msg: *mut ::std::os::raw::c_char) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn LAGraph_Finalize(msg: *mut ::std::os::raw::c_char) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn LAGraph_New(
        G: *mut LAGraph_Graph,
        A: *mut GrB_Matrix,
        kind: LAGraph_Kind,
        msg: *mut ::std::os::raw::c_char,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn LAGraph_Delete(
        G: *mut LAGraph_Graph,
        msg: *mut ::std::os::raw::c_char,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn LAGraph_Cached_AT(
        G: LAGraph_Graph,
        msg: *mut ::std::os::raw::c_char,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn LAGraph_CheckGraph(
        G: LAGraph_Graph,
        msg: *mut ::std::os::raw::c_char,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn LAGraph_GetNumThreads(
        nthreads_outer: *mut ::std::os::raw::c_int,
        nthreads_inner: *mut ::std::os::raw::c_int,
        msg: *mut ::std::os::raw::c_char,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn LAGraph_SetNumThreads(
        nthreads_outer: ::std::os::raw::c_int,
        nthreads_inner: ::std::os::raw::c_int,
        msg: *mut ::std::os::raw::c_char,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn LAGraph_MMRead(
        A: *mut GrB_Matrix,
        f: *mut FILE,
        msg: *mut ::std::os::raw::c_char,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn LAGraph_RegularPathQuery(
        reachable: *mut GrB_Vector,
        R: *mut LAGraph_Graph,
        nl: usize,
        QS: *const GrB_Index,
        nqs: usize,
        QF: *const GrB_Index,
        nqf: usize,
        G: *mut LAGraph_Graph,
        S: *const GrB_Index,
        ns: usize,
        msg: *mut ::std::os::raw::c_char,
    ) -> ::std::os::raw::c_int;
}
#[repr(u32)]
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)]
pub enum RPQMatrixOp {
    RPQ_MATRIX_OP_LABEL = 0,
    RPQ_MATRIX_OP_LOR = 1,
    RPQ_MATRIX_OP_CONCAT = 2,
    RPQ_MATRIX_OP_KLEENE = 3,
    RPQ_MATRIX_OP_KLEENE_L = 4,
    RPQ_MATRIX_OP_KLEENE_R = 5,
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct RPQMatrixPlan {
    pub op: RPQMatrixOp,
    pub lhs: *mut RPQMatrixPlan,
    pub rhs: *mut RPQMatrixPlan,
    pub mat: GrB_Matrix,
    pub res_mat: GrB_Matrix,
}
unsafe extern "C" {
    pub fn LAGraph_RPQMatrix(
        nnz: *mut GrB_Index,
        plan: *mut RPQMatrixPlan,
        msg: *mut ::std::os::raw::c_char,
    ) -> GrB_Info;
}
unsafe extern "C" {
    pub fn LAGraph_RPQMatrix_label(
        mat: *mut GrB_Matrix,
        x: GrB_Index,
        i: GrB_Index,
        j: GrB_Index,
    ) -> GrB_Info;
}
unsafe extern "C" {
    pub fn LAGraph_DestroyRpqMatrixPlan(plan: *mut RPQMatrixPlan) -> GrB_Info;
}
unsafe extern "C" {
    pub fn LAGraph_RPQMatrix_Free(mat: *mut GrB_Matrix) -> GrB_Info;
}
unsafe extern "C" {
    pub fn LAGraph_RPQMatrix_reduce(
        res: *mut GrB_Index,
        mat: GrB_Matrix,
        reduce_type: u8,
    ) -> GrB_Info;
}