Skip to content

Commit 62fac7c

Browse files
authored
Update LLVM SHA (#566)
Co-authored-by: [email protected] <Nishant Patel>
1 parent 048a585 commit 62fac7c

File tree

17 files changed

+38
-18
lines changed

17 files changed

+38
-18
lines changed

build_tools/llvm_version.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
ac1ec9e2904a696e360b40572c3b3c29d67981ef
1+
3f36d2d579d8b0e8824d9dd99bfa79f456858f88

lib/Conversion/PTensorToLinalg/PTensorToLinalg.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -231,7 +231,7 @@ struct ARangeLowering
231231
};
232232

233233
rewriter.replaceOpWithNewOp<::mlir::linalg::GenericOp>(
234-
op, retRtTyp, ::llvm::None, tensor, maps, iterators, body);
234+
op, retRtTyp, ::std::nullopt, tensor, maps, iterators, body);
235235

236236
return ::mlir::success();
237237
}

lib/Transforms/InsertGPUAllocs.cpp

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -95,14 +95,14 @@ class InsertGPUAllocsPass final
9595
// for its origin later in the code
9696
else if (auto call = mlir::dyn_cast<mlir::func::CallOp>(op)) {
9797
mlir::SmallVector<mlir::Value, 4> ret;
98-
for (auto arg : call.operands()) {
98+
for (auto arg : call.getOperands()) {
9999
if (arg.getType().isa<mlir::MemRefType>())
100100
ret.emplace_back(arg);
101101
}
102102
return std::move(ret);
103103
} else {
104104
op->emitError("Uhhandled mem op in gpu region");
105-
return llvm::None;
105+
return std::nullopt;
106106
}
107107
};
108108

@@ -120,7 +120,7 @@ class InsertGPUAllocsPass final
120120
return true;
121121
}
122122
if (auto call = mlir::dyn_cast<mlir::func::CallOp>(op)) {
123-
for (auto arg : call.operands()) {
123+
for (auto arg : call.getOperands()) {
124124
if (arg.getType().isa<mlir::MemRefType>())
125125
return true;
126126
}
@@ -256,7 +256,7 @@ class InsertGPUAllocsPass final
256256
bool hostShared = access.hostRead || access.hostWrite;
257257
auto gpuAlloc = builder.create<mlir::gpu::AllocOp>(
258258
loc, alloc.getType(), /*asyncToken*/ nullptr,
259-
/*asyncDependencies*/ llvm::None, alloc.getDynamicSizes(),
259+
/*asyncDependencies*/ std::nullopt, alloc.getDynamicSizes(),
260260
alloc.getSymbolOperands(), hostShared);
261261
auto allocResult = gpuAlloc.getResult(0);
262262
alloc->replaceAllUsesWith(gpuAlloc);
@@ -266,7 +266,7 @@ class InsertGPUAllocsPass final
266266
// TODO(nbpatel): Need a DeviceToHost copy and then free the device
267267
// memory.
268268
if (!access.hostWrite)
269-
builder.create<mlir::gpu::DeallocOp>(loc, llvm::None, allocResult);
269+
builder.create<mlir::gpu::DeallocOp>(loc, std::nullopt, allocResult);
270270
}
271271
}
272272

@@ -296,8 +296,8 @@ class InsertGPUAllocsPass final
296296
bool hostShared = access.hostRead || access.hostWrite;
297297
auto gpuAlloc = builder.create<mlir::gpu::AllocOp>(
298298
loc, allocType, /*asyncToken*/ nullptr,
299-
/*asyncDependencies*/ llvm::None, dims,
300-
/*symbolOperands*/ llvm::None, hostShared);
299+
/*asyncDependencies*/ std::nullopt, dims,
300+
/*symbolOperands*/ std::nullopt, hostShared);
301301
auto allocResult = gpuAlloc.getResult(0);
302302
if (access.hostWrite && access.deviceRead) {
303303
auto copy =
@@ -314,7 +314,7 @@ class InsertGPUAllocsPass final
314314
if (access.hostRead && access.deviceWrite) {
315315
builder.create<mlir::memref::CopyOp>(loc, allocResult, op);
316316
}
317-
builder.create<mlir::gpu::DeallocOp>(loc, llvm::None, allocResult);
317+
builder.create<mlir::gpu::DeallocOp>(loc, std::nullopt, allocResult);
318318
} else if (m_clientAPI == "vulkan") {
319319
auto gpuAlloc =
320320
builder.create<mlir::memref::AllocOp>(loc, allocType, dims);

lib/Transforms/SetSPIRVAbiAttribute.cpp

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ class SetSPIRVAbiAttributePass
5656
auto attrName =
5757
mlir::StringAttr::get(context, mlir::spirv::getEntryPointABIAttrName());
5858
if (m_clientAPI == "opencl") {
59-
auto abi = mlir::spirv::getEntryPointABIAttr(llvm::None, context);
59+
auto abi = mlir::spirv::getEntryPointABIAttr(context);
6060
for (auto gpuFunc : gpuModule.getOps<mlir::gpu::GPUFuncOp>()) {
6161
if (!mlir::gpu::GPUDialect::isKernel(gpuFunc) ||
6262
gpuFunc->getAttr(attrName))
@@ -65,8 +65,7 @@ class SetSPIRVAbiAttributePass
6565
gpuFunc->setAttr(attrName, abi);
6666
}
6767
} else if (m_clientAPI == "vulkan") {
68-
llvm::SmallVector<int32_t, 3> workgroupVec{1, 1, 1};
69-
auto abi = mlir::spirv::getEntryPointABIAttr(workgroupVec, context);
68+
auto abi = mlir::spirv::getEntryPointABIAttr(context);
7069
for (auto gpuFunc : gpuModule.getOps<mlir::gpu::GPUFuncOp>()) {
7170
if (!mlir::gpu::GPUDialect::isKernel(gpuFunc) ||
7271
gpuFunc->getAttr(attrName))

lib/Utils/TypeConversion.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ void imex::populateControlFlowTypeConversionRewritesAndTarget(
5757
typeConverter.isLegal(&op.getBody()))
5858
return true;
5959

60-
return llvm::None;
60+
return std::nullopt;
6161
});
6262

6363
mlir::populateCallOpTypeConversionPattern(patterns, typeConverter);
@@ -66,7 +66,7 @@ void imex::populateControlFlowTypeConversionRewritesAndTarget(
6666
if (typeConverter.isLegal(op))
6767
return true;
6868

69-
return llvm::None;
69+
return std::nullopt;
7070
});
7171

7272
mlir::populateBranchOpInterfaceTypeConversionPattern(patterns, typeConverter);
@@ -84,6 +84,6 @@ void imex::populateControlFlowTypeConversionRewritesAndTarget(
8484
mlir::isLegalForReturnOpTypeConversionPattern(op, typeConverter))
8585
return true;
8686

87-
return llvm::None;
87+
return std::nullopt;
8888
});
8989
}

test/Jax/gordon/linalg-to-cpu.pp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,8 @@
2020
convert-math-to-llvm
2121
convert-complex-to-llvm
2222
convert-index-to-llvm
23+
expand-strided-metadata
24+
lower-affine
2325
convert-memref-to-llvm
2426
convert-func-to-llvm
2527
reconcile-unrealized-casts)

test/Jax/gordon/linalg-to-llvm.pp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,8 @@
3939
convert-func-to-llvm
4040
convert-math-to-llvm
4141
convert-gpux-to-llvm
42+
expand-strided-metadata
43+
lower-affine
4244
convert-memref-to-llvm
4345
reconcile-unrealized-casts)
4446
// End

test/Jax/janet/linalg-to-cpu.pp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,8 @@
2020
convert-math-to-llvm
2121
convert-complex-to-llvm
2222
convert-index-to-llvm
23+
expand-strided-metadata
24+
lower-affine
2325
convert-memref-to-llvm
2426
convert-func-to-llvm
2527
reconcile-unrealized-casts)

test/Jax/janet/linalg-to-llvm.pp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,8 @@
3939
convert-func-to-llvm
4040
convert-math-to-llvm
4141
convert-gpux-to-llvm
42+
expand-strided-metadata
43+
lower-affine
4244
convert-memref-to-llvm
4345
reconcile-unrealized-casts)
4446
// End

test/Jax/qoc/linalg-to-cpu.pp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,8 @@
2121
convert-complex-to-llvm
2222
convert-vector-to-llvm
2323
convert-index-to-llvm
24+
expand-strided-metadata
25+
lower-affine
2426
convert-memref-to-llvm
2527
convert-func-to-llvm
2628
reconcile-unrealized-casts)

0 commit comments

Comments
 (0)