OSDN Git Service

[MachineOutliner][NFC] Move decrement logic to OutlinedFunction
authorJessica Paquette <jpaquette@apple.com>
Tue, 17 Oct 2017 19:03:23 +0000 (19:03 +0000)
committerJessica Paquette <jpaquette@apple.com>
Tue, 17 Oct 2017 19:03:23 +0000 (19:03 +0000)
commit3b848cff066cb97e331a57a74ffa384fd00468bc
treee6951fca9910ded36a0173a31a4943e7aa8195a0
parent6f0af489ee2ee144e62b7feccc25efd3f8d997d3
[MachineOutliner][NFC] Move decrement logic to OutlinedFunction

This commit moves the decrement logic for outlined functions into the class,
and makes OccurrenceCount private. It can now be accessed via
getOccurrenceCount().

This makes it more difficult to accidentally introduce bugs by incorrectly
decrementing the occurrence count on OutlinedFunctions.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@316020 91177308-0d34-0410-b5e6-96231b3b80d8
lib/CodeGen/MachineOutliner.cpp