Skip to content

[Issue]: --mem unit suffixes are inconsistent across sbatch/srun/salloc (K only in sbatch, T nowhere) #827

Description

@SumonAMD

Problem Description

The --mem flag accepts different unit suffixes depending on which submission command is used. sbatch --mem=1024K is accepted, but the same flag under srun and salloc fails with invalid memory value. None of the three accept a T (terabyte) suffix.

A script that works under sbatch breaks when the identical memory flag is passed to srun or salloc — a silent Slurm incompatibility.

Expected: all three commands accept the same [K|M|G|T] suffix set (case-insensitive, bare number = MiB), matching Slurm, whose sbatch/srun/salloc document --mem identically and share one parser.

Environment

  • OS: Ubuntu 22.04 LTS
  • CPU: AMD EPYC (x86_64 server-class)
  • GPU: AMD Instinct MI300X
  • ROCm Version: N/A — issue is in the spur scheduler/CLI, independent of the ROCm runtime
  • Component: spur

Steps to Reproduce

sbatch --mem=1024K --wrap 'true'   # accepted
srun   --mem=1024K true            # invalid memory value
salloc --mem=1024K                 # invalid memory value
sbatch --mem=1T --wrap 'true'      # rejected everywhere

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions