Add support for IP masks

This pull request adds support for IP prefix masking.

It also refactors LocalCompiler to use PrefixTable instead of PosNeg -- a more flexible representation that will enable us to use more kinds of patterns in the future.
That's a good thing to note in the code where appropriate (where would that be?), but my comment was more superficial than that. There's a lot of commented code in this file, and I wanted to make sure it wasn't sticking around for a reason before deleting it.