# Kotlin in iOS: Memory Debugging with Xcode and Instruments - Ben Whitley

DevFeed: [Kotlin in iOS: Memory Debugging with Xcode and Instruments - Ben Whitley](<https://devfeed.tech/articles/kotlin-in-ios-memory-debugging-with-xcode-and-instruments-ben-whitley-38262.md>)

Original publisher: [Read original article](<https://touchlab.co/kotlin-ios-memory-debugging-with-xcode-instruments>)

Published: 2020-05-13T16:05:32Z

Content type: tutorial

Language: en

Sources: [Touchlab | Enterprise Mobile Innovation & Development](<https://devfeed.tech/sources/touchlab-enterprise-mobile-innovation-development.md>)

Topics: [debugging](<https://devfeed.tech/topics/debugging.md>), [Kotlin](<https://devfeed.tech/topics/kotlin.md>), [Xcode](<https://devfeed.tech/topics/xcode.md>), [iOS](<https://devfeed.tech/topics/ios.md>), [configuration](<https://devfeed.tech/topics/configuration.md>)

Tags: [code-sharing](<https://devfeed.tech/tags/code-sharing.md>), [debugging](<https://devfeed.tech/tags/debugging.md>), [ios](<https://devfeed.tech/tags/ios.md>), [kotlin](<https://devfeed.tech/tags/kotlin.md>), [kotlin-multiplatform](<https://devfeed.tech/tags/kotlin-multiplatform.md>), [memory](<https://devfeed.tech/tags/memory.md>), [xcode](<https://devfeed.tech/tags/xcode.md>)

## AI overview

This tutorial explains how to debug memory issues in an iOS app that uses a shared Kotlin library. It covers the required dynamic framework and optional Xcode file references, then demonstrates using Xcode Instruments Allocations, call trees, Kotlin symbol searches, and stack traces to locate relevant code.

## Source excerpt

If you're working on an iOS app that's using a shared Kotlin library, you might be skeptical about your ability to debug memory issues. Not only is it possible, it's actually really easy. And not only is it really easy, there's a myriad of different ways to go about it, so you can choose whatever you like the most. I'm only going to focus on the way that I like to do it, but if you play around in Instruments, you might find a workflow you like even more.