• Alexandre Duret-Lutz's avatar
    [buddy] Inline the "is bdd constant" check performed in copies/constructors. · 1d1872ab
    Alexandre Duret-Lutz authored
    This avoids a library call to bdd_addref or bdd_delref.
    
    * src/kernel.c (bdd_delref_nc, bdd_addref_nc): New function,
    that work only on BDD that are not constant.
    * src/cpext.cxx (bdd::operator=): Move...
    * src/bdd.hh (bdd::operator=): ... here.
    (bdd::bdd, bdd::~bdd, bdd::operator=): Inline the "is bdd constant"
    check and call bdd_delref_nc/bdd_addref_nc only otherwise.
    1d1872ab
kernel.c 40.8 KB