[clang] [CIR][NFC] Fix build warnings after #154142 (PR #157724)

2025-09-09 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper approved this pull request. LGTM, Thanks https://github.com/llvm/llvm-project/pull/157724 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Add support for copy elision (PR #157713)

2025-09-09 Thread Amr Hesham via cfe-commits
@@ -44,16 +46,37 @@ CIRGenFunction::emitAutoVarAlloca(const VarDecl &d, if (ty->isVariablyModifiedType()) cgm.errorNYI(d.getSourceRange(), "emitAutoVarDecl: variably modified type"); + assert(!cir::MissingFeatures::openMP()); + Address address = Address::invalid();

[clang] [CIR] Upstream VisitOpaqueValueExpr support for Complex & Scalar (PR #157331)

2025-09-08 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/157331 >From 8941ba8930c4487c958c8f4746570575bb976931 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Sat, 6 Sep 2025 18:38:46 +0200 Subject: [PATCH] [CIR] Upstream VisitOpaqueValueExpr support for Complex & Sc

[clang] [CIR] Upstream FPToFPBuiltin ATanOp (PR #157496)

2025-09-08 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper created https://github.com/llvm/llvm-project/pull/157496 Upstream support for FPToFPBuiltin ATanOp >From baccdc42c8c4046788fa364dcc71780bfd6c9ab0 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Sun, 7 Sep 2025 22:30:39 +0200 Subject: [PATCH] [CIR] Upstream FPT

[clang] [CIR] Upstream FPToFPBuiltin ASinOp (PR #157350)

2025-09-08 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/157350 >From 764cd36f0b1ff4405616c126ac799e602a182f89 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Sun, 7 Sep 2025 18:58:07 +0200 Subject: [PATCH] [CIR] Upstream FPToFPBuiltin ASinOp --- clang/include/clang

[clang] [CIR] Upstream FPToFPBuiltin ASinOp (PR #157350)

2025-09-07 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper created https://github.com/llvm/llvm-project/pull/157350 Upstream support for FPToFPBuiltin ASinOp >From 764cd36f0b1ff4405616c126ac799e602a182f89 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Sun, 7 Sep 2025 18:58:07 +0200 Subject: [PATCH] [CIR] Upstream FPT

[clang] [CIR] Upstream VisitOpaqueValueExpr support for Complex & Scalar (PR #157331)

2025-09-07 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper created https://github.com/llvm/llvm-project/pull/157331 This change adds support for the OpaqueValueExpr for Complex & Scalar Issue: https://github.com/llvm/llvm-project/issues/141365 >From 8941ba8930c4487c958c8f4746570575bb976931 Mon Sep 17 00:00:00 2001 From

[clang] [CIR] Fix Complex emit promotion for Div op (PR #156963)

2025-09-05 Thread Amr Hesham via cfe-commits
@@ -749,6 +749,7 @@ mlir::Value ComplexExprEmitter::emitPromoted(const Expr *e, HANDLE_BINOP(Add) HANDLE_BINOP(Sub) HANDLE_BINOP(Mul) + HANDLE_BINOP(Div) AmrDeveloper wrote: For this test case, when the promotion type is not null The ol

[clang] [CIR] Implement CXX field default initialization (PR #157140)

2025-09-05 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper approved this pull request. LGTM, Thanks for updating GenExprComplex https://github.com/llvm/llvm-project/pull/157140 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinf

[clang] [CIR] Fix Complex emit promotion for Div op (PR #156963)

2025-09-05 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper closed https://github.com/llvm/llvm-project/pull/156963 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Support ComplexType in CallExpr args (PR #156236)

2025-09-03 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper edited https://github.com/llvm/llvm-project/pull/156236 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Support ComplexType in CallExpr args (PR #156236)

2025-09-03 Thread Amr Hesham via cfe-commits
@@ -909,3 +909,46 @@ void foo33(__builtin_va_list a) { // OGCG: %[[B_IMAG_PTR:.*]] = getelementptr inbounds nuw { float, float }, ptr %[[B_ADDR]], i32 0, i32 1 // OGCG: store float %[[RESULT_REAL]], ptr %[[B_REAL_PTR]], align 4 // OGCG: store float %[[RESULT_IMAG]], ptr %[[

[clang] [CIR] Upstream Atomic init for ComplexType (PR #156518)

2025-09-03 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper closed https://github.com/llvm/llvm-project/pull/156518 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Upstream FPToFPBuiltin ACosOp (PR #156356)

2025-09-03 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper closed https://github.com/llvm/llvm-project/pull/156356 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Support ComplexType in CallExpr args (PR #156236)

2025-09-03 Thread Amr Hesham via cfe-commits
@@ -909,3 +909,46 @@ void foo33(__builtin_va_list a) { // OGCG: %[[B_IMAG_PTR:.*]] = getelementptr inbounds nuw { float, float }, ptr %[[B_ADDR]], i32 0, i32 1 // OGCG: store float %[[RESULT_REAL]], ptr %[[B_REAL_PTR]], align 4 // OGCG: store float %[[RESULT_IMAG]], ptr %[[

[clang] [CIR][NFC] Fix build issue after AST modification (PR #156493)

2025-09-03 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper created https://github.com/llvm/llvm-project/pull/156493 Fix the build issue after AST modification >From 5462713936149bca0ba186dc48d104679b8ee2df Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Tue, 2 Sep 2025 19:00:35 +0200 Subject: [PATCH] [CIR][NFC] Fix bu

[clang] [CIR][NFC] Reorder GenExprComplex and add errors for unhandled visitors (PR #156241)

2025-09-03 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper closed https://github.com/llvm/llvm-project/pull/156241 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Upstream FPToFPBuiltin ACosOp (PR #156356)

2025-09-03 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper created https://github.com/llvm/llvm-project/pull/156356 Upstream support for FPToFPBuiltin ACosOp >From a23eb7b29d90a7afc9c02080ca9747f365a67270 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Sun, 31 Aug 2025 18:55:45 +0200 Subject: [PATCH] [CIR] Upstream bu

[clang] [CIR] Upstream FPToFPBuiltin ACosOp (PR #156356)

2025-09-02 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/156356 >From a23eb7b29d90a7afc9c02080ca9747f365a67270 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Sun, 31 Aug 2025 18:55:45 +0200 Subject: [PATCH 1/2] [CIR] Upstream builtin ACos op --- clang/include/clang

[clang] [CIR] Support ComplexType in CallExpr args (PR #156236)

2025-09-02 Thread Amr Hesham via cfe-commits
@@ -15,6 +15,7 @@ #include "CIRGenCXXABI.h" #include "CIRGenFunction.h" #include "CIRGenFunctionInfo.h" +#include "mlir/IR/Location.h" AmrDeveloper wrote: No, we can remove it, it's already imported by other files, thanks! https://github.com/llvm/llvm-project

[clang] [CIR] Support ComplexType in CallExpr args (PR #156236)

2025-09-02 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/156236 >From b823f59b8fcf77bfa3a703b86dc692fea8b8 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Sun, 31 Aug 2025 12:44:19 +0200 Subject: [PATCH 1/2] [CIR] Support ComplexType in CallExpr args --- clang/l

[clang] [CIR][NFC] Fix build issue after AST modification (PR #156493)

2025-09-02 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper closed https://github.com/llvm/llvm-project/pull/156493 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR][NFC] Fix build issue after AST modification (PR #156493)

2025-09-02 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/156493 >From 5462713936149bca0ba186dc48d104679b8ee2df Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Tue, 2 Sep 2025 19:00:35 +0200 Subject: [PATCH] [CIR][NFC] Fix build issue after AST modification --- clang

[clang] [CIR] Upstream FPToFPBuiltin ACosOp (PR #156356)

2025-09-02 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/156356 >From a23eb7b29d90a7afc9c02080ca9747f365a67270 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Sun, 31 Aug 2025 18:55:45 +0200 Subject: [PATCH 1/2] [CIR] Upstream builtin ACos op --- clang/include/clang

[clang] [CIR][NFC] Reorder GenExprComplex and add errors for unhandled visitors (PR #156241)

2025-08-31 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper created https://github.com/llvm/llvm-project/pull/156241 - Reorder the CIRGenExprComplex functions to be similar to OCG. - Add errors for unhandled visitors. - Rename the test file to be similar to `complex-mul-div`. Issue: https://github.com/llvm/llvm-project/is

[clang] [CIR] Support ComplexType in CallExpr args (PR #156236)

2025-08-31 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/156236 >From b823f59b8fcf77bfa3a703b86dc692fea8b8 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Sun, 31 Aug 2025 12:44:19 +0200 Subject: [PATCH] [CIR] Support ComplexType in CallExpr args --- clang/lib/C

[clang] [CIR] Support ComplexType in CallExpr args (PR #156236)

2025-08-31 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper created https://github.com/llvm/llvm-project/pull/156236 This change adds support for ComplexType in the CallExpr arg Issue: https://github.com/llvm/llvm-project/issues/141365 >From 6f5711fc1b51932fae194e34edd05a1b7a5ef1ab Mon Sep 17 00:00:00 2001 From: AmrDevel

[clang] [CIR] Implement VAArgExpr for ComplexType (PR #156092)

2025-08-30 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper closed https://github.com/llvm/llvm-project/pull/156092 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Implement VAArgExpr for ComplexType (PR #156092)

2025-08-30 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/156092 >From 5ec1b3bd422be52857c10fc16d9f1dc7268a18c8 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Fri, 29 Aug 2025 21:58:35 +0200 Subject: [PATCH 1/2] [CIR] Implement VAArgExpr for ComplexType --- clang/li

[clang] [CIR] Implement VAArgExpr for ComplexType (PR #156092)

2025-08-29 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper created https://github.com/llvm/llvm-project/pull/156092 This change adds support VAArgExpr for ComplexExpr Issue: https://github.com/llvm/llvm-project/issues/141365 >From 5ec1b3bd422be52857c10fc16d9f1dc7268a18c8 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date

[clang] [CIR] Upstream Re-Throw with no return (PR #154994)

2025-08-29 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/154994 >From f8c9593d519edadfe46a796333f1a590a6f0cdd4 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Fri, 22 Aug 2025 15:34:47 +0200 Subject: [PATCH 1/5] [CIR] Upstream Re-Throw with no return --- .../CIR/Dia

[clang] [CIR] DivOp & CompoundAssignmentDiv between ComplexType and ScalarType (PR #155167)

2025-08-29 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper closed https://github.com/llvm/llvm-project/pull/155167 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Complex Unary plus and minus with promoted type (PR #155486)

2025-08-27 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/155486 >From c97287958e5db1a598423b37ac63a940277f1988 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Tue, 26 Aug 2025 21:34:52 +0200 Subject: [PATCH 1/2] [CIR] Complex Unary plus and minus with promoted type -

[clang] [CIR] Complex Unary plus and minus with promoted type (PR #155486)

2025-08-26 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper created https://github.com/llvm/llvm-project/pull/155486 This change adds support for Complex unary plus and minus expressions with promoted type Issue: https://github.com/llvm/llvm-project/issues/141365 >From c97287958e5db1a598423b37ac63a940277f1988 Mon Sep 17

[clang] [CIR] Add support for initializing classes with multiple vtables (PR #155275)

2025-08-25 Thread Amr Hesham via cfe-commits
@@ -264,6 +289,37 @@ void CIRGenFunction::emitCtorPrologue(const CXXConstructorDecl *cd, } } +static Address applyNonVirtualAndVirtualOffset( +mlir::Location loc, CIRGenFunction &cgf, Address addr, +CharUnits nonVirtualOffset, mlir::Value virtualOffset, +const C

[clang] [CIR] Add support for initializing classes with multiple vtables (PR #155275)

2025-08-25 Thread Amr Hesham via cfe-commits
@@ -126,6 +127,32 @@ static bool isInitializerOfDynamicClass(const CXXCtorInitializer *baseInit) { return baseClassDecl->isDynamicClass(); } +namespace { +/// A visitor which checks whether an initializer uses 'this' in a +/// way which requires the vtable to be properly se

[clang] [CIR] Add support for initializing classes with multiple vtables (PR #155275)

2025-08-25 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper edited https://github.com/llvm/llvm-project/pull/155275 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Add support for initializing classes with multiple vtables (PR #155275)

2025-08-25 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper approved this pull request. LGMT, just nits https://github.com/llvm/llvm-project/pull/155275 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] DivOp & CompoundAssignmentDiv between ComplexType and ScalarType (PR #155167)

2025-08-24 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper created https://github.com/llvm/llvm-project/pull/155167 This change adds support for DivOp and CompoundAssignmentDiv between ComplexType and ScalarType Issue: https://github.com/llvm/llvm-project/issues/141365 >From 654e3bba22ce007bdb1e30e46ee898af6ec5e57f Mon

[clang] [CIR] Upstream Re-Throw with no return (PR #154994)

2025-08-23 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/154994 >From 0a0c6291aa24acbc4a758b141e0b1e56676d99fd Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Fri, 22 Aug 2025 15:34:47 +0200 Subject: [PATCH 1/4] [CIR] Upstream Re-Throw with no return --- .../CIR/Dia

[clang] [CIR] Upstream Re-Throw with no return (PR #154994)

2025-08-23 Thread Amr Hesham via cfe-commits
@@ -3800,4 +3800,58 @@ def CIR_VAArgOp : CIR_Op<"va_arg"> { }]; } +//===--===// +// ThrowOp +//===--===// + +def CIR_ThrowOp : CIR_Op<"thro

[clang] [CIR] Upstream Re-Throw with no return (PR #154994)

2025-08-23 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/154994 >From 0a0c6291aa24acbc4a758b141e0b1e56676d99fd Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Fri, 22 Aug 2025 15:34:47 +0200 Subject: [PATCH 1/3] [CIR] Upstream Re-Throw with no return --- .../CIR/Dia

[clang] [CIR] Upstream Re-Throw with no return (PR #154994)

2025-08-23 Thread Amr Hesham via cfe-commits
@@ -405,17 +405,37 @@ void LoweringPreparePass::lowerArrayCtor(cir::ArrayCtor op) { true); } +void LoweringPreparePass::lowerThrowOp(ThrowOp op) { AmrDeveloper wrote: I moved it, it was confusing that rethrow is in LP but throw i

[clang] [CIR] Upstream Re-Throw with no return (PR #154994)

2025-08-23 Thread Amr Hesham via cfe-commits
@@ -289,6 +291,52 @@ void CIRGenItaniumCXXABI::emitDestructorCall( vttTy, nullptr); } +// The idea here is creating a separate block for the throw with an +// `UnreachableOp` as the terminator. So, we branch from the current block +// to the throw b

[clang] [CIR] Upstream Re-Throw with no return (PR #154994)

2025-08-23 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/154994 >From 373d3c49c631955c9e4b50f7e9b9666fdb2faef4 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Fri, 22 Aug 2025 15:34:47 +0200 Subject: [PATCH 1/3] [CIR] Upstream Re-Throw with no return --- .../CIR/Dia

[clang] [CIR] Upstream DivOp for ComplexType (PR #153796)

2025-08-22 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper closed https://github.com/llvm/llvm-project/pull/153796 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Upstream DivOp for ComplexType (PR #153796)

2025-08-22 Thread Amr Hesham via cfe-commits
@@ -3013,6 +3013,47 @@ def CIR_ComplexMulOp : CIR_Op<"complex.mul", [ }]; } +def CIR_ComplexDivOp : CIR_Op<"complex.div", [ + Pure, SameOperandsAndResultType +]> { + let summary = "Complex division"; + let description = [{ +The `cir.complex.div` operation takes two co

[clang] [CIR] Upstream DivOp for ComplexType (PR #153796)

2025-08-22 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/153796 >From 6613d4c0d735461a0b5ef04da544f6ddf3f38541 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Wed, 13 Aug 2025 20:22:38 +0200 Subject: [PATCH 1/6] [CIR] Upstream DivOp for ComplexType --- clang/include

[clang] [CIR] Upstream DivOp for ComplexType (PR #153796)

2025-08-22 Thread Amr Hesham via cfe-commits
@@ -3013,6 +3013,47 @@ def CIR_ComplexMulOp : CIR_Op<"complex.mul", [ }]; } +def CIR_ComplexDivOp : CIR_Op<"complex.div", [ + Pure, SameOperandsAndResultType +]> { + let summary = "Complex division"; + let description = [{ +The `cir.complex.div` operation takes two co

[clang] [CIR] Upstream Re-Throw with no return (PR #154994)

2025-08-22 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/154994 >From ee45be1718bf21b394a8bb0893efff1a3416853c Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Fri, 22 Aug 2025 15:34:47 +0200 Subject: [PATCH 1/2] [CIR] Upstream Re-Throw with no return --- .../CIR/Dia

[clang] [CIR] Upstream DivOp for ComplexType (PR #153796)

2025-08-22 Thread Amr Hesham via cfe-commits
@@ -3013,6 +3013,47 @@ def CIR_ComplexMulOp : CIR_Op<"complex.mul", [ }]; } +def CIR_ComplexDivOp : CIR_Op<"complex.div", [ + Pure, SameOperandsAndResultType +]> { + let summary = "Complex division"; + let description = [{ +The `cir.complex.div` operation takes two co

[clang] [CIR] Upstream DivOp for ComplexType (PR #153796)

2025-08-22 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/153796 >From 6613d4c0d735461a0b5ef04da544f6ddf3f38541 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Wed, 13 Aug 2025 20:22:38 +0200 Subject: [PATCH 1/5] [CIR] Upstream DivOp for ComplexType --- clang/include

[clang] [CIR] Upstream Re-Throw with no return (PR #154994)

2025-08-22 Thread Amr Hesham via cfe-commits
AmrDeveloper wrote: - For the verification tests, I will add it in the emitThrow PR https://github.com/llvm/llvm-project/pull/154994 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Upstream Re-Throw with no return (PR #154994)

2025-08-22 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper created https://github.com/llvm/llvm-project/pull/154994 This change adds support for the throw op without sub expression and with noreturn Issue #154992 >From ee45be1718bf21b394a8bb0893efff1a3416853c Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Fri, 22

[clang] [CIR] Upstream DivOp for ComplexType (PR #153796)

2025-08-21 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/153796 >From 6613d4c0d735461a0b5ef04da544f6ddf3f38541 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Wed, 13 Aug 2025 20:22:38 +0200 Subject: [PATCH 1/4] [CIR] Upstream DivOp for ComplexType --- clang/include

[clang] [CIR] Run LoweringPrepare pass only for non CIR output (PR #154107)

2025-08-21 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper edited https://github.com/llvm/llvm-project/pull/154107 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Run LoweringPrepare pass only for non CIR output (PR #154107)

2025-08-21 Thread Amr Hesham via cfe-commits
@@ -110,9 +110,10 @@ class CIRGenConsumer : public clang::ASTConsumer { if (!FEOptions.ClangIRDisablePasses) { // Setup and run CIR pipeline. + bool EnableLoweringPrepare = Action != CIRGenAction::OutputType::EmitCIR; AmrDeveloper wrote: > It s

[clang] [CIR] Implement MemberExpr with VarDecl for ComplexType (PR #154307)

2025-08-20 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper closed https://github.com/llvm/llvm-project/pull/154307 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Implement MemberExpr with VarDecl for ComplexType (PR #154307)

2025-08-19 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper edited https://github.com/llvm/llvm-project/pull/154307 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Run LoweringPrepare pass only for non CIR output (PR #154107)

2025-08-19 Thread Amr Hesham via cfe-commits
@@ -110,9 +110,10 @@ class CIRGenConsumer : public clang::ASTConsumer { if (!FEOptions.ClangIRDisablePasses) { // Setup and run CIR pipeline. + bool EnableLoweringPrepare = Action != CIRGenAction::OutputType::EmitCIR; AmrDeveloper wrote: I upda

[clang] [CIR] Implement MemberExpr with VarDecl for COmplexType (PR #154307)

2025-08-19 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper created https://github.com/llvm/llvm-project/pull/154307 This change adds support for MemberExpr with VarDecl ComplexType Issue: https://github.com/llvm/llvm-project/issues/141365 >From dd84b6ff8ec1d695887ffe4168f5dd59ff9dbce2 Mon Sep 17 00:00:00 2001 From: AmrD

[clang] [CIR] Implement MemberExpr support for ComplexType (PR #154027)

2025-08-19 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper closed https://github.com/llvm/llvm-project/pull/154027 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Run LoweringPrepare pass only for non CIR output (PR #154107)

2025-08-18 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper deleted https://github.com/llvm/llvm-project/pull/154107 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Run LoweringPrepare pass only for non CIR output (PR #154107)

2025-08-18 Thread Amr Hesham via cfe-commits
@@ -15,53 +15,29 @@ struct HasDtor { ~HasDtor(); }; -// CHECK: acc.private.recipe @privatization__ZTSA5_7HasDtor : !cir.ptr> init { +// CHECK: acc.private.recipe @privatization__ZTSA5_7HasDtor : !cir.ptr> init { // CHECK-NEXT: ^bb0(%[[ARG:.*]]: !cir.ptr> {{.*}}): -// CH

[clang] [CIR] Run LoweringPrepare pass only for non CIR output (PR #154107)

2025-08-18 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/154107 >From ecd8ca3f42042ef65eef73cb743847538cededd1 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Mon, 18 Aug 2025 12:08:04 +0200 Subject: [PATCH 1/2] [CIR] Run LoweringPrepare pass only for non CIR output

[clang] [CIR] Run LoweringPrepare pass only for non CIR output (PR #154107)

2025-08-18 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper created https://github.com/llvm/llvm-project/pull/154107 Run Lowering preparing pass conditionally if the action is not to emit CIR >From ecd8ca3f42042ef65eef73cb743847538cededd1 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Mon, 18 Aug 2025 12:08:04 +0200 S

[clang] [CIR] Implement MemberExpr support for ComplexType (PR #154027)

2025-08-17 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper created https://github.com/llvm/llvm-project/pull/154027 This change adds support for the MemberExpr ComplexType Issue: https://github.com/llvm/llvm-project/issues/141365 >From 4133294ca1424acfc7b23078d7eea45af060670f Mon Sep 17 00:00:00 2001 From: AmrDeveloper

[clang] [CIR] Upstream DivOp for ComplexType (PR #153796)

2025-08-16 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/153796 >From 6613d4c0d735461a0b5ef04da544f6ddf3f38541 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Wed, 13 Aug 2025 20:22:38 +0200 Subject: [PATCH 1/3] [CIR] Upstream DivOp for ComplexType --- clang/include

[clang] [CIR] Upstream DivOp for ComplexType (PR #153796)

2025-08-16 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/153796 >From 6613d4c0d735461a0b5ef04da544f6ddf3f38541 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Wed, 13 Aug 2025 20:22:38 +0200 Subject: [PATCH 1/2] [CIR] Upstream DivOp for ComplexType --- clang/include

[clang] [CIR] Upstream DivOp for ComplexType (PR #153796)

2025-08-15 Thread Amr Hesham via cfe-commits
AmrDeveloper wrote: - Division between Complex & Scalar will be in follow-up PR https://github.com/llvm/llvm-project/pull/153796 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Upstream DivOp for ComplexType (PR #153796)

2025-08-15 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper created https://github.com/llvm/llvm-project/pull/153796 This change adds support for the division operation between two complex types Issue: #141365 >From 6613d4c0d735461a0b5ef04da544f6ddf3f38541 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Wed, 13 Aug 20

[clang] [CIR] Upstream builtin lowering emitter & FAbs op (PR #151750)

2025-08-11 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/151750 >From 64ae6442a22f4ad67c7af2089c3248a88f4cfc29 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Fri, 1 Aug 2025 20:48:02 +0200 Subject: [PATCH 1/4] [CIR] Upstream builtin fabs op --- clang/include/clang/

[clang] [CIR] Upstream builtin lowering emitter & FAbs op (PR #151750)

2025-08-11 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/151750 >From 64ae6442a22f4ad67c7af2089c3248a88f4cfc29 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Fri, 1 Aug 2025 20:48:02 +0200 Subject: [PATCH 1/4] [CIR] Upstream builtin fabs op --- clang/include/clang/

[clang] [CIR] Make ClangIR compatible with latest nested name specifier AST representation (PR #152846)

2025-08-11 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper closed https://github.com/llvm/llvm-project/pull/152846 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Make ClangIR compatible with latest nested name specifier AST representation (PR #152846)

2025-08-11 Thread Amr Hesham via cfe-commits
AmrDeveloper wrote: I think @darkbuck comitted a similar solution before I land 😕, I will rebase and land the diff from the code review comments https://github.com/llvm/llvm-project/pull/152846 ___ cfe-commits mailing list cfe-commits@lists.llvm.org h

[clang] [CIR] Make ClangIR compatible with latest nested name specifier AST representation (PR #152846)

2025-08-11 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/152846 >From 51882dd59abdc2a93f7ef18714568ce6f879e2f7 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Sat, 9 Aug 2025 11:48:23 +0200 Subject: [PATCH 1/2] [CIR] Make ClangIR compatible after AST representation m

[clang] [CIR] CompoundAssignment from ComplexType to ScalarType (PR #152915)

2025-08-10 Thread Amr Hesham via cfe-commits
AmrDeveloper wrote: Also, we can track the LValue type in the assignment, and if it is not complex, we can optimise the calculation more and not emit any complex create op for the result https://github.com/llvm/llvm-project/pull/152915 ___ cfe-commit

[clang] [CIR] CompoundAssignment from ComplexType to ScalarType (PR #152915)

2025-08-10 Thread Amr Hesham via cfe-commits
AmrDeveloper wrote: The current implementation in the incubator emits CreateComplexOp from the scalar and then emits ComplexBinOp to calculate the result between one complex and one scalar converted to complex. This approach is different from the OGCG because in the OGCG, it creates a track a

[clang] [CIR] CompoundAssignment from ComplexType to ScalarType (PR #152915)

2025-08-10 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper created https://github.com/llvm/llvm-project/pull/152915 This change adds support for the CompoundAssignment for ComplexType and updates our approach for emitting bin op between Complex & Scalar https://github.com/llvm/llvm-project/issues/141365 >From 1b36407a9

[clang] [CIR] Make ClangIR compatible with latest nested name specifier AST representation (PR #152846)

2025-08-09 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper edited https://github.com/llvm/llvm-project/pull/152846 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Make ClangIR compatible with latest nested name specifier AST representation (PR #152846)

2025-08-09 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/152846 >From 946f3718f7e67966f07c962e7283d7fd11d0b329 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Sat, 9 Aug 2025 11:48:23 +0200 Subject: [PATCH 1/4] [CIR] Make ClangIR compatible after AST representation m

[clang] [CIR] Make ClangIR compatible with latest nested name specifier AST representation (PR #152846)

2025-08-09 Thread Amr Hesham via cfe-commits
@@ -10,20 +10,20 @@ bool clang::CIRGen::isEmptyRecordForLayout(const ASTContext &context, if (!rt) return false; - const RecordDecl *rd = rt->getDecl(); + const RecordDecl *rd = rt->getOriginalDecl(); AmrDeveloper wrote: Thank you for the review and

[clang] [CIR] Make ClangIR compatible with latest nested name specifier AST representation (PR #152846)

2025-08-09 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/152846 >From 946f3718f7e67966f07c962e7283d7fd11d0b329 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Sat, 9 Aug 2025 11:48:23 +0200 Subject: [PATCH 1/3] [CIR] Make ClangIR compatible after AST representation m

[clang] [CIR] Make ClangIR compatible with latest nested name specifier AST representation (PR #152846)

2025-08-09 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/152846 >From 946f3718f7e67966f07c962e7283d7fd11d0b329 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Sat, 9 Aug 2025 11:48:23 +0200 Subject: [PATCH 1/2] [CIR] Make ClangIR compatible after AST representation m

[clang] [CIR] Make ClangIR compatible with latest nested name specifier AST representation (PR #152846)

2025-08-09 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper created https://github.com/llvm/llvm-project/pull/152846 After AST representation, new modifications landed in (https://github.com/llvm/llvm-project/pull/147835). ClangIR requires some changes in how we use Clang AST to be compatible with the new changes >From

[clang] [CIR][NFC] Fix typo in ComplexRangeKind comment (PR #152535)

2025-08-07 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper closed https://github.com/llvm/llvm-project/pull/152535 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Mul CompoundAssignment support for ComplexType (PR #152354)

2025-08-07 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper closed https://github.com/llvm/llvm-project/pull/152354 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Upstream builtin lowering emitter & FAbs op (PR #151750)

2025-08-07 Thread Amr Hesham via cfe-commits
@@ -0,0 +1,108 @@ +//===- CIRLoweringEmitter.cpp - Generate lowering of builtins --=-*- C++ -*--=// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang] [CIR][NFC] Fix typo in ComplexRangeKind comment (PR #152535)

2025-08-07 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper created https://github.com/llvm/llvm-project/pull/152535 Fix typo in ComplexRangeKind comment Catched in https://github.com/llvm/clangir/pull/1779 >From 1f4c7fb76dd14e76a868fd691ad25ee44bc4e795 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Thu, 7 Aug 2025 1

[clang] [CIR] Mul CompoundAssignment support for ComplexType (PR #152354)

2025-08-06 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/152354 >From 849151bd3ca671e1acf304e904134aa53733c88d Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Wed, 6 Aug 2025 18:53:34 +0200 Subject: [PATCH 1/2] [CIR] Mul CompoundAssignment support for ComplexType ---

[clang] [CIR] Mul CompoundAssignment support for ComplexType (PR #152354)

2025-08-06 Thread Amr Hesham via cfe-commits
@@ -286,3 +286,167 @@ void foo4() { // CXX_OGCG: %[[C_IMAG_PTR:.*]] = getelementptr inbounds nuw { i32, i32 }, ptr %[[C_ADDR]], i32 0, i32 1 // CXX_OGCG: store i32 %[[B_REAL]], ptr %[[C_REAL_PTR]], align 4 // CXX_OGCG: store i32 %[[B_IMAG]], ptr %[[C_IMAG_PTR]], align 4 +

[clang] [CIR] Mul CompoundAssignment support for ComplexType (PR #152354)

2025-08-06 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper created https://github.com/llvm/llvm-project/pull/152354 This change adds support for Mul CompoundAssignment for ComplexType https://github.com/llvm/llvm-project/issues/141365 >From 849151bd3ca671e1acf304e904134aa53733c88d Mon Sep 17 00:00:00 2001 From: AmrDevel

[clang] [CIR] Plus & Minus CompoundAssignment support for ComplexType (PR #150759)

2025-08-06 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper closed https://github.com/llvm/llvm-project/pull/150759 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Plus & Minus CompoundAssignment support for ComplexType (PR #150759)

2025-08-05 Thread Amr Hesham via cfe-commits
@@ -630,6 +654,104 @@ ComplexExprEmitter::emitBinOps(const BinaryOperator *e, QualType promotionTy) { return binOpInfo; } +LValue ComplexExprEmitter::emitCompoundAssignLValue( +const CompoundAssignOperator *e, +mlir::Value (ComplexExprEmitter::*func)(const BinOpInfo

[clang] [CIR] Plus & Minus CompoundAssignment support for ComplexType (PR #150759)

2025-08-05 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/150759 >From 966844c4bbb1a2794c184e9a47bf97aa782dcdfc Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Sat, 26 Jul 2025 14:43:06 +0200 Subject: [PATCH 1/5] [CIR] Plus & Minus CompoundAssignment support for Compl

[clang] [CIR] Plus & Minus CompoundAssignment support for ComplexType (PR #150759)

2025-08-05 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/150759 >From 966844c4bbb1a2794c184e9a47bf97aa782dcdfc Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Sat, 26 Jul 2025 14:43:06 +0200 Subject: [PATCH 1/5] [CIR] Plus & Minus CompoundAssignment support for Compl

[clang] [CIR] Upstream builtin lowering emitter & FAbs op (PR #151750)

2025-08-04 Thread Amr Hesham via cfe-commits
@@ -0,0 +1,108 @@ +//===- CIRLoweringEmitter.cpp - Generate lowering of builtins --=-*- C++ -*--=// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang] [CIR] Plus & Minus CompoundAssignment support for ComplexType (PR #150759)

2025-08-04 Thread Amr Hesham via cfe-commits
@@ -630,6 +654,104 @@ ComplexExprEmitter::emitBinOps(const BinaryOperator *e, QualType promotionTy) { return binOpInfo; } +LValue ComplexExprEmitter::emitCompoundAssignLValue( +const CompoundAssignOperator *e, +mlir::Value (ComplexExprEmitter::*func)(const BinOpInfo

[clang] [CIR] Plus & Minus CompoundAssignment support for ComplexType (PR #150759)

2025-08-04 Thread Amr Hesham via cfe-commits
@@ -0,0 +1,227 @@ +// RUN: %clang_cc1 -std=c++20 -triple x86_64-unknown-linux-gnu -Wno-unused-value -fclangir -emit-cir %s -o %t.cir +// RUN: FileCheck --input-file=%t.cir %s -check-prefix=CIR +// RUN: %clang_cc1 -x c -triple x86_64-unknown-linux-gnu -Wno-unused-value -fclangir

[clang] [CIR] Upstream builtin lowering emitter & FAbs op (PR #151750)

2025-08-04 Thread Amr Hesham via cfe-commits
@@ -0,0 +1,108 @@ +//===- CIRLoweringEmitter.cpp - Generate lowering of builtins --=-*- C++ -*--=// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

  1   2   3   4   5   6   7   8   9   >