0

Is there a way to create large JIT code from a small assembly to increase startup time of an application spent in jittering?

We are testing various methods of optimizing start-up performance (cold/warm start) and one is using Multicore JIT (https://blogs.msdn.microsoft.com/dotnet/2012/10/18/an-easy-solution-for-improving-app-launch-performance/)

However I would like to isolate the multicore JIT part and test it in a greenfield scenario where I have a load-file IO of a small assembly which produces an unproportionally large code when jittering it.

With that I am hoping to measure the effect of profile optimization. I am aware that this might be hard to measure and I have to take Operating systems' standby lists into account etc. but I would like to get some indication of load times anyway.

Peter Ritchie
  • 35,463
  • 9
  • 80
  • 98
Samuel
  • 6,126
  • 35
  • 70
  • I don't know if it would work but you could create a large tree of long nested switch statements which all need to be unfolded. This could be quite easily and would probably slow your JIT speed. – ScottishTapWater Jan 25 '17 at 12:53
  • Just a thought., but I would think that you could accomplish a variable size IL base that needs to be jitted on a type (Class) by having it create a static [DynamicMethod](https://msdn.microsoft.com/en-us/library/system.reflection.emit.dynamicmethod(v=vs.110).aspx). The loaded assembly would reference a static variable in the calling assembly to determine how much IL to add to the method. – TnTinMn Jan 26 '17 at 17:57

0 Answers0