Hello,
i have performance problem. When grid height, width is set on 100% browser takes to much of CPU, which could be problem on some low power computer. It's happening on all browsers. The worst performance is in my case is on IE (I have IE10, page is running in IE8 compatibility mode), but my colleague had worst experience with Chrome.
The problem disappears when height and width is set on fix size.
Is there any option how to fix this problem and keep width and height on 100% ? Thank you.
Best regards,
Martin Zagora
What did I do wrongly?
I'm using the latest version of IG Ignite.
Thanks
Martin
Yes it does. Unfortunately, some of our users have really bad computer still with Win XP... And when I have to use 3 grids (some of them in igDialogs) it takes them over 50% of CPU.
Does it really just compare and resize (or do whatever related work) only when window was resized or it does the work related to resizing anyway even the windows have not been resized? I think it does that work anyway because from my observation the CPU usage is related to number of rows. Am I right?
I can check size of the window and call some resize function from this script only when some resizing have happened. Would it be possible to do so? For example set the timer on couple of minutes and call resizing from other script?
Thanks for mentioning resizeTimeout property. I was searching for this property in the documentation, but I couldn't find it.
Hey,
is this CPU usage causing actual slow-down for your users? It only compares whether width/height has changed every 300 ms. this value can be easily changed (increased) by resetting it like that:
("#grid1").data("igGrid").resizeTimeout = <higher value>;
I also suggest to ensure you're using the latest javascript, because it may already include some optimizations related to your scenario.
Thanks,
Angel
Thanks you, but I tried it on my computer and it has NO effect at all on CPU usage. I ran some tests and I found out that number of rows has significant influence on usage of CPU and browsing mode (IE8, IE10) has no influence on CPU usage.
I could send you an email with unsimplified HTML, where 20 rows takes more than 10% of CPU. I don't want to present the code publicly.
I still believe that it is caused by grid resizing even if a grid is not being resized. Would it be possible to resize grid automatically only if the window is being resized? Timer set on 1000ms would be enough. But I still prefer proper solution of this problem, not workarounds :)
Thanks.
Hi Martin,
Thank you for your sample! It really helped me determine the issue. I ran the sample on a virtual machine with native Internet Explorer 8. And indeed the issue was pretty obvious. I tried to simplify the sample in order to find what causes it. I started removing unnecessary file references. The issue stopped reproducing after I removed the reference to the General.css. After that the CPU usage dropped about 4 times.
I’ll attach the simplified sample and a screenshot that shows the difference in the performance. You can uncomment the reference and try it on your machine.
Please let me know if you need more information.
Kind regards,
Petko Zhekov
Software Engineer