Skip to content

Commit 7329532

Browse files
committed
Update on "[ET-VK] Introduce generalized shaders for transfer ops and use it for select and slice"
## Changes * Introduce `transfer_buffer.glsl` and `transfer_texture.glsl`, and `Transfer.cpp` which generalizes shaders where each element of the output is copied from a unique element of the input. * Update `Slice.cpp` and `Select.cpp` to use `Transfer.cpp` * Remove old implementations of slice and select ## Motivation With this new implementation, the op can now support both buffers and textures of any packing. There are also benefits of code consolidation. Differential Revision: [D75686050](https://our.internmc.facebook.com/intern/diff/D75686050/) [ghstack-poisoned]
2 parents aa7d137 + cc24f0b commit 7329532

File tree

1 file changed

+0
-4
lines changed

1 file changed

+0
-4
lines changed

backends/vulkan/runtime/graph/ops/DispatchNode.cpp

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -75,10 +75,6 @@ void DispatchNode::encode(ComputeGraph* graph) {
7575
}
7676

7777
void DispatchNode::write_push_constant_data() {
78-
if (push_constants_.empty()) {
79-
return;
80-
}
81-
8278
push_constants_offset_ = 0;
8379
for (const auto& push_constant : push_constants_) {
8480
push_constants_offset_ += push_constant.write(

0 commit comments

Comments
 (0)