[llvm-branch-commits] [clang] [CIR][CUDA] Add NVPTX target info and CUDA/HIP global emission filtering (PR #177827)

via llvm-branch-commits llvm-branch-commits at lists.llvm.org
Sat Jan 24 21:02:31 PST 2026


github-actions[bot] wrote:

<!--LLVM CODE FORMAT COMMENT: {clang-format}-->


:warning: C/C++ code formatter, clang-format found issues in your code. :warning:

<details>
<summary>
You can test this locally with the following command:
</summary>

``````````bash
git-clang-format --diff origin/main HEAD --extensions h,cpp -- clang/lib/CIR/CodeGen/CIRGenModule.cpp clang/lib/CIR/CodeGen/CIRGenModule.h clang/lib/CIR/CodeGen/TargetInfo.cpp clang/lib/CIR/CodeGen/TargetInfo.h --diff_from_common_commit
``````````

:warning:
The reproduction instructions above might return results for more than one PR
in a stack if you are using a stacked PR workflow. You can limit the results by
changing `origin/main` to the base branch/commit you want to compare against.
:warning:

</details>

<details>
<summary>
View the diff from clang-format here.
</summary>

``````````diff
diff --git a/clang/lib/CIR/CodeGen/CIRGenModule.cpp b/clang/lib/CIR/CodeGen/CIRGenModule.cpp
index 64aee615e..ffe8d1e55 100644
--- a/clang/lib/CIR/CodeGen/CIRGenModule.cpp
+++ b/clang/lib/CIR/CodeGen/CIRGenModule.cpp
@@ -16,8 +16,8 @@
 #include "CIRGenFunction.h"
 
 #include "clang/AST/ASTContext.h"
-#include "clang/AST/DeclBase.h"
 #include "clang/AST/ASTLambda.h"
+#include "clang/AST/DeclBase.h"
 #include "clang/AST/DeclOpenACC.h"
 #include "clang/AST/GlobalDecl.h"
 #include "clang/AST/RecordLayout.h"
@@ -376,7 +376,8 @@ template <typename AttrT> static bool hasImplicitAttr(const ValueDecl *decl) {
 // or a non-generic lambda call operator.
 inline bool isLambdaCallOperator(const CXXMethodDecl *MD) {
   const CXXRecordDecl *LambdaClass = MD->getParent();
-  if (!LambdaClass || !LambdaClass->isLambda()) return false;
+  if (!LambdaClass || !LambdaClass->isLambda())
+    return false;
   return MD->getOverloadedOperator() == OO_Call;
 }
 
@@ -2045,8 +2046,6 @@ bool CIRGenModule::mayBeEmittedEagerly(const ValueDecl *global) {
   return true;
 }
 
-
-
 static bool shouldAssumeDSOLocal(const CIRGenModule &cgm,
                                  cir::CIRGlobalValueInterface gv) {
   if (gv.hasLocalLinkage())

``````````

</details>


https://github.com/llvm/llvm-project/pull/177827


More information about the llvm-branch-commits mailing list