Fix some issues relating to multiple update steps and tuples on gpus

The gpu code wasn't tracking tuples (because it was looking for buffers with
the same name as the pipeline node), and it wasn't correctly dealing with
multiple update steps that may alternate cpu/gpu.