[00:00:06] Hey, my name is John Peppers and I'm an [00:00:08] engineer on .NET MAUI and .NET in [00:00:12] general. [00:00:13] Um we're here to talk about .NET MAUI's [00:00:16] move to CoreCLR in .NET 11. [00:00:19] Um [00:00:20] and so I I joined Microsoft in 2017 [00:00:25] uh to work on Xamarin. [00:00:27] Uh and so this is a lot of this is uh [00:00:29] been a multi-year effort. Um a lot of [00:00:32] different teams, a lot of different [00:00:33] people working on this. Um [00:00:36] but I'll I'll talk about, you know, the [00:00:38] journey we've we've had. [00:00:40] Um [00:00:42] MAUI and Mobile, you know, our goal from [00:00:45] moving Xamarin to .NET was really to [00:00:47] unify everything. You know, Xamarin was [00:00:50] kind of this a separate company, so they [00:00:52] had a parallel [00:00:54] implementation of everything. [00:00:56] Um and so we wanted Mobile and and .NET [00:00:58] MAUI to really feel like it is part of [00:01:00] .NET. And so that's [00:01:02] really the reason behind a lot of this [00:01:04] work. [00:01:06] So first of all, why [00:01:08] why would we move to CoreCLR? Um [00:01:11] CoreCLR is like a battle-tested [00:01:14] runtime. Like when you see people [00:01:16] talking about web services or like [00:01:20] big industrial software, like CoreCLR is [00:01:24] the thing that runs servers, .NET [00:01:27] servers and everywhere, right? [00:01:29] Um so it makes sense to just bring this [00:01:31] to Mobile as well. [00:01:33] Um I'll talk about how apps launch um in [00:01:37] .NET. I'll I'll focus on Android mainly [00:01:40] just because maybe I'm really familiar [00:01:42] with it, but a lot of the things I talk [00:01:44] about Android will be very similar if [00:01:46] you thought of iOS instead. [00:01:48] Um we'll talk about how your code [00:01:50] actually runs. We'll talk about um some [00:01:54] confusing terms like the difference [00:01:56] between Mono AOT and Native AOT. [00:01:59] And we'll talk ready to run on Core CLR. [00:02:03] Uh and then we'll look at what actually [00:02:04] changes for you and your app. Um, [00:02:08] hopefully not much. That's our goal [00:02:09] anyway. Um, [00:02:11] but it's mainly around diagnostics and [00:02:13] compatibility and a few things. [00:02:15] And then at the end I'll show the [00:02:17] numbers we're seeing in switching to [00:02:19] Core CLR, [00:02:20] um which we're hoping that you see [00:02:22] similar. [00:02:25] So let's start out like what what [00:02:26] exactly is a runtime? So [00:02:30] if you're a a C# .NET developer you [00:02:32] might not think about this every day, [00:02:34] um but it it's basically the the engine [00:02:37] that runs your code. So you have your [00:02:39] app and your C# is compiled to a DLL or [00:02:44] IL. [00:02:45] Um, and then the .NET runtime takes your [00:02:48] code and is able to like load it, [00:02:52] run it for whatever [00:02:54] architecture, whatever operating system [00:02:56] it's running on and it gives you things [00:02:58] like garbage collection and [00:03:01] strong types, uh exceptions. Um, [00:03:05] it also gives you a way for your code to [00:03:07] reach into the operating system. So when [00:03:09] you you use an API you're familiar with [00:03:12] like system IO file, [00:03:14] um the .NET and and the base class [00:03:17] libraries are forwarding that onto the [00:03:19] operating system beneath you. So [00:03:22] if you're running on Windows, Mac, iOS, [00:03:25] Android it calls the write APIs on the [00:03:29] platform to write a file, for example. [00:03:32] And you don't have to think about that [00:03:34] as much. [00:03:36] So let's talk about the history a little [00:03:38] bit. Um, [00:03:39] before I joined Microsoft I was a [00:03:42] Xamarin customer and had submitted apps [00:03:44] to app stores. [00:03:46] Um, so I I know you know [00:03:49] the background [00:03:51] of Xamarin. Um, but Xamarin was acquired [00:03:53] in 2016 and since then you know the goal [00:03:56] has been to kind of unify mobile [00:04:00] to where it feels like it's part of [00:04:01] .NET. Like it's not a parallel universe [00:04:04] of things, right? [00:04:07] So, [00:04:08] uh [00:04:09] let's talk about before and after. So, [00:04:11] originally Xamarin uh was kind of broken [00:04:14] to different pieces. Like this is a [00:04:16] Xamarin stack, if you want to think of [00:04:18] it that way. [00:04:19] Um so at the top was Xamarin Forms, [00:04:22] which lets you write uh mobile apps in [00:04:24] XAML or C Sharp. [00:04:26] And that's directly equivalent to what [00:04:28] dotNet MAUI is today, even though we [00:04:31] kind of use MAUI as a umbrella term for [00:04:33] mobile. [00:04:35] Um [00:04:36] and then Xamarin also had Xamarin [00:04:38] Android and Xamarin iOS. And what those [00:04:40] did is [00:04:41] uh integrated into the platforms where [00:04:44] from C Sharp you could call Android APIs [00:04:47] or Apple's APIs and it handled the [00:04:50] packaging to where you actually get a [00:04:52] dotNet [00:04:53] app that you can submit to app stores. [00:04:56] And then lastly, the runtime was [00:04:58] actually uh an open source project [00:05:00] called Mono. [00:05:01] Uh is at github.com/mono/mono. [00:05:05] And it had its own copy of the base [00:05:08] class libraries and implementations of [00:05:10] things. [00:05:11] And so at the time, in this transition [00:05:13] in 2020, we moved the Mono runtime to be [00:05:16] part of the dotNet runtime repo. So [00:05:19] uh there's a subfolder that's like [00:05:21] source Mono [00:05:23] and then all the code is inside. [00:05:25] Um [00:05:26] and we did that and preserved, you know, [00:05:27] the history from the Mono project. [00:05:30] And just an interesting note is if you [00:05:32] go to the dotNet runtime repo and you [00:05:34] look at the oldest commit, [00:05:36] you can see here's the first commit of [00:05:38] the Mono project [00:05:40] uh in 2001. And that's just the way Git [00:05:43] works that [00:05:44] um it's sorted by date, right? So [00:05:47] just an interesting fact there. [00:05:51] So [00:05:52] uh [00:05:54] we did this work kind of in 2020. In [00:05:57] 2021 dotNet 6 released. At that time [00:06:01] dotNet MAUI was in preview and then we [00:06:03] in the May of of the next year, six [00:06:06] months later, we we made Maui GA, right? [00:06:10] So, but between the time .NET Maui went [00:06:12] GA [00:06:14] and [00:06:15] there was this [00:06:16] migration period to get off of Xamarin. [00:06:19] And so we we did a lot of work. We had [00:06:21] migration tools. There's there was like [00:06:23] a .NET upgrade assistant. [00:06:25] Um and most of all of our customers [00:06:28] made that migration during that time. [00:06:31] Um I think in the end you ended up with [00:06:33] a better app. Like performance should [00:06:36] have improved in in that migration just [00:06:38] because we really worked on that. [00:06:41] Um [00:06:42] but at that time [00:06:44] we still had the mono runtime [00:06:47] until .NET 11 previews. Um [00:06:51] so it if you weren't aware and you're [00:06:53] using .NET 10 right now, you can [00:06:55] actually try core CLR as an experimental [00:06:58] feature. Uh you can set use mono runtime [00:07:01] false and that would actually swap the [00:07:04] runtime in your app. [00:07:06] Um [00:07:07] but what we would prefer is to you try [00:07:09] .NET 11. Um as soon as you change your [00:07:13] target framework, it's just going to [00:07:14] automatically do the same thing. [00:07:16] Um [00:07:17] switch over to core CLR. [00:07:19] Uh we made this default in .NET 11 [00:07:22] preview four. [00:07:23] And then in preview six, we actually [00:07:26] removed the ability to target target [00:07:27] mono in .NET 11. [00:07:29] Um [00:07:30] so if you if there is some rare reason [00:07:33] you need to stay on mono [00:07:35] please tell us you know is something not [00:07:37] working, that would be great. But [00:07:40] you stay on .NET 10 for now if there is [00:07:43] a problem. Um and our hope is to you [00:07:45] know get those resolved in the next [00:07:48] few months or whatever. Yeah. [00:07:51] So [00:07:53] uh to understand the runtime here and [00:07:55] what's actually happening, what's [00:07:57] changing, I'm going to talk about the [00:07:58] startup process. [00:08:00] Uh I'm going to say talk about Android, [00:08:02] but just imagine iOS is very similar to [00:08:04] this. So [00:08:06] uh in in this case, the operating is [00:08:08] what launches the app. [00:08:10] Mobile is very locked down, and so the [00:08:13] operating system has its own life cycle [00:08:16] of apps. And so Android will look into [00:08:18] your app and it sees, you know, Android [00:08:20] components inside, like you might have [00:08:22] an application or an activity, [00:08:25] and it launches those. [00:08:27] And sometime before then, we have to [00:08:30] transparently start the .NET runtime [00:08:33] before your code can run, right? And so [00:08:35] our idea is that you don't know what's [00:08:37] you don't have to know the magic [00:08:38] happening here necessarily, [00:08:41] but then .NET is started for you and [00:08:43] your your code and your app runs. [00:08:47] So [00:08:48] to drill in a little further, [00:08:50] there's an Android feature called the [00:08:52] content provider. [00:08:54] And so we have a .NET runtime content [00:08:57] provider that [00:09:00] at this stage you can run code before an [00:09:03] an Android's main application starts, [00:09:05] right? And so we [00:09:07] during the build, we set this up for you [00:09:09] where we we put some code that starts [00:09:11] the runtime [00:09:14] application on create is called. And [00:09:16] then if you have an activity or whatever [00:09:18] is next, it'll call your activity and [00:09:20] your on create. [00:09:22] And if you're a .NET MAUI project, this [00:09:24] is also abstracted away from you a [00:09:26] little bit. Like the project template [00:09:28] sets this up for you. [00:09:31] But we want things to be easy and you [00:09:32] shouldn't be thinking about like how [00:09:35] does the OS integrate [00:09:36] into my app necessarily. [00:09:39] So at this stage, let's let's say [00:09:43] we're starting the .NET runtime. [00:09:46] Android [00:09:48] is either going to call our we have some [00:09:50] code that will start Mono for you or we [00:09:52] have some code that will start CoreCLR [00:09:54] for you. And from for the most part, [00:09:56] your code should remain unchanged. Like [00:09:59] your C# code should be able to run on [00:10:01] either runtime. [00:10:03] All your NuGet packages, etc. [00:10:06] for the most part should work the same [00:10:08] as they did before, right? [00:10:10] Um, so that this is that's our goal, [00:10:12] and and we're hoping that this [00:10:14] transition [00:10:15] is smooth for everybody. [00:10:18] So what are the benefits of this, right? [00:10:20] So I talked about Xamarin uh kind of [00:10:22] being its own [00:10:24] parallel universe. [00:10:26] Uh Mono also has kind of re-implemented [00:10:28] a lot of things. So [00:10:30] Mono has its own debugger. [00:10:32] Um, [00:10:33] it it Mono does integrate with .NET [00:10:36] Trace, but it has some of its events are [00:10:38] different from CoreCLR just cuz it was [00:10:40] different runtime. [00:10:42] And you know, crash reporting is also [00:10:44] different. So [00:10:45] uh moving to CoreCLR, we kind of get the [00:10:48] goodness that all the other platforms [00:10:50] have. So [00:10:51] desktop and server apps have deep [00:10:53] integration and diagnostics. [00:10:56] Um, Maui will kind of get those things [00:10:58] for free as as CoreCLR continues [00:11:02] uh to be used in the future, right? [00:11:06] So let's talk about um [00:11:09] Mono um [00:11:11] to this I think this more solidly [00:11:13] explains the difference of what's [00:11:15] happening even further. So [00:11:17] um let's imagine that you have a C or [00:11:20] C++ project and [00:11:23] uh you want to run .NET code inside, [00:11:25] right? [00:11:26] Uh you can actually load up the runtime [00:11:29] yourself. And and that's actually what [00:11:32] the Android and iOS workloads do for [00:11:34] you. They embed a runtime so that you [00:11:38] don't have to think about it. [00:11:39] Um, [00:11:40] so you can embed Mono, right? So [00:11:44] if you think about uh you know, our old [00:11:46] world, [00:11:48] uh we have some Android C and C++ code [00:11:51] that starts the Mono runtime. And Mono [00:11:53] has all of these APIs to [00:11:57] do things with .NET. You can actually [00:11:59] load a type, recall a method, and like [00:12:02] inspect the types and [00:12:04] there's a lot of different APIs that [00:12:06] Mono has. Uh they're we're called Mono [00:12:09] embedding APIs, if you want to think of [00:12:11] it as that. [00:12:12] Um, [00:12:13] where Core CLR just doesn't have the [00:12:15] ex-Core CLR, basically all you get is a [00:12:17] method named Core CLR initialize. [00:12:21] Um, and that just basically starts the [00:12:23] runtime, and that's that's basically all [00:12:25] you have. Um, so in many ways our our [00:12:28] codebase got simpler, um, because we you [00:12:32] know, [00:12:33] we didn't have access to all this stuff, [00:12:35] but actually we're trying to be a thin [00:12:37] runtime that launches your app, right? [00:12:38] That's the goal. [00:12:40] Um, [00:12:41] and you can still achieve the same [00:12:42] thing. So [00:12:44] we imagine not many people are are going [00:12:47] to have a problem with this, like maybe [00:12:49] someone who's writing a game engine or [00:12:51] something. Um, but most most .NET MAUI [00:12:54] developers are probably not thinking at [00:12:56] this level, right? [00:12:58] Um, [00:12:59] so anyway, [00:13:01] we'll move on. [00:13:02] Um, so let's talk about uh [00:13:05] how apps are packaged a little bit, and [00:13:07] I think this illustrates what you'll [00:13:09] notice if you unpack one of your apps [00:13:12] and look inside uh the change between [00:13:14] Mono and Core CLR. So [00:13:17] you have all your .NET assemblies, your [00:13:19] DLL files. [00:13:20] Um, we actually have those packaged [00:13:22] inside a single native library named lib [00:13:25] assembly store on Android. [00:13:27] Um, [00:13:28] and it's done this way so that uh Google [00:13:31] Play can split up your app per [00:13:33] architecture. So there's a data section [00:13:36] in that native library that has all of [00:13:38] your IL. [00:13:40] And in our our little thin runtime knows [00:13:43] how to unzip that on demand and and pass [00:13:46] it off uh to .NET runtime, right? [00:13:49] Um, [00:13:50] and so for the most part, you know, you [00:13:52] don't have to think about [00:13:54] you don't have to look inside here and [00:13:56] understand what's going on. Um, [00:13:58] but the difference [00:14:00] uh is it Core CLR will be instead of [00:14:03] just IL, they'll be ready to run images [00:14:05] also inside. [00:14:07] Um, so what let's talk about [00:14:09] ready to run and what that is next. Um, [00:14:13] so [00:14:15] this this is where the terms confusing, [00:14:16] which is why I wanted to [00:14:19] drill in here better. Is is the word [00:14:21] AOT. Someone may mention AOT [00:14:24] um [00:14:25] and they don't say which AOT, right? [00:14:27] There's Mono has its own version of AOT [00:14:29] and then there's a thing called native [00:14:31] AOT that we'll we'll talk about here [00:14:33] later. [00:14:35] And then Core CLR, it has a similar [00:14:38] uh technology named ready to run, right? [00:14:41] Which they're both very similar things, [00:14:43] right? [00:14:45] So, let let's talk about what this is. [00:14:46] So, you you have your C# code [00:14:50] that you run a build that's compiled to [00:14:51] IL. [00:14:52] And so, if you're on desktop [00:14:55] um [00:14:56] you know, that code might run through [00:14:58] the JIT, the just-in-time compiler. [00:15:00] Um on Android, we can run the JIT [00:15:03] actually. Um but on iOS um [00:15:07] Apple has actually blocked you know [00:15:10] executing RAM at the OS level. So, a JIT [00:15:14] in in its pure form can't actually work. [00:15:17] And so [00:15:18] um we do also have an interpreter for [00:15:21] for that purpose on iOS. Um [00:15:24] so, anyway, so the alternative to [00:15:26] just-in-time is is AOT or ahead-of-time [00:15:30] compilation [00:15:31] um where this work happens at build time [00:15:34] and what you end up with is native code [00:15:37] like in a file that is inside the app [00:15:39] and and can be loaded [00:15:41] where the JIT kind of does it on demand [00:15:43] in memory. Um [00:15:47] yeah. And so, you know, like I said, AOT [00:15:50] doesn't [00:15:51] mean native AOT necessarily. But I'll [00:15:54] talk about native AOT more here in a [00:15:56] second. [00:15:58] So, I showed how the [00:16:00] uh [00:16:01] your app is kind of packaged before. [00:16:03] Um so, in in the Mono world, what would [00:16:06] happen when you run Mono AOT is it would [00:16:09] look at your DLL and run a tool during [00:16:12] the build [00:16:13] during a release build hopefully [00:16:15] uh called Mono AOT Cross. And what you [00:16:18] end up with is a a native library [00:16:21] per DLL file that's in your app. [00:16:24] Uh and those are loaded independently of [00:16:26] the assembly store, right? [00:16:29] Ready to run, however, is it's just a [00:16:32] new technology. Just [00:16:34] it it's it's more built to be with Core [00:16:36] CLR, but it instead of going through [00:16:39] mono AOT cross, it goes through cross [00:16:41] gen two. [00:16:43] And it actually packs the native code [00:16:45] inside your DLL. So if you [00:16:48] if you ever have published an app with [00:16:50] ready to run, you'll notice the DLLs are [00:16:52] larger. [00:16:53] But if you open them and look inside, [00:16:55] not only do they contain IL, but they [00:16:57] have like a native image. It's like a [00:16:59] mixed [00:17:00] DLL file. [00:17:02] And so we were able to do this on [00:17:03] Android [00:17:05] um [00:17:07] and iOS as well. [00:17:11] So because Android has the ability to [00:17:14] have a JIT, [00:17:15] we're able to use partial ready to run. [00:17:18] Um we we also did this with mono. We [00:17:21] were using uh partial [00:17:23] AOT profile AOT, if you want to call it. [00:17:27] Um [00:17:28] but the idea is that we have a pipeline [00:17:30] somewhere that runs like a [00:17:31] representative Maui project and records [00:17:34] all the methods that are run at startup. [00:17:37] And so we save that in a MIB C file. [00:17:40] Um and then we hand that file Uh we [00:17:43] actually ship one of these in the [00:17:44] product, and then we hand that file [00:17:47] uh [00:17:48] to the ready to run compiler. And what [00:17:50] you end up with is a smaller app [00:17:53] where all the apps all all the methods [00:17:55] at startup are fast. [00:17:57] Um [00:17:59] and then you have this tradeoff where if [00:18:01] you ready to run everything, the app [00:18:03] would grow in size a lot. [00:18:05] Um so this is kind of the best in both [00:18:08] worlds where the app starts fast, but [00:18:10] it's small and small download size, [00:18:13] small install size. [00:18:17] So so Android uses this by default, [00:18:20] while iOS does not use this. [00:18:23] Um, [00:18:24] mainly because it it does not have a [00:18:26] chip. [00:18:28] So then let's go into native AOT. Um, [00:18:32] and I'm bringing this up mainly to [00:18:35] reduce confusion and because it's also [00:18:37] very good for mobile to use native AOT. [00:18:39] So [00:18:40] um, but what native AOT is is really [00:18:43] another runtime. So we had Mono, we had [00:18:45] CoreCLR. This is another one. [00:18:48] Um, [00:18:49] but usually uh, [00:18:52] native AOT requires you to do a little [00:18:54] more work on your end. Um, but what you [00:18:57] end up with it in in pretty much any [00:19:00] case is a smaller and faster launching [00:19:03] application. [00:19:04] Uh, which we we which is why it is good [00:19:07] for mobile, right? [00:19:10] So let's talk about what native AOT [00:19:12] does, right? [00:19:13] Um, it's it's kind of like CoreCLR in [00:19:16] that you have like an app [00:19:19] and you can you have the base class [00:19:21] libraries, you have a runtime, you have [00:19:23] a GC, but it doesn't have a JIT. And so [00:19:26] what it has is a compiler [00:19:28] that does everything ahead of time. [00:19:31] And it also aggressively trims away [00:19:34] unused code. And so [00:19:36] what you can end up with is if you have [00:19:39] special dynamic code [00:19:42] um, that won't work in native AOT. So [00:19:44] like if you had a a plugin model [00:19:47] and you're loading DLL files from disk [00:19:50] or something like that, like that's not [00:19:52] going to work in native AOT, right? [00:19:55] But what you get at the end is you get a [00:19:56] single file app as the output. So [00:20:00] when I if I built an Android app, I get [00:20:02] a single SO file that contains the [00:20:04] runtime [00:20:06] and all of my .NET code compiled ahead [00:20:09] of time. [00:20:10] Um, so in that way it's very simplified. [00:20:13] Like you're down to one file. [00:20:15] Um, and the same for iOS is you get a a [00:20:18] single Mach-O like binary that iOS can [00:20:21] launch, right? [00:20:24] And where's it's worth mentioning um [00:20:27] uh native AOT is in preview on Android. [00:20:30] And just because we didn't quite get [00:20:32] enough time to work on it in this [00:20:34] release, but we're hopeful that, you [00:20:36] know, [00:20:37] going forward it it will [00:20:38] be stable. [00:20:41] All right, so let's talk about like the [00:20:43] problems with native AOT. Um I mentioned [00:20:46] the plugin [00:20:48] uh [00:20:48] example, but this is [00:20:50] may maybe it drills in further. So let's [00:20:52] say you're using system text JSON and [00:20:56] you have some text and you're parsing [00:20:58] it, you use JSON serializer class. [00:21:02] Well, what that code does is it it it [00:21:04] dynamically reads the text and sets [00:21:07] properties on the on the person class. [00:21:10] Um and so what when the native AOT build [00:21:13] process trims away code, it can't [00:21:16] statically tell what properties need to [00:21:19] be removed or kept on the person class, [00:21:21] right? [00:21:22] Um and so the solution is to use system [00:21:25] text JSON source generator. [00:21:27] Um [00:21:29] a simple example here is you set up a [00:21:31] person context and what that does is it [00:21:34] it generates code inside there that [00:21:36] strongly uh that parses the text in a [00:21:39] strongly typed way. And so [00:21:41] once this is here, [00:21:43] the trimmer can properly keep or remove [00:21:47] anything unused. [00:21:49] Um and then you you have no warnings. [00:21:51] Well, the first example you would have a [00:21:53] squiggle [00:21:55] warning that that says, hey, this code [00:21:58] won't work on native AOT, right? [00:22:01] So this is just an example, but you you [00:22:04] will have some work to do and if you [00:22:06] want to move an existing app to native [00:22:08] AOT, but I think if you if you're [00:22:10] starting a new app, like I would start [00:22:12] with it from the beginning. Um [00:22:15] uh the problem tends to be any NuGet [00:22:18] third-party NuGet packages you use are [00:22:20] are going to be the problem [00:22:22] um [00:22:23] beyond your code. [00:22:26] So let's talk about the results. [00:22:28] Um, [00:22:30] and these these are graphs um that [00:22:34] you know a couple like we have multiple [00:22:36] versions of these numbers, but this is [00:22:39] just kind of representative, I think. [00:22:41] And so [00:22:42] just to show you what we're seeing um [00:22:45] this is on Android Samsung Galaxy A16, [00:22:49] which is kind of a budget device. [00:22:51] I think it's in the 200 US dollar range. [00:22:55] So, that's why the numbers are kind of [00:22:56] high on this first slide, but uh [00:22:59] a .NET new MAUI app like comparison mono [00:23:03] versus the middle bar is partial ready [00:23:06] to run, so that's default. [00:23:08] And then full ready to run is is the [00:23:10] next one. So, it depends on the app. [00:23:13] Uh sometimes partial ready to run is [00:23:15] faster and sometimes [00:23:17] full ready to run is faster just [00:23:19] depending on the app. Um so we have the [00:23:22] MAUI template, [00:23:24] the sample content. [00:23:26] Um so when you do .NET new MAUI, you can [00:23:28] pass sample content and that gives you a [00:23:31] bunch of other stuff. So, you get like [00:23:34] uh some sync fusion controls, like some [00:23:36] graphs and charts are in in the app on [00:23:39] the main screen. [00:23:40] Uh it sets up MAUI community toolkit. [00:23:43] Uh so it has just more stuff in the app. [00:23:47] And then the M365 admin, that's actually [00:23:50] uh [00:23:51] like a Microsoft app [00:23:53] that uses that's built with .NET MAUI [00:23:55] and it's actually a real app. And so [00:23:58] uh we can see that you know we're [00:24:00] getting comparable startup here. [00:24:04] Um same with iOS. Um so iOS does we [00:24:07] don't have that middle bar because it [00:24:09] doesn't have partial ready to run, but [00:24:12] for the most part all three apps are [00:24:14] starting faster on iOS as well. [00:24:19] And then for APK size. So, [00:24:22] what we're seeing here so partial ready [00:24:24] to run is kind of in that sweet spot [00:24:26] where it's really close to the being the [00:24:29] same as mono. [00:24:31] Um, whereas if you use full ready to [00:24:33] run, [00:24:34] um, the app is going to grow in size a [00:24:36] little bit. [00:24:37] Um, [00:24:38] and ideally you it's your choice to make [00:24:40] that trade off. You can pick the [00:24:42] defaults or enable full ready to run. [00:24:45] And if you you may profile your app [00:24:48] and find out that hey, it's worth the [00:24:50] trade off. I'm going to turn on full [00:24:52] ready to run [00:24:53] um, because the app launches more [00:24:54] quickly and the app size is okay, you [00:24:58] know. So we we we leave the option to [00:25:01] you for that one. [00:25:03] And then on iOS, [00:25:04] uh, we're seeing you know, smaller apps [00:25:07] kind of across the board here. [00:25:09] Um, [00:25:11] yeah, not much to say on that one, but [00:25:14] it looks good. [00:25:15] So we we're hopeful that you'll kind of [00:25:17] see similar numbers. If you see [00:25:19] something that's kind of outside of what [00:25:21] we've been seeing here, you know, feel [00:25:23] free to file an issue. We'd like [00:25:25] to look deeper. [00:25:28] So now let's talk about at the end. So [00:25:31] what what do you actually need to think [00:25:32] about or test when you move to .NET 11? [00:25:35] Um, [00:25:36] ideally you don't have to change any of [00:25:39] your codes, but let's let's think about [00:25:42] like what maybe the things to check, [00:25:44] right? [00:25:45] Um, so first of all, just check is the [00:25:46] performance what you expect, right? [00:25:49] Did it did startup change? Did the [00:25:52] memory usage change? Did the app size [00:25:54] change? [00:25:55] Uh, mainly just to let us know so that [00:25:58] we can investigate if if there is [00:25:59] something happening there. [00:26:01] Um, go ahead and and test your app [00:26:03] behavior. [00:26:05] Like we're trying to make sure nothing [00:26:07] could change, but it's possible that do [00:26:09] you have a strange edge case in your [00:26:11] app, right? So do things like run your [00:26:14] tests [00:26:15] and just find out is is there something [00:26:17] missing, right? [00:26:19] Is there something different? [00:26:21] Um, because there could be minor edge [00:26:23] cases. [00:26:25] Um, and then lastly diagnostics. Um, we [00:26:28] think that Core CLR should improve this [00:26:30] area, [00:26:32] um but like things like um crash APIs, [00:26:37] um you'll notice that stack traces look [00:26:39] different because um they're coming from [00:26:41] a different the different files, [00:26:43] different runtimes print things in [00:26:45] different ways. So [00:26:47] um so just keep an eye on that. [00:26:50] And then uh of course if if you are one [00:26:53] of the rare people who need the mono [00:26:55] embedding APIs, [00:26:57] um [00:26:58] that would probably need a redesign and [00:27:00] and you may look into using native AOT [00:27:03] instead because [00:27:06] um there is a feature called unmanaged [00:27:08] callers only that you can put on a [00:27:10] method [00:27:11] um that you could use that instead of um [00:27:16] um [00:27:17] mono embedding APIs. Um and native AOT [00:27:20] would give you a smaller single SO file [00:27:23] that you could call into. [00:27:27] All right. So I I hope this has kind of [00:27:30] explained the different runtimes and [00:27:32] what's happening with your app. [00:27:34] Um but our goal here was to kind of to [00:27:36] start with Xamarin, [00:27:38] you know, this [00:27:39] you know, separate .NET thing and make [00:27:43] it really make it a part of .NET. Uh and [00:27:46] our move to CoreCLR is kind of the last [00:27:48] piece here, right? We [00:27:51] definitely want to do further work in [00:27:53] the future, you know, get native AOT [00:27:56] stable on [00:27:58] on all of mobile. [00:28:00] Um but yeah, we are hopeful that .NET 11 [00:28:03] will be the fastest release for you yet. [00:28:05] Um [00:28:06] thanks.