aboutsummaryrefslogtreecommitdiff
path: root/sim/mips
AgeCommit message (Collapse)AuthorFilesLines
1998-03-27sky-gs.c: initial drop of GS control registers (outstanding questions)Patrick Macdonald1-0/+1
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
1998-03-27 * sky-vu.c: new file to read/write VU registersRon Unrau7-154/+70
* Makefile.in .Sanitize: add sky-vu.c * sky-vu.h: define registers as enum, export read/write routines * sky-vu[01].[ch]: use register read/write routines in sky-vu.c * interp.c: use register read/write routines in sky-vu.c
1998-03-27Do top level sim-hw module for device tree.Andrew Cagney1-0/+4
Add to aclocal.m4, update all configure files.
1998-03-27Define CPU_INDEX. Initialize.Andrew Cagney2-23/+40
For mips_options, iterate over MAX_NR_PROCESSORS when setting options.
1998-03-25Re-do --enable-sim-hardware so that each simulator can specify the devicesAndrew Cagney2-55/+63
it wants built. Generate hw-config.h.
1998-03-24* interp.c (Max, Min): Comment out functions. Not yet used.Andrew Cagney2-1/+15
* vr4320.igen (DCLZ): Pacify GCC, 64 bit arg, int format.
1998-03-24* Several fixes and performance enhancements from my 2 weeks working in Japan.Ian Carmichael2-1/+5
1998-03-20* Monster bug fixes & improvements from the last two days' demo-testing work.Frank Ch. Eigler4-19/+93
* sky-pke.h (pke_fifo*): Exported these formerly private functions. (pke_device): Added FIFO cache fields. * sky-pke.c (pke_fifo_reset): New function for GPUIF client - clear FIFO contents. (pke_pcrel_fifo): Added caching facility to prevent O(n^2) cost for searching for consecutive operand words. * sky-libvpe.c (MEM, uMEM): New/changed macros that perform modulo calculations to handle out-of-range VU memory addresses. (*): Replaced many previous uses of MEM[] and state->uMEM[] with calls to above macros. * sky-vu.h (struct VectorUnitState): Added qw/dw size fields for MEM/uMEM buffers, for overflow prevention. Renamed MEM/uMEM fields to catch all their prior users. * sky-vu0.c (vu0_attach): Manually align MEM0/MEM1 buffers to force 16-byte alignment. (zalloc is not enough.) * sky-vu1.c (vu1_attach): Ditto. (init_vu): Store buffer sizes from allocation into VectorUnitState. * sky-gpuif.h (GifPath): Use a pke_fifo strucf instead of temporary fixed-size array for flexible FIFO sizing. * sky-gpuif.c (SKY_GPU2_REFRESH): This is now an integer value to be used as a modulus for periodic refresh. (refresh): New function to send GPU2 refresh code periodically. (*): Use pke_fifo calls to en/dequeue GPUIF tags & operands. * sky-pke.h (struct pke_device): Added fields to allow caching of results from recent FIFO searches.
1998-03-18* Changes today consist just of some code hardening.Frank Ch. Eigler1-8/+11
1998-03-18* Added --with-sim-gpu2=<path> option for linking SCEI's GPU2 library withFrank Ch. Eigler3-58/+449
the stand-alone executable. [in ChangeLog.sky:] * sky-gpuif.c (call_gs): Call properly into GPU2 library if configured --with-sim-gpu2. Use SKY_GPU2_REFRESH symbol as placeholder for future GPU2-refresh policy. [in ChangeLog:] * Makefile.in (MIPS_EXTRA_LIBS, SIM_EXTRA_LIBS): Added configurable settings for stand-alone simulator. start-sanitize-sky * configure.in: Added --with-sim-gpu2 option to specify path of sky GPU2 library. Triggers -DSKY_GPU2 for sky-gpuif.c, and links/compiles stand-alone simulator with this library. * interp.c (MEM_SIZE): Increased default sky memory size to 16MB. end-sanitize-sky * configure.in: Added X11 search, just in case. * configure: Regenerated.
1998-03-14* PKE testing was driven by SCEI "test0" bucket; code coverage remainsFrank Ch. Eigler3-152/+311
effectively full. The code is believed to be functionally complete now. Some code cleanup is included at no extra charge in this version. Fri Mar 13 20:21:57 1998 Frank Ch. Eigler <fche@cygnus.com> * sky-vu1.c: (dump_mem): Commented out function to satiate warning-ful compilation. * sky-pke.c: (pke_reset): New function, called explicitly at initialization and at FBRST. (pke_fifo_flush): New function to flush (skip over) existing quadwords in FIFO. (pke_fifo_fit): New function to add space for new quadword in FIFO. (pke_fifo_access): New function to absolute-index into FIFO. (pke_fifo_old): New function to remove old quadwords from FIFO. (pke_begin_interrupt_stall): New function to abstract interrupt-caused stalls. (pke_*): Access PKE FIFO only thorugh pke_fifo functions. (pke_pcrel_*): Renamed pke_pc_* functions. (pke_code_unpack): Numerous logic tweaks for latest UNPACK behavior changes & clarifications from SCEI. * sky-pke.h (struct pke_fifo): New explicit FIFO representation. (struct pke_device): Use struct above. (PKE_DEBUG): Removed macro as misnomer. * sky-hardware.c: Moved *_cmd_install declarations out. * sky-hardware.h: Moved *_cmd_install declarations in.
1998-03-11Sanity for 4320Gavin Romig-Koch1-0/+36
1998-03-11Allow more than just read, write and exec memory spaces in the coreAndrew Cagney1-2/+2
module.
1998-03-11* sky-gdb.c (vu_option_handler): Delete unused local unit.Andrew Cagney1-2/+11
(log_option_handler): Delete extra arg from printf, twice. * sky-pke.c (config.h): Include. (string.h, strings.h): Include. (pke_issue): Delete unused locals imm, num * sky-libvpe.c: Pacify GCC. * sky-gpuif.c (gif_io_write_buffer): Pacify GCC. * sky-dma.c (config.h): Include. (string.h, strings.h): Include. (dma_io_read_buffer): Pacify GCC. (dma_io_write_buffer): Pacify GCC. Initialize pmem before first use. (do_dma_transfer): Delete unused local variables qwbuf and local.
1998-03-10 * vr4320.igen (clz,dclz) : Added.Gavin Romig-Koch2-1/+47
(dmac): Replaced 99, with LO.
1998-03-09 * mips/vr4320.igen: Mark the insn in here as vr4320 only.Gavin Romig-Koch1-23/+31
Reorder the insns.
1998-03-06* Numerous changes & small bug fixes in PKE sim code and test suite.Frank Ch. Eigler2-79/+111
for sim/testsuite/sky: * t-pke4.run: Removed test, since it succeeds yet returns a non-zero exit code. * Makefile.in (RUNOPTS): Removed --memory-size flag, made unnecessary by sim/mips/interp.c changes. (TESTS): Removed t-pke4.ok target. * t-pke3.trc: Classified tests with [---] indicators, to match items up with entries documented in testplan.sgml. Added numerous additional tests. They assert behavior that assumes certain favorable answers to PKE question set #6 to SCEI. * t-pke1.trc: Added some [---] indicators. for sim/mips: * sky-pke.c (pke_issue): Revamped interrupt & stall code. Assume that ER1/ER0/PIS bits are only set if not masked by ERR bits. Signal PIS only if unmasked. (pke_code_error): Signal ER1 only if unmasked. (pke_pc_fifo): Signal ER0 only if unmasked. (pke_code_unpack): Round up num_operands for last operand's partial-word. Factor out "R" bit handling for better coverage analysis. Fill upper words of a quadword with zeroes for Vn_m UNPACK with n < 4. * sky-device.c (device_error): Made function accept varargs. * sky-device.h (device_error): Changed declaration to match. * interp.c (sim_open): Made 0x0000 area memory be an alias of the K0/K1 segments. Sanitized code.
1998-03-05Fix opcode fields in SHFL.*Andrew Cagney1-0/+6
1998-03-05* Fixed a double-buffering bug in PKE, due to naive use ofFrank Ch. Eigler1-5/+6
complex macros with side-effects. Gripes.
1998-03-04 * interp.c (sim_open): Map 4M of memory at zero for SKY sim only.James Lemke1-0/+3
1998-03-04* Merely eliminated silly duplicated code, to raise test coverage.Frank Ch. Eigler1-174/+29
* sky-pke.c (pke_issue): Move interrupt-handling into decode logic. (pke_code_*): Remove duplicated interrupt-handling code.
1998-03-04sim-main.h: track SKY register number changes from gdbRon Unrau1-35/+60
interp.c: ditto
1998-03-03 * vr4320.igen: New file.Gavin Romig-Koch3-0/+163
* Makefile.in (vr4320.igen) : Added. * configure.in (mips64vr4320-*-*): Added. * configure : Rebuilt. * mips.igen : Correct the bfd-names in the mips-ISA model entries. Add the vr4320 model entry and mark the vr4320 insn as necessary.
1998-03-03Fix DIV, DIV1 (wrong check for overflow) and DIVU1 (shouldn't checkAndrew Cagney3-3/+26
for overflow). Pacify GCC.
1998-03-03* Continuing PKE sim unit tests. Found little bugs in VU instead.Frank Ch. Eigler1-1/+1
* sky-vu1.c (vu1_io_write_register_window): Make CIA (pc) write effective by updating more registers. * sky-libvpe.c: Updated to match earlier VU state-change code. * sky-vpe.h: Removed unused globals from declarations.
1998-03-02add sky-gdb.c to sky_filesRon Unrau1-1/+1
1998-03-01sky-gdb.c: new file - temporary demo version of the sim interfaceRon Unrau1-18/+19
sky-hardware.c: add sim commands Makefile.in: build sky-gdb.c
1998-02-28Add generic sim-info.c:sim_info() function using module mechanism.Andrew Cagney4-46/+18
Clean up compile probs in mips/vr5400.
1998-02-28 * interp.c (DECLARE_OPTION_HANDLER): Use it.Doug Evans2-2/+12
(mips_option_handler): New argument `cpu'. (sim_open): Update call to sim_add_option_table.
1998-02-27* Major endianness fixes on sky code today. The milestone sample and existingFrank Ch. Eigler4-48/+65
PKE tests run identically on SPARC/Solaris and x86/Linux. * sky-pke.c (pke_io_{read,write}_buffer): Endianness fixes aka "E-fixes" in register and FIFO read/writes. (pke_code_{pkemscalf,pkemscal}): E-fixes in VU CIA setting. (pke_code_{mpg,unpack}): E-fixes in VU memory & tracking updates. (pke_code_direct): E-fixes in GPUIF FIFO stuffing. * sky-pke.h (PKE_MEM_WRITE): E-fixes in trace file writing. * sky-vu0.c (vu0_attach): Allocate micro/data memory with zalloc to guarantee sufficient (16-byte) alignment. * sky-vu1.c (vu1_attach): Ditto. (vu1_io_read_register_window): *PARTIAL* E-fixes in register accesses. * sky-libvpe.c (gif_write): E-fixes in GPUIF FIFO stuffing. * sky-gpuif.c (gif_io_{read,write}_buffer): E-fixes in register and FIFO read/writes. * sky-dma.c (do_dma_transfer_tag): E-fixes in tag reading.
1998-02-25* PKE unit testing continuing. Confusion over PKE1 double-bufferingFrank Ch. Eigler2-30/+210
mechanism is starting to subside. * sky-pke.h (PKE_FLAG_INT_NOLOOP): Added device flag to indicate presence of stalled & interrupted PKEcode. * sky-pke.c (pke_issue): Added PKEcode interrupt bit handling. (pke_flip_dbf): Changed double-buffering logic to match SCEI clarification. (pke_code_*): Added interrupt bit stalling clause. (pke_code_pkems*): Added ITOP/ITOPS transmission code. (pke_code_unpack): Added more careful logic for processing overflows of VU data memory addresses.
1998-02-25Finish implementation of r5900 instructions.Andrew Cagney3-20/+61
1998-02-25* Unit testing of PKE sim continuing. Only minor VU addressing problemsFrank Ch. Eigler1-18/+16
found today.
1998-02-24* A bunch of changes which get us closer to running the sample.Ian Carmichael2-6/+16
1998-02-24Add tracing to r5900 p* instructions.Andrew Cagney1-0/+4
1998-02-24* PKE sim unit testing continuing. Starting to run milestone sample.Frank Ch. Eigler2-86/+102
* sky-pke.h (PKE_MEM_READ): Removed "read" entry from FIFO trace. * sky-pke.c (pke_attach): Set trace file to line buffering iff open. (pke_io_read_buffer, pke_io_write_buffer): Handle erroneous reads/writes by zero-padding. (pke_io_write_buffer): Switch to more bit-field definition macros. (pke_issue): Remove "stalled" entry from FIFO trace. (pke_pc_advance): Correct logic for DMA-tag-skipping, PKEcode classification. (pke_code_mskpath3): Sketch of possible PATH3 masking method. (pke_code_mpg): Keep order of lower/upper VU words as supplied. (pke_code_unpack): Logic change for wl/cl/num unpacking. Weird.
1998-02-23Make it compile again for -DTARGET_SKYRon Unrau1-32/+33
1998-02-23sim-main.h: Re-arange r5900 registers so that they have their ownAndrew Cagney7-261/+628
little struct. interp.c: Update. Also add floating point Max/Min functions. mips.igen: Remove r5900 tag from any floating point instructions. r5900.igen: Rewrite. Implement *all* floating point insns (except ld/st). r5400.igen: Tag mdmx functions as being mdmx specific.
1998-02-20* PKE sim unit testing continuing. The DIRECT and MPG instructionsFrank Ch. Eigler1-28/+53
were hammered in today's runs. Work is beginning in endian-proofing the code. * sky-pke.c (pke1_issue): Issue on correct PKE device. (pke_io_write_buffer, pke_code_mpg, pke_code_unpack): Perform more endian conversions. (pke_code_mpg, pke_code_direct): Add operand alignment assertions. (pke_code_mpg): Correct VU stall checks. Correct VU opcode transfer ordering. (pke_code_direct): Correct typos in DIRECT operand accessing. (pke_code_unpack): Correct conditional sign-extension handling. * sky-gpuif.c (gif_io_read_buffer, gif_io_write_buffer): Correct assertion polarity. (gif_read_tag): Disable faulty DMA-tag testing code.
1998-02-20* Continuing unit testing of PKE simulator. It now successfully matchesFrank Ch. Eigler2-155/+210
the SCEI PKE simulator's output on its own test sample (tsv432.in). * sky-pke.h (PKE_MEM_READ, PKE_MEM_WRITE, PKE_REG_MASK_SET): Add trace file records. * sky-pke.c: (pke_track_write): Removed function. Replaced with in-line modifications to VU tracking tables. (pke_attach): Attach VU tracking tables. Use line buffering on trace files. (pke_issue): Spit out additional trace records. (pke_pc_operand_bits): Correct bitfield masking error. (*): Replace sim_read/write with kludge PKE_MEM_READ/WRITE throughout. (pke_code_unpack): Correct numerous small bugs in operand decoding etc.
1998-02-19Fall back from using igen to using gencode for the mips64vr4100 becauseJohn Metzler1-0/+10
igen is not ready yet.
1998-02-19 * interp.c (load_memory): Add missing "break"'s.Gavin Romig-Koch2-6/+25
1998-02-18* Started PKE sim unit testing. A number of minor errors were corrected.Frank Ch. Eigler2-89/+183
A few PKE instructions even run correctly! Next missing function of interest: FIFO pruning. * sky-pke.c (pke_issue): Take extra SIM_DESC argument. (pke_attach): Attach correct PKE0/PKE1 device. Open trace file if VIF{0,1}_TRACE_FILE env. var. is defined. (pke_io_write_buffer): Classify words in FIFO quadword. Use kludgey sim_core routines to access DMA registers. (pke_pc_advance): Add PKEcode classification. Correct DMA tag skipping. Emit trace records. (pke_pc_fifo): Add PKEcode operand classification. (pke_check_stall): Perform stall checks against updated register scheme. (pke_code_unpack): Correct operand-count calculation. (pke_code_stmask): Correct instruction skipping. * sky-pke.h (PKE_MEM_WRITE, PKE_MEM_READ): New kludge macros. (BIT_MASK_BTW): Corrected off-by-one error. (enum wordclass): Classify words in a FIFO quadword. * sky-dma.c (dma_io_read_buffer): Correct address checking assertions. * sky-engine.c (engine_run): Pass along SIM_DESC to PKE instruction issue code.
1998-02-18DMA define names changed (SRCADDR -> MADR).James Lemke1-1/+1
1998-02-17* XGKICK now uses memory-based GIF fifo.Ian Carmichael1-1/+1
1998-02-16* Added VU0_CIA register #define.Ian Carmichael1-1/+2
1998-02-16* Add magic VU1_CIA register.Ian Carmichael2-10/+27
1998-02-16* Partially implement new VPE_STAT register.Ian Carmichael3-12/+25
1998-02-16configure: rerun autoconfRon Unrau1-0/+2
interp.c: shield dummy vu registers with -DTARGET_SKY
1998-02-15configure.in: add -DTARGET_SKY for mips64r5900-sky-elf configure.Ron Unrau2-2/+88
sim-main.h: Define regs for sky if -DTARGET_SKY interp.c: Initial register upload/download support for sky.