Skip to content

Debug info with non-ASCII characters breaks ptxas #2730

Open
@leoherz

Description

@leoherz

Describe the bug

When running my code, i receive the following message:

ERROR: LoadError: Failed to compile PTX code (ptxas exited with code 4294967295)
Invocation arguments: --generate-line-info --verbose --gpu-name sm_89 --output-file C:\Users\Leonardo\AppData\Local\Temp\jl_CZSpO5UVUL.cubin C:\Users\Leonardo\AppData\Local\Temp\jl_6herYrirE3.ptx
ptxas fatal : Unexpected non-ASCII character encountered on line 1288
ptxas fatal : Ptx assembly aborted due to errors
If you think this is a bug, please file an issue and attach C:\Users\Leonardo\AppData\Local\Temp\jl_6herYrirE3.ptx

To reproduce

The code is way too big and complex to be posted here. However, as stated in the error message, a ptxas file was generated in the Temp directory. I have include this file in the attachments jl_6herYrirE3_text.txt

Expected behavior

The code was working absolutely fine before. I updated my Julia version to 1.11.4 and installed the latest version of CUDA, and suddenly I started having this problem. Unfortunatelly, I did not write down the previous on version of Julia i was using (although i know for sure it was on the 1.10-x family) , neither the CUDA.jl

Version info

Details on Julia:

Julia Version 1.11.4
Commit 8561cc3d68 (2025-03-10 11:36 UTC)
Build Info:
Official https://julialang.org/ release
Platform Info:
OS: Windows (x86_64-w64-mingw32)
CPU: 32 × 13th Gen Intel(R) Core(TM) i9-13900K
WORD_SIZE: 64
LLVM: libLLVM-16.0.6 (ORCJIT, alderlake)
Threads: 1 default, 0 interactive, 1 GC (on 32 virtual cores)

Details on CUDA:

CUDA runtime 12.8, artifact installation
CUDA driver 12.8
NVIDIA driver 572.83.0

CUDA libraries:

  • CUBLAS: 12.8.4
  • CURAND: 10.3.9
  • CUFFT: 11.3.3
  • CUSOLVER: 11.7.3
  • CUSPARSE: 12.5.8
  • CUPTI: 2025.1.1 (API 26.0.0)
  • NVML: 12.0.0+572.83

Julia packages:

  • CUDA: 5.7.1
  • CUDA_Driver_jll: 0.12.1+1
  • CUDA_Runtime_jll: 0.16.1+0

Toolchain:

  • Julia: 1.11.4
  • LLVM: 16.0.6

1 device:
0: NVIDIA GeForce RTX 4090 (sm_89, 21.697 GiB / 23.988 GiB available)

Additional context

The error message "Unexpected non-ASCII character encountered" suggests that a certain character is causing the issue. My kernel code does include some Greek letters (Unicode symbols like θ). I’ve tried replacing all Greek letters with their textual descriptions (e.g., θ → theta), but the problem persists. Additionally, as I mentioned earlier, the kernel was working fine before I updated the software versions. I also attempted to examine the ptxas file, particularly at line 1288, but it only points to the function declaration of the kernel and doesn't seem to provide any further useful information — at least as far as I can tell.

Please let me know if I can help with any additional context. Thanks in advance !

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingcuda kernelsStuff about writing CUDA kernels.upstreamSomebody else's problem.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions