Ignore:
Timestamp:
Oct 16, 2017, 6:43:14 AM (18 months ago)
Author:
cameron
Message:

Cleaning up icgrep - removing experimental nvptx and incomplete UTF-16 modes

File:
1 edited

Legend:

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

    r5620 r5692  
    11/*
    2  *  Copyright (c) 2016 International Characters.
     2 *  Copyright (c) 2014-7 International Characters.
    33 *  This software is licensed to the public under the Open Software License 3.0.
    44 *  icgrep is a trademark of International Characters.
     
    3535using namespace llvm;
    3636
    37 static cl::opt<bool> UTF_16("UTF-16", cl::desc("Regular expressions over the UTF-16 representation of Unicode."));
    38 
    3937static cl::list<std::string> inputFiles(cl::Positional, cl::desc("<regex> <input file ...>"), cl::OneOrMore);
    4038
     
    4543static cl::opt<bool> MultiGrepKernels("enable-multigrep-kernels", cl::desc("Construct separated kernels for each regular expression"));
    4644static cl::opt<int> REsPerGroup("re-num", cl::desc("Number of regular expressions processed by each kernel."), cl::init(1));
    47 
    48 static cl::opt<std::string> PTXFile("ptx", cl::desc("compiled PTX file."), cl::init(""));
    4945
    5046static std::vector<std::string> allFiles;
     
    182178
    183179    allFiles = getFullFileList(inputFiles);
     180    if ((allFiles.size() > 1) && !grep::NoFilenameFlag) {
     181        grep::WithFilenameFlag = true;
     182    }
    184183
    185184    grep::GrepEngine grepEngine;
     
    187186    if (allFiles.empty()) {
    188187
    189         grepEngine.grepCodeGen(REs, grep::Mode, UTF_16, GrepSource::StdIn);
     188        grepEngine.grepCodeGen(REs, grep::Mode, GrepSource::StdIn);
    190189        allFiles = { "-" };
    191190        grep::initFileResult(allFiles);
     
    194193    } else {
    195194               
    196         if (codegen::NVPTX) {
    197             if(PTXFile=="")
    198                 grepEngine.grepCodeGen_nvptx(REs, grep::Mode, UTF_16);
    199             for (unsigned i = 0; i != allFiles.size(); ++i) {
    200                 grepEngine.doGrep(allFiles[i], PTXFile);
    201             }
    202             return 0;
    203         } else {
    204             grepEngine.grepCodeGen(REs, grep::Mode, UTF_16, GrepSource::File);
    205         }
     195        grepEngine.grepCodeGen(REs, grep::Mode, GrepSource::File);
    206196
    207197        grep::initFileResult(allFiles);
Note: See TracChangeset for help on using the changeset viewer.