You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Oct 15, 2020. It is now read-only.
`HandleScope` was simulated in chakrashim by saving references
in `JavascriptArray` which involved calling `JsSetIndexedProperty`
API. Although this API is not slow, but there is an overhead of
calling JSRT APIs. It regress performance if `AddLocal` is called
often. To avoid that, gathered elements in `_locals` stack and
then bulk pushed them to array.
* Earlier we called `JsCreateArray` with length 1 to create the
above array. This creates an array of head segment size 4
(rounding) but since we are pushing `kOnStackLocals`, we would
fill up the head segment and allocate newer segment. Instead if we
pass length 0 to `JsCreateArray` it creates a head segment of size
16 and we don't have to initialize another segment till count reaches
16.
* Also, I converted `Object::GetPropertyAttributes` to javascript
function which should save 6 JSRT calls. I have also added
`CHAKRA-TODO` comments for functions that should be easily
converted to javascript functions.
PR-URL: #101
Reviewed-By: Jianchun Xu <Jianchun.Xu@microsoft.com>
0 commit comments