Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Performance degradation in Dartium b/w 0.8.7 and 0.8.5 Dart releases (8x on sunflower demo) on Windows #14642

Closed
DartBot opened this issue Oct 31, 2013 · 7 comments
Labels
os-windows type-bug Incorrect behavior (everything from a crash to more subtle misbehavior)

Comments

@DartBot
Copy link

DartBot commented Oct 31, 2013

This issue was originally filed by @aam


There is visible degradation in performance of Dartium b/w 0.8.7 and 0.8.5 releases of Dart Editor.

To measure it I modified sunflower.dart so it draws 100 sunflowers size of 1900 to 2000 dots and exits.
0.8.5 version of Dartium exists in 2 seconds, 0.8.7 - in 17 seconds.

PS C:\g\dart-repo\dart> (measure-command {cmd /c C:\dart.28990\chromium\chrome.exe file:///C:/dart/sunflower/web/sunflower.html}).totalseconds
2.0040431

PS C:\g\dart-repo\dart> (measure-command {cmd /c C:\dart.29341\chromium\chrome.exe file:///C:/dart/sunflower/web/sunflower.html}).totalseconds
17.1227792

C:>diff sunflower-original\web\sunflower.html sunflower\web\sunflower.html

--- sunflower-original\web\sunflower.html Thu Oct 31 00:26:38 2013
+++ sunflower\web\sunflower.html Thu Oct 31 00:32:19 2013
@@ -16,9 +16,9 @­@
     <p>A canvas 2D demo.</p>

     <div id="container">

  •  &lt;canvas id=&quot;canvas&quot; width=&quot;300&quot; height=&quot;300&quot; class=&quot;center&quot;&gt;&lt;/canvas&gt;
    
  •  &lt;canvas id=&quot;canvas&quot; width=&quot;800&quot; height=&quot;800&quot; class=&quot;center&quot;&gt;&lt;/canvas&gt;
    
           <form class="center">
  •    &lt;input id=&quot;slider&quot; type=&quot;range&quot; max=&quot;1000&quot; value=&quot;500&quot;/&gt;
    
  •    &lt;input id=&quot;slider&quot; type=&quot;range&quot; max=&quot;2000&quot; value=&quot;500&quot;/&gt;
    
           </form>
           <br/>
           <img src="math.png" width="350px" height="42px" class="center">

C:>diff sunflower-original\web\sunflower.dart sunflower\web\sunflower.dart

--- sunflower-original\web\sunflower.dart Thu Oct 31 00:26:38 2013
+++ sunflower\web\sunflower.dart Thu Oct 31 00:25:30 2013
@@ -11,7 +11,7 @­@
 const int SEED_RADIUS = 2;
 const int SCALE_FACTOR = 4;
 const num TAU = PI * 2;
-const int MAX_D = 300;
+const int MAX_D = 600;
 const num centerX = MAX_D / 2;
 const num centerY = centerX;

@@ -23,8 +23,14 @­@
   (querySelector("#canvas") as CanvasElement).context2D;

 void main() {

  • slider.onChange.listen((e) => draw());
  • draw();
  • for (var i=1900; i < 2000; i++) {
  • slider.setAttribute("value", "$i");
  • draw();
  • }
  • window.close();
     }

 /// Draw the complete figure for the current number of seeds.

@vsmenon
Copy link
Member

vsmenon commented Oct 31, 2013

aprelev: some questions:

  • which version of windows? 32-bit or 64-bit?
  • do you see a similar difference with js / dart2js generated code?

@DartBot
Copy link
Author

DartBot commented Oct 31, 2013

This comment was originally written by @aam


Vijay,

  it's W8.1 64-bit.
  I see exact same difference b/w Chromiums when I force them to run javascript code. I force it by changing condition in packages/browser/dart.js file:

=== packages/browser/dart.js ===
...
(function() {
// Bootstrap support for Dart scripts on the page as this script.
if (false && navigator.webkitStartDart) {
...
===

@vsmenon
Copy link
Member

vsmenon commented Nov 14, 2013

aprelev: I wasn't able to recreate. Can you retry with the latest? We've merged in several upstream Chrome fixes.

@vsmenon
Copy link
Member

vsmenon commented Nov 14, 2013

Added this to the Later milestone.

@DartBot
Copy link
Author

DartBot commented Nov 15, 2013

This comment was originally written by @aam


Vijay, same slow performance in Chromium 31.0.1650.39 (1593) packaged with Dart 1.0.0.3_r30187:
===
PS C:\g\dart-repo\dart> (measure-command {cmd /c C:\dart.30187\chromium\chrome.exe file:///C:/dart/sunflower/web/sunflower.html}).totalseconds
15.6879496
===

@kasperl
Copy link

kasperl commented Jul 10, 2014

Removed this from the Later milestone.
Added Oldschool-Milestone-Later label.

@kasperl
Copy link

kasperl commented Aug 4, 2014

Removed Oldschool-Milestone-Later label.

@kevmoo kevmoo added type-bug Incorrect behavior (everything from a crash to more subtle misbehavior) and removed priority-unassigned labels Feb 29, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
os-windows type-bug Incorrect behavior (everything from a crash to more subtle misbehavior)
Projects
None yet
Development

No branches or pull requests

5 participants