Skip to content
This repository was archived by the owner on May 28, 2025. It is now read-only.

Commit 7e443c4

Browse files
committed
Dropped Support for Bidirectional Custom Target Definition Emulation
as requested in the review and argued that this is only consistent with later LLVM upgrades
1 parent 8236830 commit 7e443c4

File tree

1 file changed

+0
-12
lines changed

1 file changed

+0
-12
lines changed

compiler/rustc_codegen_llvm/src/attributes.rs

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -144,17 +144,6 @@ fn set_probestack(cx: &CodegenCx<'ll, '_>, llfn: &'ll Value) {
144144
);
145145
}
146146

147-
fn translate_obsolete_target_features(feature: &str) -> &str {
148-
const LLVM9_FEATURE_CHANGES: &[(&str, &str)] =
149-
&[("+fp-only-sp", "-fp64"), ("-fp-only-sp", "+fp64"), ("+d16", "-d32"), ("-d16", "+d32")];
150-
for &(old, new) in LLVM9_FEATURE_CHANGES {
151-
if feature == old {
152-
return new;
153-
}
154-
}
155-
feature
156-
}
157-
158147
pub fn llvm_target_features(sess: &Session) -> impl Iterator<Item = &str> {
159148
const RUSTC_SPECIFIC_FEATURES: &[&str] = &["crt-static"];
160149

@@ -169,7 +158,6 @@ pub fn llvm_target_features(sess: &Session) -> impl Iterator<Item = &str> {
169158
.split(',')
170159
.chain(cmdline)
171160
.filter(|l| !l.is_empty())
172-
.map(translate_obsolete_target_features)
173161
}
174162

175163
pub fn apply_target_cpu_attr(cx: &CodegenCx<'ll, '_>, llfn: &'ll Value) {

0 commit comments

Comments
 (0)