Introduce support for unlimited trampolines.
authorPaolo Molaro <lupus@oddwiz.org>
Wed, 14 Nov 2012 14:03:41 +0000 (15:03 +0100)
committerRodrigo Kumpera <kumpera@gmail.com>
Mon, 10 Dec 2012 22:26:02 +0000 (17:26 -0500)
commitb0e9fb6f6f4791e9c7684c2e9af17f9929ff6564
treec9de855ce5ceef9148fb2da1d57cb003cbaf49d7
parent98df353e1109d6d33ab3bd2765675cc1f153ab57
Introduce support for unlimited trampolines.

With this new code there is no longer an AOT compiler limit on the number of
trampolines, as they are allocated at runtime as necessary on iOS systems.
We use iOS's ability to remap a page to a different address in memory
and we replicate the trampolines we generate in the binary file to a
location in memory near a writable page where the trampolines can find the
specific runtime data needed (basically building writable constant pools).
On a big app like bcltests, this saves more than 900KB of binary size.
There is still the option to use the old code, by passing the "nopagetrampolines"
option tp the AOT compiler (the new code is the default).
mono/mini/aot-compiler.c
mono/mini/aot-runtime.c
mono/mini/tramp-arm.c