Lines Matching +full:low +full:- +full:precision
2 * fp-bench.c - A collection of simple floating point microbenchmarks.
7 * See the COPYING file in the top-level directory.
51 enum precision { enum
125 static enum precision precision; variable
147 static void update_random_ops(int n_ops, enum precision prec) in update_random_ops()
179 uint64_t lo = r.low; in update_random_ops()
194 static void fill_random(union fp *ops, int n_ops, enum precision prec, in fill_random()
230 * on the compiler to unfold this at compile-time.
232 static void bench(enum precision prec, enum op op, int n_ops, bool no_neg) in bench()
256 res.f = a - b; in bench()
291 res.d = a - b; in bench()
421 ns_elapsed += get_clock() - t0; in bench()
493 f = bench_funcs[operation][precision]; in run_bench()
498 /* @arr must be NULL-terminated */
508 return -1; in find_name()
518 fprintf(stderr, " -d = duration, in seconds. Default: %d\n", in usage_complete()
520 fprintf(stderr, " -h = show this help message.\n"); in usage_complete()
521 fprintf(stderr, " -o = floating point operation (%s). Default: %s\n", in usage_complete()
523 fprintf(stderr, " -p = floating point precision (single, double, quad[soft only]). " in usage_complete()
525 fprintf(stderr, " -r = rounding mode (even, zero, down, up, tieaway). " in usage_complete()
527 fprintf(stderr, " -t = tester (%s). Default: %s\n", in usage_complete()
529 fprintf(stderr, " -z = flush inputs to zero (soft tester only). " in usage_complete()
531 fprintf(stderr, " -Z = flush output to zero (soft tester only). " in usage_complete()
547 return -1; in round_name_to_mode()
641 precision = PREC_SINGLE; in parse_args()
643 precision = PREC_DOUBLE; in parse_args()
645 precision = PREC_QUAD; in parse_args()
647 fprintf(stderr, "Unsupported precision '%s'\n", optarg); in parse_args()
675 /* set precision and rounding mode based on the tester */ in parse_args()
682 switch (precision) { in parse_args()
684 precision = PREC_FLOAT32; in parse_args()
687 precision = PREC_FLOAT64; in parse_args()
690 precision = PREC_FLOAT128; in parse_args()