Skip to content

Commit

Permalink
Integrate LLVM
Browse files Browse the repository at this point in the history
LLVM: 26ee894
MHLO: 4805d8498dfb81566076f56f52273b426c1cc5bf

Per: llvm#1178 (comment)
  • Loading branch information
silvasean committed May 9, 2023
1 parent 51e0a2c commit d7614c2
Show file tree
Hide file tree
Showing 6 changed files with 113 additions and 113 deletions.
2 changes: 1 addition & 1 deletion externals/llvm-project
Submodule llvm-project updated 2266 files
2 changes: 1 addition & 1 deletion externals/mlir-hlo
Submodule mlir-hlo updated 127 files
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,7 @@ TosaOp CreateOpAndInfer(PatternRewriter &rewriter, Location loc, Type result_ty,
if (shapeInterface
.inferReturnTypeComponents(op.getContext(), op.getLoc(),
op->getOperands(), op->getAttrDictionary(),
op->getPropertiesStorage(),
op->getRegions(), returnedShapes)
.failed())
return op;
Expand Down
8 changes: 4 additions & 4 deletions lib/Dialect/Torch/IR/TorchOps.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1508,7 +1508,7 @@ void AtenSortIntOp::getCanonicalizationPatterns(RewritePatternSet &patterns,

LogicalResult NonValueTensorLiteralOp::inferReturnTypes(
MLIRContext *context, std::optional<Location> location, ValueRange operands,
DictionaryAttr attributes, RegionRange regions,
DictionaryAttr attributes, OpaqueProperties properties, RegionRange regions,
SmallVectorImpl<Type> &inferredReturnTypes) {
auto attr = attributes.get("value").dyn_cast_or_null<ElementsAttr>();
if (!attr)
Expand Down Expand Up @@ -1548,7 +1548,7 @@ bool NonValueTensorLiteralOp::isCompatibleReturnTypes(TypeRange inferred,

LogicalResult ValueTensorLiteralOp::inferReturnTypes(
MLIRContext *context, std::optional<Location> location, ValueRange operands,
DictionaryAttr attributes, RegionRange regions,
DictionaryAttr attributes, OpaqueProperties properties, RegionRange regions,
SmallVectorImpl<Type> &inferredReturnTypes) {
auto attr = attributes.get("value").dyn_cast_or_null<ElementsAttr>();
if (!attr)
Expand Down Expand Up @@ -1622,7 +1622,7 @@ LogicalResult CopyToNonValueTensorOp::verify() {

LogicalResult CopyToNonValueTensorOp::inferReturnTypes(
MLIRContext *context, std::optional<Location> location, ValueRange operands,
DictionaryAttr attributes, RegionRange regions,
DictionaryAttr attributes, OpaqueProperties properties, RegionRange regions,
SmallVectorImpl<Type> &inferredReturnTypes) {
auto resultType = operands[0].getType().cast<ValueTensorType>();
inferredReturnTypes.push_back(resultType.getWithoutValueSemantics());
Expand All @@ -1649,7 +1649,7 @@ LogicalResult CopyToValueTensorOp::verify() {

LogicalResult CopyToValueTensorOp::inferReturnTypes(
MLIRContext *context, std::optional<Location> location, ValueRange operands,
DictionaryAttr attributes, RegionRange regions,
DictionaryAttr attributes, OpaqueProperties properties, RegionRange regions,
SmallVectorImpl<Type> &inferredReturnTypes) {
auto resultType = operands[0].getType().cast<NonValueTensorType>();
inferredReturnTypes.push_back(resultType.getWithValueSemantics());
Expand Down
2 changes: 1 addition & 1 deletion lib/Dialect/TorchConversion/IR/TorchConversionOps.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ LogicalResult ToBuiltinTensorOp::verify() {

LogicalResult ToBuiltinTensorOp::inferReturnTypes(
MLIRContext *context, std::optional<Location> location, ValueRange operands,
DictionaryAttr attributes, RegionRange regions,
DictionaryAttr attributes, OpaqueProperties properties, RegionRange regions,
SmallVectorImpl<Type> &inferredReturnTypes) {
auto resultType =
operands[0].getType().cast<Torch::ValueTensorType>().toBuiltinTensor();
Expand Down
Loading

0 comments on commit d7614c2

Please sign in to comment.