Any comments on NGen?


Author
Message
Peter Jones
Peter Jones
StrataFrame User (450 reputation)StrataFrame User (450 reputation)StrataFrame User (450 reputation)StrataFrame User (450 reputation)StrataFrame User (450 reputation)StrataFrame User (450 reputation)StrataFrame User (450 reputation)StrataFrame User (450 reputation)StrataFrame User (450 reputation)
Group: Forum Members
Posts: 386, Visits: 2.1K
Hi,



So much to know.....



While investigating ways and means of speeding up our app (especially on initial load of forms) we have stumbled across NGen. It seems like it is something we should be using and an early test shows it could half the load time for complex forms (BTW we use DevExpress controls).



We have a way to go in looking at the pros (apparently many) and cons (can't find any of significance yet) and I was wondering if anyone has had a bad experience with NGen and can perhaps warn us of potholes before we fall down them.



Cheers, Peter
Trent Taylor
Trent Taylor
StrataFrame Developer (8.5K reputation)StrataFrame Developer (8.5K reputation)StrataFrame Developer (8.5K reputation)StrataFrame Developer (8.5K reputation)StrataFrame Developer (8.5K reputation)StrataFrame Developer (8.5K reputation)StrataFrame Developer (8.5K reputation)StrataFrame Developer (8.5K reputation)StrataFrame Developer (8.5K reputation)
Group: StrataFrame Developers
Posts: 6.6K, Visits: 6.9K
This can be a really long explanation in regards to speeding up loading and performance. Part of the issue here is actually DevExpress. A good while back, we created two large maintenance dialogs. One with DevExpress controls, and one with SF only controls. The loading difference was significant....especially if you are using DevExpress themed (Look and Feel). The DevExpress dialog with the same code, records being loaded, etc. took nearly 3 times as long as the SF controls using mostly inherited .NET controls with some of the custom SF controls.



That was just a performance test that we did to make some determinations as we were starting to notice performance issues crop up on form loads. Past that, we also noticed other performance issues in our medical application that we addressed. For example, we have one maintenance form with 400+ text boxes, labels, combos, lists, etc. across 8-10 pages with some custom controls. This is the Patient Registration and is very large. We started loading things from the database in a single query versus multiples and that had a dramatic impact. So we created SPROCS to load all combos in a single step and the used the FillMultipleDataTables method and CopyDataFrom on the combos population methods. There was more that we did as well, but it is generally by doing a number of things versus any one single thing.



So to answer your question about NGen, I think that it is worth a shot, but there are most definitely going to be a few gotchas. Distribution, for one, may be a little more complicated for a number of reasons. I can't recall, but I think that you may have to take 32-bit and 64-bit, the OS, etc. into account. Also, your QA department will need to be sure to go back through your app from start to finish as there will inevitably be some idiosyncrasies that come from the native image code versus the original assembly.



The number of assemblies that your application is comprised of as well as the overall size of your app will make a difference as well. We elected not to do this as once you add obfuscation into the formula as well, it just wasn't worth the potential issues that could come from it. Good luck Wink
Peter Jones
Peter Jones
StrataFrame User (450 reputation)StrataFrame User (450 reputation)StrataFrame User (450 reputation)StrataFrame User (450 reputation)StrataFrame User (450 reputation)StrataFrame User (450 reputation)StrataFrame User (450 reputation)StrataFrame User (450 reputation)StrataFrame User (450 reputation)
Group: Forum Members
Posts: 386, Visits: 2.1K
Hi Trent,



Thanks for the feedback on NGen and the general commentary on loading forms. I've already noticed that different DX themes load quicker than others, e.g. Christmas is a killer which is unfortunate because it would have been nice to turn it on a week or so.



Your comments on fill multiple table fills was interesting - I will certainly take a closer look at that option.



Cheers, Peter
GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Similar Topics

Reading This Topic

Login

Explore
Messages
Mentions
Search