mirror of
https://gitlab.com/libeigen/eigen.git
synced 2025-08-12 03:39:01 +08:00
Fix a bug in a packed block type in TensorContractionThreadPool
This commit is contained in:
parent
d38e6fbc27
commit
f35b9ab510
@ -750,7 +750,7 @@ struct TensorEvaluator<const TensorContractionOp<Indices, LeftArgType, RightArgT
|
|||||||
template <typename EvalCtx>
|
template <typename EvalCtx>
|
||||||
struct ThreadLocalBlocksAllocator</*pack_rhs=*/false, EvalCtx> {
|
struct ThreadLocalBlocksAllocator</*pack_rhs=*/false, EvalCtx> {
|
||||||
static void allocate(EvalCtx& ctx, Blocks& blocks) {
|
static void allocate(EvalCtx& ctx, Blocks& blocks) {
|
||||||
std::vector<RhsBlock> lhs_blocks;
|
std::vector<LhsBlock> lhs_blocks;
|
||||||
BlockMemHandle mem_handle = ctx.kernel_.allocateSlices(
|
BlockMemHandle mem_handle = ctx.kernel_.allocateSlices(
|
||||||
ctx.device_,
|
ctx.device_,
|
||||||
/*num_lhs=*/ctx.gm_,
|
/*num_lhs=*/ctx.gm_,
|
||||||
@ -758,7 +758,7 @@ struct TensorEvaluator<const TensorContractionOp<Indices, LeftArgType, RightArgT
|
|||||||
/*num_slices=*/1,
|
/*num_slices=*/1,
|
||||||
/*lhs_blocks=*/&lhs_blocks, /*rhs_blocks=*/nullptr);
|
/*lhs_blocks=*/&lhs_blocks, /*rhs_blocks=*/nullptr);
|
||||||
|
|
||||||
blocks = ThreadLocalBlocks<RhsBlock>(std::move(mem_handle),
|
blocks = ThreadLocalBlocks<LhsBlock>(std::move(mem_handle),
|
||||||
std::move(lhs_blocks));
|
std::move(lhs_blocks));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user