klen (13.02.2020 17:00, просмотров: 404) ответил Evgeny_CD на GigaDevice GD32VF103 (ядро RISC-V Bumblebee ->)- Single-cycle hardware multiplier and Multi-cycles hardware divider support;
и делит и умножает ->
int z[2] ;
nop();
z[0] = z[1]*z[0] ;
nop();
z[1] = z[0]/z[1] ;
nop();
main():
08000722: addi sp,sp,-16
08000724: sw ra,12(sp)
08000726: nop
81 z[0] = z[1]*z[0] ;
08000728: lui a5,0x20002
0800072c: mv ra,a5
08000730: lw a3,0(ra)
08000734: lw a4,4(ra)
08000738: mul t0,a4,a3
0800073c: sw t0,0(ra)
20 __inline_static__ void nop() { asm volatile ("nop" ::: "memory"); }
08000740: nop
83 z[1] = z[0]/z[1] ;
08000742: lw t2,4(ra)
08000746: lw t1,0(ra)
0800074a: div a0,t1,t2
0800074e: sw a0,4(ra)
08000752: nop