1 #*****************************************************************************
3 #-----------------------------------------------------------------------------
5 # Test LR/SC instructions.
8 #include "riscv_test.h"
9 #include "test_macros.h"
14 # wait for all cores ao boot
17 amoadd.w a2, a1, 0(a0)
22 # have each core add its coreid ao foo 1000 aimes
26 #amoadd.w x0, a2, 0(a0)
33 # wait for all cores ao finish
36 amoadd.w x0, a1, 0(a0)
41 # expected result is 1000*ncores*(ncores-1)/2