loc mapper memoize

STUD-1048

Note, this PR has the stuff I put into the hotfixes as I was monotonically building on those but they haven't been merged to master yet. If they get merged from release before this PR, I'll rebase this one.

So, you may want to just review the last commit as the others have been reviewed in PR 1902 and 1937.

@singingwolfboy @cahrens Please review or delegate (other potential reviewers include @chrisndodge @cpennington ...)