Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(161)

Side by Side Diff: src/ia32/lithium-codegen-ia32.cc

Issue 10914222: Fixed CHECK failure in LCodeGen::DoWrapReceiver when --deopt-every-n-times flag is present (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 8 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 2928 matching lines...) Expand 10 before | Expand all | Expand 10 after
2939 // object as a receiver to normal functions. Values have to be 2939 // object as a receiver to normal functions. Values have to be
2940 // passed unchanged to builtins and strict-mode functions. 2940 // passed unchanged to builtins and strict-mode functions.
2941 Label global_object, receiver_ok; 2941 Label global_object, receiver_ok;
2942 2942
2943 // Do not transform the receiver to object for strict mode 2943 // Do not transform the receiver to object for strict mode
2944 // functions. 2944 // functions.
2945 __ mov(scratch, 2945 __ mov(scratch,
2946 FieldOperand(function, JSFunction::kSharedFunctionInfoOffset)); 2946 FieldOperand(function, JSFunction::kSharedFunctionInfoOffset));
2947 __ test_b(FieldOperand(scratch, SharedFunctionInfo::kStrictModeByteOffset), 2947 __ test_b(FieldOperand(scratch, SharedFunctionInfo::kStrictModeByteOffset),
2948 1 << SharedFunctionInfo::kStrictModeBitWithinByte); 2948 1 << SharedFunctionInfo::kStrictModeBitWithinByte);
2949 __ j(not_equal, &receiver_ok, Label::kNear); 2949 __ j(not_equal, &receiver_ok); // A near jump is not sufficient here!
2950 2950
2951 // Do not transform the receiver to object for builtins. 2951 // Do not transform the receiver to object for builtins.
2952 __ test_b(FieldOperand(scratch, SharedFunctionInfo::kNativeByteOffset), 2952 __ test_b(FieldOperand(scratch, SharedFunctionInfo::kNativeByteOffset),
2953 1 << SharedFunctionInfo::kNativeBitWithinByte); 2953 1 << SharedFunctionInfo::kNativeBitWithinByte);
2954 __ j(not_equal, &receiver_ok, Label::kNear); 2954 __ j(not_equal, &receiver_ok);
2955 2955
2956 // Normal function. Replace undefined or null with global receiver. 2956 // Normal function. Replace undefined or null with global receiver.
2957 __ cmp(receiver, factory()->null_value()); 2957 __ cmp(receiver, factory()->null_value());
2958 __ j(equal, &global_object, Label::kNear); 2958 __ j(equal, &global_object, Label::kNear);
2959 __ cmp(receiver, factory()->undefined_value()); 2959 __ cmp(receiver, factory()->undefined_value());
2960 __ j(equal, &global_object, Label::kNear); 2960 __ j(equal, &global_object, Label::kNear);
2961 2961
2962 // The receiver should be a JS object. 2962 // The receiver should be a JS object.
2963 __ test(receiver, Immediate(kSmiTagMask)); 2963 __ test(receiver, Immediate(kSmiTagMask));
2964 DeoptimizeIf(equal, instr->environment()); 2964 DeoptimizeIf(equal, instr->environment());
(...skipping 2548 matching lines...) Expand 10 before | Expand all | Expand 10 after
5513 FixedArray::kHeaderSize - kPointerSize)); 5513 FixedArray::kHeaderSize - kPointerSize));
5514 __ bind(&done); 5514 __ bind(&done);
5515 } 5515 }
5516 5516
5517 5517
5518 #undef __ 5518 #undef __
5519 5519
5520 } } // namespace v8::internal 5520 } } // namespace v8::internal
5521 5521
5522 #endif // V8_TARGET_ARCH_IA32 5522 #endif // V8_TARGET_ARCH_IA32
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698