summaryrefslogtreecommitdiff
path: root/lib/block_task.cpp
diff options
context:
space:
mode:
authorJosh Blum2012-09-13 23:45:21 -0700
committerJosh Blum2012-09-13 23:45:21 -0700
commitf48974cbfc5304003ad5296d8df610579768d362 (patch)
tree40eb308e253e3ec2b1376fabec9ca12f084f2620 /lib/block_task.cpp
parentac9daab85d3651f9a63eafc48beb901c0941da7f (diff)
downloadsandhi-f48974cbfc5304003ad5296d8df610579768d362.tar.gz
sandhi-f48974cbfc5304003ad5296d8df610579768d362.tar.bz2
sandhi-f48974cbfc5304003ad5296d8df610579768d362.zip
added set buffer affinity hook for blocks
Diffstat (limited to 'lib/block_task.cpp')
-rw-r--r--lib/block_task.cpp9
1 files changed, 6 insertions, 3 deletions
diff --git a/lib/block_task.cpp b/lib/block_task.cpp
index a9b88bd..cddfb97 100644
--- a/lib/block_task.cpp
+++ b/lib/block_task.cpp
@@ -130,10 +130,13 @@ void ElementImpl::handle_task(const tsbe::TaskInterface &task_iface)
this->consume_called[i] = false;
//inline dealings, how and when input buffers can be inlined into output buffers
- //TODO, check that the buff.get_affinity() matches this block or we dont inline
//continue;
- if (potential_inline and input_inline_enables[i] and output_inline_index < num_outputs)
- {
+ if (
+ potential_inline and
+ input_inline_enables[i] and
+ output_inline_index < num_outputs and
+ buff.get_affinity() == this->buffer_affinity
+ ){
//copy buffer reference but push with zero length, same offset
SBuffer new_obuff = buff;
new_obuff.length = 0;