diff --git a/src/darwin/Framework/CHIP/MTRDevice.mm b/src/darwin/Framework/CHIP/MTRDevice.mm
index 9e2d169..c58c766 100644
--- a/src/darwin/Framework/CHIP/MTRDevice.mm
+++ b/src/darwin/Framework/CHIP/MTRDevice.mm
@@ -1035,9 +1035,11 @@
     MTRWeakReference<MTRDevice *> * weakSelf = [MTRWeakReference weakReferenceWithObject:self];
     dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t) (kTimeToWaitBeforeMarkingUnreachableAfterSettingUpSubscription * NSEC_PER_SEC)), self.queue, ^{
         MTRDevice * strongSelf = weakSelf.strongObject;
-        os_unfair_lock_lock(&strongSelf->_lock);
-        [strongSelf _markDeviceAsUnreachableIfNotSusbcribed];
-        os_unfair_lock_unlock(&strongSelf->_lock);
+        if (strongSelf != nil) {
+            os_unfair_lock_lock(&strongSelf->_lock);
+            [strongSelf _markDeviceAsUnreachableIfNotSusbcribed];
+            os_unfair_lock_unlock(&strongSelf->_lock);
+        }
     });
 
     [_deviceController
diff --git a/src/darwin/Framework/CHIP/MTRDeviceControllerDataStore.mm b/src/darwin/Framework/CHIP/MTRDeviceControllerDataStore.mm
index 6ed3b00..2b7c8d5 100644
--- a/src/darwin/Framework/CHIP/MTRDeviceControllerDataStore.mm
+++ b/src/darwin/Framework/CHIP/MTRDeviceControllerDataStore.mm
@@ -125,6 +125,12 @@
 
     __block id resumptionNodeList;
     dispatch_sync(_storageDelegateQueue, ^{
+        @autoreleasepool {
+            resumptionNodeList = [_storageDelegate controller:_controller
+                                                  valueForKey:sResumptionNodeListKey
+                                                securityLevel:MTRStorageSecurityLevelSecure
+                                                  sharingType:MTRStorageSharingTypeNotShared];
+        }
         resumptionNodeList = [_storageDelegate controller:_controller
                                               valueForKey:sResumptionNodeListKey
                                             securityLevel:MTRStorageSecurityLevelSecure
@@ -145,6 +151,7 @@
     } else {
         _nodesWithResumptionInfo = [[NSMutableArray alloc] init];
     }
+
     return self;
 }
 
@@ -233,10 +240,12 @@
 {
     __block id data;
     dispatch_sync(_storageDelegateQueue, ^{
-        data = [_storageDelegate controller:_controller
-                                valueForKey:sLastLocallyUsedNOCKey
-                              securityLevel:MTRStorageSecurityLevelSecure
-                                sharingType:MTRStorageSharingTypeNotShared];
+        @autoreleasepool {
+            data = [_storageDelegate controller:_controller
+                                    valueForKey:sLastLocallyUsedNOCKey
+                                  securityLevel:MTRStorageSecurityLevelSecure
+                                    sharingType:MTRStorageSharingTypeNotShared];
+        }
     });
 
     if (data == nil) {
@@ -259,10 +268,12 @@
 
     __block id resumptionInfo;
     dispatch_sync(_storageDelegateQueue, ^{
-        resumptionInfo = [_storageDelegate controller:_controller
-                                          valueForKey:key
-                                        securityLevel:MTRStorageSecurityLevelSecure
-                                          sharingType:MTRStorageSharingTypeNotShared];
+        @autoreleasepool {
+            resumptionInfo = [_storageDelegate controller:_controller
+                                              valueForKey:key
+                                            securityLevel:MTRStorageSecurityLevelSecure
+                                              sharingType:MTRStorageSharingTypeNotShared];
+        }
     });
 
     if (resumptionInfo == nil) {
@@ -304,11 +315,12 @@
 - (id)_fetchAttributeCacheValueForKey:(NSString *)key expectedClass:(Class)expectedClass;
 {
     id data;
-    data = [_storageDelegate controller:_controller
-                            valueForKey:key
-                          securityLevel:MTRStorageSecurityLevelSecure
-                            sharingType:MTRStorageSharingTypeNotShared];
-
+    @autoreleasepool {
+        data = [_storageDelegate controller:_controller
+                                valueForKey:key
+                              securityLevel:MTRStorageSecurityLevelSecure
+                                sharingType:MTRStorageSharingTypeNotShared];
+    }
     if (data == nil) {
         return nil;
     }
diff --git a/src/platform/Darwin/PlatformManagerImpl.cpp b/src/platform/Darwin/PlatformManagerImpl.cpp
index 5db5c69..0edc652 100644
--- a/src/platform/Darwin/PlatformManagerImpl.cpp
+++ b/src/platform/Darwin/PlatformManagerImpl.cpp
@@ -169,7 +169,10 @@
 {
     if (mWorkQueue == nullptr)
     {
-        mWorkQueue = dispatch_queue_create(CHIP_CONTROLLER_QUEUE, DISPATCH_QUEUE_SERIAL_WITH_AUTORELEASE_POOL);
+        mWorkQueue =
+            dispatch_queue_create(CHIP_CONTROLLER_QUEUE,
+                                  dispatch_queue_attr_make_with_qos_class(DISPATCH_QUEUE_SERIAL_WITH_AUTORELEASE_POOL,
+                                                                          QOS_CLASS_USER_INITIATED, QOS_MIN_RELATIVE_PRIORITY));
         dispatch_suspend(mWorkQueue);
         dispatch_queue_set_specific(mWorkQueue, &sPlatformManagerKey, this, nullptr);
         mIsWorkQueueSuspended = true;
