Quick Search:

Mode

Context

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

Other Diffs

Ignore

Blank Lines Whitespace: Expand:

Diff

1.28
 
1.29
 
MAIN:ragge:20101017090004
 
code.c
_>427427  * ...or similar for floats.
 428428  */
 429429 static NODE *
<>430 -bva(NODE *ap, TWORD dt, char *ot, int addto, int max)
  430+bva(NODE *ap, NODE *dp, char *ot, int addto, int max)
431431 {
 432432         NODE *cm1, *cm2, *gpo, *ofa, *l1, *qc;
 433433         TWORD nt;
     
 !
444444             buildtree(GE, gpo, bcon(max)),
 445445             buildtree(COLON, cm1, cm2));
 446446 
<>447 -        nt = (dt == DOUBLE ? DOUBLE : LONG);
  447+        nt = (dp->n_type == DOUBLE ? DOUBLE : LONG);
448448         l1 = block(NAME, NIL, NIL, nt|PTR, 0, MKAP(nt));
 449449         l1 = buildtree(CAST, l1, qc);
 450450         qc = l1->n_right;
 451451         nfree(l1->n_left);
 452452         nfree(l1);
 453453 
 454454         /* qc has now a real type, for indexing */
<>455 -        addto = dt == DOUBLE ? 2 : 1;
  455+        addto = dp->n_type == DOUBLE ? 2 : 1;
456456         qc = buildtree(UMUL, buildtree(PLUS, qc, bcon(-addto)), NIL);
 457457 
<>458 -        l1 = block(NAME, NIL, NIL, dt, 0, MKAP(BTYPE(dt)));
  458+        l1 = block(NAME, NIL, NIL, dp->n_type, dp->n_df, dp->n_ap);
459459         l1 = buildtree(CAST, l1, qc);
 460460         qc = l1->n_right;
 461461         nfree(l1->n_left);
     
 !
467467 NODE *
 468468 amd64_builtin_va_arg(NODE *f, NODE *a, TWORD t)
 469469 {
<>470 -        NODE *ap, *r;
 471 -        TWORD dt;
  470+        NODE *ap, *r, *dp;
472471 
 473472         ap = a->n_left;
<>474 -        dt = a->n_right->n_type;
 475 -        if (dt <= ULONGLONG || ISPTR(dt)) {
  473+        dp = a->n_right;
  474+        if (dp->n_type <= ULONGLONG || ISPTR(dp->n_type)) {
476475                 /* type might be in general register */
<>477 -                r = bva(ap, dt, gp_offset, 8, 48);
 478 -        } else if (dt == FLOAT || dt == DOUBLE) {
  476+                r = bva(ap, dp, gp_offset, 8, 48);
  477+        } else if (dp->n_type == FLOAT || dp->n_type == DOUBLE) {
479478                 /* Float are promoted to double here */
<>480 -                if (dt == FLOAT)
 481 -                        dt = DOUBLE;
 482 -                r = bva(ap, dt, fp_offset, 16, RSASZ/SZCHAR);
  479+                if (dp->n_type == FLOAT)
  480+                        dp->n_type = DOUBLE;
  481+                r = bva(ap, dp, fp_offset, 16, RSASZ/SZCHAR);
<_483482         } else {
 484483                 uerror("amd64_builtin_va_arg not supported type");
 485484                 goto bad;
FishEye: Open Source License registered to PCC.
Atlassian FishEye, CVS analysis. (Version:1.6.3 Build:build-336 2008-11-04) - Administration - Page generated 2014-12-21 02:09 +0100