mirror of
https://github.com/GOSTSec/sgminer
synced 2025-01-11 07:17:58 +00:00
Make --ndevs display verbose opencl information as well to make debugging version information easier.
This commit is contained in:
parent
b8f845b478
commit
53095da326
6
main.c
6
main.c
@ -1842,9 +1842,9 @@ struct device_api opencl_api;
|
|||||||
|
|
||||||
static char *print_ndevs_and_exit(int *ndevs)
|
static char *print_ndevs_and_exit(int *ndevs)
|
||||||
{
|
{
|
||||||
|
opt_log_output = true;
|
||||||
opencl_api.api_detect();
|
opencl_api.api_detect();
|
||||||
printf("%i GPU devices detected\n", *ndevs);
|
applog(LOG_INFO, "%i GPU devices detected", *ndevs);
|
||||||
fflush(stdout);
|
|
||||||
exit(*ndevs);
|
exit(*ndevs);
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
@ -1882,7 +1882,7 @@ static struct opt_table opt_cmdline_table[] = {
|
|||||||
#ifdef HAVE_OPENCL
|
#ifdef HAVE_OPENCL
|
||||||
OPT_WITHOUT_ARG("--ndevs|-n",
|
OPT_WITHOUT_ARG("--ndevs|-n",
|
||||||
print_ndevs_and_exit, &nDevs,
|
print_ndevs_and_exit, &nDevs,
|
||||||
"Enumerate number of detected GPUs and exit"),
|
"Display number of detected GPUs, OpenCL information, and exit"),
|
||||||
#endif
|
#endif
|
||||||
OPT_WITHOUT_ARG("--version|-V",
|
OPT_WITHOUT_ARG("--version|-V",
|
||||||
opt_version_and_exit, packagename,
|
opt_version_and_exit, packagename,
|
||||||
|
Loading…
Reference in New Issue
Block a user