jdoerfert marked an inline comment as done.
jdoerfert added a comment.

Will fix the other two nits too.



================
Comment at: clang/lib/Parse/ParseOpenMP.cpp:1823
     ASTContext &ASTCtx = Actions.getASTContext();
-    TI.getAsVariantMatchInfo(ASTCtx, VMI, /* DeviceSetOnly */ true);
+    TI.getAsVariantMatchInfo(ASTCtx, VMI);
     OMPContext OMPCtx(ASTCtx.getLangOpts().OpenMPIsDevice,
----------------
mikerice wrote:
> One of the lit tests fails because this is called before semantic checks on 
> the score expression.  This function tries to evaluate the score as a 
> constant and if it isn't will crash.  Probably not specific to this change 
> but how can we deal with that?
> 
> ```
> int foo(void);
> #pragma omp begin declare variant match(implementation={vendor(score(foo()) 
> ibm)})
> #pragma omp end declare variant
> ```
Saw that too late but it's fixed now. We will ignore non-constant scores and 
evaluae non-constant user conditions as false. Note that both are not valid 
inputs we will diagnose later anyway.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D77414/new/

https://reviews.llvm.org/D77414



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to