This commit is contained in:
str4d 2021-12-20 17:40:42 +00:00
parent 77622277bb
commit c9927ad4ae
2 changed files with 0 additions and 544 deletions

View File

@ -1,266 +0,0 @@
window.BENCHMARK_DATA = {
"lastUpdate": 1639781757390,
"repoUrl": "https://github.com/zcash/orchard",
"entries": {
"Orchard Benchmarks": [
{
"commit": {
"author": {
"email": "jack@electriccoin.co",
"name": "str4d",
"username": "str4d"
},
"committer": {
"email": "noreply@github.com",
"name": "GitHub",
"username": "web-flow"
},
"distinct": true,
"id": "a061a861b3e01cf2fa14e9f8b93d8922f7cc6de8",
"message": "Merge pull request #266 from zcash/release-0.1.0-beta.1\n\nRelease 0.1.0-beta.1",
"timestamp": "2021-12-17T22:30:14Z",
"tree_id": "b230a23419d493fa1c517677f26067c1ec6d310e",
"url": "https://github.com/zcash/orchard/commit/a061a861b3e01cf2fa14e9f8b93d8922f7cc6de8"
},
"date": 1639781756452,
"tool": "cargo",
"benches": [
{
"name": "proving/bundle/1",
"value": 7519505742,
"range": "± 177278380",
"unit": "ns/iter"
},
{
"name": "proving/bundle/2",
"value": 7498469218,
"range": "± 115596264",
"unit": "ns/iter"
},
{
"name": "proving/bundle/3",
"value": 10970385010,
"range": "± 228111689",
"unit": "ns/iter"
},
{
"name": "proving/bundle/4",
"value": 14618428606,
"range": "± 268678355",
"unit": "ns/iter"
},
{
"name": "verifying/bundle/1",
"value": 37853713,
"range": "± 2234688",
"unit": "ns/iter"
},
{
"name": "verifying/bundle/2",
"value": 39772048,
"range": "± 2831460",
"unit": "ns/iter"
},
{
"name": "verifying/bundle/3",
"value": 45609437,
"range": "± 1772075",
"unit": "ns/iter"
},
{
"name": "verifying/bundle/4",
"value": 49117511,
"range": "± 3146601",
"unit": "ns/iter"
},
{
"name": "note-decryption/valid",
"value": 1423027,
"range": "± 41352",
"unit": "ns/iter"
},
{
"name": "note-decryption/invalid",
"value": 182232,
"range": "± 4340",
"unit": "ns/iter"
},
{
"name": "note-decryption/compact-valid",
"value": 1154511,
"range": "± 77481",
"unit": "ns/iter"
},
{
"name": "compact-note-decryption/invalid",
"value": 168216699,
"range": "± 5315213",
"unit": "ns/iter"
},
{
"name": "batch-note-decryption/valid/10",
"value": 27786289,
"range": "± 1042981",
"unit": "ns/iter"
},
{
"name": "batch-note-decryption/invalid/10",
"value": 3044941,
"range": "± 130362",
"unit": "ns/iter"
},
{
"name": "batch-note-decryption/compact-valid/10",
"value": 23974111,
"range": "± 1425109",
"unit": "ns/iter"
},
{
"name": "batch-note-decryption/compact-invalid/10",
"value": 2814380,
"range": "± 105692",
"unit": "ns/iter"
},
{
"name": "batch-note-decryption/valid/50",
"value": 138960150,
"range": "± 3108233",
"unit": "ns/iter"
},
{
"name": "batch-note-decryption/invalid/50",
"value": 14578634,
"range": "± 644857",
"unit": "ns/iter"
},
{
"name": "batch-note-decryption/compact-valid/50",
"value": 122989867,
"range": "± 6402509",
"unit": "ns/iter"
},
{
"name": "batch-note-decryption/compact-invalid/50",
"value": 14264546,
"range": "± 616909",
"unit": "ns/iter"
},
{
"name": "batch-note-decryption/valid/100",
"value": 277779147,
"range": "± 5856615",
"unit": "ns/iter"
},
{
"name": "batch-note-decryption/invalid/100",
"value": 28901117,
"range": "± 1507503",
"unit": "ns/iter"
},
{
"name": "batch-note-decryption/compact-valid/100",
"value": 242670290,
"range": "± 10399465",
"unit": "ns/iter"
},
{
"name": "batch-note-decryption/compact-invalid/100",
"value": 27417820,
"range": "± 2168982",
"unit": "ns/iter"
},
{
"name": "Poseidon/2-to-1",
"value": 45994,
"range": "± 3316",
"unit": "ns/iter"
},
{
"name": "Sinsemilla/hash-to-point/510",
"value": 164451,
"range": "± 11536",
"unit": "ns/iter"
},
{
"name": "Sinsemilla/hash/510",
"value": 169084,
"range": "± 13291",
"unit": "ns/iter"
},
{
"name": "Sinsemilla/commit/510",
"value": 281767,
"range": "± 24878",
"unit": "ns/iter"
},
{
"name": "Sinsemilla/short-commit/510",
"value": 299659,
"range": "± 13443",
"unit": "ns/iter"
},
{
"name": "Sinsemilla/hash-to-point/520",
"value": 167445,
"range": "± 8361",
"unit": "ns/iter"
},
{
"name": "Sinsemilla/hash/520",
"value": 172647,
"range": "± 11206",
"unit": "ns/iter"
},
{
"name": "Sinsemilla/commit/520",
"value": 302860,
"range": "± 19078",
"unit": "ns/iter"
},
{
"name": "Sinsemilla/short-commit/520",
"value": 304751,
"range": "± 18001",
"unit": "ns/iter"
},
{
"name": "Sinsemilla/hash-to-point/1086",
"value": 347067,
"range": "± 17802",
"unit": "ns/iter"
},
{
"name": "Sinsemilla/hash/1086",
"value": 365246,
"range": "± 24587",
"unit": "ns/iter"
},
{
"name": "Sinsemilla/commit/1086",
"value": 475851,
"range": "± 30799",
"unit": "ns/iter"
},
{
"name": "Sinsemilla/short-commit/1086",
"value": 470813,
"range": "± 42363",
"unit": "ns/iter"
},
{
"name": "derive_fvk",
"value": 591350,
"range": "± 28335",
"unit": "ns/iter"
},
{
"name": "default_address",
"value": 666715,
"range": "± 37600",
"unit": "ns/iter"
}
]
}
]
}
}

View File

@ -1,278 +0,0 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1, user-scalable=yes" />
<style>
html {
font-family: BlinkMacSystemFont,-apple-system,"Segoe UI",Roboto,Oxygen,Ubuntu,Cantarell,"Fira Sans","Droid Sans","Helvetica Neue",Helvetica,Arial,sans-serif;
-webkit-font-smoothing: antialiased;
background-color: #fff;
font-size: 16px;
}
body {
color: #4a4a4a;
margin: 8px;
font-size: 1em;
font-weight: 400;
}
header {
margin-bottom: 8px;
display: flex;
flex-direction: column;
}
main {
width: 100%;
display: flex;
flex-direction: column;
}
a {
color: #3273dc;
cursor: pointer;
text-decoration: none;
}
a:hover {
color: #000;
}
button {
color: #fff;
background-color: #3298dc;
border-color: transparent;
cursor: pointer;
text-align: center;
}
button:hover {
background-color: #2793da;
flex: none;
}
.spacer {
flex: auto;
}
.small {
font-size: 0.75rem;
}
footer {
margin-top: 16px;
display: flex;
align-items: center;
}
.header-label {
margin-right: 4px;
}
.benchmark-set {
margin: 8px 0;
width: 100%;
display: flex;
flex-direction: column;
}
.benchmark-title {
font-size: 3rem;
font-weight: 600;
word-break: break-word;
text-align: center;
}
.benchmark-graphs {
display: flex;
flex-direction: row;
justify-content: space-around;
align-items: center;
flex-wrap: wrap;
width: 100%;
}
.benchmark-chart {
max-width: 1000px;
}
</style>
<title>Benchmarks</title>
</head>
<body>
<header id="header">
<div class="header-item">
<strong class="header-label">Last Update:</strong>
<span id="last-update"></span>
</div>
<div class="header-item">
<strong class="header-label">Repository:</strong>
<a id="repository-link" rel="noopener"></a>
</div>
</header>
<main id="main"></main>
<footer>
<button id="dl-button">Download data as JSON</button>
<div class="spacer"></div>
<div class="small">Powered by <a rel="noopener" href="https://github.com/marketplace/actions/continuous-benchmark">github-action-benchmark</a></div>
</footer>
<script src="https://cdn.jsdelivr.net/npm/chart.js@2.9.2/dist/Chart.min.js"></script>
<script src="data.js"></script>
<script id="main-script">
'use strict';
(function() {
// Colors from https://github.com/github/linguist/blob/master/lib/linguist/languages.yml
const toolColors = {
cargo: '#dea584',
go: '#00add8',
benchmarkjs: '#f1e05a',
pytest: '#3572a5',
googlecpp: '#f34b7d',
catch2: '#f34b7d',
julia: '#a270ba',
customBiggerIsBetter: '#38ff38',
customSmallerIsBetter: '#ff3838',
_: '#333333'
};
function init() {
function collectBenchesPerTestCase(entries) {
const map = new Map();
for (const entry of entries) {
const {commit, date, tool, benches} = entry;
for (const bench of benches) {
const result = { commit, date, tool, bench };
const arr = map.get(bench.name);
if (arr === undefined) {
map.set(bench.name, [result]);
} else {
arr.push(result);
}
}
}
return map;
}
const data = window.BENCHMARK_DATA;
// Render header
document.getElementById('last-update').textContent = new Date(data.lastUpdate).toString();
const repoLink = document.getElementById('repository-link');
repoLink.href = data.repoUrl;
repoLink.textContent = data.repoUrl;
// Render footer
document.getElementById('dl-button').onclick = () => {
const dataUrl = 'data:,' + JSON.stringify(data, null, 2);
const a = document.createElement('a');
a.href = dataUrl;
a.download = 'benchmark_data.json';
a.click();
};
// Prepare data points for charts
return Object.keys(data.entries).map(name => ({
name,
dataSet: collectBenchesPerTestCase(data.entries[name]),
}));
}
function renderAllChars(dataSets) {
function renderGraph(parent, name, dataset) {
const canvas = document.createElement('canvas');
canvas.className = 'benchmark-chart';
parent.appendChild(canvas);
const color = toolColors[dataset.length > 0 ? dataset[0].tool : '_'];
const data = {
labels: dataset.map(d => d.commit.id.slice(0, 7)),
datasets: [
{
label: name,
data: dataset.map(d => d.bench.value),
borderColor: color,
backgroundColor: color + '60', // Add alpha for #rrggbbaa
}
],
};
const options = {
scales: {
xAxes: [
{
scaleLabel: {
display: true,
labelString: 'commit',
},
}
],
yAxes: [
{
scaleLabel: {
display: true,
labelString: dataset.length > 0 ? dataset[0].bench.unit : '',
},
ticks: {
beginAtZero: true,
}
}
],
},
tooltips: {
callbacks: {
afterTitle: items => {
const {index} = items[0];
const data = dataset[index];
return '\n' + data.commit.message + '\n\n' + data.commit.timestamp + ' committed by @' + data.commit.committer.username + '\n';
},
label: item => {
let label = item.value;
const { range, unit } = dataset[item.index].bench;
label += ' ' + unit;
if (range) {
label += ' (' + range + ')';
}
return label;
},
afterLabel: item => {
const { extra } = dataset[item.index].bench;
return extra ? '\n' + extra : '';
}
}
},
onClick: (_mouseEvent, activeElems) => {
if (activeElems.length === 0) {
return;
}
// XXX: Undocumented. How can we know the index?
const index = activeElems[0]._index;
const url = dataset[index].commit.url;
window.open(url, '_blank');
},
};
new Chart(canvas, {
type: 'line',
data,
options,
});
}
function renderBenchSet(name, benchSet, main) {
const setElem = document.createElement('div');
setElem.className = 'benchmark-set';
main.appendChild(setElem);
const nameElem = document.createElement('h1');
nameElem.className = 'benchmark-title';
nameElem.textContent = name;
setElem.appendChild(nameElem);
const graphsElem = document.createElement('div');
graphsElem.className = 'benchmark-graphs';
setElem.appendChild(graphsElem);
for (const [benchName, benches] of benchSet.entries()) {
renderGraph(graphsElem, benchName, benches)
}
}
const main = document.getElementById('main');
for (const {name, dataSet} of dataSets) {
renderBenchSet(name, dataSet, main);
}
}
renderAllChars(init()); // Start
})();
</script>
</body>
</html>