Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

[FEA]: Support inheritance from Buffer

Open Beginner friendly
#2,435 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
62/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Quiet
Tech stack
python
Domain
api

Research direction

Start by locating cuda.core's Buffer implementation and its from_handle() and _reduce_helper() methods, then inspect how returned instances are constructed. Review the related issue #750 and relevant Buffer behavior; done when subclasses inherit both methods and receive subclass instances without breaking existing Buffer behavior.

Written by the indexing model from the issue text.

Description

cuda.core triage
Is this a duplicate?
Area

cuda.core

Is your feature request related to a problem? Please describe.

nvmath-python is considering creating a subclass of Buffer specific to NVSHMEM because we want to mostly follow cuda.core's semantics for Buffer/MemoryResource, but need some different behavior regarding garbage collection.

Describe the solution you'd like

Buffer should use classmethod instead of staticmethod for all methods that return an instance of the class. i.e. from_handle() and _reduce_helper()

Describe alternatives you've considered

Composing Buffer with our Buffer.
Replicating the Buffer protocol with an unrelated class.
Rolling our own MemoryResource/Buffer abstraction that is unique to nvmath's distributed APIs.

Additional context

Related to: https://github.com/NVIDIA/cuda-python/issues/750

Dominant language
Cython
Stars
3.4k
Forks
329
Avg merge
1d 22h
Merged PRs (30d)
113

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from NVIDIA/cuda-python

All issues in NVIDIA/cuda-python

Similar issues

More Backend & API Design issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.