-
-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
4d03da8
commit e1f7fe2
Showing
9 changed files
with
258 additions
and
205 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 2 additions & 2 deletions
4
recipe/patches/0001-Instructions-for-building-a-functional-Flang-cross-c.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
28 changes: 28 additions & 0 deletions
28
recipe/patches/0004-Fix-implicit-conversion-warning-when-targeting-32bit.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
From 4c2b2fac044fb1b0ad1c3fda3dc5547eda9a22f9 Mon Sep 17 00:00:00 2001 | ||
From: serge-sans-paille <sguelton@mozilla.com> | ||
Date: Fri, 9 Aug 2024 07:51:07 +0200 | ||
Subject: [PATCH 4/7] Fix implicit conversion warning when targeting 32bit | ||
|
||
See https://github.com/llvm/llvm-project/pull/99465 | ||
--- | ||
flang/runtime/derived.cpp | 7 +++---- | ||
1 file changed, 3 insertions(+), 4 deletions(-) | ||
|
||
diff --git a/flang/runtime/derived.cpp b/flang/runtime/derived.cpp | ||
index 0d9e033df4e2..659f54fa344b 100644 | ||
--- a/flang/runtime/derived.cpp | ||
+++ b/flang/runtime/derived.cpp | ||
@@ -23,10 +23,9 @@ static RT_API_ATTRS void GetComponentExtents(SubscriptValue (&extents)[maxRank], | ||
const typeInfo::Component &comp, const Descriptor &derivedInstance) { | ||
const typeInfo::Value *bounds{comp.bounds()}; | ||
for (int dim{0}; dim < comp.rank(); ++dim) { | ||
- SubscriptValue lb{bounds[2 * dim].GetValue(&derivedInstance).value_or(0)}; | ||
- SubscriptValue ub{ | ||
- bounds[2 * dim + 1].GetValue(&derivedInstance).value_or(0)}; | ||
- extents[dim] = ub >= lb ? ub - lb + 1 : 0; | ||
+ auto lb{bounds[2 * dim].GetValue(&derivedInstance).value_or(0)}; | ||
+ auto ub{bounds[2 * dim + 1].GetValue(&derivedInstance).value_or(0)}; | ||
+ extents[dim] = ub >= lb ? static_cast<SubscriptValue>(ub - lb + 1) : 0; | ||
} | ||
} | ||
|
193 changes: 0 additions & 193 deletions
193
recipe/patches/0004-Patches-to-build-flang-runtime-with-emcc.patch
This file was deleted.
Oops, something went wrong.
33 changes: 33 additions & 0 deletions
33
recipe/patches/0005-Explicitly-convert-shift-value-to-SubscriptValue.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
From 2b7c94446934e5c473f4577fd78c9a16cb225e31 Mon Sep 17 00:00:00 2001 | ||
From: serge-sans-paille <sguelton@mozilla.com> | ||
Date: Fri, 9 Aug 2024 07:57:36 +0200 | ||
Subject: [PATCH 5/7] Explicitly convert shift value to SubscriptValue | ||
|
||
See https://github.com/llvm/llvm-project/pull/99822 | ||
--- | ||
flang/runtime/transformational.cpp | 5 +++-- | ||
1 file changed, 3 insertions(+), 2 deletions(-) | ||
|
||
diff --git a/flang/runtime/transformational.cpp b/flang/runtime/transformational.cpp | ||
index cf1e61c0844d..b6b204be4418 100644 | ||
--- a/flang/runtime/transformational.cpp | ||
+++ b/flang/runtime/transformational.cpp | ||
@@ -508,7 +508,8 @@ void RTDEF(CshiftVector)(Descriptor &result, const Descriptor &source, | ||
SubscriptValue lb{sourceDim.LowerBound()}; | ||
for (SubscriptValue j{0}; j < extent; ++j) { | ||
SubscriptValue resultAt{1 + j}; | ||
- SubscriptValue sourceAt{lb + (j + shift) % extent}; | ||
+ SubscriptValue sourceAt{ | ||
+ lb + static_cast<SubscriptValue>(j + shift) % extent}; | ||
if (sourceAt < lb) { | ||
sourceAt += extent; | ||
} | ||
@@ -619,7 +620,7 @@ void RTDEF(EoshiftVector)(Descriptor &result, const Descriptor &source, | ||
} | ||
SubscriptValue lb{source.GetDimension(0).LowerBound()}; | ||
for (SubscriptValue j{1}; j <= extent; ++j) { | ||
- SubscriptValue sourceAt{lb + j - 1 + shift}; | ||
+ SubscriptValue sourceAt{lb + j - 1 + static_cast<SubscriptValue>(shift)}; | ||
if (sourceAt >= lb && sourceAt < lb + extent) { | ||
CopyElement(result, &j, source, &sourceAt, terminator); | ||
} else if (boundary) { |
Oops, something went wrong.