authorgravatar for harry.eakins@googlemail.comHarry Eakins <harry.eakins@googlemail.com> 2018-04-19 23:54:18-07:00
committergravatar for marc@tiehu.isMarc Tiehuis <marc@tiehu.is> 2018-04-21 11:06:10+12:00
logeef4bbb65f40f5101aeb8e89bb6e6f06343cc2d0
treec24b8e80fda961c16b5c24f4957bb4407525f439
parentb229aff34aeef059823c1ab7dfd3a1f5c4445d9e

Changed all MB to MiB


1 files changed, 3 insertions(+), 4 deletions(-)

std/crypto/throughput_test.zig+3-4
......@@ -14,8 +14,8 @@ const c = @cImport({
1414});
1515const HashFunction = @import("md5.zig").Md5;
1616
17const MB = 1024 * 1024;
18const BytesToHash = 1024 * MB;
17const MiB = 1024 * 1024;
18const BytesToHash = 1024 * MiB;
1919
2020pub fn main() !void {
2121 var stdout_file = try std.io.getStdOut();
......@@ -37,6 +37,5 @@ pub fn main() !void {
3737 const elapsed_s = f64(end - start) / f64(c.CLOCKS_PER_SEC);
3838 const throughput = u64(BytesToHash / elapsed_s);
3939
40 try stdout.print("{}: ", @typeName(HashFunction));
41 try stdout.print("{} MB/s\n", throughput / (1 * MB));
40 try stdout.print("{}: {} MiB/s\n", @typeName(HashFunction), throughput / (1 * MiB));
4241}