https://github.com/luporl approved this pull request.
https://github.com/llvm/llvm-project/pull/101701
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -933,10 +933,12 @@ def O : Joined<["-"], "O">, Group,
def O_flag : Flag<["-"], "O">, Visibility<[ClangOption, CC1Option, FC1Option]>,
Alias, AliasArgs<["1"]>;
def Ofast : Joined<["-"], "Ofast">, Group,
- Visibility<[ClangOption, CC1Option, FlangOption]>,
- HelpTextForVar
@@ -933,10 +933,12 @@ def O : Joined<["-"], "O">, Group,
def O_flag : Flag<["-"], "O">, Visibility<[ClangOption, CC1Option, FC1Option]>,
Alias, AliasArgs<["1"]>;
def Ofast : Joined<["-"], "Ofast">, Group,
- Visibility<[ClangOption, CC1Option, FlangOption]>,
- HelpTextForVar
@@ -855,6 +855,9 @@ void Flang::ConstructJob(Compilation &C, const JobAction
&JA,
// is experimental.
D.Diag(diag::warn_openmp_experimental);
+ if (Args.hasArg((options::OPT_fopenmp_default_none)))
luporl wrote:
```suggestion
if (Args.
https://github.com/luporl commented:
LG, except for the issue raised by @kiranchandramohan, to skip constructs that
don't support data-sharing clauses.
https://github.com/llvm/llvm-project/pull/120287
___
cfe-commits mailing list
cfe-commits@lists.llv
@@ -0,0 +1,34 @@
+! RUN: %python %S/../test_errors.py %s %flang -fopenmp -fopenmp-default-none
+
+
+! Test that -fopenmp-default-none shows the same errors as DEFAULT(NONE)
+subroutine default_none()
+ integer a(3)
+ integer, parameter :: D=10
+ A = 1
+ B = 2
+ !$omp parallel
https://github.com/luporl edited
https://github.com/llvm/llvm-project/pull/120287
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -339,11 +335,11 @@ just added using your new frontend option.
## CMake Support
As of [#7246](https://gitlab.kitware.com/cmake/cmake/-/merge_requests/7246)
-(and soon to be released CMake 3.24.0), `cmake` can detect `flang-new` as a
+(and soon to be released CMake 3.24.0), `
luporl wrote:
In my debug build, clang is receiving a SIGSEGV in frame 7 below (that is
actually frame 0, as the frames below it are from a gdb call that received a
signal). In it, `this` holds an invalid address.
In frame 8, `NE` is 0x3fff, which probably caused the invalid access.
In fram
luporl wrote:
I have been able to reproduce the issue on ARM hardware and collected the info
below.
This was with a release build. I'll check if I can get more details with a
debug build.
```
Program received signal SIGSEGV, Segmentation fault.
memset () at ../sysdeps/arm/memset.S:51
51 .
https://github.com/luporl approved this pull request.
https://github.com/llvm/llvm-project/pull/88932
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -3382,10 +3382,18 @@ def fopenmp : Flag<["-"], "fopenmp">, Group,
HelpText<"Parse OpenMP pragmas and generate parallel code.">;
def fno_openmp : Flag<["-"], "fno-openmp">, Group,
Flags<[NoArgumentUnused]>;
+class OpenMPVersionHelp {
+ string str = !strconcat(
+"Set
@@ -191,6 +191,60 @@ static MarshallingInfo createMarshallingInfo(const Record
&R) {
return Ret;
}
+static void EmitHelpTextsForVariants(
+raw_ostream &OS, std::vector,
StringRef>>
+ HelpTextsForVariants) {
+ // OptTable must be constexpr so it
@@ -191,6 +191,60 @@ static MarshallingInfo createMarshallingInfo(const Record
&R) {
return Ret;
}
+static void EmitHelpTextsForVariants(
+raw_ostream &OS, std::vector,
StringRef>>
+ HelpTextsForVariants) {
+ // OptTable must be constexpr so it
@@ -191,6 +191,60 @@ static MarshallingInfo createMarshallingInfo(const Record
&R) {
return Ret;
}
+static void EmitHelpTextsForVariants(
+raw_ostream &OS, std::vector,
StringRef>>
+ HelpTextsForVariants) {
+ // OptTable must be constexpr so it
@@ -191,6 +191,60 @@ static MarshallingInfo createMarshallingInfo(const Record
&R) {
return Ret;
}
+static void EmitHelpTextsForVariants(
+raw_ostream &OS, std::vector,
StringRef>>
+ HelpTextsForVariants) {
+ // OptTable must be constexpr so it
luporl wrote:
> I'm a bit short on spare cycles for reviewing stuff :( @luporl , do you have
> time to go over this? I'll bump this on my list regardless.
@banach-space, yes, I can go over this in more details.
https://github.com/llvm/llvm-project/pull/81869
___
https://github.com/luporl commented:
I think this can be useful, to make it possible to customize flang help
messages, even though only one flang option requires it at the moment.
https://github.com/llvm/llvm-project/pull/81869
___
cfe-commits mailing
@@ -3391,7 +3391,10 @@ def fno_openmp : Flag<["-"], "fno-openmp">,
Group,
def fopenmp_version_EQ : Joined<["-"], "fopenmp-version=">, Group,
Flags<[NoArgumentUnused]>,
Visibility<[ClangOption, CC1Option, FlangOption, FC1Option]>,
- HelpText<"Set OpenMP version (e.g. 45 fo
https://github.com/luporl edited https://github.com/llvm/llvm-project/pull/81869
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
luporl wrote:
https://github.com/llvm/llvm-project/issues/80728 opened to track this issue.
https://github.com/llvm/llvm-project/pull/77365
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-comm
luporl wrote:
It looks like `--sysroot=` is already supported by flang-new. It worked fine in
my tests. Just like clang, it doesn't show up in `--help` or `--help-hidden`,
for some reason I'm not aware.
I noticed, however, that using `--sysroot` doesn't work:
`flang-new: error: unknown argumen
luporl wrote:
> > Apart from that, the other difference that I'm aware is that on non-Darwin
> > targets -isysroot only sets the sysroot for the includes, while -sysroot
> > also affects the libraries.
>
> Sounds like in practice it wouldn’t make much difference whether it’s
> -isysroot or -s
luporl wrote:
> > As for the `isysroot.f90` test, I guess it would need to be removed, unless
> > there is some way to run it only when `DEFAULT_SYSROOT` is not set.
>
> You could also use `DEFAULT_SYSROOT` to define a LIT "feature" and check for
> that (via e.g. `REQUIRES`) in the test file.
luporl wrote:
> > If the compiler is built with `DEFAULT_SYSROOT`, the `-isysroot` option is
> > ignored. Is that the expected behavior? My local MacOS build (with
> > `-DDEFAULT_SYSROOT="$(xcrun --show-sdk-path)"`) has `isysroot.f90` failed.
>
> I expected `-isysroot` to override `DEFAULT_SYS
luporl wrote:
> If the compiler is built with `DEFAULT_SYSROOT`, the `-isysroot` option is
> ignored. Is that the expected behavior? My local MacOS build (with
> `-DDEFAULT_SYSROOT="$(xcrun --show-sdk-path)"`) has `isysroot.f90` failed.
I expected `-isysroot` to override `DEFAULT_SYSROOT`. I'l
luporl wrote:
> Could someone test this on AArch64 and/or Windows just to make sure that it
> passes there?
Works fine on AArch64.
https://github.com/llvm/llvm-project/pull/77360
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.
https://github.com/luporl closed https://github.com/llvm/llvm-project/pull/77605
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
luporl wrote:
Thanks for the reviews!
https://github.com/llvm/llvm-project/pull/77605
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/luporl closed https://github.com/llvm/llvm-project/pull/77365
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/luporl updated
https://github.com/llvm/llvm-project/pull/77605
>From 3e165d363b6211e4625056671d548037533ed819 Mon Sep 17 00:00:00 2001
From: Leandro Lupori
Date: Wed, 10 Jan 2024 10:24:52 -0300
Subject: [PATCH 1/2] [flang] Fix fveclib on Darwin
Fixes fveclib.f90 and fveclib-
https://github.com/luporl created
https://github.com/llvm/llvm-project/pull/77605
Fixes fveclib.f90 and fveclib-codegen.f90 tests, that were failing
on Darwin.
>From 3e165d363b6211e4625056671d548037533ed819 Mon Sep 17 00:00:00 2001
From: Leandro Lupori
Date: Wed, 10 Jan 2024 10:24:52 -0300
Su
luporl wrote:
I guess I was so focused on testing executables on Darwin that I forgot this
test also applies to other targets.
Let's hope it doesn't introduce a failure on any target.
https://github.com/llvm/llvm-project/pull/77365
luporl wrote:
Thanks for the review and all the suggestions!
https://github.com/llvm/llvm-project/pull/77365
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/luporl updated
https://github.com/llvm/llvm-project/pull/77365
>From 01a2a8d315af2edb9fe3f0c9b57b5c74935521f1 Mon Sep 17 00:00:00 2001
From: Leandro Lupori
Date: Mon, 8 Jan 2024 16:37:54 -0300
Subject: [PATCH 1/7] [flang][driver] Add support for -isysroot in the frontend
If
https://github.com/luporl updated
https://github.com/llvm/llvm-project/pull/77365
>From 01a2a8d315af2edb9fe3f0c9b57b5c74935521f1 Mon Sep 17 00:00:00 2001
From: Leandro Lupori
Date: Mon, 8 Jan 2024 16:37:54 -0300
Subject: [PATCH 1/6] [flang][driver] Add support for -isysroot in the frontend
If
@@ -0,0 +1,12 @@
+! Verify that the -isysroot flag is known to the frontend and, on Darwin,
+! is passed on to the linker.
+
+! RUN: %flang -### --target=aarch64-apple-darwin -isysroot /path/to/sysroot \
+! RUN:%s 2>&1 | FileCheck %s --check-prefix=CHECK-DARWIN
+! RUN: %fl
https://github.com/luporl updated
https://github.com/llvm/llvm-project/pull/77365
>From 01a2a8d315af2edb9fe3f0c9b57b5c74935521f1 Mon Sep 17 00:00:00 2001
From: Leandro Lupori
Date: Mon, 8 Jan 2024 16:37:54 -0300
Subject: [PATCH 1/5] [flang][driver] Add support for -isysroot in the frontend
If
@@ -220,6 +220,13 @@ static or shared library, the generated library does not
need a `main`
function, as a final link stage will occur that will provide the `Fortran_main`
library when creating the final executable.
+On Darwin, the logical root where the system libraries are
https://github.com/luporl updated
https://github.com/llvm/llvm-project/pull/77365
>From 01a2a8d315af2edb9fe3f0c9b57b5c74935521f1 Mon Sep 17 00:00:00 2001
From: Leandro Lupori
Date: Mon, 8 Jan 2024 16:37:54 -0300
Subject: [PATCH 1/4] [flang][driver] Add support for -isysroot in the frontend
If
@@ -0,0 +1,12 @@
+! Verify that the -isysroot flag is known to the frontend and, on Darwin,
+! is passed on to the linker.
+
+! RUN: %flang -### --target=aarch64-apple-darwin -isysroot /path/to/sysroot \
+! RUN:%s 2>&1 | FileCheck %s --check-prefix=CHECK-DARWIN
+! RUN: %fl
https://github.com/luporl updated
https://github.com/llvm/llvm-project/pull/77365
>From 01a2a8d315af2edb9fe3f0c9b57b5c74935521f1 Mon Sep 17 00:00:00 2001
From: Leandro Lupori
Date: Mon, 8 Jan 2024 16:37:54 -0300
Subject: [PATCH 1/3] [flang][driver] Add support for -isysroot in the frontend
If
https://github.com/luporl created
https://github.com/llvm/llvm-project/pull/77365
If DEFAULT_SYSROOT is not specfied when building flang, then the
-isysroot flag is needed to link binaries against system libraries
on Darwin. It's also needed when linking against a non-default
sysroot.
>From 01
luporl wrote:
Ok, thanks, I'll try with `-DDEFAULT_SYSROOT="$(xcrun --show-sdk-path)"`.
But it's good to know that using `-isysroot` with flang is the right solution.
I'll try to come up with a patch to make flang support it, when I have some
spare time.
https://github.com/llvm/llvm-project/p
luporl wrote:
> I build and `check-flang` on `arm64-apple-darwin22.6.0`.
> `Driver/no-duplicate-main.f90` fails in the 3rd RUN. The test passes with
> HEAD.
>
> ```
> kelvin@neutrino2 build % /Users/kelvin/wrk/llvm/tmp/build/bin/flang-new -o
> /Users/kelvin/wrk/llvm/tmp/build/tools/flang/test
luporl wrote:
Some sources
(https://stackoverflow.com/questions/16082470/osx-how-do-i-convert-a-static-library-to-a-dynamic-one)
suggest the use of `-force_load`:
```
-force_load path_to_archive
Loads all members of the specified static archive library. Note:
-all_load forc
luporl wrote:
I've run `flang/test/Driver/no-duplicate-main.f90` manually on Darwin and
noticed that the third RUN line fails, because no error happens:
`! RUN: not %flang -o %t.exe %t %t.c-object 2>&1`
So maybe `-whole-archive` is just not needed on it?
https://github.com/llvm/llvm-project/p
https://github.com/luporl approved this pull request.
LGTM. Worked fine on my machine.
NOTE: tested by replacing `CommonArgs.cpp` in main, to avoid conflicts.
https://github.com/llvm/llvm-project/pull/75393
___
cfe-commits mailing list
cfe-commits@lis
luporl wrote:
Since this patch I can't build binaries with flang-new on macOS anymore:
```
$ /Users/leandro.lupori/git/flang-luporl/buildr/bin/flang-new -v -fopenmp -o
stest.exe stest.o
-L/Library/Developer/CommandLineTools/SDKs/MacOSX14.0.sdk/usr/lib
flang-new version 18.0.0git (g...@github.co
@@ -50,3 +50,12 @@
! MSVC-SAME: FortranDecimal.lib
! MSVC-SAME: /subsystem:console
! MSVC-SAME: "[[object_file]]"
+
+! Verify that certain linker flags are known to the frontend and are passed on
+! to the linker.
+
+! RUN: %flang -### -rpath /path/to/dir -shared -static %s 2>&
luporl wrote:
Adding `--target=x86_64-linux-gnu`, as @MaskRay suggests, fixes the test on
Windows. But then we are not actually testing linking on Windows.
On my Windows machine, the test output is practically the same as that reported
by buildkite, as mentioned by @tarunprabhu above. I see no
luporl wrote:
I'll try to test this patch on a Windows on ARM machine.
But it may take some time to setup and build flang on it.
https://github.com/llvm/llvm-project/pull/66702
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.
52 matches
Mail list logo