Monday, August 29, 2011

PowerShell vs VBscript: Part 2

I was asked an interesting question regarding my blog post on the tests that compared ADO and ADO.NET from VBscript and PowerShell:  Was it using native PowerShell ISE or "cold start" execution?

The answer:  Native shell execution

I ran the VBscript code in a standard CMD shell.  I ran both of the PowerShell code examples in the PowerShell ISE shell.

When I ran each script using a "cold start" process, it added a half-second to VBscript and 1.5 seconds to the PowerShell tests.  That tells me that the PowerShell "engine" is slower to initialize from a cold launch request, which could be a combination of many factors from .exe size, thread starts, API requests, and so on.

No comments: