Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/netbsd-6]: src/usr.bin/nbperf Pull up following revision(s) (requested b...
details: https://anonhg.NetBSD.org/src/rev/2d888a9de411
branches: netbsd-6
changeset: 776625:2d888a9de411
user: bouyer <bouyer%NetBSD.org@localhost>
date: Wed May 21 21:00:43 2014 +0000
description:
Pull up following revision(s) (requested by joerg in ticket #1059):
usr.bin/nbperf/nbperf-bdz.c: revision 1.9 via patch
Most CPUs implement shifts modulo the width, but ARM doesn't. Don't
depend on this UB.
diffstat:
usr.bin/nbperf/nbperf-bdz.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diffs (27 lines):
diff -r cbe91e5478ef -r 2d888a9de411 usr.bin/nbperf/nbperf-bdz.c
--- a/usr.bin/nbperf/nbperf-bdz.c Wed May 21 20:56:36 2014 +0000
+++ b/usr.bin/nbperf/nbperf-bdz.c Wed May 21 21:00:43 2014 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: nbperf-bdz.c,v 1.4.4.2 2013/02/14 22:06:18 jdc Exp $ */
+/* $NetBSD: nbperf-bdz.c,v 1.4.4.3 2014/05/21 21:00:43 bouyer Exp $ */
/*-
* Copyright (c) 2009, 2012 The NetBSD Foundation, Inc.
* All rights reserved.
@@ -36,7 +36,7 @@
#endif
#include <sys/cdefs.h>
-__RCSID("$NetBSD: nbperf-bdz.c,v 1.4.4.2 2013/02/14 22:06:18 jdc Exp $");
+__RCSID("$NetBSD: nbperf-bdz.c,v 1.4.4.3 2014/05/21 21:00:43 bouyer Exp $");
#include <err.h>
#include <inttypes.h>
@@ -240,7 +240,7 @@
fprintf(nbperf->output,
"\tidx2 = idx - holes64[idx >> 6] - holes64k[idx >> 16];\n"
"\tidx2 -= popcount64(g1[idx >> 6] & g2[idx >> 6]\n"
- "\t & (((uint64_t)1 << idx) - 1));\n"
+ "\t & (((uint64_t)1 << (idx & 63)) - 1));\n"
"\treturn idx2;");
fprintf(nbperf->output, "}\n");
Home |
Main Index |
Thread Index |
Old Index