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

Side by Side Diff: src/x64/macro-assembler-x64.h

Issue 195061: Control profiling/debugger support from build script (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: '' Created 11 years, 3 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 | Annotate | Revision Log
« no previous file with comments | « src/x64/codegen-x64.cc ('k') | src/x64/macro-assembler-x64.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 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 571 matching lines...) Expand 10 before | Expand all | Expand 10 after
582 582
583 // Allocation support helpers. 583 // Allocation support helpers.
584 void LoadAllocationTopHelper(Register result, 584 void LoadAllocationTopHelper(Register result,
585 Register result_end, 585 Register result_end,
586 Register scratch, 586 Register scratch,
587 AllocationFlags flags); 587 AllocationFlags flags);
588 void UpdateAllocationTopHelper(Register result_end, Register scratch); 588 void UpdateAllocationTopHelper(Register result_end, Register scratch);
589 }; 589 };
590 590
591 591
592 #ifdef ENABLE_DEBUGGER_SUPPORT
593 // The code patcher is used to patch (typically) small parts of code e.g. for 592 // The code patcher is used to patch (typically) small parts of code e.g. for
594 // debugging and other types of instrumentation. When using the code patcher 593 // debugging and other types of instrumentation. When using the code patcher
595 // the exact number of bytes specified must be emitted. Is not legal to emit 594 // the exact number of bytes specified must be emitted. Is not legal to emit
596 // relocation information. If any of these constraints are violated it causes 595 // relocation information. If any of these constraints are violated it causes
597 // an assertion. 596 // an assertion.
598 class CodePatcher { 597 class CodePatcher {
599 public: 598 public:
600 CodePatcher(byte* address, int size); 599 CodePatcher(byte* address, int size);
601 virtual ~CodePatcher(); 600 virtual ~CodePatcher();
602 601
603 // Macro assembler to emit code. 602 // Macro assembler to emit code.
604 MacroAssembler* masm() { return &masm_; } 603 MacroAssembler* masm() { return &masm_; }
605 604
606 private: 605 private:
607 byte* address_; // The address of the code being patched. 606 byte* address_; // The address of the code being patched.
608 int size_; // Number of bytes of the expected patch size. 607 int size_; // Number of bytes of the expected patch size.
609 MacroAssembler masm_; // Macro assembler used to generate the code. 608 MacroAssembler masm_; // Macro assembler used to generate the code.
610 }; 609 };
611 #endif // ENABLE_DEBUGGER_SUPPORT
612 610
613 611
614 // ----------------------------------------------------------------------------- 612 // -----------------------------------------------------------------------------
615 // Static helper functions. 613 // Static helper functions.
616 614
617 // Generate an Operand for loading a field from an object. 615 // Generate an Operand for loading a field from an object.
618 static inline Operand FieldOperand(Register object, int offset) { 616 static inline Operand FieldOperand(Register object, int offset) {
619 return Operand(object, offset - kHeapObjectTag); 617 return Operand(object, offset - kHeapObjectTag);
620 } 618 }
621 619
(...skipping 25 matching lines...) Expand all
647 } \ 645 } \
648 masm-> 646 masm->
649 #else 647 #else
650 #define ACCESS_MASM(masm) masm-> 648 #define ACCESS_MASM(masm) masm->
651 #endif 649 #endif
652 650
653 651
654 } } // namespace v8::internal 652 } } // namespace v8::internal
655 653
656 #endif // V8_X64_MACRO_ASSEMBLER_X64_H_ 654 #endif // V8_X64_MACRO_ASSEMBLER_X64_H_
OLDNEW
« no previous file with comments | « src/x64/codegen-x64.cc ('k') | src/x64/macro-assembler-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698