Contents    Page-10    Prev    Next    Page+10    Index   

Trace of Expression Algorithm


>(genarith '(* (+ a b) 3))

  1> (GENARITH (* (+ A B) 3))
    2> (GENARITH (+ A B))
      3> (GENARITH A)
        4> (GENLOAD A R1)
   LOAD  A,R1
        <4 (GENLOAD R1)
      <3 (GENARITH R1)
      3> (GENARITH B)
        4> (GENLOAD B R2)
   LOAD  B,R2
        <4 (GENLOAD R2)
      <3 (GENARITH R2)
      3> (GENOP + R1 R2)
   ADD   R1,R2
      <3 (GENOP R2)
    <2 (GENARITH R2)
    2> (GENARITH 3)
      3> (GENLOAD 3 R3)
   LOAD  3,R3
      <3 (GENLOAD R3)
    <2 (GENARITH R3)
    2> (GENOP * R2 R3)
   MUL   R2,R3
    <2 (GENOP R3)
  <1 (GENARITH R3)
R3