Address more clang & clang-tidy warnings.
* Add more const where we can.
* Use contains() rather than count() to check for existence.
* Stop looking up options through llvm::cl::getRegisteredOptions() when
we can use their corresponding variables instead.
* Stop creating unused .blend PHI nodes.
* Enforce W^X in our loader.
* Use remove_if() rather than stable_partition() to remove released
semaphores.
* Ensure driver::CompilerInfo is always initialized.