From f1eb1f41ab81571d23654bb15af655c17152bcd6 Mon Sep 17 00:00:00 2001 From: Joshua Bakita Date: Mon, 26 Feb 2024 20:36:27 -0500 Subject: Ensure all benchmarks support --help and cleanup --- constant_cycles_kernel.cu | 2 +- copy_experiments/copy_contender.cu | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/constant_cycles_kernel.cu b/constant_cycles_kernel.cu index db92b08..b45ae8c 100644 --- a/constant_cycles_kernel.cu +++ b/constant_cycles_kernel.cu @@ -16,7 +16,7 @@ int main(int argc, char **argv) { int res, *__unused; struct timespec start, end; - if (argc != 2) { + if (argc != 2 || !strcmp(argv[1], "--help") || !strcmp(argv[1], "-h")) { fprintf(stderr, "Usage: %s <# of millions of iterations, or -1 for infinite>\n", argv[0]); return 1; diff --git a/copy_experiments/copy_contender.cu b/copy_experiments/copy_contender.cu index 5514552..7e04c22 100644 --- a/copy_experiments/copy_contender.cu +++ b/copy_experiments/copy_contender.cu @@ -1,8 +1,8 @@ -/* Copyright 2023 Joshua Bakita +/* Copyright 2024 Joshua Bakita * Serially dispatch copies in one direction and record the transfer times * In order to both record individual copy times, and maintain constant * pending copies, this program relies on the implict synchronization which - * occurs in CUDA when unidirectional copies are dispatched into seprat + * occurs in CUDA when unidirectional copies are dispatched into separate * streams. * * Parameters include the size of the copy to perform and the number of times @@ -20,7 +20,7 @@ typedef enum { } copy_mode_t; void usage(char** argv) { - fprintf(stderr, "Usage: %s <# of 4KiB pages to copy> <# of iterations>" + fprintf(stderr, "Usage: %s <# of 4KiB pages to copy> <# of iterations> " "\n", argv[0]); } -- cgit v1.2.2