Chromium Code Reviews| Index: runtime/vm/assembler_x64.h |
| diff --git a/runtime/vm/assembler_x64.h b/runtime/vm/assembler_x64.h |
| index b4b0ee8744d57c605991194f5274429714ceea8b..2d2db8e2bf2ead6bdf24d7cb23246d04936e6fb6 100644 |
| --- a/runtime/vm/assembler_x64.h |
| +++ b/runtime/vm/assembler_x64.h |
| @@ -530,6 +530,9 @@ class Assembler : public ValueObject { |
| void Align(int alignment, int offset); |
| void Bind(Label* label); |
| + void Comment(const char* format, ...); |
| + CodeComments GetComments(); |
|
srdjan
2012/05/17 17:22:08
ditto from ia32
Vyacheslav Egorov (Google)
2012/05/17 21:16:27
Done.
|
| + |
| int CodeSize() const { return buffer_.Size(); } |
| int prolog_offset() const { return prolog_offset_; } |
| const ZoneGrowableArray<int>& GetPointerOffsets() const { |
| @@ -552,6 +555,21 @@ class Assembler : public ValueObject { |
| AssemblerBuffer buffer_; |
| int prolog_offset_; |
| + class CodeComment : public ZoneAllocated { |
| + public: |
| + CodeComment(intptr_t pc, const String& comment) |
| + : pc_(pc), comment_(comment) { } |
| + |
| + intptr_t pc() const { return pc_; } |
| + const String& comment() const { return comment_; } |
| + |
| + private: |
| + intptr_t pc_; |
| + const String& comment_; |
| + }; |
| + |
| + GrowableArray<CodeComment*> comments_; |
| + |
| inline void EmitUint8(uint8_t value); |
| inline void EmitInt32(int32_t value); |
| inline void EmitInt64(int64_t value); |