Smaller MonoTouch applications

I’ve backported most (i.e. the biggest gains) linker enhancements from xtouch into MonoTouch. Here’s some number from a sample application:

Link All Assemblies
MonoTouch 4.0.x MonoTouch (master) diff
KeyChain.exe 4608 4608 0
mscorlib.dll 720896 571392 149504
System.dll 251904 0 251904
System.Core.dll 5632 0 5632
Mono.Security.dll 150351 0 150351
monotouch.dll 56320 54272 2048
total 1189711 630272 559439
100% 53% 47%

Of course this is an extreme case.  Very small applications makes the best linker test cases. Larger applications will bring more code (hiding the linker results) so YMMV. Also the linker only works on managed code (the unmanaged driver application size, that includes mono, remains mostly unchanged) so the final application size won’t change that much.

Other stuff (plenty of ideas and a bit more code from xtouch) will have to wait after monospace and vacations 😎

Advertisements

About spouliot

Xamarin Hacker, Mono Contributor, Open Source Enthusiast with strong interests in Code Analysis, Cryptography and Security. Presently working on MonoTouch, previous projects were Moonlight and libgdiplus and a lot of the cryptographic work done on Mono.
This entry was posted in linker, mono, monotouch, xamarin. Bookmark the permalink.

One Response to Smaller MonoTouch applications

  1. Pingback: Linker vs Backing Fields | surprisingly unimpressed

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s