--- uae/ChangeLog 2018/04/24 16:37:52 1.1.1.2 +++ uae/ChangeLog 2018/04/24 16:37:54 1.1.1.3 @@ -1,3 +1,398 @@ +960617 Fix memory clobber in X86.S when diwfirstword==0. +960616 Handle programs that don't wait for the blitter by finishing a pending + blit as soon as a blitter register is written to (regardless of DMACON, + to be safe). + Call gui_led only if the LED changed. +960615 Fixed dual playfield sprite priorities. Optimized dual playfield code + in X86.S. More work on AGA code. Get joystick status only in + vsync_handler to speed things up. + Make blitter fill more intelligent with table lookups instead of loop. +960614 DOS update from Gustavo. Pass real bitplane pointer to + bpl_data_differs(), don't calculate it again. +960610 Fixed silly INTEL_FLAG_OPT bug: The new __asm__ expressions use + regflags, which is of course _regflags on a.out... + More BeBox fixes from Christian. + Make the CIA bank bigger (A0..BF) and relax the CIA A/B selection + checks to make broken software (Kingsoft's Emerald Mine, reportedly) + happy. + Default framerate is now 1. +960603 New BeBox code from Christian. Fix test for ELF in configure.in. +960529 genblitter.c: generate blitfunc as a function taking ULONGs and + returning an ULONG. This makes custom.o about 4500 bytes smaller on the + x86 by removing worthless size prefixes, and should increase + performance (better for the cache, and the P6 reportedly doesn't like + 16 bit instructions anyway). + memory.c: Load Kickstart in one block and swap bytes after that if + necessary (eliminates the need for the special bebox load routine) + custom.c: Some preliminary work for AGA support. +960528 Saw a real awful piece of code that detects the right mouse button by + reading a value from POT0DAT, counting up to 25, reading from POT0DAT + again, and deciding the button is pressed if the value changed. Urgl! + Added POT0DAT() in custom.c ... + Gustavo's latest patches. +960525 Do index pulse handling in CIA_hsync_handler(). Make sure bit 12 in + INTREQ gets set on an index pulse. Don't call DISK_Index() for now, + since this breaks the Workbench. + The CIA code should _probably_ not be resetting the bits in INTREQ. + Disable this as an experiment, let's see what breaks. +960524 Z flag handling for ABCD/SBCD/ADDX/SUBX was wrong (must be clear if not + zero, was set if zero). Some other flag bugs in these functions fixed. +960523 gfxlib.c update from Christian Schmitt. Some new Mac code from Ernesto, + still not all of it, though. Italian keyboard from Alessandro Bissacco. +960522 Fix the CHK instruction. Implement middle mouse button. +960515 Fix some Nextstep problems in configure.in. +960513 New Makefile target "streifenfrei" to remove all output from configure. + Use autoconf 2.7; 2.9 is buggy. +960512 Remove BIG_ALIGNMENT hack. Remove superfluous pfield_fetchdata() call + in pfield_doline_slow_l() that resulted in garbage on the screen. + Move blttbl array from custom.h to genblitter.c + Use new lookup tables imm8_table and areg_byteinc in CPU emulation + instead of ?: expressions. + GCC appears to generate better code if the opcode is passed as ULONG to + the CPU emulation functions instead of as UWORD. + Modify some of the flag emulation __asm__ statements so that GCC uses + less registers for them. +960510 Cast malloc() results to char *, for C++ compilers. +960509 Use test for GCC and __i386__ in options.h to decide whether to use + intel flag optimization. + Use test for wish4.0 to decide whether to use the GUI. +960507 New bebox.cpp from Christian. AF sound patches from Marcus Sundberg. +960505 Fix the configuration stuff so it works. Fix some bugs in gfxlib.c +960504 Use GNU autoconf scripts to generate Makefile and sysconfig.h. Add new + files sysdeps.h that includes the right system header files. Remove + amiga.h and Makefile. +960502 More Next code from Ian (new Uae.app directory, 2 bit drawing for + custom.c). +960501 Allow the sound driver to set the frequency to a value that is slightly + different from the requested one. +960430 Added AmigaOS port from Olaf Barthel. +960427 Fixed single playfield sprite priorities in X86.S. +960426 Added new NeXTwin.m from Ian. + Turn off the blitter delay in line mode. + Added a CPU optimization from Olivier Raoul: gencpu now reads a file + "insncount" that can be generated by UAE during execution and generates + specific functions for the most common opcodes. Not documented yet. +960414 Reimplemented the fast disk emulation in a more sane way. Also it's + only done for reads now. (Plus, it no longer works :-/ Need to work + some more on this). + In blitter emulation, defer not only the setting of the bltfinish bit, + but actually defer the whole blit for the number of cycles it will + take. This makes programs the clear the screen while it is still being + displayed look much better. + Changed supervisor mode handling around a bit (was messy). + New DOS code from Gustavo. +960412 Removed smart update method 2. Added Alessandro Bissacco's blitter + optimization patch. + Fixed some sprite problems: during hysnc, clear sprpos and sprctl, and + don't do_sprites() in line 0. +960409 Be a little more intelligent about when to call pfield_linetoscr() from + pfield_doline_slow(). It's only necessary if a color register changed. + If it can be deferred to the end of the line, use the the _full + variants. + Some CIA TOD fixes. + Better transdisk, accepts first/last track parameters. +960405 New function memcmpy(), inline assembler for the i386. Compares two + memory blocks and copies them at the same time. Used in + bpl_data_differs. +960404 French keyboard from Tristan Cavelier. Parallel port emulation from + Stefan Reinauer. + Turn bpl?pt and r_bpl?pt into arrays, simplify some code using them. +960401 Some parts of Ernesto's new Mac sources. +960331 filesys.c: Close filedescriptors in free_key(). get_path() sometimes + read uninitialized bytes. + Minor cleanups all over the place. + unchain_mnn() leaves sibling intact, but clobbers next. customreset() + didn't care about that and crashed. + Use the __asm__("intel_flag_lookup") magic not only for DOS. + Support 320x300 for X (without LOW_BANDWIDTH). + Add new function fast_memcmp(), defined as memcmp if __i386__ is + undefined, otherwise a slightly optimized inline assembly function. +960329 Some bug fixes in gencpu.c +960328 Stupid programs write odd playfield modulos into the hw registers... + Eek! Sometimes, linedescr[] was indexed with a negative value... Add a + vpos >= minfirstline check to pfield_may_need_update(). I really need + to rewrite this in Oberon... + Don't turn off SHM when LOW_BANDWIDTH is selected. + Keep the nextpos and linepos variables from pfield_doline_slow_?() as + globals and initialize them in pfield_may_need_udpate(). + Modified alloc_colors256() some more. + Try to make sprite DMA follow the Amiga DMA slots more closely by + adding a currhp parameter to do_sprites() and calling it at the end + of a scanline or in pfield_may_need_update(). +960327 Added Gustavo's latest DOS code, as far as possible. Modified X86.S to + use a macro SYM() to create symbol names either with underscore or + without. + Fixed some very silly SVGAlib lores bugs. Move screen 8 pixels up in + low resolution. + Use diwstop instead of diwstart to caclulate the DIW for 320x200 modes. + Reset it not only in calcdiw(), but also in init_frame(). + Speed up 256 color allocation a little bit. +960326 New function flush_block() in xwin.c and svga.c. Called from + do_flush_line() and (new function) do_flush_screen(). Modify struct + vidbuf_description, new member maxblocklines that records the maximum + number of scanlines that do_flush_line() should collect before calling + flush_block(). If it is zero, then flush_line() is used as before. + This makes the special case stuff for SHM unnecessary, so it's removed. + Fixed a stupid bug in events code: Put ev_hsync in front of ev_copper, + so that do_copper gets called with hpos == 0 instead of hpos == 227 at + the beginning of the line. + New function init_frame() that sets up some variables, called from + customreset() and vsync_handler(). + Move smart update code to pfield_doline() from pfield_doline_h() and + ..._l(). Clean up these two with a macro DO_ONE_PLANE, removing + duplicate code. + Implement big blits and ECS chip ids. New configuration options + ECS_AGNUS and ECS_DENISE. + Implement MOVEP. +960325 Before calling pfield_may_need_update(), make sure the value that was + written to a register actually differs from the previous one. + New expansion code from Stefan Reinauer. + Modify struct mem_notify_node to contain a pointer to a valid bit + instead of the valid bit itself, so that the playfield code has to + check only one flag to decide whether to draw the line (SU method 2) +960324 The chip_flags approach has several problems. A flag may cover an area + in memory that spans two scanlines, or several scanlines may use the + same area in memory. + Provide two other, different methods for the smart update: + 1. Save all the bitplane data for each line and compare the chipmem + with the saved data to decide whether an update is necessary. + 2. Use a chain of memory_notify_node structs instead of a single bit + for flags. Each scanline owns a set of these structs and chains them + into the right place, and the chipmem_?put routines walk the chains + and set the modified bit for each element. + Unfortunately, both methods are slower than the old one. Especially the + first one has some advantages though: it speeds up programs that clear + the screen each update and write the same contents back, and it + can speed up double-buffering programs at full framerate, since it does + not have to check whether the bitplane pointers have changed. + Remember the first and last drawn line for each frame, and pass them to + flush_screen. Use this in xwin.c for SHM. Modify SHM logic: if smart + update is selected, call XShmPutImage() from flush_line() instead of + from flush_screen(). But gather blocks of consecutive lines to avoid + calling XShmPutImage() too often. +960323 "Smart update" method, based very loosely on Alessandro Bissacco's + work, implemented: + Add an array chip_flags that records any change made to specific words + in chip memory. + Move all the hardware registers relevant to playfield display into a + new structure bplinfo. Remember the contents of this structure in + struct line_description for every line on the screen. Avoid redrawing + in pfield_doline if the screen memory has not been modified for the + line to be drawn and if the information from the last frame matches + that in the current frame. +960322 Duplicate all functions responsible for drawing (pfield_doline, + pfield_doline_slow, pfield_sprite, pfield_*word_*res) and append _h + or _l (ah, the golden C++ days, when we had templates... which never + worked). Modify the *_l functions to support drawing in low resolution + (i.e. 320x200). Change the options -d and -H to support selecting color + mode and resolution, thereby getting rid of some SVGALIB_* options. + Get rid of the old pfield_*word_*res functions. + Collect information about the minimum diwstart value during the + previous frame and use that in case 320x200 was selected to fit the + image on the screen. + Get rid of HAVE_JOYSTICK (breaks the "-J" option) +960321 Give up in op_illg() if opcode is 0x4e7b and the exception handler for + it is NULL. In that case, it's a 68020 Kickstart. +960319 New Next code from Ian. SunOS target was still screwed (two CFLAGS). + Turn -x option into a "hair cursor" option. Support multiple mounts, + but warn if more than one is seen (still does not work with Kick 1.3). + Integrated Samuel Devulder's new LOW_BANDWIDTH patch. +960318 Integrated the start of Markus Gietzen's gfx library replacement. + Changed the interface between custom.c and the graphics code. There has + to be a buffer holding the data of all the lines on the screen. For + linear SVGAlib modes, this is the video memory. Eliminated -x option, + prepare_line(), DrawPixel() and the X_?BIT_SCREEN options, replace with + 3 versions of pfield_linetoscr for different datatypes. Implement + proper handling of the borders above and below the DIW in custom.c + instead of in flush_screen(). + Move common code (color allocation) from all the graphics files to new + file gfxutil.c. + Swedish keyboard from Per Olofsson. + +960315 Release 0.5.0 +960315 Newest DOS port from Gustavo. New sgi-gcc target. +960314 Add -lXext to osf target. Use "rb" for fopen() in main.c +960310 Play a bit with the __asm__ constraints. Implement CHK. +960307 Fix some stupid Makefile errors. Call parse_cmdline() if no init file + is found. + First round of NextStep patches; new file NeXTwin.m + Stupid bug in custom.c: The #define is called NO_FAST_DISK, not + NO_FAST_FLOPPY. + Fix one of the problems the Deform demo had with the blitter: The + line texture wasn't rotated to the right position in blitter_init(). +960306 Use some black GCC __asm__ magic to calculate flags more quickly + (config INTEL_FLAG_OPT) + HAM was broken by pfield_linetoscr changes. Fixed. + LOW_BANDWIDTH sometimes got confused when the display window changed. +960305 BCD instructions work well enough for Locomotive Basic on CPE. + New function parse_cmdline_and_init_file() that reads ~/.uaerc or + ./.uaerc and adds the options found in those files to those in argv[]. + Patch from Denis Sablic to make disk image filenames runtime + configurable. Extend it for the ROM filename. + Remove some of the run-time configurable stuff from config.h. + More X keysym fixes (I finally got a proper .Xmodmap ...) + for SVGAlib: Delete key, and PgUp/PgDn as Amiga keys. + The sound driver can now handle 22050 Hz and/or 8 bit samples. Both of + these are the default with LINUX_SOUND_SLOW_MACHINE. + Also use the SNDCTL_DSP_GETBLKSIZE ioctl and write the buffer when + there is enough data. + Abuse keybuf.c to provide a fake joystick emulation with the numeric + pad (enable with -J) +960304 bebox.cpp from Christian. + Rename pfield_linetoscr_full to pfield_linetoscr_full8. + More x86 assembly: pfield_linetoscr_full16. +960303 SunOS target from Dirk Vangestel. Put some not-so-superfluous includes + back in. Added the DOS specific patches to filesys.c. + Started x86 assembly optimizations. New file X86.S, includes an + optimized version of pfield_linetoscr (for 8 bit screens only). + Don't use SA_RESTART if it isn't defined. + prepare_line() wasn't called often enough (again...), leading to memory + corruption and "hit the reset button" bugs when using SVGAlib. +960226 Get rid of bool, true and false in amiga.h and everywhere else. + Copy yesterdays code to AF_SOUND code, too. + Include first round of Christian Bauer's BeBox patches. Add AIX fix + from Samuel Mackrill. + Add #include and #include in some more places. + Modify gencpu.c and readcpu.c so that immediate types j and J (0..15 + and 1..8) can be merged. Replace HAVE_ONE_GIG... option with a new + CPU_EMU_SIZE option that can be set to a value in the range 0..5, + where 0 is minimum size and 5 is equivalent to HAVE_ONE_GIG... +960225 Remove multiplications in sound code, use a big lookup table. +960222 Go back to having only one memory bank table of type addrbank instead + of several function pointer arrays. Eliminate the HAVE_BROKEN_SOFTWARE + define by extending the memory bank table to 65536 entries. + Remove remaining DUALCPU code. Allow BTST src,imm instructions in + table68k. +960220 Back out filesys.c change from Stefan Reinauer: don't call V36 specific + functions in expansion.library. + Better fix for the filesys.c assign problems by Oliver Moehrke. + Make new playfield code conditional on EXPERIMENTAL_SCREEN_UPDATE. + Improve the 64bit variant of said code. Try to get alignment for + apixels by putting it into a union with a long. + Kill the child in gui_exit(). Make graphics_init() return a value and + check it in main.c to see whether graphics were initialized. If not, + call gui_exit() anyway. + Use new 256 color allocation routine from svga.c in xwin.c, too. + Make LOW_BANDWIDTH compile _and_ work (wow...). +960219 Fix bug in memory.c: When loading 256K Kickstart, copy 256K, not 128K. +960218 Finished the rest of the UI: reset, debug and quit buttons as well as + drive LEDs. New target linux-gui; all others use dummy file nogui.c + for now. +960217 The GUI now supports inserting and ejecting diskfiles and displays + their names. Two pipes are used now, one for reading and one for + writing. Properly wait for the process to start up. + Use sigaction() instead of signal() in debug.c. + More fixes for the new display routines: Need to do a final call to + pfield_*word_*res with the data shifted right from the last fetched + word. +960216 Copper & sprite bugfixes from Marco Nelissen. Better X keyboard support + from Bruno Coste. + Move my_strdup() from filesys.c to options.h + New files xui.c, uae-ui (shell script) and uae-ui.tk (wish script). + These create a GUI for the X version of the emulator. So far, the + power LED works. +960215 Don't rely on SVGAlib headers defining any keycodes at all. + Include Thorsten Frueauf's NetBSD patch. Apparently, the devname + variable in hardfile.c caused a namespace collision, so rename it to + uaedevname. Fastmem fixes, debugger help, and ConfigDev allocation in + hardfile and filesys from Stefan Reinauer. + xwin.c: Give the window a title. + Half-implemented the DIVU.L, DIVS.L, MULU.L and MULS.L instructions. +960213 AF sound system support from Marcus Sundberg. Win95 keyboard support + for SVGAlib from Thierry Lescot. Added most of Gustavo Goedert's MS-DOS + port. + When using the old pfield_*word_*res functions, the gen_pfield_tables() + function was undefined. + Hmmm, /dev/brain must have been unmounted when I wrote the new pfield_* + functions. Now they make sure they access the apixels array only with + addresses that are multiples of 16 bytes. +960212 Fix copy&paste bug in cia.c found by Marco Nelissen: Need to call + RethinkICRB() instead of RethinkICRA() for CIA B timers. + Added Stefan Reinauers autoconfig area/fastmem support. Added run-time + options for use_slow_mem and use_fast_mem. + Oops, the pfield_*word_*res() optimizations break completely on HPs and + Sparcs. Now use this optimization only if we are using GCC 2.7. + HPUX fixes in the Makefile. New target hpux-gcc. + The code for clearing the areas above and below the DIW was trying to + be a little too clever selecting the color. Just use the current + background color. + Added channel attachment to the sound code. Untested. +960211 Found some flag setting bugs in the rotate/shift instructions and in + addx/subx (which I thought I had already fixed) by reimplementing + DUALCPU mode to work with Ed's e68k. + Argh! The copper is completely disabled during DDF in Hires 4 bitplane + mode - so copper positions 0x30 and 0x34 are about 640 pixels apart. + The Kickstart uses FF39FFFE to wait for the end of line 256 instead of + FFDFFFFE as in all the other modes. This is implemented now, but + probably not 100% correct. + Added check whether SVGAlib doesn't support our mode. + If using GCC >= 2.7, define __attribute__((aligned(16))) as + BIG_ALIGNMENT in config.h. Use it for the apixels array to prevent + potential problems on the Alpha. + Tried to make the color selection routine produce better results in 256 + color mode. +960210 readdisk didn't work at all for large files - fixed. + In pfield_doline(), clear the apixels array if playfield DMA is off. + In SPRxCTL(), reset sprite mode when sprpos==sprctl==0 + Rewrite pfield_orword_hires() and friends to use lookup tables. No + noticeable improvement on my machine, but might be different on other + machines. Two versions of this code: one using 64bit longs on the Alpha. + New targets linux-debug and linux-prof. + Use 1MB slow mem. + -funroll-loops is a little excessive. Remove it. + Add support for linear addressing modes for SVGAlib version. Speedup + is 20-30% on my old 486 VLB. Now, would someone please fix SVGAlib to + support that for the S3-864 as well? + Set SVGAlib keyboard mode to DONT_CATCH_CTRLC. + Change custom.c, xwin.c and svga.c to keep track of the display window + and background color and to clear the areas above and below the display + window if necessary to remove garbage images from previous frames. + Set the LOF bit in the Kickstart replacement init routine. Also + initialize CIAs to Kick 1.3-like values. +960209 Some more -DHAVE_xxx_H options in the Makefile and filesys.c. DEC Alpha + fixes for filesys.c from Ed and Marcus. HPUX fixes. + New field in table68k for CPU type, parsed by readcpu and compared to + CPU_LEVEL which is defined in config.h. New instructions MOVE2C, MOVEC2 + and CAS. Also a new field for priviledge level that is used by gencpu to + generate tests for regs.s and Exception(8) calls if necessary. + Move parsing of table68k into a new file build68k.c. Generate a file + called cpudefs.c containing the information from table68k in + machine-readable form. Change readcpu.c to use the array found in + cpudefs.c. + Don't generate the d8(An,Dn) addressing mode in-line. Generate a call to + get_disp_ea(), which is an inline function in newcpu.h if UAE is + configured for 68000 emulation; for 68020 emulation, it is defined in + newcpu.c. + Debugger could crash on illegals because there was no mnemonic defined + in lookuptab[]. + Return zero for SERDATR. +960207 It seems that the copper stops completely if an attempt to write to a + specific register fails because of COPDANG. Apparently, the Kickstarts + use this to stop the copper with a 0x00000000 longword. This leaves the + question why they don't do 0xFFFFFFFE like everybody else. + Enable 512K slow memory by default. + Integrate Stefan Reinauers battclock patch that makes it work with + newer Kickstarts. + In cia.c, do the little index pulse hack even if dskdmaen==1, because + DMA is only enabled when dskdmaen==2 (Helps the "Mad Decision" demo). + Add solaris entry to Makefile (GCC, Openwin, -DHAVE_STATFS_H) + Define HAVE_STRINGS_H for SGIs, change filesys.c accordingly. +960206 Build a smaller table instead of cputbl.c. Use readcpu and the smaller + table to build the cpufunctbl array at run-time. + Nuked the other half of the old CPU emulator. Reimplemented debugger to + use the information generated by readcpu. + Define HAVE_STATFS_H for SGIs in the Makefile, and use that as a test + in filesys.c instead of #ifndef __linux. + Hack filesys.c, get_path() to support the assign command. + Add -fstrength-reduce and -funroll-loops in Makefile to make people + nervous. + Rewrite Sam Devulder's LOW_BANDWIDTH patch and add it to xwin.c. +960205 Forgot some PC-relative bit instructions in table68k. + Nuked half of the old CPU emulator. + Split gencpu.c into two parts, new one is called readcpu.c and just + parses the table68k file. Link it to the main program. + +960205 Release 0.4 960203 filesys.c, action_read(): Slightly more efficient code (translate Amiga address to real pointer). Moved some common code in the generate_* functions in gencpu.c to a