Home | History | Annotate | Download | only in src

Lines Matching refs:Code

6 //     * Redistributions of source code must retain the above copyright
31 #include "code-stubs.h"
53 bool CodeStub::FindCodeInCache(Code** code_out, Isolate* isolate) {
57 *code_out = Code::cast(stubs->ValueAt(index));
74 void CodeStub::RecordCodeGeneration(Code* code, Isolate* isolate) {
76 PROFILE(isolate, CodeCreateEvent(Logger::STUB_TAG, code, *name));
77 GDBJIT(AddCode(GDBJITInterface::STUB, *name, code));
79 counters->total_stubs_code_size()->Increment(code->instruction_size());
83 Code::Kind CodeStub::GetCodeKind() const {
84 return Code::STUB;
88 Handle<Code> CodeStub::GetCodeCopyFromTemplate(Isolate* isolate) {
89 Handle<Code> ic = GetCode(isolate);
96 Handle<Code> PlatformCodeStub::GenerateCode() {
100 // Generate the new code.
104 // Update the static counter each time a new code stub is generated.
110 // Generate the code for the stub.
116 // Create the code object.
120 // Copy the generated code into a heap object.
121 Code::Flags flags = Code::ComputeFlags(
127 Handle<Code> new_object = factory->NewCode(
133 Handle<Code> CodeStub::GetCode(Isolate* isolate) {
136 Code* code;
138 ? FindCodeInSpecialCache(&code, isolate)
139 : FindCodeInCache(&code, isolate)) {
140 ASSERT(IsPregenerated() == code->is_pregenerated());
141 return Handle<Code>(code);
147 Handle<Code> new_object = GenerateCode();
170 code = *new_object;
173 Activate(code);
175 heap->lo_space()->Contains(code) ||
176 heap->code_space()->FirstPage()->Contains(code->address()));
177 return Handle<Code>(code, isolate);
209 // generation code does not use any raw pointers.
344 void ICCompareStub::AddToSpecialCache(Handle<Code> new_object) {
356 bool ICCompareStub::FindCodeInSpecialCache(Code** code_out, Isolate* isolate) {
358 Code::Flags flags = Code::ComputeFlags(
370 *code_out = Code::cast(*probe);
575 void JSEntryStub::FinishCode(Handle<Code> code) {
577 code->GetIsolate()->factory()->NewFixedArray(1, TENURED);
579 code->set_handler_table(*handler_table);