URL
https://opencores.org/ocsvn/quark/quark/trunk
Subversion Repositories quark
[/] [quark/] [trunk/] [01_SysRequirements/] [03_InternalRequirements/] [01_MatlabAlgorithmDesign/] [DIV_tb.m] - Rev 3
Go to most recent revision | Compare with Previous | Blame | View Log
function DIV_tb() div_alu = 0; div_real = 0; for y = 1:65535 for x = 1:65535 div_alu = DIV(x,y); div_real = fix(x/y); if (div_alu ~= div_real) disp(strcat('not ok! div_alu = ',num2str(div_alu),'; div_real = ',num2str(div_real))); return; else disp(strcat('opcode ok! div_alu = ',num2str(div_alu),'; div_real = ',num2str(div_real))); end end end end
Go to most recent revision | Compare with Previous | Blame | View Log