[PATCH] D83176: [OpenMPIRBuilder][Fix] Move llvm::omp::types to OpenMPIRBuilder.
Johannes Doerfert via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Jul 7 17:08:38 PDT 2020
jdoerfert accepted this revision.
jdoerfert added a comment.
This revision is now accepted and ready to land.
LGTM.
================
Comment at: llvm/lib/Frontend/OpenMP/OMPIRBuilder.cpp:1125
+#include "llvm/Frontend/OpenMP/OMPKinds.def"
+}
----------------
While we are here, remove `uninitializeTypes`
================
Comment at: llvm/lib/Transforms/IPO/OpenMPOpt.cpp:313
{ \
SmallVector<Type *, 8> ArgsTypes({__VA_ARGS__}); \
Function *F = M.getFunction(_Name); \
----------------
hoyFB wrote:
> sstefan1 wrote:
> > I wasn't sure how to handle `__VA_ARGS__` here, since we would need `OMPBuilder` in front of every type.
> > That is why helper macros above exist. The problem with this is that this creates some unused variables in `OpenMPOpt`.
> >
> > Not sure if `-Wno-unused-variable` would be a good thing to do temporarily? Is there another way to handle `__VA_ARGS__` here?
> Could it be possible to use `OMPBuilder. _Name`, `OMPBuilder. _ReturnType` everywhere?
Since this will (soonish) be replaced by tablegen definitions we can apply the following workaround:
Keep your helper macros but add
`(void) VarName;`
after each declaration :)
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D83176/new/
https://reviews.llvm.org/D83176
More information about the cfe-commits
mailing list