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/CodeGen/CGHLSLBuiltins.cpp clang/lib/Headers/hlsl/hlsl_intrinsics.h 
clang/lib/Sema/HLSLBuiltinTypeDeclBuilder.cpp 
clang/lib/Sema/HLSLBuiltinTypeDeclBuilder.h clang/lib/Sema/SemaHLSL.cpp 
llvm/lib/Target/DirectX/DXILShaderFlags.cpp --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/Headers/hlsl/hlsl_intrinsics.h 
b/clang/lib/Headers/hlsl/hlsl_intrinsics.h
index e92f999fb..f7482ae8a 100644
--- a/clang/lib/Headers/hlsl/hlsl_intrinsics.h
+++ b/clang/lib/Headers/hlsl/hlsl_intrinsics.h
@@ -668,46 +668,47 @@ smoothstep(__detail::HLSL_FIXED_VECTOR<float, N> Min,
 
 inline bool CheckAccessFullyMapped(uint Status) {
   return static_cast<bool>(Status);
-  
-//===----------------------------------------------------------------------===//
-// fwidth builtin
-//===----------------------------------------------------------------------===//
-
-/// \fn T fwidth(T x)
-/// \brief Computes the sum of the absolute values of the partial derivatives
-/// with regard to the x and y screen space coordinates.
-/// \param x [in] The floating-point scalar or vector to process.
-///
-/// The return value is a floating-point scalar or vector where each element
-/// holds the computation of the matching element in the input.
-
-template <typename T>
-_HLSL_16BIT_AVAILABILITY(shadermodel, 6.2)
-const inline __detail::enable_if_t<__detail::is_arithmetic<T>::Value &&
-                                       __detail::is_same<half, T>::value,
-                                   T> fwidth(T input) {
-  return __detail::fwidth_impl(input);
-}
-
-template <typename T>
-const inline __detail::enable_if_t<
-    __detail::is_arithmetic<T>::Value && __detail::is_same<float, T>::value, T>
-fwidth(T input) {
-  return __detail::fwidth_impl(input);
-}
 
-template <int N>
-_HLSL_16BIT_AVAILABILITY(shadermodel, 6.2)
-const inline __detail::HLSL_FIXED_VECTOR<half, N> fwidth(
-    __detail::HLSL_FIXED_VECTOR<half, N> input) {
-  return __detail::fwidth_impl(input);
-}
-
-template <int N>
-const inline __detail::HLSL_FIXED_VECTOR<float, N>
-fwidth(__detail::HLSL_FIXED_VECTOR<float, N> input) {
-  return __detail::fwidth_impl(input);
-}
+  
//===----------------------------------------------------------------------===//
+  // fwidth builtin
+  
//===----------------------------------------------------------------------===//
+
+  /// \fn T fwidth(T x)
+  /// \brief Computes the sum of the absolute values of the partial derivatives
+  /// with regard to the x and y screen space coordinates.
+  /// \param x [in] The floating-point scalar or vector to process.
+  ///
+  /// The return value is a floating-point scalar or vector where each element
+  /// holds the computation of the matching element in the input.
+
+  template <typename T>
+  _HLSL_16BIT_AVAILABILITY(shadermodel, 6.2)
+  const inline __detail::enable_if_t<
+      __detail::is_arithmetic<T>::Value && __detail::is_same<half, T>::value, 
T>
+  fwidth(T input) {
+    return __detail::fwidth_impl(input);
+  }
+
+  template <typename T>
+  const inline __detail::enable_if_t<__detail::is_arithmetic<T>::Value &&
+                                         __detail::is_same<float, T>::value,
+                                     T>
+  fwidth(T input) {
+    return __detail::fwidth_impl(input);
+  }
+
+  template <int N>
+  _HLSL_16BIT_AVAILABILITY(shadermodel, 6.2)
+  const inline __detail::HLSL_FIXED_VECTOR<half, N> fwidth(
+      __detail::HLSL_FIXED_VECTOR<half, N> input) {
+    return __detail::fwidth_impl(input);
+  }
+
+  template <int N>
+  const inline __detail::HLSL_FIXED_VECTOR<float, N> fwidth(
+      __detail::HLSL_FIXED_VECTOR<float, N> input) {
+    return __detail::fwidth_impl(input);
+  }
 
 } // namespace hlsl
 #endif //_HLSL_HLSL_INTRINSICS_H_

``````````

</details>


https://github.com/llvm/llvm-project/pull/166449
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to