Rollup merge of #97808 - alexcrichton:wasm-features, r=petrochenkov
Add some unstable target features for the wasm target codegen I was experimenting with cross-language LTO for the wasm target recently between Rust and C and found that C was injecting the `+mutable-globals` flag on all functions. When specifying the corresponding `-Ctarget-feature=+mutable-globals` feature to Rust it prints a warning about an unknown feature. I've added the `mutable-globals` feature plus another few I know of to the list of known features for wasm targets. These features all continue to be unstable to source code as they were before.
This commit is contained in:
commit
95266530d5
@ -246,6 +246,9 @@ const WASM_ALLOWED_FEATURES: &[(&str, Option<Symbol>)] = &[
|
||||
("simd128", None),
|
||||
("atomics", Some(sym::wasm_target_feature)),
|
||||
("nontrapping-fptoint", Some(sym::wasm_target_feature)),
|
||||
("bulk-memory", Some(sym::wasm_target_feature)),
|
||||
("mutable-globals", Some(sym::wasm_target_feature)),
|
||||
("reference-types", Some(sym::wasm_target_feature)),
|
||||
];
|
||||
|
||||
const BPF_ALLOWED_FEATURES: &[(&str, Option<Symbol>)] = &[("alu32", Some(sym::bpf_target_feature))];
|
||||
|
Loading…
x
Reference in New Issue
Block a user