Add ability to inject custom lowering passes from user code

This is the first in a series of pull request that work towards type legalization for better vectorization of non-native vectors, and to support pnacl's 128-bit hard requirement. 

This PR adds the ability to append custom passes to lowering from user code. For us it will be useful for writing tests. Seemed like a worthy front-end feature in general though, so I pulled it out into its own PR for consideration.
I'd like to make a small change here: I think that if I were writing a custom lowering pass, it would be nice to see the lowering before and after the custom passes even at debug(1). Or even the lowering between every custom pass. More specifically, it would be nice *not* to have to turn on debug == 2 to see all the custom lowerings. In some programs, debug == 2 generates waaay too much IR. In that situation, debugging the custom lowering becomes really unwieldy.

If no objection, I will make this change later today and then I think this would be ready to merge?