From 6e4f085c7f459e0777a71bcb61ed3aa8257fa386 Mon Sep 17 00:00:00 2001 From: Mike Frysinger Date: Sun, 22 Mar 2015 23:10:09 -0400 Subject: sim: sim-close: unify sim_close logic Other than the nice advantage of all sims having to declare one fewer common function, this also fixes leakage in pretty much every sim. Many were not freeing any resources, and a few were inconsistent as to the ones they did. Now we have a single module that takes care of all the logic for us. Most of the non-cgen based ones could be deleted outright. The cgen ones required adding a callback to the arch-specific cleanup func. The few that still have close callbacks are to manage their internal state. We do not convert erc32, m32c, ppc, rl78, or rx as they do not use the common sim core. --- sim/sh/interp.c | 6 ------ 1 file changed, 6 deletions(-) (limited to 'sim/sh/interp.c') diff --git a/sim/sh/interp.c b/sim/sh/interp.c index 2f02e69..55a2d64 100644 --- a/sim/sh/interp.c +++ b/sim/sh/interp.c @@ -2501,12 +2501,6 @@ parse_and_set_memory_size (const char *str) callback->printf_filtered (callback, "Bad memory size %d; must be 1 to 24, inclusive\n", n); } -void -sim_close (SIM_DESC sd, int quitting) -{ - /* nothing to do */ -} - SIM_RC sim_create_inferior (SIM_DESC sd, struct bfd *prog_bfd, char **argv, char **env) { -- cgit v1.1