Hi there, The memory consumption in iphone is keep...
# multiplatform
s
Hi there, The memory consumption in iphone is keeps on increasing and its not releasing as like android, I have an use case wherein we open bottomsheetdialog with some ui components, when I open and close multiple times the memory consumption graph increase's as shown in below and after sometime with idle the memory get's released in case of android but not in iOS... we already tried, below flags to make GC faster and clean up memory but nothing helped here...
Copy code
//gradle.properties

kotlin.native.binary.mimallocUseCompaction=true
kotlin.native.binary.objcDisposeOnMain=false
-Xbinary=disableAllocatorOverheadEstimate=true
-Xallocator=mimalloc
kotlin.native.internal.GC.threshold=50
Xbinary=concurrentWeakSweep=true
kotlin.native.internal.GC.collect()=true
Copy code
//build.gradle

configure(listOf(
        iosX64(),
        iosArm64(),
        iosSimulatorArm64()
    )) {
        this.compilations.configureEach {
            compilerOptions.configure {
                freeCompilerArgs.add("-Xallocator=mimalloc")
            }
        }
    }
👀 2
m
Are you using ktor? I heard that there's some memory leeks on iOS with ktor 2.x
s
yes
ktor version 2.3.10 ktorfit version 1.12.0, this are the version I am using
btw we are not making any network calls while opening the bottomsheetdialog, how does it ktor plays role here..