Added basic random number generator to runtime.

It's mostly thread-safe, and the quality of the randomness is merely OK.
It's a 31-bit linear congruential generator, with a small array of states
that it rotates through atomically so that threads aren't using the same
state at the same time.

The seed is set via Func::set_random_seed or halide_set_random_seed in the
runtime. The default seed is zero. In the absence of parallelism you get
the same sequence of random numbers every time.

Should be fine for imaging work.
Allow CSE lifting of casts.
rand now takes an argument, to distinguish between different random variables

Otherwise they get coalesced by CSE

Also added random ints.
Switched game of life to use random_int instead of random_float