Restrict the syntax that we aggressively optimize.
authorkmillikin@chromium.org <kmillikin@chromium.org@ce2b1a6d-e550-0410-aec6-3dcde31c8c00>
Wed, 10 Feb 2010 09:18:55 +0000 (09:18 +0000)
committerkmillikin@chromium.org <kmillikin@chromium.org@ce2b1a6d-e550-0410-aec6-3dcde31c8c00>
Wed, 10 Feb 2010 09:18:55 +0000 (09:18 +0000)
commit30cf88af6b405698dc6eee65201439bfe908361d
treeda03291b95667324ee42b18634367b25403425bf
parentd1d56d98913760eb9d5065205aaa2f2c88b05950
Restrict the syntax that we aggressively optimize.

Do not use the speculative compiler for functions with other than one
statement in the body, and do not use it if subexpressions can have
side effects.  Bailing out to the beginning of the full code is not
sound if side effects have already occurred.

Add tests that would fail without the restrictions.

Review URL: http://codereview.chromium.org/598016

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3826 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
src/fast-codegen.cc
test/mjsunit/compiler/simple-bailouts.js [new file with mode: 0644]