[PATCH] D94961: [OpenMP] Add OpenMP offloading toolchain for AMDGPU
Jon Chesterfield via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Feb 2 04:02:12 PST 2021
JonChesterfield added inline comments.
================
Comment at: clang/lib/Driver/Driver.cpp:755
+ *this, TT, *HostTC, C.getInputArgs(), Action::OFK_OpenMP);
+ else if (TT.isAMDGCN())
+ DeviceTC =
----------------
pdhaliwal wrote:
> JonChesterfield wrote:
> > Minor suggestion,
> > ```
> > if (TT.isNVPTX() {
> > ...
> > } else {
> > assert(TT.isAMDGCN());
> > ...
> > }```
> >
> > ? Semantically equivalent, but `if () else if ()` looks like there is a missing else clause.
> I think, having assert in last else is bit cleaner. What do you think?
I also prefer the if () else {assert()} construct.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D94961/new/
https://reviews.llvm.org/D94961
More information about the cfe-commits
mailing list