Ignore:
Timestamp:
Mar 18, 2016, 5:45:18 AM (4 years ago)
Author:
cameron
Message:

Remove mod64 junk

File:
1 edited

Legend:

Unmodified
Added
Removed
  • icGREP/icgrep-devel/icgrep/pablo/codegenstate.cpp

    r4959 r4980  
    144144}
    145145
    146 PabloAST * PabloBlock::createMod64Advance(PabloAST * expr, PabloAST * shiftAmount) {
    147     if (isa<Zeroes>(expr) || cast<Integer>(shiftAmount)->value() == 0) {
    148         return expr;
    149     }
    150     return insertAtInsertionPoint(new Mod64Advance(expr, shiftAmount, makeName("advance")));
    151 }
    152 
    153 PabloAST * PabloBlock::createMod64Advance(PabloAST * expr, PabloAST * shiftAmount, const std::string prefix) {
    154     if (isa<Zeroes>(expr) || cast<Integer>(shiftAmount)->value() == 0) {
    155         return expr;
    156     }
    157     return insertAtInsertionPoint(new Mod64Advance(expr, shiftAmount, makeName(prefix, false)));
    158 }
    159 
    160 PabloAST * PabloBlock::createMod64Advance(PabloAST * expr, const Integer::Type shiftAmount) {
    161     if (isa<Zeroes>(expr) || shiftAmount == 0) {
    162         return expr;
    163     }
    164     return insertAtInsertionPoint(new Mod64Advance(expr, getInteger(shiftAmount), makeName("advance")));
    165 }
    166 
    167 PabloAST * PabloBlock::createMod64Advance(PabloAST * expr, const Integer::Type shiftAmount, const std::string prefix) {
    168     if (isa<Zeroes>(expr) || shiftAmount == 0) {
    169         return renameNonNamedNode(expr, std::move(prefix));
    170     }   
    171     return insertAtInsertionPoint(new Mod64Advance(expr, getInteger(shiftAmount), makeName(prefix, false)));
    172 }
    173 
    174 PabloAST * PabloBlock::createMod64Lookahead(PabloAST * expr, PabloAST * shiftAmount) {
    175     if (isa<Zeroes>(expr) || cast<Integer>(shiftAmount)->value() == 0) {
    176         return expr;
    177     }
    178     return insertAtInsertionPoint(new Mod64Lookahead(expr, shiftAmount, makeName("advance")));
    179 }
    180 
    181 PabloAST * PabloBlock::createMod64Lookahead(PabloAST * expr, PabloAST * shiftAmount, const std::string prefix) {
    182     if (isa<Zeroes>(expr) || cast<Integer>(shiftAmount)->value() == 0) {
    183         return expr;
    184     }
    185     return insertAtInsertionPoint(new Mod64Lookahead(expr, shiftAmount, makeName(prefix, false)));
    186 }
    187 
    188 PabloAST * PabloBlock::createMod64Lookahead(PabloAST * expr, const Integer::Type shiftAmount) {
    189     if (isa<Zeroes>(expr) || shiftAmount == 0) {
    190         return expr;
    191     }
    192     return insertAtInsertionPoint(new Mod64Lookahead(expr, getInteger(shiftAmount), makeName("advance")));
    193 }
    194 
    195 PabloAST * PabloBlock::createMod64Lookahead(PabloAST * expr, const Integer::Type shiftAmount, const std::string prefix) {
    196     if (isa<Zeroes>(expr) || shiftAmount == 0) {
    197         return renameNonNamedNode(expr, std::move(prefix));
    198     }
    199     return insertAtInsertionPoint(new Mod64Lookahead(expr, getInteger(shiftAmount), makeName(prefix, false)));
    200 }
    201 
    202146PabloAST * PabloBlock::createCount(PabloAST * expr) {
    203147    assert (expr);
     
    248192    }
    249193    return insertAtInsertionPoint(new ScanThru(from, thru, makeName(prefix, false)));
    250 }
    251 
    252 PabloAST * PabloBlock::createMod64MatchStar(PabloAST * marker, PabloAST * charclass) {
    253     assert (marker && charclass);
    254     if (isa<Zeroes>(marker) || isa<Zeroes>(charclass)) {
    255         return marker;
    256     }
    257     return insertAtInsertionPoint(new Mod64MatchStar(marker, charclass, makeName("matchstar")));
    258 }
    259 
    260 PabloAST * PabloBlock::createMod64MatchStar(PabloAST * marker, PabloAST * charclass, const std::string prefix) {
    261     assert (marker && charclass);
    262     if (isa<Zeroes>(marker) || isa<Zeroes>(charclass)) {
    263         return renameNonNamedNode(marker, std::move(prefix));
    264     }
    265     return insertAtInsertionPoint(new Mod64MatchStar(marker, charclass, makeName(prefix, false)));
    266 }
    267 
    268 PabloAST * PabloBlock::createMod64ScanThru(PabloAST * from, PabloAST * thru) {
    269     assert (from && thru);
    270     if (isa<Zeroes>(from) || isa<Zeroes>(thru)) {
    271         return from;
    272     }
    273     return insertAtInsertionPoint(new Mod64ScanThru(from, thru, makeName("scanthru")));
    274 }
    275 
    276 PabloAST * PabloBlock::createMod64ScanThru(PabloAST * from, PabloAST * thru, const std::string prefix) {
    277     assert (from && thru);
    278     if (isa<Zeroes>(from) || isa<Zeroes>(thru)) {       
    279         return renameNonNamedNode(from, std::move(prefix));
    280     }
    281     return insertAtInsertionPoint(new Mod64ScanThru(from, thru, makeName(prefix, false)));
    282194}
    283195
Note: See TracChangeset for help on using the changeset viewer.