From 4b57535c8dc73857f47fe0a40e5871c8d92993cf Mon Sep 17 00:00:00 2001 From: Jeremy Soller Date: Wed, 2 Nov 2016 21:46:34 -0600 Subject: [PATCH] Switch to release mode, allow all optimizations --- Makefile | 14 +++++++------- x86_64-unknown-redox.json | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/Makefile b/Makefile index 0d6af5b..83c213f 100644 --- a/Makefile +++ b/Makefile @@ -13,10 +13,10 @@ KCARGOFLAGS=--target $(KTARGET).json -- -C opt-level=s -C soft-float TARGET=$(ARCH)-unknown-redox BUILD=build/userspace RUSTC=./rustc.sh -RUSTCFLAGS=--target $(TARGET).json -C opt-level=s --cfg redox +RUSTCFLAGS=--target $(TARGET).json -C opt-level=2 -C debuginfo=0 --cfg redox RUSTDOC=./rustdoc.sh CARGO=RUSTC="$(RUSTC)" RUSTDOC="$(RUSTDOC)" cargo -CARGOFLAGS=--target $(TARGET).json -- -C opt-level=s --cfg redox +CARGOFLAGS=--target $(TARGET).json --release -- --cfg redox # Default targets .PHONY: all clean doc update qemu bochs drivers schemes coreutils extrautils netutils userutils wireshark FORCE @@ -232,7 +232,7 @@ $(BUILD)/libopenlibm.a: libstd/openlibm/libopenlibm.a $(BUILD)/libstd.rlib: libstd/Cargo.toml libstd/src/** $(BUILD)/libcore.rlib $(BUILD)/liballoc.rlib $(BUILD)/librustc_unicode.rlib $(BUILD)/libcollections.rlib $(BUILD)/librand.rlib $(BUILD)/libopenlibm.a $(CARGO) rustc --verbose --manifest-path $< $(CARGOFLAGS) -o $@ - cp libstd/target/$(TARGET)/debug/deps/*.rlib $(BUILD) + cp libstd/target/$(TARGET)/release/deps/*.rlib $(BUILD) initfs/bin/%: drivers/%/Cargo.toml drivers/%/src/** $(BUILD)/libstd.rlib mkdir -p initfs/bin @@ -435,8 +435,8 @@ $(BUILD)/filesystem.bin: \ rm -rf $@ $(BUILD)/filesystem/ echo exit | cargo run --manifest-path schemes/redoxfs/Cargo.toml --bin redoxfs-utility $@ 256 mkdir -p $(BUILD)/filesystem/ - cargo build --manifest-path schemes/redoxfs/Cargo.toml --bin redoxfs-fuse - schemes/redoxfs/target/debug/redoxfs-fuse $@ $(BUILD)/filesystem/ & + cargo build --manifest-path schemes/redoxfs/Cargo.toml --bin redoxfs-fuse --release + schemes/redoxfs/target/release/redoxfs-fuse $@ $(BUILD)/filesystem/ & sleep 2 pgrep redoxfs-fuse cp -RL filesystem/* $(BUILD)/filesystem/ @@ -454,8 +454,8 @@ $(BUILD)/filesystem.bin: \ mount: $(BUILD)/filesystem.bin FORCE mkdir -p $(BUILD)/filesystem/ - cargo build --manifest-path schemes/redoxfs/Cargo.toml --bin redoxfs-fuse - schemes/redoxfs/target/debug/redoxfs-fuse $< $(BUILD)/filesystem/ & + cargo build --manifest-path schemes/redoxfs/Cargo.toml --bin redoxfs-fuse --release + schemes/redoxfs/target/release/redoxfs-fuse $< $(BUILD)/filesystem/ & sleep 2 pgrep redoxfs-fuse diff --git a/x86_64-unknown-redox.json b/x86_64-unknown-redox.json index e0a010a..8878e06 100644 --- a/x86_64-unknown-redox.json +++ b/x86_64-unknown-redox.json @@ -10,7 +10,7 @@ "target-family": "redox", "pre-link-args": ["-m64", "-nostdlib", "-static"], "post-link-args": ["build/userspace/libopenlibm.a"], - "features": "-sse3,-ssse3,-sse4.1,-sse4.2,-3dnow,-3dnowa,-avx,-avx2", + "features": "", "dynamic-linking": false, "executables": true, "relocation-model": "static",