From bca25aeeb40b220d7330d71cd4906acafc32ebe7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B6rn=20Steinbrink?= Date: Mon, 26 Jan 2015 09:45:16 +0100 Subject: [PATCH] Use more specific target CPUs on Darwin Macs don't come with anything older than a Yonah (32bit) or Core2 (64bit), so we can default to those targets. Clang does the same. --- src/librustc_back/target/i686_apple_darwin.rs | 1 + src/librustc_back/target/x86_64_apple_darwin.rs | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/src/librustc_back/target/i686_apple_darwin.rs b/src/librustc_back/target/i686_apple_darwin.rs index 1b079323bf9..fcea900283d 100644 --- a/src/librustc_back/target/i686_apple_darwin.rs +++ b/src/librustc_back/target/i686_apple_darwin.rs @@ -12,6 +12,7 @@ use target::Target; pub fn target() -> Target { let mut base = super::apple_base::opts(); + base.cpu = "yonah".to_string(); base.pre_link_args.push("-m32".to_string()); Target { diff --git a/src/librustc_back/target/x86_64_apple_darwin.rs b/src/librustc_back/target/x86_64_apple_darwin.rs index f2abfd4564c..0b3b2bea62d 100644 --- a/src/librustc_back/target/x86_64_apple_darwin.rs +++ b/src/librustc_back/target/x86_64_apple_darwin.rs @@ -12,7 +12,7 @@ use target::Target; pub fn target() -> Target { let mut base = super::apple_base::opts(); - base.cpu = "x86-64".to_string(); + base.cpu = "core2".to_string(); base.eliminate_frame_pointer = false; base.pre_link_args.push("-m64".to_string());