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

Side by Side Diff: src/ic/ic.cc

Issue 2118493002: Revert of Add crash instrumentation for crbug.com/621147 (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 5 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
« 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 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "src/ic/ic.h" 5 #include "src/ic/ic.h"
6 6
7 #include "src/accessors.h" 7 #include "src/accessors.h"
8 #include "src/api-arguments-inl.h" 8 #include "src/api-arguments-inl.h"
9 #include "src/api.h" 9 #include "src/api.h"
10 #include "src/arguments.h" 10 #include "src/arguments.h"
(...skipping 2517 matching lines...) Expand 10 before | Expand all | Expand 10 after
2528 isolate, 2528 isolate,
2529 Runtime::SetObjectProperty(isolate, object, key, value, language_mode)); 2529 Runtime::SetObjectProperty(isolate, object, key, value, language_mode));
2530 } 2530 }
2531 2531
2532 2532
2533 MaybeHandle<Object> BinaryOpIC::Transition( 2533 MaybeHandle<Object> BinaryOpIC::Transition(
2534 Handle<AllocationSite> allocation_site, Handle<Object> left, 2534 Handle<AllocationSite> allocation_site, Handle<Object> left,
2535 Handle<Object> right) { 2535 Handle<Object> right) {
2536 BinaryOpICState state(isolate(), extra_ic_state()); 2536 BinaryOpICState state(isolate(), extra_ic_state());
2537 2537
2538 #ifdef V8_TARGET_ARCH_X64
2539 // Crash instrumentation for crbug.com/621147.
2540 uintptr_t left_raw = reinterpret_cast<uintptr_t>(*left);
2541 uintptr_t hole_raw =
2542 reinterpret_cast<uintptr_t>(isolate()->heap()->the_hole_value());
2543 if ((hole_raw & ((1ull << 32) - 1)) == (left_raw & ((1ull << 32) - 1))) {
2544 Code* c = GetCode();
2545 Code::Kind kind = c->kind();
2546 int instruction_size = c->instruction_size() + 2 * sizeof(Address);
2547 byte* instructions = static_cast<byte*>(alloca(instruction_size));
2548 Address* start = reinterpret_cast<Address*>(instructions);
2549 start[0] = fp();
2550 start[1] = pc();
2551 for (int i = 2 * sizeof(Address); i < instruction_size; i++) {
2552 instructions[i] = c->instruction_start()[i];
2553 }
2554 isolate()->PushStackTraceAndDie(0xBAAAAAAD, instructions, fp(),
2555 static_cast<unsigned int>(kind));
2556 }
2557 #endif // V8_TARGET_ARCH_X64
2558
2559 // Compute the actual result using the builtin for the binary operation. 2538 // Compute the actual result using the builtin for the binary operation.
2560 Handle<Object> result; 2539 Handle<Object> result;
2561 switch (state.op()) { 2540 switch (state.op()) {
2562 default: 2541 default:
2563 UNREACHABLE(); 2542 UNREACHABLE();
2564 case Token::ADD: 2543 case Token::ADD:
2565 ASSIGN_RETURN_ON_EXCEPTION(isolate(), result, 2544 ASSIGN_RETURN_ON_EXCEPTION(isolate(), result,
2566 Object::Add(isolate(), left, right), Object); 2545 Object::Add(isolate(), left, right), Object);
2567 break; 2546 break;
2568 case Token::SUB: 2547 case Token::SUB:
(...skipping 445 matching lines...) Expand 10 before | Expand all | Expand 10 after
3014 DCHECK_EQ(FeedbackVectorSlotKind::KEYED_LOAD_IC, 2993 DCHECK_EQ(FeedbackVectorSlotKind::KEYED_LOAD_IC,
3015 vector->GetKind(vector_slot)); 2994 vector->GetKind(vector_slot));
3016 KeyedLoadICNexus nexus(vector, vector_slot); 2995 KeyedLoadICNexus nexus(vector, vector_slot);
3017 KeyedLoadIC ic(IC::EXTRA_CALL_FRAME, isolate, &nexus); 2996 KeyedLoadIC ic(IC::EXTRA_CALL_FRAME, isolate, &nexus);
3018 ic.UpdateState(receiver, key); 2997 ic.UpdateState(receiver, key);
3019 RETURN_RESULT_OR_FAILURE(isolate, ic.Load(receiver, key)); 2998 RETURN_RESULT_OR_FAILURE(isolate, ic.Load(receiver, key));
3020 } 2999 }
3021 } 3000 }
3022 } // namespace internal 3001 } // namespace internal
3023 } // namespace v8 3002 } // namespace v8
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