[SROA] Use the members for New{Begin,End}Offset in the rewrite helpers
authorChandler Carruth <chandlerc@gmail.com>
Wed, 26 Feb 2014 04:25:04 +0000 (04:25 +0000)
committerChandler Carruth <chandlerc@gmail.com>
Wed, 26 Feb 2014 04:25:04 +0000 (04:25 +0000)
commitf11f7a49b9ea1c5be61ad5ddca3eb0d42891f422
tree37ba1d0399ce1a3ded2cb21391d9b4b5cf6be44b
parentabd2555e365dc24ce71a1ef1afaf7d687d04a208
[SROA] Use the members for New{Begin,End}Offset in the rewrite helpers
rather than passing them as arguments.

While I generally prefer actual arguments, in this case the readability
loss is substantial. By using members we avoid repeatedly calculating
the offsets, and once we're using members it is useful to ensure that
those names *always* refer to the original-alloca-relative new offset
for a rewritten slice.

No functionality changed. Follow-up refactoring, all toward getting the
address space patch merged.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@202228 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/Scalar/SROA.cpp