[TIMOB-26699] Windows: Runtime Performance Improvement
| GitHub Issue | n/a |
|---|---|
| Type | Epic |
| Priority | High |
| Status | Open |
| Resolution | Unresolved |
| Affected Version/s | Release 7.5.0 |
| Fix Version/s | n/a |
| Components | Windows |
| Labels | n/a |
| Reporter | Kota Iguchi |
| Assignee | Kota Iguchi |
| Created | 2019-01-08T01:03:11.000+0000 |
| Updated | 2019-03-08T02:08:07.000+0000 |
Description
Peformance has been the issue on Windows for a long time. From what I observed, some basic JavaScript operations (like calling constructor, accessing properties and functions) against Titanium proxy objects are simply slow. For instance, creating 200 proxy objects on Windows (Titanium 7.4.0.GA) takes about 2 seconds on Windows locally for me.
var win = Ti.UI.createWindow({ backgroundColor: 'green' });
win.addEventListener('open', function() {
var start = +new Date();
for (var i = 0; i < 200; i++) {
win.add(Ti.UI.createView({
width: 50, height: 50, left: i * 10, top: i * 10
}));
}
// setTimeout() effectively push tasks on UI thread.
// This can be useful when you need to see actual UI response time.
setTimeout(function() {
alert((+new Date() - start) + ' m seconds elapsed');
}, 0)
});
win.open();
We might be able to "gradually" improve performance by fixing following areas:
* UI rendering engine ... I expect there could be some redundant rendering calls that can be optimized.
* Optimize WinRT API call ... Passing WinRT boundaries are horribly slow. We want to eliminate the calls as much as we can
* HAL ... It is heavy weight framework that is not quite efficient. We might be able to make it more lightweight.
No comments