Integrate LLVM at llvm/llvm-project@c85b6bf33c
Updates LLVM usage to match [c85b6bf33c47](https://github.com/llvm/llvm-project/commit/c85b6bf33c47) PiperOrigin-RevId: 354136678
This commit is contained in:
parent
d77c9ad6fa
commit
c653db73c5
|
@ -15,9 +15,9 @@
|
||||||
|
|
||||||
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
|
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
|
||||||
|
|
||||||
LLVM_COMMIT = "f3f3c9c2549a268e602be8730990b552e30cc932"
|
LLVM_COMMIT = "c85b6bf33c473633c9873b600f8a31fa55464e1e"
|
||||||
|
|
||||||
LLVM_SHA256 = "3faf880bf9562c9b63de8b7d2f15146e2e691a471f66903bc07c29ffaf6b9df3"
|
LLVM_SHA256 = "21710892f964bd781f95b559741264b026580e3544c500782b69b63f00b1c68d"
|
||||||
|
|
||||||
LLVM_BAZEL_TAG = "llvm-project-{commit}".format(commit = LLVM_COMMIT)
|
LLVM_BAZEL_TAG = "llvm-project-{commit}".format(commit = LLVM_COMMIT)
|
||||||
|
|
||||||
|
|
|
@ -1,2 +1,2 @@
|
||||||
f3f3c9c2549a268e602be8730990b552e30cc932
|
c85b6bf33c473633c9873b600f8a31fa55464e1e
|
||||||
|
|
||||||
|
|
|
@ -284,7 +284,7 @@ class HloToLhloDynamicBroadcastInDimOpConverter
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
SmallVector<Value, 2> sizes, strides;
|
SmallVector<OpFoldResult, 2> sizes, strides;
|
||||||
sizes.reserve(result_rank);
|
sizes.reserve(result_rank);
|
||||||
strides.reserve(result_rank);
|
strides.reserve(result_rank);
|
||||||
|
|
||||||
|
@ -319,8 +319,9 @@ class HloToLhloDynamicBroadcastInDimOpConverter
|
||||||
int dim = it->second;
|
int dim = it->second;
|
||||||
Value is_expansion = b->create<CmpIOp>(
|
Value is_expansion = b->create<CmpIOp>(
|
||||||
loc, CmpIPredicate::slt, operand_sizes[dim], result_dim_size);
|
loc, CmpIPredicate::slt, operand_sizes[dim], result_dim_size);
|
||||||
strides.push_back(b->create<mlir::SelectOp>(loc, is_expansion, zero,
|
Value select = b->create<mlir::SelectOp>(loc, is_expansion, zero,
|
||||||
operand_strides[dim]));
|
operand_strides[dim]);
|
||||||
|
strides.push_back(select);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Type-erased memref type with static rank, dynamic sizes and strides.
|
// Type-erased memref type with static rank, dynamic sizes and strides.
|
||||||
|
@ -333,13 +334,9 @@ class HloToLhloDynamicBroadcastInDimOpConverter
|
||||||
makeStridedLinearLayoutMap(dynamic_layout,
|
makeStridedLinearLayoutMap(dynamic_layout,
|
||||||
/*offset=*/0, b->getContext()));
|
/*offset=*/0, b->getContext()));
|
||||||
|
|
||||||
SmallVector<int64_t, 2> static_sizes(sizes.size(),
|
|
||||||
ShapedType::kDynamicSize);
|
|
||||||
SmallVector<int64_t, 2> static_strides(strides.size(),
|
|
||||||
ShapedType::kDynamicStrideOrOffset);
|
|
||||||
auto transformed_operand = b->create<MemRefReinterpretCastOp>(
|
auto transformed_operand = b->create<MemRefReinterpretCastOp>(
|
||||||
loc, type_erased_memref_type, operand, /*offset=*/0, static_sizes,
|
loc, type_erased_memref_type, operand,
|
||||||
static_strides, llvm::None, sizes, strides);
|
/*offset=*/b->getI64IntegerAttr(0), sizes, strides);
|
||||||
return transformed_operand;
|
return transformed_operand;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue