mirror of
https://github.com/espressif/esp-idf.git
synced 2024-10-05 20:47:46 -04:00
5ed8388f6b
It gave us a better performance of RSA operations. (2~11 times) The old modexp implementation (Z = X ^ Y mod M) loaded all the data into the hw registers and was waiting for completion, but due to the hardware RSA implementation, the calculations always started with 4096 bit, which took a lot of time. Measurement results (measurements were made for keys: 2048, 3072 and 4096 bits) (Old) - Sliding-window exponentiation (HAC 14.85): keysize = 2048 bits RSA key operation (performance): public [93206 us], private [280189 us] keysize = 3072 bits RSA key operation (performance): public [293614 us], private [858157 us] keysize = 4096 bits RSA key operation (performance): public [653192 us], private [1912126 us] Instead (Old) - Sliding-window exponentiation (HAC 14.85) was implemented (New) - Montgomery exponentiation (HAC 14.94) which showed better performance on private and public keys. keysize = 2048 bits RSA key operation (performance): public [14504 us], private [149456 us] keysize = 3072 bits RSA key operation (performance): public [35073 us], private [392743 us] keysize = 4096 bits RSA key operation (performance): public [58650 us], private [787186 us] For this reason, the old implementation was removed and the MBEDTLS_HARDWARE_MPI option was turned on by default. Why the MPI_INTERRUPT option is removed: the old implementation used calculations on the hardware and it took a lot of time (10ms - 500ms). And in order not to stand idle while waiting for completion, an interrupt option was added. This made it possible to carry out other tasks during the calculation, and this one to block. The new method is free from such a drawback and the maximum duration of one RSA HW operation does not exceed 70us (usually 2-70 μs). This option is no longer needed. Closes: IDF-965 |
||
---|---|---|
.. | ||
ble | ||
catch | ||
ci | ||
cmake | ||
docker | ||
esp_app_trace | ||
esp_prov | ||
kconfig | ||
kconfig_new | ||
ldgen | ||
mass_mfg | ||
test_idf_monitor | ||
test_idf_py | ||
test_idf_size | ||
test_idf_tools | ||
tiny-test-fw | ||
unit-test-app | ||
windows | ||
check_kconfigs.py | ||
check_python_dependencies.py | ||
eclipse-code-style.xml | ||
elf_to_ld.sh | ||
format-minimal.sh | ||
format.sh | ||
gen_esp_err_to_name.py | ||
idf_monitor.py | ||
idf_size.py | ||
idf_tools.py | ||
idf.py | ||
set-submodules-to-github.sh | ||
test_check_kconfigs.py | ||
toolchain_versions.mk | ||
tools_schema.json | ||
tools.json |