Commit Graph

1040 Commits

Author SHA1 Message Date
Amanieu d'Antras
f16e62159b Release 0.1.112 2024-05-11 10:05:33 +02:00
Trevor Gross
f52b4a268f Remove the undocumented and unused rustbuild feature
See
<https://github.com/rust-lang/compiler-builtins/pull/603#discussion_r1590747361>
2024-05-11 09:56:55 +02:00
Trevor Gross
54d96150b5 Update cfg to fix warnings 2024-05-11 09:56:55 +02:00
Trevor Gross
286944e479 Emit directives for cargo-check-cfg 2024-05-11 09:56:55 +02:00
Trevor Gross
ccfe0e3808 Deny warnings in CI
There are currently a lot of warnings printed in CI, mostly dead code.
Update CI to deny warnings.
2024-05-11 09:56:55 +02:00
Nicholas Bishop
e4e03883ed Enable chkstk/alloca intrinsics on i686-unknown-uefi 2024-05-08 21:47:12 -04:00
Amanieu d'Antras
2faef31e96 Release version 0.1.111 2024-05-04 19:57:27 +01:00
Patryk Wychowaniec
461682bd91 fix: Add #[avr_skip] for __addsf3 & __adddf3
It looks like I've forgotten about them [back in 2023](https://github.com/rust-lang/compiler-builtins/pull/527).
2024-05-04 19:50:22 +02:00
Amanieu d'Antras
060391b020 Release version 0.1.110 2024-05-04 15:31:14 +01:00
Martin Nordholts
8c0c504d4f Update reference to rustc-std-workspace-core 2024-05-04 14:56:01 +02:00
Amjad Alsharafi
ce8a0c346d Cleanup manged-names macro
Don't generate the whole function if we are not going to use `no_mangle`, there is no point
2024-05-03 13:27:03 +02:00
Amjad Alsharafi
e232a79146 Remove unneeded weak for optimized-c function
`weak` is only used with `no_mangle`
2024-05-03 13:27:03 +02:00
Amjad Alsharafi
2e096145c3 Apply weak attributes to all intrinsics
Removed the `weak-intrinsics` feature, so that all functions
will have the `weak` linkage attribute.

Also this fixed the bug in
https://github.com/rust-lang/rust/issues/124042.

Before this commit, generated code will be
```rust
pub extern "C" fn <name>(...) -> ... {
        // code...
}
pub mod <name> {
    #[linkage = "weak"]
    #[no_mangle]
    pub extern "C" fn <name>(...) -> ... {
        super::<name>(...)
    }
}
```

The issue is that there is 2 `weak` linkage, the first one is not required.
Along refactoring `weak` attributes, this was fixed.
2024-05-03 13:27:03 +02:00
beetrees
229babb1d0 Add builtins for f16/f128 float conversions 2024-05-02 13:49:24 +02:00
Amjad Alsharafi
656106f050 Updated libm to fix clippy warning 2024-04-30 23:28:43 +02:00
Amjad Alsharafi
f761f03822 Fix clippy warnings in math
The solution is not pretty, but not sure why we still get clippy
warning from one of the files in `libm` even though we use
`allow(clippy::all)`
2024-04-30 23:28:43 +02:00
Amjad Alsharafi
2ce9bc0cc1 Fix math libraries not being linked on some platforms
This is a continuation/fix of 018616e. In that commit, we made it add
the math functions to all platforms (except apple-targets and windows),
and use `weak` linking, so that it can be used if the system doesn't
have those functions.

Didn't notice `mod math` was behind another set of `cfg`, so removed it
as well here.
2024-04-30 23:28:43 +02:00
beetrees
a2587f7b02
Update status of 128-bit integers in README.md 2024-04-28 17:41:35 +01:00
Trevor Gross
1b679e5cee Apply some more fixes suggested by Shellcheck 2024-04-19 11:49:23 -04:00
Trevor Gross
a55604fd8c Add a way to run tests on non-linux machines
Allow using the `rust-lang/rust:nightly` docker image to run tests in
cases where the host rust and cargo cannot be used, such as non-linux
hosts.
2024-04-19 11:49:23 -04:00
Trevor Gross
d5bc2de9ec Add CI testing for AArch64 Darwin
The Apple ARM silicon has been around for a while now and hopefully will
become Rust Tier 1 at some point. Add it to CI since it is distinct
enough from aarch64-linux and x86_86-darwin that there may be
differences.
2024-04-16 14:04:47 -04:00
Trevor Gross
47f2241db9 Change aarch64_linux module and lse tests to have the same gating
Trying to run testcrate on non-linux aarch64 currently hits a
compilation error. Make this test linux-only, to be consistent with the
`aarch64_linux` module that it depends on.

Additionally, enable the `aarch64_linux` module for `target_arch =
"arm64ec"` to be the same as these tests.
2024-04-16 14:04:47 -04:00
Amanieu d'Antras
bd48df66bd Release 0.1.109 2024-04-10 13:16:43 +01:00
Amjad Alsharafi
6cf5c13e87 Do not include math intrinsics for windows and apple targets 2024-04-10 13:40:59 +02:00
Amjad Alsharafi
5416c204a9 Always have math functions but with weak linking attribute if we can
This is a replacement for https://github.com/rust-lang/libm/pull/290

This fixes crashes during compilations for targets that don't have math
symbols by default.

So, we will provide them libm symbols, but mark it as `weak` (if its
supported), so that the linker will choose the system builtin functions,
since those are sometimes more optimized.
If the linker couldn't find those, it will go with `libm`
implementation.
2024-04-10 13:40:59 +02:00
Ralf Jung
bf0ce314e9 add lib.miri.rs file for miri-test-libstd 2024-04-10 12:59:14 +02:00
Jeremy Drake
f23a83c53c Add __chkstk on i686-pc-windows-gnu.
libLLVMSupport.a(DynamicLibrary.cpp.obj) references ___chkstk, which is
an alias of __alloca in libgcc.  This crate provided __alloca, but
libgcc's implementation was also pulled in by the linker due to the
reference to ___chkstk, causing a multiple definition linker error.
Providing that symbol here prevents that.

Fixes #585
2024-04-07 13:08:27 -07:00
Kleis Auke Wolthuizen
f04f8a6a9d Sync x86 chkstk intrinsics with LLVM
Incorporates the following commits:
885d7b759b
1f9eff100c
7a5cba8bea
2024-03-29 19:51:56 +01:00
Daniel Paoliello
30182128c9 Add support for arm64ec 2024-03-28 09:20:13 -07:00
trevyn
dc1321a5ca Remove duplicate symbol workaround 2024-03-28 14:19:13 +00:00
WANG Rui
75624cc8ae Add compiler-rt fallbacks on loongarch64-musl 2024-03-28 14:12:16 +00:00
Ralf Jung
ce85d06f3b add c_unwind feature 2024-03-28 11:33:03 +01:00
Amanieu d'Antras
68b5a7a0ad Clean up and rework CI script 2024-03-28 10:17:42 +00:00
Amanieu d'Antras
079d7d857c Release 0.1.108 2024-02-04 06:40:51 +00:00
Nikita Popov
168bc9ecd7 Also don't build floatdixf and floatundixf 2024-02-02 10:04:55 +01:00
Nikita Popov
2f8b08f9e3 Remove 80-bit builtins entirely
It turns out that these also don't build on x86 + MSVC. Rather
than fixing up the condition, I'm just deleting them entirely.
As far as I know, Rust does not support 80-bit floats and has
no plan to support them, so we shouldn't need them.
2024-01-31 17:37:26 +01:00
Amanieu d'Antras
1cd23fa8b0
Bump to 0.1.107 (#571) 2024-01-31 08:36:00 +00:00
trevyn
f4dbd52ed5
Merge branch 'master' into wasm 2024-01-28 07:20:27 -08:00
Tyler Mandry
45a113effb Handle move of cpu_model.c
This happened in https://github.com/llvm/llvm-project/pull/75635/files
and shows up when building against a recent commit of LLVM.
2024-01-28 11:20:12 +00:00
Amanieu d'Antras
bb30119076
Merge pull request #569 from Kobzol/ci-check-success
CI: add a success conclusion job
2024-01-26 02:37:28 +00:00
BD103
845f4e75d1
fix: replace travis link with github actions link 2024-01-24 13:57:31 -05:00
Jakub Beránek
8ca492c7d7 CI: add a success conclusion job 2024-01-24 19:38:55 +01:00
Nikita Popov
105f0d834d Only add 80-bit long double source on x86
These no longer build on other architectures with LLVM 18. In
previous versions they used an incorrect float layout.
2024-01-22 13:04:44 +01:00
trevyn
d9065480c7
Merge branch 'master' into wasm 2024-01-18 09:36:53 +04:00
Amanieu d'Antras
0dc7f73408 Bump to 0.1.106 2024-01-18 01:27:08 +00:00
Amanieu d'Antras
56f10da22e
Merge pull request #563 from alistair23/alistair/riscv-builtins
build: Allow building C compiler-rt fallbacks for RISC-V
2024-01-18 01:25:47 +00:00
trevyn
0808cdeb67 build: Allow building C compiler-rt fallbacks for wasm 2024-01-09 02:11:00 +04:00
Taiki Endo
c464d5a38d Update actions/checkout action to v4 2024-01-09 00:07:27 +09:00
Alistair Francis
e898296fd9 build: Allow building C compiler-rt fallbacks for RISC-V
Now that https://github.com/rust-lang/rust/pull/117654 has been merged
the rust-lang/rust distribution containers contain RISC-V C compilers.

This means that we can now enable the "c" feature fallback.

Resolves: https://github.com/rust-lang/compiler-builtins/issues/350
Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
2023-12-20 09:47:37 +10:00
Amanieu d'Antras
72dbe301ff Bump to 0.1.105 2023-12-14 20:23:55 +00:00