1 /*
2  * Copyright (c) 2018 Nordic Semiconductor ASA
3  * Copyright (c) 2016 Intel Corporation
4  *
5  * SPDX-License-Identifier: Apache-2.0
6  */
7 
8 #include "kernel_shell.h"
9 
10 #include <zephyr/kernel.h>
11 
cmd_kernel_cycles(const struct shell * sh,size_t argc,char ** argv)12 static int cmd_kernel_cycles(const struct shell *sh, size_t argc, char **argv)
13 {
14 	ARG_UNUSED(argc);
15 	ARG_UNUSED(argv);
16 
17 	shell_print(sh, "cycles: %u hw cycles", k_cycle_get_32());
18 	return 0;
19 }
20 
21 KERNEL_CMD_ADD(cycles, NULL, "Kernel cycles.", cmd_kernel_cycles);
22