Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GpuArrowColumnarBatchBuilder retains the references of ArrowBuf until HostToGpuCoalesceIterator put them into device #1882

Merged
merged 2 commits into from
Mar 8, 2021

Conversation

Dooyoung-Hwang
Copy link
Contributor

GpuArrowColumnarBatchBuilder gets the ByteBuffer address directly from the ArrowBuf in host ColumnVector. Thus, when the provider of host ColumnVector such as custom data-source closes the ArrowBuf, the ByteBuffer memory area stored in GpuArrowColumnarBatchBuilder becomes invalid. In order to prevent the ByteBuffer memory from being deallocated, GpuArrowColumnarBatchBuilder obtains not only the ByteBuffer address but ReferenceManager from ArrowBuf and retains the ReferenceManager until it copies the ArrowBuf into device.

Signed-off-by: Dooyoung Hwang dooyoung.hwang@sk.com

@tgravescs tgravescs assigned tgravescs and unassigned tgravescs Mar 5, 2021
… HostToGpuCoalesceIterator put them into device

Signed-off-by: Dooyoung Hwang <dooyoung.hwang@sk.com>
@tgravescs
Copy link
Collaborator

build

tgravescs
tgravescs previously approved these changes Mar 5, 2021
… releases ArrowBuf's reference

Signed-off-by: Dooyoung Hwang <dooyoung.hwang@sk.com>
@tgravescs
Copy link
Collaborator

build

@tgravescs tgravescs merged commit 8787797 into NVIDIA:branch-0.5 Mar 8, 2021
@tgravescs tgravescs added this to the Mar 1 - Mar 12 milestone Mar 8, 2021
@tgravescs tgravescs added the feature request New feature or request label Mar 8, 2021
nartal1 pushed a commit to nartal1/spark-rapids that referenced this pull request Jun 9, 2021
… HostToGpuCoalesceIterator put them into device (NVIDIA#1882)

* GpuArrowColumnarBatchBuilder retains the references of ArrowBuf until HostToGpuCoalesceIterator put them into device

Signed-off-by: Dooyoung Hwang <dooyoung.hwang@sk.com>

* Add a testSuite to make sure GpuArrowColumnarBatchBuilder retains and releases ArrowBuf's reference

Signed-off-by: Dooyoung Hwang <dooyoung.hwang@sk.com>
nartal1 pushed a commit to nartal1/spark-rapids that referenced this pull request Jun 9, 2021
… HostToGpuCoalesceIterator put them into device (NVIDIA#1882)

* GpuArrowColumnarBatchBuilder retains the references of ArrowBuf until HostToGpuCoalesceIterator put them into device

Signed-off-by: Dooyoung Hwang <dooyoung.hwang@sk.com>

* Add a testSuite to make sure GpuArrowColumnarBatchBuilder retains and releases ArrowBuf's reference

Signed-off-by: Dooyoung Hwang <dooyoung.hwang@sk.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature request New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants