Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/external/cddl/osnet/dist/cmd/ztest Revert my last wrong chan...
details: https://anonhg.NetBSD.org/src/rev/72db70f3cf7d
branches: trunk
changeset: 747444:72db70f3cf7d
user: haad <haad%NetBSD.org@localhost>
date: Tue Sep 15 02:04:12 2009 +0000
description:
Revert my last wrong change this will need more work.
diffstat:
external/cddl/osnet/dist/cmd/ztest/ztest.c | 13 ++++---------
1 files changed, 4 insertions(+), 9 deletions(-)
diffs (33 lines):
diff -r 8e890e391f31 -r 72db70f3cf7d external/cddl/osnet/dist/cmd/ztest/ztest.c
--- a/external/cddl/osnet/dist/cmd/ztest/ztest.c Tue Sep 15 01:48:41 2009 +0000
+++ b/external/cddl/osnet/dist/cmd/ztest/ztest.c Tue Sep 15 02:04:12 2009 +0000
@@ -2983,13 +2983,10 @@
(double)zi->zi_call_total / zi->zi_call_target >
(double)(now - zs->zs_start_time) / (zopt_time * NANOSEC))
continue;
-#ifdef __HAVE_ATOMIC64_OPS
+
atomic_add_64(&zi->zi_calls, 1);
atomic_add_64(&zi->zi_call_total, 1);
-#else
- atomic_add_32(&zi->zi_calls, 1);
- atomic_add_32(&zi->zi_call_total, 1);
-#end
+
za->za_diroff = (za->za_instance * ZTEST_FUNCS + f) *
ZTEST_DIRSIZE;
za->za_diroff_shared = (1ULL << 63);
@@ -2998,11 +2995,9 @@
zi->zi_func(za);
functime = gethrtime() - now;
-#ifdef __HAVE_ATOMIC64_OPS
+
atomic_add_64(&zi->zi_call_time, functime);
-#else
- atomic_add_32(&zi->zi_call_time, functime);
-#endif
+
if (zopt_verbose >= 4) {
Dl_info dli;
(void) dladdr((void *)zi->zi_func, &dli);
Home |
Main Index |
Thread Index |
Old Index