Skip to content

Commit 4291a6d

Browse files
committed
Update toolchains
- Update LLVM to 14.0.4.
1 parent 7d35724 commit 4291a6d

File tree

8 files changed

+55
-58
lines changed

8 files changed

+55
-58
lines changed

build/overrides.mk

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -555,8 +555,8 @@ define librsvg_BUILD
555555
(cd '$(SOURCE_DIR)' && $(PATCH) -p1 -u) < $(realpath $(dir $(lastword $(librsvg_PATCHES))))/librsvg-llvm-mingw.patch \
556556
# Update expected Cargo SHA256 hashes for the vendored files we have patched
557557
$(SED) -i 's/3c7fe77a67a34e6641b798f3a67dd6904396011a428f6af82cbec993eb924f0c/a52dbb88925434e6769aa0a10eec5b0648ea8f8092a9607e0c734b725a55e0ec/' '$(SOURCE_DIR)/vendor/cfg-expr/.cargo-checksum.json'; \
558-
$(SED) -i 's/67578522c146e1e44d44023c7b1b2b9fc65dc239d7c92ba61b2ec839e360ee80/af12eea5309f061da5623c41e711b135bacc9f8fd0507ccb63f5ff2088b62484/' '$(SOURCE_DIR)/vendor/compiler_builtins/.cargo-checksum.json'; \
559-
$(SED) -i 's/ed8e92a9655ef164c62a7c033906c41601ca458b477ae32ad37f89228683c295/bfa574dfa19737edeeef6de682207009a9020e3a980d1bb3b554f46f49792c0d/' '$(SOURCE_DIR)/vendor/compiler_builtins/.cargo-checksum.json'; \
558+
$(SED) -i 's/991919d9ab1eca85e87a85acafcb86d4880f1afe9fe35d6bd87039dcb1fa9aa7/38fb6d61251112ff4ff22ebcdad41f4193cd2e0b2788065e5634e9a9027260e2/' '$(SOURCE_DIR)/vendor/compiler_builtins/.cargo-checksum.json'; \
559+
$(SED) -i 's/55138604371e00ef14167894159156b68f939039b0e5b2b1f3db61456e3d3870/ff7df885cb6b31736b49f8d0a4755e8a2d947145316c3e5b212c78ab08142108/' '$(SOURCE_DIR)/vendor/compiler_builtins/.cargo-checksum.json'; \
560560
$(SED) -i 's/966128476fdf0d3148da21508a27a159ad2d272391e4a3ffbf18008300cca80c/ead5a3b748c9a5fcb145fa2e5cfc8df32f383369b8842fba4272ca3b568109ea/' '$(SOURCE_DIR)/vendor/windows-sys/.cargo-checksum.json';)
561561

562562
# Allow libtool to statically link against libintl

build/patches/librsvg-llvm-mingw.patch

Lines changed: 42 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ diff --git a/vendor/compiler_builtins/build.rs b/vendor/compiler_builtins/build.
9494
index 1111111..2222222 100644
9595
--- a/vendor/compiler_builtins/build.rs
9696
+++ b/vendor/compiler_builtins/build.rs
97-
@@ -324,7 +324,7 @@ mod c {
97+
@@ -313,7 +313,7 @@ mod c {
9898
if target_arch == "arm"
9999
&& target_os != "ios"
100100
&& target_os != "watchos"
@@ -151,76 +151,73 @@ diff --git a/vendor/compiler_builtins/src/float/conv.rs b/vendor/compiler_builti
151151
index 1111111..2222222 100644
152152
--- a/vendor/compiler_builtins/src/float/conv.rs
153153
+++ b/vendor/compiler_builtins/src/float/conv.rs
154-
@@ -86,7 +86,7 @@ intrinsics! {
154+
@@ -82,12 +82,12 @@ intrinsics! {
155+
f64::from_bits(int_to_float::u32_to_f64_bits(i))
155156
}
156157

157-
#[maybe_use_optimized_c_shim]
158-
- #[arm_aeabi_alias = __aeabi_l2f]
159-
+ #[arm_aeabi_alias = __i64tos]
160-
pub extern "C" fn __floatdisf(i: i64) -> f32 {
161-
// On x86_64 LLVM will use native instructions for this conversion, we
162-
// can just do it directly
163-
@@ -98,7 +98,7 @@ intrinsics! {
164-
}
165-
166-
#[maybe_use_optimized_c_shim]
167-
- #[arm_aeabi_alias = __aeabi_l2d]
168-
+ #[arm_aeabi_alias = __i64tod]
169-
pub extern "C" fn __floatdidf(i: i64) -> f64 {
170-
// On x86_64 LLVM will use native instructions for this conversion, we
171-
// can just do it directly
172-
@@ -120,13 +120,13 @@ intrinsics! {
173-
}
174-
175-
#[maybe_use_optimized_c_shim]
176158
- #[arm_aeabi_alias = __aeabi_ul2f]
177159
+ #[arm_aeabi_alias = __u64tos]
178160
pub extern "C" fn __floatundisf(i: u64) -> f32 {
179-
int_to_float(i)
161+
f32::from_bits(int_to_float::u64_to_f32_bits(i))
180162
}
181163

182-
#[maybe_use_optimized_c_shim]
183164
- #[arm_aeabi_alias = __aeabi_ul2d]
184165
+ #[arm_aeabi_alias = __u64tod]
185166
pub extern "C" fn __floatundidf(i: u64) -> f64 {
186-
int_to_float(i)
167+
f64::from_bits(int_to_float::u64_to_f64_bits(i))
187168
}
188-
@@ -199,7 +199,7 @@ intrinsics! {
189-
float_to_int(f)
169+
@@ -117,13 +117,13 @@ intrinsics! {
170+
f64::from_bits(int_to_float::u32_to_f64_bits(i.unsigned_abs()) | sign_bit)
190171
}
191172

192-
- #[arm_aeabi_alias = __aeabi_f2lz]
193-
+ #[arm_aeabi_alias = __stoi64]
194-
pub extern "C" fn __fixsfdi(f: f32) -> i64 {
195-
float_to_int(f)
196-
}
197-
@@ -209,7 +209,7 @@ intrinsics! {
198-
float_to_int(f)
173+
- #[arm_aeabi_alias = __aeabi_l2f]
174+
+ #[arm_aeabi_alias = __i64tos]
175+
pub extern "C" fn __floatdisf(i: i64) -> f32 {
176+
let sign_bit = ((i >> 63) as u32) << 31;
177+
f32::from_bits(int_to_float::u64_to_f32_bits(i.unsigned_abs()) | sign_bit)
199178
}
200179

201-
- #[arm_aeabi_alias = __aeabi_d2lz]
202-
+ #[arm_aeabi_alias = __dtoi64]
203-
pub extern "C" fn __fixdfdi(f: f64) -> i64 {
204-
float_to_int(f)
205-
}
206-
@@ -219,7 +219,7 @@ intrinsics! {
207-
float_to_int(f)
180+
- #[arm_aeabi_alias = __aeabi_l2d]
181+
+ #[arm_aeabi_alias = __i64tod]
182+
pub extern "C" fn __floatdidf(i: i64) -> f64 {
183+
let sign_bit = ((i >> 63) as u64) << 63;
184+
f64::from_bits(int_to_float::u64_to_f64_bits(i.unsigned_abs()) | sign_bit)
185+
@@ -160,7 +160,7 @@ intrinsics! {
186+
}
208187
}
209188

210189
- #[arm_aeabi_alias = __aeabi_f2ulz]
211190
+ #[arm_aeabi_alias = __stou64]
212191
pub extern "C" fn __fixunssfdi(f: f32) -> u64 {
213-
float_to_int(f)
214-
}
215-
@@ -229,7 +229,7 @@ intrinsics! {
216-
float_to_int(f)
192+
let fbits = f.to_bits();
193+
if fbits < 127 << 23 { // >= 0, < 1
194+
@@ -209,7 +209,7 @@ intrinsics! {
195+
}
217196
}
218197

219198
- #[arm_aeabi_alias = __aeabi_d2ulz]
220199
+ #[arm_aeabi_alias = __dtou64]
221200
pub extern "C" fn __fixunsdfdi(f: f64) -> u64 {
222-
float_to_int(f)
201+
let fbits = f.to_bits();
202+
if fbits < 1023 << 52 { // >= 0, < 1
203+
@@ -262,7 +262,7 @@ intrinsics! {
204+
}
223205
}
206+
207+
- #[arm_aeabi_alias = __aeabi_f2lz]
208+
+ #[arm_aeabi_alias = __stoi64]
209+
pub extern "C" fn __fixsfdi(f: f32) -> i64 {
210+
let fbits = f.to_bits() & !0 >> 1; // Remove sign bit.
211+
if fbits < 127 << 23 { // >= 0, < 1
212+
@@ -314,7 +314,7 @@ intrinsics! {
213+
}
214+
}
215+
216+
- #[arm_aeabi_alias = __aeabi_d2lz]
217+
+ #[arm_aeabi_alias = __dtoi64]
218+
pub extern "C" fn __fixdfdi(f: f64) -> i64 {
219+
let fbits = f.to_bits() & !0 >> 1; // Remove sign bit.
220+
if fbits < 1023 << 52 { // >= 0, < 1
224221

225222
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
226223
From: Kleis Auke Wolthuizen <github@kleisauke.nl>

build/plugins/llvm-mingw/compiler-rt-sanitizers.mk

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
PKG := compiler-rt-sanitizers
44
$(PKG)_WEBSITE := https://compiler-rt.llvm.org/
5-
$(PKG)_VERSION := 14.0.3
5+
$(PKG)_VERSION := 14.0.4
66
$(PKG)_DEPS := cc
77
$(PKG)_TYPE := meta
88

build/plugins/llvm-mingw/llvm-mingw.mk

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ define $(PKG)_PRE_BUILD
5959
# Can't symlink here, it will break the basename detection of LLVM. See:
6060
# sys::path::stem("x86_64-w64-mingw32.shared-ranlib"); -> x86_64-w64-mingw32
6161
# TODO(kleisauke): Remove this if we omit any dots from our target, see:
62-
# https://github.com/llvm/llvm-project/blob/llvmorg-14.0.3/llvm/tools/llvm-ar/llvm-ar.cpp#L1285-L1304
62+
# https://github.com/llvm/llvm-project/blob/llvmorg-14.0.4/llvm/tools/llvm-ar/llvm-ar.cpp#L1285-L1304
6363
$(foreach EXEC, addr2line ar cvtres nm objcopy ranlib rc strings strip, \
6464
(echo '#!/bin/sh'; \
6565
echo 'exec "$(PREFIX)/$(BUILD)/bin/llvm-$(EXEC)" "$$@"') \
@@ -68,7 +68,7 @@ define $(PKG)_PRE_BUILD
6868

6969
# We need to pass some additional arguments for windres
7070
# TODO(kleisauke): Remove this if we omit any dots from our target, see:
71-
# https://github.com/llvm/llvm-project/blob/llvmorg-14.0.3/llvm/tools/llvm-rc/llvm-rc.cpp#L266-L277
71+
# https://github.com/llvm/llvm-project/blob/llvmorg-14.0.4/llvm/tools/llvm-rc/llvm-rc.cpp#L266-L277
7272
(echo '#!/bin/sh'; \
7373
echo 'exec "$(PREFIX)/$(BUILD)/bin/llvm-windres" \
7474
--preprocessor-arg="--sysroot=$(PREFIX)/$(TARGET)" \
@@ -82,7 +82,7 @@ define $(PKG)_PRE_BUILD
8282
# armv7 -> arm
8383
# aarch64 -> arm64
8484
# TODO(kleisauke): Remove this if we omit any dots from our target, see:
85-
# https://github.com/llvm/llvm-project/blob/llvmorg-14.0.3/llvm/lib/ToolDrivers/llvm-dlltool/DlltoolDriver.cpp#L97-L108
85+
# https://github.com/llvm/llvm-project/blob/llvmorg-14.0.4/llvm/lib/ToolDrivers/llvm-dlltool/DlltoolDriver.cpp#L97-L108
8686
$(eval DLLTOOL_ARCH := $(strip \
8787
$(if $(findstring i686,$(PROCESSOR)),i386, \
8888
$(if $(findstring x86_64,$(PROCESSOR)),i386:x86-64, \

build/plugins/llvm-mingw/llvm.mk

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@ $(PKG)_WEBSITE := https://llvm.org/
55
$(PKG)_DESCR := A collection of modular and reusable compiler and toolchain technologies
66
$(PKG)_IGNORE :=
77
# This version needs to be in-sync with the compiler-rt-sanitizers package
8-
$(PKG)_VERSION := 14.0.3
9-
$(PKG)_CHECKSUM := 44d3e7a784d5cf805e72853bb03f218bd1058d448c03ca883dabbebc99204e0c
8+
$(PKG)_VERSION := 14.0.4
9+
$(PKG)_CHECKSUM := f40c77ceff02ae3873d273a51b0f93cd8e6409576f771d860d75835335522052
1010
$(PKG)_PATCHES := $(realpath $(sort $(wildcard $(dir $(lastword $(MAKEFILE_LIST)))/patches/llvm-[0-9]*.patch)))
1111
$(PKG)_GH_CONF := llvm/llvm-project/releases/latest,llvmorg-,,,,.tar.xz
1212
$(PKG)_SUBDIR := $(PKG)-project-$(subst -,,$($(PKG)_VERSION)).src

build/plugins/llvm-mingw/overrides.mk

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ IS_LLVM := $(true)
44

55
# [major].[minor].[patch]-[label] -> [major].[minor].[patch]
66
#clang_VERSION := $(firstword $(subst -, ,$(llvm_VERSION)))
7-
clang_VERSION := 14.0.3
7+
clang_VERSION := 14.0.4
88

99
# Override sub-dependencies
1010
cc_DEPS := llvm

build/plugins/llvm-mingw/patches/rust-1-fixes.patch

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ diff --git a/compiler/rustc_target/src/spec/mod.rs b/compiler/rustc_target/src/s
6363
index 1111111..2222222 100644
6464
--- a/compiler/rustc_target/src/spec/mod.rs
6565
+++ b/compiler/rustc_target/src/spec/mod.rs
66-
@@ -944,7 +944,9 @@ supported_targets! {
66+
@@ -945,7 +945,9 @@ supported_targets! {
6767
("x86_64-uwp-windows-gnu", x86_64_uwp_windows_gnu),
6868

6969
("aarch64-pc-windows-gnullvm", aarch64_pc_windows_gnullvm),

build/plugins/llvm-mingw/rust.mk

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,13 @@ PKG := rust
22
$(PKG)_WEBSITE := https://www.rust-lang.org/
33
$(PKG)_DESCR := A systems programming language focused on safety, speed and concurrency.
44
$(PKG)_IGNORE :=
5-
# https://static.rust-lang.org/dist/2022-05-28/rustc-nightly-src.tar.xz.sha256
5+
# https://static.rust-lang.org/dist/2022-06-05/rustc-nightly-src.tar.xz.sha256
66
$(PKG)_VERSION := nightly
7-
$(PKG)_CHECKSUM := 29f48bd81858f921b7e6099395857bfe14cdd41447fce79b10b59eec0f75fe51
7+
$(PKG)_CHECKSUM := 35295830e5072f343393d977a021f67e7050bad05fa2d58a56b43c8b4208731a
88
$(PKG)_PATCHES := $(realpath $(sort $(wildcard $(dir $(lastword $(MAKEFILE_LIST)))/patches/$(PKG)-[0-9]*.patch)))
99
$(PKG)_SUBDIR := $(PKG)c-$($(PKG)_VERSION)-src
1010
$(PKG)_FILE := $(PKG)c-$($(PKG)_VERSION)-src.tar.xz
11-
$(PKG)_URL := https://static.rust-lang.org/dist/2022-05-28/$($(PKG)_FILE)
11+
$(PKG)_URL := https://static.rust-lang.org/dist/2022-06-05/$($(PKG)_FILE)
1212
$(PKG)_DEPS := $(BUILD)~$(PKG)
1313
$(PKG)_TARGETS := $(BUILD) $(MXE_TARGETS)
1414

0 commit comments

Comments
 (0)