-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathStructs.cs
More file actions
139 lines (122 loc) · 5 KB
/
Structs.cs
File metadata and controls
139 lines (122 loc) · 5 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
// ReSharper disable InconsistentNaming
// ReSharper disable UnusedMember.Global
namespace ChacoSharp
{
public unsafe struct vtx_data
{
public int vwgt; /**< weight of vertex */
public int nedges; /**< number of neighbors of vertex in subgraph */
/**< Note: above always includes self-edge first */
public int* edges; /**< neighbor list in subgraph numbering scheme */
public float* ewgts; /**< weights of all the edges */
/**< Note: above 2 fields have self-edge first */
}
/**< An Array of lists made of these stores scheduler's message table. */
public unsafe struct msg_data
{
public int dest; /**< destination of the message */
public double dur; /**< duration of message */
public double beg; /**< time at which message begins */
public double end; /**< time at which message end */
public list* route; /**< linked list of ints stores message route */
public msg_data* pntr; /**< pointer to next outgoing message from this set */
}
/**< A linked list of these stores the selective orthogonalization set */
public unsafe struct orthlink
{
public int depth; /**< bottom of list is 0, previous is 1 etc */
public int index; /**< position in list of ritz vals (i index) */
public double ritzval; /**< good ritz value */
public double betaji; /**< residual bound on good ritz pair */
public double tau; /**< from orthogonality recursion */
public double prevtau; /**< from orthogonality recursion */
public double* vec; /**< vector to orthogonalize against */
public orthlink* pntr; /**< pointer to next link */
}
/**< A linked list of these stores the selective orthogonalization set */
public unsafe struct orthlink_float
{
public int depth; /**< bottom of list is 0, previous is 1 etc */
public int index; /**< position in list of ritz vals (i index) */
public double ritzval; /**< good ritz value */
public double betaji; /**< residual bound on good ritz pair */
public double tau; /**< from orthogonality recursion */
public double prevtau; /**< from orthogonality recursion */
public float* vec; /**< vector to orthogonalize against */
public orthlink_float* pntr; /**< pointer to next link */
}
/**< Array data structure for heap information */
public struct heap
{
public double val; /**< value being kept in a heap */
public int tag; /**< info associated with value */
}
/**< A linked list of these stores the minimum elements of a vector */
public unsafe struct scanlink
{
public double val; /**< value of vector entry */
public int indx; /**< index of corresponding entry */
public scanlink* pntr; /**< pointer to next link */
}
/**< These store the phantom edges needed to keep a subgraph connected */
public unsafe struct edgeslist
{
public int vtx1; /**< first vertex in edge */
public int vtx2; /**< second vertex in edge */
public edgeslist* next; /**< pointer to next element in list */
}
/**< These store all the data needed to modify edges for connectivity. */
public unsafe struct connect_data
{
public ilists* old_edges; /**< overwritten old edges */
public flists* old_ewgts; /**< overwritten old weights */
public edgeslist* new_edges; /**< list of new edges */
public int old_nedges; /**< original number of edges in graph */
}
/**< Information about subsets of processors is needed in recurse. */
public unsafe struct set_info
{
public int setnum; /**< assignment value for this set */
public int ndims; /**< log of # processors if hypercube */
public fixed int low[3]; /**< low limit for grid dimensions if mesh */
public fixed int span[3]; /**< size of grid dimensions if mesh */
public set_info* next; /**< pointer to next element in linked list */
}
/**< Linked list stuff for various uses */
public unsafe struct list
{
/**< linked list of integers */
public int num; /**< element number */
public list* next; /**< ptr to next element in list */
}
public unsafe struct lists
{
/**< linked list of lists */
public list* begin; /**< pointer to list */
public lists* nextlist; /**< next list header */
}
public unsafe struct bilist
{
/**< bidirectional list */
public bilist* prev; /**< pointer to previous element */
public bilist* next; /**< ptr to next element in list */
}
struct ipairs
{
/**< stores pairs of integers */
public int val1;
public int val2;
}
public unsafe struct ilists
{
/**< linked list of integer lists */
public int* list;
public ilists* next;
}
public unsafe struct flists
{
/**< linked list of floating lists */
public float* list;
public flists* next;
}
}