16.02.2013 Aufrufe

24531904_j

24531904_j

24531904_j

MEHR ANZEIGEN
WENIGER ANZEIGEN

Sie wollen auch ein ePaper? Erhöhen Sie die Reichweite Ihrer Titel.

YUMPU macht aus Druck-PDFs automatisch weboptimierte ePaper, die Google liebt.

操作 : if (PR[qp]) {<br />

if (p1 == p2)<br />

illegal_operation_fault();<br />

tmp_nat = (register_form ? GR[r 2].nat : 0) || GR[r 3].nat;<br />

if (register_form)<br />

tmp_src = GR[r 2 ];<br />

else if (imm8_form)<br />

tmp_src = sign_ext(imm 8 , 8);<br />

else // parallel_inequality_form<br />

tmp_src = 0;<br />

if (crel == ‘eq’) tmp_rel = tmp_src{31:0} == GR[r 3 ]{31:0};<br />

else if (crel == ‘ne’) tmp_rel = tmp_src{31:0} != GR[r 3 ]{31:0};<br />

else if (crel == ‘lt’)<br />

tmp_rel = lesser_signed(sign_ext(tmp_src, 32),<br />

sign_ext(GR[r 3 ], 32));<br />

else if (crel == ‘le’)<br />

tmp_rel = lesser_equal_signed(sign_ext(tmp_src, 32),<br />

sign_ext(GR[r 3 ], 32));<br />

else if (crel == ‘gt’)<br />

tmp_rel = greater_signed(sign_ext(tmp_src, 32),<br />

sign_ext(GR[r 3 ], 32));<br />

else if (crel == ‘ge’)<br />

tmp_rel = greater_equal_signed(sign_ext(tmp_src, 32),<br />

sign_ext(GR[r 3 ], 32));<br />

else if (crel == ‘ltu’)<br />

tmp_rel = lesser(zero_ext(tmp_src, 32),<br />

zero_ext(GR[r 3 ], 32));<br />

else if (crel == ‘leu’)<br />

tmp_rel = lesser_equal(zero_ext(tmp_src, 32),<br />

zero_ext(GR[r 3 ], 32));<br />

else if (crel == ‘gtu’)<br />

tmp_rel = greater(zero_ext(tmp_src, 32),<br />

zero_ext(GR[r 3 ], 32));<br />

else // ‘geu’<br />

tmp_rel = greater_equal(zero_ext(tmp_src, 32),<br />

zero_ext(GR[r 3 ], 32));<br />

cmp4<br />

switch (ctype) {<br />

case ‘and’: // and-type compare<br />

if (tmp_nat || !tmp_rel) {<br />

PR[p 1 ] = 0;<br />

PR[p 2 ] = 0;<br />

}<br />

break;<br />

case ‘or’: // or-type compare<br />

if (!tmp_nat && tmp_rel) {<br />

PR[p 1 ] = 1;<br />

PR[p 2 ] = 1;<br />

}<br />

break;<br />

case ‘or.andcm’: // or.andcm-type compare<br />

if (!tmp_nat && tmp_rel) {<br />

PR[p 1 ] = 1;<br />

PR[p 2 ] = 0;<br />

}<br />

break;<br />

case ‘unc’: // unc-type compare<br />

default: // normal compare<br />

if (tmp_nat) {<br />

3:38 第 3 巻 : 命令リファレンス

Hurra! Ihre Datei wurde hochgeladen und ist bereit für die Veröffentlichung.

Erfolgreich gespeichert!

Leider ist etwas schief gelaufen!