lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1392053356-23024-7-git-send-email-dzickus@redhat.com>
Date:	Mon, 10 Feb 2014 12:29:01 -0500
From:	Don Zickus <dzickus@...hat.com>
To:	acme@...stprotocols.net
Cc:	LKML <linux-kernel@...r.kernel.org>, jolsa@...hat.com,
	jmario@...hat.com, fowles@...each.com, eranian@...gle.com,
	Don Zickus <dzickus@...hat.com>
Subject: [PATCH 06/21] perf, stat: FIXME Stddev calculation is incorrect

Fix the standard deviation calculation.  The current calculation
does the standard deviation mean which is slightly different.

Signed-off-by: Don Zickus <dzickus@...hat.com>
---
 tools/perf/util/stat.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/tools/perf/util/stat.c b/tools/perf/util/stat.c
index 6506b3d..58aa661 100644
--- a/tools/perf/util/stat.c
+++ b/tools/perf/util/stat.c
@@ -47,7 +47,8 @@ double stddev_stats(struct stats *stats)
 		return 0.0;
 
 	variance = stats->M2 / (stats->n - 1);
-	variance_mean = variance / stats->n;
+	//variance_mean = variance / stats->n;
+	variance_mean = variance;
 
 	return sqrt(variance_mean);
 }
-- 
1.7.11.7

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ