|
Simplify and optimize ToBoolean handling.
Changing our builtin JavaScript code slightly, we can make sure that we never
see internal objects as arguments for ToBoolean at runtime. Removing that case
from the stub generator and crankshaft makes things a lot easier.
Heap numbers can never be undetectable (only strings and spec objects can), so
we can leave out a useless test.
Try to re-use a non-null register value when returning 'true' in some cases.
Removed special handling of the 'handle all' case, it will very probably never
happen in real code and only makes things more complicated.
Improved naming of the ToBoolean stubs a bit, reflecting the order in which
cases are handled in the code itself.
Committed: http://code.google.com/p/v8/source/detail?r=8886
Total comments: 4
|
Unified diffs |
Side-by-side diffs |
Delta from patch set |
Stats (+138 lines, -304 lines) |
Patch |
|
M |
src/apinatives.js
|
View
|
|
2 chunks |
+11 lines, -3 lines |
4 comments
|
Download
|
|
M |
src/arm/code-stubs-arm.cc
|
View
|
|
6 chunks |
+14 lines, -40 lines |
0 comments
|
Download
|
|
M |
src/arm/lithium-arm.cc
|
View
|
|
1 chunk |
+1 line, -7 lines |
0 comments
|
Download
|
|
M |
src/arm/lithium-codegen-arm.cc
|
View
|
|
4 chunks |
+9 lines, -51 lines |
0 comments
|
Download
|
|
M |
src/code-stubs.h
|
View
|
|
4 chunks |
+2 lines, -4 lines |
0 comments
|
Download
|
|
M |
src/code-stubs.cc
|
View
|
|
3 chunks |
+13 lines, -7 lines |
0 comments
|
Download
|
|
M |
src/ia32/code-stubs-ia32.cc
|
View
|
|
5 chunks |
+34 lines, -46 lines |
0 comments
|
Download
|
|
M |
src/ia32/lithium-codegen-ia32.cc
|
View
|
|
4 chunks |
+10 lines, -47 lines |
0 comments
|
Download
|
|
M |
src/ia32/lithium-ia32.cc
|
View
|
|
1 chunk |
+1 line, -4 lines |
0 comments
|
Download
|
|
M |
src/x64/code-stubs-x64.cc
|
View
|
|
5 chunks |
+33 lines, -45 lines |
0 comments
|
Download
|
|
M |
src/x64/lithium-codegen-x64.cc
|
View
|
|
4 chunks |
+9 lines, -45 lines |
0 comments
|
Download
|
|
M |
src/x64/lithium-x64.cc
|
View
|
|
1 chunk |
+1 line, -5 lines |
0 comments
|
Download
|
Total messages: 3 (0 generated)
|