Skip to content
Snippets Groups Projects
  1. Mar 06, 2018
  2. Nov 09, 2017
  3. Oct 25, 2017
  4. Oct 12, 2017
    • Thomas Huth's avatar
      disas: Always initialize read_memory_inner_func properly · eb584b40
      Thomas Huth authored
      
      I've recently seen this with valgrind while running the HMP tester:
      
      ==22373== Conditional jump or move depends on uninitialised value(s)
      ==22373==    at 0x4A41FD: arm_disas_set_info (cpu.c:504)
      ==22373==    by 0x3867A7: monitor_disas (disas.c:390)
      ==22373==    by 0x38E80E: memory_dump (monitor.c:1339)
      ==22373==    by 0x38FA43: handle_hmp_command (monitor.c:3123)
      ==22373==    by 0x38FB9E: qmp_human_monitor_command (monitor.c:613)
      ==22373==    by 0x4E3124: qmp_marshal_human_monitor_command (qmp-marshal.c:1736)
      ==22373==    by 0x769678: do_qmp_dispatch (qmp-dispatch.c:104)
      ==22373==    by 0x769678: qmp_dispatch (qmp-dispatch.c:131)
      ==22373==    by 0x38B734: handle_qmp_command (monitor.c:3853)
      ==22373==    by 0x76ED07: json_message_process_token (json-streamer.c:105)
      ==22373==    by 0x78D40A: json_lexer_feed_char (json-lexer.c:323)
      ==22373==    by 0x78D4CD: json_lexer_feed (json-lexer.c:373)
      ==22373==    by 0x38A08D: monitor_qmp_read (monitor.c:3895)
      
      And indeed, in monitor_disas, the read_memory_inner_func variable was
      not initialized, but arm_disas_set_info() expects this to be NULL
      or a valid pointer. Let's properly set this to NULL in the
      INIT_DISASSEMBLE_INFO to fix it in all functions that use the
      disassemble_info struct.
      
      Fixes: f7478a92 ("Fix Thumb-1 BE32 execution")
      Signed-off-by: default avatarThomas Huth <thuth@redhat.com>
      Message-Id: <1506524313-20037-1-git-send-email-thuth@redhat.com>
      eb584b40
  5. Sep 05, 2017
  6. Feb 07, 2017
    • Julian Brown's avatar
      Fix Thumb-1 BE32 execution and disassembly. · f7478a92
      Julian Brown authored
      
      Thumb-1 code has some issues in BE32 mode (as currently implemented). In
      short, since bytes are swapped within words at load time for BE32
      executables, this also swaps pairs of adjacent Thumb-1 instructions.
      
      This patch un-swaps those pairs of instructions again, both for execution,
      and for disassembly. (The previous version of the patch always read four
      bytes in arm_read_memory_func and then extracted the proper two bytes,
      in a probably misguided attempt to match the behaviour of actual hardware
      as described by e.g. the ARM9TDMI TRM, section 3.3 "Endian effects for
      instruction fetches". It's less complicated to just read the correct
      two bytes though.)
      
      Signed-off-by: default avatarJulian Brown <julian@codesourcery.com>
      Message-id: ca20462a044848000370318a8bd41dd0a4ed273f.1484929304.git.julian@codesourcery.com
      Reviewed-by: default avatarPeter Maydell <peter.maydell@linaro.org>
      Signed-off-by: default avatarPeter Maydell <peter.maydell@linaro.org>
      f7478a92
  7. Jan 23, 2017
  8. Sep 15, 2016
    • Thomas Huth's avatar
      Remove remainders of HPPA backend · d41f3c3c
      Thomas Huth authored
      
      The HPPA backend has been removed by the following commit:
      
          802b5081
          tcg-hppa: Remove tcg backend
      
      But some small pieces of the HPPA backend still survived until
      today. Since we also do not have support for a HPPA target in
      QEMU, we can nowadays safely remove the remaining HPPA parts
      (like the disassembler code, or the detection of HPPA in the
      configure script).
      
      Signed-off-by: default avatarThomas Huth <thuth@redhat.com>
      Signed-off-by: default avatarMichael Tokarev <mjt@tls.msk.ru>
      d41f3c3c
  9. Feb 04, 2016
    • Peter Maydell's avatar
      all: Clean up includes · d38ea87a
      Peter Maydell authored
      
      Clean up includes so that osdep.h is included first and headers
      which it implies are not included manually.
      
      This commit was created with scripts/clean-includes.
      
      Signed-off-by: default avatarPeter Maydell <peter.maydell@linaro.org>
      Message-id: 1454089805-5470-16-git-send-email-peter.maydell@linaro.org
      d38ea87a
  10. Oct 22, 2015
  11. Sep 25, 2015
  12. Aug 14, 2015
  13. Jul 09, 2015
  14. Jun 22, 2015
    • Peter Crosthwaite's avatar
      disas: Remove uses of CPU env · d49190c4
      Peter Crosthwaite authored
      
      disas does not need to access the CPU env for any reason. Change the
      APIs to accept CPU pointers instead. Small change pattern needs to be
      applied to all target translate.c. This brings us closer to making
      disas.o a common-obj and less architecture specific in general.
      
      Cc: Richard Henderson <rth@twiddle.net>
      Cc: Peter Maydell <peter.maydell@linaro.org>
      Cc: "Edgar E. Iglesias" <edgar.iglesias@gmail.com>
      Cc: Paolo Bonzini <pbonzini@redhat.com>
      Cc: Eduardo Habkost <ehabkost@redhat.com>
      Cc: Michael Walle <michael@walle.cc>
      Cc: Aurelien Jarno <aurelien@aurel32.net>
      Cc: Leon Alrae <leon.alrae@imgtec.com>
      Cc: Jia Liu <proljc@gmail.com>
      Cc: Alexander Graf <agraf@suse.de>
      Cc: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
      Cc: Bastian Koppelmann <kbastian@mail.uni-paderborn.de>
      Cc: Guan Xuetao <gxt@mprc.pku.edu.cn>
      Cc: Max Filippov <jcmvbkbc@gmail.com>
      Reviewed-by: default avatarRichard Henderson <rth@twiddle.net>
      Reviewed-by: default avatarEduardo Habkost <ehabkost@redhat.com>
      Signed-off-by: default avatarPeter Crosthwaite <crosthwaite.peter@gmail.com>
      Acked-by: default avatarLuiz Capitulino <lcapitulino@redhat.com>
      Signed-off-by: default avatarMarkus Armbruster <armbru@redhat.com>
      d49190c4
  15. Jun 16, 2014
  16. Feb 08, 2014
    • Claudio Fontana's avatar
      disas: Implement disassembly output for A64 · 999b53ec
      Claudio Fontana authored
      
      Use libvixl to implement disassembly output in debug
      logs for A64, for use with both AArch64 hosts and targets.
      
      Signed-off-by: default avatarClaudio Fontana <claudio.fontana@linaro.org>
      [PMM:
       * added support for target disassembly
       * switched to custom QEMUDisassembler so the output format
         matches what QEMU expects
       * make sure we correctly fall back to "just print hex"
         if we didn't build the AArch64 disassembler because of
         lack of a C++ compiler
       * rename from 'aarch64' to 'arm-a64' because this is a
         disassembler for the A64 instruction set
       * merge aarch64.c and aarch64-cxx.cc into one C++ file
       * simplify the aarch64.c<->aarch64-cxx.cc interface]
      Signed-off-by: default avatarPeter Maydell <peter.maydell@linaro.org>
      999b53ec
  17. Aug 24, 2013
  18. Jul 23, 2013
  19. Apr 26, 2013
  20. Apr 15, 2013
  21. Mar 23, 2013
Loading