Skip to content
This repository has been archived by the owner on Nov 6, 2020. It is now read-only.

Enable aesni #10756

Merged
merged 27 commits into from
Jun 18, 2019
Merged
Show file tree
Hide file tree
Changes from 22 commits
Commits
Show all changes
27 commits
Select commit Hold shift + click to select a range
3efca47
Run cargo fix
dvdplm Jun 1, 2019
431eccf
Optimize imports
dvdplm Jun 1, 2019
95a958d
compiles
dvdplm Jun 3, 2019
66f3659
cleanup
dvdplm Jun 3, 2019
be06f57
Use Secret to store mac-key
dvdplm Jun 3, 2019
9634be3
cleanup
dvdplm Jun 3, 2019
d5d1eb0
Merge branch 'master' into dp/chore/devp2p-cosmetics
dvdplm Jun 3, 2019
1e68071
Reorg imports
dvdplm Jun 3, 2019
6f51390
Merge branch 'dp/chore/devp2p-cosmetics' into dp/chore/remove-rust-cr…
dvdplm Jun 3, 2019
b0c89b8
Merge branch 'master' into dp/chore/remove-rust-crypto-from-devp2p
dvdplm Jun 4, 2019
f190a63
brwchk hand waving
dvdplm Jun 4, 2019
0ae675b
Review feedback
dvdplm Jun 14, 2019
17c3a3b
Merge branch 'master' into dp/chore/remove-rust-crypto-from-devp2p
dvdplm Jun 17, 2019
e4e00c9
whitespace
dvdplm Jun 17, 2019
b2e51bb
error chain is dead
dvdplm Jun 17, 2019
9999b71
Build parity-ethereum with SSE2, SSSE3 and AES enabled
dvdplm Jun 17, 2019
56c0706
Correct rustflag setting
dvdplm Jun 18, 2019
b34da90
List all target triples because [target.'cfg(…)'] is broken
dvdplm Jun 18, 2019
08401a1
whitespace
dvdplm Jun 18, 2019
4a38f5c
Merge branch 'master' into dp/chore/turn-on-aesni
dvdplm Jun 18, 2019
011688e
Enable hardware aes for CI builds
dvdplm Jun 18, 2019
79453f2
Add note about synchronizing changes
dvdplm Jun 18, 2019
0278e37
Remove "Linker" printout
dvdplm Jun 18, 2019
30fba7f
Build artefacts to check hardware aesni
dvdplm Jun 18, 2019
a8ae24b
Skip signing windows binaries
dvdplm Jun 18, 2019
5efefc5
Build windows like before
dvdplm Jun 18, 2019
47762be
address grumble
dvdplm Jun 18, 2019
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 25 additions & 2 deletions .cargo/config
Original file line number Diff line number Diff line change
@@ -1,3 +1,26 @@
# NOTE: if you make changes here, remember to also update:
# scripts/test-linux.sh
# scripts/build-linux.sh
# scripts/build-windows.sh

# Using 'cfg` is broken, see https://github.com/rust-lang/cargo/issues/6858
#[target.'cfg(target_arch = "x86_64")']
#rustflags = ["-Ctarget-feature=+aes,+sse2,+ssse3"]

# …so instead we list all target triples (Tier 1 64-bit platforms)
[target.x86_64-unknown-linux-gnu]
# Enable aesimc.
dvdplm marked this conversation as resolved.
Show resolved Hide resolved
rustflags = ["-Ctarget-feature=+aes,+sse2,+ssse3"]

[target.x86_64-pc-windows-gnu]
# Enable aesimc.
rustflags = ["-Ctarget-feature=+aes,+sse2,+ssse3"]

[target.x86_64-pc-windows-msvc]
# Link the C runtime statically ; https://github.com/paritytech/parity-ethereum/issues/6643
rustflags = ["-Ctarget-feature=+crt-static"]
# Enable aesimc. Link the C runtime statically ; https://github.com/paritytech/parity-ethereum/issues/6643
rustflags = ["-Ctarget-feature=+aes,+sse2,+ssse3", "-Ctarget-feature=+crt-static"]

[target.x86_64-apple-darwin]
# Enable aesimc.
rustflags = ["-Ctarget-feature=+aes,+sse2,+ssse3"]

7 changes: 6 additions & 1 deletion scripts/gitlab/build-linux.sh
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ echo "CC: " $CC
echo "CXX: " $CXX
#strip ON
export RUSTFLAGS=" -C link-arg=-s"
# Linker for crosscomile
# Linker for crosscompilation
dvdplm marked this conversation as resolved.
Show resolved Hide resolved
echo "_____ Linker _____"
cat .cargo/config

Expand All @@ -20,6 +20,11 @@ if [ "${CARGO_TARGET}" = "armv7-linux-androideabi" ]
then
time cargo build --target $CARGO_TARGET --verbose --color=always --release -p parity-clib --features final
else
if [ "${CARGO_TARGET}" = "x86_64-unknown-linux-gnu" ] || [ "${CARGO_TARGET}" = "x86_64-apple-darwin" ]
then
# NOTE: if you change this please remember to also update .cargo/config
export RUSTFLAGS="$RUSTFLAGS -Ctarget-feature=+aes,+sse2,+ssse3"
fi
time cargo build --target $CARGO_TARGET --verbose --color=always --release --features final
time cargo build --target $CARGO_TARGET --verbose --color=always --release -p evmbin
time cargo build --target $CARGO_TARGET --verbose --color=always --release -p ethstore-cli
Expand Down
3 changes: 3 additions & 0 deletions scripts/gitlab/build-windows.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@ echo "RUSTC_WRAPPER: " $RUSTC_WRAPPER
echo "SCCACHE_DIR: " $SCCACHE_DIR

echo "_____ Building target: "$CARGO_TARGET" _____"
# NOTE: if you change this please remember to also update .cargo/config
export RUSTFLAGS=" -Ctarget-feature=+aes,+sse2,+ssse3 -Ctarget-feature=+crt-static"
dvdplm marked this conversation as resolved.
Show resolved Hide resolved

time cargo build --target $CARGO_TARGET --verbose --release --features final
time cargo build --target $CARGO_TARGET --verbose --release -p evmbin
time cargo build --target $CARGO_TARGET --verbose --release -p ethstore-cli
Expand Down
2 changes: 1 addition & 1 deletion scripts/gitlab/test-linux.sh
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,4 @@ rustup show

echo "________Running Parity Full Test Suite________"
# Why are we using RUSTFLAGS? See https://github.com/paritytech/parity-ethereum/pull/10719
CARGO_INCREMENTAL=0 RUSTFLAGS="-C opt-level=3 -C overflow-checks=on -C debuginfo=2" time cargo test $OPTIONS --features "$FEATURES" --locked --all --target $CARGO_TARGET --verbose --color=never -- --test-threads $THREADS
CARGO_INCREMENTAL=0 RUSTFLAGS="-C opt-level=3 -C overflow-checks=on -C debuginfo=2 -Ctarget-feature=+aes,+sse2,+ssse3" time cargo test $OPTIONS --features "$FEATURES" --locked --all --target $CARGO_TARGET --verbose --color=never -- --test-threads $THREADS