|
Fix calls of strict mode function with an implicit receiver.
Only IA32 version for now. I'll start porting.
Strict mode functions are to get 'undefined' as the receiver when
called with an implicit receiver. Modes are bad! It forces us to have
checks on all function calls.
This change attempts to limit the cost by passing information about
whether or not a call is with an implicit or explicit receiver in ecx
as part of the calling convention. The cost is setting ecx on all
calls and checking ecx on entry to strict mode functions.
Implicit/explicit receiver state has to be maintained by ICs. Various
stubs have to not clobber ecx or save and restore it.
CallFunction stub needs to check if the receiver is implicit when it
doesn't know from the context.
Committed: http://code.google.com/p/v8/source/detail?r=8040
Total comments: 23
Total comments: 2
Total comments: 5
|
Unified diffs |
Side-by-side diffs |
Delta from patch set |
Stats (+1122 lines, -429 lines) |
Patch |
 |
M |
src/arm/builtins-arm.cc
|
View
|
1
2
3
4
5
6
|
6 chunks |
+14 lines, -0 lines |
0 comments
|
Download
|
 |
M |
src/arm/code-stubs-arm.cc
|
View
|
1
2
3
4
5
6
|
2 chunks |
+27 lines, -23 lines |
0 comments
|
Download
|
 |
M |
src/arm/full-codegen-arm.cc
|
View
|
1
2
3
4
5
6
|
8 chunks |
+28 lines, -11 lines |
0 comments
|
Download
|
 |
M |
src/arm/ic-arm.cc
|
View
|
1
2
3
4
5
|
8 chunks |
+30 lines, -12 lines |
0 comments
|
Download
|
 |
M |
src/arm/lithium-arm.cc
|
View
|
1
2
3
4
5
|
1 chunk |
+2 lines, -1 line |
0 comments
|
Download
|
 |
M |
src/arm/lithium-codegen-arm.h
|
View
|
1
2
3
4
5
6
|
1 chunk |
+2 lines, -1 line |
0 comments
|
Download
|
 |
M |
src/arm/lithium-codegen-arm.cc
|
View
|
1
2
3
4
5
6
|
8 chunks |
+30 lines, -9 lines |
0 comments
|
Download
|
 |
M |
src/arm/macro-assembler-arm.h
|
View
|
1
2
3
4
5
6
|
2 chunks |
+13 lines, -4 lines |
0 comments
|
Download
|
 |
M |
src/arm/macro-assembler-arm.cc
|
View
|
1
2
3
4
5
6
|
6 chunks |
+32 lines, -7 lines |
0 comments
|
Download
|
 |
M |
src/arm/stub-cache-arm.cc
|
View
|
1
2
3
4
5
6
|
5 chunks |
+24 lines, -12 lines |
0 comments
|
Download
|
 |
M |
src/ast.h
|
View
|
1
2
3
4
|
1 chunk |
+2 lines, -1 line |
0 comments
|
Download
|
 |
M |
src/ast.cc
|
View
|
1
2
3
4
|
1 chunk |
+3 lines, -2 lines |
0 comments
|
Download
|
 |
M |
src/code-stubs.h
|
View
|
1
2
3
4
5
6
|
1 chunk |
+3 lines, -2 lines |
0 comments
|
Download
|
 |
M |
src/compiler.cc
|
View
|
1
2
3
4
5
6
|
1 chunk |
+1 line, -0 lines |
0 comments
|
Download
|
 |
M |
src/debug.cc
|
View
|
1
2
3
4
5
6
|
2 chunks |
+2 lines, -2 lines |
0 comments
|
Download
|
 |
M |
src/frames.cc
|
View
|
1
2
3
|
2 chunks |
+21 lines, -15 lines |
0 comments
|
Download
|
 |
M |
src/full-codegen.h
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
src/hydrogen.h
|
View
|
1
2
3
4
|
1 chunk |
+2 lines, -1 line |
0 comments
|
Download
|
 |
M |
src/hydrogen.cc
|
View
|
1
2
3
4
|
7 chunks |
+26 lines, -10 lines |
0 comments
|
Download
|
 |
M |
src/hydrogen-instructions.h
|
View
|
1
2
3
4
|
2 chunks |
+8 lines, -2 lines |
0 comments
|
Download
|
 |
M |
src/ia32/builtins-ia32.cc
|
View
|
1
2
3
4
5
6
|
9 chunks |
+41 lines, -22 lines |
0 comments
|
Download
|
 |
M |
src/ia32/code-stubs-ia32.cc
|
View
|
1
2
3
4
5
6
|
2 chunks |
+26 lines, -23 lines |
0 comments
|
Download
|
 |
M |
src/ia32/full-codegen-ia32.cc
|
View
|
1
2
3
4
5
6
|
8 chunks |
+28 lines, -12 lines |
0 comments
|
Download
|
 |
M |
src/ia32/ic-ia32.cc
|
View
|
1
2
3
4
|
9 chunks |
+29 lines, -12 lines |
0 comments
|
Download
|
 |
M |
src/ia32/lithium-codegen-ia32.h
|
View
|
1
2
3
4
|
1 chunk |
+2 lines, -1 line |
0 comments
|
Download
|
 |
M |
src/ia32/lithium-codegen-ia32.cc
|
View
|
1
2
3
4
5
6
|
7 chunks |
+32 lines, -10 lines |
0 comments
|
Download
|
 |
M |
src/ia32/lithium-ia32.cc
|
View
|
1
2
3
4
|
1 chunk |
+2 lines, -1 line |
0 comments
|
Download
|
 |
M |
src/ia32/macro-assembler-ia32.h
|
View
|
1
2
3
4
5
6
|
2 chunks |
+13 lines, -4 lines |
0 comments
|
Download
|
 |
M |
src/ia32/macro-assembler-ia32.cc
|
View
|
1
2
3
4
5
6
|
7 chunks |
+35 lines, -7 lines |
0 comments
|
Download
|
 |
M |
src/ia32/stub-cache-ia32.cc
|
View
|
1
2
3
4
|
5 chunks |
+22 lines, -10 lines |
0 comments
|
Download
|
 |
M |
src/ic.h
|
View
|
1
2
3
4
5
6
|
4 chunks |
+17 lines, -5 lines |
0 comments
|
Download
|
 |
M |
src/ic.cc
|
View
|
1
2
3
4
5
6
|
10 chunks |
+21 lines, -9 lines |
0 comments
|
Download
|
 |
M |
src/objects-inl.h
|
View
|
1
2
3
4
5
6
|
1 chunk |
+3 lines, -4 lines |
0 comments
|
Download
|
 |
M |
src/runtime.cc
|
View
|
1
2
3
4
5
6
|
8 chunks |
+20 lines, -19 lines |
0 comments
|
Download
|
 |
M |
src/stub-cache.h
|
View
|
1
2
3
4
5
6
|
4 chunks |
+45 lines, -27 lines |
0 comments
|
Download
|
 |
M |
src/stub-cache.cc
|
View
|
1
2
3
4
|
23 chunks |
+87 lines, -39 lines |
0 comments
|
Download
|
 |
M |
src/type-info.h
|
View
|
1
2
3
4
|
1 chunk |
+3 lines, -1 line |
0 comments
|
Download
|
 |
M |
src/type-info.cc
|
View
|
1
2
3
4
5
6
|
2 chunks |
+9 lines, -9 lines |
0 comments
|
Download
|
 |
M |
src/utils.h
|
View
|
|
1 chunk |
+5 lines, -0 lines |
0 comments
|
Download
|
 |
M |
src/v8globals.h
|
View
|
1
2
3
4
|
2 chunks |
+11 lines, -1 line |
0 comments
|
Download
|
 |
M |
src/x64/builtins-x64.cc
|
View
|
1
2
3
4
5
6
|
9 chunks |
+33 lines, -17 lines |
0 comments
|
Download
|
 |
M |
src/x64/code-stubs-x64.cc
|
View
|
1
2
3
4
5
6
|
2 chunks |
+26 lines, -22 lines |
0 comments
|
Download
|
 |
M |
src/x64/full-codegen-x64.cc
|
View
|
1
2
3
4
5
6
|
8 chunks |
+28 lines, -11 lines |
0 comments
|
Download
|
 |
M |
src/x64/ic-x64.cc
|
View
|
1
2
3
4
5
|
9 chunks |
+30 lines, -12 lines |
0 comments
|
Download
|
 |
M |
src/x64/lithium-codegen-x64.h
|
View
|
1
2
3
4
5
|
1 chunk |
+2 lines, -1 line |
0 comments
|
Download
|
 |
M |
src/x64/lithium-codegen-x64.cc
|
View
|
1
2
3
4
5
6
|
8 chunks |
+32 lines, -10 lines |
0 comments
|
Download
|
 |
M |
src/x64/lithium-x64.cc
|
View
|
1
2
3
4
5
|
1 chunk |
+2 lines, -1 line |
0 comments
|
Download
|
 |
M |
src/x64/macro-assembler-x64.h
|
View
|
1
2
3
4
5
6
|
2 chunks |
+14 lines, -5 lines |
0 comments
|
Download
|
 |
M |
src/x64/macro-assembler-x64.cc
|
View
|
1
2
3
4
5
6
|
8 chunks |
+33 lines, -7 lines |
0 comments
|
Download
|
 |
M |
src/x64/stub-cache-x64.cc
|
View
|
1
2
3
4
5
|
5 chunks |
+24 lines, -11 lines |
0 comments
|
Download
|
 |
A |
test/mjsunit/strict-mode-implicit-receiver.js
|
View
|
1
2
3
4
|
1 chunk |
+176 lines, -0 lines |
0 comments
|
Download
|
Total messages: 8 (0 generated)
|