NGEN : Native Image Generator (1 Viewer)

alcalc

Portal Member
August 9, 2006
15
1
Does anyone have any experience using NGEN to compile native images of mediaportal?

I would be interested in hearing about your experiences:
- notice any difference
- any advice on getting all sub assemblies & dependencies included
- etc.

If there is any performance gain maybe a script to set up the Native Image Service for media portal could be on the horizon.

Cheers.
 

and-81

Retired Team Member
  • Premium Supporter
  • March 7, 2005
    2,257
    183
    Melbourne
    Home Country
    Australia Australia
    I have a .net application I wrote that uses NGEN at install time to optimize the main assemblies. As far as I can tell the app loads up a little quicker, but I can't quantify the improvement as I haven't done any serious comparisons. From what I know about NGEN I certainly don't think it would hurt to run it over mediaportal at install time. It would be very easy to do as part of the install process.

    Unfortunately I'm not in a position to thoroughly test this on MediaPortal at the moment, but if I get some time the weekend after next then I might see what I can come up with.
     

    sean2078

    Portal Member
    August 10, 2006
    7
    0
    ngen will help only just after you install MediaPortal, but it does help. .NET 2.0 ngen is much improved over .NET 1.1 ngen. Mainly because in 1.1 each time a dependency was changed, the entire dependency chain had to be JIT'ed again.

    Generally speaking (and I'm not a MediaPortal engineer) there shouldn't be much need to run ngen at the end of install. It wouldn't hurt, but in terms of supporting it, it definitely shouldn't rank high at all on the priority list.

    In terms of experience, sure - there's always going to be a difference between an exe that's been ngen'ed (or JIT'ed) and the same exe that hasn't been JIT'ed yet.

    But the point is that as soon as you run the app once, running ngen on any of the components again won't speed up anything. Also running it just after install won't speed up the app any more than it would perform the 2nd time you run MediaPortal. Also, MS is attempting to get the 2.0 framework optimizer service on everyone's Win. installation and if that's running, it will automatically ngen MediaPortal for you whenever your computer is idle.

    Personally, I would like engineering time to be spent on more important items.

    Hope that helps.
     

    Users who are viewing this thread

    Top Bottom