Changeset dcddf66 in git for kernel/GBEngine/kutil.cc


Ignore:
Timestamp:
Jun 7, 2017, 3:37:38 PM (7 years ago)
Author:
Hans Schoenemann <hannes@…>
Branches:
(u'fieker-DuVal', '117eb8c30fc9e991c4decca4832b1d19036c4c65')(u'spielwiese', 'b4f17ed1d25f93d46dbe29e4b499baecc2fd51bb')
Children:
5361740013273f5e2466bb8da3694c915d880fa8
Parents:
ce1b53088c76b35ea7757238cd2eb7a737b01645
Message:
minor opt: p_GetComp -> __p_GetComp if there is a component
File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/GBEngine/kutil.cc

    rce1b53 rdcddf66  
    148148static inline int pDivCompRing(poly p, poly q)
    149149{
    150   if (pGetComp(p) == pGetComp(q))
     150  if ((currRing->pCompIndex < 0)
     151  || (__p_GetComp(p,currRing) == __p_GetComp(q,currRing)))
    151152  {
    152153    BOOLEAN a=FALSE, b=FALSE;
     
    186187static inline int pDivComp(poly p, poly q)
    187188{
    188   if (pGetComp(p) == pGetComp(q))
     189  if ((currRing->pCompIndex < 0)
     190  || (__p_GetComp(p,currRing) == __p_GetComp(q,currRing)))
    189191  {
    190192#ifdef HAVE_RATGRING
     
    331333void cancelunit (LObject* L,BOOLEAN inNF)
    332334{
    333   int  i;
    334   poly h;
    335335  number lc;
    336336
     
    340340  ring r = L->tailRing;
    341341  poly p = L->GetLmTailRing();
     342  if(p_GetComp(p, r) != 0 && !p_OneComp(p, r)) return;
    342343
    343344  if (rField_is_Ring(r) /*&& (rHasLocalOrMixedOrdering(r))*/)
     
    354355#endif
    355356
    356   if(p_GetComp(p, r) != 0 && !p_OneComp(p, r)) return;
    357357
    358358//    for(i=r->N;i>0;i--)
     
    360360//      if ((p_GetExp(p,i,r)>0) && (rIsPolyVar(i, r)==TRUE)) return;
    361361//    }
    362   h = pNext(p);
     362  poly h = pNext(p);
     363  int  i;
    363364
    364365  if(rField_is_Ring(currRing))
     
    393394        if (L->p != NULL && pNext(L->p) != NULL)
    394395          pNext(L->p) = NULL;
    395 
    396396        return;
    397397      }
     
    46944694      if (rRing_has_Comp(currRing) && rRing_has_Comp(strat->tailRing))
    46954695      {
    4696         p_SetComp(tmp, p_GetComp(p, strat->tailRing), currRing);
     4696        p_SetComp(tmp, __p_GetComp(p, strat->tailRing), currRing);
    46974697      }
    46984698      p_Setm(tmp, currRing);
     
    47764776      if (rRing_has_Comp(currRing) && rRing_has_Comp(strat->tailRing))
    47774777      {
    4778         p_SetComp(tmp, p_GetComp(p, strat->tailRing), currRing);
     4778        p_SetComp(tmp, __p_GetComp(p, strat->tailRing), currRing);
    47794779      }
    47804780      p_Setm(tmp, currRing);
     
    71567156  pWrite(sig);
    71577157#endif
    7158   int comp = p_GetComp(sig, currRing);
     7158  int comp = __p_GetComp(sig, currRing);
    71597159  int min, max;
    71607160  if (comp<=1)
     
    76017601        if (Ln.p!=NULL)
    76027602        {
    7603           if (p_GetComp(Ln.p,currRing)> strat->syzComp) break;
     7603          if (__p_GetComp(Ln.p,currRing)> strat->syzComp) break;
    76047604        }
    76057605        else
    76067606        {
    7607           if (p_GetComp(Ln.t_p,strat->tailRing)> strat->syzComp) break;
     7607          if (__p_GetComp(Ln.t_p,strat->tailRing)> strat->syzComp) break;
    76087608        }
    76097609      }
     
    77097709        if (Ln.p!=NULL)
    77107710        {
    7711           if (p_GetComp(Ln.p,currRing)> strat->syzComp) break;
     7711          if (__p_GetComp(Ln.p,currRing)> strat->syzComp) break;
    77127712        }
    77137713        else
    77147714        {
    7715           if (p_GetComp(Ln.t_p,strat->tailRing)> strat->syzComp) break;
     7715          if (__p_GetComp(Ln.t_p,strat->tailRing)> strat->syzComp) break;
    77167716        }
    77177717      }
     
    84578457          p_ExpVectorCopy(q,strat->S[i],currRing);
    84588458          q               = p_Neg (q, currRing);
    8459           p_SetCompP (q, p_GetComp(strat->sig[k], currRing), currRing);
     8459          p_SetCompP (q, __p_GetComp(strat->sig[k], currRing), currRing);
    84608460          Q.sig = p_Add_q (Q.sig, q, currRing);
    84618461          Q.sevSig  = p_GetShortExpVector(Q.sig,currRing);
     
    85018501      p_ExpVectorCopy(q,strat->L[strat->Ll].p,currRing);
    85028502      q               = p_Neg (q, currRing);
    8503       p_SetCompP (q, p_GetComp(strat->sig[k], currRing), currRing);
     8503      p_SetCompP (q, __p_GetComp(strat->sig[k], currRing), currRing);
    85048504      Q.sig = p_Add_q (Q.sig, q, currRing);
    85058505      Q.sevSig = p_GetShortExpVector(Q.sig,currRing);
Note: See TracChangeset for help on using the changeset viewer.