Skip to content

Add a convenient shortcut Device.arch that returns the CC value as a string #729

Closed

Description

@leofang

btw I get annoyed having to do a silly string concat like this everywhere. Do you think it'd be better if we have a shortcut Device.arch that returns this string?

Originally posted by @leofang in #720 (comment)

This refers to the usage like this that we have everywhere:

arch = "".join(f"{i}" for i in dev.compute_capability)

I want to be able to just write

arch: str = dev.arch

Activity

  1. self-assigned this
    on Jun 26, 2025
  2. added this to the cuda.core parking lot milestone on Jun 26, 2025
  3. added
    enhancementAny code-related improvements
    P0High priority - Must do!
    cuda.coreEverything related to the cuda.core module
    and removed
    triageNeeds the team's attention
    on Jun 26, 2025
  4. leofang commented on Aug 21, 2025

    @leofang
    MemberAuthor

    @copilot please work on this. Make sure this change is propagated to all public samples that we have under cuda_cores/examples. It is OK to keep the old usage as is in the test files.

  5. moved this from Todo to Done in CCCLon Aug 21, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

P0High priority - Must do!cuda.coreEverything related to the cuda.core moduleenhancementAny code-related improvements

Type

No type

Projects

  • Status
    Done

Relationships

None yet

Development

No branches or pull requests

Issue actions