Ignore:
Timestamp:
Aug 26, 2015, 1:41:38 PM (4 years ago)
Author:
cameron
Message:

Clean ups for compilation with gcc 4.8

File:
1 edited

Legend:

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

    r4749 r4750  
    8888                                                   /*Linkage=*/ GlobalValue::PrivateLinkage,
    8989                                                   /*Initializer=*/ regNameData);
    90     Value * regStrPtr = mBuilder->CreateGEP(regStrVar, {mBuilder->getInt64(0), mBuilder->getInt32(0)});
    91     mBuilder->CreateCall(mPrintRegisterFunction, {regStrPtr, bitblockValue});
     90    Value * regStrPtr = mBuilder->CreateGEP(regStrVar, std::vector<Value *>({mBuilder->getInt64(0), mBuilder->getInt32(0)}));
     91    mBuilder->CreateCall(mPrintRegisterFunction, std::vector<Value *>({regStrPtr, bitblockValue}));
    9292}
    9393
     
    178178    mInputType = PointerType::get(StructType::get(mMod->getContext(), std::vector<Type *>(function.getNumOfParameters(), mBitBlockType)), 0);
    179179    Type * outputType = PointerType::get(StructType::get(mMod->getContext(), std::vector<Type *>(function.getNumOfResults(), mBitBlockType)), 0);
    180     FunctionType * functionType = FunctionType::get(Type::getVoidTy(mMod->getContext()), {{mInputType, outputType}}, false);
     180    FunctionType * functionType = FunctionType::get(Type::getVoidTy(mMod->getContext()), std::vector<Type *>({mInputType, outputType}), false);
    181181
    182182
    183183    //Starts on process_block
    184184    SmallVector<AttributeSet, 3> Attrs;
    185     Attrs.push_back(AttributeSet::get(mMod->getContext(), ~0U, { Attribute::NoUnwind, Attribute::UWTable }));
    186     Attrs.push_back(AttributeSet::get(mMod->getContext(), 1U, { Attribute::ReadOnly, Attribute::NoCapture }));
    187     Attrs.push_back(AttributeSet::get(mMod->getContext(), 2U, { Attribute::ReadNone, Attribute::NoCapture }));
     185    Attrs.push_back(AttributeSet::get(mMod->getContext(), ~0U, std::vector<Attribute::AttrKind>({ Attribute::NoUnwind, Attribute::UWTable })));
     186    Attrs.push_back(AttributeSet::get(mMod->getContext(), 1U, std::vector<Attribute::AttrKind>({ Attribute::ReadOnly, Attribute::NoCapture })));
     187    Attrs.push_back(AttributeSet::get(mMod->getContext(), 2U, std::vector<Attribute::AttrKind>({ Attribute::ReadNone, Attribute::NoCapture })));
    188188    AttributeSet AttrSet = AttributeSet::get(mMod->getContext(), Attrs);
    189189
     
    427427        //Starts on process_block
    428428        SmallVector<AttributeSet, 3> Attrs;
    429         Attrs.push_back(AttributeSet::get(mMod->getContext(), 1U, { Attribute::ReadOnly, Attribute::NoCapture }));
    430         Attrs.push_back(AttributeSet::get(mMod->getContext(), 2U, { Attribute::ReadNone, Attribute::NoCapture }));
     429        Attrs.push_back(AttributeSet::get(mMod->getContext(), 1U, std::vector<Attribute::AttrKind>({ Attribute::ReadOnly, Attribute::NoCapture })));
     430        Attrs.push_back(AttributeSet::get(mMod->getContext(), 2U, std::vector<Attribute::AttrKind>({ Attribute::ReadNone, Attribute::NoCapture })));
    431431        AttributeSet AttrSet = AttributeSet::get(mMod->getContext(), Attrs);
    432432
     
    440440        AllocaInst * outputStruct = mBuilder->CreateAlloca(outputType);
    441441        mBuilder->CreateCall2(externalFunction, mInputAddressPtr, outputStruct);
    442         Value * outputPtr = mBuilder->CreateGEP(outputStruct, { mBuilder->getInt32(0), mBuilder->getInt32(0) });
     442        Value * outputPtr = mBuilder->CreateGEP(outputStruct, std::vector<Value *>({ mBuilder->getInt32(0), mBuilder->getInt32(0) }));
    443443        expr = mBuilder->CreateAlignedLoad(outputPtr, BLOCK_SIZE / 8, false);
    444444    }
Note: See TracChangeset for help on using the changeset viewer.