Changeset 4282


Ignore:
Timestamp:
Oct 31, 2014, 8:11:20 PM (4 years ago)
Author:
nmedfort
Message:

Made boost optional but base compilation cost is worse without it.

Location:
icGREP/icgrep-devel/icgrep/pablo
Files:
2 edited

Legend:

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

    r4280 r4282  
    11#include "useanalysis.h"
     2#ifdef USE_BOOST
    23#include <queue>
    3 #include <pablo/printer_pablos.h>
    4 #include <fstream>
    54
    65using namespace boost;
     
    87namespace pablo {
    98
    10 #ifdef USE_BOOST
    119bool UseAnalysis::optimize(PabloBlock & block) {
    1210    UseAnalysis analyzer;
     
    1614    return true;
    1715}
    18 
    1916
    2017void UseAnalysis::cse(PabloBlock & block) {
     
    9895
    9996Statement * UseAnalysis::findLastStatement(const PredecessorSet & predecessors, StatementList & statements) {
    100 
    10197    for (auto ri = statements.rbegin(); ri != statements.rend(); ++ri) {
    10298        Statement * stmt = *ri;
     
    117113        }
    118114    }
    119 
    120115    return nullptr;
    121 
    122116}
    123117
     
    246240    return f->second;
    247241}
     242}
    248243#endif
    249 
    250 }
  • icGREP/icgrep-devel/icgrep/pablo/pablo_compiler.cpp

    r4281 r4282  
    235235    #endif
    236236
     237
     238
    237239    //Create a verifier.  The verifier will print an error message if our module is malformed in any way.
    238240    #ifdef USE_LLVM_3_5
     
    253255#ifdef USE_LLVM_3_4
    254256    fpm.add(new DataLayout(*mExecutionEngine->getDataLayout()));
     257#endif
     258#ifndef USE_BOOST
     259    fpm.add(createCorrelatedValuePropagationPass());
     260    fpm.add(createEarlyCSEPass());
     261    fpm.add(createInstructionCombiningPass());    //Simple peephole optimizations and bit-twiddling.
     262    fpm.add(createReassociatePass());             //Reassociate expressions.
     263    fpm.add(createGVNPass());                     //Eliminate common subexpressions.
    255264#endif
    256265    fpm.doInitialization();
Note: See TracChangeset for help on using the changeset viewer.