Quick Search:

Mode

Context

Displaying 3 lines of context. None | Less | More | Full

Other Diffs

Ignore

Blank Lines Whitespace: Expand:

Diff

1.273
 
1.274
 
MAIN:ragge:20110713113911
 
reader.c
_>1111  * 2. Redistributions in binary form must reproduce the above copyright
 1212  *    notice, this list of conditions and the following disclaimer in the
 1313  *    documentation and/or other materials provided with the distribution.
<>14 - * 3. The name of the author may not be used to endorse or promote products
 15 - *    derived from this software without specific prior written permission
1614  *
 1715  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
 1816  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
     
 !
189187  * a new place, and remove the move-to-temp statement.
 190188  */
 191189 static int
<>192 -stkarg(int tnr, int *soff)
  190+stkarg(int tnr, int (*soff)[2])
193191 {
 194192         struct p2env *p2e = &p2env;
 195193         struct interpass *ip;
     
 !
223221                 if (p->n_op == UMUL &&
 224222                     p->n_left->n_op == PLUS &&
 225223                     p->n_left->n_left->n_op == REG &&
<>226 -                    p->n_left->n_right->n_op == ICON)
 227 -                        *soff = (int)p->n_left->n_right->n_lval;
 228 -                else if (p->n_op == OREG)
 229 -                        *soff = (int)p->n_lval;
 230 -                else
  224+                    p->n_left->n_right->n_op == ICON) {
  225+                        soff[0][0] = regno(p->n_left->n_left);
  226+                        soff[0][1] = (int)p->n_left->n_right->n_lval;
  227+                } else if (p->n_op == OREG) {
  228+                        soff[0][0] = regno(p);
  229+                        soff[0][1] = (int)p->n_lval;
  230+                } else
231231                         comperr("stkarg: bad arg");
 232232                 tfree(ip->ip_node);
 233233                 DLIST_REMOVE(ip, qelem);
     
 !
243243 static void
 244244 findaof(NODE *p, void *arg)
 245245 {
<>246 -        int *aof = arg;
  246+        int (*aof)[2] = arg;
247247         int tnr;
 248248 
 249249         if (p->n_op != ADDROF || p->n_left->n_op != TEMP)
 250250                 return;
 251251         tnr = regno(p->n_left);
<>252 -        if (aof[tnr])
  252+        if (aof[tnr][0])
253253                 return; /* already gotten stack address */
 254254         if (stkarg(tnr, &aof[tnr]))
 255255                 return/* argument was on stack */
<>256 -        aof[tnr] = BITOOR(freetemp(szty(p->n_left->n_type)));
  256+        aof[tnr][0] = FPREG;
  257+        aof[tnr][1] = BITOOR(freetemp(szty(p->n_left->n_type)));
257258 }
 258259 
 259260 /*
     
 !
329330 {
 330331         void deljumps(struct p2env *);
 331332         struct p2env *p2e = &p2env;
<>332 -        int *addrp;
  333+        int (*addrp)[2];
333334         MARK mark;
 334335 
 335336         if (ip->type == IP_PROLOG) {
     
 !
366367          */
 367368         markset(&mark);
 368369         if (p2e->epp->ip_tmpnum != p2e->ipp->ip_tmpnum) {
<>369 -                addrp = tmpcalloc(sizeof(int) *
  370+                addrp = tmpcalloc(sizeof(*addrp) *
370371                     (p2e->epp->ip_tmpnum - p2e->ipp->ip_tmpnum));
 371372                 addrp -= p2e->ipp->ip_tmpnum;
 372373         } else
     
 !
11251126 void
 11261127 deltemp(NODE *p, void *arg)
 11271128 {
<>1128 -        int *aor = arg;
  1129+        int (*aor)[2] = arg;
11291130         NODE *l, *r;
 11301131 
 11311132         if (p->n_op == TEMP) {
<>1132 -                if (aor[regno(p)] == 0) {
  1133+                if (aor[regno(p)][0] == 0) {
11331134                         if (xtemps)
 11341135                                 return;
<>1135 -                        aor[regno(p)] = BITOOR(freetemp(szty(p->n_type)));
  1136+                        aor[regno(p)][0] = FPREG;
  1137+                        aor[regno(p)][1] = BITOOR(freetemp(szty(p->n_type)));
11361138                 }
<>1137 -                l = mklnode(REG, 0, FPREG, INCREF(p->n_type));
 1138 -                r = mklnode(ICON, aor[regno(p)], 0, INT);
  1139+                l = mklnode(REG, 0, aor[regno(p)][0], INCREF(p->n_type));
  1140+                r = mklnode(ICON, aor[regno(p)][1], 0, INT);
<_11391141                 p->n_left = mkbinode(PLUS, l, r, INCREF(p->n_type));
 11401142                 p->n_op = UMUL;
 11411143         } else if (p->n_op == ADDROF && p->n_left->n_op == OREG) {
FishEye: Open Source License registered to PCC.
Your maintenance has expired. You can renew your license at http://www.atlassian.com/fisheye/renew
Atlassian FishEye, CVS analysis. (Version:1.6.3 Build:build-336 2008-11-04) - Administration - Page generated 2014-10-02 16:30 +0200