Ignore:
Timestamp:
Dec 19, 2016, 12:58:29 PM (3 years ago)
Author:
cameron
Message:

Distinguishing between StreamType? and StreamSetType?; fixing StreamSetBlock? pointer calculations

File:
1 edited

Legend:

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

    r5217 r5229  
    163163void s2pKernel::generateDoBlockLogic(Value * self, Value * blockNo) {
    164164
    165     Value * bytePtr = iBuilder->CreateMul(blockNo, ConstantInt::get(blockNo->getType(), 8));
    166     Value * byteStream = getStreamSetBlockPtr(self, "byteStream", bytePtr);
     165    Value * byteStream = getStreamSetBlockPtr(self, "byteStream", blockNo);
    167166    Value * basisBits = getStreamSetBlockPtr(self, "basisBits", blockNo);
    168167
    169168    Value * bytepack[8];
    170169    for (unsigned i = 0; i < 8; i++) {
    171         Value * ptr = iBuilder->CreateGEP(byteStream, {iBuilder->getInt32(0), iBuilder->getInt32(i)});
     170        Value * ptr = iBuilder->CreateGEP(byteStream, {iBuilder->getInt32(0), iBuilder->getInt32(0), iBuilder->getInt32(i)});
    172171        bytepack[i] = iBuilder->CreateBlockAlignedLoad(ptr);
    173172    }
Note: See TracChangeset for help on using the changeset viewer.