Commit 1041f58e authored by yangguo@chromium.org's avatar yangguo@chromium.org

Use Cell instead of PropertyCell in DoCheckFunction (in case of new space object).

R=danno@chromium.org
BUG=

Review URL: https://codereview.chromium.org/23036004

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@16175 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent 415b61e1
......@@ -5150,7 +5150,7 @@ void LCodeGen::DoCheckFunction(LCheckFunction* instr) {
AllowDeferredHandleDereference smi_check;
if (isolate()->heap()->InNewSpace(*target)) {
Register reg = ToRegister(instr->value());
Handle<Cell> cell = isolate()->factory()->NewPropertyCell(target);
Handle<Cell> cell = isolate()->factory()->NewCell(target);
__ mov(ip, Operand(Handle<Object>(cell)));
__ ldr(ip, FieldMemOperand(ip, Cell::kValueOffset));
__ cmp(reg, ip);
......
......@@ -5121,7 +5121,7 @@ void LCodeGen::DoCheckFunction(LCheckFunction* instr) {
AllowDeferredHandleDereference smi_check;
if (isolate()->heap()->InNewSpace(*target)) {
Register reg = ToRegister(instr->value());
Handle<Cell> cell = isolate()->factory()->NewPropertyCell(target);
Handle<Cell> cell = isolate()->factory()->NewCell(target);
__ li(at, Operand(Handle<Object>(cell)));
__ lw(at, FieldMemOperand(at, Cell::kValueOffset));
DeoptimizeIf(ne, instr->environment(), reg,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment