-
Notifications
You must be signed in to change notification settings - Fork 46
Open
Description
Copied directly from #7 :
See cscript-registry-benchmark and its output.
Calling registry.GetStringValue directly (eg, agnostic mode) is roughly 2x as fast as registry.ExecMethod_("GetStringValue", ..) with a "__ProviderArchitecture" flag / context.
The relevant bit of the output is (the third column is the difference to the agnostic duration):
Agnostic: 2.219 sec
64-bit: 4.797 sec +2.578
64-bit (predefined method): 3.906 sec +1.688
As the third row shows, a small speed gain can be made by reusing the method object:
' Initialize
set method = registry.Methods_("GetStringValue")
' Then later ..
Set params = method.Inparameters
params.hDefKey = ..Instead of doing registry.Methods_("GetStringValue").Inparameters each time.
PS. You might see "20000 sec" in the output, that's a formatting mistake, should be 2 seconds.
xmedeko
Metadata
Metadata
Assignees
Labels
No labels