Renamed NUM_STREAM_TYPES -> NUM_STREAMS

This commit is contained in:
jpekkila
2019-09-12 15:48:38 +03:00
parent 53230c9b61
commit 021e5f3774
2 changed files with 5 additions and 5 deletions

View File

@@ -127,9 +127,9 @@ typedef enum {
STREAM_14,
STREAM_15,
STREAM_16,
NUM_STREAM_TYPES
NUM_STREAMS
} Stream;
#define STREAM_ALL (NUM_STREAM_TYPES)
#define STREAM_ALL (NUM_STREAMS)
#define AC_GEN_ID(X) X
typedef enum {

View File

@@ -46,7 +46,7 @@ struct device_s {
AcMeshInfo local_config;
// Concurrency
cudaStream_t streams[NUM_STREAM_TYPES];
cudaStream_t streams[NUM_STREAMS];
// Memory
VertexBufferArray vba;
@@ -163,7 +163,7 @@ acDeviceCreate(const int id, const AcMeshInfo device_config, Device* device_hand
printf("Success!\n");
// Concurrency
for (int i = 0; i < NUM_STREAM_TYPES; ++i) {
for (int i = 0; i < NUM_STREAMS; ++i) {
cudaStreamCreateWithPriority(&device->streams[i], cudaStreamNonBlocking, 0);
}
@@ -228,7 +228,7 @@ acDeviceDestroy(Device device)
#endif
// Concurrency
for (int i = 0; i < NUM_STREAM_TYPES; ++i) {
for (int i = 0; i < NUM_STREAMS; ++i) {
cudaStreamDestroy(device->streams[i]);
}