* dv-mn103int.c (external_group): Use enumerated types to access
correct group addresses.
* dv-mn103tim.c (do_counter_event): Underflow of cascaded timer
triggers an interrupt on the higher-numbered timer's port.
Wed Jun 10 15:56:10 1998 Frank Ch. Eigler <fche@cygnus.com>
* sim/sky/t-int.c: New file to test sky hardware
interrupts.
* sim/sky/t-int-handler.s: New file for null interrupt
handler.
* sim/sky/t-int.brn: New file to build new test.
Tue Jun 9 12:29:50 1998 Frank Ch. Eigler <fche@cygnus.com>
* dv-tx3904cpu.c (deliver_*_interrupt,*_port_event): Set the CAUSE
register upon non-zero interrupt event level, clear upon zero
event value.
* dv-tx3904irc.c (*_port_event): Handle deactivated interrupt signal
by passing zero event value.
(*_io_{read,write}_buffer): Endianness fixes.
* dv-tx3904tmr.c (*_io_{read,write}_buffer): Endianness fixes.
(deliver_*_tick): Reduce sim event interval to 75% of count interval.
* interp.c (sim_open): Added jmr3904pal board type that adds PAL-based
serial I/O and timer module at base address 0xFFFF0000.
using sim-options.
start-sanitize-am30
* (board): Add --board option for specifying am32.
* (sim_open): Create new timer and serial devices and control
configuration of other am32 devices via board option.
end-sanitize-am30
It is not yet properly tested.
Thu Jun 4 15:37:33 1998 Frank Ch. Eigler <fche@cygnus.com>
* dv-tx3904tmr.c: New file - implements tx3904 timer.
* dv-tx3904{irc,cpu}.c: Mild reformatting.
* configure.in: Include tx3904tmr in hw_device list.
* configure: Rebuilt.
* interp.c (sim_open): Instantiate three timer instances.
Fix address typo of tx3904irc instance.
byte-swapping unnecessary. Add -sparclite-board option for
emulating RAM found on typical SPARClite boards. Print
error message for unrecognized option.
* erc32.c: Change RAM address and size from constants to variables,
to allow emulation of SPARClite board RAM.
(fetch_bytes, store_bytes): New helper functions for revamped
mememory_read and memory_write.
(memory_read, memory_write): Rewrite to store bytes in target
byte order instead of storing words in host byte order; this
greatly simplifies support of little-endian programs.
(get_mem_ptr): Remove unnecessary byte parameter.
(sis_memory_write, sis_memory_read): Store words in target
byte order instead of host byte order.
(byte_swap_words): Remove, no longer needed.
* sis.h ((byte_swap_words): Remove declaration, no longer needed.
(memory_read): Add new sz parameter.
* sis.c (run_sim): Use revamped memory_read, which makes
byte-swapping unnecessary.
* exec.c (dispatch_instruction): Use revamped memory_read, which
makes byte-swapping and double-word fetching unnecessary.
* func.c (sparclite_board): Declare new variable.
(get_regi): Handle little-endian data.
(bfd_load): Recognize little-endian SPARClite as having
little-endian data.
* armos.c (ARMul_OSHandleSWI::SWI_Open): Handle special case
of ":tt" to catch stdin in addition to stdout.
(ARMul_OSHandleSWI::SWI_Seek): Return 0 or 1 to indicate failure
or success of lseek().
From PR 15839, modified a bit by me to appease my sense of style--but
not too much because I am lazy.
Mon Jun 1 18:54:22 1998 Frank Ch. Eigler <fche@cygnus.com>
* lib/sim-defs.exp (sim_run): Add possible environment variable
list to simulator run.
start-sanitize-sky
* sim/sky/sky-defs.tcl: Use it.
* sim/sky/t-pke2.vif1out: Update to match recent word-precise
tracking table change in sim/mips/sky-pke.c.
* sim/sky/t-pke3.trc: Ditto.
* sim/sky/t-pke4.vif0expect: Ditto.
end-sanitize-sky
Mon May 18 10:37:47 1998 Doug Evans <devans@canuck.cygnus.com>
* mloopx.in (extract): Set abuf.addr for proper fill nop counting.
(execute): Count parallel insns.
* sim-if.c (print_m32r_misc_cpu): Print count.
* sim-main.h (M32R_MISC_PROFILE): New member parallel_count.
(trace_insn_init): Set it.
(trace_insn_fini): Use TRACE_PREFIX.
(trace_insn): Rewrite to use trace_prefix.
* sim-trace.c (trace_prefix): Don't print filename arg if NULL.
Adjust width accordingly.
* sim-profile.h (PROFILE_DATA): New member profile_any_p.
(PROFILE_ANY_P,PROFILE_INSN_P,PROFILE_MEMORY): New macros.
(PROFILE_SCACHE_P,PROFILE_PC_P,PROFILE_CORE_P): New macros.
(PROFILE_COUNT_INSN,PROFILE_COUNT_READ,PROFILE_COUNT_WRITE): Simplify.
(PROFILE_COUNT_CORE): Simplify.
* sim-profile.c (profile_option_handler): Compute profile_any_p.
* Followup patch for SCEI PR 15853
* First check-in of TX3904 interrupt controller devices for ECC. [sanitized]
* First implementation of MIPS hardware interrupt emulation.
Mon May 18 18:22:42 1998 Frank Ch. Eigler <fche@cygnus.com>
* configure.in (SIM_AC_OPTION_HARDWARE): Added common hardware
modules. Recognize TX39 target with "mips*tx39" pattern.
* configure: Rebuilt.
* sim-main.h (*): Added many macros defining bits in
TX39 control registers.
(SignalInterrupt): Send actual PC instead of NULL.
(SignalNMIReset): New exception type.
* interp.c (board): New variable for future use to identify
a particular board being simulated.
(mips_option_handler,mips_options): Added "--board" option.
(interrupt_event): Send actual PC.
(sim_open): Make memory layout conditional on board setting.
(signal_exception): Initial implementation of hardware interrupt
handling. Accept another break instruction variant for simulator
exit.
(decode_coproc): Implement RFE instruction for TX39.
(mips.igen): Decode RFE instruction as such.
start-sanitize-tx3904
* configure.in (tx3904cpu,tx3904irc): Added devices for tx3904.
* interp.c: Define "jmr3904" and "jmr3904debug" board types and
bbegin to implement memory map.
* dv-tx3904cpu.c: New file.
* dv-tx3904irc.c: New file.
end-sanitize-tx3904
* sim-engine.h (sim_engine_set_run_state): Declare.
* genmloop.sh (pending_reason,pending_sigrc): New static locals.
(@cpu@_engine_stop): New args reason,sigrc. All callers updated.
(engine_resume): Reorganize. Allow synchronous exit from main loop.
* exec.c (SDIV, SDIVCC, UDIV, UDIVCC): Define new opcodes.
* (mul64): Simplify calculation of negative result.
* (div64): New helper function for 64-bit division.
* (dispatch_instruction): Add emulation of SDIV, SDIVCC, UDIV,
and UDIVCC.
Replace check_op_hilo with check_mult_hilo and check_div_hilo.
Add special r3900 version of do_mult_hilo.
(do_dmultx,do_mult,do_multu): Replace calls to check_op_hilo
with calls to check_mult_hilo.
(do_ddiv,do_ddivu,do_div,do_divu): Replace calls to check_op_hilo
with calls to check_div_hilo.
for VU memory tracking tables.
Thu May 7 12:15:41 1998 Frank Ch. Eigler <fche@cygnus.com>
* sky-pke.c (pke_pcrel_operand_bits): Compute word-resolution
source address for UNPACK into VU MEM.
(pke_code_mpg): Ditto for MPG into VU uMEM.
Instead save them in the sim_hw structure.
*) Route sim-core accesses to hw devices through the sim_hw module.
*) Route hw device requests to abort/halt through the sim_hw module.
*) Add print parameter to hw_tree_print() function.
*) Add sim_engine_vabort () function.
* common/aclocal.m4: call AM_EXEEXT in SIM_AC_COMMON, define
AM_CYGWIN32 and AM_EXEEXT.
* common/Make-common.in: set EXEEXT, add missing EXEEXTs
to run and install-common rules.
* common/configure: regenerate
And update all subdirectory ChangeLogs and configure files.
and variable renaming due to macro insn additions.
* mloop.in: Update to use CGEN_INSN_NUM.
* cpu.x,modelx.c,readx.c,semx.c: Regenerated.
* mloopx.in: Update to use CGEN_INSN_NUM.
and variable renaming due to macro insn additions.
* mloop.in: Update to use CGEN_INSN_NUM.
* cpu.x,modelx.c,readx.c,semx.c: Regenerated.
* mloopx.in: Update to use CGEN_INSN_NUM.
../common' to autoconf and autoheader. Unconditionally run
autoconf in every subdir.
(autoconf-changelog autoheader-changelog): Unconditionally run
commands in every subdir.
(autoconf-install autoheader-install): Likewise.
* config.in: Ditto.
* Makefile.in (top_builddir): New macro.
(INTLLIBS): New macro.
(INTLDEPS): Likewise.
(psim): Depend on INTLDEPS; link against INTLLIBS.
* configure.in: Call CY_GNU_GETTEXT.
* config.in: Ditto.
* acconfig.h: New file.
* Make-common.in (top_builddir): New macro.
(INTL_LIB): Removed.
(INTLLIBS): New macro.
(INTLDEPS): Likewise.
(LIBDEPS): Use INTLDEPS.
(EXTRA_LIBS): Use INTLLIBS.
* aclocal.m4 (SIM_AC_COMMON): Call CY_GNU_GETTEXT.
(CY_WITH_NLS, CY_GNU_GETTEXT, AM_PATH_PROG_WITH_TEST,
AM_LC_MESSAGES): New macros from GNU gettext.
* gen.c (insns_bit_useless): Perform unsigned bit comparisons.
* filter.c (is_filtered_out, filter_parse): Pacify GCC, len is unsigned.
* gen-icache.c (print_icache_extraction): Do not type cast pointers.
o When unpacking an r5900 FP value,
was not treating IEEE-NaN's as very
large values.
o When packing an r5900 FP result from an infinite
precision intermediate value was saturating
to IEEE-MAX instead of r5900-MAX
o The least significant bit of the FP status
register did not stick to one.
* sim-memopt.c (parse_addr): Sunos 4.5 does not hane strtol
declared so we need this cast to prevent long long addresses
from being misconfigures. Results in access to unmapped memory.
[ChangeLog]
Mon Apr 13 16:51:00 1998 Frank Ch. Eigler <fche@cygnus.com>
* Makefile.in (*): Added .vuout/.vuexpect/.vuok test targets
for confirming VU instruction trace.
(t-cop2): Test COP2 sim using above facility.
* t-cop2.vuexpect: New file.
[ChangeLog]
Mon Apr 13 16:28:52 1998 Frank Ch. Eigler <fche@cygnus.com>
* interp.c (decode_coproc): Add proper 1000000 bit-string at top
of VU lower instruction.
VCALLMS-related were found/fixed.
[ChangeLog.sky]
* sky-vu.c ({read,write}_vu_special_reg): Add CMSAR[01] as special
registers for a VU. Behavior not as mandated.
({read,write}_vu_{misc,special}_reg): Create sim_io_error upon
access to unknown register. Behavior not as mandated.
* sky-vu.h (anonymous register numbering enum): Add CMSAR[01].
* sky-libvpe.c (indebug): Cache $ENV{'SKY_DEBUG'}.
[ChangeLog]
* Makefile.in (SIM_SKY_OBJS): Added sky-vudis.o.
* interp.c (decode_coproc): Refer to VU CIA as a "special"
register, not as a "misc" register. Aha. Add activity
assertions after VCALLMS* instructions.
work!
[ChangeLog.sky]
* sky-vu.h (vu_device): Represent "macro instruction just stuffed
into fetch buffer" condition with new "m" bit. Rename old "m" to
"l".
* sky-libvpe.c (indebug): Save snapshot of environment value;
workaround for suspected memory corruption.
(fetch_inst): Respect new "m" macro-instruction flag for reporting
successful fetch to caller.
(exec_inst): Disassemble instruction here instead of fetch time.
Renamed old "m" -> "l" flag in VU state to track interlock
release.
(vpecallms_cycle): Call exec_inst only if fetch_inst did some
work.
* sky-vu.c (vu_attach, vu[01]_device): Revamped initialization to
ensure complete clear of tail part of struct at attach time.
(vu0_busy): Fix thinko.
(vu0_macro_issue): Adapt to new "l" flag.
(vu0_micro_interlock_released): Ditto.
(write_vu_special_reg): Ditto.
(read_vu_special_reg): Compute VBS0/VBS1 bits more explicitly.
The other VU status bits are not yet computed.
[ChangeLog]
* interp.c (decode_coproc): Do not apply superfluous E (end) flag
to upper code of generated VU instruction.
sce*_testN.* corresponds to the original testN/test.*
*.vuasm : MICRO code
*.dvpasm : DMAtag and VIF code description
*.out_gif.dat : GIF output values for the corresponding testcase.
sce_main.c : driver file for the SCE testcases
sce_macro.s : SCE provided macro file needed by the SCE (feb28) testcases
refresh.s : Needed by sce_main.c
Makefile.in : Updated to run make and run the SCE testsuite.
: ----------------------------------------------------------------------
masking facility for PATH3 transfers.
[ChangeLog.sky]
Sun Apr 5 12:11:45 1998 Frank Ch. Eigler <fche@cygnus.com>
* sky-libvpe.c (exec-inst): Added "M" bit detection for upper
instruction.
* sky-pke.c (pke_check_stall): Added more assertions.
(pke_code_mskpath3): Use new GPUIF M3P control register.
* sky-pke.h (VU[01]_CIA): New macros that give VU CIA
pseudo-register addresses.
* sky-vu.h (vu_device, VectorUnitState): Merged structs.
(VectorUnitState.mflag): New field.
(VU_REG_{CMSAR0,CMSAR1,FBRST}) Added missing control registers.
* sky-vu.c (vu0_busy): New function.
(vu0_q_busy): New function.
(vu0_macro_issue): New function.
(vu0_micro_interlock_released): New function.
(vu0_busy_in_{micro,macro}_mode): Deleted stubs.
(vu0_macro_hazard_check): Deleted stubs.
(vu_attach): Adapted code to merged device & state struct.
(read_vu_special_reg): Compute VBS0/VBS1 bits in STAT register.
[ChangeLog]
start-sanitize-sky
Sun Apr 5 12:05:44 1998 Frank Ch. Eigler <fche@cygnus.com>
* interp.c (*): Adapt code to merged VU device & state structs.
(decode_coproc): Execute COP2 each macroinstruction without
pipelining, by stepping VU to completion state. Adapted to
read_vu_*_reg style of register access.
* mips.igen ([SL]QC2): Removed these COP2 instructions.
* r5900.igen ([SL]QC2): Transplanted these COP2 instructions here.
* sim-main.h (cop_[ls]q): Enclosed in TARGET_SKY guards.
end-sanitize-sky
into single PKE-style vu.[ch].
[ChangeLog]
Fri Mar 27 16:19:29 1998 Frank Ch. Eigler <fche@cygnus.com>
start-sanitize-sky
* Makefile.in (SIM_SKY_OBJS): Replaced sky-vu[01].o with sky-vu.o.
* interp.c (sim_{load,store}_register): Use new vu[01]_device
static to access VU registers.
(decode_coproc): Added skeleton of sky COP2 (VU) instruction
decoding. Work in progress.
* mips.igen (LDCzz, SDCzz): Removed *5900 case for this
overlapping/redundant bit pattern.
(LQC2, SQC2): Added *5900 COP2 instruction skeleta. Work in
progress.
* sim-main.h (status_CU[012]): Added COP[n]-enabled flags for
status register.
end-sanitize-sky
* interp.c (cop_lq, cop_sq): New functions for future 128-bit
access to coprocessor registers.
* sim-main.h (COP_LQ, COP_SQ): New macro front-ends for above.
[ChangeLog.sky]
* sky-engine.c (engine_run): Adapted from vu[01] -> vu merge.
* sky-hardware.c (register_devices): Ditto
* sky-pke.c (pke_fifo_*): Made these functions private again, now
that the GPUIF code does not use them.
* sky-pke.h (pke_fifo_*): Removed newly private declarations.
* sky-vu.c (*): Major rework: merge of old sky-vu0.c and
sky-vu1.c. Management of two VU devices parallels two PKEs.
Work in progress.
* sky-vu.h (*): Other half of merge.
(vu_device): New struct, parallel to pke_device.
sky-gs.h: initial drop of GS control registers
Makefile.in: added sky-gs.o to sanitized list
sky-gpuif.c (gif_io_write_buffer): correct memset length error, renamed
trace file for gif
(hw_tree_find_*_property): Clean up error message when property is not found.
* dv-pal.c (hw_pal_io_read_buffer): Check the smp property is present before
looking for it.