OLD | NEW |
1 // Copyright 2006-2008 the V8 project authors. All rights reserved. | 1 // Copyright 2006-2008 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 210 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
221 out.AddFormatted(" ;; object: %s", *obj_name); | 221 out.AddFormatted(" ;; object: %s", *obj_name); |
222 } else if (rmode == RelocInfo::EXTERNAL_REFERENCE) { | 222 } else if (rmode == RelocInfo::EXTERNAL_REFERENCE) { |
223 const char* reference_name = | 223 const char* reference_name = |
224 ref_encoder.NameOfAddress(*relocinfo.target_reference_address()); | 224 ref_encoder.NameOfAddress(*relocinfo.target_reference_address()); |
225 out.AddFormatted(" ;; external reference (%s)", reference_name); | 225 out.AddFormatted(" ;; external reference (%s)", reference_name); |
226 } else if (RelocInfo::IsCodeTarget(rmode)) { | 226 } else if (RelocInfo::IsCodeTarget(rmode)) { |
227 out.AddFormatted(" ;; code:"); | 227 out.AddFormatted(" ;; code:"); |
228 if (rmode == RelocInfo::CONSTRUCT_CALL) { | 228 if (rmode == RelocInfo::CONSTRUCT_CALL) { |
229 out.AddFormatted(" constructor,"); | 229 out.AddFormatted(" constructor,"); |
230 } | 230 } |
231 Code* code = Debug::GetCodeTarget(relocinfo.target_address()); | 231 Code* code = Code::GetCodeFromTargetAddress(relocinfo.target_address()); |
232 Code::Kind kind = code->kind(); | 232 Code::Kind kind = code->kind(); |
233 if (code->is_inline_cache_stub()) { | 233 if (code->is_inline_cache_stub()) { |
234 if (rmode == RelocInfo::CODE_TARGET_CONTEXT) { | 234 if (rmode == RelocInfo::CODE_TARGET_CONTEXT) { |
235 out.AddFormatted(" contextual,"); | 235 out.AddFormatted(" contextual,"); |
236 } | 236 } |
237 InlineCacheState ic_state = code->ic_state(); | 237 InlineCacheState ic_state = code->ic_state(); |
238 out.AddFormatted(" %s, %s", Code::Kind2String(kind), | 238 out.AddFormatted(" %s, %s", Code::Kind2String(kind), |
239 Code::ICState2String(ic_state)); | 239 Code::ICState2String(ic_state)); |
240 if (kind == Code::CALL_IC) { | 240 if (kind == Code::CALL_IC) { |
241 out.AddFormatted(", argc = %d", code->arguments_count()); | 241 out.AddFormatted(", argc = %d", code->arguments_count()); |
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
300 | 300 |
301 #else // ENABLE_DISASSEMBLER | 301 #else // ENABLE_DISASSEMBLER |
302 | 302 |
303 void Disassembler::Dump(FILE* f, byte* begin, byte* end) {} | 303 void Disassembler::Dump(FILE* f, byte* begin, byte* end) {} |
304 int Disassembler::Decode(FILE* f, byte* begin, byte* end) { return 0; } | 304 int Disassembler::Decode(FILE* f, byte* begin, byte* end) { return 0; } |
305 void Disassembler::Decode(FILE* f, Code* code) {} | 305 void Disassembler::Decode(FILE* f, Code* code) {} |
306 | 306 |
307 #endif // ENABLE_DISASSEMBLER | 307 #endif // ENABLE_DISASSEMBLER |
308 | 308 |
309 } } // namespace v8::internal | 309 } } // namespace v8::internal |
OLD | NEW |