File Index
Files and directories
Sign in
FILE

benchmark.h

File preview with syntax highlighting.

linux-6.19.14/tools/power/cpupower/bench/benchmark.h OBJECTIVE-C
 1/* SPDX-License-Identifier: GPL-2.0-or-later */
 2/*  cpufreq-bench CPUFreq microbenchmark
 3 *
 4 *  Copyright (C) 2008 Christian Kornacker <ckornacker@suse.de>
 5 */
 6
 7/* load loop, this schould take about 1 to 2ms to complete */
 8#define ROUNDS(x) {unsigned int rcnt;			       \
 9		for (rcnt = 0; rcnt < x*1000; rcnt++) { \
10			(void)(((int)(pow(rcnt, rcnt) * \
11				      sqrt(rcnt*7230970)) ^ 7230716) ^ \
12				      (int)atan2(rcnt, rcnt));	       \
13		} }							\
14
15
16void start_benchmark(struct config *config);
~/ Read-only file preview.