You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Mbed TLS version (number or commit id): 3.6.2
Operating system and version: Ubuntu
Configuration (if not default, please attach mbedtls_config.h): default
Compiler and options (if you used a pre-built binary, please indicate how you obtained it):
Additional environment information:
Expected behavior
Actual behavior
Steps to reproduce
Additional information
A workaround is to add __attribute__((nomips16)) to the function mbedtls_mpi_core_mla in bignum_core
The text was updated successfully, but these errors were encountered:
Summary
When compiling with mips16 the assembler in bn_muil.h https://github.com/Mbed-TLS/mbedtls/blob/main/library/bn_mul.h
fails with error messsage:
[12%] Building C object library/CMakeFiles/mbedcrypto.dir/bignum_core.c.o cd /workspace/2UGW/ugw_sw/openwrt/build_dir/xRX500_BootCore/build_dir/target-mips_24kc_musl/mbedtls-3.6.2/library && /workspace/2UGW/ugw_sw/openwrt/build_dir/xRX500_BootCore/staging_dir/toolchain-mips_24kc_gcc-8.3.0_musl/bin/mips-openwrt-linux-musl-gcc -Dmbedcrypto_EXPORTS -I/workspace/2UGW/ugw_sw/openwrt/build_dir/xRX500_BootCore/build_dir/target-mips_24kc_musl/mbedtls-3.6.2/include -I/workspace/2UGW/ugw_sw/openwrt/build_dir/xRX500_BootCore/build_dir/target-mips_24kc_musl/mbedtls-3.6.2/library -I/workspace/2UGW/ugw_sw/openwrt/build_dir/xRX500_BootCore/build_dir/target-mips_24kc_musl/mbedtls-3.6.2/3rdparty/everest/include -I/workspace/2UGW/ugw_sw/openwrt/build_dir/xRX500_BootCore/build_dir/target-mips_24kc_musl/mbedtls-3.6.2/3rdparty/p256-m -I/workspace/2UGW/ugw_sw/openwrt/build_dir/xRX500_BootCore/build_dir/target-mips_24kc_musl/mbedtls-3.6.2/3rdparty/p256-m/p256-m -pipe -mno-branch-likely -mips32r2 -mtune=24kc -g -fno-caller-saves -fno-plt -fhonour-copts -Wno-error=unused-but-set-variable -Wno-error=unused-result - msoft-float -mips16 -minterlink-mips16 -fmacro-prefix-map=/workspace/2UGW/ugw_sw/openwrt/build_dir/xRX500_BootCore/build_dir/target-mips_24kc_musl/mbedtls-3.6.2=mbedtls-3.6.2 -Wformat -Werror=format-security -fpic -fstack-protector-strong -D_FORTIFY_SOURCE=2 -Wl,-z,now -Wl,-z,relro -Wall -Wextra -Wwrite-strings -Wmissing-prototypes -Wformat=2 -Wno-format-nonliteral -Wvla -Wlogical-op -Wshadow -Wformat-signedness -Wformat-overflow=2 -Wformat-truncation -Werror -Wmissing-declarations -O2 -fPIC -std=c99 -o CMakeFiles/mbedcrypto.dir/bignum_core.c.o -c /workspace/2UGW/ugw_sw/openwrt/build_dir/xRX500_BootCore/build_dir/target-mips_24kc_musl/mbedtls-3.6.2/library/bignum_core.c {standard input}: Assembler messages: {standard input}:2982: Error: invalid operands
lw $10,24($sp)'{standard input}:2983: Error: invalid operands
lw $11,28($sp)' {standard input}:2984: Error: invalid operands
lw $12,32($sp)'{standard input}:2985: Error: invalid operands
lw $13,64($sp)' {standard input}:2986: Error: invalid operands
lw $14,0($10)'{standard input}:2987: Error: invalid operands
multu $13,$14' {standard input}:2988: Error: unrecognized opcode
addi $10,$10,4'{standard input}:2989: Error: invalid operands
mflo $14' ...
System information
Mbed TLS version (number or commit id): 3.6.2
Operating system and version: Ubuntu
Configuration (if not default, please attach
mbedtls_config.h
): defaultCompiler and options (if you used a pre-built binary, please indicate how you obtained it):
Additional environment information:
Expected behavior
Actual behavior
Steps to reproduce
Additional information
A workaround is to add
__attribute__((nomips16))
to the functionmbedtls_mpi_core_mla
in bignum_coreThe text was updated successfully, but these errors were encountered: