File tree Expand file tree Collapse file tree 1 file changed +9
-2
lines changed Expand file tree Collapse file tree 1 file changed +9
-2
lines changed Original file line number Diff line number Diff line change @@ -770,8 +770,15 @@ class RefCounts {
770
770
771
771
void setPureSwiftDeallocation (bool nonobjc) {
772
772
auto oldbits = refCounts.load (SWIFT_MEMORY_ORDER_CONSUME);
773
- // Immortal and no objc complications share a bit, so don't let setting
774
- // the complications one clear the immmortal one
773
+
774
+ // Having a side table precludes using bits this way, but also precludes
775
+ // doing the pure Swift deallocation path. So trying to turn this off
776
+ // on something that has a side table is a noop
777
+ if (!nonobjc && oldbits.hasSideTable ()) {
778
+ return ;
779
+ }
780
+ // Immortal and no objc complications share a bit, so don't let setting
781
+ // the complications one clear the immmortal one
775
782
if (oldbits.isImmortal (true ) || oldbits.pureSwiftDeallocation () == nonobjc){
776
783
assert (!oldbits.hasSideTable ());
777
784
return ;
You can’t perform that action at this time.
0 commit comments