Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add __powitf2 symbol for f128 integer exponentiation #614

Merged
merged 3 commits into from
Sep 28, 2024

Conversation

tgross35
Copy link
Contributor

No description provided.

@tgross35 tgross35 changed the title Add __powitf2 symbol for f128 powi Add __powitf2 symbol for f128 integer exponentation May 16, 2024
@tgross35 tgross35 changed the title Add __powitf2 symbol for f128 integer exponentation Add __powitf2 symbol for f128 integer exponentiation May 16, 2024
tgross35 added a commit to tgross35/rust that referenced this pull request May 16, 2024
This will unblock adding support to compiler_builtins
(<rust-lang/compiler-builtins#614>), which will
then unblock adding tests for these new functions.
tgross35 added a commit to tgross35/rust that referenced this pull request May 16, 2024
This will unblock adding support to compiler_builtins
(<rust-lang/compiler-builtins#614>), which will
then unblock adding tests for these new functions.
@tgross35
Copy link
Contributor Author

Blocked until we have the function in libs, rust-lang/rust#125188

@tgross35
Copy link
Contributor Author

Lol @Qadeem411 I have to imagine you didn’t mean to approve this

bors added a commit to rust-lang-ci/rust that referenced this pull request May 17, 2024
Add `powi` fo `f16` and `f128`

This will unblock adding support to compiler_builtins (<rust-lang/compiler-builtins#614>), which will then unblock adding tests for these new functions.
@tgross35 tgross35 force-pushed the f16-f128-powi branch 7 times, most recently from 65841d8 to 9550d45 Compare May 18, 2024 04:25
@tgross35
Copy link
Contributor Author

WIndows targets appear to fail compiling this crate because powi uses the f128 multiply and divide in its implementation, and these are not available. I don't know why only Windows has the issue, but other platforms without these available natively (e.g. aarch darwin) do not, must be slightly different linkage rules. How should I handle this @Amanieu?

@Amanieu
Copy link
Member

Amanieu commented May 21, 2024

I think this just happens to work before libgcc provides these symbols, but that's not available on -msvc targets. You'll need to implement a fallback for that target for testing, at least temporarily.

@tgross35 tgross35 force-pushed the f16-f128-powi branch 3 times, most recently from fdb0fd1 to 241b9a8 Compare May 21, 2024 04:25
@tgross35
Copy link
Contributor Author

It looks like I can make this work by recreating __multf3 and __divtf3 in testcrate's lib.rs, this will just be blocked until I implement divtf3.

flip1995 pushed a commit to flip1995/rust-clippy that referenced this pull request May 24, 2024
Add `powi` fo `f16` and `f128`

This will unblock adding support to compiler_builtins (<rust-lang/compiler-builtins#614>), which will then unblock adding tests for these new functions.
@tgross35 tgross35 mentioned this pull request Aug 19, 2024
@tgross35 tgross35 force-pushed the f16-f128-powi branch 2 times, most recently from fbf79c0 to f74817b Compare August 19, 2024 21:33
@tgross35
Copy link
Contributor Author

__divtf3 hasn't made it to nightly yet, and I can't seem to figure out a way to provide it here to avoid the Windows linking. Hopefully that won't be too far off, but I just disabled this new symbol on MSVC in the meantime.

This should be ready for a look when you get the chance @Amanieu

@tgross35 tgross35 marked this pull request as ready for review September 26, 2024 02:46
Copy link
Member

@Amanieu Amanieu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Feel free to merge it either now (and enable it with MSVC later) or after a boostrap bump.

@tgross35
Copy link
Contributor Author

Thanks! rust-lang/rust#130792 hasn't been picked up yet so I might as well just update that to include this.

@tgross35 tgross35 merged commit 9975c79 into rust-lang:master Sep 28, 2024
24 checks passed
@tgross35 tgross35 deleted the f16-f128-powi branch September 28, 2024 15:13
tgross35 added a commit to tgross35/rust that referenced this pull request Sep 28, 2024
This includes the following which add `__divtf3` and `__powtf2`, and do
some feature cleanup:

- rust-lang/compiler-builtins#622
- rust-lang/compiler-builtins#692
- rust-lang/compiler-builtins#614
- rust-lang/compiler-builtins#694

The `cc` bump [1] was previously included but was reverted due to
problems updating.

[1]: rust-lang/compiler-builtins#690
tgross35 added a commit to tgross35/rust that referenced this pull request Sep 28, 2024
This includes the following which add `__divtf3` and `__powtf2`, and do
some feature cleanup:

- rust-lang/compiler-builtins#622
- rust-lang/compiler-builtins#692
- rust-lang/compiler-builtins#614
- rust-lang/compiler-builtins#694

The `cc` bump [1] was previously included but was reverted due to
problems updating.

[1]: rust-lang/compiler-builtins#690
bors added a commit to rust-lang-ci/rust that referenced this pull request Sep 28, 2024
Update compiler-builtins to 0.1.130

This includes the following which add `__divtf3` and `__powtf2`, and do some feature cleanup:

- rust-lang/compiler-builtins#622
- rust-lang/compiler-builtins#692
- rust-lang/compiler-builtins#614
- rust-lang/compiler-builtins#694

The `cc` bump [1] was previously included but was reverted due to problems updating.

[1]: rust-lang/compiler-builtins#690
cberner pushed a commit to cberner/rust that referenced this pull request Sep 28, 2024
This includes the following which add `__divtf3` and `__powtf2`, and do
some feature cleanup:

- rust-lang/compiler-builtins#622
- rust-lang/compiler-builtins#692
- rust-lang/compiler-builtins#614
- rust-lang/compiler-builtins#694

The `cc` bump [1] was previously included but was reverted due to
problems updating.

[1]: rust-lang/compiler-builtins#690
RalfJung pushed a commit to RalfJung/miri that referenced this pull request Oct 3, 2024
Update compiler-builtins to 0.1.130

This includes the following which add `__divtf3` and `__powtf2`, and do some feature cleanup:

- rust-lang/compiler-builtins#622
- rust-lang/compiler-builtins#692
- rust-lang/compiler-builtins#614
- rust-lang/compiler-builtins#694

The `cc` bump [1] was previously included but was reverted due to problems updating.

[1]: rust-lang/compiler-builtins#690
cberner pushed a commit to cberner/rust that referenced this pull request Oct 13, 2024
This includes the following which add `__divtf3` and `__powtf2`, and do
some feature cleanup:

- rust-lang/compiler-builtins#622
- rust-lang/compiler-builtins#692
- rust-lang/compiler-builtins#614
- rust-lang/compiler-builtins#694

The `cc` bump [1] was previously included but was reverted due to
problems updating.

[1]: rust-lang/compiler-builtins#690
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants