Commit graph

2672 commits

Author SHA1 Message Date
bsmiles32
331b88637c Merge pull request #317 from loganmc10/patch-1
Allow using compiler other than gcc
2017-06-22 20:22:13 -06:00
Gillou68310
c0ace1d971 Fix random resets in South Park 64
https://github.com/mupen64plus/mupen64plus-core/issues/316
2017-06-22 15:20:46 +02:00
Logan McNaughton
c6506eccc4 Allow using compiler other than gcc 2017-06-20 21:13:13 -06:00
Bobby Smiles
a6e770951d Pass pointer to fcr31 around in fpu.h functions to avoid usage of g_dev. 2017-06-21 04:23:22 +02:00
bsmiles32
039d4e68af Merge pull request #310 from loganmc10/random
Fix reading CP0_RANDOM_REG
2017-06-12 12:08:12 -06:00
Francisco Zurita
1adb4c8840 In the speed limiter use the average sleep time over 5 samples
This is done to prevent jitter from samples to sample.
2017-06-09 22:32:07 -04:00
Logan McNaughton
9fd20bdb00 Fix reading CP0_RANDOM_REG 2017-06-05 11:27:37 -06:00
bsmiles32
2276eff105 Merge pull request #308 from loganmc10/patch-1
Add note for NBA Showtime - NBA on NBC
2017-06-03 09:10:05 -06:00
bsmiles32
afd689d4fc Merge pull request #307 from loganmc10/intr_fix
Trust plugins to trigger SP interrupts
2017-06-03 09:08:28 -06:00
Logan McNaughton
af7bf5092b Trust plugins to trigger SP/DP interrupts. 2017-06-02 20:53:44 -06:00
Logan McNaughton
c84be36e1f Add note for NBA Showtime - NBA on NBC 2017-06-02 16:23:20 -06:00
bsmiles32
85fae8b1aa Merge branch 'master' into mac-fixes 2017-06-02 08:01:50 -06:00
bsmiles32
41db004880 Merge pull request #296 from comex/fix-ub
Fix undefined behavior in the interpreter
2017-06-02 07:41:12 -06:00
bsmiles32
ec41a85876 Merge pull request #269 from bsmiles32/remove_memb_new
Remove byte and hword accessors
2017-06-02 07:28:43 -06:00
bsmiles32
e805380a3a Merge pull request #297 from comex/fix-swap-interval
Fix M64P_GL_SWAP_CONTROL with SDL>=1.3 and no video extension
2017-06-02 07:23:00 -06:00
bsmiles32
9c5d9e932a Merge pull request #301 from bsmiles32/no_g_delay_si
Avoid usage of global variable g_delay_si.
2017-06-02 07:20:54 -06:00
bsmiles32
896668512d Merge pull request #306 from loganmc10/ini
INI cheat cleanup
2017-06-02 07:19:40 -06:00
Logan McNaughton
a8526f6c28 INI cheat cleanup
Mainly, remove Pokemon Snap cheats
2017-06-01 19:41:22 -06:00
comex
cb414fbe35 Fix undefined behavior in the interpreter
Partially fixes #87, but there are probably more potential overflows
lurking in there; I didn't go over it too thoroughly.

FYI: In C, integer overflow when adding and multiplying signed integers
is undefined, as is shifting any integer by too high a width, and
left-shifting a signed integer if it changes the sign.  GCC started
performing optimizations based on these a decade ago, but those
optimizations don't usually apply in any particular situation, so
usually you just get away with it.

But on my system, with clang-802.0.42, Mario 64 actually fails to boot
in the interpreter without this patch: it fails the ROM checksum test
performed early on (at 0x800001AC).  (Not sure exactly which operation
was responsible; I compiled with -fsanitize=undefined, fixed everything
that made it crash under that and some nearby code, and now Mario 64
works.  However, all of the changes here should be correct/necessary.)
2017-05-30 22:38:20 -04:00
Gillou68310
57cffc7d70 new_dynarec: Rework ARM readstub and writestub functions 2017-05-30 04:45:18 +02:00
Gillou68310
cc735030d2 new_dynarec: Rework x86 readstub and writestub functions 2017-05-30 04:41:53 +02:00
Bobby Smiles
e7b0516528 Avoid usage of global variable g_delay_si. 2017-05-30 01:59:07 +02:00
bsmiles32
1d6d57e61e Merge pull request #300 from loganmc10/patch-12
CountPerScanline=1600 for Twisted Edge
2017-05-29 09:32:46 -06:00
Logan McNaughton
02f696399d CountPerScanline=1600 for Twisted Edge 2017-05-29 08:07:20 -06:00
comex
95c6c32b05 Remove unused and useless method from OGLFT
The implementation just infinitely recurses, causing a Clang warning.
2017-05-28 18:42:08 -04:00
comex
11fe79ac7e Avoid Clang warning about empty structs when new_dynarec isn't enabled
(This is also a hard error in newer Visual Studio.)
2017-05-28 18:34:55 -04:00
comex
a67645ec5a Fix M64P_GL_SWAP_CONTROL with SDL>=1.3 and no video extension
It originally mapped to SDL_GL_SWAP_CONTROL, which was removed in SDL
1.3; whoever wrote this decided to replace it with
SDL_RENDERER_PRESENTVSYNC.  However, SDL_RENDERER_PRESENTVSYNC is not a
GL attribute: it's a setting used when creating a 2D renderer, which
this code doesn't use at all.  If passed to SDL_GL_(Get|Set)Attribute,
it'll be interpreted as the SDL_GLattr value which happens to have the
same numeric value, 4, namely SDL_GL_BUFFER_SIZE.

This changes the code to use the functions SDL_GL_(Get|Set)SwapInterval
instead.
2017-05-28 18:30:23 -04:00
comex
8b82dc6a57 Makefile fixes:
- Explicitly name asm_defines_gas.h and asm_defines_nasm.h rather than
using a wildcard rule: otherwise make automatically deletes the latter
after the build is complete(!?) - see [1].

- Add missing dependency of the awk rule on ../../tools/gen_asm_defines.awk.

[1]
https://www.gnu.org/software/make/manual/html_node/Chained-Rules.html
2017-05-28 17:07:22 -04:00
comex
7b6ffc26a2 Change how asm_defines works to fix Mac build.
This didn't work correctly for two reasons:
- The symbols were being marked as undefined (imported) rather than
exported.  I could fix that by adding an initializer (= {0}), but then
the binary gets huge; not sure if there's a way around that.
- Mach-O binaries don't store symbol sizes.  You can get nm to try to
calculate them with --size-sort, but I'm not sure if this will always
output the correct result.

In lieu of more complicated platform-specific fixes, I switched to an
approach that renders the value as hex, allowing the object file to be
piped directly to awk on all platforms.
2017-05-28 17:02:05 -04:00
comex
3d36c05562 Minor Mac build fixes:
- Fix BITS=32 build (-Wl,-m,elf_i386 obviously doesn't work, and -m32
isn't needed since another part adds '-arch i686' to CFLAGS).

- Change -bundle to -dynamiclib.  (-bundle has been effectively
deprecated altogether since the early days of OS X, and was never the
right setting for .dylib files.)

- Only pass '-read_only_relocs suppress' on 32-bit.  On x86-64 this flag
just emits a warning saying that it has no effect, and evidently isn't
necessary.  (On 32-bit x86 it enables text relocations, which are used
by some of the asm stuff.)
2017-05-28 16:59:57 -04:00
bsmiles32
e8baea699f Merge pull request #293 from bsmiles32/revert_fpu
Revert "Pass pointer to fcr31 around in fpu.h functions to avoid usag…
2017-05-27 13:42:14 -06:00
Bobby Smiles
87e8207cfe Revert "Pass pointer to fcr31 around in fpu.h functions to avoid usage of g_dev."
This reverts commit 936c00ccce.
2017-05-26 16:28:42 +02:00
bsmiles32
9154619ff5 Merge pull request #289 from loganmc10/twisted_audio
Fix Twisted Edge audio
2017-05-25 17:54:38 -06:00
Logan McNaughton
4743a5e0d2 Fix Twisted Edge audio 2017-05-25 15:50:22 -06:00
bsmiles32
8e06af1ea5 Merge pull request #290 from loganmc10/patch-11
Fix audio in RE2
2017-05-25 15:03:52 -06:00
Logan McNaughton
c02e7e7eab Fix audio in RE2 2017-05-25 10:00:32 -06:00
bsmiles32
c0cb7006e7 Merge pull request #281 from bsmiles32/no_g_dev_in_fpu_h
Pass pointer to fcr31 around in fpu.h functions to avoid usage of g_dev.
2017-05-23 16:42:05 -06:00
bsmiles32
d15fcb8473 Merge pull request #282 from bsmiles32/no_g_dev_in_interrupt
No g dev in interrupt
2017-05-23 16:41:50 -06:00
bsmiles32
712ea6c3fc Merge pull request #280 from loganmc10/patch-10
Remove MK64 cheat for E and J
2017-05-23 16:41:20 -06:00
bsmiles32
15abf5746d Merge pull request #278 from bsmiles32/no_g_dev_in_rdram_hack
Avoid usage of g_dev in rdram_deteciton_hack.
2017-05-23 16:37:11 -06:00
Richard Goedeken
3ccfa7e590 Merge pull request #237 from loganmc10/new
Add ConfigExternalGetParameter
2017-05-19 22:57:53 -07:00
Bobby Smiles
a21299985f Rework the way the first vi is triggered (somewhat hackish!)...
... to avoid usage of g_dev in init_interrupt.
2017-05-18 08:36:34 +02:00
Bobby Smiles
f34bbc7f6e Adopt the same technique for reset_hard_handler ...
even if it's not a "proper" interrupt handler. I guess, for now terms
are quite confusing. But later refactoring could improve the situation.
2017-05-18 08:36:34 +02:00
Bobby Smiles
89b45c20c3 Avoid explicit dependency on concrete interrupt handler in interrupt.c
By doing so we also avoid usage of g_dev variable.
2017-05-18 08:36:34 +02:00
Bobby Smiles
3f6147e221 Pass r4300_core struct to gen_interrupt. 2017-05-18 08:36:34 +02:00
Bobby Smiles
936c00ccce Pass pointer to fcr31 around in fpu.h functions to avoid usage of g_dev. 2017-05-18 05:56:20 +02:00
Logan McNaughton
581b867707 Remove MK64 cheat for E and J 2017-05-17 11:27:42 -06:00
Bobby Smiles
e19bde226f Avoid usage of g_dev in rdram_deteciton_hack. 2017-05-16 00:37:43 +02:00
bsmiles32
46a3c1a3d0 Merge pull request #275 from TheFlagCourier/patch-1
README.md URL fix
2017-05-15 12:55:33 -06:00
Landon Jobe
6e0e5ba498 README.md Formatting Error Fix (small)
Fixed a small formatting error in the README file's markdown. Prior to fix, It listed the mupen64plus website AND a link separately. This is to address that.
2017-05-15 13:45:29 -05:00