Skip to content

[Release-2.6] Fix bugs of empty_xpu and soft_shrink#1139

Merged
toyxu merged 2 commits into
release/2.6from
xyt/rc26_bugfix_2
Dec 3, 2024
Merged

[Release-2.6] Fix bugs of empty_xpu and soft_shrink#1139
toyxu merged 2 commits into
release/2.6from
xyt/rc26_bugfix_2

Conversation

@toyxu

@toyxu toyxu commented Dec 3, 2024

Copy link
Copy Markdown
Contributor

guangyey and others added 2 commits December 3, 2024 06:39
# Motivation
Fix pytorch/pytorch#140877
Some PyTorch C++ users could call empty op directly. In this situation,
lazy initialization would not have been triggered. So we have to add
`lazyInitDevice` here, which also aligns with CUDA
[convention](https://github.com/pytorch/pytorch/blob/150ffb6e07f3802f8d0d3e843486e77a872803cf/aten/src/ATen/cuda/EmptyTensor.cpp#L13).
@toyxu toyxu changed the title [Release-2.6] Fix bugs [Release-2.6] Fix bugs of empty_xpu and soft_shrink Dec 3, 2024
@toyxu toyxu merged commit f312190 into release/2.6 Dec 3, 2024
@toyxu toyxu deleted the xyt/rc26_bugfix_2 branch December 3, 2024 06:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants