@@ -1087,7 +1087,7 @@ struct InstOpConversion : public ConvertToLLVMPattern {
10871087 auto oneC = initBuilder.create <LLVM::ConstantOp>(
10881088 op->getLoc (), i32Ty, rewriter.getI32IntegerAttr (1 ));
10891089 auto regNull =
1090- initBuilder.create <LLVM::NullOp >(op->getLoc (), regStatePtrTy);
1090+ initBuilder.create <LLVM::ZeroOp >(op->getLoc (), regStatePtrTy);
10911091 auto regGep = initBuilder.create <LLVM::GEPOp>(
10921092 op->getLoc (), regStatePtrTy, regNull, ArrayRef<Value>({oneC}));
10931093 auto regSize =
@@ -1157,7 +1157,7 @@ struct InstOpConversion : public ConvertToLLVMPattern {
11571157 op.getLoc (), i32Ty, rewriter.getI32IntegerAttr (1 ));
11581158 auto twoC = initBuilder.create <LLVM::ConstantOp>(
11591159 op.getLoc (), i64Ty, rewriter.getI32IntegerAttr (2 ));
1160- auto nullPtr = initBuilder.create <LLVM::NullOp >(
1160+ auto nullPtr = initBuilder.create <LLVM::ZeroOp >(
11611161 op.getLoc (), LLVM::LLVMPointerType::get (underlyingTy));
11621162 auto sizeGep = initBuilder.create <LLVM::GEPOp>(
11631163 op.getLoc (), LLVM::LLVMPointerType::get (underlyingTy), nullPtr,
@@ -1210,7 +1210,7 @@ struct InstOpConversion : public ConvertToLLVMPattern {
12101210 rewriter.getI32IntegerAttr (arrayTy.getNumElements ()));
12111211
12121212 // Get element size.
1213- auto null = initBuilder.create <LLVM::NullOp >(
1213+ auto null = initBuilder.create <LLVM::ZeroOp >(
12141214 op.getLoc (), LLVM::LLVMPointerType::get (arrayTy));
12151215 auto gepFirst = initBuilder.create <LLVM::GEPOp>(
12161216 op.getLoc (), LLVM::LLVMPointerType::get (arrayTy.getElementType ()),
@@ -1227,7 +1227,7 @@ struct InstOpConversion : public ConvertToLLVMPattern {
12271227 auto zeroC = initBuilder.create <LLVM::ConstantOp>(
12281228 op.getLoc (), i32Ty, rewriter.getI32IntegerAttr (0 ));
12291229
1230- auto null = initBuilder.create <LLVM::NullOp >(
1230+ auto null = initBuilder.create <LLVM::ZeroOp >(
12311231 op.getLoc (), LLVM::LLVMPointerType::get (structTy));
12321232 for (size_t i = 0 , e = structTy.getBody ().size (); i < e; ++i) {
12331233 auto oneC = initBuilder.create <LLVM::ConstantOp>(
@@ -1243,7 +1243,7 @@ struct InstOpConversion : public ConvertToLLVMPattern {
12431243 op.getLoc (), i32Ty, gepElem);
12441244
12451245 // Get element size.
1246- auto elemNull = initBuilder.create <LLVM::NullOp >(
1246+ auto elemNull = initBuilder.create <LLVM::ZeroOp >(
12471247 op.getLoc (), LLVM::LLVMPointerType::get (structTy.getBody ()[i]));
12481248 auto gepElemSize = initBuilder.create <LLVM::GEPOp>(
12491249 op.getLoc (), LLVM::LLVMPointerType::get (structTy.getBody ()[i]),
@@ -1283,7 +1283,7 @@ struct InstOpConversion : public ConvertToLLVMPattern {
12831283
12841284 // Malloc space for the process state.
12851285 auto procStateNullPtr =
1286- initBuilder.create <LLVM::NullOp >(op->getLoc (), procStatePtrTy);
1286+ initBuilder.create <LLVM::ZeroOp >(op->getLoc (), procStatePtrTy);
12871287 auto procStateGep = initBuilder.create <LLVM::GEPOp>(
12881288 op->getLoc (), procStatePtrTy, procStateNullPtr,
12891289 ArrayRef<Value>({oneC}));
@@ -1307,7 +1307,7 @@ struct InstOpConversion : public ConvertToLLVMPattern {
13071307
13081308 // Malloc space for the senses table.
13091309 auto sensesNullPtr =
1310- initBuilder.create <LLVM::NullOp >(op->getLoc (), sensesPtrTy);
1310+ initBuilder.create <LLVM::ZeroOp >(op->getLoc (), sensesPtrTy);
13111311 auto sensesGep = initBuilder.create <LLVM::GEPOp>(
13121312 op->getLoc (), sensesPtrTy, sensesNullPtr, ArrayRef<Value>({oneC}));
13131313 auto sensesSize =
@@ -1512,7 +1512,7 @@ struct DrvOpConversion : public ConvertToLLVMPattern {
15121512 op->getLoc (), i32Ty, rewriter.getI32IntegerAttr (1 ));
15131513 auto eightC = rewriter.create <LLVM::ConstantOp>(
15141514 op->getLoc (), i64Ty, rewriter.getI64IntegerAttr (8 ));
1515- auto nullPtr = rewriter.create <LLVM::NullOp >(op->getLoc (), llvmPtrTy);
1515+ auto nullPtr = rewriter.create <LLVM::ZeroOp >(op->getLoc (), llvmPtrTy);
15161516 auto gepOne = rewriter.create <LLVM::GEPOp>(
15171517 op->getLoc (), llvmPtrTy, nullPtr, ArrayRef<Value>(oneC));
15181518 auto toInt =
0 commit comments