Bugfixes to allow kernel reuse in fusion