1
Fork 0
rust/compiler/rustc_codegen_llvm/src
bors c97922dca5 Auto merge of #99443 - jam1garner:mips-virt-feature, r=nagisa
Add support for MIPS VZ ISA extension

[Link to relevant LLVM line where virt extension is specified](83fab8cee9/llvm/lib/Target/Mips/Mips.td (L172-L173))

This has been tested on mips-unknown-linux-musl with a target-cpu that is >= MIPS32 5 and `target-features=+virt`. The example was checked in a disassembler to ensure the correct assembly sequence was being generated using the virtualization instructions.

Needed additional work:

* MIPS is missing from [the Rust reference CPU feature lists](https://doc.rust-lang.org/reference/attributes/codegen.html#available-features)

Example docs for later:

```md
#### `mips` or `mips64`

This platform requires that `#[target_feature]` is only applied to [`unsafe`
functions][unsafe function]. This target's feature support is currently unstable
and must be enabled by `#![feature(mips_target_feature)]` ([Issue #44839])

[Issue #44839]: https://github.com/rust-lang/rust/issues/44839

Further documentation on these features can be found in the [MIPS Instruction Set
Reference Manual], or elsewhere on [mips.com].

[MIPS Instruction Set Reference Manual]: https://s3-eu-west-1.amazonaws.com/downloads-mips/documents/MD00086-2B-MIPS32BIS-AFP-6.06.pdf
[developer.arm.com]: https://www.mips.com/products/architectures/ase/

Feature        | Implicitly Enables | Description
---------------|--------------------|-------------------
`fp64`         |                    | 64-bit Floating Point
`msa`          |                    | "MIPS SIMD Architecture"
`virt`         |                    | Virtualization instructions (VZ ASE)
```

If the above is good I can also submit a PR for that if there's interest in documenting it while it's still unstable. Otherwise that can be dropped, I just wrote it before realizing it was possibly not a good idea.

Relevant to #44839
2022-09-14 08:21:25 +00:00
..
back Always import all tracing macros for the entire crate instead of piecemeal by module 2022-09-01 14:54:27 +00:00
coverageinfo Always import all tracing macros for the entire crate instead of piecemeal by module 2022-09-01 14:54:27 +00:00
debuginfo Change name of "dataful" variant to "untagged" 2022-09-07 20:12:45 +00:00
llvm Introduce a fallible variant of LLVMConstIntGetZExtValue 2022-09-09 15:54:14 +02:00
abi.rs Rollup merge of #99207 - 5225225:msan-eager-checks, r=jackh726 2022-09-09 07:02:30 +02:00
allocator.rs Rename debugging_opts to unstable_opts 2022-07-13 17:47:06 -05:00
asm.rs Always import all tracing macros for the entire crate instead of piecemeal by module 2022-09-01 14:54:27 +00:00
attributes.rs Add inline-llvm option for disabling/enabling LLVM inlining 2022-09-09 08:00:47 -07:00
base.rs Auto merge of #95689 - lqd:self-profiler, r=wesleywiser 2022-04-16 11:43:28 +00:00
builder.rs Always import all tracing macros for the entire crate instead of piecemeal by module 2022-09-01 14:54:27 +00:00
callee.rs Always import all tracing macros for the entire crate instead of piecemeal by module 2022-09-01 14:54:27 +00:00
common.rs Introduce a fallible variant of LLVMConstIntGetZExtValue 2022-09-09 15:54:14 +02:00
consts.rs Always import all tracing macros for the entire crate instead of piecemeal by module 2022-09-01 14:54:27 +00:00
context.rs Do not use void pointer for ptr_mask intrinsic 2022-08-21 05:27:14 +04:00
declare.rs Always import all tracing macros for the entire crate instead of piecemeal by module 2022-09-01 14:54:27 +00:00
intrinsic.rs Auto merge of #96946 - WaffleLapkin:ptr_mask, r=scottmcm 2022-08-28 01:34:47 +00:00
lib.rs Directly use the instrument macro instead of its full path 2022-09-01 14:53:46 +00:00
llvm_util.rs Auto merge of #99443 - jam1garner:mips-virt-feature, r=nagisa 2022-09-14 08:21:25 +00:00
mono_item.rs Always import all tracing macros for the entire crate instead of piecemeal by module 2022-09-01 14:54:27 +00:00
type_.rs Add fine-grained LLVM CFI support to the Rust compiler 2022-07-23 10:51:34 -07:00
type_of.rs Always import all tracing macros for the entire crate instead of piecemeal by module 2022-09-01 14:54:27 +00:00
va_arg.rs Introduce Bx::switch_to_block 2022-02-24 12:18:21 +01:00
value.rs mv compiler to compiler/ 2020-08-30 18:45:07 +03:00