This patch teaches "disassembly" use code cache mechanism to read
target code.
gdb:
2013-11-24 Yao Qi <yao@codesourcery.com>
* disasm.c (dis_asm_read_memory): Call target_read_code
instead of target_read_memory.
2013-11-24 Yao Qi <yao@codesourcery.com>
2013-11-24 Yao Qi <yao@codesourcery.com>
+ * disasm.c (dis_asm_read_memory): Call target_read_code
+ instead of target_read_memory.
+
+2013-11-24 Yao Qi <yao@codesourcery.com>
+
* NEWS: Add note on new "set code-cache" option.
* target-dcache.c (code_cache_enabled_1): New variable.
(code_cache_enabled): New variable.
* NEWS: Add note on new "set code-cache" option.
* target-dcache.c (code_cache_enabled_1): New variable.
(code_cache_enabled): New variable.
dis_asm_read_memory (bfd_vma memaddr, gdb_byte *myaddr, unsigned int len,
struct disassemble_info *info)
{
dis_asm_read_memory (bfd_vma memaddr, gdb_byte *myaddr, unsigned int len,
struct disassemble_info *info)
{
- return target_read_memory (memaddr, myaddr, len);
+ return target_read_code (memaddr, myaddr, len);
}
/* Like memory_error with slightly different parameters. */
}
/* Like memory_error with slightly different parameters. */