Conversion of C to Assembly language

liunx

Guest
Hi everyone,<br /><br />I am trying to hand compile a C code to assembly language.<br /><br />im having trouble to code only this part of my C code<br /><br /><!--c1--><div class='codetop'>CODE</div><div class='codemain'><!--ec1--><br /><br />while ((dividend > divisor) && !(divisor & 0x40000000 )){<br />     blaa..blaa<br /><br />}<br />    <br /><br /><!--c2--></div><!--ec2--><br /><br />here is the assembly language code i have written<br />dividend = a1<br />divisor = a2<br /><br /><!--c1--><div class='codetop'>CODE</div><div class='codemain'><!--ec1--><br /><br />cmp    a1, a2                      ;comparing the value in register a1 and a2<br />blt       exit_loop                  ;if a1 <  a2 exit the while loop<br />and     a2, #0x40000000      ;bitwise AND the value in a2 with 0x40000000<br />(?????????)                         ;the question is how to translate "!" in assembly language <br /><br /><!--c2--></div><!--ec2--><br /><br /><br />hope anybody who read this understand my problem. Can anybody plz help me on this.<br /><br /><br /><br /><br /><br /><br /><br /><br />
</div>
 
Top