Add `f16` and `f128` const eval for binary and unary operationations by tgross35 · Pull Request #126429 · rust-lang/rust

@rustbot rustbot added T-compiler

Relevant to the compiler team, which will review and decide on the PR/issue.

S-waiting-on-review

Status: Awaiting review from the assignee but also interested parties.

labels

Jun 13, 2024

@tgross35 tgross35 marked this pull request as ready for review

June 13, 2024 20:35

matthiaskrgr

oli-obk

RalfJung

This excludes casting, which needs more tests.

@tgross35

@tgross35

Const eval negation was added. This test is now covered by Miri tests,
and merged into an existing UI test.

Fixes <rust-lang#124583>

RalfJung

@tgross35 tgross35 changed the title Add f16 and f128 const evaluation Add f16 and f128 const eval for binary and unary operationations

Jun 14, 2024

@bors bors added S-waiting-on-bors

Status: Waiting on bors to run and complete tests. Bors will change the label on completion.

and removed S-waiting-on-review

Status: Awaiting review from the assignee but also interested parties.

labels

Jun 14, 2024

matthiaskrgr added a commit to matthiaskrgr/rust that referenced this pull request

Jun 15, 2024
…lfJung

Add `f16` and `f128` const eval for binary and unary operationations

Add const evaluation and Miri support for f16 and f128, including unary and binary operations. Casts are not yet included.

Fixes rust-lang#124583

r? `@RalfJung`

bors added a commit to rust-lang-ci/rust that referenced this pull request

Jun 15, 2024
…iaskrgr

Rollup of 10 pull requests

Successful merges:

 - rust-lang#125829 (rustc_span: Add conveniences for working with span formats)
 - rust-lang#126279 (Migrate `inaccessible-temp-dir`, `output-with-hyphens` and `issue-10971-temps-dir` `run-make` tests to `rmake`)
 - rust-lang#126361 (Unify intrinsics body handling in StableMIR)
 - rust-lang#126417 (Add `f16` and `f128` inline ASM support for `x86` and `x86-64`)
 - rust-lang#126424 ( Also sort `crt-static` in `--print target-features` output)
 - rust-lang#126428 (Polish `std::path::absolute` documentation.)
 - rust-lang#126429 (Add `f16` and `f128` const eval for binary and unary operationations)
 - rust-lang#126448 (End support for Python 3.8 in tidy)
 - rust-lang#126488 (Use `std::path::absolute` in bootstrap)
 - rust-lang#126511 (.mailmap: Associate both my work and my private email with me)

r? `@ghost`
`@rustbot` modify labels: rollup

bors added a commit to rust-lang-ci/rust that referenced this pull request

Jun 15, 2024
…iaskrgr

Rollup of 9 pull requests

Successful merges:

 - rust-lang#125829 (rustc_span: Add conveniences for working with span formats)
 - rust-lang#126361 (Unify intrinsics body handling in StableMIR)
 - rust-lang#126417 (Add `f16` and `f128` inline ASM support for `x86` and `x86-64`)
 - rust-lang#126424 ( Also sort `crt-static` in `--print target-features` output)
 - rust-lang#126428 (Polish `std::path::absolute` documentation.)
 - rust-lang#126429 (Add `f16` and `f128` const eval for binary and unary operationations)
 - rust-lang#126448 (End support for Python 3.8 in tidy)
 - rust-lang#126488 (Use `std::path::absolute` in bootstrap)
 - rust-lang#126511 (.mailmap: Associate both my work and my private email with me)

r? `@ghost`
`@rustbot` modify labels: rollup

rust-timer added a commit to rust-lang-ci/rust that referenced this pull request

Jun 15, 2024
Rollup merge of rust-lang#126429 - tgross35:f16-f128-const-eval, r=RalfJung

Add `f16` and `f128` const eval for binary and unary operationations

Add const evaluation and Miri support for f16 and f128, including unary and binary operations. Casts are not yet included.

Fixes rust-lang#124583

r? ``@RalfJung``

This was referenced

Jun 19, 2024

compiler-errors added a commit to compiler-errors/rust that referenced this pull request

Jun 23, 2024
…Simulacrum

Add more constants, functions, and tests for `f16` and `f128`

This adds everything that was in some way blocked on const eval, since rust-lang#126429 landed. There is a lot of `cfg(bootstrap)` since that is a fairly recent change.

`f128` tests are disabled on everything except x86_64 and Linux aarch64, which are two platforms I know have "good" support for these types - meaning basic math symbols are available and LLVM doesn't hit selection crashes. `f16` tests are enabled on almost everything except for known LLVM crashes. Doctests are only enabled on x86_64.

Tracking issue: rust-lang#116909

bors added a commit to rust-lang-ci/rust that referenced this pull request

Jun 23, 2024
…mulacrum

Add more constants, functions, and tests for `f16` and `f128`

This adds everything that was in some way blocked on const eval, since rust-lang#126429 landed. There is a lot of `cfg(bootstrap)` since that is a fairly recent change.

`f128` tests are disabled on everything except x86_64 and Linux aarch64, which are two platforms I know have "good" support for these types - meaning basic math symbols are available and LLVM doesn't hit selection crashes. `f16` tests are enabled on almost everything except for known LLVM crashes. Doctests are only enabled on x86_64.

Tracking issue: rust-lang#116909

bors added a commit to rust-lang-ci/rust that referenced this pull request

Jun 26, 2024
…mulacrum

Add more constants, functions, and tests for `f16` and `f128`

This adds everything that was in some way blocked on const eval, since rust-lang#126429 landed. There is a lot of `cfg(bootstrap)` since that is a fairly recent change.

`f128` tests are disabled on everything except x86_64 and Linux aarch64, which are two platforms I know have "good" support for these types - meaning basic math symbols are available and LLVM doesn't hit selection crashes. `f16` tests are enabled on almost everything except for known LLVM crashes. Doctests are only enabled on x86_64.

Tracking issue: rust-lang#116909

github-actions bot pushed a commit to rust-lang/miri that referenced this pull request

Jun 27, 2024
Add more constants, functions, and tests for `f16` and `f128`

This adds everything that was in some way blocked on const eval, since rust-lang/rust#126429 landed. There is a lot of `cfg(bootstrap)` since that is a fairly recent change.

`f128` tests are disabled on everything except x86_64 and Linux aarch64, which are two platforms I know have "good" support for these types - meaning basic math symbols are available and LLVM doesn't hit selection crashes. `f16` tests are enabled on almost everything except for known LLVM crashes. Doctests are only enabled on x86_64.

Tracking issue: rust-lang/rust#116909

flip1995 pushed a commit to flip1995/rust-clippy that referenced this pull request

Jun 28, 2024
Add more constants, functions, and tests for `f16` and `f128`

This adds everything that was in some way blocked on const eval, since rust-lang/rust#126429 landed. There is a lot of `cfg(bootstrap)` since that is a fairly recent change.

`f128` tests are disabled on everything except x86_64 and Linux aarch64, which are two platforms I know have "good" support for these types - meaning basic math symbols are available and LLVM doesn't hit selection crashes. `f16` tests are enabled on almost everything except for known LLVM crashes. Doctests are only enabled on x86_64.

Tracking issue: rust-lang/rust#116909