Skip to content

get_minimal_required_cuda_ver_from_ptx_ver rejects PTX ISA 9.4 (CUDA 13.4) #3336

Closed

Description

@0z5a

Is this a duplicate?

Type of Bug

Runtime Error

Component

cuda.bindings

Describe the bug

cuda.bindings.utils.get_minimal_required_cuda_ver_from_ptx_ver raises for PTX produced by the CUDA 13.4 toolchain, because _ptx_to_cuda in cuda/bindings/utils/_ptx_utils.py ends at "9.3": (13, 3). The PTX ISA release history lists PTX ISA 9.4 with CUDA 13.4 (driver r615).

How to Reproduce

cuda-bindings 13.4.4 with nvidia-cuda-nvrtc 13.4 (no GPU needed):

from cuda.bindings import nvrtc
from cuda.bindings.utils import get_ptx_ver, get_minimal_required_cuda_ver_from_ptx_ver

err, prog = nvrtc.nvrtcCreateProgram(b'extern "C" __global__ void k(){}', b"k.cu", 0, [], [])
nvrtc.nvrtcCompileProgram(prog, 1, [b"-arch=compute_90"])
err, n = nvrtc.nvrtcGetPTXSize(prog)
buf = b" " * n
nvrtc.nvrtcGetPTX(prog, buf)
ver = get_ptx_ver(buf.decode())  # "9.4"
get_minimal_required_cuda_ver_from_ptx_ver(ver)
ValueError: Unknown or unsupported PTX ISA version: 9.4

Expected behavior

13040.

Operating System

Ubuntu 24.04, aarch64

nvidia-smi output

Not GPU-specific; NVRTC only, no GPU needed.

Proposed fix

I have a fix ready: the "9.4": (13, 4) entry, a 9.4 case in test_ptx_utils and a release note. The same line would be needed on the 13.4.x branch. Happy to open a PR if you assign this to me.

Activity

  1. added
    bugSomething isn't working
    cuda.bindingsEverything related to the cuda.bindings module
    and removed
    triageNeeds the team's attention
    on Nov 3, 2026
  2. leofang commented on Nov 3, 2026

    @leofang
    Member

    @rwgk @mdboom we missed this during 13.4 bring-up. I believe updating the table is documented in Ralf's (internal) bring-up manual.

  3. rwgk commented on Nov 3, 2026

    @rwgk
    Contributor

    7. @rwgk @mdboom we missed this during 13.4 bring-up. I believe updating the table is documented in Ralf's (internal) bring-up manual.

    Yes. It just easily falls through the cracks. Not sure what to do about it. I think we need a minimal reminder on the public side, to inspect the internal documentation as part of release preparation.

  4. assigned and unassigned on Nov 3, 2026
  5. rwgk commented on Nov 3, 2026

    @rwgk
    Contributor

    I assigned this issue to myself: I created PR #3348 already. In hindsight, it's a super obvious and simple way to ensure this doesn't happen again in the future. (Excuses omitted.)

  6. leofang commented on Nov 3, 2026

    @leofang
    Member

    No worries, I suppose we can add an item to the release checklist. Future ourselves and agents should be able to pick it up :)

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

Metadata

Metadata

Assignees

Labels

P0High priority - Must do!bugSomething isn't workingcuda.bindingsEverything related to the cuda.bindings module

Type

No type

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions