mirror of
https://github.com/rust-lang/rust.git
synced 2025-06-04 19:29:07 +00:00
rustc_trans: clobber $1 (aka $at) on mips
This copies what clang does. There is a long explanation as to why this is needed in the clang source (tools/clang/lib/Basic/Targets/Mips.h).
This commit is contained in:
parent
fe7e1a45f3
commit
d8e4142bd4
@ -59,8 +59,9 @@ pub fn trans_inline_asm<'a, 'tcx>(
|
|||||||
// Default per-arch clobbers
|
// Default per-arch clobbers
|
||||||
// Basically what clang does
|
// Basically what clang does
|
||||||
let arch_clobbers = match &bx.sess().target.target.arch[..] {
|
let arch_clobbers = match &bx.sess().target.target.arch[..] {
|
||||||
"x86" | "x86_64" => vec!["~{dirflag}", "~{fpsr}", "~{flags}"],
|
"x86" | "x86_64" => vec!["~{dirflag}", "~{fpsr}", "~{flags}"],
|
||||||
_ => Vec::new()
|
"mips" | "mips64" => vec!["~{$1}"],
|
||||||
|
_ => Vec::new()
|
||||||
};
|
};
|
||||||
|
|
||||||
let all_constraints =
|
let all_constraints =
|
||||||
|
Loading…
Reference in New Issue
Block a user