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

dart2js: disable range check, $index, bailout #12059

Closed
DartBot opened this issue Jul 26, 2013 · 6 comments
Closed

dart2js: disable range check, $index, bailout #12059

DartBot opened this issue Jul 26, 2013 · 6 comments
Labels
type-enhancement A request for a change that isn't a bug web-dart2js

Comments

@DartBot
Copy link

DartBot commented Jul 26, 2013

This issue was originally filed by @davidB


What steps will reproduce the problem?

I make game (physics + rendering) that do lot of vectors manipulation each frame (via vector_math lib). But too many useless (IMHO as I test, and run the code in dartvm) defensive code is generated and run every frame.

See bug http://code.google.com/p/dart/issues/detail?id=9139 (Can someone re-open it)

I result is that the code run at 1 fps on firefox and I can up to 10 fps if I manually replace the generated js by the raw code (same as dart) in simple add, sub, setFrom function of Vector3.

What is the expected output?

a raw js without without range check, without $index, without bailout.

It seems to be a hard task for the code analyzer and ... So why not provide an option (command line, code annotation) to disable this defensive code and simply trust the developper (at its own risk).

I use dart as a better tool to create js (for chrome and firefox). If the generated js is useless (as is), then I don't need dart.

@madsager
Copy link
Contributor

Added Area-Dart2JS, Triaged labels.

@kasperl
Copy link

kasperl commented Sep 18, 2013

Added this to the M7 milestone.

@kasperl
Copy link

kasperl commented Sep 23, 2013

Removed this from the M7 milestone.
Added this to the Later milestone.
Removed Type-Defect, Priority-Unassigned labels.
Added Type-Enhancement, Priority-Medium labels.

@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.

@rakudrama
Copy link
Member

We no longer generate bailouts.
We have two experimental flags in the spirit of the request:
--trust-type-annotations
--trust-primitives

@kevmoo kevmoo added type-enhancement A request for a change that isn't a bug and removed triaged labels Mar 1, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type-enhancement A request for a change that isn't a bug web-dart2js
Projects
None yet
Development

No branches or pull requests

5 participants