Update git-svnrevert to accept git and svn revisions

Interchangeable commit ids can now be used on this git-svnrevert, which
will figure out what kind of commit that is (if you use format rNNNN for SVN
commits) and make sure the right ids are used in the right places.

It's a little bit more robust and user-friendly.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@219290 91177308-0d34-0410-b5e6-96231b3b80d8
Grab the TargetRegisterInfo off of the subtarget from the
MachineFunction rather than a lookup on the TargetMachine
to avoid unnecessary lookups.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@219291 91177308-0d34-0410-b5e6-96231b3b80d8
Use the TargetLowering information we already have on the
SelectionDAG in SelectionDAGBuilder rather than going through
the TargetMachine for lookup.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@219292 91177308-0d34-0410-b5e6-96231b3b80d8