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

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

Issue 211393007: Backport https://code.google.com/p/v8/source/detail?r=19360 to 3.24.35 (Closed) Base URL: https://github.com/v8/v8.git@3.24
Patch Set: Created 6 years, 8 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 | « src/arm/lithium-arm.cc ('k') | src/codegen.cc » ('j') | 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 266 matching lines...) Expand 10 before | Expand all | Expand 10 after
277 277
278 278
279 bool LCodeGen::GenerateDeferredCode() { 279 bool LCodeGen::GenerateDeferredCode() {
280 ASSERT(is_generating()); 280 ASSERT(is_generating());
281 if (deferred_.length() > 0) { 281 if (deferred_.length() > 0) {
282 for (int i = 0; !is_aborted() && i < deferred_.length(); i++) { 282 for (int i = 0; !is_aborted() && i < deferred_.length(); i++) {
283 LDeferredCode* code = deferred_[i]; 283 LDeferredCode* code = deferred_[i];
284 284
285 HValue* value = 285 HValue* value =
286 instructions_->at(code->instruction_index())->hydrogen_value(); 286 instructions_->at(code->instruction_index())->hydrogen_value();
287 RecordAndWritePosition(value->position()); 287 RecordAndWritePosition(
288 chunk()->graph()->SourcePositionToScriptPosition(value->position()));
288 289
289 Comment(";;; <@%d,#%d> " 290 Comment(";;; <@%d,#%d> "
290 "-------------------- Deferred %s --------------------", 291 "-------------------- Deferred %s --------------------",
291 code->instruction_index(), 292 code->instruction_index(),
292 code->instr()->hydrogen_value()->id(), 293 code->instr()->hydrogen_value()->id(),
293 code->instr()->Mnemonic()); 294 code->instr()->Mnemonic());
294 __ bind(code->entry()); 295 __ bind(code->entry());
295 if (NeedsDeferredFrame()) { 296 if (NeedsDeferredFrame()) {
296 Comment(";;; Build frame"); 297 Comment(";;; Build frame");
297 ASSERT(!frame_is_built_); 298 ASSERT(!frame_is_built_);
(...skipping 608 matching lines...) Expand 10 before | Expand all | Expand 10 after
906 void LCodeGen::PopulateDeoptimizationData(Handle<Code> code) { 907 void LCodeGen::PopulateDeoptimizationData(Handle<Code> code) {
907 int length = deoptimizations_.length(); 908 int length = deoptimizations_.length();
908 if (length == 0) return; 909 if (length == 0) return;
909 Handle<DeoptimizationInputData> data = 910 Handle<DeoptimizationInputData> data =
910 factory()->NewDeoptimizationInputData(length, TENURED); 911 factory()->NewDeoptimizationInputData(length, TENURED);
911 912
912 Handle<ByteArray> translations = 913 Handle<ByteArray> translations =
913 translations_.CreateByteArray(isolate()->factory()); 914 translations_.CreateByteArray(isolate()->factory());
914 data->SetTranslationByteArray(*translations); 915 data->SetTranslationByteArray(*translations);
915 data->SetInlinedFunctionCount(Smi::FromInt(inlined_function_count_)); 916 data->SetInlinedFunctionCount(Smi::FromInt(inlined_function_count_));
917 data->SetOptimizationId(Smi::FromInt(info_->optimization_id()));
916 918
917 Handle<FixedArray> literals = 919 Handle<FixedArray> literals =
918 factory()->NewFixedArray(deoptimization_literals_.length(), TENURED); 920 factory()->NewFixedArray(deoptimization_literals_.length(), TENURED);
919 { AllowDeferredHandleDereference copy_handles; 921 { AllowDeferredHandleDereference copy_handles;
920 for (int i = 0; i < deoptimization_literals_.length(); i++) { 922 for (int i = 0; i < deoptimization_literals_.length(); i++) {
921 literals->set(i, *deoptimization_literals_[i]); 923 literals->set(i, *deoptimization_literals_[i]);
922 } 924 }
923 data->SetLiteralArray(*literals); 925 data->SetLiteralArray(*literals);
924 } 926 }
925 927
(...skipping 4823 matching lines...) Expand 10 before | Expand all | Expand 10 after
5749 __ sub(scratch, result, Operand::PointerOffsetFromSmiKey(index)); 5751 __ sub(scratch, result, Operand::PointerOffsetFromSmiKey(index));
5750 __ ldr(result, FieldMemOperand(scratch, 5752 __ ldr(result, FieldMemOperand(scratch,
5751 FixedArray::kHeaderSize - kPointerSize)); 5753 FixedArray::kHeaderSize - kPointerSize));
5752 __ bind(&done); 5754 __ bind(&done);
5753 } 5755 }
5754 5756
5755 5757
5756 #undef __ 5758 #undef __
5757 5759
5758 } } // namespace v8::internal 5760 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/arm/lithium-arm.cc ('k') | src/codegen.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698