These changes provide some improvements that potentially can to speed up the work of bitcoind. Cause i dont have enough resources i haven't done any tests, so i dont have any results which can approve that these changes can increase the speed of work.
SetTip method The main idea of this change is if we want to add a new block to our vector and this block can to join to the active chain, we just add it and dont rebuild the whole vector.
GetAncestor method If the previous block contains in our active chain in the vector, we can obtain the needed block from the vector and dont have to walk throught the references.