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

Side by Side Diff: src/crankshaft/mips/lithium-codegen-mips.cc

Issue 2542403002: MIPS: Use JIC/JIALC offset when possible (Closed)
Patch Set: Created 4 years 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
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved.7 1 // Copyright 2012 the V8 project authors. All rights reserved.7
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 354 matching lines...) Expand 10 before | Expand all | Expand 10 after
365 365
366 Comment(";;; call deopt"); 366 Comment(";;; call deopt");
367 __ bind(&call_deopt_entry); 367 __ bind(&call_deopt_entry);
368 368
369 if (info()->saves_caller_doubles()) { 369 if (info()->saves_caller_doubles()) {
370 DCHECK(info()->IsStub()); 370 DCHECK(info()->IsStub());
371 RestoreCallerDoubles(); 371 RestoreCallerDoubles();
372 } 372 }
373 373
374 // Add the base address to the offset previously loaded in entry_offset. 374 // Add the base address to the offset previously loaded in entry_offset.
375 __ Addu(entry_offset, entry_offset, 375 if (IsMipsArchVariant(kMips32r6)) {
376 Operand(ExternalReference::ForDeoptEntry(base))); 376 uint32_t lui_offset, jic_offset;
377 __ Jump(entry_offset); 377 Assembler::UnpackTargetAddressUnsigned(
378 Operand(ExternalReference::ForDeoptEntry(base)).immediate(),
379 lui_offset, jic_offset);
380 masm()->RecordRelocInfo(
381 RelocInfo::EXTERNAL_REFERENCE,
382 Operand(ExternalReference::ForDeoptEntry(base)).immediate());
383 __ aui(entry_offset, entry_offset, lui_offset);
384 __ Jump(entry_offset, jic_offset);
385 } else {
386 __ Addu(entry_offset, entry_offset,
387 Operand(ExternalReference::ForDeoptEntry(base)));
388 __ Jump(entry_offset);
389 }
378 } 390 }
379 __ RecordComment("]"); 391 __ RecordComment("]");
380 392
381 // The deoptimization jump table is the last part of the instruction 393 // The deoptimization jump table is the last part of the instruction
382 // sequence. Mark the generated code as done unless we bailed out. 394 // sequence. Mark the generated code as done unless we bailed out.
383 if (!is_aborted()) status_ = DONE; 395 if (!is_aborted()) status_ = DONE;
384 return !is_aborted(); 396 return !is_aborted();
385 } 397 }
386 398
387 399
(...skipping 5026 matching lines...) Expand 10 before | Expand all | Expand 10 after
5414 __ lw(result, FieldMemOperand(scratch, 5426 __ lw(result, FieldMemOperand(scratch,
5415 FixedArray::kHeaderSize - kPointerSize)); 5427 FixedArray::kHeaderSize - kPointerSize));
5416 __ bind(deferred->exit()); 5428 __ bind(deferred->exit());
5417 __ bind(&done); 5429 __ bind(&done);
5418 } 5430 }
5419 5431
5420 #undef __ 5432 #undef __
5421 5433
5422 } // namespace internal 5434 } // namespace internal
5423 } // namespace v8 5435 } // namespace v8
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698