From ce9d162dd31f1ef84b94c373effb80f3083c65ef Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Wed, 15 Apr 2026 22:12:24 +0000 Subject: [PATCH 1/9] feat: add compute-perf mode for kernel build benchmarks --- package.json | 7 ++ src/compute-perf/benchmark.ts | 194 ++++++++++++++++++++++++++++++++++ src/compute-perf/providers.ts | 48 +++++++++ src/compute-perf/scoring.ts | 67 ++++++++++++ src/compute-perf/table.ts | 118 +++++++++++++++++++++ src/compute-perf/types.ts | 54 ++++++++++ src/run.ts | 63 ++++++++++- 7 files changed, 549 insertions(+), 2 deletions(-) create mode 100644 src/compute-perf/benchmark.ts create mode 100644 src/compute-perf/providers.ts create mode 100644 src/compute-perf/scoring.ts create mode 100644 src/compute-perf/table.ts create mode 100644 src/compute-perf/types.ts diff --git a/package.json b/package.json index 932c58d..a7f8e7d 100644 --- a/package.json +++ b/package.json @@ -21,6 +21,13 @@ "bench:vercel": "tsx src/run.ts --provider vercel", "bench:just-bash": "tsx src/run.ts --provider just-bash", "bench:sprites": "tsx src/run.ts --provider sprites", + "bench:compute-perf": "tsx src/run.ts --mode compute-perf", + "bench:compute-perf:blaxel": "tsx src/run.ts --mode compute-perf --provider blaxel", + "bench:compute-perf:daytona": "tsx src/run.ts --mode compute-perf --provider daytona", + "bench:compute-perf:e2b": "tsx src/run.ts --mode compute-perf --provider e2b", + "bench:compute-perf:hopx": "tsx src/run.ts --mode compute-perf --provider hopx", + "bench:compute-perf:namespace": "tsx src/run.ts --mode compute-perf --provider namespace", + "bench:compute-perf:runloop": "tsx src/run.ts --mode compute-perf --provider runloop", "bench:browser": "tsx src/run.ts --mode browser", "bench:browser:browserbase": "tsx src/run.ts --mode browser --provider browserbase", "bench:storage": "tsx src/run.ts --mode storage", diff --git a/src/compute-perf/benchmark.ts b/src/compute-perf/benchmark.ts new file mode 100644 index 0000000..236b94a --- /dev/null +++ b/src/compute-perf/benchmark.ts @@ -0,0 +1,194 @@ +import { computeStats } from '../util/stats.js'; +import { withTimeout } from '../util/timeout.js'; +import type { ComputePerfBenchmarkResult, ComputePerfProviderConfig, ComputePerfTimingResult } from './types.js'; +import { KERNEL_VERSION } from './types.js'; + +const KERNEL_TARBALL = `linux-${KERNEL_VERSION}.tar.xz`; +const KERNEL_URL = `https://cdn.kernel.org/pub/linux/kernel/v6.x/${KERNEL_TARBALL}`; +const KERNEL_SHA256 = '335aeec4f6af045d958e2dabaf55222349933e396df17b5cd31798f5ec7f8c35'; + +function parseResultLine(output: string): { buildMs: number; cpuCount?: number; memTotalKb?: number } | null { + const markerLine = output + .split('\n') + .find(line => line.startsWith('__COMPUTE_PERF_RESULT__')); + + if (!markerLine) return null; + + const build = markerLine.match(/buildMs=(\d+)/); + const cpu = markerLine.match(/cpu=(\d+)/); + const mem = markerLine.match(/memKb=(\d+)/); + + if (!build) return null; + + return { + buildMs: Number(build[1]), + cpuCount: cpu ? Number(cpu[1]) : undefined, + memTotalKb: mem ? Number(mem[1]) : undefined, + }; +} + +function getKernelBuildScript(): string { + return [ + 'set -euo pipefail', + 'WORKDIR=/tmp/compute-perf-linux', + 'rm -rf "$WORKDIR"', + 'mkdir -p "$WORKDIR"', + 'cd "$WORKDIR"', + 'if command -v curl >/dev/null 2>&1; then', + ` curl -fsSL --retry 3 "${KERNEL_URL}" -o "${KERNEL_TARBALL}"`, + 'elif command -v wget >/dev/null 2>&1; then', + ` wget -qO "${KERNEL_TARBALL}" "${KERNEL_URL}"`, + 'else', + ' echo "Missing downloader: curl or wget"', + ' exit 2', + 'fi', + `echo "${KERNEL_SHA256} ${KERNEL_TARBALL}" | sha256sum -c -`, + `tar -xf "${KERNEL_TARBALL}"`, + `cd "linux-${KERNEL_VERSION}"`, + 'for cmd in make gcc ld bison flex bc; do', + ' command -v "$cmd" >/dev/null 2>&1 || { echo "Missing dependency: $cmd"; exit 3; }', + 'done', + 'make defconfig >/dev/null', + 'START_NS=$(date +%s%N)', + 'make -j"$(nproc)" bzImage >/tmp/compute-perf-build.log 2>&1', + 'END_NS=$(date +%s%N)', + 'BUILD_MS=$(( (END_NS - START_NS) / 1000000 ))', + 'CPU_COUNT=$(nproc)', + "MEM_TOTAL_KB=$(awk '/MemTotal:/ { print $2 }' /proc/meminfo)", + 'echo "__COMPUTE_PERF_RESULT__ buildMs=${BUILD_MS} cpu=${CPU_COUNT} memKb=${MEM_TOTAL_KB}"', + ].join('; '); +} + +async function runComputePerfIteration( + compute: any, + timeout: number, + sandboxOptions?: Record, + destroyTimeoutMs: number = 15_000, +): Promise { + let sandbox: any = null; + + try { + sandbox = await withTimeout( + compute.sandbox.create(sandboxOptions), + timeout, + 'Sandbox creation timed out', + ); + + const iterationStart = performance.now(); + const command = `bash -lc '${getKernelBuildScript().replace(/'/g, "'\\''")}'`; + + const result = await withTimeout( + sandbox.runCommand(command), + timeout, + 'Kernel build command timed out', + ) as { exitCode: number; stdout?: string; stderr?: string }; + + if (result.exitCode !== 0) { + const details = [result.stderr, result.stdout] + .filter(Boolean) + .join('\n') + .trim(); + throw new Error(`Command failed with exit code ${result.exitCode}${details ? `: ${details}` : ''}`); + } + + const totalMs = performance.now() - iterationStart; + const parsed = parseResultLine(`${result.stdout || ''}\n${result.stderr || ''}`); + if (!parsed) { + throw new Error('Unable to parse build metrics from command output'); + } + + return { + totalMs, + buildMs: parsed.buildMs, + cpuCount: parsed.cpuCount, + memTotalKb: parsed.memTotalKb, + }; + } finally { + if (sandbox) { + let timer: ReturnType | undefined; + try { + await Promise.race([ + sandbox.destroy(), + new Promise((_, reject) => { + timer = setTimeout(() => reject(new Error('Destroy timeout')), destroyTimeoutMs); + }), + ]); + } catch (err) { + console.warn(` [cleanup] destroy failed: ${err instanceof Error ? err.message : String(err)}`); + } finally { + if (timer) clearTimeout(timer); + } + } + } +} + +export async function runComputePerfBenchmark(config: ComputePerfProviderConfig): Promise { + const { + name, + iterations = 5, + timeout = 2_700_000, + requiredEnvVars, + sandboxOptions, + destroyTimeoutMs, + } = config; + + const missingVars = requiredEnvVars.filter(v => !process.env[v]); + if (missingVars.length > 0) { + return { + provider: name, + mode: 'compute-perf', + kernelVersion: KERNEL_VERSION, + iterations: [], + summary: { + buildMs: { median: 0, p95: 0, p99: 0 }, + totalMs: { median: 0, p95: 0, p99: 0 }, + }, + skipped: true, + skipReason: `Missing: ${missingVars.join(', ')}`, + }; + } + + const compute = config.createCompute(); + const results: ComputePerfTimingResult[] = []; + + console.log(`\n--- Compute Perf: ${name} (${iterations} iterations, linux-${KERNEL_VERSION}) ---`); + + for (let i = 0; i < iterations; i++) { + console.log(` Iteration ${i + 1}/${iterations}...`); + + try { + const iterationResult = await runComputePerfIteration( + compute, + timeout, + sandboxOptions, + destroyTimeoutMs, + ); + results.push(iterationResult); + console.log( + ` Build: ${(iterationResult.buildMs / 1000).toFixed(2)}s | Total: ${(iterationResult.totalMs / 1000).toFixed(2)}s` + + `${iterationResult.cpuCount ? ` | CPU: ${iterationResult.cpuCount}` : ''}`, + ); + } catch (err) { + const error = err instanceof Error ? err.message : String(err); + console.log(` FAILED: ${error}`); + results.push({ totalMs: 0, buildMs: 0, error }); + } + } + + const successful = results.filter(r => !r.error); + + return { + provider: name, + mode: 'compute-perf', + kernelVersion: KERNEL_VERSION, + iterations: results, + summary: { + buildMs: successful.length > 0 + ? computeStats(successful.map(r => r.buildMs)) + : { median: 0, p95: 0, p99: 0 }, + totalMs: successful.length > 0 + ? computeStats(successful.map(r => r.totalMs)) + : { median: 0, p95: 0, p99: 0 }, + }, + }; +} diff --git a/src/compute-perf/providers.ts b/src/compute-perf/providers.ts new file mode 100644 index 0000000..fe9a129 --- /dev/null +++ b/src/compute-perf/providers.ts @@ -0,0 +1,48 @@ +import { e2b } from '@computesdk/e2b'; +import { daytona } from '@computesdk/daytona'; +import { blaxel } from '@computesdk/blaxel'; +import { hopx } from '@computesdk/hopx'; +import { namespace } from '@computesdk/namespace'; +import { runloop } from '@computesdk/runloop'; +import type { ComputePerfProviderConfig } from './types.js'; + +/** + * Providers that participate in sustained compute benchmark runs. + * + * Keep this list intentionally narrow to providers that position around + * runner-style or general-purpose compute performance. + */ +export const computePerfProviders: ComputePerfProviderConfig[] = [ + { + name: 'blaxel', + requiredEnvVars: ['BL_API_KEY', 'BL_WORKSPACE'], + createCompute: () => blaxel({ apiKey: process.env.BL_API_KEY!, workspace: process.env.BL_WORKSPACE!, region: 'us-was-1' }), + }, + { + name: 'daytona', + requiredEnvVars: ['DAYTONA_API_KEY'], + createCompute: () => daytona({ apiKey: process.env.DAYTONA_API_KEY! }), + sandboxOptions: { autoStopInterval: 15, autoDeleteInterval: 0 }, + }, + { + name: 'e2b', + requiredEnvVars: ['E2B_API_KEY'], + createCompute: () => e2b({ apiKey: process.env.E2B_API_KEY! }), + }, + { + name: 'hopx', + requiredEnvVars: ['HOPX_API_KEY'], + createCompute: () => hopx({ apiKey: process.env.HOPX_API_KEY! }), + }, + { + name: 'namespace', + requiredEnvVars: ['NSC_TOKEN'], + createCompute: () => namespace({ token: process.env.NSC_TOKEN! }), + sandboxOptions: { image: 'node:22' }, + }, + { + name: 'runloop', + requiredEnvVars: ['RUNLOOP_API_KEY'], + createCompute: () => runloop({ apiKey: process.env.RUNLOOP_API_KEY! }), + }, +]; diff --git a/src/compute-perf/scoring.ts b/src/compute-perf/scoring.ts new file mode 100644 index 0000000..c5f5fbe --- /dev/null +++ b/src/compute-perf/scoring.ts @@ -0,0 +1,67 @@ +import type { ComputePerfBenchmarkResult, ComputePerfStats } from './types.js'; + +export interface ComputePerfScoringWeights { + median: number; + p95: number; + p99: number; +} + +export const DEFAULT_COMPUTE_PERF_WEIGHTS: ComputePerfScoringWeights = { + median: 0.60, + p95: 0.25, + p99: 0.15, +}; + +/** + * Ceiling for build-time metric scoring. + * 30 minutes at or above scores 0. + */ +const BUILD_CEILING_MS = 30 * 60 * 1000; + +function scoreMetric(valueMs: number): number { + return Math.max(0, 100 * (1 - valueMs / BUILD_CEILING_MS)); +} + +export function computeComputePerfSuccessRate(result: ComputePerfBenchmarkResult): number { + if (result.skipped || result.iterations.length === 0) return 0; + const successful = result.iterations.filter(i => !i.error).length; + return successful / result.iterations.length; +} + +function computeBuildScore( + stats: ComputePerfStats, + weights: ComputePerfScoringWeights = DEFAULT_COMPUTE_PERF_WEIGHTS, +): number { + return ( + weights.median * scoreMetric(stats.median) + + weights.p95 * scoreMetric(stats.p95) + + weights.p99 * scoreMetric(stats.p99) + ); +} + +export function computeComputePerfCompositeScores( + results: ComputePerfBenchmarkResult[], + weights: ComputePerfScoringWeights = DEFAULT_COMPUTE_PERF_WEIGHTS, +): void { + for (const result of results) { + const successRate = computeComputePerfSuccessRate(result); + result.successRate = successRate; + + if (result.skipped || successRate === 0) { + result.compositeScore = 0; + continue; + } + + const buildScore = computeBuildScore(result.summary.buildMs, weights); + result.compositeScore = Math.round(buildScore * successRate * 100) / 100; + } +} + +export function sortComputePerfByCompositeScore(results: ComputePerfBenchmarkResult[]): ComputePerfBenchmarkResult[] { + return [...results].sort((a, b) => { + if (a.skipped && !b.skipped) return 1; + if (!a.skipped && b.skipped) return -1; + if (a.skipped && b.skipped) return 0; + return (b.compositeScore ?? 0) - (a.compositeScore ?? 0); + }); +} diff --git a/src/compute-perf/table.ts b/src/compute-perf/table.ts new file mode 100644 index 0000000..1141fc9 --- /dev/null +++ b/src/compute-perf/table.ts @@ -0,0 +1,118 @@ +import type { ComputePerfBenchmarkResult } from './types.js'; +import { sortComputePerfByCompositeScore } from './scoring.js'; + +function pad(str: string, width: number): string { + return str.padEnd(width); +} + +function formatSeconds(ms: number): string { + return (ms / 1000).toFixed(2); +} + +function round(n: number): number { + return Math.round(n * 100) / 100; +} + +function roundStats(s: { median: number; p95: number; p99: number }) { + return { median: round(s.median), p95: round(s.p95), p99: round(s.p99) }; +} + +export function printComputePerfResultsTable(results: ComputePerfBenchmarkResult[]): void { + const header = [ + pad('Provider', 12), + pad('Score', 8), + pad('Build Med', 12), + pad('Build P95', 12), + pad('Build P99', 12), + pad('Total Med', 12), + pad('Status', 10), + ].join(' | '); + + const separator = [12, 8, 12, 12, 12, 12, 10] + .map(w => '-'.repeat(w)) + .join('-+-'); + + console.log('\n' + '='.repeat(separator.length)); + console.log(' COMPUTE PERFORMANCE RESULTS - LINUX KERNEL BUILD'); + console.log('='.repeat(separator.length)); + console.log(header); + console.log(separator); + + const sorted = sortComputePerfByCompositeScore(results); + + for (const result of sorted) { + const successful = result.iterations.filter(i => !i.error).length; + const total = result.iterations.length; + + if (result.skipped) { + console.log([ + pad(result.provider, 12), + pad('--', 8), + pad('--', 12), + pad('--', 12), + pad('--', 12), + pad('--', 12), + pad('SKIPPED', 10), + ].join(' | ')); + continue; + } + + const score = result.compositeScore !== undefined ? result.compositeScore.toFixed(1) : '--'; + const allFailed = successful === 0; + + console.log([ + pad(result.provider, 12), + pad(score, 8), + pad(allFailed ? '--' : formatSeconds(result.summary.buildMs.median), 12), + pad(allFailed ? '--' : formatSeconds(result.summary.buildMs.p95), 12), + pad(allFailed ? '--' : formatSeconds(result.summary.buildMs.p99), 12), + pad(allFailed ? '--' : formatSeconds(result.summary.totalMs.median), 12), + pad(`${successful}/${total} OK`, 10), + ].join(' | ')); + } + + console.log('='.repeat(separator.length)); +} + +export async function writeComputePerfResultsJson(results: ComputePerfBenchmarkResult[], outPath: string): Promise { + const fs = await import('fs'); + const os = await import('os'); + + const cleanResults = results.map(r => ({ + provider: r.provider, + mode: r.mode, + kernelVersion: r.kernelVersion, + iterations: r.iterations.map(i => ({ + totalMs: round(i.totalMs), + buildMs: round(i.buildMs), + ...(i.cpuCount !== undefined ? { cpuCount: i.cpuCount } : {}), + ...(i.memTotalKb !== undefined ? { memTotalKb: i.memTotalKb } : {}), + ...(i.error ? { error: i.error } : {}), + })), + summary: { + buildMs: roundStats(r.summary.buildMs), + totalMs: roundStats(r.summary.totalMs), + }, + ...(r.compositeScore !== undefined ? { compositeScore: round(r.compositeScore) } : {}), + ...(r.successRate !== undefined ? { successRate: round(r.successRate) } : {}), + ...(r.skipped ? { skipped: r.skipped, skipReason: r.skipReason } : {}), + })); + + const output = { + version: '1.0', + timestamp: new Date().toISOString(), + environment: { + node: process.version, + platform: os.platform(), + arch: os.arch(), + }, + config: { + iterations: results[0]?.iterations.length || 0, + mode: 'compute-perf', + }, + results: cleanResults, + }; + + fs.writeFileSync(outPath, JSON.stringify(output, null, 2)); + console.log(`Results written to ${outPath}`); +} diff --git a/src/compute-perf/types.ts b/src/compute-perf/types.ts new file mode 100644 index 0000000..2268cb8 --- /dev/null +++ b/src/compute-perf/types.ts @@ -0,0 +1,54 @@ +export interface ComputePerfProviderConfig { + /** Provider name */ + name: string; + /** Number of iterations (default: 5) */ + iterations?: number; + /** Timeout per iteration in ms (default: 2700000) */ + timeout?: number; + /** Environment variables that must all be set to run this benchmark */ + requiredEnvVars: string[]; + /** Creates a compute instance */ + createCompute: () => any; + /** Options passed to sandbox.create() */ + sandboxOptions?: Record; + /** Timeout for sandbox.destroy() in ms (default: 15000) */ + destroyTimeoutMs?: number; +} + +export interface ComputePerfTimingResult { + /** End-to-end workload time inside sandbox command execution */ + totalMs: number; + /** Linux kernel compile time captured in-sandbox */ + buildMs: number; + /** Number of CPUs reported by sandbox */ + cpuCount?: number; + /** Total memory in KB reported by sandbox */ + memTotalKb?: number; + /** Error message if this iteration failed */ + error?: string; +} + +export interface ComputePerfStats { + median: number; + p95: number; + p99: number; +} + +export interface ComputePerfBenchmarkResult { + provider: string; + mode: 'compute-perf'; + kernelVersion: string; + iterations: ComputePerfTimingResult[]; + summary: { + buildMs: ComputePerfStats; + totalMs: ComputePerfStats; + }; + /** Composite weighted score (0-100, higher = better). Computed post-benchmark. */ + compositeScore?: number; + /** Success rate as a fraction (0 to 1). Computed post-benchmark. */ + successRate?: number; + skipped?: boolean; + skipReason?: string; +} + +export const KERNEL_VERSION = '6.12.24'; diff --git a/src/run.ts b/src/run.ts index 160b810..72dd23b 100644 --- a/src/run.ts +++ b/src/run.ts @@ -7,16 +7,21 @@ import { runConcurrentBenchmark } from './sandbox/concurrent.js'; import { runStaggeredBenchmark } from './sandbox/staggered.js'; import { runStorageBenchmark, writeStorageResultsJson } from './storage/benchmark.js'; import { runBrowserBenchmark, writeBrowserResultsJson } from './browser/benchmark.js'; +import { runComputePerfBenchmark } from './compute-perf/benchmark.js'; import { printResultsTable, writeResultsJson } from './sandbox/table.js'; +import { printComputePerfResultsTable, writeComputePerfResultsJson } from './compute-perf/table.js'; import { providers } from './sandbox/providers.js'; import { storageProviders } from './storage/providers.js'; import { browserProviders } from './browser/providers.js'; +import { computePerfProviders } from './compute-perf/providers.js'; import { computeCompositeScores } from './sandbox/scoring.js'; import { computeStorageCompositeScores } from './storage/scoring.js'; import { computeBrowserCompositeScores } from './browser/scoring.js'; +import { computeComputePerfCompositeScores } from './compute-perf/scoring.js'; import type { BenchmarkResult, BenchmarkMode } from './sandbox/types.js'; import type { StorageBenchmarkResult } from './storage/types.js'; import type { BrowserBenchmarkResult } from './browser/types.js'; +import type { ComputePerfBenchmarkResult } from './compute-perf/types.js'; // Load .env from the benchmarking root const __dirname = path.dirname(fileURLToPath(import.meta.url)); @@ -37,26 +42,57 @@ function getArgValue(args: string[], flag: string): string | undefined { } /** Resolve which modes to run */ -function getModesToRun(): BenchmarkMode[] | ['storage'] | ['browser'] { +function getModesToRun(): BenchmarkMode[] | ['storage'] | ['browser'] | ['compute-perf'] { if (!rawMode) return ['sequential', 'staggered', 'burst']; if (rawMode === 'storage') return ['storage']; if (rawMode === 'browser') return ['browser']; + if (rawMode === 'compute-perf') return ['compute-perf']; const m = rawMode === 'concurrent' ? 'burst' : rawMode as BenchmarkMode; return [m]; } /** Map mode to results subdirectory name */ -function modeToDir(m: BenchmarkMode | 'storage'): string { +function modeToDir(m: BenchmarkMode | 'storage' | 'compute-perf'): string { switch (m) { case 'sequential': return 'sequential_tti'; case 'staggered': return 'staggered_tti'; case 'burst': case 'concurrent': return 'burst_tti'; case 'storage': return 'storage'; + case 'compute-perf': return 'compute_perf'; default: return `${m}_tti`; } } +async function runComputePerf(toRun: typeof computePerfProviders): Promise { + console.log('\n' + '='.repeat(70)); + console.log(' MODE: COMPUTE-PERF'); + console.log(` Iterations per provider: ${iterations}`); + console.log(' Workload: linux kernel build (defconfig + bzImage)'); + console.log('='.repeat(70)); + + const results: ComputePerfBenchmarkResult[] = []; + + for (const providerConfig of toRun) { + const result = await runComputePerfBenchmark({ ...providerConfig, iterations }); + results.push(result); + } + + computeComputePerfCompositeScores(results); + printComputePerfResultsTable(results); + + const timestamp = new Date().toISOString().slice(0, 10); + const resultsDir = path.resolve(__dirname, `../results/${modeToDir('compute-perf')}`); + fs.mkdirSync(resultsDir, { recursive: true }); + + const outPath = path.join(resultsDir, `${timestamp}.json`); + await writeComputePerfResultsJson(results, outPath); + + const latestPath = path.join(resultsDir, 'latest.json'); + fs.copyFileSync(outPath, latestPath); + console.log(`Copied latest: ${latestPath}`); +} + async function runMode(mode: BenchmarkMode, toRun: typeof providers): Promise { console.log('\n' + '='.repeat(70)); console.log(` MODE: ${mode.toUpperCase()}`); @@ -244,6 +280,29 @@ async function main() { return; } + if (modes[0] === 'compute-perf') { + console.log('ComputeSDK Compute Performance Benchmarks'); + console.log(`Date: ${new Date().toISOString()}\n`); + + const toRun = providerFilter + ? computePerfProviders.filter(p => p.name === providerFilter) + : computePerfProviders; + + if (toRun.length === 0) { + if (providerFilter) { + console.error(`Unknown compute-perf provider: ${providerFilter}`); + console.error(`Available: ${computePerfProviders.map(p => p.name).join(', ')}`); + } else { + console.error('No compute-perf providers configured. Add entries to src/compute-perf/providers.ts.'); + } + process.exit(1); + } + + await runComputePerf(toRun); + console.log('\nAll compute-perf tests complete.'); + return; + } + // Handle storage mode separately if (modes[0] === 'storage') { console.log('ComputeSDK Storage Provider Benchmarks'); From 2bbc91f243bc4db5d26ea21a625b45c89f059a8b Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Wed, 15 Apr 2026 22:19:59 +0000 Subject: [PATCH 2/9] chore: label compute-perf workload as LKB --- src/compute-perf/benchmark.ts | 8 ++++++-- src/compute-perf/table.ts | 6 +++++- src/compute-perf/types.ts | 4 ++++ src/run.ts | 2 +- 4 files changed, 16 insertions(+), 4 deletions(-) diff --git a/src/compute-perf/benchmark.ts b/src/compute-perf/benchmark.ts index 236b94a..afa25c7 100644 --- a/src/compute-perf/benchmark.ts +++ b/src/compute-perf/benchmark.ts @@ -1,7 +1,7 @@ import { computeStats } from '../util/stats.js'; import { withTimeout } from '../util/timeout.js'; import type { ComputePerfBenchmarkResult, ComputePerfProviderConfig, ComputePerfTimingResult } from './types.js'; -import { KERNEL_VERSION } from './types.js'; +import { KERNEL_VERSION, WORKLOAD, WORKLOAD_ACRONYM } from './types.js'; const KERNEL_TARBALL = `linux-${KERNEL_VERSION}.tar.xz`; const KERNEL_URL = `https://cdn.kernel.org/pub/linux/kernel/v6.x/${KERNEL_TARBALL}`; @@ -137,6 +137,8 @@ export async function runComputePerfBenchmark(config: ComputePerfProviderConfig) return { provider: name, mode: 'compute-perf', + workload: WORKLOAD, + workloadAcronym: WORKLOAD_ACRONYM, kernelVersion: KERNEL_VERSION, iterations: [], summary: { @@ -151,7 +153,7 @@ export async function runComputePerfBenchmark(config: ComputePerfProviderConfig) const compute = config.createCompute(); const results: ComputePerfTimingResult[] = []; - console.log(`\n--- Compute Perf: ${name} (${iterations} iterations, linux-${KERNEL_VERSION}) ---`); + console.log(`\n--- Compute Perf (${WORKLOAD_ACRONYM}): ${name} (${iterations} iterations, linux-${KERNEL_VERSION}) ---`); for (let i = 0; i < iterations; i++) { console.log(` Iteration ${i + 1}/${iterations}...`); @@ -180,6 +182,8 @@ export async function runComputePerfBenchmark(config: ComputePerfProviderConfig) return { provider: name, mode: 'compute-perf', + workload: WORKLOAD, + workloadAcronym: WORKLOAD_ACRONYM, kernelVersion: KERNEL_VERSION, iterations: results, summary: { diff --git a/src/compute-perf/table.ts b/src/compute-perf/table.ts index 1141fc9..e42f84c 100644 --- a/src/compute-perf/table.ts +++ b/src/compute-perf/table.ts @@ -33,7 +33,7 @@ export function printComputePerfResultsTable(results: ComputePerfBenchmarkResult .join('-+-'); console.log('\n' + '='.repeat(separator.length)); - console.log(' COMPUTE PERFORMANCE RESULTS - LINUX KERNEL BUILD'); + console.log(' COMPUTE PERFORMANCE RESULTS - LKB (Linux Kernel Build)'); console.log('='.repeat(separator.length)); console.log(header); console.log(separator); @@ -81,6 +81,8 @@ export async function writeComputePerfResultsJson(results: ComputePerfBenchmarkR const cleanResults = results.map(r => ({ provider: r.provider, mode: r.mode, + workload: r.workload, + workloadAcronym: r.workloadAcronym, kernelVersion: r.kernelVersion, iterations: r.iterations.map(i => ({ totalMs: round(i.totalMs), @@ -109,6 +111,8 @@ export async function writeComputePerfResultsJson(results: ComputePerfBenchmarkR config: { iterations: results[0]?.iterations.length || 0, mode: 'compute-perf', + workload: 'linux-kernel-build', + workloadAcronym: 'LKB', }, results: cleanResults, }; diff --git a/src/compute-perf/types.ts b/src/compute-perf/types.ts index 2268cb8..79486d2 100644 --- a/src/compute-perf/types.ts +++ b/src/compute-perf/types.ts @@ -37,6 +37,8 @@ export interface ComputePerfStats { export interface ComputePerfBenchmarkResult { provider: string; mode: 'compute-perf'; + workload: 'linux-kernel-build'; + workloadAcronym: 'LKB'; kernelVersion: string; iterations: ComputePerfTimingResult[]; summary: { @@ -52,3 +54,5 @@ export interface ComputePerfBenchmarkResult { } export const KERNEL_VERSION = '6.12.24'; +export const WORKLOAD = 'linux-kernel-build'; +export const WORKLOAD_ACRONYM = 'LKB'; diff --git a/src/run.ts b/src/run.ts index 72dd23b..5a6919c 100644 --- a/src/run.ts +++ b/src/run.ts @@ -68,7 +68,7 @@ async function runComputePerf(toRun: typeof computePerfProviders): Promise console.log('\n' + '='.repeat(70)); console.log(' MODE: COMPUTE-PERF'); console.log(` Iterations per provider: ${iterations}`); - console.log(' Workload: linux kernel build (defconfig + bzImage)'); + console.log(' Workload: LKB (Linux Kernel Build) - defconfig + bzImage'); console.log('='.repeat(70)); const results: ComputePerfBenchmarkResult[] = []; From 8f98af08491d2f288a73b21dd87b49f2bcd1ba32 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Thu, 16 Apr 2026 01:18:56 +0000 Subject: [PATCH 3/9] ci: run compute-perf benchmark on pull requests --- .github/workflows/compute-perf-benchmarks.yml | 69 +++++++++++++++++++ 1 file changed, 69 insertions(+) create mode 100644 .github/workflows/compute-perf-benchmarks.yml diff --git a/.github/workflows/compute-perf-benchmarks.yml b/.github/workflows/compute-perf-benchmarks.yml new file mode 100644 index 0000000..a82610f --- /dev/null +++ b/.github/workflows/compute-perf-benchmarks.yml @@ -0,0 +1,69 @@ +name: Compute Perf Benchmark + +on: + pull_request: + paths: + - 'src/compute-perf/**' + - 'src/util/**' + - 'src/run.ts' + - 'package.json' + - '.github/workflows/compute-perf-benchmarks.yml' + workflow_dispatch: + inputs: + iterations: + description: 'Iterations per provider' + required: false + default: '1' + +concurrency: + group: compute-perf-benchmarks + cancel-in-progress: true + +permissions: + contents: read + +jobs: + bench: + name: Compute Perf ${{ matrix.provider }} + runs-on: namespace-profile-default + timeout-minutes: 90 + strategy: + fail-fast: false + matrix: + provider: + - blaxel + - daytona + - e2b + - hopx + - namespace + - runloop + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 + with: + node-version: 24 + cache: 'npm' + - name: Install dependencies + run: npm ci + - name: Run compute-perf benchmark (LKB) + env: + BL_API_KEY: ${{ secrets.BL_API_KEY }} + BL_WORKSPACE: ${{ secrets.BL_WORKSPACE }} + DAYTONA_API_KEY: ${{ secrets.DAYTONA_API_KEY }} + E2B_API_KEY: ${{ secrets.E2B_API_KEY }} + HOPX_API_KEY: ${{ secrets.HOPX_API_KEY }} + NSC_TOKEN: ${{ secrets.NSC_TOKEN }} + RUNLOOP_API_KEY: ${{ secrets.RUNLOOP_API_KEY }} + run: | + npm run bench -- \ + --mode compute-perf \ + --provider ${{ matrix.provider }} \ + --iterations ${{ github.event.inputs.iterations || '1' }} + - name: Upload compute-perf artifacts + if: always() + uses: actions/upload-artifact@v4 + with: + name: compute-perf-${{ matrix.provider }} + path: results/compute_perf/ + if-no-files-found: ignore + retention-days: 7 From 8412f2457721fe0d6b3474a999070565e30593ca Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Thu, 16 Apr 2026 01:23:50 +0000 Subject: [PATCH 4/9] ci: trigger compute-perf workflow on push --- .github/workflows/compute-perf-benchmarks.yml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/.github/workflows/compute-perf-benchmarks.yml b/.github/workflows/compute-perf-benchmarks.yml index a82610f..92fa6f0 100644 --- a/.github/workflows/compute-perf-benchmarks.yml +++ b/.github/workflows/compute-perf-benchmarks.yml @@ -1,6 +1,13 @@ name: Compute Perf Benchmark on: + push: + paths: + - 'src/compute-perf/**' + - 'src/util/**' + - 'src/run.ts' + - 'package.json' + - '.github/workflows/compute-perf-benchmarks.yml' pull_request: paths: - 'src/compute-perf/**' From c261d1d4b664d5a0b73a23bc402eb3fc13c0b1de Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Thu, 16 Apr 2026 01:26:47 +0000 Subject: [PATCH 5/9] fix: run LKB script correctly and rename workload --- .github/workflows/compute-perf-benchmarks.yml | 4 ++-- src/compute-perf/benchmark.ts | 13 +++++++++---- src/compute-perf/table.ts | 7 ++++--- src/compute-perf/types.ts | 5 +++-- src/run.ts | 2 +- 5 files changed, 19 insertions(+), 12 deletions(-) diff --git a/.github/workflows/compute-perf-benchmarks.yml b/.github/workflows/compute-perf-benchmarks.yml index 92fa6f0..c431398 100644 --- a/.github/workflows/compute-perf-benchmarks.yml +++ b/.github/workflows/compute-perf-benchmarks.yml @@ -1,4 +1,4 @@ -name: Compute Perf Benchmark +name: Linux Kernel Builder Benchmark on: push: @@ -52,7 +52,7 @@ jobs: cache: 'npm' - name: Install dependencies run: npm ci - - name: Run compute-perf benchmark (LKB) + - name: Run Linux Kernel Builder benchmark (LKB) env: BL_API_KEY: ${{ secrets.BL_API_KEY }} BL_WORKSPACE: ${{ secrets.BL_WORKSPACE }} diff --git a/src/compute-perf/benchmark.ts b/src/compute-perf/benchmark.ts index afa25c7..091c85d 100644 --- a/src/compute-perf/benchmark.ts +++ b/src/compute-perf/benchmark.ts @@ -1,7 +1,7 @@ import { computeStats } from '../util/stats.js'; import { withTimeout } from '../util/timeout.js'; import type { ComputePerfBenchmarkResult, ComputePerfProviderConfig, ComputePerfTimingResult } from './types.js'; -import { KERNEL_VERSION, WORKLOAD, WORKLOAD_ACRONYM } from './types.js'; +import { KERNEL_VERSION, WORKLOAD, WORKLOAD_ACRONYM, WORKLOAD_LABEL } from './types.js'; const KERNEL_TARBALL = `linux-${KERNEL_VERSION}.tar.xz`; const KERNEL_URL = `https://cdn.kernel.org/pub/linux/kernel/v6.x/${KERNEL_TARBALL}`; @@ -56,7 +56,7 @@ function getKernelBuildScript(): string { 'CPU_COUNT=$(nproc)', "MEM_TOTAL_KB=$(awk '/MemTotal:/ { print $2 }' /proc/meminfo)", 'echo "__COMPUTE_PERF_RESULT__ buildMs=${BUILD_MS} cpu=${CPU_COUNT} memKb=${MEM_TOTAL_KB}"', - ].join('; '); + ].join('\n'); } async function runComputePerfIteration( @@ -75,7 +75,12 @@ async function runComputePerfIteration( ); const iterationStart = performance.now(); - const command = `bash -lc '${getKernelBuildScript().replace(/'/g, "'\\''")}'`; + const command = [ + "cat <<'__COMPUTE_PERF_SCRIPT__' >/tmp/compute-perf.sh", + getKernelBuildScript(), + '__COMPUTE_PERF_SCRIPT__', + 'bash /tmp/compute-perf.sh', + ].join('\n'); const result = await withTimeout( sandbox.runCommand(command), @@ -153,7 +158,7 @@ export async function runComputePerfBenchmark(config: ComputePerfProviderConfig) const compute = config.createCompute(); const results: ComputePerfTimingResult[] = []; - console.log(`\n--- Compute Perf (${WORKLOAD_ACRONYM}): ${name} (${iterations} iterations, linux-${KERNEL_VERSION}) ---`); + console.log(`\n--- ${WORKLOAD_LABEL} (${WORKLOAD_ACRONYM}): ${name} (${iterations} iterations, linux-${KERNEL_VERSION}) ---`); for (let i = 0; i < iterations; i++) { console.log(` Iteration ${i + 1}/${iterations}...`); diff --git a/src/compute-perf/table.ts b/src/compute-perf/table.ts index e42f84c..eb759eb 100644 --- a/src/compute-perf/table.ts +++ b/src/compute-perf/table.ts @@ -1,5 +1,6 @@ import type { ComputePerfBenchmarkResult } from './types.js'; import { sortComputePerfByCompositeScore } from './scoring.js'; +import { WORKLOAD, WORKLOAD_ACRONYM, WORKLOAD_LABEL } from './types.js'; function pad(str: string, width: number): string { return str.padEnd(width); @@ -33,7 +34,7 @@ export function printComputePerfResultsTable(results: ComputePerfBenchmarkResult .join('-+-'); console.log('\n' + '='.repeat(separator.length)); - console.log(' COMPUTE PERFORMANCE RESULTS - LKB (Linux Kernel Build)'); + console.log(` COMPUTE PERFORMANCE RESULTS - ${WORKLOAD_ACRONYM} (${WORKLOAD_LABEL})`); console.log('='.repeat(separator.length)); console.log(header); console.log(separator); @@ -111,8 +112,8 @@ export async function writeComputePerfResultsJson(results: ComputePerfBenchmarkR config: { iterations: results[0]?.iterations.length || 0, mode: 'compute-perf', - workload: 'linux-kernel-build', - workloadAcronym: 'LKB', + workload: WORKLOAD, + workloadAcronym: WORKLOAD_ACRONYM, }, results: cleanResults, }; diff --git a/src/compute-perf/types.ts b/src/compute-perf/types.ts index 79486d2..0e07485 100644 --- a/src/compute-perf/types.ts +++ b/src/compute-perf/types.ts @@ -37,7 +37,7 @@ export interface ComputePerfStats { export interface ComputePerfBenchmarkResult { provider: string; mode: 'compute-perf'; - workload: 'linux-kernel-build'; + workload: 'linux-kernel-builder'; workloadAcronym: 'LKB'; kernelVersion: string; iterations: ComputePerfTimingResult[]; @@ -54,5 +54,6 @@ export interface ComputePerfBenchmarkResult { } export const KERNEL_VERSION = '6.12.24'; -export const WORKLOAD = 'linux-kernel-build'; +export const WORKLOAD = 'linux-kernel-builder'; export const WORKLOAD_ACRONYM = 'LKB'; +export const WORKLOAD_LABEL = 'Linux Kernel Builder'; diff --git a/src/run.ts b/src/run.ts index 5a6919c..6242057 100644 --- a/src/run.ts +++ b/src/run.ts @@ -68,7 +68,7 @@ async function runComputePerf(toRun: typeof computePerfProviders): Promise console.log('\n' + '='.repeat(70)); console.log(' MODE: COMPUTE-PERF'); console.log(` Iterations per provider: ${iterations}`); - console.log(' Workload: LKB (Linux Kernel Build) - defconfig + bzImage'); + console.log(' Workload: LKB (Linux Kernel Builder) - defconfig + bzImage'); console.log('='.repeat(70)); const results: ComputePerfBenchmarkResult[] = []; From 846721caccec235919c24df77d5cf3296467c72d Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Thu, 16 Apr 2026 01:27:56 +0000 Subject: [PATCH 6/9] chore: rename workflow file to linux-kernel-builder --- ...erf-benchmarks.yml => linux-kernel-builder-benchmarks.yml} | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) rename .github/workflows/{compute-perf-benchmarks.yml => linux-kernel-builder-benchmarks.yml} (93%) diff --git a/.github/workflows/compute-perf-benchmarks.yml b/.github/workflows/linux-kernel-builder-benchmarks.yml similarity index 93% rename from .github/workflows/compute-perf-benchmarks.yml rename to .github/workflows/linux-kernel-builder-benchmarks.yml index c431398..ced6e85 100644 --- a/.github/workflows/compute-perf-benchmarks.yml +++ b/.github/workflows/linux-kernel-builder-benchmarks.yml @@ -7,14 +7,14 @@ on: - 'src/util/**' - 'src/run.ts' - 'package.json' - - '.github/workflows/compute-perf-benchmarks.yml' + - '.github/workflows/linux-kernel-builder-benchmarks.yml' pull_request: paths: - 'src/compute-perf/**' - 'src/util/**' - 'src/run.ts' - 'package.json' - - '.github/workflows/compute-perf-benchmarks.yml' + - '.github/workflows/linux-kernel-builder-benchmarks.yml' workflow_dispatch: inputs: iterations: From 0fbea73cb6d4ed647a003b73ae8edca8d3841a1c Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Thu, 16 Apr 2026 01:59:10 +0000 Subject: [PATCH 7/9] refactor: rename compute-perf mode to linux-kernel-builder --- .../linux-kernel-builder-benchmarks.yml | 16 +++--- package.json | 14 ++--- .../benchmark.ts | 30 +++++------ .../providers.ts | 4 +- .../scoring.ts | 22 ++++---- .../table.ts | 12 ++--- .../types.ts | 16 +++--- src/run.ts | 52 +++++++++---------- 8 files changed, 83 insertions(+), 83 deletions(-) rename src/{compute-perf => linux-kernel-builder}/benchmark.ts (86%) rename src/{compute-perf => linux-kernel-builder}/providers.ts (90%) rename src/{compute-perf => linux-kernel-builder}/scoring.ts (61%) rename src/{compute-perf => linux-kernel-builder}/table.ts (87%) rename src/{compute-perf => linux-kernel-builder}/types.ts (80%) diff --git a/.github/workflows/linux-kernel-builder-benchmarks.yml b/.github/workflows/linux-kernel-builder-benchmarks.yml index ced6e85..848facf 100644 --- a/.github/workflows/linux-kernel-builder-benchmarks.yml +++ b/.github/workflows/linux-kernel-builder-benchmarks.yml @@ -3,14 +3,14 @@ name: Linux Kernel Builder Benchmark on: push: paths: - - 'src/compute-perf/**' + - 'src/linux-kernel-builder/**' - 'src/util/**' - 'src/run.ts' - 'package.json' - '.github/workflows/linux-kernel-builder-benchmarks.yml' pull_request: paths: - - 'src/compute-perf/**' + - 'src/linux-kernel-builder/**' - 'src/util/**' - 'src/run.ts' - 'package.json' @@ -23,7 +23,7 @@ on: default: '1' concurrency: - group: compute-perf-benchmarks + group: linux-kernel-builder-benchmarks cancel-in-progress: true permissions: @@ -31,7 +31,7 @@ permissions: jobs: bench: - name: Compute Perf ${{ matrix.provider }} + name: LKB ${{ matrix.provider }} runs-on: namespace-profile-default timeout-minutes: 90 strategy: @@ -63,14 +63,14 @@ jobs: RUNLOOP_API_KEY: ${{ secrets.RUNLOOP_API_KEY }} run: | npm run bench -- \ - --mode compute-perf \ + --mode linux-kernel-builder \ --provider ${{ matrix.provider }} \ --iterations ${{ github.event.inputs.iterations || '1' }} - - name: Upload compute-perf artifacts + - name: Upload Linux Kernel Builder artifacts if: always() uses: actions/upload-artifact@v4 with: - name: compute-perf-${{ matrix.provider }} - path: results/compute_perf/ + name: linux-kernel-builder-${{ matrix.provider }} + path: results/linux_kernel_builder/ if-no-files-found: ignore retention-days: 7 diff --git a/package.json b/package.json index a7f8e7d..bcb0622 100644 --- a/package.json +++ b/package.json @@ -21,13 +21,13 @@ "bench:vercel": "tsx src/run.ts --provider vercel", "bench:just-bash": "tsx src/run.ts --provider just-bash", "bench:sprites": "tsx src/run.ts --provider sprites", - "bench:compute-perf": "tsx src/run.ts --mode compute-perf", - "bench:compute-perf:blaxel": "tsx src/run.ts --mode compute-perf --provider blaxel", - "bench:compute-perf:daytona": "tsx src/run.ts --mode compute-perf --provider daytona", - "bench:compute-perf:e2b": "tsx src/run.ts --mode compute-perf --provider e2b", - "bench:compute-perf:hopx": "tsx src/run.ts --mode compute-perf --provider hopx", - "bench:compute-perf:namespace": "tsx src/run.ts --mode compute-perf --provider namespace", - "bench:compute-perf:runloop": "tsx src/run.ts --mode compute-perf --provider runloop", + "bench:linux-kernel-builder": "tsx src/run.ts --mode linux-kernel-builder", + "bench:linux-kernel-builder:blaxel": "tsx src/run.ts --mode linux-kernel-builder --provider blaxel", + "bench:linux-kernel-builder:daytona": "tsx src/run.ts --mode linux-kernel-builder --provider daytona", + "bench:linux-kernel-builder:e2b": "tsx src/run.ts --mode linux-kernel-builder --provider e2b", + "bench:linux-kernel-builder:hopx": "tsx src/run.ts --mode linux-kernel-builder --provider hopx", + "bench:linux-kernel-builder:namespace": "tsx src/run.ts --mode linux-kernel-builder --provider namespace", + "bench:linux-kernel-builder:runloop": "tsx src/run.ts --mode linux-kernel-builder --provider runloop", "bench:browser": "tsx src/run.ts --mode browser", "bench:browser:browserbase": "tsx src/run.ts --mode browser --provider browserbase", "bench:storage": "tsx src/run.ts --mode storage", diff --git a/src/compute-perf/benchmark.ts b/src/linux-kernel-builder/benchmark.ts similarity index 86% rename from src/compute-perf/benchmark.ts rename to src/linux-kernel-builder/benchmark.ts index 091c85d..42c5002 100644 --- a/src/compute-perf/benchmark.ts +++ b/src/linux-kernel-builder/benchmark.ts @@ -1,6 +1,6 @@ import { computeStats } from '../util/stats.js'; import { withTimeout } from '../util/timeout.js'; -import type { ComputePerfBenchmarkResult, ComputePerfProviderConfig, ComputePerfTimingResult } from './types.js'; +import type { LinuxKernelBuilderBenchmarkResult, LinuxKernelBuilderProviderConfig, LinuxKernelBuilderTimingResult } from './types.js'; import { KERNEL_VERSION, WORKLOAD, WORKLOAD_ACRONYM, WORKLOAD_LABEL } from './types.js'; const KERNEL_TARBALL = `linux-${KERNEL_VERSION}.tar.xz`; @@ -10,7 +10,7 @@ const KERNEL_SHA256 = '335aeec4f6af045d958e2dabaf55222349933e396df17b5cd31798f5e function parseResultLine(output: string): { buildMs: number; cpuCount?: number; memTotalKb?: number } | null { const markerLine = output .split('\n') - .find(line => line.startsWith('__COMPUTE_PERF_RESULT__')); + .find(line => line.startsWith('__LKB_RESULT__')); if (!markerLine) return null; @@ -30,7 +30,7 @@ function parseResultLine(output: string): { buildMs: number; cpuCount?: number; function getKernelBuildScript(): string { return [ 'set -euo pipefail', - 'WORKDIR=/tmp/compute-perf-linux', + 'WORKDIR=/tmp/lkb-linux', 'rm -rf "$WORKDIR"', 'mkdir -p "$WORKDIR"', 'cd "$WORKDIR"', @@ -50,21 +50,21 @@ function getKernelBuildScript(): string { 'done', 'make defconfig >/dev/null', 'START_NS=$(date +%s%N)', - 'make -j"$(nproc)" bzImage >/tmp/compute-perf-build.log 2>&1', + 'make -j"$(nproc)" bzImage >/tmp/lkb-build.log 2>&1', 'END_NS=$(date +%s%N)', 'BUILD_MS=$(( (END_NS - START_NS) / 1000000 ))', 'CPU_COUNT=$(nproc)', "MEM_TOTAL_KB=$(awk '/MemTotal:/ { print $2 }' /proc/meminfo)", - 'echo "__COMPUTE_PERF_RESULT__ buildMs=${BUILD_MS} cpu=${CPU_COUNT} memKb=${MEM_TOTAL_KB}"', + 'echo "__LKB_RESULT__ buildMs=${BUILD_MS} cpu=${CPU_COUNT} memKb=${MEM_TOTAL_KB}"', ].join('\n'); } -async function runComputePerfIteration( +async function runLinuxKernelBuilderIteration( compute: any, timeout: number, sandboxOptions?: Record, destroyTimeoutMs: number = 15_000, -): Promise { +): Promise { let sandbox: any = null; try { @@ -76,10 +76,10 @@ async function runComputePerfIteration( const iterationStart = performance.now(); const command = [ - "cat <<'__COMPUTE_PERF_SCRIPT__' >/tmp/compute-perf.sh", + "cat <<'__LKB_SCRIPT__' >/tmp/lkb.sh", getKernelBuildScript(), - '__COMPUTE_PERF_SCRIPT__', - 'bash /tmp/compute-perf.sh', + '__LKB_SCRIPT__', + 'bash /tmp/lkb.sh', ].join('\n'); const result = await withTimeout( @@ -127,7 +127,7 @@ async function runComputePerfIteration( } } -export async function runComputePerfBenchmark(config: ComputePerfProviderConfig): Promise { +export async function runLinuxKernelBuilderBenchmark(config: LinuxKernelBuilderProviderConfig): Promise { const { name, iterations = 5, @@ -141,7 +141,7 @@ export async function runComputePerfBenchmark(config: ComputePerfProviderConfig) if (missingVars.length > 0) { return { provider: name, - mode: 'compute-perf', + mode: 'linux-kernel-builder', workload: WORKLOAD, workloadAcronym: WORKLOAD_ACRONYM, kernelVersion: KERNEL_VERSION, @@ -156,7 +156,7 @@ export async function runComputePerfBenchmark(config: ComputePerfProviderConfig) } const compute = config.createCompute(); - const results: ComputePerfTimingResult[] = []; + const results: LinuxKernelBuilderTimingResult[] = []; console.log(`\n--- ${WORKLOAD_LABEL} (${WORKLOAD_ACRONYM}): ${name} (${iterations} iterations, linux-${KERNEL_VERSION}) ---`); @@ -164,7 +164,7 @@ export async function runComputePerfBenchmark(config: ComputePerfProviderConfig) console.log(` Iteration ${i + 1}/${iterations}...`); try { - const iterationResult = await runComputePerfIteration( + const iterationResult = await runLinuxKernelBuilderIteration( compute, timeout, sandboxOptions, @@ -186,7 +186,7 @@ export async function runComputePerfBenchmark(config: ComputePerfProviderConfig) return { provider: name, - mode: 'compute-perf', + mode: 'linux-kernel-builder', workload: WORKLOAD, workloadAcronym: WORKLOAD_ACRONYM, kernelVersion: KERNEL_VERSION, diff --git a/src/compute-perf/providers.ts b/src/linux-kernel-builder/providers.ts similarity index 90% rename from src/compute-perf/providers.ts rename to src/linux-kernel-builder/providers.ts index fe9a129..3a6e610 100644 --- a/src/compute-perf/providers.ts +++ b/src/linux-kernel-builder/providers.ts @@ -4,7 +4,7 @@ import { blaxel } from '@computesdk/blaxel'; import { hopx } from '@computesdk/hopx'; import { namespace } from '@computesdk/namespace'; import { runloop } from '@computesdk/runloop'; -import type { ComputePerfProviderConfig } from './types.js'; +import type { LinuxKernelBuilderProviderConfig } from './types.js'; /** * Providers that participate in sustained compute benchmark runs. @@ -12,7 +12,7 @@ import type { ComputePerfProviderConfig } from './types.js'; * Keep this list intentionally narrow to providers that position around * runner-style or general-purpose compute performance. */ -export const computePerfProviders: ComputePerfProviderConfig[] = [ +export const linuxKernelBuilderProviders: LinuxKernelBuilderProviderConfig[] = [ { name: 'blaxel', requiredEnvVars: ['BL_API_KEY', 'BL_WORKSPACE'], diff --git a/src/compute-perf/scoring.ts b/src/linux-kernel-builder/scoring.ts similarity index 61% rename from src/compute-perf/scoring.ts rename to src/linux-kernel-builder/scoring.ts index c5f5fbe..4145000 100644 --- a/src/compute-perf/scoring.ts +++ b/src/linux-kernel-builder/scoring.ts @@ -1,12 +1,12 @@ -import type { ComputePerfBenchmarkResult, ComputePerfStats } from './types.js'; +import type { LinuxKernelBuilderBenchmarkResult, LinuxKernelBuilderStats } from './types.js'; -export interface ComputePerfScoringWeights { +export interface LinuxKernelBuilderScoringWeights { median: number; p95: number; p99: number; } -export const DEFAULT_COMPUTE_PERF_WEIGHTS: ComputePerfScoringWeights = { +export const DEFAULT_LKB_WEIGHTS: LinuxKernelBuilderScoringWeights = { median: 0.60, p95: 0.25, p99: 0.15, @@ -22,15 +22,15 @@ function scoreMetric(valueMs: number): number { return Math.max(0, 100 * (1 - valueMs / BUILD_CEILING_MS)); } -export function computeComputePerfSuccessRate(result: ComputePerfBenchmarkResult): number { +export function computeLinuxKernelBuilderSuccessRate(result: LinuxKernelBuilderBenchmarkResult): number { if (result.skipped || result.iterations.length === 0) return 0; const successful = result.iterations.filter(i => !i.error).length; return successful / result.iterations.length; } function computeBuildScore( - stats: ComputePerfStats, - weights: ComputePerfScoringWeights = DEFAULT_COMPUTE_PERF_WEIGHTS, + stats: LinuxKernelBuilderStats, + weights: LinuxKernelBuilderScoringWeights = DEFAULT_LKB_WEIGHTS, ): number { return ( weights.median * scoreMetric(stats.median) + @@ -39,12 +39,12 @@ function computeBuildScore( ); } -export function computeComputePerfCompositeScores( - results: ComputePerfBenchmarkResult[], - weights: ComputePerfScoringWeights = DEFAULT_COMPUTE_PERF_WEIGHTS, +export function computeLinuxKernelBuilderCompositeScores( + results: LinuxKernelBuilderBenchmarkResult[], + weights: LinuxKernelBuilderScoringWeights = DEFAULT_LKB_WEIGHTS, ): void { for (const result of results) { - const successRate = computeComputePerfSuccessRate(result); + const successRate = computeLinuxKernelBuilderSuccessRate(result); result.successRate = successRate; if (result.skipped || successRate === 0) { @@ -57,7 +57,7 @@ export function computeComputePerfCompositeScores( } } -export function sortComputePerfByCompositeScore(results: ComputePerfBenchmarkResult[]): ComputePerfBenchmarkResult[] { +export function sortLinuxKernelBuilderByCompositeScore(results: LinuxKernelBuilderBenchmarkResult[]): LinuxKernelBuilderBenchmarkResult[] { return [...results].sort((a, b) => { if (a.skipped && !b.skipped) return 1; if (!a.skipped && b.skipped) return -1; diff --git a/src/compute-perf/table.ts b/src/linux-kernel-builder/table.ts similarity index 87% rename from src/compute-perf/table.ts rename to src/linux-kernel-builder/table.ts index eb759eb..61e931b 100644 --- a/src/compute-perf/table.ts +++ b/src/linux-kernel-builder/table.ts @@ -1,5 +1,5 @@ -import type { ComputePerfBenchmarkResult } from './types.js'; -import { sortComputePerfByCompositeScore } from './scoring.js'; +import type { LinuxKernelBuilderBenchmarkResult } from './types.js'; +import { sortLinuxKernelBuilderByCompositeScore } from './scoring.js'; import { WORKLOAD, WORKLOAD_ACRONYM, WORKLOAD_LABEL } from './types.js'; function pad(str: string, width: number): string { @@ -18,7 +18,7 @@ function roundStats(s: { median: number; p95: number; p99: number }) { return { median: round(s.median), p95: round(s.p95), p99: round(s.p99) }; } -export function printComputePerfResultsTable(results: ComputePerfBenchmarkResult[]): void { +export function printLinuxKernelBuilderResultsTable(results: LinuxKernelBuilderBenchmarkResult[]): void { const header = [ pad('Provider', 12), pad('Score', 8), @@ -39,7 +39,7 @@ export function printComputePerfResultsTable(results: ComputePerfBenchmarkResult console.log(header); console.log(separator); - const sorted = sortComputePerfByCompositeScore(results); + const sorted = sortLinuxKernelBuilderByCompositeScore(results); for (const result of sorted) { const successful = result.iterations.filter(i => !i.error).length; @@ -75,7 +75,7 @@ export function printComputePerfResultsTable(results: ComputePerfBenchmarkResult console.log('='.repeat(separator.length)); } -export async function writeComputePerfResultsJson(results: ComputePerfBenchmarkResult[], outPath: string): Promise { +export async function writeLinuxKernelBuilderResultsJson(results: LinuxKernelBuilderBenchmarkResult[], outPath: string): Promise { const fs = await import('fs'); const os = await import('os'); @@ -111,7 +111,7 @@ export async function writeComputePerfResultsJson(results: ComputePerfBenchmarkR }, config: { iterations: results[0]?.iterations.length || 0, - mode: 'compute-perf', + mode: 'linux-kernel-builder', workload: WORKLOAD, workloadAcronym: WORKLOAD_ACRONYM, }, diff --git a/src/compute-perf/types.ts b/src/linux-kernel-builder/types.ts similarity index 80% rename from src/compute-perf/types.ts rename to src/linux-kernel-builder/types.ts index 0e07485..ea863a3 100644 --- a/src/compute-perf/types.ts +++ b/src/linux-kernel-builder/types.ts @@ -1,4 +1,4 @@ -export interface ComputePerfProviderConfig { +export interface LinuxKernelBuilderProviderConfig { /** Provider name */ name: string; /** Number of iterations (default: 5) */ @@ -15,7 +15,7 @@ export interface ComputePerfProviderConfig { destroyTimeoutMs?: number; } -export interface ComputePerfTimingResult { +export interface LinuxKernelBuilderTimingResult { /** End-to-end workload time inside sandbox command execution */ totalMs: number; /** Linux kernel compile time captured in-sandbox */ @@ -28,22 +28,22 @@ export interface ComputePerfTimingResult { error?: string; } -export interface ComputePerfStats { +export interface LinuxKernelBuilderStats { median: number; p95: number; p99: number; } -export interface ComputePerfBenchmarkResult { +export interface LinuxKernelBuilderBenchmarkResult { provider: string; - mode: 'compute-perf'; + mode: 'linux-kernel-builder'; workload: 'linux-kernel-builder'; workloadAcronym: 'LKB'; kernelVersion: string; - iterations: ComputePerfTimingResult[]; + iterations: LinuxKernelBuilderTimingResult[]; summary: { - buildMs: ComputePerfStats; - totalMs: ComputePerfStats; + buildMs: LinuxKernelBuilderStats; + totalMs: LinuxKernelBuilderStats; }; /** Composite weighted score (0-100, higher = better). Computed post-benchmark. */ compositeScore?: number; diff --git a/src/run.ts b/src/run.ts index 6242057..7ec94ee 100644 --- a/src/run.ts +++ b/src/run.ts @@ -7,21 +7,21 @@ import { runConcurrentBenchmark } from './sandbox/concurrent.js'; import { runStaggeredBenchmark } from './sandbox/staggered.js'; import { runStorageBenchmark, writeStorageResultsJson } from './storage/benchmark.js'; import { runBrowserBenchmark, writeBrowserResultsJson } from './browser/benchmark.js'; -import { runComputePerfBenchmark } from './compute-perf/benchmark.js'; +import { runLinuxKernelBuilderBenchmark } from './linux-kernel-builder/benchmark.js'; import { printResultsTable, writeResultsJson } from './sandbox/table.js'; -import { printComputePerfResultsTable, writeComputePerfResultsJson } from './compute-perf/table.js'; +import { printLinuxKernelBuilderResultsTable, writeLinuxKernelBuilderResultsJson } from './linux-kernel-builder/table.js'; import { providers } from './sandbox/providers.js'; import { storageProviders } from './storage/providers.js'; import { browserProviders } from './browser/providers.js'; -import { computePerfProviders } from './compute-perf/providers.js'; +import { linuxKernelBuilderProviders } from './linux-kernel-builder/providers.js'; import { computeCompositeScores } from './sandbox/scoring.js'; import { computeStorageCompositeScores } from './storage/scoring.js'; import { computeBrowserCompositeScores } from './browser/scoring.js'; -import { computeComputePerfCompositeScores } from './compute-perf/scoring.js'; +import { computeLinuxKernelBuilderCompositeScores } from './linux-kernel-builder/scoring.js'; import type { BenchmarkResult, BenchmarkMode } from './sandbox/types.js'; import type { StorageBenchmarkResult } from './storage/types.js'; import type { BrowserBenchmarkResult } from './browser/types.js'; -import type { ComputePerfBenchmarkResult } from './compute-perf/types.js'; +import type { LinuxKernelBuilderBenchmarkResult } from './linux-kernel-builder/types.js'; // Load .env from the benchmarking root const __dirname = path.dirname(fileURLToPath(import.meta.url)); @@ -42,51 +42,51 @@ function getArgValue(args: string[], flag: string): string | undefined { } /** Resolve which modes to run */ -function getModesToRun(): BenchmarkMode[] | ['storage'] | ['browser'] | ['compute-perf'] { +function getModesToRun(): BenchmarkMode[] | ['storage'] | ['browser'] | ['linux-kernel-builder'] { if (!rawMode) return ['sequential', 'staggered', 'burst']; if (rawMode === 'storage') return ['storage']; if (rawMode === 'browser') return ['browser']; - if (rawMode === 'compute-perf') return ['compute-perf']; + if (rawMode === 'linux-kernel-builder') return ['linux-kernel-builder']; const m = rawMode === 'concurrent' ? 'burst' : rawMode as BenchmarkMode; return [m]; } /** Map mode to results subdirectory name */ -function modeToDir(m: BenchmarkMode | 'storage' | 'compute-perf'): string { +function modeToDir(m: BenchmarkMode | 'storage' | 'linux-kernel-builder'): string { switch (m) { case 'sequential': return 'sequential_tti'; case 'staggered': return 'staggered_tti'; case 'burst': case 'concurrent': return 'burst_tti'; case 'storage': return 'storage'; - case 'compute-perf': return 'compute_perf'; + case 'linux-kernel-builder': return 'linux_kernel_builder'; default: return `${m}_tti`; } } -async function runComputePerf(toRun: typeof computePerfProviders): Promise { +async function runLinuxKernelBuilder(toRun: typeof linuxKernelBuilderProviders): Promise { console.log('\n' + '='.repeat(70)); - console.log(' MODE: COMPUTE-PERF'); + console.log(' MODE: LINUX-KERNEL-BUILDER'); console.log(` Iterations per provider: ${iterations}`); console.log(' Workload: LKB (Linux Kernel Builder) - defconfig + bzImage'); console.log('='.repeat(70)); - const results: ComputePerfBenchmarkResult[] = []; + const results: LinuxKernelBuilderBenchmarkResult[] = []; for (const providerConfig of toRun) { - const result = await runComputePerfBenchmark({ ...providerConfig, iterations }); + const result = await runLinuxKernelBuilderBenchmark({ ...providerConfig, iterations }); results.push(result); } - computeComputePerfCompositeScores(results); - printComputePerfResultsTable(results); + computeLinuxKernelBuilderCompositeScores(results); + printLinuxKernelBuilderResultsTable(results); const timestamp = new Date().toISOString().slice(0, 10); - const resultsDir = path.resolve(__dirname, `../results/${modeToDir('compute-perf')}`); + const resultsDir = path.resolve(__dirname, `../results/${modeToDir('linux-kernel-builder')}`); fs.mkdirSync(resultsDir, { recursive: true }); const outPath = path.join(resultsDir, `${timestamp}.json`); - await writeComputePerfResultsJson(results, outPath); + await writeLinuxKernelBuilderResultsJson(results, outPath); const latestPath = path.join(resultsDir, 'latest.json'); fs.copyFileSync(outPath, latestPath); @@ -280,26 +280,26 @@ async function main() { return; } - if (modes[0] === 'compute-perf') { - console.log('ComputeSDK Compute Performance Benchmarks'); + if (modes[0] === 'linux-kernel-builder') { + console.log('ComputeSDK Linux Kernel Builder Benchmarks'); console.log(`Date: ${new Date().toISOString()}\n`); const toRun = providerFilter - ? computePerfProviders.filter(p => p.name === providerFilter) - : computePerfProviders; + ? linuxKernelBuilderProviders.filter(p => p.name === providerFilter) + : linuxKernelBuilderProviders; if (toRun.length === 0) { if (providerFilter) { - console.error(`Unknown compute-perf provider: ${providerFilter}`); - console.error(`Available: ${computePerfProviders.map(p => p.name).join(', ')}`); + console.error(`Unknown linux-kernel-builder provider: ${providerFilter}`); + console.error(`Available: ${linuxKernelBuilderProviders.map(p => p.name).join(', ')}`); } else { - console.error('No compute-perf providers configured. Add entries to src/compute-perf/providers.ts.'); + console.error('No linux-kernel-builder providers configured. Add entries to src/linux-kernel-builder/providers.ts.'); } process.exit(1); } - await runComputePerf(toRun); - console.log('\nAll compute-perf tests complete.'); + await runLinuxKernelBuilder(toRun); + console.log('\nAll linux-kernel-builder tests complete.'); return; } From 500e4ade5cc25225dc8f88ce4b22274887312883 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Thu, 16 Apr 2026 02:05:25 +0000 Subject: [PATCH 8/9] ci: post LKB benchmark comment on pull requests --- .../linux-kernel-builder-benchmarks.yml | 100 ++++++++++++++++++ 1 file changed, 100 insertions(+) diff --git a/.github/workflows/linux-kernel-builder-benchmarks.yml b/.github/workflows/linux-kernel-builder-benchmarks.yml index 848facf..a88ebd2 100644 --- a/.github/workflows/linux-kernel-builder-benchmarks.yml +++ b/.github/workflows/linux-kernel-builder-benchmarks.yml @@ -28,6 +28,7 @@ concurrency: permissions: contents: read + pull-requests: write jobs: bench: @@ -74,3 +75,102 @@ jobs: path: results/linux_kernel_builder/ if-no-files-found: ignore retention-days: 7 + + collect: + name: Collect LKB Results + runs-on: namespace-profile-default + needs: bench + if: always() && github.event_name == 'pull_request' + steps: + - uses: actions/checkout@v4 + - name: Download all LKB artifacts + uses: actions/download-artifact@v4 + with: + path: artifacts/ + pattern: linux-kernel-builder-* + - name: Post results to PR + continue-on-error: true + uses: actions/github-script@v7 + with: + script: | + const fs = require('fs'); + const path = require('path'); + + function walk(dir, out) { + if (!fs.existsSync(dir)) return; + for (const entry of fs.readdirSync(dir, { withFileTypes: true })) { + const full = path.join(dir, entry.name); + if (entry.isDirectory()) walk(full, out); + else if (entry.name === 'latest.json') out.push(full); + } + } + + const latestFiles = []; + walk('artifacts', latestFiles); + + const runUrl = `${context.serverUrl}/${context.repo.owner}/${context.repo.repo}/actions/runs/${context.runId}`; + const marker = '## Linux Kernel Builder Benchmark Results'; + + let body = `${marker}\n\n`; + + if (latestFiles.length === 0) { + body += '> No Linux Kernel Builder results were generated.\n\n'; + } else { + const byProvider = new Map(); + + for (const file of latestFiles) { + const raw = JSON.parse(fs.readFileSync(file, 'utf-8')); + for (const r of raw.results || []) { + byProvider.set(r.provider, r); + } + } + + const results = Array.from(byProvider.values()) + .sort((a, b) => (b.compositeScore || 0) - (a.compositeScore || 0)); + + body += '| # | Provider | Score | Build Median | Build P95 | Build P99 | Status |\n'; + body += '|---|----------|-------|--------------|-----------|-----------|--------|\n'; + + results.forEach((r, i) => { + if (r.skipped) { + body += `| ${i + 1} | ${r.provider} | -- | -- | -- | -- | SKIPPED |\n`; + return; + } + + const score = r.compositeScore !== undefined ? r.compositeScore.toFixed(1) : '--'; + const med = r.summary?.buildMs ? `${(r.summary.buildMs.median / 1000).toFixed(2)}s` : '--'; + const p95 = r.summary?.buildMs ? `${(r.summary.buildMs.p95 / 1000).toFixed(2)}s` : '--'; + const p99 = r.summary?.buildMs ? `${(r.summary.buildMs.p99 / 1000).toFixed(2)}s` : '--'; + const ok = (r.iterations || []).filter(it => !it.error).length; + const total = (r.iterations || []).length; + body += `| ${i + 1} | ${r.provider} | ${score} | ${med} | ${p95} | ${p99} | ${ok}/${total} |\n`; + }); + + body += '\n'; + } + + body += `---\n*[View full run](${runUrl}) ยท JSON artifacts available in the run artifacts*`; + + const { data: comments } = await github.rest.issues.listComments({ + owner: context.repo.owner, + repo: context.repo.repo, + issue_number: context.issue.number, + }); + + const existing = comments.find(c => c.body.startsWith(marker)); + + if (existing) { + await github.rest.issues.updateComment({ + owner: context.repo.owner, + repo: context.repo.repo, + comment_id: existing.id, + body, + }); + } else { + await github.rest.issues.createComment({ + owner: context.repo.owner, + repo: context.repo.repo, + issue_number: context.issue.number, + body, + }); + } From 619dd32c21fe524f7d89abb49d9ed3e14424a028 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Thu, 16 Apr 2026 02:09:03 +0000 Subject: [PATCH 9/9] fix: correct LKB kernel checksum and improve PR failure reporting --- .../linux-kernel-builder-benchmarks.yml | 18 +++++++++++------- src/linux-kernel-builder/benchmark.ts | 2 +- 2 files changed, 12 insertions(+), 8 deletions(-) diff --git a/.github/workflows/linux-kernel-builder-benchmarks.yml b/.github/workflows/linux-kernel-builder-benchmarks.yml index a88ebd2..492ba32 100644 --- a/.github/workflows/linux-kernel-builder-benchmarks.yml +++ b/.github/workflows/linux-kernel-builder-benchmarks.yml @@ -128,22 +128,26 @@ jobs: const results = Array.from(byProvider.values()) .sort((a, b) => (b.compositeScore || 0) - (a.compositeScore || 0)); - body += '| # | Provider | Score | Build Median | Build P95 | Build P99 | Status |\n'; - body += '|---|----------|-------|--------------|-----------|-----------|--------|\n'; + body += '| # | Provider | Score | Build Median | Build P95 | Build P99 | Status | Sample Failure |\n'; + body += '|---|----------|-------|--------------|-----------|-----------|--------|----------------|\n'; results.forEach((r, i) => { if (r.skipped) { - body += `| ${i + 1} | ${r.provider} | -- | -- | -- | -- | SKIPPED |\n`; + const reason = (r.skipReason || '').replace(/\n/g, ' ').slice(0, 120); + body += `| ${i + 1} | ${r.provider} | -- | -- | -- | -- | SKIPPED | ${reason || '--'} |\n`; return; } const score = r.compositeScore !== undefined ? r.compositeScore.toFixed(1) : '--'; - const med = r.summary?.buildMs ? `${(r.summary.buildMs.median / 1000).toFixed(2)}s` : '--'; - const p95 = r.summary?.buildMs ? `${(r.summary.buildMs.p95 / 1000).toFixed(2)}s` : '--'; - const p99 = r.summary?.buildMs ? `${(r.summary.buildMs.p99 / 1000).toFixed(2)}s` : '--'; const ok = (r.iterations || []).filter(it => !it.error).length; const total = (r.iterations || []).length; - body += `| ${i + 1} | ${r.provider} | ${score} | ${med} | ${p95} | ${p99} | ${ok}/${total} |\n`; + const hasSuccess = ok > 0; + const med = hasSuccess && r.summary?.buildMs ? `${(r.summary.buildMs.median / 1000).toFixed(2)}s` : '--'; + const p95 = hasSuccess && r.summary?.buildMs ? `${(r.summary.buildMs.p95 / 1000).toFixed(2)}s` : '--'; + const p99 = hasSuccess && r.summary?.buildMs ? `${(r.summary.buildMs.p99 / 1000).toFixed(2)}s` : '--'; + const firstError = (r.iterations || []).find(it => it.error)?.error || ''; + const compactError = firstError.replace(/\n/g, ' ').slice(0, 120); + body += `| ${i + 1} | ${r.provider} | ${score} | ${med} | ${p95} | ${p99} | ${ok}/${total} | ${compactError || '--'} |\n`; }); body += '\n'; diff --git a/src/linux-kernel-builder/benchmark.ts b/src/linux-kernel-builder/benchmark.ts index 42c5002..3d2ea17 100644 --- a/src/linux-kernel-builder/benchmark.ts +++ b/src/linux-kernel-builder/benchmark.ts @@ -5,7 +5,7 @@ import { KERNEL_VERSION, WORKLOAD, WORKLOAD_ACRONYM, WORKLOAD_LABEL } from './ty const KERNEL_TARBALL = `linux-${KERNEL_VERSION}.tar.xz`; const KERNEL_URL = `https://cdn.kernel.org/pub/linux/kernel/v6.x/${KERNEL_TARBALL}`; -const KERNEL_SHA256 = '335aeec4f6af045d958e2dabaf55222349933e396df17b5cd31798f5ec7f8c35'; +const KERNEL_SHA256 = '643142c1b5991560dd12f950825cc19e4497b95b82641918ecff1177f4130c1d'; function parseResultLine(output: string): { buildMs: number; cpuCount?: number; memTotalKb?: number } | null { const markerLine = output