[PyTorch] Fix missing move in torch::jit::Lexer::next (#64653)
authorScott Wolchok <swolchok@fb.com>
Fri, 10 Sep 2021 01:53:36 +0000 (18:53 -0700)
committerFacebook GitHub Bot <facebook-github-bot@users.noreply.github.com>
Fri, 10 Sep 2021 02:01:07 +0000 (19:01 -0700)
commit88c0ea91317b48a3f2fc07a0229f51977b3cc7e6
tree2cd96ce83ad006bd397d4e062919c8a03adb09f0
parentb7b4f63bbc271d9c491e7639e9a0117cd19d4ec8
[PyTorch] Fix missing move in torch::jit::Lexer::next (#64653)

Summary:
Pull Request resolved: https://github.com/pytorch/pytorch/pull/64653

Saves shared_ptr refcount inc/dec in SourceRange.
ghstack-source-id: 137608457

Test Plan: Profiled startup of framework overheads benchmark from high_per_models; self time spent in next() is way down.

Reviewed By: dhruvbird

Differential Revision: D30739240

fbshipit-source-id: ac455678c9d46e657b111d3788d4369983028674
torch/csrc/jit/frontend/lexer.h