OLD | NEW |
1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 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/v8.h" | 5 #include "src/v8.h" |
6 | 6 |
7 #include "src/ic/call-optimization.h" | 7 #include "src/ic/call-optimization.h" |
8 #include "src/ic/handler-compiler.h" | 8 #include "src/ic/handler-compiler.h" |
9 #include "src/ic/ic.h" | 9 #include "src/ic/ic.h" |
10 #include "src/ic/ic-inl.h" | 10 #include "src/ic/ic-inl.h" |
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
68 return handler; | 68 return handler; |
69 } | 69 } |
70 | 70 |
71 | 71 |
72 Handle<Code> PropertyHandlerCompiler::GetCode(Code::Kind kind, | 72 Handle<Code> PropertyHandlerCompiler::GetCode(Code::Kind kind, |
73 Code::StubType type, | 73 Code::StubType type, |
74 Handle<Name> name) { | 74 Handle<Name> name) { |
75 Code::Flags flags = Code::ComputeHandlerFlags(kind, type, cache_holder()); | 75 Code::Flags flags = Code::ComputeHandlerFlags(kind, type, cache_holder()); |
76 Handle<Code> code = GetCodeWithFlags(flags, name); | 76 Handle<Code> code = GetCodeWithFlags(flags, name); |
77 PROFILE(isolate(), CodeCreateEvent(Logger::STUB_TAG, *code, *name)); | 77 PROFILE(isolate(), CodeCreateEvent(Logger::STUB_TAG, *code, *name)); |
| 78 #ifdef DEBUG |
| 79 code->VerifyEmbeddedObjects(); |
| 80 #endif |
78 return code; | 81 return code; |
79 } | 82 } |
80 | 83 |
81 | 84 |
82 void PropertyHandlerCompiler::set_type_for_object(Handle<Object> object) { | 85 void PropertyHandlerCompiler::set_type_for_object(Handle<Object> object) { |
83 type_ = IC::CurrentTypeOf(object, isolate()); | 86 type_ = IC::CurrentTypeOf(object, isolate()); |
84 } | 87 } |
85 | 88 |
86 | 89 |
87 #define __ ACCESS_MASM(masm()) | 90 #define __ ACCESS_MASM(masm()) |
(...skipping 427 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
515 DCHECK(elements_kind == DICTIONARY_ELEMENTS); | 518 DCHECK(elements_kind == DICTIONARY_ELEMENTS); |
516 cached_stub = LoadDictionaryElementStub(isolate()).GetCode(); | 519 cached_stub = LoadDictionaryElementStub(isolate()).GetCode(); |
517 } | 520 } |
518 } | 521 } |
519 | 522 |
520 handlers->Add(cached_stub); | 523 handlers->Add(cached_stub); |
521 } | 524 } |
522 } | 525 } |
523 } | 526 } |
524 } // namespace v8::internal | 527 } // namespace v8::internal |
OLD | NEW |