@@ -479,8 +479,9 @@ class PrunedLiveness {
479479 llvm::SmallMapVector<SILInstruction *, bool , 8 > users;
480480
481481public:
482- PrunedLiveness (SmallVectorImpl<SILBasicBlock *> *discoveredBlocks = nullptr )
483- : liveBlocks(1 /* num bits*/ , discoveredBlocks) {}
482+ PrunedLiveness (SILFunction *function,
483+ SmallVectorImpl<SILBasicBlock *> *discoveredBlocks = nullptr )
484+ : liveBlocks(function, discoveredBlocks) {}
484485
485486 bool empty () const {
486487 assert (!liveBlocks.empty () || users.empty ());
@@ -745,8 +746,9 @@ class SSAPrunedLiveness : public PrunedLiveRange<SSAPrunedLiveness> {
745746
746747public:
747748 SSAPrunedLiveness (
749+ SILFunction *function,
748750 SmallVectorImpl<SILBasicBlock *> *discoveredBlocks = nullptr )
749- : PrunedLiveRange(discoveredBlocks) {}
751+ : PrunedLiveRange(function, discoveredBlocks) {}
750752
751753 SILValue getDef () const { return def; }
752754
@@ -815,8 +817,8 @@ class MultiDefPrunedLiveness : public PrunedLiveRange<MultiDefPrunedLiveness> {
815817 MultiDefPrunedLiveness (
816818 SILFunction *function,
817819 SmallVectorImpl<SILBasicBlock *> *discoveredBlocks = nullptr )
818- : PrunedLiveRange(discoveredBlocks), defs(function), defBlocks(function) {
819- }
820+ : PrunedLiveRange(function, discoveredBlocks), defs(function),
821+ defBlocks (function) { }
820822
821823 void clear () {
822824 llvm_unreachable (" multi-def liveness cannot be reused" );
@@ -886,10 +888,11 @@ class DiagnosticPrunedLiveness : public SSAPrunedLiveness {
886888
887889public:
888890 DiagnosticPrunedLiveness (
891+ SILFunction *function,
889892 SmallVectorImpl<SILBasicBlock *> *discoveredBlocks = nullptr ,
890893 SmallSetVector<SILInstruction *, 8 > *nonLifetimeEndingUsesInLiveOut =
891894 nullptr )
892- : SSAPrunedLiveness(discoveredBlocks),
895+ : SSAPrunedLiveness(function, discoveredBlocks),
893896 nonLifetimeEndingUsesInLiveOut (nonLifetimeEndingUsesInLiveOut) {}
894897
895898 void clear () {
0 commit comments