-
Notifications
You must be signed in to change notification settings - Fork 14.3k
Fix what seems to be a silly bug in gpu.set_default_device rewriting. Smoke test included. #75756
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
Conversation
Thank you for submitting a Pull Request (PR) to the LLVM Project! This PR will be automatically labeled and the relevant teams will be If you wish to, you can add reviewers by using the "Reviewers" section on this page. If this is not working for you, it is probably because you do not have write If you have received no comments on your PR for a week, you can request a review If you have further questions, they may be answered by the LLVM GitHub User Guide. You can also ask questions in a comment on this PR, on the LLVM Discord or on the forums. |
@llvm/pr-subscribers-mlir-gpu @llvm/pr-subscribers-mlir Author: Paul C Fuqua (pcf000) ChangesFull diff: https://github.com/llvm/llvm-project/pull/75756.diff 1 Files Affected:
diff --git a/mlir/lib/Conversion/GPUCommon/GPUToLLVMConversion.cpp b/mlir/lib/Conversion/GPUCommon/GPUToLLVMConversion.cpp
index b68baffb5a8565..94df3765a67e74 100644
--- a/mlir/lib/Conversion/GPUCommon/GPUToLLVMConversion.cpp
+++ b/mlir/lib/Conversion/GPUCommon/GPUToLLVMConversion.cpp
@@ -1334,8 +1334,9 @@ LogicalResult ConvertSetDefaultDeviceOpToGpuRuntimeCallPattern::matchAndRewrite(
gpu::SetDefaultDeviceOp op, OpAdaptor adaptor,
ConversionPatternRewriter &rewriter) const {
Location loc = op.getLoc();
- setDefaultDeviceCallBuilder.create(loc, rewriter, {adaptor.getDevIndex()});
- rewriter.replaceOp(op, {});
+ auto call = setDefaultDeviceCallBuilder.create(loc, rewriter,
+ {adaptor.getDevIndex()});
+ rewriter.replaceOp(op, call);
return success();
}
|
Thanks for the fix. also I’d look for a more descriptive title (and description) |
Smoke test included.
Fix gpu.set_default_device rewriting to properly use the new call. Smoke test included.
e8a7a7a
to
47645c1
Compare
@krzysz00 : I mentioned the need for fixing the title and description before merging, did you miss this? |
@joker-eph Yeah, I did miss this, I just got pinged with an "it's been approved and you've got write access, can you merge"? |
I did fix them with a !amend commit, as the documentation seemed to tell me: the squash-and-merge was supposed to recognise that and update title and description. |
No description provided.