@@ -15,6 +15,7 @@ typedef uint64_t GrB_Index;
1515/* GxB typedefs */
1616typedef double _Complex GxB_FC64_t ;
1717typedef float _Complex GxB_FC32_t ;
18+ typedef struct GB_Iterator_opaque * GxB_Iterator ;
1819typedef struct GB_Scalar_opaque * GxB_Scalar ;
1920typedef struct GB_SelectOp_opaque * GxB_SelectOp ;
2021
@@ -68,6 +69,7 @@ typedef enum
6869{
6970 GrB_SUCCESS = 0 ,
7071 GrB_NO_VALUE = 1 ,
72+ GxB_EXHAUSTED = 2 ,
7173 GrB_UNINITIALIZED_OBJECT = -1 ,
7274 GrB_NULL_POINTER = -2 ,
7375 GrB_INVALID_VALUE = -3 ,
@@ -3059,6 +3061,14 @@ extern GrB_Info GrB_Vector_wait(GrB_Vector v, GrB_WaitMode waitmode);
30593061/* binary */
30603062extern GrB_Info GB_BinaryOp_new (GrB_BinaryOp * binaryop , GxB_binary_function function , GrB_Type ztype , GrB_Type xtype , GrB_Type ytype , const char * binop_name );
30613063
3064+ /* iterator */
3065+ extern GrB_Info GB_Iterator_rc_bitmap_next (GxB_Iterator iterator );
3066+ extern GrB_Info GB_Iterator_rc_seek (GxB_Iterator iterator , GrB_Index j , bool jth_vector );
3067+ extern GrB_Info GB_Vector_Iterator_bitmap_seek (GxB_Iterator iterator , GrB_Index p );
3068+
3069+ /* matrix */
3070+ extern GrB_Info GB_Iterator_attach (GxB_Iterator iterator , GrB_Matrix A , GxB_Format_Value format , GrB_Descriptor desc );
3071+
30623072/* selectop */
30633073extern GrB_Info GB_SelectOp_new (GxB_SelectOp * selectop , GxB_select_function function , GrB_Type xtype , GrB_Type ttype , const char * name );
30643074
@@ -3101,8 +3111,51 @@ extern GrB_Info GxB_IndexUnaryOp_xtype_name(char *type_name, const GrB_IndexUnar
31013111extern GrB_Info GxB_IndexUnaryOp_ytype_name (char * type_name , const GrB_IndexUnaryOp op );
31023112extern GrB_Info GxB_IndexUnaryOp_ztype_name (char * type_name , const GrB_IndexUnaryOp op );
31033113
3114+ /* iterator */
3115+ extern GrB_Index GxB_Matrix_Iterator_getp (GxB_Iterator iterator );
3116+ extern GrB_Index GxB_Matrix_Iterator_getpmax (GxB_Iterator iterator );
3117+ extern GrB_Index GxB_Vector_Iterator_getIndex (GxB_Iterator iterator );
3118+ extern GrB_Index GxB_Vector_Iterator_getp (GxB_Iterator iterator );
3119+ extern GrB_Index GxB_Vector_Iterator_getpmax (GxB_Iterator iterator );
3120+ extern GrB_Index GxB_colIterator_getColIndex (GxB_Iterator iterator );
3121+ extern GrB_Index GxB_colIterator_getRowIndex (GxB_Iterator iterator );
3122+ extern GrB_Index GxB_colIterator_kount (GxB_Iterator iterator );
3123+ extern GrB_Index GxB_rowIterator_getColIndex (GxB_Iterator iterator );
3124+ extern GrB_Index GxB_rowIterator_getRowIndex (GxB_Iterator iterator );
3125+ extern GrB_Index GxB_rowIterator_kount (GxB_Iterator iterator );
3126+ extern GrB_Info GxB_Iterator_free (GxB_Iterator * iterator );
3127+ extern GrB_Info GxB_Iterator_new (GxB_Iterator * iterator );
3128+ extern GrB_Info GxB_Matrix_Iterator_next (GxB_Iterator iterator );
3129+ extern GrB_Info GxB_Matrix_Iterator_seek (GxB_Iterator iterator , GrB_Index p );
3130+ extern GrB_Info GxB_Vector_Iterator_next (GxB_Iterator iterator );
3131+ extern GrB_Info GxB_Vector_Iterator_seek (GxB_Iterator iterator , GrB_Index p );
3132+ extern GrB_Info GxB_colIterator_kseek (GxB_Iterator iterator , GrB_Index k );
3133+ extern GrB_Info GxB_colIterator_nextCol (GxB_Iterator iterator );
3134+ extern GrB_Info GxB_colIterator_nextRow (GxB_Iterator iterator );
3135+ extern GrB_Info GxB_colIterator_seekCol (GxB_Iterator iterator , GrB_Index col );
3136+ extern GrB_Info GxB_rowIterator_kseek (GxB_Iterator iterator , GrB_Index k );
3137+ extern GrB_Info GxB_rowIterator_nextCol (GxB_Iterator iterator );
3138+ extern GrB_Info GxB_rowIterator_nextRow (GxB_Iterator iterator );
3139+ extern GrB_Info GxB_rowIterator_seekRow (GxB_Iterator iterator , GrB_Index row );
3140+ extern GxB_FC32_t GxB_Iterator_get_FC32 (GxB_Iterator iterator );
3141+ extern GxB_FC64_t GxB_Iterator_get_FC64 (GxB_Iterator iterator );
3142+ extern bool GxB_Iterator_get_BOOL (GxB_Iterator iterator );
3143+ extern double GxB_Iterator_get_FP64 (GxB_Iterator iterator );
3144+ extern float GxB_Iterator_get_FP32 (GxB_Iterator iterator );
3145+ extern int8_t GxB_Iterator_get_INT8 (GxB_Iterator iterator );
3146+ extern int16_t GxB_Iterator_get_INT16 (GxB_Iterator iterator );
3147+ extern int32_t GxB_Iterator_get_INT32 (GxB_Iterator iterator );
3148+ extern int64_t GxB_Iterator_get_INT64 (GxB_Iterator iterator );
3149+ extern uint8_t GxB_Iterator_get_UINT8 (GxB_Iterator iterator );
3150+ extern uint16_t GxB_Iterator_get_UINT16 (GxB_Iterator iterator );
3151+ extern uint32_t GxB_Iterator_get_UINT32 (GxB_Iterator iterator );
3152+ extern uint64_t GxB_Iterator_get_UINT64 (GxB_Iterator iterator );
3153+ extern void GxB_Iterator_get_UDT (GxB_Iterator iterator , void * value );
3154+ extern void GxB_Matrix_Iterator_getIndex (GxB_Iterator iterator , GrB_Index * row , GrB_Index * col );
3155+
31043156/* matrix */
31053157extern GrB_Info GxB_Col_subassign (GrB_Matrix C , const GrB_Vector mask , const GrB_BinaryOp accum , const GrB_Vector u , const GrB_Index * I , GrB_Index ni , GrB_Index j , const GrB_Descriptor desc );
3158+ extern GrB_Info GxB_Matrix_Iterator_attach (GxB_Iterator iterator , GrB_Matrix A , GrB_Descriptor desc );
31063159extern GrB_Info GxB_Matrix_Option_get (GrB_Matrix A , GxB_Option_Field field , ...);
31073160extern GrB_Info GxB_Matrix_Option_set (GrB_Matrix A , GxB_Option_Field field , ...);
31083161extern GrB_Info GxB_Matrix_apply_BinaryOp1st (GrB_Matrix C , const GrB_Matrix Mask , const GrB_BinaryOp accum , const GrB_BinaryOp op , const GrB_Scalar x , const GrB_Matrix A , const GrB_Descriptor desc );
@@ -3195,6 +3248,8 @@ extern GrB_Info GxB_Matrix_unpack_HyperCSC(GrB_Matrix A, GrB_Index **Ap, GrB_Ind
31953248extern GrB_Info GxB_Matrix_unpack_HyperCSR (GrB_Matrix A , GrB_Index * * Ap , GrB_Index * * Ah , GrB_Index * * Aj , void * * Ax , GrB_Index * Ap_size , GrB_Index * Ah_size , GrB_Index * Aj_size , GrB_Index * Ax_size , bool * iso , GrB_Index * nvec , bool * jumbled , const GrB_Descriptor desc );
31963249extern GrB_Info GxB_Row_subassign (GrB_Matrix C , const GrB_Vector mask , const GrB_BinaryOp accum , const GrB_Vector u , GrB_Index i , const GrB_Index * J , GrB_Index nj , const GrB_Descriptor desc );
31973250extern GrB_Info GxB_Vector_diag (GrB_Vector v , const GrB_Matrix A , int64_t k , const GrB_Descriptor desc );
3251+ extern GrB_Info GxB_colIterator_attach (GxB_Iterator iterator , GrB_Matrix A , GrB_Descriptor desc );
3252+ extern GrB_Info GxB_rowIterator_attach (GxB_Iterator iterator , GrB_Matrix A , GrB_Descriptor desc );
31983253
31993254/* monoid */
32003255extern GrB_Info GxB_Monoid_fprint (GrB_Monoid monoid , const char * name , GxB_Print_Level pr , FILE * f );
@@ -3289,6 +3344,7 @@ extern GrB_Info GxB_UnaryOp_ztype(GrB_Type *ztype, GrB_UnaryOp unaryop);
32893344extern GrB_Info GxB_UnaryOp_ztype_name (char * type_name , const GrB_UnaryOp unaryop );
32903345
32913346/* vector */
3347+ extern GrB_Info GxB_Vector_Iterator_attach (GxB_Iterator iterator , GrB_Vector v , GrB_Descriptor desc );
32923348extern GrB_Info GxB_Vector_Option_get (GrB_Vector A , GxB_Option_Field field , ...);
32933349extern GrB_Info GxB_Vector_Option_set (GrB_Vector A , GxB_Option_Field field , ...);
32943350extern GrB_Info GxB_Vector_apply_BinaryOp1st (GrB_Vector w , const GrB_Vector mask , const GrB_BinaryOp accum , const GrB_BinaryOp op , const GrB_Scalar x , const GrB_Vector u , const GrB_Descriptor desc );
0 commit comments