diff --git a/include/astaroth_node.h b/include/astaroth_node.h index 6b2d626..5458ac9 100644 --- a/include/astaroth_node.h +++ b/include/astaroth_node.h @@ -27,7 +27,16 @@ extern "C" { typedef struct node_s* Node; // Opaque pointer to node_s. typedef struct { + int3 m; + int3 n; +} Grid; +typedef struct { + int num_devices; + Device* devices; + + Grid grid; + Grid subgrid; } DeviceConfiguration; /** */ diff --git a/src/core/node.cu b/src/core/node.cu index f9a4aa9..6fa80f2 100644 --- a/src/core/node.cu +++ b/src/core/node.cu @@ -131,11 +131,6 @@ static const int MAX_NUM_DEVICES = 32; -typedef struct { - int3 m; - int3 n; -} Grid; - struct node_s { int id; @@ -334,10 +329,12 @@ acNodePrintInfo(const Node node) AcResult acNodeQueryDeviceConfiguration(const Node node, DeviceConfiguration* config) { - (void)node; - (void)config; - WARNING("Not implemented"); - return AC_FAILURE; + config->num_devices = node->num_devices; + config->devices = node->devices; + config->grid = node->grid; + config->subgrid = node->subgrid; + + return AC_SUCCESS; } AcResult