Skip to content

[CIR] Refactor floating point type constraints #138112

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 2, 2025

Conversation

xlauko
Copy link
Contributor

@xlauko xlauko commented May 1, 2025

  • This cleans up moves cir floating point type constraints to dedicated constraints file, and fixes long double verifier to use constraints directly.
  • Renames CIR_AnyFloat to CIR_AnyFloatType.

This mirrors inbubator changes from llvm/clangir#1594

@xlauko xlauko marked this pull request as ready for review May 1, 2025 10:48
@xlauko xlauko requested review from lanza and bcardosolopes as code owners May 1, 2025 10:48
@xlauko
Copy link
Contributor Author

xlauko commented May 1, 2025

This stack of pull requests is managed by Graphite. Learn more about stacking.

@llvmbot llvmbot added clang Clang issues not falling into any other category ClangIR Anything related to the ClangIR project labels May 1, 2025
@xlauko xlauko requested a review from andykaylor May 1, 2025 10:49
@llvmbot
Copy link
Member

llvmbot commented May 1, 2025

@llvm/pr-subscribers-clang

Author: Henrich Lauko (xlauko)

Changes
  • This cleans up moves cir floating point type constraints to dedicated constraints file, and fixes long double verifier to use constraints directly.
  • Renames CIR_AnyFloat to CIR_AnyFloatType.

This mirrors inbubator changes from llvm/clangir#1594


Full diff: https://github.com/llvm/llvm-project/pull/138112.diff

4 Files Affected:

  • (modified) clang/include/clang/CIR/Dialect/IR/CIRTypeConstraints.td (+29)
  • (modified) clang/include/clang/CIR/Dialect/IR/CIRTypes.h (-1)
  • (modified) clang/include/clang/CIR/Dialect/IR/CIRTypes.td (+7-16)
  • (modified) clang/lib/CIR/Dialect/IR/CIRTypes.cpp (-20)
diff --git a/clang/include/clang/CIR/Dialect/IR/CIRTypeConstraints.td b/clang/include/clang/CIR/Dialect/IR/CIRTypeConstraints.td
index 3b8cb20da8edb..274b9e509f0d6 100644
--- a/clang/include/clang/CIR/Dialect/IR/CIRTypeConstraints.td
+++ b/clang/include/clang/CIR/Dialect/IR/CIRTypeConstraints.td
@@ -110,4 +110,33 @@ def CIR_AnyFundamentalSIntType
     let cppFunctionName = "isFundamentalSIntType";
 }
 
+//===----------------------------------------------------------------------===//
+// Float Type predicates
+//===----------------------------------------------------------------------===//
+
+def CIR_AnySingleType : CIR_TypeBase<"::cir::SingleType", "single float type">;
+def CIR_AnyFP32Type : TypeAlias<CIR_AnySingleType>;
+
+def CIR_AnyDoubleType : CIR_TypeBase<"::cir::DoubleType", "double float type">;
+def CIR_AnyFP64Type : TypeAlias<CIR_AnyDoubleType>;
+
+def CIR_AnyFP16Type : CIR_TypeBase<"::cir::FP16Type", "f16 type">;
+def CIR_AnyBFloat16Type : CIR_TypeBase<"::cir::BF16Type", "bf16 type">;
+def CIR_AnyFP80Type : CIR_TypeBase<"::cir::FP80Type", "f80 type">;
+def CIR_AnyFP128Type : CIR_TypeBase<"::cir::FP128Type", "f128 type">;
+def CIR_AnyLongDoubleType : CIR_TypeBase<"::cir::LongDoubleType",
+    "long double type">;
+
+def CIR_AnyFloatType : AnyTypeOf<[
+    CIR_AnySingleType, CIR_AnyDoubleType, CIR_AnyFP16Type,
+    CIR_AnyBFloat16Type, CIR_AnyFP80Type, CIR_AnyFP128Type,
+    CIR_AnyLongDoubleType
+]> {
+    let cppFunctionName = "isAnyFloatingPointType";
+}
+
+def CIR_AnyIntOrFloat : AnyTypeOf<[CIR_AnyFloatType, CIR_AnyIntType]>;
+
+
+
 #endif // CLANG_CIR_DIALECT_IR_CIRTYPECONSTRAINTS_TD
diff --git a/clang/include/clang/CIR/Dialect/IR/CIRTypes.h b/clang/include/clang/CIR/Dialect/IR/CIRTypes.h
index 2e32765c1e941..3845fd2a4b67d 100644
--- a/clang/include/clang/CIR/Dialect/IR/CIRTypes.h
+++ b/clang/include/clang/CIR/Dialect/IR/CIRTypes.h
@@ -26,7 +26,6 @@ struct RecordTypeStorage;
 
 bool isValidFundamentalIntWidth(unsigned width);
 
-bool isAnyFloatingPointType(mlir::Type t);
 bool isFPOrFPVectorTy(mlir::Type);
 
 } // namespace cir
diff --git a/clang/include/clang/CIR/Dialect/IR/CIRTypes.td b/clang/include/clang/CIR/Dialect/IR/CIRTypes.td
index d9f05c9aea63d..959e2cd822e76 100644
--- a/clang/include/clang/CIR/Dialect/IR/CIRTypes.td
+++ b/clang/include/clang/CIR/Dialect/IR/CIRTypes.td
@@ -80,12 +80,10 @@ def CIR_IntType : CIR_Type<"Int", "int",
 // FloatType
 //===----------------------------------------------------------------------===//
 
-class CIR_FloatType<string name, string mnemonic>
-    : CIR_Type<name, mnemonic,
-          [
-            DeclareTypeInterfaceMethods<DataLayoutTypeInterface>,
-            DeclareTypeInterfaceMethods<CIRFPTypeInterface>,
-          ]> {}
+class CIR_FloatType<string name, string mnemonic> : CIR_Type<name, mnemonic, [
+  DeclareTypeInterfaceMethods<DataLayoutTypeInterface>,
+  DeclareTypeInterfaceMethods<CIRFPTypeInterface>
+]>;
 
 def CIR_Single : CIR_FloatType<"Single", "float"> {
   let summary = "CIR single-precision 32-bit float type";
@@ -155,21 +153,14 @@ def CIR_LongDouble : CIR_FloatType<"LongDouble", "long_double"> {
     format are all in use.
   }];
 
-  let parameters = (ins "mlir::Type":$underlying);
+  let parameters = (ins AnyTypeOf<[CIR_Double, CIR_FP80, CIR_FP128],
+    "expects !cir.double, !cir.fp80 or !cir.fp128">:$underlying);
 
   let assemblyFormat = [{
     `<` $underlying `>`
   }];
-
-  let genVerifyDecl = 1;
 }
 
-// Constraints
-
-def CIR_AnyFloat: AnyTypeOf<[CIR_Single, CIR_Double, CIR_FP80, CIR_FP128,
-                             CIR_LongDouble, CIR_FP16, CIR_BFloat16]>;
-def CIR_AnyIntOrFloat: AnyTypeOf<[CIR_AnyFloat, CIR_IntType]>;
-
 //===----------------------------------------------------------------------===//
 // PointerType
 //===----------------------------------------------------------------------===//
@@ -518,7 +509,7 @@ def CIRRecordType : Type<
 
 def CIR_AnyType : AnyTypeOf<[
   CIR_VoidType, CIR_BoolType, CIR_ArrayType, CIR_VectorType, CIR_IntType,
-  CIR_AnyFloat, CIR_PointerType, CIR_FuncType, CIR_RecordType
+  CIR_AnyFloatType, CIR_PointerType, CIR_FuncType, CIR_RecordType
 ]>;
 
 #endif // MLIR_CIR_DIALECT_CIR_TYPES
diff --git a/clang/lib/CIR/Dialect/IR/CIRTypes.cpp b/clang/lib/CIR/Dialect/IR/CIRTypes.cpp
index 7d960c21d7251..9a44f923ac143 100644
--- a/clang/lib/CIR/Dialect/IR/CIRTypes.cpp
+++ b/clang/lib/CIR/Dialect/IR/CIRTypes.cpp
@@ -550,26 +550,6 @@ LongDoubleType::getABIAlignment(const mlir::DataLayout &dataLayout,
       .getABIAlignment(dataLayout, params);
 }
 
-LogicalResult
-LongDoubleType::verify(function_ref<InFlightDiagnostic()> emitError,
-                       mlir::Type underlying) {
-  if (!mlir::isa<DoubleType, FP80Type, FP128Type>(underlying)) {
-    emitError() << "invalid underlying type for long double";
-    return failure();
-  }
-
-  return success();
-}
-
-//===----------------------------------------------------------------------===//
-// Floating-point type helpers
-//===----------------------------------------------------------------------===//
-
-bool cir::isAnyFloatingPointType(mlir::Type t) {
-  return isa<cir::SingleType, cir::DoubleType, cir::LongDoubleType,
-             cir::FP80Type, cir::BF16Type, cir::FP16Type, cir::FP128Type>(t);
-}
-
 //===----------------------------------------------------------------------===//
 // Floating-point and Float-point Vector type helpers
 //===----------------------------------------------------------------------===//

@llvmbot
Copy link
Member

llvmbot commented May 1, 2025

@llvm/pr-subscribers-clangir

Author: Henrich Lauko (xlauko)

Changes
  • This cleans up moves cir floating point type constraints to dedicated constraints file, and fixes long double verifier to use constraints directly.
  • Renames CIR_AnyFloat to CIR_AnyFloatType.

This mirrors inbubator changes from llvm/clangir#1594


Full diff: https://github.com/llvm/llvm-project/pull/138112.diff

4 Files Affected:

  • (modified) clang/include/clang/CIR/Dialect/IR/CIRTypeConstraints.td (+29)
  • (modified) clang/include/clang/CIR/Dialect/IR/CIRTypes.h (-1)
  • (modified) clang/include/clang/CIR/Dialect/IR/CIRTypes.td (+7-16)
  • (modified) clang/lib/CIR/Dialect/IR/CIRTypes.cpp (-20)
diff --git a/clang/include/clang/CIR/Dialect/IR/CIRTypeConstraints.td b/clang/include/clang/CIR/Dialect/IR/CIRTypeConstraints.td
index 3b8cb20da8edb..274b9e509f0d6 100644
--- a/clang/include/clang/CIR/Dialect/IR/CIRTypeConstraints.td
+++ b/clang/include/clang/CIR/Dialect/IR/CIRTypeConstraints.td
@@ -110,4 +110,33 @@ def CIR_AnyFundamentalSIntType
     let cppFunctionName = "isFundamentalSIntType";
 }
 
+//===----------------------------------------------------------------------===//
+// Float Type predicates
+//===----------------------------------------------------------------------===//
+
+def CIR_AnySingleType : CIR_TypeBase<"::cir::SingleType", "single float type">;
+def CIR_AnyFP32Type : TypeAlias<CIR_AnySingleType>;
+
+def CIR_AnyDoubleType : CIR_TypeBase<"::cir::DoubleType", "double float type">;
+def CIR_AnyFP64Type : TypeAlias<CIR_AnyDoubleType>;
+
+def CIR_AnyFP16Type : CIR_TypeBase<"::cir::FP16Type", "f16 type">;
+def CIR_AnyBFloat16Type : CIR_TypeBase<"::cir::BF16Type", "bf16 type">;
+def CIR_AnyFP80Type : CIR_TypeBase<"::cir::FP80Type", "f80 type">;
+def CIR_AnyFP128Type : CIR_TypeBase<"::cir::FP128Type", "f128 type">;
+def CIR_AnyLongDoubleType : CIR_TypeBase<"::cir::LongDoubleType",
+    "long double type">;
+
+def CIR_AnyFloatType : AnyTypeOf<[
+    CIR_AnySingleType, CIR_AnyDoubleType, CIR_AnyFP16Type,
+    CIR_AnyBFloat16Type, CIR_AnyFP80Type, CIR_AnyFP128Type,
+    CIR_AnyLongDoubleType
+]> {
+    let cppFunctionName = "isAnyFloatingPointType";
+}
+
+def CIR_AnyIntOrFloat : AnyTypeOf<[CIR_AnyFloatType, CIR_AnyIntType]>;
+
+
+
 #endif // CLANG_CIR_DIALECT_IR_CIRTYPECONSTRAINTS_TD
diff --git a/clang/include/clang/CIR/Dialect/IR/CIRTypes.h b/clang/include/clang/CIR/Dialect/IR/CIRTypes.h
index 2e32765c1e941..3845fd2a4b67d 100644
--- a/clang/include/clang/CIR/Dialect/IR/CIRTypes.h
+++ b/clang/include/clang/CIR/Dialect/IR/CIRTypes.h
@@ -26,7 +26,6 @@ struct RecordTypeStorage;
 
 bool isValidFundamentalIntWidth(unsigned width);
 
-bool isAnyFloatingPointType(mlir::Type t);
 bool isFPOrFPVectorTy(mlir::Type);
 
 } // namespace cir
diff --git a/clang/include/clang/CIR/Dialect/IR/CIRTypes.td b/clang/include/clang/CIR/Dialect/IR/CIRTypes.td
index d9f05c9aea63d..959e2cd822e76 100644
--- a/clang/include/clang/CIR/Dialect/IR/CIRTypes.td
+++ b/clang/include/clang/CIR/Dialect/IR/CIRTypes.td
@@ -80,12 +80,10 @@ def CIR_IntType : CIR_Type<"Int", "int",
 // FloatType
 //===----------------------------------------------------------------------===//
 
-class CIR_FloatType<string name, string mnemonic>
-    : CIR_Type<name, mnemonic,
-          [
-            DeclareTypeInterfaceMethods<DataLayoutTypeInterface>,
-            DeclareTypeInterfaceMethods<CIRFPTypeInterface>,
-          ]> {}
+class CIR_FloatType<string name, string mnemonic> : CIR_Type<name, mnemonic, [
+  DeclareTypeInterfaceMethods<DataLayoutTypeInterface>,
+  DeclareTypeInterfaceMethods<CIRFPTypeInterface>
+]>;
 
 def CIR_Single : CIR_FloatType<"Single", "float"> {
   let summary = "CIR single-precision 32-bit float type";
@@ -155,21 +153,14 @@ def CIR_LongDouble : CIR_FloatType<"LongDouble", "long_double"> {
     format are all in use.
   }];
 
-  let parameters = (ins "mlir::Type":$underlying);
+  let parameters = (ins AnyTypeOf<[CIR_Double, CIR_FP80, CIR_FP128],
+    "expects !cir.double, !cir.fp80 or !cir.fp128">:$underlying);
 
   let assemblyFormat = [{
     `<` $underlying `>`
   }];
-
-  let genVerifyDecl = 1;
 }
 
-// Constraints
-
-def CIR_AnyFloat: AnyTypeOf<[CIR_Single, CIR_Double, CIR_FP80, CIR_FP128,
-                             CIR_LongDouble, CIR_FP16, CIR_BFloat16]>;
-def CIR_AnyIntOrFloat: AnyTypeOf<[CIR_AnyFloat, CIR_IntType]>;
-
 //===----------------------------------------------------------------------===//
 // PointerType
 //===----------------------------------------------------------------------===//
@@ -518,7 +509,7 @@ def CIRRecordType : Type<
 
 def CIR_AnyType : AnyTypeOf<[
   CIR_VoidType, CIR_BoolType, CIR_ArrayType, CIR_VectorType, CIR_IntType,
-  CIR_AnyFloat, CIR_PointerType, CIR_FuncType, CIR_RecordType
+  CIR_AnyFloatType, CIR_PointerType, CIR_FuncType, CIR_RecordType
 ]>;
 
 #endif // MLIR_CIR_DIALECT_CIR_TYPES
diff --git a/clang/lib/CIR/Dialect/IR/CIRTypes.cpp b/clang/lib/CIR/Dialect/IR/CIRTypes.cpp
index 7d960c21d7251..9a44f923ac143 100644
--- a/clang/lib/CIR/Dialect/IR/CIRTypes.cpp
+++ b/clang/lib/CIR/Dialect/IR/CIRTypes.cpp
@@ -550,26 +550,6 @@ LongDoubleType::getABIAlignment(const mlir::DataLayout &dataLayout,
       .getABIAlignment(dataLayout, params);
 }
 
-LogicalResult
-LongDoubleType::verify(function_ref<InFlightDiagnostic()> emitError,
-                       mlir::Type underlying) {
-  if (!mlir::isa<DoubleType, FP80Type, FP128Type>(underlying)) {
-    emitError() << "invalid underlying type for long double";
-    return failure();
-  }
-
-  return success();
-}
-
-//===----------------------------------------------------------------------===//
-// Floating-point type helpers
-//===----------------------------------------------------------------------===//
-
-bool cir::isAnyFloatingPointType(mlir::Type t) {
-  return isa<cir::SingleType, cir::DoubleType, cir::LongDoubleType,
-             cir::FP80Type, cir::BF16Type, cir::FP16Type, cir::FP128Type>(t);
-}
-
 //===----------------------------------------------------------------------===//
 // Floating-point and Float-point Vector type helpers
 //===----------------------------------------------------------------------===//

@xlauko xlauko requested a review from erichkeane May 1, 2025 10:49
@xlauko xlauko force-pushed the users/xlauko/cir-float-type-constraints branch from 17f61b8 to 3fb2fba Compare May 1, 2025 10:52
Copy link
Contributor

@andykaylor andykaylor left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, with one minor request.

// Float Type predicates
//===----------------------------------------------------------------------===//

def CIR_AnySingleType : CIR_TypeBase<"::cir::SingleType", "single float type">;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a reason for the explicit global scope?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe it used to make problems when core mlir dialects where included in out of tree projects/dialects.
Thats why entire mlir has explicit global scope, though I cannot remember the issue it was causing.

@xlauko xlauko force-pushed the users/xlauko/cir-float-type-constraints branch from 3fb2fba to 88149b4 Compare May 2, 2025 07:13
@xlauko xlauko force-pushed the users/xlauko/cir-type-constraints branch from 04686fc to 4e5819c Compare May 2, 2025 07:13
Base automatically changed from users/xlauko/cir-type-constraints to main May 2, 2025 07:15
- This cleans up moves cir floating point type constraints to dedicated constraints file, and fixes long double verifier to use constraints directly.
- Renames `CIR_AnyFloat` to `CIR_AnyFloatType`.

This mirrors inbubator changes from llvm/clangir#1594
@xlauko xlauko force-pushed the users/xlauko/cir-float-type-constraints branch from 88149b4 to fbbee19 Compare May 2, 2025 07:17
@xlauko xlauko merged commit ff28e1a into main May 2, 2025
6 of 11 checks passed
@xlauko
Copy link
Contributor Author

xlauko commented May 2, 2025

Merge activity

@xlauko xlauko deleted the users/xlauko/cir-float-type-constraints branch May 2, 2025 07:21
@llvm-ci
Copy link
Collaborator

llvm-ci commented May 2, 2025

LLVM Buildbot has detected a new failure on builder llvm-clang-aarch64-darwin running on doug-worker-4 while building clang at step 6 "test-build-unified-tree-check-all".

Full details are available at: https://lab.llvm.org/buildbot/#/builders/190/builds/19356

Here is the relevant piece of the build log for the reference
Step 6 (test-build-unified-tree-check-all) failure: test (failure)
******************** TEST 'Clang-Unit :: ./AllClangUnitTests/6/48' FAILED ********************
Script(shard):
--
GTEST_OUTPUT=json:/Users/buildbot/buildbot-root/aarch64-darwin/build/tools/clang/unittests/./AllClangUnitTests-Clang-Unit-7586-6-48.json GTEST_SHUFFLE=0 GTEST_TOTAL_SHARDS=48 GTEST_SHARD_INDEX=6 /Users/buildbot/buildbot-root/aarch64-darwin/build/tools/clang/unittests/./AllClangUnitTests
--

Script:
--
/Users/buildbot/buildbot-root/aarch64-darwin/build/tools/clang/unittests/./AllClangUnitTests --gtest_filter=TimeProfilerTest.ConstantEvaluationCxx20
--
/Users/buildbot/buildbot-root/aarch64-darwin/llvm-project/clang/unittests/Support/TimeProfilerTest.cpp:240: Failure
Expected equality of these values:
  R"(
Frontend (test.cc)
| ParseDeclarationOrFunctionDefinition (test.cc:2:1)
| ParseDeclarationOrFunctionDefinition (test.cc:6:1)
| | ParseFunctionDefinition (slow_func)
| | | EvaluateAsRValue (<test.cc:8:21>)
| | | EvaluateForOverflow (<test.cc:8:21, col:25>)
| | | EvaluateForOverflow (<test.cc:8:30, col:32>)
| | | EvaluateAsRValue (<test.cc:9:14>)
| | | EvaluateForOverflow (<test.cc:9:9, col:14>)
| | | isPotentialConstantExpr (slow_namespace::slow_func)
| | | EvaluateAsBooleanCondition (<test.cc:8:21, col:25>)
| | | | EvaluateAsRValue (<test.cc:8:21, col:25>)
| | | EvaluateAsBooleanCondition (<test.cc:8:21, col:25>)
| | | | EvaluateAsRValue (<test.cc:8:21, col:25>)
| ParseDeclarationOrFunctionDefinition (test.cc:16:1)
| | ParseFunctionDefinition (slow_test)
| | | EvaluateAsInitializer (slow_value)
| | | EvaluateAsConstantExpr (<test.cc:17:33, col:59>)
| | | EvaluateAsConstantExpr (<test.cc:18:11, col:37>)
| ParseDeclarationOrFunctionDefinition (test.cc:22:1)
| | EvaluateAsConstantExpr (<test.cc:23:31, col:57>)
| | EvaluateAsRValue (<test.cc:22:14, line:23:58>)
| ParseDeclarationOrFunctionDefinition (test.cc:25:1)
| | EvaluateAsInitializer (slow_init_list)
| PerformPendingInstantiations
)"
    Which is: "\nFrontend (test.cc)\n| ParseDeclarationOrFunctionDefinition (test.cc:2:1)\n| ParseDeclarationOrFunctionDefinition (test.cc:6:1)\n| | ParseFunctionDefinition (slow_func)\n| | | EvaluateAsRValue (<test.cc:8:21>)\n| | | EvaluateForOverflow (<test.cc:8:21, col:25>)\n| | | EvaluateForOverflow (<test.cc:8:30, col:32>)\n| | | EvaluateAsRValue (<test.cc:9:14>)\n| | | EvaluateForOverflow (<test.cc:9:9, col:14>)\n| | | isPotentialConstantExpr (slow_namespace::slow_func)\n| | | EvaluateAsBooleanCondition (<test.cc:8:21, col:25>)\n| | | | EvaluateAsRValue (<test.cc:8:21, col:25>)\n| | | EvaluateAsBooleanCondition (<test.cc:8:21, col:25>)\n| | | | EvaluateAsRValue (<test.cc:8:21, col:25>)\n| ParseDeclarationOrFunctionDefinition (test.cc:16:1)\n| | ParseFunctionDefinition (slow_test)\n| | | EvaluateAsInitializer (slow_value)\n| | | EvaluateAsConstantExpr (<test.cc:17:33, col:59>)\n| | | EvaluateAsConstantExpr (<test.cc:18:11, col:37>)\n| ParseDeclarationOrFunctionDefinition (test.cc:22:1)\n| | EvaluateAsConstantExpr (<test.cc:23:31, col:57>)\n| | EvaluateAsRValue (<test.cc:22:14, line:23:58>)\n| ParseDeclarationOrFunctionDefinition (test.cc:25:1)\n| | EvaluateAsInitializer (slow_init_list)\n| PerformPendingInstantiations\n"
  buildTraceGraph(Json)
    Which is: "\nFrontend (test.cc)\n| ParseDeclarationOrFunctionDefinition (test.cc:2:1)\n| ParseDeclarationOrFunctionDefinition (test.cc:6:1)\n| | ParseFunctionDefinition (slow_func)\n| | | EvaluateAsRValue (<test.cc:8:21>)\n| | | EvaluateForOverflow (<test.cc:8:21, col:25>)\n| | | EvaluateForOverflow (<test.cc:8:30, col:32>)\n| | | EvaluateAsRValue (<test.cc:9:14>)\n| | | EvaluateForOverflow (<test.cc:9:9, col:14>)\n| | | isPotentialConstantExpr (slow_namespace::slow_func)\n| | | EvaluateAsBooleanCondition (<test.cc:8:21, col:25>)\n| | | | EvaluateAsRValue (<test.cc:8:21, col:25>)\n| | | EvaluateAsBooleanCondition (<test.cc:8:21, col:25>)\n| | | | EvaluateAsRValue (<test.cc:8:21, col:25>)\n| ParseDeclarationOrFunctionDefinition (test.cc:16:1)\n| | ParseFunctionDefinition (slow_test)\n| | | EvaluateAsInitializer (slow_value)\n| | | EvaluateAsConstantExpr (<test.cc:17:33, col:59>)\n| | | EvaluateAsConstantExpr (<test.cc:18:11, col:37>)\n| ParseDeclarationOrFunctionDefinition (test.cc:22:1)\n| | EvaluateAsConstantExpr (<test.cc:23:31, col:57>)\n| | EvaluateAsRValue (<test.cc:22:14, line:23:58>)\n| ParseDeclarationOrFunctionDefinition (test.cc:25:1)\n| | EvaluateAsInitializer (slow_init_list)\n| | PerformPendingInstantiations\n"
With diff:
@@ -24,3 +24,3 @@
 | ParseDeclarationOrFunctionDefinition (test.cc:25:1)
 | | EvaluateAsInitializer (slow_init_list)
-| PerformPendingInstantiations\n
+| | PerformPendingInstantiations\n


...

IanWood1 pushed a commit to IanWood1/llvm-project that referenced this pull request May 6, 2025
- This cleans up moves cir floating point type constraints to dedicated constraints file, and fixes long double verifier to use constraints directly.
- Renames `CIR_AnyFloat` to `CIR_AnyFloatType`.

This mirrors inbubator changes from llvm/clangir#1594
IanWood1 pushed a commit to IanWood1/llvm-project that referenced this pull request May 6, 2025
- This cleans up moves cir floating point type constraints to dedicated constraints file, and fixes long double verifier to use constraints directly.
- Renames `CIR_AnyFloat` to `CIR_AnyFloatType`.

This mirrors inbubator changes from llvm/clangir#1594
IanWood1 pushed a commit to IanWood1/llvm-project that referenced this pull request May 6, 2025
- This cleans up moves cir floating point type constraints to dedicated constraints file, and fixes long double verifier to use constraints directly.
- Renames `CIR_AnyFloat` to `CIR_AnyFloatType`.

This mirrors inbubator changes from llvm/clangir#1594
GeorgeARM pushed a commit to GeorgeARM/llvm-project that referenced this pull request May 7, 2025
- This cleans up moves cir floating point type constraints to dedicated constraints file, and fixes long double verifier to use constraints directly.
- Renames `CIR_AnyFloat` to `CIR_AnyFloatType`.

This mirrors inbubator changes from llvm/clangir#1594
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
clang Clang issues not falling into any other category ClangIR Anything related to the ClangIR project
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants