Commit Graph

646 Commits

Author SHA1 Message Date
gbeauche
7efab4276f Improve FPU emulation accurracy. However, PPC_ENABLE_FPU_EXCEPTIONS is still
set to 0 until generated code is optimized enough (current slow down factor
is 3x vs. previous core, expectations are about 50% slower FP code).

The main benefit is exception bits are accurate. All glibc test-fenv,
test-arith{,f}, test-double, test-float pass on ppc, and mostly on x86_64
with gcc 4.0.1. Yes, this is also compiler dependent.

FIXME: find a real Mac application that depends on precise FPSCR bits... I
think I don't want to care optimizing yet until someone shows me a real world
application.
2006-07-04 07:19:18 +00:00
gbeauche
0a74d0559a Fix fnmadds & fnmsubs emulation + try to provide optimized fma routines for
better precision
2006-07-04 07:06:18 +00:00
gbeauche
dc88ee271d Use lrint() for fctiw on x86-64. This is because some glibc use AMD optimized
math library where floor(), ceil() et al. don't set the inexact flag correctly
2006-07-04 06:59:28 +00:00
gbeauche
dc3df920c5 Fix fctiw emulation (VEX's jm-ppc-test -f, handle current rounding mode) 2006-07-04 06:58:24 +00:00
gbeauche
de5389bc0e Fix vminfp & vmaxfp emulation (VEX's jm-ppc-test -a, triggered nan bugs) 2006-07-04 04:47:04 +00:00
gbeauche
39ee6ba1aa Fix vctsxs & vctuxs emulation (VEX's jm-ppc-test -a, triggered inf/nan bugs) 2006-07-04 04:37:15 +00:00
gbeauche
0a2f9d3f03 Add fsel instruction emulation (VEX's jm-ppc-test -f) 2006-07-04 04:25:02 +00:00
gbeauche
635ee55a5d Fix floating-point single precision load/store (VEX's jm-ppc-test -f) 2006-07-04 04:21:02 +00:00
gbeauche
d9eb35f026 updates 2006-05-14 20:46:19 +00:00
gbeauche
e339993b22 Updates. It's high time for a new snapshot. 2006-05-14 17:14:09 +00:00
gbeauche
c512377a12 Add 1GB item to GUI 2006-05-14 16:14:29 +00:00
gbeauche
bd6ec66354 Add missing "etherguid" prefs item for Basilisk II Ethernet support (b2ether). 2006-05-14 16:13:16 +00:00
gbeauche
3f3891ab31 Move up NATMEM_OFFSET to 0x11000000. This is arbitrarily determined to be
the base of the largest free block. Turns out SDL libraries are loaded around
0x10000000 so we have some luck here.
2006-05-14 15:58:11 +00:00
gbeauche
8a27c90e15 Temporary workaround for Windows (shndx_text is not unique...) 2006-05-14 14:12:57 +00:00
gbeauche
d26f8ad8e2 Fix for DIRECT_ADDRESSING mode (Windows) 2006-05-14 13:48:05 +00:00
gbeauche
7ef09b90bb NQD dirty boxes, BeOS backend -- no-op. 2006-05-14 08:35:35 +00:00
gbeauche
5e4c2b7bb9 NQD dirty boxes, X11 backend. 2006-05-14 08:32:33 +00:00
gbeauche
757f849ad0 Optimize generated code to NQD & CheckLoad functions. They don't call into
68k or MacOS code, so they don't need to be a termination point. i.e. don't
split into two basic blocks and thus avoid a full hash search.

Also add missing NQD_unknown_hook NativeOp from previous commit.
2006-05-14 07:21:10 +00:00
gbeauche
74a5024be4 NQD dirty boxes, generic code
+ while we are at it, also rename a few NQD related NativeOps.
2006-05-13 17:12:18 +00:00
gbeauche
484469962b Don't let SDL catch SIGINT and SIGTERM signals. This is not suitable for
SheepShaver since we are typically translating SDL_QUIT events to PowerOff()
on MacOS side. And, if MacOS is not fully booted, it's not really convenient
to shut it down, even with ctrl-C. i.e. you had to kill -9 it.
2006-05-09 19:53:31 +00:00
gbeauche
0af4721cb6 Don't read from 0xf8000090 during MacOS (8.5, 9.0) installation. Is this an
OpenFirmware check for OldWorld 604-based machines?

XXX I have code pending that makes it possible to use PowerMac ID #3035 and
model 510 (PowerMac G3 Series). However, I have a regression with one of my
MacOS 8.6 disks. This is non-standard anyway since it was installed from the
iMac DV 8.6 discs ("yellow" not generic) with MOL -- SheepShaver can't cope
with it.

So I am not surprised it breaks. Otherwise, 8.5 -> 9.0.4 were fine with it.

BTW, the "regression" is Native Resource Manager is not installed and the
boot gets mad later. FWIW, it's the same as for MacOS 9.1. A resource is
very likely not loaded.
2006-05-08 23:32:58 +00:00
gbeauche
0a37b8f5e9 Fix MacOS X GUI (new fake DarwinSys*() functions) 2006-05-08 17:20:20 +00:00
gbeauche
8bd38cff75 Also nuke MacOS X GUI binary and bundle for make clean 2006-05-08 17:19:45 +00:00
gbeauche
12195c32b5 Define UNALIGNED_PROFITABLE on x86 platforms 2006-05-07 16:54:58 +00:00
gbeauche
75f3bdea68 Fix NQD_bitblt_hook() to perform sign check correctly 2006-05-07 10:49:48 +00:00
gbeauche
bc13355b57 Add linker scripts from Basilisk II and make it possible to allocate up to
1 GB of Mac memory. Only tested on Linux/x86_64 so far but with a somewhat
interesting (MacOS, ROM, RAM size) matrix.

XXX: It should be possible to allocate up to 1.5 GB by relocating the ROM
base to something like 0x60800000.
2006-05-06 10:42:51 +00:00
gbeauche
6da4032ab7 Add a few FE0A opcode patches. This slightly improves stability. 2006-05-06 10:30:00 +00:00
gbeauche
80c87484f3 Add 'nsrd' 1 and 'gpch' 650 patches for MacOS 7.5.3 Revision 2.2 2006-05-06 09:23:28 +00:00
gbeauche
3bd5d0c787 Instructions that trap are now an end-of-block condition. This should avoid
the compilation of illegal instructions and thus stopping execution earlier.
2006-05-06 07:19:39 +00:00
gbeauche
e88961bc45 Review MacOS 8.6 vs 9.0 patches:
- 'boot' 3: set boot stack pointer only once at the correct place
- 'gpch' 750: fix FE0A opcode replacement (selector #$0a is virt2phys on pgidx)
- 'gpch' 750: remove bogus patch for SonyVars
- Mark patches "9.0" verified accordingly vs. 8.6
2006-05-05 19:05:24 +00:00
gbeauche
4578abcbd4 Add native GetNamedResource() and Get1NamedResource() patches for PPC Unix.
Only tested on MacOS X so far. It shouldn't be a problem for Linux/PowerPC.
2006-05-03 22:11:49 +00:00
gbeauche
812682fda6 update 2006-05-03 21:53:47 +00:00
gbeauche
f3ba2f0d64 Don't access ROM85 as it it was a pointer to a ROM version number (8.0, 8.1)
aka. fix bogus AppleShare extension, it was trying to dereference 0x3fff.

XXX: why is this code called in the first place?
2006-05-03 21:53:33 +00:00
gbeauche
21f35a34f0 Add patches for native GetNamedResource() and Get1NamedResource(). This will
be useful to fix a bug in the AppleShare extension (see DRVR .AFPTranslator
in Basilisk II)

Unrelated improvement: call sheepshaver_cpu::get_resource() directly, don't
get it through another global function.
2006-05-03 21:45:14 +00:00
gbeauche
0f5f874e11 Huh, committed wrong changelog for configure.ac, it should have been the
following: fix build of the CPU emulator (check for additional math functions)
2006-05-02 19:36:57 +00:00
gbeauche
8123813cad Add SLiRP support to SheepShaver for Windows 2006-05-02 19:35:39 +00:00
gbeauche
22110cb4f3 Make GetMainWindowHandle() a globally exported function as it is used e.g.
in clip_windows.cpp & video_sdl.cpp
2006-05-02 19:34:04 +00:00
gbeauche
e5051464bf Move likely() definitions to dyngen-exec.h, they are only used in the CPU
core where it's most useful (give a stronger hint to gcc4)
2006-05-02 19:33:10 +00:00
gbeauche
b9b1fd4e22 Don't build a built-in GUI with --enable-standalone-gui was requested 2006-05-02 05:50:38 +00:00
gbeauche
085253dc9b - Fix build on ppc (paranoia.cpp -- one extra STR_SIGUSR2_INSTALL_ERR left)
- Fix for GTK+ 1.2 GUI on ppc (notebook's panes redraw)
- Add run-time detection of the underlying arch for "jit" detection (MacOS X)
2006-05-01 23:01:53 +00:00
gbeauche
9b60acb2da Port --enable-standalone-gui support to SheepShaver
Others changes include:
- Factor out STR_SIG_INSTALL_ERR messages
- Process command line arguments early (prior to calling PrefsInit())
- GUI: set start_clicked only if the "Start" button was clicked
- GUI: save changes to the "Input" pane when the "Start" button was clicked
2006-05-01 22:33:34 +00:00
gbeauche
a7888c6c64 fix underquoted definitions 2006-04-06 22:36:43 +00:00
gbeauche
5678c1d37d Detect SSE3 & SSE4. 2006-04-01 22:14:33 +00:00
gbeauche
b288f6278e Helper macros to annotate likely branch directions. Colateral effect: this
also fixes build with GCC 4.1 (ppc-dyngen-ops.cpp) since the branches are
re-ordered in a way there is now only one exit-point in op_jump_next_A0().
2006-04-01 21:41:19 +00:00
gbeauche
d475faf4ba Copy constants to 32-bit addressable data pool. This fixes -pie builds on
x86_64: program resides above 32-bit barrier and JIT generated code wants
(knowingly) to access globals directly.
2006-01-28 22:03:31 +00:00
gbeauche
d9b4b31490 Merge from KPX: new exit() handling code 2006-01-28 22:00:10 +00:00
gbeauche
e0589a097e fix new/delete mismatch in slow_allocator, also use that for lazy_allocator 2006-01-28 21:59:41 +00:00
gbeauche
022d09375f Merge from KPX: new exit() handling code; make "syscall" illegal for MacOS
emulation (SheepShaver)
2006-01-28 21:57:52 +00:00
gbeauche
d4210ef902 Check whether compiler supports byte bit-fields. If so, we can enable slirp
emulation code since it pure C+sockets code.
2006-01-27 23:48:08 +00:00
gbeauche
6ddf123991 Adapt for new non-blocking I/O error message 2006-01-24 23:50:19 +00:00