diff options
| author | Sadeep Madurange <sadeep@asciimx.com> | 2026-04-19 11:46:27 +0800 |
|---|---|---|
| committer | Sadeep Madurange <sadeep@asciimx.com> | 2026-04-19 11:46:27 +0800 |
| commit | dd3af6be8d1c1a12d9cefc072928282056892f3a (patch) | |
| tree | b33eb62d1ba997b00833da523e7e833c6208da39 | |
| parent | 015192c00e9bdc178eac2194228d7f5e190e88d3 (diff) | |
| download | urn-dd3af6be8d1c1a12d9cefc072928282056892f3a.tar.gz | |
Repo size benchmarks.
| -rw-r--r-- | bm/BM_REPO_SIZE_200_20.txt | 48 | ||||
| -rw-r--r-- | bm/BM_REPO_SIZE_5000_50.txt | 48 | ||||
| -rw-r--r-- | bm/bm_size.pl | 17 | ||||
| -rw-r--r-- | urn | 2 |
4 files changed, 106 insertions, 9 deletions
diff --git a/bm/BM_REPO_SIZE_200_20.txt b/bm/BM_REPO_SIZE_200_20.txt new file mode 100644 index 0000000..99d81c7 --- /dev/null +++ b/bm/BM_REPO_SIZE_200_20.txt @@ -0,0 +1,48 @@ +============================================================= + BENCHMARK: 200 files @ 20 depth +============================================================= + +ACTION: Status +------------------------------------------------------------- +METRIC | URN | GIT +----------------+----------------------+--------------------- +Real Time | 0.10s | 0.00s +Max RSS | 0.02 MB | 0.00 MB +Page Faults | Maj:0 / Min:0 | Maj:0 / Min:0 +Meta Inodes | 6 | 27 +Meta Size | 20 KB | 116 KB +------------------------------------------------------------- + +ACTION: Add +------------------------------------------------------------- +METRIC | URN | GIT +----------------+----------------------+--------------------- +Real Time | 0.17s | 0.18s +Max RSS | 0.02 MB | 0.00 MB +Page Faults | Maj:0 / Min:0 | Maj:0 / Min:0 +Meta Inodes | 225 | 373 +Meta Size | 3596 KB | 3440 KB +------------------------------------------------------------- + +ACTION: Commit +------------------------------------------------------------- +METRIC | URN | GIT +----------------+----------------------+--------------------- +Real Time | 0.18s | 0.05s +Max RSS | 0.02 MB | 0.01 MB +Page Faults | Maj:0 / Min:0 | Maj:0 / Min:0 +Meta Inodes | 344 | 412 +Meta Size | 4096 KB | 3596 KB +------------------------------------------------------------- + +ACTION: Status(Clean) +------------------------------------------------------------- +METRIC | URN | GIT +----------------+----------------------+--------------------- +Real Time | 0.11s | 0.02s +Max RSS | 0.02 MB | 0.00 MB +Page Faults | Maj:0 / Min:0 | Maj:0 / Min:0 +Meta Inodes | 344 | 412 +Meta Size | 4096 KB | 3596 KB +------------------------------------------------------------- + diff --git a/bm/BM_REPO_SIZE_5000_50.txt b/bm/BM_REPO_SIZE_5000_50.txt new file mode 100644 index 0000000..06d1289 --- /dev/null +++ b/bm/BM_REPO_SIZE_5000_50.txt @@ -0,0 +1,48 @@ +============================================================= + BENCHMARK: 5000 files @ 50 depth +============================================================= + +ACTION: Status +------------------------------------------------------------- +METRIC | URN | GIT +----------------+----------------------+--------------------- +Real time | 0.26s | 0.00s +Max RSS | 0.02 MB | 0.00 MB +Page faults | Maj:0 / Min:0 | Maj:0 / Min:0 +Inodes | 6 | 27 +Repo size | 20 KB | 116 KB +------------------------------------------------------------- + +ACTION: Add +------------------------------------------------------------- +METRIC | URN | GIT +----------------+----------------------+--------------------- +Real time | 2.89s | 4.66s +Max RSS | 0.02 MB | 0.01 MB +Page faults | Maj:0 / Min:0 | Maj:0 / Min:0 +Inodes | 5055 | 5284 +Repo size | 89724 KB | 69916 KB +------------------------------------------------------------- + +ACTION: Commit +------------------------------------------------------------- +METRIC | URN | GIT +----------------+----------------------+--------------------- +Real time | 1.22s | 0.96s +Max RSS | 0.03 MB | 0.01 MB +Page faults | Maj:0 / Min:0 | Maj:0 / Min:0 +Inodes | 5264 | 5342 +Repo size | 91900 KB | 70148 KB +------------------------------------------------------------- + +ACTION: Status(Clean) +------------------------------------------------------------- +METRIC | URN | GIT +----------------+----------------------+--------------------- +Real time | 0.34s | 0.11s +Max RSS | 0.02 MB | 0.01 MB +Page faults | Maj:0 / Min:0 | Maj:0 / Min:0 +Inodes | 5264 | 5342 +Repo size | 91900 KB | 70148 KB +------------------------------------------------------------- + diff --git a/bm/bm_size.pl b/bm/bm_size.pl index e9de614..21a05b0 100644 --- a/bm/bm_size.pl +++ b/bm/bm_size.pl @@ -16,7 +16,7 @@ my $seed_bin = abs_path("seed.pl"); my $bm_repo = "bm_repo"; my %results; -my @actions = qw(Status Add Commit); +my @actions = qw(Status Add Commit Status(Clean)); sub count_inodes { my $dir = shift; @@ -46,9 +46,10 @@ sub run_benchmark { system("$init_cmd > /dev/null 2>&1"); my %cmds = ( - "Status" => ($tool_name eq "URN") ? "perl $urn_bin status" : "git status", - "Add" => ($tool_name eq "URN") ? "perl $urn_bin add ." : "git add .", - "Commit" => ($tool_name eq "URN") ? "perl $urn_bin commit -m 'bench'" : "git commit -m 'bench'", + "Status" => ($tool_name eq "URN") ? "perl $urn_bin status" : "git status", + "Add" => ($tool_name eq "URN") ? "perl $urn_bin add ." : "git add .", + "Commit" => ($tool_name eq "URN") ? "perl $urn_bin commit -m 'bench'" : "git commit -m 'bench'", + "Status(Clean)" => ($tool_name eq "URN") ? "perl $urn_bin status" : "git status", ); foreach my $action (@actions) { @@ -92,11 +93,11 @@ foreach my $action (@actions) { print $res "-------------------------------------------------------------\n"; printf $res "%-15s | %-20s | %-20s\n", "METRIC", "URN", "GIT"; print $res "----------------+----------------------+---------------------\n"; - printf $res "%-15s | %20s | %20s\n", "Real Time", $u->{real}."s", $g->{real}."s"; + printf $res "%-15s | %20s | %20s\n", "Real time", $u->{real}."s", $g->{real}."s"; printf $res "%-15s | %20s | %20s\n", "Max RSS", $u->{rss}, $g->{rss}; - printf $res "%-15s | %20s | %20s\n", "Page Faults", $u->{faults}, $g->{faults}; - printf $res "%-15s | %20s | %20s\n", "Meta Inodes", $u->{inodes}, $g->{inodes}; - printf $res "%-15s | %20s | %20s\n", "Meta Size", $u->{disk}, $g->{disk}; + printf $res "%-15s | %20s | %20s\n", "Page faults", $u->{faults}, $g->{faults}; + printf $res "%-15s | %20s | %20s\n", "Inodes", $u->{inodes}, $g->{inodes}; + printf $res "%-15s | %20s | %20s\n", "Repo size", $u->{disk}, $g->{disk}; print $res "-------------------------------------------------------------\n\n"; } @@ -23,7 +23,7 @@ use constant REV_DIR => REPO . '/rev'; # Revisions use constant TMP_DIR => REPO . '/stg'; # Staging area use constant CHUNK_LEN => 4096; -use constant MEM_LIMIT => 10 * 1024 * 1024; +use constant MEM_LIMIT => 256 * 1024 * 1024; use constant IO_LAYER => ":raw:perlio(layer=" . CHUNK_LEN . ")"; Getopt::Long::Configure("bundling"); |
