aboutsummaryrefslogtreecommitdiff
path: root/sim/frv
AgeCommit message (Collapse)AuthorFilesLines
2015-06-12sim: cgen: namespace custom trace functionsMike Frysinger4-1661/+1668
The cgen code declares some macros/funcs using the trace_xxx prefix, but the code isn't generic and only works with cgen targets. This is blocking the creation of new common trace functions. Let's blindly add cgen_xxx prefixes to all these symbols. Some already use this convention to avoid conflicts, so it makes sense to align them. In the future we might want to move some to the common trace core, but one thing at a time.
2015-06-11sim: frv: drop custom debug maskMike Frysinger2-5/+4
This is the only sim that sets up its own WITH_TRACE mask and it conflicts with the user setting their own list at configure time. Drop it to match all the other sims.
2015-04-18sim: trim old USING_SIM_BASE_H defineMike Frysinger2-2/+4
This doesn't appear to have been used since 1998, but wasn't cleaned up since. So much for being "quick" ;).
2015-04-18sim: unify SIM_CPU definitionMike Frysinger2-3/+4
Since every target typedefs this the same way, move it to the common code. We have to leave Blackfin behind here for now because of inter-dependencies on types and headers: sim-base.h includes sim-model.h which needs types in machs.h which needs types in bfim-sim.h which needs SIM_CPU.
2015-04-18sim: unify sim_cia definitionMike Frysinger2-4/+7
Almost every target defines sim_cia the same way -- either using the address_word type directly, or a type of equivalent size. The only odd one out is sh64 (who has 32bit address_word and 64bit cia), and even that case doesn't seem to make sense. We'll put off clean up though of sh64 and at least set up a sensible default for everyone.
2015-04-17sim: replace CIA_{GET,SET} with CPU_PC_{GET,SET}Mike Frysinger3-4/+6
The CIA_{GET,SET} macros serve the same function as CPU_PC_{GET,SET} except the latter adds a layer of indirection via the sim state. This lets models set up different functions at runtime and doesn't reach so directly into the arch-specific cpu state. It also doesn't make sense to have two sets of macros that do exactly the same thing, so lets standardize on the one that gets us more.
2015-04-15sim: unify sim-cpu usageMike Frysinger3-6/+5
Now that all the targets are utilizing CPU_PC_{FETCH,STORE}, and the cpu state is multicore, and the STATE_CPU defines match, we can move it all to the common code.
2015-04-15sim: cris/frv/h8300/iq2000/lm32/m32r/sh64: standardize cpu stateMike Frysinger2-2/+11
This sets up the sim_state structure and the cpu member to match what we do in most other sims, and what the common code suggests. This is a step to unifying on the sim-cpu.o object.
2015-04-13sim: fix the PKGVERSION defineMike Frysinger2-2/+6
This should be SIM, not GDB.
2015-04-06sim: move sim-engine.o/sim-hrw.o to the common listMike Frysinger2-2/+5
This makes these two objects available to all sims by default.
2015-04-02Regenerate configure in simH.J. Lu1-2/+2
* arm/configure: Regenerated. * avr/configure: Likewise. * bfin/configure: Likewise. * common/configure: Likewise. * cr16/configure: Likewise. * cris/configure: Likewise. * d10v/configure: Likewise. * erc32/configure: Likewise. * frv/configure: Likewise. * ft32/configure: Likewise. * h8300/configure: Likewise. * igen/configure: Likewise. * iq2000/configure: Likewise. * lm32/configure: Likewise. * m32c/configure: Likewise. * m32r/configure: Likewise. * m68hc11/configure: Likewise. * mcore/configure: Likewise. * microblaze/configure: Likewise. * mips/configure: Likewise. * mn10300/configure: Likewise. * moxie/configure: Likewise. * msp430/configure: Likewise. * ppc/configure: Likewise. * rl78/configure: Likewise. * rx/configure: Likewise. * sh/configure: Likewise. * sh64/configure: Likewise. * v850/configure: Likewise.
2015-04-01Regenerate configure in simH.J. Lu1-4/+6
* arm/configure: Regenerated. * avr/configure: Likewise. * bfin/configure: Likewise. * common/configure: Likewise. * cr16/configure: Likewise. * cris/configure: Likewise. * d10v/configure: Likewise. * erc32/configure: Likewise. * frv/configure: Likewise. * ft32/configure: Likewise. * h8300/configure: Likewise. * igen/configure: Likewise. * iq2000/configure: Likewise. * lm32/configure: Likewise. * m32c/configure: Likewise. * m32r/configure: Likewise. * m68hc11/configure: Likewise. * mcore/configure: Likewise. * microblaze/configure: Likewise. * mips/configure: Likewise. * mn10300/configure: Likewise. * moxie/configure: Likewise. * msp430/configure: Likewise. * ppc/configure: Likewise. * rl78/configure: Likewise. * rx/configure: Likewise. * sh/configure: Likewise. * sh64/configure: Likewise. * v850/configure: Likewise.
2015-04-01sim: update zlib handlingMike Frysinger3-84/+17
With zlib being mandatory, and the updated m4 configs, we need to regen and use the new settings w/bfd to avoid linkage errors.
2015-03-24sim: Revert "Fix frv/iq2000/m32r/sh64 sim, default hardware to off."Mike Frysinger3-2/+6
This partially reverts commits: 105dd264de9a2fa7eee45eff897aa1d6171c1c4b 3df3af7c3f9095f9dc951fe680ce76f6e497914b c4892a6b37647a0b33a2113b59762f678aabe4b2 9e3042ec073e05a0a5aa56398fd2662c5dcd5002 Now that dv-sockser is handled entirely by the common build logic, the failure these targets were hitting isn't really possible anymore. Lets reset their hardware status back to defaulting to on. Some of these were set to "always" previously, but we don't support that anymore.
2015-03-24sim: fix sim-hardware configure optionMike Frysinger2-6/+6
The current default handling for the --enable-sim-hardware option ends up forcing the value to whatever is set as the first argument when calling the macro (by virtue of how autoconf works). Relocate the setup code to the 4th parameter of the AC_ARG_ENABLE macro to fix it. This was caused by the simplification work in 1517bd274290e06af498ef7e49. Reported-by: Hans-Peter Nilsson <hans-peter.nilsson@axis.com>
2015-03-23sim: drop support for requiring hw supportMike Frysinger2-10/+9
Since no sim is using the "always" option to SIM_AC_OPTION_HARDWARE, and we don't want to require hw support to always be enabled, drop the option. This leads to a slight simplification in the macro too as we can collapse the sim_hw_p variable.
2015-03-23sim: frv: delete UART device supportMike Frysinger2-37/+6
This looks like copy & paste logic from the m32r port (and history suggests this as well). Since building with hw & device support enabled leads to failures: sim/frv/devices.c: In function 'device_io_read_buffer': sim/frv/devices.c:39:15: error: 'UART_INCHAR_ADDR' undeclared (first use in this function) Delete it entirely. We leave device support in place as it is used to flush the scache.
2015-03-23sim: dv-sockser: move build to common dirMike Frysinger2-6/+10
If dv-sockser is available, lets add it to the common SIM_HW_OBJS variable so it is always included automatically. Now ports do not have to shoe horn it in directly themselves. It does mean it will be compiled for targets that don't explicitly use it, but that's really what we want anyways.
2015-03-16sim: rename tconfig.in to tconfig.hMike Frysinger5-21/+22
Rather than manually include tconfig.h when we think we'll need it (which is error prone as it can define symbols we expect from config.h), have it be included directly by config.h. Since we know we have to include that header everywhere already, this will make sure tconfig.h isn't missed. It should also be fine as tconfig.h is supposed to be simple and only set up a few core defines for the target. This allows us to stop symlinking it in place all the time and just use it straight out of the respective source directory.
2015-03-15sim: dv-sockser: push module init prototype downMike Frysinger2-6/+4
Pull out the duplicated dv_sockser_install prototype from the tconfig.in files and put it in the one place it gets used -- sim-module.c. This is still arguably incorrect, but it's better than the status quo where the tconfig.in has to include header files and duplicate the dv-sockser func. The tconfig header is meant to be simple and contain a target defines.
2015-03-14sim: make nrun the default run programMike Frysinger2-1/+4
We want people to stop using the run.c frontend, but it's hard to notice when it's still set as the default. Lets flip things so nrun.c is the default, and users of run.c will get an error by default. We turn that error into a warning for existing sims so we don't break them -- this is mostly meant for people starting new ports.
2015-01-01Update year range in copyright notice of all files owned by the GDB project.Joel Brobecker35-35/+35
gdb/ChangeLog: Update year range in copyright notice of all files.
2014-08-23Fix frv-elf sim, default hardware to off.Hans-Peter Nilsson4-12/+13
At 2974be626, frv-elf fails at the dv_sockser_install declaration in sim/frv/tconfig.in. But, with the trivial #include's added (see other sims tconfig.in, like cris or mn10300), it *still* fails building sim/frv/devices.c because of a missing UART_INCHAR_ADDR. I have no insight into what'd be a valid value, except that there's a definition in m32r, which was probably used as a template with frv not finished. Simulated hardware should not have been be enabled, and was indeed not enabled by default before 94c63d78f (2013-03-23), where it seems to have been enabled for no simulator-specific reason. Except dv-sockser.o wasn't enabled even then: sim/frv/config.in wasn't regenerated, so HAVE_DV_SOCKSER was never defined. Maybe people were fooled by this in sim/frv/Makefile.in at that time (these two lines were later deleted, in 73e76d20): CONFIG_DEVICES = dv-sockser.o CONFIG_DEVICES = (As it seems people have missed it before: the second line overrides the first...) I'm guessing these lines were part of the never-completed hardware-support. Commit 73e76d20 attempted to move the imagined dv-sockser.o from $(CONFIG_DEVICES) to $(frv_extra_objs) but missed that AC_SUBST would only affect @frv_extra_objs@ (not $(frv_extra_objs) per se) so nothing happened regarding sockser: dv-sockser.o was not compiled and HAVE_DV_SOCKSER was not defined. I'm removing the $(frv_extra_objs) too, to avoid confusion. The best action seems to be disabling all hardware support by default again until a specific sim maintainer finishes the work. Make check-sim for frv-elf shows no failures after this. sim/frv: * configure.ac: Default simulator hardware to off again. Remove dead frv_extra_objs substitution. * configure: Regenerate. * Makefile.in: Remove unused frv_extra_objs.
2014-08-19Fix --diable-shared --enable-plugins build breakageAlan Modra2-2/+64
Directories that don't use libtool need to add -ldl (on most *nix hosts) to provide dlopen for libbfd. config/ * plugins.m4 (AC_PLUGINS): If plugins are enabled, add -ldl to LIBS via AC_SEARCH_LIBS. gdb/ * acinclude.m4 (GDB_AC_CHECK_BFD): Don't add -ldl. * config.in: Regenerate. sim/ppc/ * configure.ac: Invoke AC_PLUGINS. * config.in: Regenerate. and regen lots of configure files.
2014-08-15Regenerate sim configury.Roland McGrath3-9/+58
2014-01-01Update Copyright year range in all files maintained by GDB.Joel Brobecker35-35/+35
2013-09-23Regenerate sim configure files to pick up support for powerpc64le inAlan Modra2-5/+15
libtool.m4.
2013-06-05sim: use AM_MAINTAINER_MODEMike Frysinger3-13/+72
I noticed the sim code is using an old implementation of the maintainer logic. I cut it over to the new macro (like gdb has been doing). In practice, it makes no difference currently as nothing in the sim tree uses it, but I have a follow up commit for the Blackfin tree that needs it.
2013-03-31sim: frv/m32r: back out hard failure when dv-sockser is not availableMike Frysinger4-17/+15
These sims have optional support for the dv-sockser model, so do not make them hard failures. The Makefile made it seem like they didn't actually support things dynamically, but a further code dive into the source and the Makefile shows that things work out.
2013-03-26sim: rewrite SIM_AC_OPTION_HARDWARE a bit to simplify thingsMike Frysinger2-31/+30
There's no need to put the majority of the logic into the 3rd arg of the AC_ARG_ENABLE. Coupled with the lack of indentation, it makes it hard to follow, error prone to update, and duplicates code (with the 4th arg). So pull the logic out of the 3rd arg and outside of the AC_ARG_ENABLE macro. This allows us to gut the 4th arg entirely, merge with the code that followed the macro, and fix bugs related to the new dv-sockser in the process. Hopefully building the various sims with the default sim-hardware settings, as well as with explicit --{dis,en}able-sim-hardware flags, should all just work now.
2013-03-232013-03-23 Joel Sherrill <joel.sherrill@oarcorp.com>Joel Sherrill3-2/+147
* configure.ac: Fail if dv-sockser.o not available. Error when --disable-sim-hardware is specified. * configure: Regenerated.
2013-01-01Update years in copyright notice for the GDB files.Joel Brobecker35-50/+35
Two modifications: 1. The addition of 2013 to the copyright year range for every file; 2. The use of a single year range, instead of potentially multiple year ranges, as approved by the FSF.
2012-12-19[sim] Update old contact info in GPL license noticesJoel Brobecker9-18/+9
sim/ChangeLog: Update old contact info in GPL license notices.
2012-11-20Fix sim build when configured with --enable-pluginsH.J. Lu1-1/+8960
* common/Make-common.in: Use lt_cv_dlopen_libs under PLUGINS condition. * common/acinclude.m4: Define lt_cv_dlopen_libs. * arm/configure: Regenerate. * avr/configure: Regenerate. * bfin/configure: Regenerate. * common/configure: Regenerate. * cr16/configure: Regenerate. * cris/configure: Regenerate. * d10v/configure: Regenerate. * erc32/configure: Regenerate. * frv/configure: Regenerate. * h8300/configure: Regenerate. * igen/configure: Regenerate. * iq2000/configure: Regenerate. * lm32/configure: Regenerate. * m32c/configure: Regenerate. * m32r/configure: Regenerate. * m68hc11/configure: Regenerate. * mcore/configure: Regenerate. * microblaze/configure: Regenerate. * mips/configure: Regenerate. * mn10300/configure: Regenerate. * moxie/configure: Regenerate. * ppc/configure: Regenerate. * rl78/configure: Regenerate. * rx/configure: Regenerate. * sh/configure: Regenerate. * sh64/configure: Regenerate. * testsuite/configure: Regenerate. * v850/configure: Regenerate.
2012-06-15Define PACKAGE macro in all sims' config.h.Joel Brobecker3-0/+19
Some of the common includes in include/gdb such as callback.h include bfd.h. But there was a recent change in bfd-in.h to require that config.h be included before bfd.h can be included: /* PR 14072: Ensure that config.h is included first. */ #if !defined PACKAGE && !defined PACKAGE_VERSION #error config.h must be included before this header #endif PACKAGE_VERSION is always defined by default by the AC_INIT autoconf macro, but PACKAGE isn't. This patch updates the SIM_AC_COMMON macro to define it, and then regenerates all configure scripts and config.in files. sim/common/changeLog: * acinclude.m4 (SIM_AC_COMMON): Define PACKAGE. * config.in, configure: Regenerate. sim/ChangeLog: * configure: Regenerate. sim/arm/ChangeLog: * config.in, configure: Regenerate. sim/avr/ChangeLog: * config.in, configure: Regenerate. sim/bfin/ChangeLog: * config.in, configure: Regenerate. sim/cr16/ChangeLog: * config.in, configure: Regenerate. sim/cris/ChangeLog: * config.in, configure: Regenerate. sim/d10v/ChangeLog: * config.in, configure: Regenerate. sim/erc32/ChangeLog: * config.in, configure: Regenerate. sim/frv/ChangeLog: * config.in, configure: Regenerate. sim/h8300/ChangeLog: * config.in, configure: Regenerate. sim/iq2000/ChangeLog: * config.in, configure: Regenerate. sim/lm32/ChangeLog: * config.in, configure: Regenerate. sim/m32c/ChangeLog: * config.in, configure: Regenerate. sim/m32r/ChangeLog: * config.in, configure: Regenerate. sim/m68hc11/ChangeLog: * config.in, configure: Regenerate. sim/mcore/ChangeLog: * config.in, configure: Regenerate. sim/microblaze/ChangeLog: * config.in, configure: Regenerate. sim/mips/ChangeLog: * config.in, configure: Regenerate. sim/mn10300/ChangeLog: * config.in, configure: Regenerate. sim/moxie/ChangeLog: * config.in, configure: Regenerate. sim/ppc/ChangeLog: * configure: Regenerate. sim/rl78/ChangeLog: * config.in, configure: Regenerate. sim/rx/ChangeLog: * config.in, configure: Regenerate. sim/sh/ChangeLog: * config.in, configure: Regenerate. sim/sh64/ChangeLog: * config.in, configure: Regenerate. sim/v850/ChangeLog: * config.in, configure: Regenerate. sim/testsuite/ChangeLog: * configure: Regenerate.
2012-03-24[PATCH] sim: make sure to include strsignal prototypeMike Frysinger4-126/+225
Before POSIX standardized strsignal(), old systems would hide the prototype unless the normal extension defines were enabled. So use the AC_USE_SYSTEM_EXTENSIONS helper for that. Then make sure we include string.h ourselves in nrun.c rather than relying on implicit includes via other sim headers. Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2012-01-04Copyright year update in most files of the GDB Project.Joel Brobecker35-61/+50
gdb/ChangeLog: Copyright year update in most files of the GDB Project.
2011-12-03sim: generate build dependencies on the flyMike Frysinger3-0/+319
Lift the code that GDB is using to generate dependencies on the fly and port it over to the sim. Now people shouldn't have to manually maintain these in their Makefile's. Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2011-10-18sim: rename common/aclocal.m4 to common/acinclude.m4Mike Frysinger2-1/+5
Automake likes to dump macros automatically used into the aclocal.m4 file, but the common/aclocal.m4 naming prevents that. So rename it to the more normal "acinclude.m4" so the aclocal tool can work. Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2011-10-18sim: move from common.m4 to SIM_AC_COMMONMike Frysinger3-367/+360
Now that the sourceware tree generally requires autoconf-2.64, update the sim tree to require that too. This allows us to drop the long standing SIM_AC_COMMON/common.m4 workaround as autoconf 2.64+ seems to work for me. Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2011-07-05sim: start a unified sim_do_commandMike Frysinger2-9/+4
Since sim_do_command for many people simply calls sim_args_command, start a unified version of it. For people who handle their own options, they could switch to this by using sim_add_option_table instead. Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2011-01-01run copyright.sh for 2011.Joel Brobecker26-27/+31
2010-04-22sim: profile: implement --profile-file backendMike Frysinger2-1/+5
Need to update the sim_profile_print_bar() call after the common/ changes. Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2010-03-30sim: update device_error() prototypeMike Frysinger2-1/+5
The device_error() takes a printf style string, so update the prototype accordingly. The message should be const and it should use an attribute. This fixes gcc warnings like: sim-core.c: In function 'sim_core_map_attach': sim-core.c:200: warning: passing argument 2 of 'device_error' discards qualifiers from pointer target type sim-core.c:237: warning: passing argument 2 of 'device_error' discards qualifiers from pointer target type sim-core.c: In function 'sim_core_attach': sim-core.c:304: warning: passing argument 2 of 'device_error' discards qualifiers from pointer target type sim-core.c:314: warning: passing argument 2 of 'device_error' discards qualifiers from pointer target type sim-core.c:335: warning: passing argument 2 of 'device_error' discards qualifiers from pointer target type sim-core.c:348: warning: passing argument 2 of 'device_error' discards qualifiers from pointer target type
2010-02-13regenerate cgen-based filesDoug Evans3-66/+418
2010-02-12Regenerate cgen-derived files.Doug Evans5-214/+215
2010-01-25 common/Doug Evans2-20/+24
* cgen-accfp.c (fextsfdf): New arg how. All callers updated. (ftruncdfsf, floatsisf, flostsidf, ufloatsisf, fixsfsi, fixdfsi, ufixsfsi): Ditto. * cgen-fpu.h (CGEN_FPCONV_KIND): New enum. (struct cgen_fp_ops): Update signatures of floating point conversion operations. frv/ * sem.c: Regenerate. sh64/ * cpu.h: Regenerate.
2010-01-09Sync Libtool from GCC.Ralf Wildenhues2-1/+5
/: * libtool.m4: Sync from git Libtool. * ltmain.sh: Likewise. * ltoptions.m4: Likewise. * ltversion.m4: Likewise. * lt~obsolete.m4: Likewise. sim/iq2000/: * configure: Regenerate. sim/d10v/: * configure: Regenerate. sim/m32r/: * configure: Regenerate. sim/frv/: * configure: Regenerate. sim/: * avr/configure: Regenerate. * cris/configure: Regenerate. * microblaze/configure: Regenerate. sim/h8300/: * configure: Regenerate. sim/mn10300/: * configure: Regenerate. sim/erc32/: * configure: Regenerate. sim/arm/: * configure: Regenerate. sim/m68hc11/: * configure: Regenerate. sim/lm32/: * configure: Regenerate. sim/sh64/: * configure: Regenerate. sim/v850/: * configure: Regenerate. sim/cr16/: * configure: Regenerate. sim/moxie/: * configure: Regenerate. sim/m32c/: * configure: Regenerate. sim/mips/: * configure: Regenerate. sim/mcore/: * configure: Regenerate. sim/sh/: * configure: Regenerate. gprof/: * Makefile.in: Regenerate. * configure: Regenerate. opcodes/: * Makefile.in: Regenerate. * configure: Regenerate. gas/: * Makefile.in: Regenerate. * configure: Regenerate. * doc/Makefile.in: Regenerate. ld/: * configure: Regenerate. gdb/testsuite/: * gdb.cell/configure: Regenerate. binutils/: * Makefile.in: Regenerate. * configure: Regenerate. * doc/Makefile.in: Regenerate. bfd/: * Makefile.in: Regenerate. * configure: Regenerate. bfd/doc/: * Makefile.in: Regenerate.
2010-01-02Regenerate cgen files, update copyright year.Doug Evans10-9/+14
2010-01-01Update copyright notices to add year 2010.Joel Brobecker26-26/+29