Ignore:
Timestamp:
May 12, 2017, 4:54:11 PM (2 years ago)
Author:
nmedfort
Message:

Refactoring work + correction for getRawItemPointer

File:
1 edited

Legend:

Unmodified
Added
Removed
  • icGREP/icgrep-devel/icgrep/IR_Gen/idisa_builder.h

    r5436 r5446  
    118118    }
    119119
    120     llvm::VectorType * getStreamTy(const unsigned FieldWidth = 1) {
    121         return llvm::VectorType::get(llvm::IntegerType::getIntNTy(getContext(), FieldWidth), 0);
     120    static llvm::VectorType * getStreamTy(llvm::LLVMContext & C, const unsigned FieldWidth = 1) {
     121        return llvm::VectorType::get(llvm::IntegerType::getIntNTy(C, FieldWidth), 0);
    122122    }
    123123
    124     inline llvm::ArrayType * getStreamSetTy(const unsigned NumElements = 1, const unsigned FieldWidth = 1) {
    125         return llvm::ArrayType::get(getStreamTy(FieldWidth), NumElements);
     124    static llvm::ArrayType * getStreamSetTy(llvm::LLVMContext & C, const unsigned NumElements = 1, const unsigned FieldWidth = 1) {
     125        return llvm::ArrayType::get(getStreamTy(C, FieldWidth), NumElements);
     126    }
     127
     128    llvm::VectorType * getStreamTy(const unsigned FieldWidth = 1) {
     129        return getStreamTy(getContext(), FieldWidth);
     130    }
     131
     132    llvm::ArrayType * getStreamSetTy(const unsigned NumElements = 1, const unsigned FieldWidth = 1) {
     133        return getStreamSetTy(getContext(), NumElements, FieldWidth);
    126134    }
    127135
Note: See TracChangeset for help on using the changeset viewer.