[GPGPU] Fix depricated warning.

setAlignment(unsigned) was deprecated in commit:

0e62011df8
[Alignment][NFC] Remove dependency on GlobalObject::setAlignment(unsigned)
This commit is contained in:
Michael Kruse 2019-11-14 15:17:16 -06:00
parent 3cec2a17de
commit f7b3ae65c8
1 changed files with 1 additions and 1 deletions

View File

@ -2242,7 +2242,7 @@ void GPUNodeBuilder::createKernelVariables(ppcg_kernel *Kernel, Function *FN) {
auto GlobalVar = new GlobalVariable(
*M, ArrayTy, false, GlobalValue::InternalLinkage, 0, Var.name,
nullptr, GlobalValue::ThreadLocalMode::NotThreadLocal, 3);
GlobalVar->setAlignment(EleTy->getPrimitiveSizeInBits() / 8);
GlobalVar->setAlignment(llvm::Align(EleTy->getPrimitiveSizeInBits() / 8));
GlobalVar->setInitializer(Constant::getNullValue(ArrayTy));
Allocation = GlobalVar;