Open
Conversation
… misiug/slurmscripts
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Unified Launcher: Overview and Motivation
The
presto/slurm/unified/directory provides an alternative launcher for running Presto TPC-H benchmarks on Slurm. It is intended to produce identical benchmark results to the existingpresto/slurm/presto-nvl72/scripts while consolidating the execution logic into fewer files with a more linear control flow.How the original launcher works
The existing launcher involves several files and external tools that coordinate across multiple directories in the repository:
launch-run.shparses CLI arguments and submits the job viasbatch, passing parameters as exported environment variables.run-presto-benchmarks.slurmreceives those environment variables, sets up paths and computed values (e.g.,CONFIGSpointing topresto/docker/config/generated/gpu/), then delegates to a shell script.run-presto-benchmarks.shsources two helper files (echo_helpers.shandfunctions.sh) and orchestrates the benchmark phases: setup, coordinator launch, worker launch, schema creation, query execution, and result collection.functions.shcontains the actual implementation of each phase. During the setup phase, if generated configs do not already exist, it invokespresto/scripts/generate_presto_config.sh.generate_presto_config.shcalls thepbenchbinary (presto/pbench/pbench genconfig) to render Go-style templates frompresto/docker/config/template/using parameters frompresto/docker/config/params.json. After generation, it applies variant-specific patches (e.g., uncommenting GPU optimizer flags, toggling multi-worker settings) and duplicates per-worker configs via theduplicate_worker_configs()function, which appliessedtransformations to adjust ports, node IDs, and multi-node flags.In total, a single benchmark run traverses at least six files across four directories, plus the
pbenchbinary and its template/parameter inputs.How the unified launcher works
The unified launcher consists of two files:
launch.shparses CLI arguments and submits the job viasbatch.run.slurmcontains all logic in a single file: environment setup, config generation (from local templates inconfig-templates/), coordinator launch, worker launch, schema setup, and query execution.Configuration templates live in
config-templates/within the unified directory itself and use simple__PLACEHOLDER__substitution viased, with no external tooling required. Memory settings are computed dynamically from the node's actual RAM using the same formulas defined inparams.json.Parallel container loading
One structural improvement in the unified launcher is that all container images are loaded in parallel. The original launcher waits on the host for the coordinator to become active before launching workers, and waits for workers to register before launching the benchmark container. Each of these phases incurs a container image load delay. The unified launcher issues all
sruncommands immediately and moves the dependency waits inside the containers themselves, so image loading happens concurrently.Scope
This unified launcher was developed primarily for the use case of running TPC-H GPU benchmarks on Slurm with a straightforward configuration. The original implementation may have been architected with additional considerations in mind -- for example, supporting multiple variant types (CPU, GPU, Java), integration with broader infrastructure tooling via
pbench, or other workflows that benefit from the separation of template rendering and config patching. There may be more advanced use cases where the original implementation's flexibility is preferred or required, and this unified alternative is not intended to replace it in those scenarios.Note
Please note that this is based off of an older version of #202, and it seems there were some changes to the benchmark code that have broken it, so there may be a little bit of work to bring it up to speed. In its current form though the PR was still running on NVL72.