Now I use DS5 to develop an assembly crypto code, instructions like AESE are used in my code, after assign the CPU = 8-A.64.crypto, the code could be built, but when i debug the code in
8-A.64.crypto, the code could be built, but when i debug the code in
the FVP VE_AEMv8x1, the program crash, do anybody now how to use instructions in ARMv8 ?
Hi cyao,
Use of the crypto instructions requires the SIMD/floating point unit to be enabled. Make sure CPACR_EL1.FPEN is set before executing the AES instructions. (You'll probably need an ISB after writing to CPACR_EL1.)
Also, Crypto is optional in ARMv8-A (hence it needing a special flag to the build tools). The model can be configured to include the Crypto support or not. If the model is configured to not include the support, the instructions will UNDEF.
Hi, peterrielly
Thanks for your reply, it seems like the problem is that i did't configure the system register CPACR_EL1, but i am not familiar with the system register configuration, could you share me an example to init the cpu system registers before
use the AES instructions.
Hi, Martin Weidmann
now i only configure CPU = 8-A.64.crypto with armasm, the AES insturction can be built with armasm
8-A.64.crypto with armasm, the AES insturction can be built with armasm
but for armclang, i did't now how to configure the Crypto flag.Do you have any idea?
Thanks for your reply.
Try "-fpu=crypto-neon-fp-armv8", more details on this page:
-fpu=crypto-neon-fp-armv8
ARM Compiler armclang Reference Guide : 1.24 -mfpu