OLD | NEW |
1 // Copyright 2009 the V8 project authors. All rights reserved. | 1 // Copyright 2009 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 382 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
393 } | 393 } |
394 | 394 |
395 void Move(const Operand& dst, Smi* source) { | 395 void Move(const Operand& dst, Smi* source) { |
396 Set(dst, reinterpret_cast<int64_t>(source)); | 396 Set(dst, reinterpret_cast<int64_t>(source)); |
397 } | 397 } |
398 | 398 |
399 void Push(Smi* smi); | 399 void Push(Smi* smi); |
400 void Test(const Operand& dst, Smi* source); | 400 void Test(const Operand& dst, Smi* source); |
401 | 401 |
402 // --------------------------------------------------------------------------- | 402 // --------------------------------------------------------------------------- |
403 // Macro instructions | 403 // Macro instructions. |
404 | 404 |
405 // Load a register with a long value as efficiently as possible. | 405 // Load a register with a long value as efficiently as possible. |
406 void Set(Register dst, int64_t x); | 406 void Set(Register dst, int64_t x); |
407 void Set(const Operand& dst, int64_t x); | 407 void Set(const Operand& dst, int64_t x); |
408 | 408 |
409 // Handle support | 409 // Handle support |
410 void Move(Register dst, Handle<Object> source); | 410 void Move(Register dst, Handle<Object> source); |
411 void Move(const Operand& dst, Handle<Object> source); | 411 void Move(const Operand& dst, Handle<Object> source); |
412 void Cmp(Register dst, Handle<Object> source); | 412 void Cmp(Register dst, Handle<Object> source); |
413 void Cmp(const Operand& dst, Handle<Object> source); | 413 void Cmp(const Operand& dst, Handle<Object> source); |
414 void Push(Handle<Object> source); | 414 void Push(Handle<Object> source); |
| 415 void Drop(int stack_elements); |
| 416 void Call(Label* target) { call(target); } |
415 | 417 |
416 // Control Flow | 418 // Control Flow |
417 void Jump(Address destination, RelocInfo::Mode rmode); | 419 void Jump(Address destination, RelocInfo::Mode rmode); |
418 void Jump(ExternalReference ext); | 420 void Jump(ExternalReference ext); |
419 void Jump(Handle<Code> code_object, RelocInfo::Mode rmode); | 421 void Jump(Handle<Code> code_object, RelocInfo::Mode rmode); |
420 | 422 |
421 void Call(Address destination, RelocInfo::Mode rmode); | 423 void Call(Address destination, RelocInfo::Mode rmode); |
422 void Call(ExternalReference ext); | 424 void Call(ExternalReference ext); |
423 void Call(Handle<Code> code_object, RelocInfo::Mode rmode); | 425 void Call(Handle<Code> code_object, RelocInfo::Mode rmode); |
424 | 426 |
(...skipping 11 matching lines...) Expand all Loading... |
436 // jcc instructions (je, ja, jae, jb, jbe, je, and jz). | 438 // jcc instructions (je, ja, jae, jb, jbe, je, and jz). |
437 void FCmp(); | 439 void FCmp(); |
438 | 440 |
439 // --------------------------------------------------------------------------- | 441 // --------------------------------------------------------------------------- |
440 // Exception handling | 442 // Exception handling |
441 | 443 |
442 // Push a new try handler and link into try handler chain. The return | 444 // Push a new try handler and link into try handler chain. The return |
443 // address must be pushed before calling this helper. | 445 // address must be pushed before calling this helper. |
444 void PushTryHandler(CodeLocation try_location, HandlerType type); | 446 void PushTryHandler(CodeLocation try_location, HandlerType type); |
445 | 447 |
| 448 // Unlink the stack handler on top of the stack from the try handler chain. |
| 449 void PopTryHandler(); |
446 | 450 |
447 // --------------------------------------------------------------------------- | 451 // --------------------------------------------------------------------------- |
448 // Inline caching support | 452 // Inline caching support |
449 | 453 |
450 // Generates code that verifies that the maps of objects in the | 454 // Generates code that verifies that the maps of objects in the |
451 // prototype chain of object hasn't changed since the code was | 455 // prototype chain of object hasn't changed since the code was |
452 // generated and branches to the miss label if any map has. If | 456 // generated and branches to the miss label if any map has. If |
453 // necessary the function also generates code for security check | 457 // necessary the function also generates code for security check |
454 // in case of global object holders. The scratch and holder | 458 // in case of global object holders. The scratch and holder |
455 // registers are always clobbered, but the object register is only | 459 // registers are always clobbered, but the object register is only |
(...skipping 289 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
745 } \ | 749 } \ |
746 masm-> | 750 masm-> |
747 #else | 751 #else |
748 #define ACCESS_MASM(masm) masm-> | 752 #define ACCESS_MASM(masm) masm-> |
749 #endif | 753 #endif |
750 | 754 |
751 | 755 |
752 } } // namespace v8::internal | 756 } } // namespace v8::internal |
753 | 757 |
754 #endif // V8_X64_MACRO_ASSEMBLER_X64_H_ | 758 #endif // V8_X64_MACRO_ASSEMBLER_X64_H_ |
OLD | NEW |