Ivan Nikitin
Ivan Nikitin

Reputation: 4143

Do MonoTouch and MonoDroid produce the same ARM6/7 code for both platforms?

Do MonoTouch and MonoDroid use the same C#-to-native compiler and GC and thus provide identical performance? Is it the same compiler Mono uses to produce AOT-compiled assemblies on Windows?

If I write a completely platform-independent feature, say a JPEG decoder, will it produce the same ARM6/7 code for both platforms?

Upvotes: 3

Views: 171

Answers (1)

poupou
poupou

Reputation: 43553

No. Depending on your options the generated code could be similar but it will never be identical.

MonoTouch on the iOS simulator uses the Mono JIT (x86).

MonoTouch on iOS devices using an AOT compiler, by default it's the one from Mono. Optionally you can use the LLVM-backed AOT compiler. That will be ARMv6, ARMv7 and/or (soon) ARMv7s.

MonoTouch default GC is Boehm. Optionally you can use sgen and, as a further option, you can use the newrefcount* option.

Mono for Android uses the JIT, both on the emulator and on devices (not all devices are ARM-based, even if most are). It also uses the sgen garbage collector by default (in fact it cannot use the Boehm collector since it needs to coexists with the Java GC).

Upvotes: 4

Related Questions