Ignore:
Timestamp:
Apr 25, 2017, 2:33:31 PM (2 years ago)
Author:
nmedfort
Message:

Changes towards separate compilation

File:
1 edited

Legend:

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

    r5418 r5425  
    2323#include <pablo/pablo_toolchain.h>                 // for pablo_function_passes
    2424#include <pablo/pe_zeroes.h>
    25 #include <kernels/toolchain.h>
     25#include <toolchain/toolchain.h>
    2626#include "kernels/streamset.h"                     // for CircularBuffer
    27 #include <kernels/pipeline.h>
    2827#include "llvm/ADT/StringRef.h"                    // for StringRef
    2928#include "llvm/IR/CallingConv.h"                   // for ::C
     
    358357void u8u16PipelineGen(ParabixDriver & pxDriver) {
    359358   
    360     IDISA::IDISA_Builder * iBuilder = pxDriver.getIDISA_Builder();
     359    auto iBuilder = pxDriver.getIDISA_Builder();
    361360    Module * mod = iBuilder->getModule();
    362361   
    363362    const unsigned segmentSize = codegen::SegmentSize;
    364363    const unsigned bufferSegments = codegen::ThreadNum+1;
    365    
    366     assert (iBuilder);
    367    
    368364    Type * const voidTy = iBuilder->getVoidTy();
    369365    Type * const bitBlockType = iBuilder->getBitBlockType();
     
    436432typedef void (*u8u16FunctionType)(uint32_t fd, char * output_data);
    437433
    438 u8u16FunctionType u8u16CodeGen(void) {
    439     LLVMContext TheContext;                           
    440     Module * M = new Module("u8u16", TheContext);
    441     IDISA::IDISA_Builder * idb = IDISA::GetIDISA_Builder(M);
    442     ParabixDriver pxDriver(idb);
    443    
     434u8u16FunctionType u8u16CodeGen() {
     435    ParabixDriver pxDriver("u8u16");
    444436    if (enableAVXdel && AVX2_available() && codegen::BlockSize==256) {
    445         //u8u16PipelineAVX2(M, idb)
    446437        u8u16PipelineAVX2Gen(pxDriver);
    447     }
    448     else{
    449         //u8u16Pipeline(M, idb);
     438    } else{
    450439        u8u16PipelineGen(pxDriver);
    451440    }
    452     u8u16FunctionType main = reinterpret_cast<u8u16FunctionType>(pxDriver.getPointerToMain());
    453 
    454     delete idb;
    455     return main;
     441    return reinterpret_cast<u8u16FunctionType>(pxDriver.getPointerToMain());
    456442}
    457443
Note: See TracChangeset for help on using the changeset viewer.