Why are my programs running from my SD card so slow?

When moving my .Net Compact Framework application to the SD-card of a Windows CE device, the program executes slower then running it from the internal memory.

I thought, the start-up might be slower, but it is the whole program. There is no IO to the storage card.

Why is my application so slow and how does the compact framework handles and loads the assemblies?

Answers


It has to do with demand-paging. Your app cannot be run directly from the SD-card, as SD is not executable media so it has to be pulled into RAM to run. Windows CE doesn't typically have a whole lot of RAM, so the loader doesn't pull your entire application into RAM to run. Sure, your heaps and stacks will be in RAM, but the actual IL code in the assembly itself is paged in as needed. It's also paged out when the system decides it no longer needs a specific page.

This paging can have an impact on performance, though I'm a bit surprised that it's a large impact unless the app itself is really large (like if you have lots of embedded resources that it's pulling out of the assembly).


Need Your Help

Testing the Keychain - OSStatus error -34018

ios iphone xcode sentestingkit

I'm trying to test code that reads and alters the keychain using the basic SenTest framework on Xcode. The code works fine on device, but when I start the test I get these errors every time I want to

hidden and make visible a div with a button

jquery html css

i have a problem with my jquery code.

About UNIX Resources Network

Original, collect and organize Developers related documents, information and materials, contains jQuery, Html, CSS, MySQL, .NET, ASP.NET, SQL, objective-c, iPhone, Ruby on Rails, C, SQL Server, Ruby, Arrays, Regex, ASP.NET MVC, WPF, XML, Ajax, DataBase, and so on.