Fix bug where we fold more than one dimension of a func.
Fix handling of extern stages.
Update two tests for the new bounds inference behavior.
Added a complex multi-stage reduction test.

It recursively expands its bounds.
Reduced reduction_chain test verbosity
Made bounds inference once again use output buffer constraints.