mirror of https://github.com/proxmox/mirror_qemu
accel/tcg: Move perf and debuginfo support to tcg/
tcg/ should not depend on accel/tcg/, but perf and debuginfo support provided by the latter are being used by tcg/tcg.c. Since that's the only user, move both to tcg/. Suggested-by: Philippe Mathieu-Daudé <philmd@linaro.org> Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org> Signed-off-by: Ilya Leoshkevich <iii@linux.ibm.com> Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Message-ID: <20231212003837.64090-5-iii@linux.ibm.com> Message-Id: <20240125054631.78867-5-philmd@linaro.org> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>master
parent
ad66ac2b3a
commit
327b75a469
|
@ -16,10 +16,6 @@ tcg_ss.add(when: 'CONFIG_SYSTEM_ONLY', if_false: files('user-exec-stub.c'))
|
||||||
if get_option('plugins')
|
if get_option('plugins')
|
||||||
tcg_ss.add(files('plugin-gen.c'))
|
tcg_ss.add(files('plugin-gen.c'))
|
||||||
endif
|
endif
|
||||||
tcg_ss.add(when: libdw, if_true: files('debuginfo.c'))
|
|
||||||
if host_os == 'linux'
|
|
||||||
tcg_ss.add(files('perf.c'))
|
|
||||||
endif
|
|
||||||
specific_ss.add_all(when: 'CONFIG_TCG', if_true: tcg_ss)
|
specific_ss.add_all(when: 'CONFIG_TCG', if_true: tcg_ss)
|
||||||
|
|
||||||
specific_ss.add(when: ['CONFIG_SYSTEM_ONLY', 'CONFIG_TCG'], if_true: files(
|
specific_ss.add(when: ['CONFIG_SYSTEM_ONLY', 'CONFIG_TCG'], if_true: files(
|
||||||
|
|
|
@ -63,7 +63,7 @@
|
||||||
#include "tb-context.h"
|
#include "tb-context.h"
|
||||||
#include "internal-common.h"
|
#include "internal-common.h"
|
||||||
#include "internal-target.h"
|
#include "internal-target.h"
|
||||||
#include "perf.h"
|
#include "tcg/perf.h"
|
||||||
#include "tcg/insn-start-words.h"
|
#include "tcg/insn-start-words.h"
|
||||||
|
|
||||||
TBContext tb_ctx;
|
TBContext tb_ctx;
|
||||||
|
|
|
@ -62,7 +62,7 @@
|
||||||
#include "hw/boards.h"
|
#include "hw/boards.h"
|
||||||
#include "qemu/cutils.h"
|
#include "qemu/cutils.h"
|
||||||
#include "sysemu/runstate.h"
|
#include "sysemu/runstate.h"
|
||||||
#include "accel/tcg/debuginfo.h"
|
#include "tcg/debuginfo.h"
|
||||||
|
|
||||||
#include <zlib.h>
|
#include <zlib.h>
|
||||||
|
|
||||||
|
|
|
@ -4,8 +4,8 @@
|
||||||
* SPDX-License-Identifier: GPL-2.0-or-later
|
* SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifndef ACCEL_TCG_DEBUGINFO_H
|
#ifndef TCG_DEBUGINFO_H
|
||||||
#define ACCEL_TCG_DEBUGINFO_H
|
#define TCG_DEBUGINFO_H
|
||||||
|
|
||||||
#include "qemu/bitops.h"
|
#include "qemu/bitops.h"
|
||||||
|
|
|
@ -4,8 +4,8 @@
|
||||||
* SPDX-License-Identifier: GPL-2.0-or-later
|
* SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifndef ACCEL_TCG_PERF_H
|
#ifndef TCG_PERF_H
|
||||||
#define ACCEL_TCG_PERF_H
|
#define TCG_PERF_H
|
||||||
|
|
||||||
#if defined(CONFIG_TCG) && defined(CONFIG_LINUX)
|
#if defined(CONFIG_TCG) && defined(CONFIG_LINUX)
|
||||||
/* Start writing perf-<pid>.map. */
|
/* Start writing perf-<pid>.map. */
|
|
@ -22,7 +22,7 @@
|
||||||
#include "qapi/error.h"
|
#include "qapi/error.h"
|
||||||
#include "qemu/error-report.h"
|
#include "qemu/error-report.h"
|
||||||
#include "target_signal.h"
|
#include "target_signal.h"
|
||||||
#include "accel/tcg/debuginfo.h"
|
#include "tcg/debuginfo.h"
|
||||||
|
|
||||||
#ifdef TARGET_ARM
|
#ifdef TARGET_ARM
|
||||||
#include "target/arm/cpu-features.h"
|
#include "target/arm/cpu-features.h"
|
||||||
|
|
|
@ -17,7 +17,7 @@
|
||||||
* along with this program; if not, see <http://www.gnu.org/licenses/>.
|
* along with this program; if not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
#include "qemu/osdep.h"
|
#include "qemu/osdep.h"
|
||||||
#include "accel/tcg/perf.h"
|
#include "tcg/perf.h"
|
||||||
#include "gdbstub/syscalls.h"
|
#include "gdbstub/syscalls.h"
|
||||||
#include "qemu.h"
|
#include "qemu.h"
|
||||||
#include "user-internals.h"
|
#include "user-internals.h"
|
||||||
|
|
|
@ -54,7 +54,7 @@
|
||||||
#include "signal-common.h"
|
#include "signal-common.h"
|
||||||
#include "loader.h"
|
#include "loader.h"
|
||||||
#include "user-mmap.h"
|
#include "user-mmap.h"
|
||||||
#include "accel/tcg/perf.h"
|
#include "tcg/perf.h"
|
||||||
|
|
||||||
#ifdef CONFIG_SEMIHOSTING
|
#ifdef CONFIG_SEMIHOSTING
|
||||||
#include "semihosting/semihost.h"
|
#include "semihosting/semihost.h"
|
||||||
|
|
|
@ -96,7 +96,7 @@
|
||||||
#endif
|
#endif
|
||||||
#include "sysemu/qtest.h"
|
#include "sysemu/qtest.h"
|
||||||
#ifdef CONFIG_TCG
|
#ifdef CONFIG_TCG
|
||||||
#include "accel/tcg/perf.h"
|
#include "tcg/perf.h"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#include "disas/disas.h"
|
#include "disas/disas.h"
|
||||||
|
|
|
@ -6,11 +6,10 @@
|
||||||
|
|
||||||
#include "qemu/osdep.h"
|
#include "qemu/osdep.h"
|
||||||
#include "qemu/lockable.h"
|
#include "qemu/lockable.h"
|
||||||
|
#include "tcg/debuginfo.h"
|
||||||
|
|
||||||
#include <elfutils/libdwfl.h>
|
#include <elfutils/libdwfl.h>
|
||||||
|
|
||||||
#include "debuginfo.h"
|
|
||||||
|
|
||||||
static QemuMutex lock;
|
static QemuMutex lock;
|
||||||
static Dwfl *dwfl;
|
static Dwfl *dwfl;
|
||||||
static const Dwfl_Callbacks dwfl_callbacks = {
|
static const Dwfl_Callbacks dwfl_callbacks = {
|
|
@ -22,6 +22,11 @@ if get_option('tcg_interpreter')
|
||||||
tcg_ss.add(files('tci.c'))
|
tcg_ss.add(files('tci.c'))
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
tcg_ss.add(when: libdw, if_true: files('debuginfo.c'))
|
||||||
|
if host_os == 'linux'
|
||||||
|
tcg_ss.add(files('perf.c'))
|
||||||
|
endif
|
||||||
|
|
||||||
tcg_ss = tcg_ss.apply({})
|
tcg_ss = tcg_ss.apply({})
|
||||||
|
|
||||||
libtcg_user = static_library('tcg_user',
|
libtcg_user = static_library('tcg_user',
|
||||||
|
|
|
@ -11,13 +11,12 @@
|
||||||
#include "qemu/osdep.h"
|
#include "qemu/osdep.h"
|
||||||
#include "elf.h"
|
#include "elf.h"
|
||||||
#include "exec/target_page.h"
|
#include "exec/target_page.h"
|
||||||
#include "exec/exec-all.h"
|
#include "exec/translation-block.h"
|
||||||
#include "qemu/timer.h"
|
#include "qemu/timer.h"
|
||||||
|
#include "tcg/debuginfo.h"
|
||||||
|
#include "tcg/perf.h"
|
||||||
#include "tcg/tcg.h"
|
#include "tcg/tcg.h"
|
||||||
|
|
||||||
#include "debuginfo.h"
|
|
||||||
#include "perf.h"
|
|
||||||
|
|
||||||
static FILE *safe_fopen_w(const char *path)
|
static FILE *safe_fopen_w(const char *path)
|
||||||
{
|
{
|
||||||
int saved_errno;
|
int saved_errno;
|
|
@ -55,7 +55,7 @@
|
||||||
#include "tcg/tcg-ldst.h"
|
#include "tcg/tcg-ldst.h"
|
||||||
#include "tcg/tcg-temp-internal.h"
|
#include "tcg/tcg-temp-internal.h"
|
||||||
#include "tcg-internal.h"
|
#include "tcg-internal.h"
|
||||||
#include "accel/tcg/perf.h"
|
#include "tcg/perf.h"
|
||||||
#ifdef CONFIG_USER_ONLY
|
#ifdef CONFIG_USER_ONLY
|
||||||
#include "exec/user/guest-base.h"
|
#include "exec/user/guest-base.h"
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Reference in New Issue