[PATCH] D24785: [AVX512] Fix return types on __builtin_ia32_gather3XivXdi builtins

2016-09-20 Thread Cameron McInally via cfe-commits
cameron.mcinally created this revision. cameron.mcinally added reviewers: delena, igorb, craig.topper. cameron.mcinally added a subscriber: cfe-commits. cameron.mcinally set the repository for this revision to rL LLVM. The return types on the AVX512 __builtin_ia32_gather3XivXdi builtins are incor

r282082 - [AVX512] Fix return types on __builtin_ia32_gather3XivXdi builtins

2016-09-21 Thread Cameron McInally via cfe-commits
Author: mcinally Date: Wed Sep 21 11:07:40 2016 New Revision: 282082 URL: http://llvm.org/viewvc/llvm-project?rev=282082&view=rev Log: [AVX512] Fix return types on __builtin_ia32_gather3XivXdi builtins The return types on the AVX512 __builtin_ia32_gather3XivXdi builtins are incorrect. The return

Re: [PATCH] D24785: [AVX512] Fix return types on __builtin_ia32_gather3XivXdi builtins

2016-09-22 Thread Cameron McInally via cfe-commits
cameron.mcinally closed this revision. cameron.mcinally added a comment. This was fixed with r282082. My cfe-commits email is being held for moderation (not a member of the list), so there was no automatic update. Repository: rL LLVM https://reviews.llvm.org/D24785 __

[clang] [flang] [mlir] [flang] Add support for -mprefer-vector-width= (PR #141380)

2025-05-24 Thread Cameron McInally via cfe-commits
https://github.com/mcinally created https://github.com/llvm/llvm-project/pull/141380 This patch adds support for the -mprefer-vector-width= command line option. The parsing of this options is equivalent to Clang's and it is implemented by setting the "prefer-vector-width" function attribute.

[clang] [flang] [mlir] [flang] Add support for -mprefer-vector-width= (PR #141380)

2025-05-24 Thread Cameron McInally via cfe-commits
mcinally wrote: This is my first patch to Flang, so please be suspicious and gentle. In particular, I am not sure if `FlangOption, FC1Option` were the correct phases to pass this option to or not. https://github.com/llvm/llvm-project/pull/141380 ___

[clang] [flang] [mlir] [flang] Add support for -mprefer-vector-width= (PR #141380)

2025-05-24 Thread Cameron McInally via cfe-commits
https://github.com/mcinally updated https://github.com/llvm/llvm-project/pull/141380 >From 9f8619cb54a3a11e4c90af7f5156141ddc59e4d4 Mon Sep 17 00:00:00 2001 From: Cameron McInally Date: Sat, 24 May 2025 13:35:13 -0700 Subject: [PATCH] [flang] Add support for -mprefer-vector-width= This patch a

[clang] [flang] [mlir] [flang] Add support for -mprefer-vector-width= (PR #141380)

2025-05-27 Thread Cameron McInally via cfe-commits
https://github.com/mcinally updated https://github.com/llvm/llvm-project/pull/141380 >From 9f8619cb54a3a11e4c90af7f5156141ddc59e4d4 Mon Sep 17 00:00:00 2001 From: Cameron McInally Date: Sat, 24 May 2025 13:35:13 -0700 Subject: [PATCH 1/2] [flang] Add support for -mprefer-vector-width= This pat

[clang] [flang] [mlir] [flang] Add support for -mprefer-vector-width= (PR #141380)

2025-05-27 Thread Cameron McInally via cfe-commits
@@ -2636,6 +2636,10 @@ void ModuleImport::processFunctionAttributes(llvm::Function *func, funcOp.setTargetFeaturesAttr( LLVM::TargetFeaturesAttr::get(context, attr.getValueAsString())); + if (llvm::Attribute attr = func->getFnAttribute("prefer-vector-width"); +

[clang] [flang] [mlir] [flang] Add support for -mprefer-vector-width= (PR #142073)

2025-05-30 Thread Cameron McInally via cfe-commits
mcinally wrote: Thanks, @tarunprabhu! https://github.com/llvm/llvm-project/pull/142073 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [flang] [mlir] [flang] Add support for -mrecip[=] (PR #142172)

2025-05-30 Thread Cameron McInally via cfe-commits
https://github.com/mcinally created https://github.com/llvm/llvm-project/pull/142172 This patch adds support for the -mrecip command line option. The parsing of this options is equivalent to Clang's and it is implemented by setting the "reciprocal-estimates" function attribute. >From e7c60252

[clang] [flang] [mlir] [flang] Add support for -mprefer-vector-width= (PR #141380)

2025-05-28 Thread Cameron McInally via cfe-commits
https://github.com/mcinally updated https://github.com/llvm/llvm-project/pull/141380 >From 9f8619cb54a3a11e4c90af7f5156141ddc59e4d4 Mon Sep 17 00:00:00 2001 From: Cameron McInally Date: Sat, 24 May 2025 13:35:13 -0700 Subject: [PATCH 1/3] [flang] Add support for -mprefer-vector-width= This pat

[clang] [flang] [mlir] [flang] Add support for -mprefer-vector-width= (PR #141380)

2025-05-28 Thread Cameron McInally via cfe-commits
@@ -0,0 +1,9 @@ +; RUN: mlir-translate -import-llvm -split-input-file %s | FileCheck %s + +; CHECK-LABEL: llvm.func @prefer_vector_width() +; CHECK: prefer_vector_width = "128" mcinally wrote: It does continue where the last match ended, but no problem to update.

[clang] [flang] [mlir] [flang] Add support for -mprefer-vector-width= (PR #141380)

2025-05-28 Thread Cameron McInally via cfe-commits
https://github.com/mcinally updated https://github.com/llvm/llvm-project/pull/141380 >From 9f8619cb54a3a11e4c90af7f5156141ddc59e4d4 Mon Sep 17 00:00:00 2001 From: Cameron McInally Date: Sat, 24 May 2025 13:35:13 -0700 Subject: [PATCH 1/3] [flang] Add support for -mprefer-vector-width= This pat

[clang] [flang] [mlir] [flang] Add support for -mprefer-vector-width= (PR #141380)

2025-05-29 Thread Cameron McInally via cfe-commits
mcinally wrote: @tarunprabhu Would you mind mashing the "Merge" button? It looks like getting commit access approval is taking longer than expected. https://github.com/llvm/llvm-project/pull/141380 ___ cfe-commits mailing list cfe-commits@lists.llvm.o

[clang] [flang] [mlir] [flang] Add support for -mprefer-vector-width= (PR #141380)

2025-05-29 Thread Cameron McInally via cfe-commits
mcinally wrote: Seems ok now: "Changes can be cleanly merged." If it's still not available, I may have messed something up on my side. I'll review the GitHub docs to see if I missed something... https://github.com/llvm/llvm-project/pull/141380 ___ cf

[clang] [flang] [mlir] [flang] Add support for -mprefer-vector-width= (PR #141380)

2025-05-29 Thread Cameron McInally via cfe-commits
@@ -126,6 +127,8 @@ struct MLIRToLLVMPassPipelineConfig : public FlangEPCallBacks { bool NoSignedZerosFPMath = false; ///< Set no-signed-zeros-fp-math attribute for functions. bool UnsafeFPMath = false; ///< Set unsafe-fp-math attribute for functions. + std::string

[clang] [flang] [mlir] [flang] Add support for -mprefer-vector-width= (PR #141380)

2025-05-29 Thread Cameron McInally via cfe-commits
https://github.com/mcinally updated https://github.com/llvm/llvm-project/pull/141380 >From 9f8619cb54a3a11e4c90af7f5156141ddc59e4d4 Mon Sep 17 00:00:00 2001 From: Cameron McInally Date: Sat, 24 May 2025 13:35:13 -0700 Subject: [PATCH 1/3] [flang] Add support for -mprefer-vector-width= This pat

[clang] [flang] [mlir] [flang] Add support for -mprefer-vector-width= (PR #142073)

2025-05-31 Thread Cameron McInally via cfe-commits
mcinally wrote: PR #142269 for PPC buildbot fix. https://github.com/llvm/llvm-project/pull/142073 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [flang] [mlir] [flang] Add support for -mrecip[=] (PR #142172)

2025-05-31 Thread Cameron McInally via cfe-commits
mcinally wrote: > LGTM, though, I think we'd better reuse the code from `Clang.cpp`. > `flangFrontend` already depends on `clangDriver`, so we just need to export > `ParseMRecip` and `getRefinementStep` from `clangDriver` (and probably > replace their `Driver` argument with a `DiagnosticEngine

[clang] [flang] [Driver] Move CommonArgs to a location visible by the Frontend Drivers (PR #142800)

2025-06-04 Thread Cameron McInally via cfe-commits
https://github.com/mcinally created https://github.com/llvm/llvm-project/pull/142800 This patch moves the CommonArgs utilities into a location visible by the Frontend Drivers, so that the Frontend Drivers may share option parsing code with the Compiler Driver. This is useful when the Frontend

[clang] [flang] [Driver] Move CommonArgs to a location visible by the Frontend Drivers (PR #142800)

2025-06-04 Thread Cameron McInally via cfe-commits
@@ -270,6 +270,12 @@ void handleVectorizeLoopsArgs(const llvm::opt::ArgList &Args, /// Enable -fslp-vectorize based on the optimization level selected. void handleVectorizeSLPArgs(const llvm::opt::ArgList &Args, llvm::opt::ArgStringList &CmdArgs); +

[clang] [flang] [Driver] Move CommonArgs to a location visible by the Frontend Drivers (PR #142800)

2025-06-04 Thread Cameron McInally via cfe-commits
@@ -3167,3 +3167,30 @@ void tools::handleInterchangeLoopsArgs(const ArgList &Args, options::OPT_fno_loop_interchange, EnableInterchange)) CmdArgs.push_back("-floop-interchange"); } + +void tools::ParseMPreferVectorWidthOption(clang::DiagnosticsEngine &Di

[clang] [flang] [Driver] Move CommonArgs to a location visible by the Frontend Drivers (PR #142800)

2025-06-04 Thread Cameron McInally via cfe-commits
https://github.com/mcinally edited https://github.com/llvm/llvm-project/pull/142800 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [flang] [Driver] Move CommonArgs to a location visible by the Frontend Drivers (PR #142800)

2025-06-04 Thread Cameron McInally via cfe-commits
https://github.com/mcinally updated https://github.com/llvm/llvm-project/pull/142800 >From 918b853de8c43dacebecb42cafa6d3b8fec15b47 Mon Sep 17 00:00:00 2001 From: Cameron McInally Date: Tue, 3 Jun 2025 11:12:42 -0700 Subject: [PATCH] [Driver] Move CommonArgs to a location visible by the Fronte

[clang] [flang] [Driver] Move CommonArgs to a location visible by the Frontend Drivers (PR #142800)

2025-06-05 Thread Cameron McInally via cfe-commits
@@ -3167,3 +3167,30 @@ void tools::handleInterchangeLoopsArgs(const ArgList &Args, options::OPT_fno_loop_interchange, EnableInterchange)) CmdArgs.push_back("-floop-interchange"); } + +void tools::ParseMPreferVectorWidthOption(clang::DiagnosticsEngine &Di

[clang] [flang] [Driver] Move CommonArgs to a location visible by the Frontend Drivers (PR #142800)

2025-06-05 Thread Cameron McInally via cfe-commits
https://github.com/mcinally updated https://github.com/llvm/llvm-project/pull/142800 >From 918b853de8c43dacebecb42cafa6d3b8fec15b47 Mon Sep 17 00:00:00 2001 From: Cameron McInally Date: Tue, 3 Jun 2025 11:12:42 -0700 Subject: [PATCH 1/3] [Driver] Move CommonArgs to a location visible by the Fr

[clang] [flang] [Driver] Move CommonArgs to a location visible by the Frontend Drivers (PR #142800)

2025-06-05 Thread Cameron McInally via cfe-commits
https://github.com/mcinally updated https://github.com/llvm/llvm-project/pull/142800 >From 918b853de8c43dacebecb42cafa6d3b8fec15b47 Mon Sep 17 00:00:00 2001 From: Cameron McInally Date: Tue, 3 Jun 2025 11:12:42 -0700 Subject: [PATCH 1/4] [Driver] Move CommonArgs to a location visible by the Fr

[clang] [flang] [Driver] Move CommonArgs to a location visible by the Frontend Drivers (PR #142800)

2025-06-05 Thread Cameron McInally via cfe-commits
https://github.com/mcinally updated https://github.com/llvm/llvm-project/pull/142800 >From 918b853de8c43dacebecb42cafa6d3b8fec15b47 Mon Sep 17 00:00:00 2001 From: Cameron McInally Date: Tue, 3 Jun 2025 11:12:42 -0700 Subject: [PATCH 1/5] [Driver] Move CommonArgs to a location visible by the Fr

[clang] [flang] [llvm] [Driver] Move CommonArgs to a location visible by the Frontend Drivers (PR #142800)

2025-06-06 Thread Cameron McInally via cfe-commits
https://github.com/mcinally updated https://github.com/llvm/llvm-project/pull/142800 >From 918b853de8c43dacebecb42cafa6d3b8fec15b47 Mon Sep 17 00:00:00 2001 From: Cameron McInally Date: Tue, 3 Jun 2025 11:12:42 -0700 Subject: [PATCH 1/9] [Driver] Move CommonArgs to a location visible by the Fr

[clang] [flang] [llvm] [Driver] Move CommonArgs to a location visible by the Frontend Drivers (PR #142800)

2025-06-06 Thread Cameron McInally via cfe-commits
https://github.com/mcinally updated https://github.com/llvm/llvm-project/pull/142800 >From 918b853de8c43dacebecb42cafa6d3b8fec15b47 Mon Sep 17 00:00:00 2001 From: Cameron McInally Date: Tue, 3 Jun 2025 11:12:42 -0700 Subject: [PATCH 1/9] [Driver] Move CommonArgs to a location visible by the Fr

[clang] [flang] [llvm] [Driver] Move CommonArgs to a location visible by the Frontend Drivers (PR #142800)

2025-06-06 Thread Cameron McInally via cfe-commits
mcinally wrote: All checks have passed, if someone wouldn't mind merging for me. Thanks in advance! https://github.com/llvm/llvm-project/pull/142800 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinf

[clang] [flang] [Driver] Move CommonArgs to a location visible by the Frontend Drivers (PR #142800)

2025-06-06 Thread Cameron McInally via cfe-commits
@@ -3167,3 +3167,29 @@ void tools::handleInterchangeLoopsArgs(const ArgList &Args, options::OPT_fno_loop_interchange, EnableInterchange)) CmdArgs.push_back("-floop-interchange"); } + +std::optional tools::ParseMPreferVectorWidthOption( +clang::Diagno

[clang] [flang] [Driver] Move CommonArgs to a location visible by the Frontend Drivers (PR #142800)

2025-06-06 Thread Cameron McInally via cfe-commits
@@ -3167,3 +3167,29 @@ void tools::handleInterchangeLoopsArgs(const ArgList &Args, options::OPT_fno_loop_interchange, EnableInterchange)) CmdArgs.push_back("-floop-interchange"); } + +std::optional tools::ParseMPreferVectorWidthOption( +clang::Diagno

[clang] [flang] [Driver] Move CommonArgs to a location visible by the Frontend Drivers (PR #142800)

2025-06-06 Thread Cameron McInally via cfe-commits
mcinally wrote: > Thanks for the changes, Cameron. > > Could you take a look at the [failing > buildkite](https://github.com/llvm/llvm-project/actions/runs/15493623574/job/43624895590?pr=142800) > and see if it is something relevant? It seems to be a Windows build. Those > are a bit flaky and

[clang] [flang] [Driver] Move CommonArgs to a location visible by the Frontend Drivers (PR #142800)

2025-06-05 Thread Cameron McInally via cfe-commits
https://github.com/mcinally updated https://github.com/llvm/llvm-project/pull/142800 >From 918b853de8c43dacebecb42cafa6d3b8fec15b47 Mon Sep 17 00:00:00 2001 From: Cameron McInally Date: Tue, 3 Jun 2025 11:12:42 -0700 Subject: [PATCH 1/2] [Driver] Move CommonArgs to a location visible by the Fr

[clang] [flang] [Driver] Move CommonArgs to a location visible by the Frontend Drivers (PR #142800)

2025-06-06 Thread Cameron McInally via cfe-commits
https://github.com/mcinally updated https://github.com/llvm/llvm-project/pull/142800 >From 918b853de8c43dacebecb42cafa6d3b8fec15b47 Mon Sep 17 00:00:00 2001 From: Cameron McInally Date: Tue, 3 Jun 2025 11:12:42 -0700 Subject: [PATCH 1/7] [Driver] Move CommonArgs to a location visible by the Fr

[clang] [flang] [Driver] Move CommonArgs to a location visible by the Frontend Drivers (PR #142800)

2025-06-06 Thread Cameron McInally via cfe-commits
mcinally wrote: It looks like we have a number of approvals and I haven't seen any objections yet. Should we go ahead with merging this in the current state? If so, I'll need help there since I don't have commit access yet. @tarunprabhu would you mind volunteering to mash the merge button aga

[clang] [flang] [llvm] [Driver] Move CommonArgs to a location visible by the Frontend Drivers (PR #142800)

2025-06-06 Thread Cameron McInally via cfe-commits
https://github.com/mcinally updated https://github.com/llvm/llvm-project/pull/142800 >From 918b853de8c43dacebecb42cafa6d3b8fec15b47 Mon Sep 17 00:00:00 2001 From: Cameron McInally Date: Tue, 3 Jun 2025 11:12:42 -0700 Subject: [PATCH 1/8] [Driver] Move CommonArgs to a location visible by the Fr

[clang] [flang] [llvm] [Driver] Move CommonArgs to a location visible by the Frontend Drivers (PR #142800)

2025-06-06 Thread Cameron McInally via cfe-commits
mcinally wrote: It was easy enough to add. Seems like it would be useful in general too. https://github.com/llvm/llvm-project/pull/142800 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commit

[clang] [flang] [Driver] Move CommonArgs to a location visible by the Frontend Drivers (PR #142800)

2025-06-05 Thread Cameron McInally via cfe-commits
@@ -3167,3 +3167,30 @@ void tools::handleInterchangeLoopsArgs(const ArgList &Args, options::OPT_fno_loop_interchange, EnableInterchange)) CmdArgs.push_back("-floop-interchange"); } + +void tools::ParseMPreferVectorWidthOption(clang::DiagnosticsEngine &Di

[clang] [flang] [mlir] [flang] Add support for -mrecip[=] (PR #142172)

2025-06-05 Thread Cameron McInally via cfe-commits
mcinally wrote: This PR has been abandoned in hopes of using the more modular solution in #142800. https://github.com/llvm/llvm-project/pull/142172 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo

[clang] [flang] [mlir] [flang] Add support for -mrecip[=] (PR #142172)

2025-06-05 Thread Cameron McInally via cfe-commits
https://github.com/mcinally closed https://github.com/llvm/llvm-project/pull/142172 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [flang] [Driver] Move CommonArgs to a location visible by the Frontend Drivers (PR #142800)

2025-06-05 Thread Cameron McInally via cfe-commits
@@ -3167,3 +3167,30 @@ void tools::handleInterchangeLoopsArgs(const ArgList &Args, options::OPT_fno_loop_interchange, EnableInterchange)) CmdArgs.push_back("-floop-interchange"); } + +void tools::ParseMPreferVectorWidthOption(clang::DiagnosticsEngine &Di

[clang] [flang] [Driver] Move CommonArgs to a location visible by the Frontend Drivers (PR #142800)

2025-06-06 Thread Cameron McInally via cfe-commits
@@ -3167,3 +3167,29 @@ void tools::handleInterchangeLoopsArgs(const ArgList &Args, options::OPT_fno_loop_interchange, EnableInterchange)) CmdArgs.push_back("-floop-interchange"); } + +std::optional tools::ParseMPreferVectorWidthOption( +clang::Diagno

[clang] [flang] [Driver] Move CommonArgs to a location visible by the Frontend Drivers (PR #142800)

2025-06-06 Thread Cameron McInally via cfe-commits
https://github.com/mcinally updated https://github.com/llvm/llvm-project/pull/142800 >From 918b853de8c43dacebecb42cafa6d3b8fec15b47 Mon Sep 17 00:00:00 2001 From: Cameron McInally Date: Tue, 3 Jun 2025 11:12:42 -0700 Subject: [PATCH 1/6] [Driver] Move CommonArgs to a location visible by the Fr

[clang] [flang] [llvm] [Driver] Move CommonArgs to a location visible by the Frontend Drivers (PR #142800)

2025-06-06 Thread Cameron McInally via cfe-commits
mcinally wrote: > > I had 1 minor objection, see my concern on the `uninitialized` attribute > > removal. > > Would it be simpler just to initialize the variable before use? I assume that > the attribute is present to eliminate compiler warnings about uninitialized > variables being passed by

[clang] [flang] [mlir] [flang] Add support for -mrecip[=] (PR #143418)

2025-06-09 Thread Cameron McInally via cfe-commits
https://github.com/mcinally created https://github.com/llvm/llvm-project/pull/143418 This patch adds support for the -mrecip command line option. The parsing of this options is equivalent to Clang's and it is implemented by setting the "reciprocal-estimates" function attribute. Also move the

[clang] [flang] [mlir] [flang] Add support for -mrecip[=] (PR #143418)

2025-06-09 Thread Cameron McInally via cfe-commits
@@ -1549,6 +1549,9 @@ LogicalResult ModuleTranslation::convertOneFunction(LLVMFuncOp func) { if (auto tuneCpu = func.getTuneCpu()) llvmFunc->addFnAttr("tune-cpu", *tuneCpu); + if (auto reciprocalEstimates = func.getReciprocalEstimates()) mcinally wrote

[clang] [flang] [mlir] [flang] Add support for -mrecip[=] (PR #143418)

2025-06-09 Thread Cameron McInally via cfe-commits
@@ -2636,6 +2636,11 @@ void ModuleImport::processFunctionAttributes(llvm::Function *func, funcOp.setTargetFeaturesAttr( LLVM::TargetFeaturesAttr::get(context, attr.getValueAsString())); + if (llvm::Attribute attr = func->getFnAttribute("reciprocal-estimates"); +

[clang] [flang] [mlir] [flang] Add support for -mrecip[=] (PR #143418)

2025-06-09 Thread Cameron McInally via cfe-commits
@@ -0,0 +1,9 @@ +; RUN: mlir-translate -import-llvm -split-input-file %s | FileCheck %s + +; CHECK-LABEL: llvm.func @reciprocal_estimates() +; CHECK-SAME: reciprocal_estimates = "all" +define void @reciprocal_estimates() #0 { + ret void +} + +attributes #0 = { "reciprocal-estimat

[clang] [flang] [mlir] [flang] Add support for -mrecip[=] (PR #143418)

2025-06-09 Thread Cameron McInally via cfe-commits
https://github.com/mcinally updated https://github.com/llvm/llvm-project/pull/143418 >From f4812aacb17aaf535f454c82e4ef29c5c9950a12 Mon Sep 17 00:00:00 2001 From: Cameron McInally Date: Mon, 9 Jun 2025 11:19:36 -0700 Subject: [PATCH 1/2] [flang] Add support for -mrecip[=] This patch adds suppo