diff options
author | Nicolas Boichat <drinkcat@chromium.org> | 2017-09-06 18:04:19 +0800 |
---|---|---|
committer | chrome-bot <chrome-bot@chromium.org> | 2017-09-11 04:42:59 -0700 |
commit | 797d740727813c7b600e8ecd9df0bb87b0d39678 (patch) | |
tree | a4c71e038186ad4f84054dfda567a2e0dcf79e79 /test | |
parent | 1d4c4530ac5bf2d2e4acb8950fba5dd8c5a12033 (diff) | |
download | chrome-ec-797d740727813c7b600e8ecd9df0bb87b0d39678.tar.gz |
common/sha256: agressive SHA-256 unrolling as an option
Reduces "hash done" time from ~1.30 to ~1.15s on soraka.
BRANCH=none
BUG=chromium:702378
BUG=b:64196191
TEST=Boot soraka, looks at hash done time.
TEST=make run-sha256 run-sha256_unrolled passes.
Change-Id: Ia29ee27404d6e9aa615ff59755b59d3f26648e71
Signed-off-by: Nicolas Boichat <drinkcat@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/652327
Reviewed-by: Furquan Shaikh <furquan@chromium.org>
Reviewed-by: Vincent Palatin <vpalatin@chromium.org>
Diffstat (limited to 'test')
-rw-r--r-- | test/build.mk | 2 | ||||
l--------- | test/sha256_unrolled.tasklist | 1 | ||||
-rw-r--r-- | test/test_config.h | 5 |
3 files changed, 8 insertions, 0 deletions
diff --git a/test/build.mk b/test/build.mk index c54627d03c..a1f03c9235 100644 --- a/test/build.mk +++ b/test/build.mk @@ -71,6 +71,7 @@ test-list-host += rsa test-list-host += rsa3 test-list-host += sbs_charging_v2 test-list-host += sha256 +test-list-host += sha256_unrolled test-list-host += shmalloc test-list-host += system test-list-host += thermal @@ -121,6 +122,7 @@ rsa3-y=rsa.o sbs_charging-y=sbs_charging.o sbs_charging_v2-y=sbs_charging_v2.o sha256-y=sha256.o +sha256_unrolled-y=sha256.o shmalloc-y=shmalloc.o stress-y=stress.o system-y=system.o diff --git a/test/sha256_unrolled.tasklist b/test/sha256_unrolled.tasklist new file mode 120000 index 0000000000..06d8620957 --- /dev/null +++ b/test/sha256_unrolled.tasklist @@ -0,0 +1 @@ +sha256.tasklist
\ No newline at end of file diff --git a/test/test_config.h b/test/test_config.h index 5c4807fd66..31d5679d05 100644 --- a/test/test_config.h +++ b/test/test_config.h @@ -85,6 +85,11 @@ #define CONFIG_SHA256 #endif +#ifdef TEST_SHA256_UNROLLED +#define CONFIG_SHA256 +#define CONFIG_SHA256_UNROLLED +#endif + #ifdef TEST_SHMALLOC #define CONFIG_MALLOC #endif |