Index: src/assembler.h |
=================================================================== |
--- src/assembler.h (revision 13419) |
+++ src/assembler.h (working copy) |
@@ -842,6 +842,7 @@ |
#ifdef ENABLE_GDB_JIT_INTERFACE |
gdbjit_lineinfo_ = NULL; |
#endif |
+ user_data_ = NULL; |
danno
2013/02/01 13:43:10
please call this (and all names of variables deriv
|
} |
#ifdef ENABLE_GDB_JIT_INTERFACE |
@@ -861,7 +862,15 @@ |
return lineinfo; |
} |
#endif |
+ void InitializeUserData(void* user_data) { |
danno
2013/02/01 13:43:10
AttachJITHandlerData?
|
+ user_data_ = user_data; |
+ } |
+ void* DetachJITLineInfo() { |
danno
2013/02/01 13:43:10
DetachJITHandlerData?
|
+ void* old_user_data = user_data_; |
+ user_data_ = NULL; |
+ return old_user_data; |
+ } |
// Set current position to pos. |
void RecordPosition(int pos); |
@@ -877,13 +886,18 @@ |
return state_.current_statement_position; |
} |
+ Assembler* assembler() { |
+ return assembler_; |
+ } |
+ |
private: |
Assembler* assembler_; |
PositionState state_; |
#ifdef ENABLE_GDB_JIT_INTERFACE |
GDBJITLineInfo* gdbjit_lineinfo_; |
#endif |
- |
+ // Currently user_data_ is used to keep the JITted code line info. |
danno
2013/02/01 13:43:10
I don't think this comment is exactly correct. It
|
+ void* user_data_; |
friend class PreservePositionScope; |
DISALLOW_COPY_AND_ASSIGN(PositionsRecorder); |