Factor out common DBLU code