added if statements to stages to handle bubbles and stalls
minor fixes
Merge pull request #17 from acbrewbaker/master

minor changes