diff --git a/library/bn_mul.h b/library/bn_mul.h index 34719b995..6b8106f9f 100644 --- a/library/bn_mul.h +++ b/library/bn_mul.h @@ -743,10 +743,10 @@ #define MULADDC_X1_CORE \ ".p2align 2 \n\t" \ - "ldr.w %[a], [%[in]], #4 \n\t" \ - "ldr.w %[b], [%[acc]] \n\t" \ + "ldr %[a], [%[in]], #4 \n\t" \ + "ldr %[b], [%[acc]] \n\t" \ "umaal %[b], %[carry], %[scalar], %[a] \n\t" \ - "str.w %[b], [%[acc]], #4 \n\t" + "str %[b], [%[acc]], #4 \n\t" #define MULADDC_X1_STOP \ : [a] "=&r" (tmp_a), \ @@ -777,14 +777,14 @@ * 2 cycles, while subsequent loads/stores are single-cycle. */ #define MULADDC_X2_CORE \ ".p2align 2 \n\t" \ - "ldr.w %[a0], [%[in]], #+8 \n\t" \ - "ldr.w %[b0], [%[acc]], #+8 \n\t" \ - "ldr.w %[a1], [%[in], #-4] \n\t" \ - "ldr.w %[b1], [%[acc], #-4] \n\t" \ + "ldr %[a0], [%[in]], #+8 \n\t" \ + "ldr %[b0], [%[acc]], #+8 \n\t" \ + "ldr %[a1], [%[in], #-4] \n\t" \ + "ldr %[b1], [%[acc], #-4] \n\t" \ "umaal %[b0], %[carry], %[scalar], %[a0] \n\t" \ "umaal %[b1], %[carry], %[scalar], %[a1] \n\t" \ - "str.w %[b0], [%[acc], #-8] \n\t" \ - "str.w %[b1], [%[acc], #-4] \n\t" + "str %[b0], [%[acc], #-8] \n\t" \ + "str %[b1], [%[acc], #-4] \n\t" #define MULADDC_X2_STOP \ : [a0] "=&r" (tmp_a0), \ diff --git a/tests/scripts/all.sh b/tests/scripts/all.sh index e5d3afc7b..7915dfba0 100755 --- a/tests/scripts/all.sh +++ b/tests/scripts/all.sh @@ -2948,6 +2948,7 @@ component_build_armcc () { scripts/config.py baremetal # armc[56] don't support SHA-512 intrinsics scripts/config.py unset MBEDTLS_SHA512_USE_A64_CRYPTO_IF_PRESENT + scripts/config.py set MBEDTLS_HAVE_ASM make CC="$ARMC5_CC" AR="$ARMC5_AR" WARNING_CFLAGS='--strict --c99' lib @@ -2956,20 +2957,25 @@ component_build_armcc () { make clean + # Compile with -O1 since some Arm inline assembly is disabled for -O0. + # ARM Compiler 6 - Target ARMv7-A - armc6_build_test "--target=arm-arm-none-eabi -march=armv7-a" + armc6_build_test "-O1 --target=arm-arm-none-eabi -march=armv7-a" # ARM Compiler 6 - Target ARMv7-M - armc6_build_test "--target=arm-arm-none-eabi -march=armv7-m" + armc6_build_test "-O1 --target=arm-arm-none-eabi -march=armv7-m" + + # ARM Compiler 6 - Target ARMv7-M+DSP + armc6_build_test "-O1 --target=arm-arm-none-eabi -march=armv7-m+dsp" # ARM Compiler 6 - Target ARMv8-A - AArch32 - armc6_build_test "--target=arm-arm-none-eabi -march=armv8.2-a" + armc6_build_test "-O1 --target=arm-arm-none-eabi -march=armv8.2-a" # ARM Compiler 6 - Target ARMv8-M - armc6_build_test "--target=arm-arm-none-eabi -march=armv8-m.main" + armc6_build_test "-O1 --target=arm-arm-none-eabi -march=armv8-m.main" # ARM Compiler 6 - Target ARMv8.2-A - AArch64 - armc6_build_test "--target=aarch64-arm-none-eabi -march=armv8.2-a+crypto" + armc6_build_test "-O1 --target=aarch64-arm-none-eabi -march=armv8.2-a+crypto" } component_test_tls13_only () {