Commit Graph

2694 Commits

Author SHA1 Message Date
Ryan Houdek b24197f913 Adds MCR/MRC to the ARMv7 emitter. 2014-11-16 09:29:27 +00:00
Stevoisiak b25e1a2eb4 Various formatting and consistency fixes 2014-11-13 22:42:18 -05:00
Fiora 6603f98d04 JIT: add 64-bit write support to FIFO functions
Also fix 64-bit values passed to CallAC and otherwise correct immediate
handling in FIFO writes.
Fixes 007 Nightfire.
2014-11-09 21:24:30 -08:00
Lioncash f6b4b4dbba Merge pull request #1497 from lioncash/host
Host: Kill off Host_SysMessage
2014-11-06 20:41:53 -05:00
Lioncash d79c794e8c Merge pull request #1490 from rohit-n/initialize
Common: Fix -Wmaybe-uninitialized warning.
2014-11-06 20:37:32 -05:00
Lioncash 884ec2ed13 Host: Kill off Host_SysMessage
Equivalent facilities already exist.
2014-11-05 02:30:48 -05:00
Rohit Nirmal f361ef1eb3 Common: Fix -Wmaybe-uninitialized warning. 2014-11-03 21:38:42 -06:00
comex 9cba787871 Merge pull request #1408 from randomstuff/perf
Profiling: measure time on non-Windows/POSIX using clock_gettime
2014-11-03 22:36:32 -05:00
Jasper St. Pierre e290a3d39c MemArena: Fix the launching of non-Wii games
When we cleaned up the code to calculate the shm_position and total_mem
in one step, we sometimes skipped over certain views because they were
Wii-only. When looking at the total memory, we'd look at the last field,
whether or not it was skipped. Since Wii-only fields are the last view,
this meant that the shm_position was 0, since it was skipped, causing us
to map a 0-sized field. Fix this by explicitly returning the total size
from MemoryMap_InitializeViews.

Additionally, the shm_position was being calculated incorrectly because
it was adding up the shm_position *before* the mirror, rather than after
it. Fix this by adopting a scheme similar to what we had before.
2014-11-03 11:08:59 -08:00
Jasper St. Pierre f660789254 MemArena: Merge the initialization code with the size calculation code
To make mistakes like in the previous commit less prevalent in the future.
2014-11-02 19:59:14 -08:00
Jasper St. Pierre 5e5ed07b41 MemArena: Fix the calculation of position in SHM
The code to calculate the offsets into the SHM file wasn't properly
respecting the skip flags, causing it to calculate offsets beyond
the end of the SHM file.
2014-11-02 19:25:42 -08:00
Jasper St. Pierre 64540bc60d MemArena: Fix a memory leak caused by pointer confusion
This code was ported from out_ptr, which was a double-pointer, and
wanted to double-check that the proper arena was actually allocated.

When I ported it to store the pointer directly in the view regardless
of whether out_ptr was non-NULL, I got confused here and instead
caused the code to only free the arena if the first byte was non-zero.
2014-11-02 19:25:42 -08:00
Jasper St. Pierre 1e93b0db19 MemArena: Rename GrabLowMemSpace to GrabSHMSegment
This code originally tried to map the "low space" for the Gamecube's
memory layout, but since has expanded to mapping all of the easily
mappable memory on the system. Change the name to "GrabSHMSegment" to
indicate that we're looking for a shared memory segment we can map into
our process space.
2014-11-02 16:51:27 -08:00
Jasper St. Pierre 079b881d20 MemArena: Clean up the code that does the mirroring 2014-11-02 16:51:26 -08:00
Jasper St. Pierre 6813473367 MemArena: Remove the low mappings for our pointers
These are effectively unused, since the memmap already maps them in one
place. For 32-bit, they might have some slight advantage, but we already
special-case the regular "high-mem" pointer for 32-bit, so just use the
one we already have...
2014-11-02 16:50:36 -08:00
Jasper St. Pierre 4a59750b30 MemArena: Bail on Arch64 if the out_ptr allocation fails 2014-11-02 16:34:17 -08:00
Jasper St. Pierre 48aff73b6a MemArena: Remove duplicated code
I can't find any obvious difference between these two paths.
2014-11-02 16:34:17 -08:00
Gabriel Corona 641e820257 Profiling: measure time on POSIX systems using clock_gettime 2014-11-03 00:07:12 +01:00
Tillmann Karras 033f2a7e93 x64ABI: get rid of some duplicate code 2014-11-02 02:00:47 +01:00
Rohit Nirmal a09afe8821 Fix build failing with PCH disabled. 2014-10-29 13:00:48 -04:00
comex 089e32ba7d Merge pull request #1307 from comex/bitset
Higher level bitset wrapper
2014-10-28 23:39:35 -04:00
Jasper St. Pierre d9a1fc1564 BreakPoints: Fix compile warning 2014-10-28 12:22:30 -07:00
skidau 1630b0c684 Merge pull request #1291 from skidau/debugger-step-out
Dolphin debugger enhancements
2014-10-28 12:53:22 +11:00
Ryan Houdek 043bd710a0 Merge pull request #1394 from Sonicadvance1/fix-arm-cpudetect
Fixes ARM CPU detection routine for the hardware.
2014-10-27 05:07:24 -06:00
skidau 4570dd7eeb Fixed a crash that would occur if a new watch were added by entering a watch name.
Code style updates.
2014-10-26 23:23:45 +11:00
skidau 73dca1ca33 Added a new option to add memchecks from the Watch window.
Fixed watch labels from being truncated at the first whitespace.
2014-10-26 16:14:17 +11:00
skidau b73130af77 Added Load/Save function for the Watch window.
Made the floating windows toolbars dockable.
Scaled down the breakpoint toolbar icons to 16x16.
2014-10-26 14:56:03 +11:00
skidau b34e220086 Added a "Delete watch" context menu to the Watch window.
Added a "View memory" command to the context menu.
2014-10-26 14:56:03 +11:00
skidau 613cae613a Added a RAM Watch window to the debugger
Conflicts:
	Source/Core/Core/HW/Memmap.cpp
	Source/Core/Core/HW/Memmap.h
	Source/Core/DolphinWX/Debugger/CodeWindow.h
2014-10-26 14:56:02 +11:00
skidau df37649b9f Changed the step over routine to a single stepping version that steps until a blr is encountered.
Cleared out all temporary breakpoints on each step to prevent phantom breakpoints from stopping the debugger.
2014-10-26 14:56:02 +11:00
comex 5f21683343 Merge pull request #1388 from waddlesplash/dolphin-qt
DolphinQt: About dialog fixes, SystemInfo dialog
2014-10-25 21:20:02 -04:00
comex f51c233a08 Add workaround for OS X symbol clash and AllOnes helper method. 2014-10-25 16:57:25 -04:00
comex eb7f4dac50 Convert registersInUse to BitSet. 2014-10-25 16:57:25 -04:00
comex b6a7438053 Add BitSet and, as a test, convert some JitRegCache stuff to it.
This is a higher level, more concise wrapper for bitsets which supports
efficiently counting and iterating over set bits.  It's similar to
std::bitset, but the latter does not support efficient iteration (and at
least in libc++, the count algorithm is subpar, not that it really
matters).  The converted uses include both bitsets and, notably,
considerably less efficient regular arrays (for in/out registers in
PPCAnalyst).

Unfortunately, this may slightly pessimize unoptimized builds.
2014-10-25 16:56:51 -04:00
comex 4b0c6d8e0f Merge pull request #1385 from lioncash/bitfield
BitField: Fix a typo in the sample usage.
2014-10-25 16:48:31 -04:00
Ryan Houdek 3ac2d8e1f1 Revert "Removes ARMv7 specific byteswap routines from CommonFuncs.h" 2014-10-25 15:28:04 -05:00
Ryan Houdek b66a7f83c2 Fixes ARM CPU detection routine for the hardware.
We weren't dropping a newline character from the string, we were cutting off the last character of the hardware name.
This fixes my TK1 being called 'lagun' when it's name is 'laguna'
2014-10-25 09:14:14 -05:00
skidau 8598d6bc2b Merge pull request #1364 from RachelBryk/titles
Read game title from ini file, or titles.txt if it exists.
2014-10-25 13:33:26 +11:00
Ryan Houdek 6483f8d45c Removes ARMv7 specific byteswap routines from CommonFuncs.h
GCC has optimized this using the exact same code since 4.7 or 4.8.
Android building falls back to the __linux__ route.
No need to keep these around anymore since we aren't building on an old GCC version.
2014-10-24 16:21:54 -05:00
Augustin Cavalier 51700a2b68 Fix the brand/cpu_string reversal.
Before this commit, the two were reversed ("cpu_string" had the brand, e.g. "AuthenticAMD"; and "brand_string" had the CPU type, e.g. "AMD Phenom II X4 925").
2014-10-24 16:09:21 -04:00
Lioncash c0c835d0b6 BitField: Fix a typo in the sample usage. 2014-10-24 13:33:02 -04:00
skidau 716fe06289 Merge pull request #1349 from comex/good-job-dereferencing-null-on-purpose
Fix some warnings from Clang trunk in an overly aggressive manner
2014-10-24 13:03:09 +11:00
comex 00c6ec97a6 Merge pull request #1347 from comex/header-hygiene
Add missing includes where headers depend on other headers having been included first.
2014-10-22 23:23:58 -04:00
Rachel Bryk b1e14a65a2 Read game title from ini file, or titles.txt if it exists. 2014-10-22 22:19:40 -04:00
comex 6e774f1b64 Add missing includes where headers depend on other headers having been included first.
This is good hygiene, and also happens to be required to build Dolphin
using Clang modules.

(Under this setup, each header file becomes a module, and each #include
is automatically translated to a module import.  Recursive includes
still leak through (by default), but modules are compiled independently,
and can't depend on defines or types having previously been set up.  The
main reason to retrofit it onto Dolphin is compilation performance - no
more textual includes whatsoever, rather than putting a few blessed
common headers into a PCH.  Unfortunately, I found multiple Clang bugs
while trying to build Dolphin this way, so it's not ready yet, but I can
start with this prerequisite.)
2014-10-21 21:22:16 -04:00
comex 06433652be Improve some libcdio CoreFoundation code.
I found it via clang complaining about a useless null check on an array,
but I decided to get rid of the array in favor of dynamic allocation, as
there was no reason to assume a maximum length of 0x32 bytes.  Plus, add
a CFString type check just in case, and switch to UTF-8 in the
off-chance it matters.

The result has not actually been tested, as I have no CD drive.
2014-10-21 21:20:11 -04:00
Ryan Houdek 2e94814441 Changes from ARMv6 NOP to ARMv7 NOP.
Dolphin doesn't support ARMv6. Get this out of here.
2014-10-21 14:17:07 +00:00
skidau e8da34ef25 Merge pull request #1320 from FioraAeterna/hash64bitcrc
Use CRC to output 64 bits instead of 32
2014-10-20 14:50:21 +11:00
Lioncash 3782be15a3 Merge pull request #1309 from Stevoisiak/spellingFix
Minor spelling fix
2014-10-18 22:40:41 -04:00
Fiora d2e004fa9e Use CRC to output 64 bits instead of 32
A bit hacky, but should dramatically reduce the odds of hash collision.
2014-10-18 00:24:35 -07:00
Fiora 15a4bccb73 Hash: unroll CRC loop, since CRC32 typically has nontrivial latency
Seems to be about 20-30% faster texture cache hashing on my machine.
2014-10-17 15:39:08 -07:00
Stevoisiak ed5e698511 Minor spelling fix 2014-10-17 15:51:19 -04:00
skidau 9ddbdeb39f Merge pull request #995 from FioraAeterna/fma
Add FMA support to emitter and use it in the JIT
2014-10-12 13:56:18 +11:00
Henrik Rydgård 877081c7df Be consistent with braces. 2014-10-10 22:34:03 +02:00
Henrik Rydgård 9bca1a00d7 x64 emitter: Add some more missing ops (MOVDQA, MOVDQU, PSHUFHW)
Also constify some pointers.
2014-10-10 18:30:05 +02:00
Henrik Rydgård a2c46665c5 x64 emitter: Add a few missing instructions 2014-10-10 18:30:04 +02:00
Fiora 019657cd93 X64Emitter: add FMA3 support 2014-10-07 18:21:07 -07:00
skidau b3b34d16e6 Merge pull request #1218 from hthh/trampolinecaching
JIT: reuse trampolines when possible
2014-10-07 13:26:23 +11:00
skidau 8fdf43109f Merge pull request #1216 from FioraAeterna/movoptimizations
Add more AVX support, refactor emitter, reduce redundant XMM moves
2014-10-07 13:25:28 +11:00
hthh c7208318fb JIT: Reuse trampolines when possible 2014-10-05 15:03:11 +11:00
Fiora 7a2dd3a3c6 x64Emitter: refactor, add some new AVX instructions 2014-10-03 10:05:10 -07:00
Fiora 85547d94be JIT: properly remove FIFO write addresses when code is invalidated
Fixes a bug caused by interaction with carry optimizations; might fix other
issues too.
2014-09-30 01:00:23 -07:00
comex a9b4016cd3 Merge pull request #1166 from FioraAeterna/flaglocking
JIT+Emitter: support locking flags
2014-09-30 02:57:53 -04:00
comex 2eebdff01b Remove useless STACKALIGN macro.
It only ever did anything on 32-bit OS X.

Anyway, it wasn't even on the right functions, and these days
ABI_PushRegistersAndAdjustStack should handle maintaining the ABI
correctly.
2014-09-30 01:42:47 -04:00
Fiora c102fed36a GekkoDisassembler: show W and I in psq_l/psq_st disassembly 2014-09-28 17:01:35 -07:00
Fiora ac1fc9ad03 JIT+Emitter: support locking flags
This helps us avoid accidentally clobbering flags between two instructions
when the flags are expected to be maintained. Dolphin will of course crash
immediately, but at least it will crash loudly and alert us of the mistake,
instead of forcing hours of bisecting to find the subtle way in which the JIT
has managed to sneak a flag-modifying instruction where there shouldn't be one.
2014-09-26 20:47:06 -07:00
comex fb3d9c9d58 Fix warning in x64CPUDetect.cpp in generic build by not building it. 2014-09-25 18:48:00 -04:00
Rohit Nirmal 3168361e32 Android: Silence some more warnings. 2014-09-22 17:45:42 -04:00
Ryan Houdek 9206dd016e Merge pull request #1135 from FioraAeterna/twidisasmfix
Disassembler: fix disassembly of some twi instructions
2014-09-21 14:19:05 -05:00
Fiora 9c4407fb80 Disassembler: fix disassembly of some twi instructions 2014-09-21 08:17:41 -07:00
Tony Wasserka 6d4fd54683 ChunkFile: Add a DoArray overload which takes an std::array.
This is inconsistent with how other containers are used (i.e. with Do()), but making std::array be used with Do() seems rather confusing when there's also a DoArray available.
2014-09-21 10:38:22 +02:00
Ryan Houdek eb23882398 Merge pull request #1120 from rohit-n/muh-precompiled-headers
Fix build failing when disabling precompiled headers.
2014-09-19 17:43:42 -05:00
Rohit Nirmal 46057db37d Fix build failing when disabling precompiled headers. 2014-09-19 18:17:51 -04:00
Ryan Houdek 522d7eb275 Merge pull request #1109 from FioraAeterna/ps_cmp
JIT: add ps_cmp0/ps_cmp1/ps_res/ps_rsqrte
2014-09-19 14:41:05 -05:00
Fiora 3c49200b22 X64Emitter: add MOVHLPS/MOVLHPS 2014-09-18 17:57:27 -07:00
Ryan Houdek 7608e3f11e Add AArch64 emitter aliases for MOV and MVN. 2014-09-18 16:30:40 -05:00
comex 7ad9027593 Be pedantic about stack overflow on Linux and OS X.
Add some magic to the fault handler to handle stack overflow due to BLR
optimization, and disable the optimization if fastmem is not enabled.
2014-09-17 20:08:09 -04:00
Fiora d3dee1d7ed GekkoDisassembler: fix some float opcodes 2014-09-16 02:06:40 -07:00
skidau 8361d2b1da Merge pull request #805 from FioraAeterna/storerefactor
JIT: support immediate stores
2014-09-16 13:31:39 +10:00
Dolphin Bot bef2016909 Merge pull request #1091 from FioraAeterna/fixdisasm
GekkoDisassembler: fix/improve disassembly for a few instructions
2014-09-16 03:53:18 +02:00
Fiora 7368c2ee9e GekkoDisassembler: fix/improve disassembly for a few instructions 2014-09-15 18:48:54 -07:00
Fiora d02b7c7755 JIT: support immediate stores 2014-09-15 07:25:32 -07:00
Fiora 02dce5dbbf x64Emitter: fix silent failure if WriteNormalOp is passed two memory operands
Should now fail loudly and clearly instead.
2014-09-15 07:08:08 -07:00
Ryan Houdek 4e7f284a81 Merge pull request #1064 from Sonicadvance1/AArch64-Fix-MOVI2R
Fix AArch64 MOVI2R helper function.
2014-09-14 09:26:02 -05:00
Fiora 997c5c2d0e x64Emitter: add LZCNT/TZCNT support and detection
Also add a unit test.
2014-09-14 05:31:22 -07:00
Pierre Bourdon 439068acae Merge pull request #1055 from FioraAeterna/smallermov
X64Emitter: support shorter mov reg, imm opcodes
2014-09-14 01:57:36 +02:00
Lioncash a92003c1ab ARM64: Make getters within ArithOption const. 2014-09-12 20:55:26 -04:00
Ryan Houdek 17d31ecd6c Fix AArch64 MOVI2R helper function.
In the case of a zero immediate, it wouldn't generate code at all.
Also in the case of max u32/u64, use ORN to optimize it.
2014-09-12 05:45:10 -05:00
Ryan Houdek 5061a33c29 Merge pull request #1051 from Sonicadvance1/ARM-Common
Include a missing include in the ARM emitter's common code.
2014-09-11 21:12:21 -05:00
Fiora 18d83a310e X64Emitter: support shorter mov reg, imm opcodes
Also refactor WriteNormalOp a little bit and add comments.
2014-09-11 11:40:30 -07:00
Lioncash b06ec302d1 Remove some unnecessary semicolons 2014-09-11 13:05:31 -04:00
Fiora 5726e0cdfb JIT: use XCHG in MOVTwo
Roughly the same speed or slightly faster depending on CPU; mostly just cleaner
since we don't have to pass in a temp.
2014-09-10 22:17:38 -07:00
Ryan Houdek 44baab30cf Include a missing include in the ARM emitter's common code. 2014-09-10 20:39:19 -05:00
Ryan Houdek 24f6c98a55 Add sign extending aliases to the ARM64Emitter. 2014-09-10 17:52:54 -05:00
Ryan Houdek 71cb09f1ca Merge pull request #1027 from rohit-n/change-include
Include CommonTypes.h instead of Common.h.
2014-09-10 00:35:16 -05:00
Ryan Houdek 09c1ad1631 Merge pull request #753 from FioraAeterna/integeropts
JIT64: various integer optimizations
2014-09-09 04:10:30 -05:00
Ryan Houdek f09cb723c5 Merge pull request #1044 from lioncash/pedantry
Common: Fix code styling in Arm64Emitter
2014-09-08 23:29:19 -05:00
Ryan Houdek af732dea39 Merge pull request #1043 from lioncash/unused
Common: Remove unused variable in MemoryMap_Setup
2014-09-08 22:46:04 -05:00
Lioncash bc331ee809 Common: Fix code styling in Arm64Emitter 2014-09-08 23:39:20 -04:00
Ryan Houdek ed476c997c Fix Generic build from AArch64 merge.
I had missed this file and hadn't tested the branch on my new build system.
2014-09-08 22:24:23 -05:00
Fiora 94c20db369 Rename Log2 and add IsPow2 to MathUtils for future use
Also remove unused pow2/pow2f functions.
2014-09-08 20:15:45 -07:00
skidau 0926f1d344 Merge pull request #897 from Sonicadvance1/AArch64-jit
Initial AArch64 JIT
2014-09-09 12:34:58 +10:00
Lioncash 22800dc711 Common: Remove unused variable in MemoryMap_Setup 2014-09-08 21:44:03 -04:00
Rohit Nirmal fbc64984ca Include CommonTypes.h instead of Common.h. 2014-09-08 15:39:58 -04:00
comex 7fb6628789 Merge pull request #1024 from comex/abi-cleanup
ABI cleanup
2014-09-08 01:03:36 -04:00
comex 4dc090643d Remove ABI_AlignStack/ABI_RestoreStack and the noProlog option to ABI_CallFunctionRR.
The latter being true was the only case where the former would do
anything, and it was never true.  They became obsolete with x86's
removal.
2014-09-08 01:00:10 -04:00
comex c5c0b36046 Remove the inaccurately named ABI_PushAllCalleeSavedRegsAndAdjustStack (it didn't preserve FPRs!) and replace with ABI_PushRegistersAndAdjustStack.
To avoid FPRs being pushed unnecessarily, I checked the uses: DSPEmitter
doesn't use FPRs, and VertexLoader doesn't use anything but RAX, so I
specified the register list accordingly.  The regular JIT, however, does
use FPRs, and as far as I can tell, it was incorrect not to save them in
the outer routine.  Since the dispatcher loop is only exited when
pausing or stopping, this should have no noticeable performance impact.
2014-09-08 01:00:10 -04:00
comex 2dafbfb3ef Improve code and clarify parameters to ABI_Push/PopRegistersAndAdjustStack.
- Factor common work into a helper function.
- Replace confusingly named "noProlog" with "rsp_alignment".  Now that
x86 is not supported, we can just specify it explicitly as 8 for
clarity.
- Add the option to include more frame size, which I'll need later.
- Revert a change by magumagu in March which replaced MOVAPD with MOVUPD
on account of 32-bit Windows, since it's no longer supported.  True,
apparently recent processors don't execute the former any faster if the
pointer is, in fact, aligned, but there's no point using MOVUPD for
something that's guaranteed to be aligned...

(I discovered that GenFrsqrte and GenFres were incorrectly passing false
to noProlog - they were, in fact, functions without prologs, the
original meaning of the parameter - which caused the previous change to
break.  This is now fixed.)
2014-09-08 00:58:56 -04:00
Lioncash a38093729e Common: Inline declare some loop variables in ArmEmitter 2014-09-07 00:26:26 -04:00
Ryan Houdek 2b06257e16 Beginning of the AArch64 JIT branch.
This is the bare minimum required to run a few games on AArch64.
Was able to run starfield and Animal Crossing to the Nintendo logo.
QEmu emulation is literally the slowest thing in the world, it maxes out at around 12mhz on my Core i7-4930MX.
2014-09-06 20:14:52 -05:00
Ryan Houdek f107b5e176 [AArch64-emitter] Initial work on a emitter for 64bit ARM.
I've tested a few instruction encodings and am expecting most to work as long as one stays away from VFP/SIMD.
This implements mostly instructions to bring up an initial JIT with integer support.
This can be improved to allow ease of use functions in the future, dealing with the raw imms/immr encodings is probably the worst thing ever.
2014-09-06 20:13:44 -05:00
shuffle2 9302218a19 Merge pull request #851 from lioncash/logg
Common: Kill off duplicate log warning definitions
2014-09-06 12:35:19 -07:00
Ryan Houdek 01b90c1007 Fix ArmEmitter's asserts from failing to compile.
Changed them all from debug asserts to regular asserts, since they shouldn't only be run at debug time.
2014-09-06 15:11:39 -04:00
Lioncash 690ed8580c Common: Kill off duplicate log warning definitions
Also embed the log checks rather than using macros
2014-09-06 15:11:29 -04:00
shuffle2 85fd8c2bec Merge pull request #983 from lioncash/lol-str
Common: Fix a potential infinite loop in ReplaceAll
2014-09-06 12:00:23 -07:00
shuffle2 1b23432d34 Merge pull request #990 from rohit-n/fix-formatting
Fix formatting
2014-09-06 11:54:17 -07:00
comex 6c382f6627 Merge pull request #926 from comex/ppcstate-reg
PowerPCState register (and rationalize register usage, and add some registers to replace it)
2014-09-06 13:24:38 -04:00
comex 6fd0333c14 Symbolicize explicit uses of x86 registers where possible (GPRs only for now).
Uses are split into three categories:

- Arbitrary (except for size savings) - constants like RSCRATCH are
used.

- ABI (i.e. RAX as return value) - ABI_RETURN is used.

- Fixed by architecture (RCX shifts, RDX/RAX for some instructions) -
explicit register is kept.

In theory this allows the assignments to be modified easily.  I verified
that I was able to run Melee with all the registers changed, although
there may be issues if RSCRATCH[2] and ABI_PARAM{1,2} conflict.
2014-09-06 13:18:31 -04:00
comex 67cdb6e07a Factor code from ABI_CallFunctionRR and GetWriteTrampoline into a helper, and fix a special case.
The special case is where the registers are actually to be swapped (i.e.
func(ABI_PARAM2, ABI_PARAM1); this was previously impossible but would
be ugly not to handle anyway.
2014-09-06 13:16:20 -04:00
Lioncash 1d66b1d3f4 Common: Remove HAVE_CXX11_SYNTAX define from Common.h
All the compilers we support have C++11 support now, so this isn't needed.
2014-09-06 11:32:19 -04:00
Rohit Nirmal 629ceaf2b1 Split some parts of UpdateBoundingBox into multiple lines. Also,
fix issues causing failure on Lint.
2014-09-06 09:49:27 -05:00
Rohit Nirmal 1ecb318bcc Fix some formatting (new lines on collapsed single-line conditionals,
new lines for opening braces).
2014-09-06 01:23:05 -05:00
lioncash 3e0c04a83e Common: Fix a potential infinite loop in ReplaceAll
Prior to this change, it was possible to cause an infinite loop by making the string to be replaced and the replacing string the same thing.

e.g.

std::string some_str = "test";
ReplaceAll(some_str, "test", "test");

This also changes the replacing in a way that doesn't require starting from the beginning of the string on each replacement iteration.
2014-09-05 15:12:17 -04:00
Fiora 07e0c917c6 Revert "JIT64: optimize CA calculations" 2014-09-05 10:26:30 -07:00
comex 97420c6ec6 Merge pull request #852 from FioraAeterna/optimizeca
JIT64: optimize CA calculations
2014-09-05 11:52:02 -04:00
comex aa1df21bb6 Merge pull request #947 from FioraAeterna/rsqrte
JIT: implement frsqte
2014-09-05 11:48:00 -04:00
Lioncash 6369173981 DolphinWX: Simplify wiki link construction 2014-09-04 21:30:33 -04:00
lioncash bd91e8b0c8 Common: Remove unused header from Thread.cpp
This define isn't even used in the Windows builds.
2014-09-04 09:15:18 -04:00
Rachel Bryk 345b608d64 Change IniFile::Section::Set() with default value to use a template. 2014-09-04 03:29:49 -04:00
shuffle2 4fcb633df5 Merge pull request #961 from RachelBryk/logs
Read the config file before enabling logs.
2014-09-03 17:20:11 -07:00
Rachel Bryk 22d2c7d053 Read the config file before enabling logs. 2014-09-03 19:50:02 -04:00
shuffle2 05cd06539b Merge pull request #960 from lioncash/preproc-stuff
Common: Make TITLEID_SYSMENU a static const variable in NandPaths.h
2014-09-03 15:22:32 -07:00
lioncash a687cc556b Common: Make TITLEID_SYSMENU a static const variable in NandPaths.h 2014-09-03 18:03:23 -04:00
Fiora 1b50f9df14 JIT: implement fres
Mostly a straightforward translation of the interpreter code, with a few
tricksy optimizations and fallbacks for rare paths.
2014-09-03 12:15:30 -07:00
Fiora c72a133206 JIT: implement frsqrte
Mostly a straightforward translation of the interpreter code, with a few
tricksy optimizations and fallbacks for rare paths.
2014-09-03 11:21:04 -07:00
Dolphin Bot e1248599eb Merge pull request #868 from FioraAeterna/bmi
x64Emitter: add BMI1/BMI2 support
2014-09-03 19:24:27 +02:00
lioncash f69e6ef16f Common: Remove unnecessary define check in Log2 2014-09-03 13:04:48 -04:00
Fiora 5088a2b4e2 x64Emitter: add BMI1/BMI2 support
TZCNT and LZCNT use a completely different encoding scheme, so they should
probably go in a separate patch.

Also add some tests.
2014-09-03 10:04:01 -07:00
shuffle2 db84a22109 Merge pull request #770 from lioncash/panic
Core: Fix case where a panic alert wouldn't be shown in MemoryUtil.cpp
2014-09-03 00:10:12 -07:00
comex 64575d565a Merge pull request #923 from FioraAeterna/fixcallersave
JIT: Fix caller-save registers on WIN64
2014-09-03 02:27:44 -04:00
shuffle2 532b7bb7da Merge pull request #893 from rohitnirmal/scan-build-fixes
Scan build fixes
2014-09-02 23:15:18 -07:00
Fiora 9e4419e786 x64Emitter: add support for shorter EAX forms of instructions
Should save a few bytes of code size here and there.
2014-09-02 21:52:41 -07:00
Fiora 6655c7775e JIT: Fix callee-save registers on WIN64 2014-09-02 10:56:14 -07:00
Pierre Bourdon e72146d19c x64Emitter: Do not assert-fail on redundant MOVs, instead show an error log 2014-09-02 10:17:32 +02:00
Pierre Bourdon a79ced2fc2 x64Emitter: Make it clear for both SSE to int conv that X64 regs are expected 2014-09-02 09:55:47 +02:00
Pierre Bourdon c428c5999f x64Emitter: UNPCKLPS/HPS are now tested 2014-09-02 09:53:00 +02:00
Pierre Bourdon cc0b048c0b x64Emitter: Support FLD/FSTP with 80 bits operands 2014-09-02 09:52:59 +02:00
Pierre Bourdon f99f302c91 x64Emitter: assert instead of crashing when generating MOVZX with a wrong size 2014-09-02 09:52:04 +02:00
Pierre Bourdon b1738b60fc x64Emitter: Fix MUL with AH/BH/CH/DH registers. 2014-09-02 09:52:04 +02:00
Pierre Bourdon f0e8b1fda8 x64Emitter: Error out on 8 bits CMOV, and emit 16 bits CMOV properly 2014-09-02 09:52:04 +02:00
Pierre Bourdon d4ec9737bd x64Emitter: Assert when using an invalid POP instead of generating an INT3 2014-09-02 09:52:04 +02:00
Pierre Bourdon 9c4daac3a4 x64Emitter: RDTSC now without a typo'd name 2014-09-02 09:52:04 +02:00
Pierre Bourdon 88af225070 x64Emitter: Remove a declared function that is never implemented 2014-09-02 09:52:04 +02:00
Pierre Bourdon 5941653d47 Merge pull request #920 from shuffle2/msvc-gtest
Provide a way to build and run unittests on Windows
2014-09-02 07:40:49 +02:00
Pierre Bourdon 9b10d36a85 Merge pull request #938 from lioncash/statics
Common: Make the LUTs in ColorUtil static
2014-09-02 07:36:17 +02:00
Lioncash 824a0a19f1 Common: Make the LUTs in ColorUtil static 2014-09-02 00:52:13 -04:00
Shawn Hoffman 839cace5ff msvc: get UnitTests compiling
Choose it from VS or pass /p:RunUnitTests=true to msbuild
2014-09-01 21:27:45 -07:00
Shawn Hoffman 266992684d msvc: remove some remnants of SDL and DSound from projects and general cleanup. 2014-09-01 21:27:44 -07:00
Fiora b51aa4fa89 Rename Log2 and add IsPow2 to MathUtils for future use
Also remove unused pow2/pow2f functions.
2014-09-01 20:41:07 -07:00
Lioncash ec9fc6bfc1 Common: Remove unnecessary "using namespace Gen;" from x64emitter 2014-09-01 23:10:56 -04:00
Lioncash ba4934b75e Common: Clean up brace placements 2014-08-30 18:06:35 -04:00
Lioncash 1d706b2311 Get rid of C-style empty function parameter indicators 2014-08-30 15:23:48 -04:00
comex 683191b6c6 Merge pull request #892 from comex/oh-the-abstraction
Optimize PointerWrap.
2014-08-28 17:28:16 -04:00
comex faa2666393 PointerWrap currently checks its mode for every individual byte of everything it 'does', including all of RAM. Make it not do that.
Decreases total Wii state save time (not counting compression) from
~570ms to ~18ms.

The compiler can't remove this check because of potential aliasing; this
might be fixable (e.g. by making mode const), but there is no reason to
have the code work in such a braindead way in the first place.

- DoVoid now uses memcpy.
- DoArray now uses DoVoid on the whole rather than Doing each element
(would fail for an array of STL structures, but we don't have any of
those).
- Do also now uses DoVoid.  (In the previous version, it replicated
DoVoid's code in order to ensure each type gets its own implementation,
which for small types then becomes a simple load/store in any modern
compiler.  Now DoVoid is __forceinline, which addresses that issue and
shouldn't make a big difference otherwise - perhaps a few extra copies
of the code inlined into DoArray or whatever.)
2014-08-28 15:35:19 -04:00
Fiora f9d4ff0d5d x64Emitter: add support for some missing CVT instructions 2014-08-27 20:15:42 -07:00
Rohit Nirmal 4c14ebdf32 Remove pointless initializations. 2014-08-27 20:36:49 -05:00
comex de7294ecc1 Add Flag support to ChunkFile.h 2014-08-26 12:43:39 -04:00
comex d128795594 Merge pull request #862 from comex/registersinuse
Reduce my idiocy in register saving code.
2014-08-24 16:16:32 -04:00
Dolphin Bot f31ebd23bb Merge pull request #864 from FioraAeterna/avx2bmi
Add AVX2/BMI1/BMI2 detection support
2014-08-24 18:55:01 +02:00
Fiora ce6d09ca5d Add AVX2/BMI1/BMI2 detection support
Also clean up the formatting in a bit of the CPU detection code.
2014-08-24 09:14:54 -07:00
comex d19ec35363 Reduce my idiocy in register saving code.
(1) Rename ABI_ALL_CALLEE_SAVED to ABI_ALL_CALLER_SAVED, because that's
what it was actually defined as (and used as).  Derp.

(2) RegistersInUse is always used for the purpose of saving registers
before calling a C++ function in the middle of a JIT block (without
flushing).  There is no need to save callee-saved registers in this
case.  Change the name to CallerSavedRegistersInUse and mask with
ABI_ALL_CALLER_SAVED.

Nothing obvious broke when starting up a Melee game.  (I added a test
for anything actually being masked out; it happens, but in this
particular case seemed to occur at most a few dozen times per second, so
the actual performance benefit is probably negligible.)
2014-08-23 15:46:10 -04:00
Shawn Hoffman 327d35377d windows: remove now-extraneous NOMINMAX and WIN32_LEAN_AND_MEAN #defines from dolphin code.
Wrap dinput.h in a header defining DIRECTINPUT_VERSION instead of repeating it multiple places.
2014-08-23 10:48:48 -07:00
Tillmann Karras 80be585fef x64Emitter: remove redundant "Gen::" 2014-08-20 02:56:07 +02:00
Tillmann Karras a363f4fa3e x64Emitter: make 'packed' parameter a bool 2014-08-20 02:54:30 +02:00
Shawn Hoffman 87c324c55a Add Common::Event::WaitFor(), which has the same semantics as std::condition_variable::wait_for() (with millisecond units). 2014-08-17 21:52:40 -07:00
Shawn Hoffman 375be67158 Add Common/Event.h to the VS project files. 2014-08-17 21:52:40 -07:00
Fiora 802b28daf9 x64Emitter: refactor to support longer opcodes
Also add some new SSE4 opcodes.
2014-08-17 04:48:17 -07:00
Lioncash 4759510f70 Get rid of instances of "using namespace std;" in the project 2014-08-17 02:05:33 -04:00
Lioncash 6ee2267b2d Merge pull request #771 from lioncash/32bit-cruft
Core: Remove leftover Windows 32-bit functions in MemArena.cpp
2014-08-17 01:40:23 -04:00
Lioncash 1b92c68f05 Common: Add Flag.h to the Visual Studio project. 2014-08-16 23:33:28 -04:00
Lioncash d18d3e1f3e Common: Get rid of StdConditionVariable, StdMutex, and StdThread.
All of the compilers we support have support for these now.
2014-08-16 23:33:19 -04:00
shuffle2 2270c3e90a Merge pull request #797 from shuffle2/msvc-pch
Windows: Use a shared precompiled header for dolphin code under Source/
2014-08-16 14:58:28 -07:00
Lioncash cf46ac7dc9 Core: Kill off Host_ShowJitResults
Another host function that can be killed off by simple wx event handling
2014-08-15 15:18:28 -04:00
Shawn Hoffman f1b82a34b2 Windows: Use a shared precompiled header for dolphin code under Source/ 2014-08-14 23:51:13 -07:00
Shawn Hoffman 66fdbdd18d Windows: Give SCMRevGen a configuration for x64 instead of Win32. 2014-08-13 03:57:10 -07:00
Ryan Houdek 6bdc32c54a Add the VideoCommon PostProcessing class.
This class loads all the common PP shader configuration options and passes those options through to a inherited class that OpenGL or D3D will have.
Makes it so all the common code for PP shaders is in VideoCommon instead of duplicating the code across each backend.
2014-08-13 01:05:10 -05:00
Ryan Houdek 3a657fe33c Add TryParseVector to StringUtil.
Adds a nice way to have options be in a vector for results
2014-08-12 23:45:14 -05:00
shuffle2 43010818fa Merge pull request #785 from lioncash/string
Common: Fix AsciiToHex returning true on overflow values
2014-08-12 14:43:02 -07:00
shuffle2 9f4008c5bc Merge pull request #760 from lioncash/swap
Common: Use the OSX equivalent byte-swap functions
2014-08-12 14:31:32 -07:00
shuffle2 b8d126c101 Merge pull request #754 from FioraAeterna/immediateopt
x64Emitter: optimize immediate sizes
2014-08-12 14:19:31 -07:00
Lioncash 5afb9cc5c4 Common: Fix AsciiToHex returning true on overflow values
We should be checking errno against ERANGE.
2014-08-12 02:49:04 -04:00
shuffle2 36af1b518d Merge pull request #777 from shuffle2/vs2013-update3
Use official flag for detailed symbols. Require VS2013 with update 3 or later to build.
2014-08-11 20:12:52 -07:00
Shawn Hoffman d0c3e46c80 Windows: Improve XSaveWorkaround to behave correctly when XSAVE processor feature is enabled, but AVX support isn't available for whatever reason. 2014-08-10 14:50:29 -07:00
Shawn Hoffman 5eccc08c7e Use official flag for detailed symbols. Require VS2013 with update 3 or later to build. 2014-08-10 14:47:29 -07:00
Lioncash eb10899b53 Core: Remove leftover Windows 32-bit functions in MemArena.cpp 2014-08-10 05:35:14 -04:00
Lioncash 9a61cfc650 Core: Actually show MemoryUtil.cpp allocation error messages on Linux 2014-08-10 05:28:00 -04:00
Lioncash be3428cf8e Core: Fix case where a panic alert wouldn't be shown in MemoryUtil.cpp 2014-08-10 04:50:58 -04:00
Lioncash 7bf82f1989 Core: Kill off Host_UpdateLogDisplay()
This was actually never used as far as I can tell. There was no wx event handling done whatsoever for the global ID, So this is basically a dead function.
2014-08-08 19:21:40 -04:00
lioncash 85ace9751e Common: Use the OSX equivalent byte-swap functions 2014-08-08 13:26:26 -04:00
Fiora 75b3e425fd x64Emitter: optimize immediate sizes
A nice alternative than trying to do it throughout the JIT.
2014-08-07 13:07:27 -04:00
Lioncash 0718937237 Common: Introduce the new Gekko disassembler to Common.
This moves the Gekko disassembler to Common where it should be. Having it in the Bochs disassembly Externals is incorrect.

Unlike the PowerPC disassembler prior however, this one is updated to have an API that is more fitting for C++. e.g. Not needing to specify a string buffer and size. It does all of this under the hood.

This modifies all the DebuggingInterfaces as necessary to handle this.
2014-08-04 00:45:07 -04:00
Pierre Bourdon 4c42b38de1 Merge pull request #428 from Sonicadvance1/x86_32-removal
Remove x86_32 support from Dolphin.
2014-08-03 21:17:28 -07:00
Ryan Houdek 0c24e1dcf2 Remove the rest of x86_32 support from Common. 2014-08-03 13:49:46 -05:00
Pierre Bourdon 8b26d7bf1e UnitTests: make it possible to build tests for code that has global dependencies 2014-08-02 09:34:39 -07:00
Lioncash 77c2b6829a Merge pull request #702 from lioncash/netplay-version
Common: State OS instead of 32/64 bit in the netplay lobby
2014-08-01 22:51:30 -04:00
Lioncash 4b32dcbc33 Merge pull request #707 from lioncash/strip
Common: Simplify StripTailDirSlashes
2014-08-01 16:01:37 -04:00
Lioncash 1dc5294629 Common: Simplify StripTailDirSlashes 2014-07-31 22:18:45 -04:00
Lioncash c5188c76b3 Merge pull request #705 from Sonicadvance1/fix-memoryutil-check
Fixes a check for what mmap returns.
2014-07-31 03:06:00 -04:00
Ryan Houdek 33450c80c3 Fixes a check for what mmap returns.
On error mmap returns MAP_FAILED(-1) not null.
FreeBSD was checking the return correctly, Linux was not.
This was noticed by triad attempting to run Dolphin under valgrind and not getting a memory space under the 2GB limit(Because -1 wraps around on
unsigned obviously)
2014-07-31 00:53:00 -05:00
Pierre Bourdon 9b9817f927 x64Emitter: Fix REX encoding for SETcc
Previously using the new "lower 8 bits" registers (SIL, SPL, ...) caused SETcc
to write to other registers (for example, SETcc SIL would generate SETcc DH).
2014-07-30 06:41:29 -07:00
Lioncash 22e9d6977b Common: State OS instead of 32/64 bit in the netplay lobby 2014-07-30 02:04:17 -04:00
Lioncash b03c12764d Really get rid of the MSVC 2005 workaround completely 2014-07-29 21:20:43 -04:00
Lioncash 4fa71dd59e Remove fakepoll.h.
It was only used for Windows XP and lower.

This also bumps the _WIN32_WINNT define in the stdafx precompiled headers to set the minimum version as Windows Vista.
2014-07-26 22:53:40 -04:00
Shawn Hoffman cfc7bb35c2 Windows: Also look for git.exe in the registry (for Git Extensions installs). 2014-07-20 12:33:56 -07:00
Tillmann Karras 6df48ed432 x64Emitter: add CVTTPD2DQ 2014-07-15 23:53:56 +02:00
Lioncash 79eb0f8d0c Merge pull request #623 from phire/sw-xfb-clamping
Fix incorrect clamping in SWRenderer.
2014-07-15 12:04:06 -04:00
Scott Mansell b8695a57da Fix incorrect clamping in SWRenderer.
A previous PR changed a whole lot of min/maxes to std::min/std::max
but made a mistake here and used a templated min which cast it's
arguments to unsigned instead of casting return value.

This resulted in glitchy artifacts in bright areas (See issue 7439)

I rewrote the code to use a proper clamping function so it's cleaner
to read.
2014-07-15 21:15:49 +12:00
Lioncash 8087a89afd Remove some unnecessary defines in Log.h 2014-07-14 15:51:28 -04:00
Tillmann Karras d398e9ef61 Common: add macros for assisting branch prediction 2014-07-14 01:52:14 +02:00
Tillmann Karras 0ccee6c87b Fix warnings unearthed by #579 2014-07-13 02:16:51 +02:00
degasus 7e79806efc remove unused globals
Also change globals into statics which are only used in one file
2014-07-11 16:10:20 +02:00
degasus 81ed17be53 avoid the extern keyword in .cpp files 2014-07-11 16:10:20 +02:00
degasus 22e1aa5bb4 mark all local functions as static 2014-07-11 16:07:23 +02:00
Lioncash 09eb1acc5e Common: Using size_t in PointerWrap's DoContainer apparently causes crashes. Fixes this. 2014-07-06 03:05:27 -04:00
Lioncash b97d2853a7 Common: Make DoContainer within PointerWrap private.
This shouldn't really be exposed as a public function and should only be called through other Do class functions that take a container type as a parameter.
2014-07-05 23:03:43 -04:00
Lioncash bd377b9580 Merge pull request #443 from magumagu/loadstore-cleanup
Loadstore cleanup
2014-06-26 21:32:59 -04:00
Lioncash ca5340ebde Centralize the logging code into its own folder in Common. 2014-06-25 22:11:42 -04:00
Lioncash 177658aed6 Merge pull request #513 from lioncash/vs-x64
Remove the 32-bit config platform from the VS solution file
2014-06-25 21:23:45 -04:00
Lioncash 8b13afbb8e Remove the 32-bit config platform from the VS solution and projects 2014-06-24 22:07:26 -04:00
Lioncash eb3de73ab9 Merge pull request #531 from LPFaint99/memcard
GCI Folder: correctly identify region of sysmenu
2014-06-24 21:18:27 -04:00
Jordan Woyak 516369594f Store ini sections in a std::list (rather than vector) to prevent unexpected pointer invalidation with use of GetOrCreateSection. 2014-06-24 12:37:38 -05:00
LPFaint99 c65a6f5fb0 GCI Folder: correctly identify region of sysmenu 2014-06-23 19:58:27 -07:00
Pierre Bourdon ce74752e91 Common: Add a PCAP writer module 2014-06-22 20:04:46 +02:00
Pierre Bourdon 5dff577339 Merge pull request #500 from lioncash/ini
Use only section-based ini reading.
2014-06-22 17:21:45 +02:00
magumagu 06864e9fee JIT: Clean up float loads and stores.
Less code is good, and this should make future changes to memory handling
easier.
2014-06-20 12:52:39 -07:00
Lioncash f05d3f6e5d Use only section-based ini reading. 2014-06-16 01:31:23 -04:00
magumagu ee0c5bdc20 Try to fix android build. 2014-06-15 15:56:42 -07:00
magumagu d905cbfd5d Don't set DAZ on x86 in non-IEEE mode.
I have no idea why we were using it in the first place; it doesn't match
the behavior of PPC NI flag.
2014-06-15 03:51:51 -07:00
Tony Wasserka 3d6f9ef897 BitField: Add an explicit getter function for retrieving the BitField value.
Sometimes (in particular when using non-typesafe functions) it can be convenient to have a getter method rather than performing a potentially lengthy explicit cast.
2014-06-11 20:58:40 +02:00
Tony Wasserka b3c7f003da BitField: Delete copy assignment to prevent obscure bugs. 2014-06-11 20:58:40 +02:00
Ryan Houdek 6e1d312091 Make it so ARMv7 isn't a generic target.
Rearranges a bit of code so that ARM isn't a generic build anymore. Because it obviously isn't
2014-06-07 20:26:31 -05:00
Ryan Houdek b6db0d0ab8 Merge pull request #457 from Tilka/jcc
x64Emitter: J_CC: use 32 bit offset automatically
2014-06-06 20:53:50 -05:00
Lioncash 3843848ed4 Use std::string in LogContainer's constructor.
This allows for removal of the strcpy calls, also it's technically way more safe, though I doubt we'll ever have a log name larger than 128 characters or a short description larger than 32 characters.

Also moved these assignments into the constructor's initializer list.
2014-06-05 18:50:14 -04:00
Tillmann Karras f8280401f6 x64Emitter: J_CC: use 32 bit offset automatically 2014-06-03 23:08:58 +02:00
Ryan Houdek 3a06907653 Merge pull request #455 from lioncash/arm-cpudetect-fix
Stringify ArmCPUDetect.cpp.
2014-06-02 20:10:39 -05:00
Lioncash 7d7b3d6156 Stringify ArmCPUDetect.cpp. 2014-06-02 21:08:26 -04:00
Ryan Houdek 5d3382fb56 Fix a crash in ARM's CPUDetect on a malformed /proc/cpuinfo.
If a CPU string was incapable of being found we would return a null pointer, which would crash with strncpy.
Also if we couldn't get a CPU implementer we would call free() to a null pointer.
In addition, detect 64bit ARM running.
2014-06-01 23:55:38 -05:00
Ryan Houdek 87e671404a Make MemoryUtil.cpp use the correct x86_64 define.
MemoryUtil.cpp was incorrectly using the old __x86_64__ define when it should be using _M_X86_64.
It was also using _ARCH_64 when it shouldn't have which was causing an errant PanicAlert to come up in my development.
2014-06-01 23:45:44 -05:00
Lioncash 49b0eef393 Remove the min/max functions in CommonFuncs.
The algorithm header has the same functions.
2014-05-29 21:44:41 -04:00
Lioncash eca70d1562 Get rid of the temporary buffer in IniFile's Load function.
std::getline is the string-based equivalent.
2014-05-28 20:26:15 -04:00
Rachel Bryk 80ab567a5b When reading an ini file, if there is an error, check if it is simply because the eof was reached. 2014-05-28 14:06:18 -04:00
Pierre Bourdon 10efd5b8c0 Merge pull request #430 from shuffle2/xsave-workaround-fix
msvc C initializers return int...fix EnableXSaveWorkaround when rax doesn't implicitly equal zero.
2014-05-28 12:25:25 +02:00
Pierre Bourdon ce139622f6 Merge pull request #392 from RachelBryk/error-check-ini-file
Check for errors when reading lines from ini files.
2014-05-28 11:57:00 +02:00
Shawn Hoffman 47a2eb47a0 msvc C initializers return int...fix EnableXSaveWorkaround when rax doesn't implicitly equal zero. 2014-05-28 00:16:33 -07:00
Shawn Hoffman 58bcc3d12a Redo commit 932945d480
This time, make sure the object for disabling XSave support in msvcr can't be dropped by the linker.
2014-05-27 13:41:19 -07:00
Rachel Bryk 0782d106db Check for errors when reading lines from ini files.
Fixes issue 7283.
2014-05-23 03:17:19 -04:00
Lioncash 5f796e919b Move bn.h and ec.h into the correct filter section 2014-05-17 16:47:41 -04:00
Lioncash d0bd4119d1 Use size_t in std::string operations in IniFile.cpp, not int 2014-05-14 20:38:08 -04:00
shuffle2 36720e6822 Merge pull request #351 from Tilka/make_unique
Add a std::make_unique implementation (Common/StdMakeUnique.h)
2014-05-11 01:46:09 -07:00
Tillmann Karras 4400e511c0 fixmeup rename 2014-05-11 10:40:18 +02:00
Shawn Hoffman 700c135386 Revert "x64FPURoundMode: always set x87 precision"
This reverts commit 9de77b7c23.
Setting x87 precision control is only supported on x86 platforms (not ARM or x64).
2014-05-10 20:21:07 -07:00
Tillmann Karras 81d4d7368a Add a std::make_unique implementation
Some compilers we care about (mostly g++) do not support std::make_unique yet,
but we still want to use it in our codebase to make unique_ptr code more
readable. This commit introduces an implementation derivated from the libc++
code in the Dolphin codebase so we can use it right now everywhere.

Adapted from delroth's pull request.
2014-05-06 12:32:03 +02:00
Tillmann Karras 9de77b7c23 x64FPURoundMode: always set x87 precision
Set the x87 precision, even on x64. Since we are using x87 instructions
in the JIT now, we can't guarantee that x87 precision will never
influence Dolphin on x64.
2014-05-01 01:10:00 +02:00
Tillmann Karras ed762a3eda x64FPURoundMode: use fesetround() instead of asm 2014-05-01 01:09:55 +02:00
Tillmann Karras e659f5ac58 JitBackpatch: fix NOP padding
The new NOP emitter breaks when called with a negative count. As it
turns out, it did happen when deoptimizing 8 bit MOVs because they are
only 4 bytes long and need no BSWAP.
2014-04-30 15:26:11 +02:00
Pierre Bourdon aef24d509b Merge pull request #304 from Tilka/nop
Optimize NOPs
2014-04-27 11:52:05 +02:00
Tillmann Karras 886c887e80 Fix Fastmem on CPUs without MOVBE
The problem was that when BSWAP was used, UnsafeWriteRegToReg() returned
the address of that instead of the MOV.
2014-04-25 01:11:52 +02:00
Tillmann Karras acfd9ee76c Add remaining possible uses of MOVBE
Also fixes a missing 'break' statement in DisassembleMov().
2014-04-24 16:36:03 +02:00
Tillmann Karras 957649b7af Optimize NOPs 2014-04-23 21:15:09 +02:00
Tillmann Karras b3c7395a23 Atomic: support clang 3.4+ 2014-04-17 10:39:02 +02:00
Pierre Bourdon cf315a487f Merge pull request #271 from delroth/threading-stuff
Threading improvements: add Common::Flag and improve Common::Event
2014-04-14 23:23:16 +02:00
Pierre Bourdon 7074feacbe Common::Event: Add a faster Windows specific implementation based on the concurrency runtime. 2014-04-14 23:13:15 +02:00
Pierre Bourdon 48bd904028 Common::Event: Implement in terms of Common::Flag to get rid of a volatile and optimize with early returns and atomic swaps 2014-04-14 23:13:15 +02:00
Pierre Bourdon e24cad0780 Common::Flag: Add support for TestAndSet + test by implementing basic spinlocks. 2014-04-14 23:13:15 +02:00
Tony Wasserka ccc04944b2 BitField: Fix alignment issues.
At least one platform (ARM with NEON instructions enabled) generates SIGBUSes if BitField objects aren't aligned properly.
2014-04-14 20:04:44 +02:00
Pierre Bourdon 6bdcbad3e4 Common: Move the Event class to a separate file, and add tests for it. Fix includes everywhere to match this. 2014-04-14 10:54:07 +02:00
Pierre Bourdon f9fb39d383 Common: Add a 'Flag' class that is used to encapsulate a boolean flag manipulated from several threads 2014-04-14 10:54:07 +02:00
Tony Wasserka 12841928df BitField: Optimize generated assembly by forcing inlining. 2014-04-13 13:27:01 +02:00
Pierre Bourdon b2597739ff x64Emitter: Add the MOVBE instruction. 2014-04-11 23:33:21 +02:00
Pierre Bourdon d2de1ddabc CPUDetect: add support for MOVBE detection 2014-04-11 23:29:03 +02:00
Ryan Houdek 87d106d65c Remove dumb CodeBlock duplication in the emitters.
Fixes issue 6990.
This uses a bit of templating to remove the duplicate code that is the CodeBlocks in each emitter headers.
No actual functionality change in this.
2014-04-09 13:53:43 -05:00
Ryan Houdek 93c871522f Fix a bug in the ARMEmitter.
When creating a Fixupbranch we were swapping the BL and B targets.
I think this was found by PPSSPP a while ago, but they never send PRs to merge their changes upstream.
2014-04-06 10:28:41 -04:00
Pierre Bourdon 664c8d30a0 Remove all trailing whitespaces from our codebase. 2014-03-29 11:05:44 +01:00
comex 4d5df0d008 Fix IsTriviallyCopyable for volatile (fixes Mac build).
Between C++11 and C++14, volatile types stopped being trivially
copyable.  The serializer has no reason to care about this distinction,
so tack on remove_volatile.
2014-03-27 23:42:52 -04:00
magumagu 4eab240e25 Compute stack usage correctly in ABI_CallFunctionPC.
(The numbers need to be consistent with the actual usage, or else the stack gets corrupted.)
2014-03-25 20:48:25 -07:00
magumagu e4081b29f9 Use unaligned stores to save XMM regs to stack.
On Win32, the stack isn't aligned, so aligned stores will cause crashes.
2014-03-25 20:46:36 -07:00
Pierre Bourdon 5fc6ce59c3 Merge pull request #210 from magumagu/writerex-fix
Fix OpArg::WriteRex with 8-bit memory operand.
2014-03-26 02:34:44 +01:00
Tony Wasserka 48a1790d81 Common: Add a generic class for accessing bitfields in a fast and endianness-independent way.
The underlying storage type of a bitfield can be any intrinsic integer type,
but also any enumeration.

Custom storage types are supported if the following things are defined on the storage type:
- casting 0 to the storage type
- bit shift operators (in both directions)
- bitwise & operator
- bitwise ~ operator
- std::make_unsigned specialization
2014-03-25 23:33:04 +01:00
magumagu 03292eabc2 Fix OpArg::WriteRex with 8-bit memory operand.
Previously he function was misbehaving because of a missing check for
whether an 8-bit operand was a register operand; it would therefore
emit unnecessary REX prefixes, incorrectly assert on 32-bit targets, and
could potentially emit wrong code in rare cases (like a memory to register
operation involving AH.)

Also, some cleanup while I was in the area to make the function easier to
read.
2014-03-25 14:09:15 -07:00
Tillmann Karras af525266d4 MathUtil: add constructors to IntFloat/IntDouble 2014-03-24 16:14:22 +01:00
Ryan Houdek 3586ab1d4c Fix the Android build when using clang 3.4 2014-03-17 17:56:22 -05:00
Tillmann Karras fa3cc05753 Turn some non-const refs into pointers 2014-03-17 02:55:57 +01:00
Lioncash a82675b7d5 Kill off some usages of c_str.
Also changes some function params, but this is ok.
Some simplifications were also able to be made (ie. killing off strcmps with ==, etc).
2014-03-14 13:51:23 -04:00
Matthew Parlane 31cfc73a09 Fixes spacing for "for", "while", "switch" and "if"
Also moved && and || to ends of lines instead of start.
Fixed misc vertical alignments and some { needed newlining.
2014-03-11 00:35:07 +13:00
Tillmann Karras d802d39281 clang-modernize -use-nullptr
and s/\bNULL\b/nullptr/g for *.cpp/h/mm files not compiled on my machine
2014-03-09 21:14:26 +01:00
Tillmann Karras f28116b7da clang-modernize -add-override 2014-03-09 21:12:01 +01:00
Tillmann Karras c89f04a7c5 clang-modernize -loop-convert
and some manual adjustments
2014-03-09 21:11:59 +01:00
Tillmann Karras 9ef64245fa MathUtil: fix IsQNAN()
The constants were one nibble too short and the lower 51 bits don't
actually have to be zero.
2014-03-09 19:34:58 +01:00
Tillmann Karras d05e205a24 FPURoundMode: revert use of enums in bit-fields
The workaround of using fixed underlying types produces lots of warnings
in GCC because now the bit-fields are too small for the value range used
for conversion semantics.
2014-03-09 15:24:35 +01:00
Pierre Bourdon edba8096bf x64Emitter: Add functions to call a C++ std::function from JITed code 2014-03-08 23:32:43 +01:00
Pierre Bourdon 9869c53859 x64ABI: Add two more CallFunction functions (for additional parameter types). 2014-03-08 23:32:43 +01:00
Pierre Bourdon 6d6abfa61f x64Emitter: Allow const pointers where it makes sense to do so. 2014-03-08 23:32:43 +01:00
Pierre Bourdon 248f5d7f22 Merge pull request #130 from lioncash/breakpoint-clear
Actually make PPCDebugInterface::ClearAllBreakpoints have functionality.
2014-03-07 20:42:52 +01:00
Matthew Parlane 57f2eda130 Fix MAC address reading on Windows. 2014-03-07 21:40:59 +13:00
Shawn Hoffman 932945d480 Implement workaround for Windows versions which do not support XSAVE.
Fixes CRT math routines using FMA instructions from causing illegal instructions.
2014-03-06 14:38:10 -08:00
Shawn Hoffman 8995d299f2 windows: move arch defines to base.props 2014-03-06 14:37:40 -08:00
Lioncash 610a6f9b23 Add ClearAllMemChecks to DebugInterface
Breakpoints have one, but memchecks don't, despite being cleared directly in the breakpoint window.

Now DolphinWX should call the interface functions and not the direct functions of the breakpoints or memchecks for clearing.
2014-03-05 21:50:23 -05:00
Shawn Hoffman 3647dfa711 Allow VS builds to be speedy again. 2014-03-05 11:17:14 -08:00
Shawn Hoffman 7733463e65 commit 1a428de189 introduced a bug by using a signed enum in a bitfield, the value of which is then used in a ldmxcsr instruction. The sign-extension corrupts the value, causing an exception by attempting to load mxcsr with an invalid value. 2014-03-05 10:19:29 -08:00
Ryan Houdek 4f02132f93 Make our architecture defines less stupid.
Our defines were never clear between what meant 64bit or x86_64
This makes a clear cut between bitness and architecture.
This commit also has the side effect of bringing up aarch64 compiling support.
2014-03-04 09:36:59 -06:00
Lioncash 279a8c0148 Change the DebugInterface, PPCDebugInterface, and DSPDebugInterface to use CamelCase names.
This is the standard coding convention in the codebase, so our interfaces should use it too.
2014-03-03 00:39:08 -05:00
Tillmann Karras 7a66a3ded1 ArmEmitter: make it more readable 2014-02-28 12:43:22 +01:00
Tillmann Karras 46e7c0657f Crypto: small cleanup 2014-02-28 12:43:22 +01:00
Tillmann Karras 315a8ba1c0 Various changes suggested by cppcheck
- remove unused variables
- reduce the scope where it makes sense
- correct limits (did you know that strcat()'s last parameter does not
  include the \0 that is always added?)
- set some free()'d pointers to NULL
2014-02-28 12:43:20 +01:00
Tillmann Karras 5f0a8008f4 Convert MemoryUtil.cpp to Unix-style line endings 2014-02-28 12:28:21 +01:00
Tillmann Karras 1a428de189 x64FPURoundMode: move things around a bit 2014-02-28 12:28:21 +01:00
degasus 94da4e1aa2 MathUtil: Change Log2 return value to int
Log2(u64) can't be bigger than 63, so there is no need in forcing a 64 bit value.
So just using a common int seems more natural.
2014-02-26 11:37:28 +01:00
Pierre Bourdon 70f3a069f2 Revert "Merge pull request #83 from lioncash/remove-console"
This breaks Linux stdout logging.

This reverts commit 7ac5b1f2f8, reversing
changes made to 9bc14012fc.

Revert "Merge pull request #77 from lioncash/remove-console"

This reverts commit 9bc14012fc, reversing
changes made to b18a33377d.

Conflicts:
	Source/Core/Common/LogManager.cpp
	Source/Core/DolphinWX/Frame.cpp
	Source/Core/DolphinWX/FrameAui.cpp
	Source/Core/DolphinWX/LogConfigWindow.cpp
	Source/Core/DolphinWX/LogWindow.cpp
2014-02-23 07:48:06 +01:00
Pierre Bourdon 311caef094 Merge pull request #25 from Tilka/ppc_fp
Fix non-IEEE mode
2014-02-23 04:15:37 +01:00
Pierre Bourdon 83b7bb64aa Make Common/ mostly IWYU clean (and fix errors in rest of the project detected by this change). 2014-02-22 23:37:29 +01:00
Lioncash 91286f5021 Fix the Windows build in relation to the recent changes. 2014-02-20 01:01:11 +01:00
Pierre Bourdon 9a8ea53195 Fix LinearDiskCache.h relying on a file not directly included. 2014-02-20 01:01:11 +01:00
Pierre Bourdon 3f9c38d231 Fix more header sorting issues in Common/ (now check-includes clean). 2014-02-20 01:01:10 +01:00
Lioncash 2afe215271 Convert all includes to relative paths. 2014-02-18 02:19:10 -05:00
Lioncash 3fd87a7636 Second and final pass of clearing out tabs. 2014-02-17 02:19:41 -05:00
Lioncash cd8196f5db Turns out Console.cpp and ConsoleListener.cpp were being built into the Linux builds too. Fixes the build. 2014-02-16 20:55:07 -05:00
Lioncash ca7bdf1d5d Remove the embedded Console from the possible logging options.
Note I do not mean the Logging window, but the console window.
It's literally rarely, if at all used, and offers less advantages over the built-in logging window (ie. it breaks on different locales: http://i.imgur.com/Cs92tQE.png)

This commit should remove all of the console logging.
2014-02-16 20:40:33 -05:00
Pierre Bourdon 92f8d93e96 Remove the old MMIO access "interface". 2014-02-16 19:22:40 +01:00
Tillmann Karras 404624bf0b Turn loops into range-based form
and some things suggested by cppcheck and compiler warnings.
2014-02-13 09:05:50 +01:00
Tillmann Karras 2ff794d299 Fix some warnings 2014-02-13 09:02:43 +01:00
Matthew Parlane 88526be3b5 Merge pull request #50 from Parlane/inifile_tidy
Fix IniFile to use string& instead of char*
2014-02-13 19:04:27 +13:00
Matthew Parlane 3fe05e0a9f Fix IniFile to use string& instead of char*
Also removes .c_str() usages where found.
2014-02-13 17:06:30 +13:00
Scott Mansell cf5938c4df x64Emitter: Fix the PSUBQ instruction's opcode 2014-02-12 23:12:17 +01:00
Scott Mansell 1eb8168488 x64Emitter: Add the xmm, xmm form of PSRLQ instruction. 2014-02-12 23:12:16 +01:00
Tillmann Karras 1f34ed2c25 Re-enable non-IEEE mode support 2014-02-12 23:12:16 +01:00
Tillmann Karras db196d8c5b Jit64[IL]: fix float conversions
Floating-point is complicated...

Some background: Denormals are floats that are too close to zero to be
stored in a normalized way (their exponent would need more bits). Since
they are stored unnormalized, they are hard to work with, even in
hardware.  That's why both PowerPC and SSE can be configured to operate
in faster but non-standard-conpliant modes in which these numbers are
simply rounded ('flushed') to zero.

Internally, we do the same as the PowerPC CPU and store all floats in
double format. This means that for loading and storing singles we need a
conversion. The PowerPC CPU does this in hardware. We previously did
this using CVTSS2SD/CVTSD2SS. Unfortunately, these instructions are
considered arithmetic and therefore flush denormals to zero if non-IEEE
mode is active. This normally wouldn't be a problem since the next
arithmetic floating-point instruction would do the same anyway but as it
turns out some games actually use floating-point instructions for
copying arbitrary data.

My idea for fixing this problem was to use x87 instructions since the
x87 FPU never supported flush-to-zero and thus doesn't mangle denormals.
However, there is one more problem to deal with: SNaNs are automatically
converted to QNaNs (by setting the most-significant bit of the
fraction). I opted to fix this by manually resetting the QNaN bit of all
values with all-1s exponent.
2014-02-12 23:12:15 +01:00
Tillmann Karras c25c4a6e20 x64: add support for some x87 instructions 2014-02-12 22:45:01 +01:00
Tillmann Karras 3218f6cca8 x64: drop instructions that don't exist
These instructions don't exist in hardware although I agree that they
would be useful for our purposes ;)
2014-02-11 05:22:53 +01:00
lioncash d2038049f5 Replace all include guard ifdefs with "#pragma once" 2014-02-10 18:07:16 -05:00
Matthew Parlane 32bfcc034f Some tidy up of sprintf to StringFromFormat
Includes a small fix to SetupWiiMemory
2014-02-10 17:25:18 +13:00
Lioncash ebb48d019e Clean up some struct indentations
Also cleaned up the indentations of some variable declarations.
2014-02-09 19:40:11 -05:00
Lioncash 40182a48a5 Cleanup enum indentations. 2014-02-09 16:16:10 -05:00
Pierre Bourdon e59f770ccb Revert "Merge pull request #49 from Parlane/sprintf_tidy"
Change broke the build on Debian stable.

This reverts commit 28755439b3, reversing
changes made to 64e01ec763.
2014-02-09 16:14:13 +01:00
Matthew Parlane ebff7974c3 Some tidy up of sprintf to StringFromFormat 2014-02-08 14:32:48 +13:00
Matthew Parlane 6b980cbf30 Tidy up SetupWiiMemory 2014-02-07 19:00:34 +13:00
Pierre Bourdon 70e2ed320d Revert "Merge pull request #47 from lioncash/remove-stringfromint"
Breaks Android build.

This reverts commit 12d026c544, reversing
changes made to 6d678490f5.
2014-02-07 00:26:33 +01:00
Pierre Bourdon 12d026c544 Merge pull request #47 from lioncash/remove-stringfromint
Remove function StringFromInt from StringUtil.cpp/.h. C++11 has std::to_string for this now.
2014-02-07 00:19:15 +01:00
Lioncash 05742ffd48 Remove function StringFromInt from StringUtil.cpp/.h. C++11 has std::to_string for this now. 2014-02-06 18:08:31 -05:00
Matthew Parlane 70d2592ffb Fix warnings found by StringFromFormat having printf style checking. 2014-02-07 01:38:08 +13:00
Matthew Parlane 09cc7e2ddf Give StringFromFormat a printf format attribute.
It gives StringFromFormat printf style arguments that should be type-checked against a format string.
2014-02-07 01:10:04 +13:00
Lioncash 249b00c469 Change the modified parameter in the Clamp function to be a pointer.
Makes it easier to identify the one being modified.
2014-02-05 04:04:35 -05:00
Lioncash 6b87a0ef20 Introduce a generic clamp function to clean up some similarly duplicated code. 2014-02-04 20:43:07 -05:00
Lioncash 7ebc829b17 Remove a pointless c_str() call in FileUtil.cpp. The function takes a string in it's parameter 2014-02-03 21:31:12 -05:00
Tillmann Karras b34fe2b8f1 x64: fix parameter names of WriteModRM() 2014-01-25 17:36:09 +01:00
Tillmann Karras 21b0252e27 Jit64: disable non-IEEE mode emulation
I give up. Merging the ppc_fp branch has caused issues in numerous games
and I can't find the bug. I'm leaving this merged to enable easy
recompilation for people who would like to play games that benefit from
non-IEEE mode emulation (e.g. Starfox Assault).
2014-01-19 09:36:08 +01:00
Jasper St. Pierre 34692ab826 Remove unnecessary Src/ folders 2013-12-31 14:03:19 -05:00
Jasper St. Pierre 43e618682e Convert all vcxproj files to UNIX line endings 2013-12-31 14:03:18 -05:00
comex 1b617c736c Add a non-tiny warning about CPUs that will silently desync. 2013-12-16 22:41:52 -05:00
Ryan Houdek eb3b933dd0 Remove all instances of OpenCL in the Dolphin Project. A brief history of OpenCL in Dolphin. OpenCL was originally added to the Dolphin codebase 1 month after it was released with OS X Snow Leopard in 2009. OpenCL was one of the largest group projects that Dolphin ever has had. The OpenCL texture decoder was originally aded with version 1.0 of the OpenCL spec; This version didn't have the capability of a OpenCL-OpenGL interop which would allow for uploading textures once and have it decoded directly to a OpenGL texure. This was to be worked out when the OpenCL 1.1 spec was released and allowed the interop. This work has never been done, and no one in the team is willing to work on it for various reasons. OpenCL has had the unreasonable expectation that it increases the performance of video games that require a large amount of EFB copies like NSMBW. In reality, enabling OpenCL just put the graphics card in a higher power mode which increased the game speed. This is due to the unfortunate effect of Dolphin tending to not push GPUs out of their lower frequency power savings modes. Thanks to everyone that had contributed to the OpenCL texture decoder. 2013-12-11 15:15:55 -06:00
comex eaacf10f71 Fix an idiotic race condition when starting games in multiple Dolphin instances at the same time on Unix.
MemArena mmaps the emulated memory from a file in order to get the same
mapping at multiple addresses.  A file which, formerly, was located at a
static filename: it was unlinked after creation, but the open did not
use O_EXCL, so if two instances started up on the same system at just
the right time, they would get the same memory.  Naturally, this caused
extremely mysterious crashes, but only in Netplay, where the game is
automatically started when the client receives a broadcast from the
server, so races are actually quite likely.

And switch to shm_open, because it fits the bill better and avoids any
issues with using /tmp.
2013-12-10 16:20:52 -05:00
Tillmann Karras b863e40677 Merge branch 'ppc_fp' 2013-11-18 19:31:09 +01:00
Jordan Cristiano f96e9e1ae4 warnings and code formatting 2013-11-13 04:03:46 -05:00
Tillmann Karras 288bef2807 x64: add small warning if CPU has SSE2 but not DAZ 2013-11-13 06:26:57 +01:00
Tillmann Karras cd069fdce1 Interpreter: software-based flush-to-zero
bDAZ is now called bFlushToZero to better reflect what it's actually
used for.

I decided not to support any hardware-based flush-to-zero on systems
that don't support this for both inputs _and_ outputs. It makes the code
cleaner and the intersection of CPUs that support SSE2 but not DAZ
should be very small.
2013-11-13 06:24:58 +01:00
Tillmann Karras 466a7afde3 Interpreter: support non-IEEE mode emulation
v2: fix fxsave on visual studio, thx @ rodolfo for this patch
2013-11-13 06:24:57 +01:00
Tillmann Karras ae86850a78 x64: support VEX opcode encoding
and add some AVX instructions
2013-11-13 06:12:23 +01:00
Tillmann Karras 6054129df8 x64: detect FMA support 2013-11-13 04:46:34 +01:00
Tillmann Karras 268bdf19ce Fix format string warnings 2013-11-13 04:01:16 +01:00
Ryan Houdek 7c1ac441f6 Redo 'Fixes GCC 4.9 compilation. It now supplies its own _mm_shuffle_epi8 intrinsic.' This time with support for Windows. 2013-11-12 16:34:56 -06:00
Ryan Houdek 56557c845a [ARM] Fix NEON emitter encodings. 2013-11-12 01:01:54 +00:00
Ryan Houdek d1de336879 [ARM] More NEON emitters. 2013-11-11 01:47:05 +00:00
Jordan Cristiano 3a28afd8d5 Changed thread barrier and event to use a lamba wait predicate instead of a functor. 2013-11-10 04:57:11 -05:00
Ryan Houdek e013a74cdb [ARM] More NEON emitters. 2013-11-10 05:02:32 +00:00
Ryan Houdek 56685c396a [ARM] Fix an issue with the data offset in LoadStore operations. Thanks to PPSSPP. 2013-11-05 13:05:38 +00:00
Matthew Parlane e15f628935 Fix {Read,Write}FileToString.
We should be using binary always.
2013-11-05 00:33:41 +13:00
comex c579637eaf Run code through the advanced tool 'sed' to remove trailing whitespace. 2013-11-03 20:54:05 -05:00
comex 965b32be9c Run code through clang-modernize -loop-convert to create range-based for loops, and manually fix some stuff up. 2013-11-03 20:54:01 -05:00
comex 82729fcc8f Merge remote-tracking branch 'shuffle2/vc12'
Conflicts:
	Source/Core/Common/Common.vcxproj
	Source/Core/Common/Common.vcxproj.filters
2013-10-31 16:51:56 -04:00
comex 4c7bbd96e4 Improve ChunkFile.h:
- Add support for std::set and std:pair.

- Switch from std::is_pod to std::is_trivially_copyable, to allow for
  types that have constructors but trivial copy constructors.  Easy,
  except there are three different nonstandard versions of it required
  on different platforms, in addition to the standard one.
2013-10-31 15:40:53 -04:00
comex 2e983071c5 Add git.bat to the options in make_scmrev.h.js because depot_tools uses it and I'm silly. 2013-10-27 19:51:55 -04:00
Ryan Houdek 8e73e8ae5f Wipe all traces of OpenSSL's AES implementation. Use polarssl instead. 2013-10-27 18:27:07 +00:00
Shawn Hoffman ccd30024b3 Update to VS2013 and a slew of build-related updates. Notes:
* Currently there is no DEBUGFAST configuration. Defining DEBUGFAST as a preprocessor definition in Base.props (or a global header) enables it for now, pending a better method. This was done to make managing the build harder to screw up. However it may not even be an issue anymore with the new .props usage.
* D3DX11SaveTextureToFile usage is dropped and not replaced.
* If you have $(DXSDK_DIR) in your global property sheets (Microsoft.Cpp.$(PlatformName).user), you need to remove it. The build will error out with a message if it's configured incorrectly.
* If you are on Windows 8 or above, you no longer need the June 2010 DirectX SDK installed to build dolphin. If you are in this situation, it is still required if you want your built binaries to be able to use XAudio2 and XInput on previous Windows versions.
* GLew updated to 1.10.0
* compiler switches added: /volatile:iso, /d2Zi+
* LTCG available via msbuild property: DolphinRelease
* SDL updated to 2.0.0
* All Externals (excl. OpenAL and SDL) are built from source.
* Now uses STL version of std::{mutex,condition_variable,thread}
* Now uses Build as root directory for *all* intermediate files
* Binary directory is populated as post-build msbuild action
* .gitignore is simplified
* UnitTests project is no longer compiled
2013-10-26 17:55:38 -07:00
Ryan Houdek 1eba4da21a Revert "Fixes GCC 4.9 compilation. It now supplies its own _mm_shuffle_epi8 intrinsic."
This reverts commit b2c4901b3f.

Breaks Windows build. GCC 4.9 isn't out yet anyway.
2013-10-26 19:21:00 -05:00
Ryan Houdek b2c4901b3f Fixes GCC 4.9 compilation. It now supplies its own _mm_shuffle_epi8 intrinsic. 2013-10-26 19:05:31 -05:00
Ryan Houdek e3febb1603 [Android] Fix MIPS compiling. 2013-10-21 09:52:43 -05:00
Lioncash 4b774ef99a Fix my fix. 2013-10-20 16:42:30 -04:00
Lioncash 448c19bce1 Fix an issue where my recent changes would cause compilation to fail on some distros of Linux.
Note that before pushing those changes, they were initially tested in a branch, and passed the compilation testing. Sorry that I didn't catch this before.
2013-10-20 16:32:40 -04:00
Lioncash b3da5c5d58 Really fix the Linux build this time.
Dammit size_t :(
2013-10-19 19:59:05 -04:00
Lioncash a5a21e7f44 Fix Linux build.
Turns out Hash.h needs Common.h
2013-10-19 19:59:04 -04:00
Lioncash 8b10d5b481 Add header cstdint to CommonTypes.h 2013-10-19 19:59:03 -04:00
Lioncash 1f0710caf7 Remove some more includes. 2013-10-19 19:59:03 -04:00
Lioncash 97cd42f5c3 Remove some unnecessary includes as well as simplifying exisiting ones if possible. 2013-10-19 19:58:56 -04:00
comex de1773affb Basic precompiled header support for Linux/OS X. Shaves 20-30% off full rebuild time on my system. 2013-10-17 00:07:35 -04:00
comex b11cf1fa10 Fix config file saving on Windows. 2013-10-15 17:20:00 -04:00
comex 72c1e143f3 Try to atomically save config files. 2013-10-15 02:59:25 -04:00
Lioncash f3af8ee0f0 Revert "Remove some unnecessary includes."
Turns out this explodes on Linux.

This reverts commit c4696568cc.
2013-10-14 04:05:38 -04:00
Lioncash c4696568cc Remove some unnecessary includes. 2013-10-14 04:01:57 -04:00
Ryan Houdek 715d5ae8a7 Merge branch 'JitArmIL'
This implements a partial JITIL based off of the JIT64IL. It's enough to run most games, albiet at a slow speed.
Implementing instructions for this IL is really simple since it basically is just enabling based on what is already in JIT64IL, and then enabling each individual IL instruction.
2013-10-09 23:16:07 +00:00
Ryan Houdek f5e1b4659a [ARM] Clean up LSL, LSR, and ASR emitters, we don't need a separate instruction for each to support registers. 2013-10-09 22:57:31 +00:00
Rachel Bryk 99c89ae109 Fix unicode support for File::Rename() on windows.
Partial fix of issue 6721.
2013-10-09 15:33:21 -04:00
Ryan Houdek 7dd8deecec [ARM] Update the ArmEmitter with a bunch of NEON emitters. This adds around 47 instruction emitters if I counted correctly. None well tested at this point. On going to add all the NEON emitters. 2013-10-08 10:17:01 +00:00
comex a9908fdf09 Fix build issues on OS X i386. 2013-10-07 02:16:51 -04:00
comex 21a114ec28 ...Forgot the XMM regs for x86. 2013-10-05 01:17:34 -04:00
comex 144d7e5500 Fix build-breaking typo. 2013-10-05 01:08:08 -04:00
comex 3679f9ba60 Don't push registers before pairedStoreQuantized, that's dumb.
And fix some stuff up.  It would probably be good to unify the stack
handling some more rather than having ABI_PushRegistersAndAdjustStack do
part of it and ABI_AlignStack the rest, causing unnecessary subtract
instructions on Linux x86 (only).
2013-10-04 15:48:06 -04:00
comex 5e4665301b Finish replacing ThunkManager with ABI_PushRegistersAndAdjustStack.
As part of that, change SafeLoadToEAX to SafeLoadToReg, and have JitIL
use that, which should fix fastmem on JitIL.

This should also fix a potential stack corruption issue with x86.
2013-10-03 18:22:35 -04:00
Lioncash 1ec4894bc5 [Common] Abstract out the decode5A3Image and decodeCI8Image functions in BannerLoaderGC, BannerLoaderWii, and GCMemcard into ColorUtil.cpp. Makes for less copied code and remains functionally the same. 2013-10-02 18:18:54 -04:00
Ryan Houdek 3c53f2e5e0 [Android] Fix Fastmem on Android 4.2 2013-09-29 20:53:32 -05:00
comex 1a008b9e62 Fix use of ABI_GetAlignedFrameSize. 2013-09-29 16:36:26 -04:00
comex ccbf2ac21a Match ABI_AlignStack with ABI_RestoreStack properly.
The relevant function is entirely unused, so it shouldn't have any
effect.
2013-09-29 14:59:13 -04:00
comex ecca0045a9 Fix Imm8 check.
(I blame whoever made it take a u8 despite logically being a s8.)
2013-09-25 14:29:17 -04:00
comex ebe4448749 Save only the registers that need to be saved rather than going through ProtectFunction. 2013-09-25 03:15:53 -04:00
comex 2a339c926e Fastmem writes for x86-64. 2013-09-25 03:15:53 -04:00
Ryan Houdek eb6ed3e42a [ARM] Change all floating point loadstores to fastmem implementations except lfs since all floating point accesses tend to be to RAM space. lfs tends to get used to write quickly to the gatherpipe and other places, look at the JIT64 implementation to see how to make it quicker. 2013-09-24 05:41:58 +00:00
comex 4cdce55615 Don't define _M_IX86 on ARM(!).
Also define _M_* in a common location, and clean up code that these
changes break (including DSPJit files that assume X86 yet are compiled
on ARM for some reason...)
2013-09-24 01:30:41 -04:00
comex 2f384c75d2 Only include scmrev.h from Version.cpp.
This way less code has to be rebuilt whenever that file gets
regenerated.
2013-09-24 01:14:56 -04:00
comex f81df136c2 Add an explicit error message for outdated GCC, and remove some commented out code. 2013-09-23 15:01:38 -04:00
comex c8c83f7b8a Remove FifoQueue iterator and RemoveThreadsafeEvents.
No point making a whole iterator class for the sake of a function that
doesn't need to exist.
2013-09-22 23:14:42 -04:00
comex e82c9e616d operator= is a function too! std::forward is still appropriate.
Fix the potentially unsafe use of std::move I added to FifoQueue.
2013-09-22 21:15:58 -04:00
comex 17e753faf3 Fix FifoQueue's atomicity on ARM.
Theoretically.
2013-09-22 16:08:09 -04:00
comex c3b9f3556f Make CoreTiming's threadsafe events lock-free.
Not sure if this actually helps in practice, but might help in
pathological cases, and almost certainly can't hurt.
2013-09-22 16:08:01 -04:00
comex 7fe440340f Improve Atomic.h:
- For GCC, use intrinsics that will work on ARM.
- Add AtomicExchangeAcquire.
- Make Atomic{Load,LoadAcquire,Store,StoreRelease} work for any suitable type.
2013-09-22 16:07:45 -04:00
comex 6209067daa Fix stack misalignment fix. 2013-09-22 15:48:27 -04:00
Rachel Bryk 9a6f28fce4 Revert "Fix stack misalignment issues."
This reverts commit d334a9bc23.

This breaks single core.
2013-09-22 14:29:35 -04:00
comex d334a9bc23 Fix stack misalignment issues.
- Call ABI_AlignStack even on x86-64.

- Have ABI_AlignStack respect the difference in current alignment
  between the root JIT function, which has a prolog, and
  ProtectFunction thunks, which do not.  This was causing many games
  to crash on start on OS X.  Since this might otherwise mean changing
  the stack pointer before every call...

- Have one prolog/epilog function rather than two (one of which
  definitely did not do what it was thought to do), and make it
  actually work like a normal one, so that the stack frame shows up
  properly in the debugger.  There should be no performance impact.
2013-09-20 16:46:48 -04:00
Lioncash 86d70cee15 Turns out CVTSD2SI in x64Emitter.cpp should actually use 64 bits instead of 32. Thanks for pointing that out hk.konpie. 2013-09-20 14:50:27 -04:00
Ryan Houdek 6fc2117503 [ARM] Enable VMOV to move from double VFP reg to two ARM registers. 2013-09-18 17:21:22 -05:00
Lioncash d03fb11188 Fix an incorrect opcode for an SSE instruction in x64Emitter.cpp. CVTSD2SI should write 0x2D, not 0xF2.
Also format the NormalSSEOps enum.
2013-09-18 07:43:31 -04:00
Ryan Houdek 06062d5744 [ARM] Fix VSQRT/VCMP/VCMPE/VCMPE0/VCMP0 emitters when using the high 16 double registers. 2013-09-17 22:08:23 +00:00
Pierre Bourdon e34d8aee1d Add * to the characters leading a verbatim line (used in Gecko codes comments) 2013-09-17 16:50:44 +02:00
Lioncash 38c7d38800 Fix two wrong opcodes in the x64Emitter. PEXTRW and PINSRW were actually writing PCMPGTB opcodes. Thanks for the help Sintendo. 2013-09-16 15:59:31 -04:00
Ryan Houdek 7d410ec95c [ARM] VRSQRTE NEON emitter. 2013-09-16 12:58:20 +00:00
Ryan Houdek beb41a8f56 [ARM] Add NEON VORR and fix encoding on NEON VEOR. Remove VMRS_APSR because it is the same as VMRS(PC) 2013-09-16 07:49:16 +00:00
Pierre Bourdon f0fc611f15 Add a hacky check for text file size in ReadFileToString. Fixes issue 6455. 2013-09-16 06:57:44 +02:00
Pierre Bourdon 037199c326 Look for portable.txt in the exe directory and activate portable mode if it exists 2013-09-16 05:46:07 +02:00
Pierre Bourdon 2c350a5e6b Fix INIFile ignoring the last line of files 2013-09-16 05:28:14 +02:00
Pierre Bourdon 24e9aedc14 Merge branch 'global-user-directory'
Please read https://wiki.dolphin-emu.org/index.php?title=Controlling_the_Global_User_Directory
for documentation about this feature.

Thanks to neobrain and RachelB for their work on this change, and thanks to
everyone who helped test it.
2013-09-14 19:24:27 +02:00
Pierre Bourdon 501eafb407 Overlay local gameinis over global gameinis instead of copying.
Huge megacommit because a lot of things needed to be modified to make this
possible.
2013-09-14 17:46:41 +02:00
Ryan Houdek 81d7986202 [ARM] Add LSRS emitters, and ASR{S} register emitters. Fixes encoding in LSR emitter. 2013-09-14 09:06:49 +00:00
Pierre Bourdon cf4c39d2be IniFile: Support extending the list of loaded keys and sections with data from other ini files.
Changes a lot of parsing code which previously was not aware of the notion of
key/value, and operated only with raw lines. Now key/value is the default and
lines are handled as raw only if they do not contain =, or they start with $ or
+ (for Gecko/AR compatibility).
2013-09-14 06:08:31 +02:00
Pierre Bourdon aa202c2e21 Move global gameinis from User to Sys. Get rid of SHARED_USER. 2013-09-14 06:08:30 +02:00
Pierre Bourdon 86e765f3eb Move Themes/ from User to Sys. Only Gameinis remain. 2013-09-14 06:08:30 +02:00
Pierre Bourdon b587af3ea3 Change the initial user directory creation to stop special casing Windows 2013-09-14 06:08:29 +02:00
Rachel Bryk dfcef6890e Use global user directory on windows.
Can override by setting HKCU\Software\Dolphin-emu\LocalUserConfig to true.
2013-09-14 06:08:29 +02:00
Jordan Woyak ef1d33647f Improve the ArraySize function a bit now that c++11 isn't forbidden there. Error messages should be friendlier now. 2013-09-12 12:57:13 -05:00
comex b9c1af04ad Replace the one use of CompileTimeAssert with static_assert (already used elsewhere). 2013-09-11 20:58:47 -04:00
Jordan Woyak fde3815d34 Replace ARRAYSIZE macro with another ugly macro. At least this will throw an error for a non-array and won't conflict with Windows macro names. 2013-09-11 19:19:36 -05:00
Ryan Houdek c1aa80cefa [ARM] Add support for double registers in VMOV(immediate). Add VEOR and VSTR1. Fix some minor encoding bugs. 2013-09-08 21:56:17 +00:00
Ryan Houdek e6af4970d8 [ARM] Use NEON for loading the values from psq_l, gives a minimal performance increase. This change also begins a new NEONXEmitter for having cleaner support for NEON. 2013-09-08 07:07:15 +00:00
Ryan Houdek d0d053a9f9 Fix for old libc version on bionic. Old versions would crash if the second argument was NULL. 2013-09-04 02:04:31 -05:00
comex 4c3230bcde Remove accessType from BackPatch's signature in favor of getting it from DisassembleMov.
It isn't easily accessible with sigaction or Mach exceptions (well,
requires an additional system call in the latter), and isn't necessary.

(and get rid of the enum, because it's only used once, and the comments
are more expressive than enum names)
2013-09-02 16:55:22 -04:00
Ryan Houdek e7157e7c52 [Android] Fix fastmem and enable. 2013-09-02 04:10:21 -05:00
comex 35b8dfbe0c A few more warnings. 2013-09-01 23:33:35 -04:00
comex 4f5729dd59 MSVC warnings. 2013-09-01 22:59:32 -04:00
comex fd7cf5bb71 A bunch of trivial changes to fix clang warnings. 2013-09-01 22:58:33 -04:00
comex a6f6695ecd Work around MSVC bug, and make it less likely to happen again. Ew.
MSVC insisted on using a copy assignment where a move was intended and
ought to be used.  This would have been caught, because the class in
question inherits from NonCopyable, which declares a move assignment
operator, which is supposed to delete the implicitly declared copy
assignment operator, but of course MSVC didn't do that either, causing a
class that should have been safe to be unsafe.
2013-09-01 00:04:50 -04:00
comex 04c41c1d38 Fix loading DLC using IOCTL_ES_OPENTITLECONTENT & /dev/es state save.
(Intertwined enough that's it's easier to do in one patch.)

(1) /dev/es did not support state save, which could cause crashes and
    incorrect behavior after loading.

(2) NANDContentLoader tried to read all of a title's contents into
    memory when it was first opened.  Two issues:

- If any contents were missing, it bailed out.  However, with DLC,
  only some of the contents may be downloaded, as determined by the
  permission bits in the ticket.  Instead, return an appropriate error
  when a content is accessed that doesn't exist on the filesystem
  (don't bother checking the permission bits though).

- Everything was loaded into memory - even if it consisted of 3 GB of
  songs, which caused Dolphin to lag out for quite a while (and would
  fail on 32-bit).  Instead, open content on demand.
2013-08-31 01:38:52 -04:00
comex 4d6d4a97e4 Make NonCopyable use rvalue references.
This is required to be able to move objects that inherit from it.
(Note that this patch also #ifs out the class for the externals that
include it yet are compiled in pre-C++11 mode.  It shouldn't matter,
since those externals don't use it.)
2013-08-31 01:38:49 -04:00
Ryan Houdek 710ac04084 [ARM] Fix the VMOV encoding to encode the destination VFP register correctly. 2013-08-30 05:13:43 -05:00
Ryan Houdek 2c1337eb5f [ARM] Support both hardfp and softfp with lfs and lfd. Fixes these two instructions on Android since it uses softfp calling conventions. This adds a emitter for moving from two ARM Registers to a double VFP reg. 2013-08-30 09:38:11 +00:00
Ryan Houdek 8bb16d8e98 [Android] Android NDK now supports full implementations of std::mutex, std::thread, and std::conditional_variable so there is no need to have our own implementations there now. 2013-08-29 22:29:33 -05:00
comex 2de2e774fe Use pthread_setname_np.
This makes SetCurrentThreadName actually work (name shows up in
debugger) on non-Windows.
2013-08-29 16:30:32 -04:00
Ryan Houdek 160d72a9ae [Android] Add in a static libiconv library so non English games don't crash Dolphin Mobile. 2013-08-29 04:43:31 -05:00
Matthew Parlane b34a5faee7 More cleaning. 2013-08-28 01:07:43 +12:00
Matthew Parlane 75c398118f Fix headings and more. 2013-08-28 00:57:08 +12:00
Matthew Parlane 15f8603d1f Merge branch 'master' into wii-network
Conflicts:
	Source/Core/Common/Src/CommonPaths.h
	Source/Core/Common/Src/FileUtil.cpp
2013-08-26 00:50:57 +00:00
Rachel Bryk 18749bad68 Actually allow the dump and logs folders to be set outside of user/ 2013-08-25 01:35:32 -04:00
Rachel Bryk 8882f89bbc Allow user folder to be set via command line.
Clean up GetUserPath(), to allow setting any path with it.
2013-08-24 23:15:55 -04:00
Pierre Bourdon 73be79f4e0 Fix trailing whitespaces in all files where some were added 2013-08-25 02:49:58 +02:00
Matthew Parlane b6e054a2be Merge branch 'master' into wii-network
Conflicts:
	Source/Core/Core/Core.vcxproj
	Source/Core/Core/Core.vcxproj.filters
	Source/Core/Core/Src/CoreParameter.cpp
	Source/Core/DolphinWX/Dolphin.vcxproj
	Source/Core/DolphinWX/Dolphin.vcxproj.filters
2013-08-23 00:51:12 +12:00
Pierre Bourdon 20e82ec08c Fix the fix to AVX support detection
Should be xgetbv(0) & 6 == 6, not just & 6. Thanks to tueidj for pointing this
out.
2013-08-22 01:08:14 +02:00
Ryan Houdek 60ccb2f44d [Android] Fix Android 4.3 from crashing on my devices. This was annoying to find. 2013-08-21 00:12:53 -05:00
Pierre Bourdon 377202b9f6 Correctly check for AVX support in x64CPUDetect
It's not enough to check for the CPUID bit to know if AVX is supported since
AVX requires OS support (new set of registers == more registers to be saved
when context switching). If the OS does not support, the cpuid bit will still
be set but using YMM registers will cause an illegal exception fault.
2013-08-20 01:25:10 +02:00
Ryan Houdek 9bded1382c [ARM] Add ASR/ASRS and UMULLS emitters. 2013-08-19 06:26:34 +00:00
Ryan Houdek 367f294ed2 [Android] Make sure to unallocate the correct memory size in MemArena. 2013-08-16 04:55:43 -05:00
Matthew Parlane 59e060aba2 Missed some VS build options. 2013-08-16 21:42:31 +12:00
Matthew Parlane 9de7611ff9 Merge branch 'master' into wii-network
Conflicts:
	CMakeLists.txt
	Source/Core/Core/Core.vcxproj
	Source/Core/DolphinWX/Dolphin.vcxproj
	Source/Core/DolphinWX/Dolphin.vcxproj.filters
	Source/Dolphin_2010.sln
	Source/VSProps/Dolphin.Win32.props
	Source/VSProps/Dolphin.x64.props
2013-08-16 19:17:07 +12:00
Matthew Parlane d6ec6ae97a Fix polarssl on Windows. 2013-08-16 00:24:10 +12:00
Matthew Parlane d8b39b9dcf Support PolarSSL on *nix
Removed unneeded PolarSSL directories.
Remove duplicate sha1 and md5 files.
Define out SSL test file writing.
Fix format string bug and warning.
2013-08-15 23:36:17 +12:00
Matthew Parlane fede38985e Replace OpenSSL with PolarSSL
Works on windows, not yet cmake.
2013-08-15 20:47:47 +12:00
Jasper St. Pierre 3380e47ca7 MemArena: Free memory for 64-bit machines
Make the logic here a lot simpler. Patch contributed by Google Code
user plbl4ster.
2013-08-14 20:34:15 -04:00
Pierre Bourdon ffdd79df36 Move VideoBackendBase from Common to VideoCommon 2013-08-14 23:16:46 +02:00
Jasper St. Pierre b5c2737c9f IniFile: Don't parse comments after the [Section] brackets
This is non-standard behavior. We won't fail to parse, but we now
won't write them back out either.
2013-08-11 11:32:10 -04:00
Jasper St. Pierre 0eaea5f4df IniFile: Remove support for comments anywhere but the beginning of lines
The MS INI parser and most other INI parsing libraries APIs only support
comments at the beginning of lines. Right now, some Game INI files use sections
like:

  [OnFrame]#Add memory patches here

But these section headers are parsed separately, so this should not break
them.
2013-08-11 11:30:52 -04:00
Jordan Woyak a279001472 Remove "-0" from stable version numbers in a more foolproof manner for vs and cmake builds. 2013-08-10 17:19:19 -05:00
Rachel Bryk 90d454d22f Remove -0 from stable release version numbers. 2013-08-08 23:59:53 -04:00
Pierre Bourdon 9ea01aa7a8 Use a multibyte-neutral codepage when calling *printf on Windows.
More explanation in code comments.

Fixes issue 4046.
2013-08-09 00:17:48 +02:00
NeoBrainX 72abe7c654 Fix a stack corruption in ExtendedTrace.
Fixes issue 6454.
2013-08-08 20:29:20 +02:00
Lioncash 9d0554e4a6 Free two memory leaks in ArmCPUDetect.cpp
Char pointers aren't freed after use.

Fixed this in PPSSPP a few days ago. Forgot to check here for the same thing until now.
2013-08-06 18:17:54 -04:00
Ryan Houdek ca7fb9f38e [ARM] Fix VCVT F32<->F64 encoding. 2013-08-03 00:48:44 +00:00
Ryan Houdek ab0f42636d [ARM] Push new ArmEmitter changes from PPSSPP. Mostly Fixes a few VFP/NEON instruction encodings. 2013-08-02 23:18:44 +00:00
Jasper St. Pierre 52482115e1 Move in-game keybinding handling to a central location
Instead of handling it separately in every backend.
2013-07-21 23:17:16 -04:00
Ryan Houdek f4b414a9c1 Fix encoding issue with VADD(Integer) 2013-07-16 22:18:15 -05:00
Ryan Houdek 9123f58bd5 Check for IDIVA/IDIVT correctly. Cortex-A5 parts would have had this set since it supports VFPv4 but not IDIVA. Qualcomm Krait/Krait 300 still doesn't report in the kernel that it supports this. 2013-07-16 01:22:25 -05:00
Ryan Houdek 012c32c14c [Android] Undefine the swaps in Android completely, not just on ARM Android. 2013-07-11 08:58:10 -05:00
Ryan Houdek 7d6b36bf73 Fix most ARM warnings 2013-07-05 19:56:15 -05:00
John Peterson 0fd3acd152 Saving real Wiimote state
because that's simpler than reconnecting
2013-06-25 09:24:14 -04:00
Ryan Houdek 6bb7cc5fea [Android] Add an about screen that shows build revision. 2013-06-22 22:54:36 -05:00
NeoBrainX 15943de313 Revert "Added optimizations to ClassifyFloat/Double functions in Mathutil.cpp and to PPCCache.cpp"
This reverts commit 7aae9ccbc0.

Reasons:
- no test results have been provided to prove the usefulness of the patch
- broken coding style
- the author hasn't replied to any criticism
2013-06-22 12:25:03 +02:00
Armada fc7099a905 Set the locale per-thread instead of globally when generating shaders. Add cross-compatible versions of newlocale, uselocale and freelocale.
This commit fixes a rare race condition when generating shaders because setlocale is global.
2013-06-16 12:33:13 +02:00
eli173 7aae9ccbc0 Added optimizations to ClassifyFloat/Double functions in Mathutil.cpp and to PPCCache.cpp 2013-06-01 19:17:52 -05:00
Ryan Houdek 09def3ed3f [Android] Add in a compiling option for GLES3 2013-05-05 23:37:01 -05:00
Matthew Parlane 934e150596 Merge branch 'master' into wii-network
Conflicts:
	Source/Core/Core/Src/Boot/Boot_BS2Emu.cpp
	Source/Core/Core/Src/ConfigManager.cpp
	Source/Core/Core/Src/HLE/HLE_OS.h
	Source/Core/Core/Src/IPC_HLE/WII_IPC_HLE_Device_es.cpp
	Source/Core/Core/Src/IPC_HLE/WII_IPC_HLE_Device_es.h
	Source/Core/Core/Src/IPC_HLE/WII_IPC_HLE_Device_net.cpp
	Source/Core/Core/Src/IPC_HLE/WII_IPC_HLE_Device_net.h
2013-04-24 00:48:00 +12:00
Pierre 9a8dd7963e Merge branch 'dspjit'
Conflicts:
	Source/Core/Core/Src/DSP/Jit/DSPJitExtOps.cpp
	Source/Core/Core/Src/DSP/Jit/DSPJitMisc.cpp
	Source/Core/Core/Src/DSP/Jit/DSPJitRegCache.cpp
	Source/Core/Core/Src/DSP/Jit/DSPJitUtil.cpp
2013-04-21 12:29:18 +02:00
lioncash d244bca1f5 Fix a bunch of random typos in comments and logging.
Also update the comment headers for two functions in GCMemcard.cpp.
2013-04-19 09:21:45 -04:00
Ryan Houdek 491ffabb56 Android Clang doesn't support TLS, so do the same thing as OSX. 2013-04-18 22:52:53 -05:00
Ryan Houdek f811d11863 Fix clang building the std headers. 2013-04-18 22:52:05 -05:00
Ryan Houdek d68955c539 Clang uses __clear_cache instead of __builtin___clear_cache like GCC 2013-04-18 22:50:58 -05:00
Lioncash bab9963b00 New license header introduced for DiscIO, AudioCommon, InputCommon, VideoCommon, and Common projects. 2013-04-17 23:09:55 -04:00
lioncash ef85b9af45 Update the license file text (change SVN to Git) in all projects except Core since I was told a merge was happening soon. So for the sake of the merge going smoothly, I'll fix that when I remove the tab/space mismatches from the Core project.
Also, some tab/space mismatches removed from VideoOGL, and some places I missed in VideoDX[number] projects.

Now, the Core is literally the only project with tab/space mismatches (on a large scale).
2013-04-15 16:28:55 -04:00
Ryan Houdek bde7ea00ef Removes the Java ButtonManager for one in the C++ source so the OSD class can call in to it each frame for drawing the buttons. Copy our assets to the dolphin-emu directory for now. Remove NativeRenderer, ButtonManager, and Button Java classes since they aren't used anymore. Buttons A, B, and Start all work and are drawn on screen now. Button input on Android is still a bit hacky, needs a proper controller interface still. Android specific button drawing code is still hanging out in SWRenderer.cpp 2013-04-14 20:39:56 -05:00
Pierre 6b5b8ab5be Implement and use MOVZX(64, 32,...)
Probably better to keep that same-register-MOV assert useful. Also,
explicit type extension documents whats happening.

Internally, this boils down to the original MOV, but without the assert.
2013-04-14 13:34:29 +02:00
Pierre 701b5916ab Revert "In memory of calc84."
This reverts commit 539bf405f2.
2013-04-14 13:34:29 +02:00
Ryan Houdek 605bbf5ca8 Merge remote-tracking branch 'origin/master' into Android-trash 2013-04-13 00:58:37 -05:00
Ryan Houdek 6d9c0c8863 Merge in latest changes to ArmEmitter from the PPSSPP crew. Should fix the dumb random crashes I had from IOS icache clearing not initializing a value. 2013-04-12 11:59:19 -05:00
Matthew Parlane 5eeed7aa9f This should never have been committed. Sorry. 2013-04-12 00:14:38 +12:00
Matthew Parlane 0c9d8d34e1 Merge branch 'master' into wii-network
Conflicts:
	Source/Core/Core/CMakeLists.txt
2013-04-11 19:55:36 +12:00
Jordan Woyak 385d8e2b15 ChunkFile has allowed me to accidentally "Do" a non-POD for the last time! 2013-04-09 19:02:22 -05:00
Jordan Woyak 71f4bf25a7 Make FifoQueue take advantage of rvalue references to avoid std::vector copies. 2013-04-04 19:34:50 -05:00
Ryan Houdek d06379fc59 Fix 32bit Linux. GCC's lrotl/lrotr instrinsic functions are 32bit when building for 32bit, we require 64bit at all times, so keep using our own instead. 2013-04-03 12:43:17 -05:00
Ryan Houdek b5676fe82b Fix GCC 4.8 compiling. GCC 4.8 now defines _rotl/_rotr/_lrotl/_lrotr. 2013-04-03 10:52:26 -05:00
Jordan Woyak d951c4c374 real buildfix 2013-04-02 13:07:51 -05:00
Jordan Woyak c65473d9d3 Probably a sloppy buildfix. 2013-04-01 23:30:05 -05:00
Jordan Woyak 69779a4321 Fix loading of "themes" with non-ascii character names.
Fixed issue 6189.
Why did GetUserPath return a non-const ref to string..?
2013-04-01 23:22:20 -05:00
Pierre Bourdon 49d809ac0e Merge branch 'osx-libcxx' 2013-04-01 18:17:49 +02:00
Lioncash 58159a1693 Some more logging typos and clarifications. Missed these in my last commit.
This commit mainly elaborates on some messages a little more. Also fixes some typos that slipped through the last commit.

A large change in text can be seen in EXI_DeviceMemoryCard.cpp. I added more info as to why a write to a memory card may fail. (This actually was a reason I was unable to write to a memcard recently).

Elaborations can be seen in WGL.cpp

I did change some comments in some files that I was correcting logging messages in, however this is only if I spot a typo or if an abbreviation is lower-cased. Even in that case, the amount of changes done to comments is very minimal.
2013-04-01 00:10:54 -04:00
Lioncash f432d6038e Fix some typos and correct some capitalizations in the log messages.
Makes the logging look more orderly and less spammy when spitting out things.
2013-03-31 19:13:30 -04:00
Pierre Bourdon 194ada2481 More MSVC 2010 build fixes 2013-03-29 07:55:56 -07:00
Pierre Bourdon 38db520617 MSVC 2010 does not have <mutex> or <thread> either, adding the Std* files back 2013-03-29 07:53:45 -07:00
Pierre Bourdon a8513e4605 Re-add StdConditionVariable, MSVC 2010 does not support <condition_variable> 2013-03-29 07:42:41 -07:00
Pierre Bourdon 4895e38bd5 This change might work better if I git add the files 2013-03-29 07:31:15 -07:00
Pierre Bourdon b73941c0ea Use libc++ for Mac OS X builds now that we require >= 10.7 anyway 2013-03-29 07:29:31 -07:00
Lioncash b1dd14c319 Fix a slight leak in LogManager.
m_debuggerLog wasn't ever deleted in the destructor.
2013-03-27 23:39:48 -04:00
skidau 7784fa4c67 Merge branch 'master' into wii-network
# By Ryan Houdek (185) and others
# Via degasus (12) and others
* master: (625 commits)
  Revert "Don't open/close file for every file operation." as it was crashing PokePark in Windows builds.
  Array overrun fixed in VertexShaderCache for the DX11 plugin.
  Fixed DSPTool build.
  Windows build fix
  Go back to assuming every HID device is a wiimote on Windows. Fixed issue 6117. Unfixed issue 6031.
  VideoSoftware: Improve fog range adjustment by using less magic and more comments.
  revert RasterFont for VideoSoftware
  ogl: fix virtual xfb
  Windows build fix from web interface...
  Adjusted the audio loop criteria, using >= on the Wii and == on GC.  This fixes the audio static that occurred in Wii games after hours of play.
  Forced the exception check only for ARAM DMA transfers. Removed the Eternal Darkness boot hack and replaced it with an exception check.
  VideoSoftware: Implement fog range adjustment, fixing issue 6147.
  implement 4xSSAA for OGL
  move ogl-only settings into backend
  Fix description of disable fog, and move it to enhancements tab.
  Reverted rd76ca5783743 as it was made obsolete by r1d550f4496e4.
  Removed the tracking of the FIFO Writes as it was made obsolete by r1d550f4496e4.
  Forced the external exception check to occur sooner by changing the downcount.
  Mark the Direct3D9 backend deprecated.
  Prefer D3D11 and OpenGL over D3D9 by default.
  ...

Conflicts:
	CMakeLists.txt
	Source/Core/Common/Common.vcxproj.filters
	Source/Core/Common/Src/CommonPaths.h
	Source/Core/Core/Core.vcxproj.filters
	Source/Core/Core/Src/Core.cpp
	Source/Core/Core/Src/IPC_HLE/WII_IPC_HLE_Device_FileIO.cpp
	Source/VSProps/Dolphin.Win32.props
	Source/VSProps/Dolphin.x64.props
2013-03-27 13:19:23 +11:00
Ryan Houdek 7034c79ab9 Big commit. Fix running the APK, I had missed a view in the manifest. Clean up the Android EGL context creation to fit more in line with how Dolphin works. This breaks input at the moment as well. Change the memarena from 768MB to 64MB to allow 1GB phones to potentially run it. Rename EGL_X11 back to EGL since this merge brings in some of soreau's changes to more easily allow different platforms like Wayland and Android. Not quite all of the code because some needs to be cleaned up still. 2013-03-24 21:06:34 -05:00
NeoBrainX bb3ce1f8d3 Mark the Direct3D9 backend deprecated. 2013-03-23 23:53:19 +01:00
NeoBrainX 816020f4eb Prefer D3D11 and OpenGL over D3D9 by default. 2013-03-23 23:52:30 +01:00
Ryan Houdek d11679a06e Android mega commit of trash. 2013-03-19 21:53:09 -05:00
lioncash edd9d0e0ef Clean up more space/tab mismatches in AudioCommon, Common, and VideoCommon.
Not planning to touch Core since it's the most actively changed part of the project.
2013-03-19 21:51:12 -04:00
Ryan Houdek 7d74293170 Fix a typo in ArmEmitter noticed by LionCash. 2013-03-18 08:45:33 -05:00
Ryan Houdek 9ae9910490 Finish up VFP cleanup. A few more instructions are left for VFP, and a bunch of NEON ones if it will ever be used. 2013-03-18 00:10:56 +00:00
Pierre Bourdon 612c2e8516 Fix converting the charset of an empty string. Thanks to MrData on the forums for reporting this issue. 2013-03-17 14:37:00 +01:00
Ryan Houdek 8c1091a21f Merge branch 'master' into GLSL-master
Conflicts:
	Source/Core/VideoCommon/Src/PixelShaderGen.cpp
	Source/Plugins/Plugin_VideoDX11/Src/VertexManager.cpp
	Source/Plugins/Plugin_VideoDX9/Src/VertexManager.cpp
2013-03-15 11:19:52 -05:00
Ryan Houdek e6c6053fcc Beginning of VFP cleanup. Will finish when I have the hardware in front of me. 2013-03-14 10:45:26 -05:00
Ryan Houdek b4830be9bc Actually set the bIDIVa value in the ARM CPUDetect. 2013-03-14 08:48:01 -05:00
Ryan Houdek c93f7760ce Really clean up all the emitter loadstores on ARM. If a ARM device supports VFPv4, then it supports IDIVA, so handle that in CPUDetect. 2013-03-14 01:50:38 +00:00
Ryan Houdek 202e2fa5c8 Add a new WriteNewStoreOp emitter function for beginning of rewrite of the Arm Emitter LoadStores. Will finish when I have the hardware in front of me to test on. 2013-03-13 14:08:54 -05:00
degasus 382be2aabd Merge branch 'master' into GLSL-master
Conflicts:
	.gitignore
2013-03-12 11:28:56 +01:00
Ryan Houdek 8406d9972d Fix JIT from rebasing on PPSSPP ArmEmitter. 2013-03-12 02:35:29 +00:00
Ryan Houdek b94b4a9e8f Rebase ArmEmitter on PPSSPP's base. The loadstores are making my heart cry at this point. 2013-03-11 13:57:55 -05:00
Ryan Houdek be217bf096 Add a comment about Qualcomm in load stores. 2013-03-07 20:28:18 -05:00
degasus 12e84f918a Merge branch 'master' into GLSL-master
this fix debug build
2013-03-07 17:05:32 +01:00
Ryan Houdek f3528277c4 Make sure to mask out the FPU rounding mode correctly. Good spot from LionCash. 2013-03-07 09:52:38 -06:00
degasus eaa5a77d9e fix debug build 2013-03-06 20:47:48 +01:00
degasus a1c5e90083 Merge branch 'master' into GLSL-master
Conflicts:
	CMakeLists.txt
	Source/Core/DolphinWX/CMakeLists.txt
	Source/Core/DolphinWX/Src/GLInterface.h
	Source/Core/VideoCommon/Src/PixelShaderGen.cpp
	Source/Core/VideoCommon/Src/TextureCacheBase.cpp
	Source/Core/VideoCommon/Src/VertexManagerBase.cpp
	Source/Plugins/Plugin_VideoDX11/Src/VertexManager.cpp
	Source/Plugins/Plugin_VideoDX9/Src/VertexManager.cpp
	Source/Plugins/Plugin_VideoOGL/Plugin_VideoOGL.vcxproj
	Source/Plugins/Plugin_VideoOGL/Plugin_VideoOGL.vcxproj.filters
	Source/Plugins/Plugin_VideoOGL/Src/GLUtil.h
	Source/Plugins/Plugin_VideoOGL/Src/PixelShaderCache.cpp
	Source/Plugins/Plugin_VideoOGL/Src/TextureCache.cpp
	Source/Plugins/Plugin_VideoOGL/Src/VertexManager.cpp
	Source/Plugins/Plugin_VideoOGL/Src/VertexShaderCache.cpp
	Source/Plugins/Plugin_VideoOGL/Src/main.cpp
2013-03-06 15:59:29 +01:00
degasus 8d5299c20b Merge branch 'vertex-loader-cleanup' 2013-03-06 14:08:02 +01:00
Ryan Houdek d6558e1c31 Make the (V)LDR/(V)STR instructions support negative offsets. This fixes a bug where Arm Jit couldn't load the top 33 FPRs. Also makes it so the core can access all GPRs, FPRs, and SPRs in ppcState. This increases VPS 15-20 on SSBM intro movie on ODROIDX 2013-03-06 01:51:59 +00:00
Jordan Woyak 2095641af0 OK, seriously, buildfix. I shouldn't even have commit access! 2013-03-05 16:17:45 -06:00
Jordan Woyak b34991c4c3 Buildfix for real. 2013-03-05 16:08:26 -06:00
Jordan Woyak fe3a54d7fd Buildfix! 2013-03-05 15:48:57 -06:00
Jordan Woyak 10d57a3402 Use standard binary multiple unit symbols for game size display.
Use integer math for the calculation as we cannot rely on floats for something as important as game size display!
2013-03-05 14:58:30 -06:00
Jordan Woyak f3f89e1d00 Merge branch 'master' into vertex-loader-cleanup
Conflicts:
	Source/Core/Common/Src/CommonFuncs.h
	Source/Core/VideoCommon/Src/VertexLoader.cpp
2013-03-04 15:47:56 -06:00
Jordan Woyak 814c2ffdfd Fix some leaking file handles and buildfix probably. 2013-03-03 19:20:35 -06:00
Jordan Woyak 989f0663eb Make "Crypto" file opening unicode-safe on Windows. 2013-03-03 19:14:13 -06:00
Jordan Woyak c07b8a6e37 Fix more of what I broke. 2013-03-03 17:08:41 -06:00
Jordan Woyak aeb4fc9846 Fix what I broke. 2013-03-03 02:12:24 -06:00
Jordan Woyak 6c8adf6130 Eliminate the wstring game name.
Some cleanup throughout related code. (try to make logic in ISOFile understandable by a human)
Encode strings in UTF-8 rather than somehow trying to determine the encoding in the GUI code.

Non-windows OSes temporarily broken.
2013-03-02 20:00:36 -06:00
Jordan Woyak 2b1af36900 Merge branch 'master' into windows-unicode 2013-03-02 15:33:32 -06:00
Jordan Woyak 2356e5c0e7 Eliminate some baseless restrictions in PointerWrap, mainly vector<string> not working. 2013-03-02 03:32:30 -06:00
Jordan Woyak b0630790c1 It's 2013! Why can't I use C++11 yet!? 2013-02-28 19:42:29 -06:00
Jordan Woyak dea1e2827d Open std::fstream in a unicode-safe manner. 2013-02-28 19:33:39 -06:00
NeoBrainX 1c9860246c Build fixes for everyone! 2013-03-01 01:14:10 +01:00
NeoBrainX 7682ed22c6 Merge branch 'master' into perfqueries.
Conflicts:
	Source/Core/VideoCommon/Src/VideoConfig.h
	Source/Core/VideoCommon/VideoCommon.vcxproj.filters
	Source/Plugins/Plugin_VideoDX11/Src/VertexManager.cpp
	Source/Plugins/Plugin_VideoSoftware/Src/Rasterizer.cpp
	Source/Plugins/Plugin_VideoSoftware/Src/Tev.cpp
2013-03-01 01:07:34 +01:00
Pierre Bourdon 07539b9a3f Fix a StringUtil regression from the arm-noglsl merge
Fixes issue 6048. Thanks to Starscream for locating the regression.
2013-02-28 13:12:35 +01:00
Jordan Woyak e82d976d2f Buildfix for non-legacy OSes. 2013-02-27 20:55:19 -06:00
Jordan Woyak 65683ebc64 Hopefully fix all filename handling to support Unicode. 2013-02-27 20:03:06 -06:00
Jordan Woyak 69f7671ee8 Fix "Common" to build with "Unicode" project setting. 2013-02-27 19:19:38 -06:00
Jordan Woyak 0ea458b4dc Add functions for converting between UTF-8/16. 2013-02-27 18:00:42 -06:00
Ryan Houdek f1d727cf13 Merge latest ArmEmitter changes from ppsspp while we're at it. 2013-02-27 11:53:24 -06:00
Ryan Houdek 8c779bb242 Ah. I blame vim on this typo entirely. 2013-02-27 10:26:32 -06:00
Ryan Houdek 717b976875 ARM Support without GLSL 2013-02-26 13:49:00 -06:00
degasus 4883fa268f Split VideoBackend::Cleanup from Shutdown.
First is called from ogl/d3d thread, second is called from emulation thread (x11...)
2013-02-26 16:42:32 +01:00
degasus 90ff648d00 shader cache based by git revision 2013-02-26 10:48:19 +01:00
Jordan Woyak bd14ad5300 Merge branch 'master' into vertex-loader-cleanup 2013-02-25 17:55:44 -06:00
Jordan Woyak 46adbfa9ed Merge branch 'real-wiimote-scanning' 2013-02-25 17:33:34 -06:00
Matthew Parlane c30b8c9eae Merge branch 'master' into wii-network
Conflicts:
	Source/Core/Core/Src/IPC_HLE/WII_IPC_HLE_Device_FileIO.cpp
2013-02-23 17:02:58 +13:00
Jordan Woyak 6a13a4e5ed Add template "swap" function to CommonFuncs. 2013-02-20 20:20:53 -06:00
Jordan Woyak e9232280c4 Fix OSX! 2013-02-20 17:35:41 -06:00
Jordan Woyak f3e91bc10d Hopefully kill a stupid warning on Windows. 2013-02-20 17:30:34 -06:00
degasus a629dea4dc Merge branch 'master' into GLSL-master
Conflicts:
	CMakeLists.txt
	Source/Core/DolphinWX/Dolphin.vcxproj
	Source/Core/DolphinWX/Src/GLInterface/WX.cpp
	Source/Core/DolphinWX/Src/GLInterface/WX.h
	Source/Core/VideoCommon/Src/TextureCacheBase.cpp
	Source/Core/VideoCommon/Src/TextureCacheBase.h
	Source/Plugins/Plugin_VideoDX11/Src/TextureCache.cpp
	Source/Plugins/Plugin_VideoDX11/Src/TextureCache.h
	Source/Plugins/Plugin_VideoDX9/Src/TextureCache.cpp
	Source/Plugins/Plugin_VideoDX9/Src/TextureCache.h
	Source/Plugins/Plugin_VideoOGL/Src/Render.cpp
	Source/Plugins/Plugin_VideoOGL/Src/TextureCache.cpp
	Source/Plugins/Plugin_VideoOGL/Src/TextureCache.h
	Source/Plugins/Plugin_VideoSoftware/Src/SWmain.cpp

damn mipmap_fixes ...
2013-02-18 18:49:20 +01:00
Jordan Woyak fa9aafeed8 Some cleanup of CWII_IPC_HLE_Device_FileIO:
The real file was never kept open for longer than a single operation so there was no point in dealing with it in DoState.
Saving the real path in the savestate was also probably a bad idea. Savestates should be a bit more portable now.
2013-02-17 13:37:01 -06:00
Jordan Woyak 3330842505 Let's not CreateDir an empty string every time CreateFullPath is used, logging an error every time. 2013-02-17 01:33:22 -06:00
Jordan Woyak 206fdde933 Remove the core count from the cpu info OSD message. It was often wrong and not rather important. 2013-02-16 23:48:20 -06:00
Jordan Woyak 53aec6c476 Fix OGL perf queries and make them not slow! 2013-02-16 19:30:24 -06:00
Matthew Parlane 3d480c088f Merge branch 'master' into wii-network
Conflicts:
	Source/Core/Core/Src/IPC_HLE/WII_IPC_HLE.cpp
2013-02-09 20:13:11 +13:00
Jordan Woyak 8ce58759e3 Remove some old nonsense. 2013-02-07 23:52:50 -06:00
Glenn Rice f7fa33f2d6 Fix remaining compiler warnings. 2013-01-31 15:29:29 -06:00
Matthew Parlane bca2cac640 keys.bin support added.
Remove hollywood id from config.
Tidy HLE_Device_es.h (maybe)
Added const params to crypto stuff.
2013-01-29 01:18:53 +13:00
Matthew Parlane 2dd077028f Merge branch 'master' into wii-network 2013-01-28 22:00:47 +13:00
Matthew Parlane ca4ea817e0 Merge branch 'master' into wii-network
Conflicts:
	Source/Core/Common/Src/CommonPaths.h
	Source/Core/Common/Src/FileUtil.h
	Source/Core/Core/Src/HLE/HLE.cpp
	Source/Core/Core/Src/PowerPC/Interpreter/Interpreter.cpp
2013-01-26 21:46:12 +13:00
Matthew Parlane a354f47f98 Fixes for POLL on Linux and Mac. 2013-01-26 18:22:58 +13:00
degasus d60cc373d1 Revert "Revert 30dd9c2 e9d00bf db5f4c8 and bff0fae"
This reverts commit d0301ca89d.

Conflicts:
	.gitignore
2013-01-24 16:11:07 +01:00
lioncash 2db0c4270e Fix a potential memory leak on non-windows systems.
Also added a FIXME to BPStructs.cpp and BPMemLoader.cpp
2013-01-24 08:21:08 -05:00
Rachel Bryk 196c2867ad Move DSP settings to dolphin.ini 2013-01-16 20:17:44 -05:00
Jordan Woyak 3cb4300439 Merge branch 'external-theme' 2013-01-16 19:00:19 -06:00
skidau 0a4272c96b Merge branch 'OpenAL'
* OpenAL:
  Changed SoundTouch to use float samples, allowing SSE to be used. Made the DPL2 decoder disabled by default. Re-added the audio hack used by the Accurate VBeam emulation option.
  Added a latency setting to the audio settings. Removed the Sample Rate setting.  It is now hardcoded to 48000hz (accurate audio timing).
  Skipped timestretching if the emulator is running below 10% speed to prevent buffer overflows.
  Removed the synchronisation between the CPU thread and the audio thread. Added code to detect and resume from buffer underruns. Disabled the ability to change the DPL2 option after the game has started. Fixed a memory leak that occurred in the DPL2 decoder. Fixed the OSX build.
  Build fix
  Added a Dolby Pro Logic II (DPL2) decoder in the OpenAL backend.  DPL2 audio is decoded to 5.1.  Code adapted from ffdshow. Added an option in the DSP settings to disable the DPL2 decoder in case Dolphin incorrectly detects a 5.1 audio system. Updated the OpenAL files to OpenAL Soft 1.15.1 in the Windows build.
  Removed the system timing hack which was activated when the Accurate VBeam option was enabled.
  Fixed the include directories in Audio Common for the Windows 32bit build.
  Fixed the include directories in Audio Common for the Windows build.
  Messed up the static include line
  Fix include paths and compiling in Linux. Externals soundtouch is 1.7.1, while Ubuntu 12.10 is 1.6.x. Externals soundtouch is compiled with integer samples, while ubuntu is compiled with float samples. Float samples is probably the more common route. If you're going to use soundtouch, you should probably use SAMPLETYPE instead of explicitly choosing short. This probably breaks the windows build since its includes aren't setup.
  OSX: typedef signed char BOOL
  OSX build fix
  Build fix
  Added audio time stretching by using the SoundTouch library.
  Implemented correct audio timing.
  OpenAL for Windows initial commit
2013-01-15 22:40:12 +11:00
Jordan Woyak a9ff3709e4 Attempt to make file searching stuff less crappy on Linux.
Supports a * search now.
2013-01-13 15:32:26 -06:00
Jordan Woyak 6f7b11b9be themes directory stuffs 2013-01-13 14:12:19 -06:00
Matthew Parlane 6e58c50065 Merge branch 'master' into wii-network 2013-01-13 15:13:56 +13:00
Lioncash dfc0c4b08d Fix two signed/unsigned mismatch warnings.
Also tidied up SDCardUtil - made the variables make more sense (typewise)
2013-01-11 19:38:04 -05:00
Matthew Parlane 465df943a5 Merge branch 'master' into wii-network 2013-01-12 00:01:27 +13:00
Matthew Parlane 9754fda516 Merge branch 'wii-usb' into temp merge branch
Conflicts:
	Source/Core/Common/Src/Log.h
	Source/Core/Core/Core.vcxproj
	Source/Core/Core/Core.vcxproj.filters
	Source/VSProps/Dolphin.Win32.props
	Source/VSProps/Dolphin.x64.props
2013-01-11 23:07:12 +13:00
Jordan Woyak 51a1d4cde7 Revert "Very tiny cleanup of ChunkFile.h."
int/size_t change without updating the rev# caused crash on Dolphin start

This reverts commit cf942450e0.
2013-01-10 17:41:12 -06:00
lioncash cf942450e0 Very tiny cleanup of ChunkFile.h.
Also changed the size parameter from DoVoid to size_t. As far as I know, that should never be negative.

Also changed the the count parameter of DoArray to size_t, this also should never be negative.

Got rid of some typecasts.
2013-01-10 17:38:38 -05:00
Jordan Woyak 4f4aa4860d Fix a currently unused unique_lock function. Thanks to Lioncash. 2013-01-08 16:50:09 -06:00
Jordan Woyak baa29f571c Fix incorrect iterator usage in BreakPoints::Clear 2013-01-08 15:02:50 -06:00
NeoBrainX 4925a28f94 PixelShaderGen: Shader uid maintainance 2013-01-08 18:56:01 +01:00
NeoBrainX b06f30f845 Remove the per pixel depth option.
Depth calculations are always done in the pixel shader now.

Due to the unpredictability of our zcomploc hacks this commit probably changes the behavior of some games which use zcomploc.
2013-01-08 18:16:48 +01:00
NeoBrainX 876eee5e60 PixelShaderGen: Don't disable depth texture emulation if z writing is disabled (this is what VideoSoftware is doing). 2013-01-08 18:16:48 +01:00
Matthew Parlane e8624cc0f2 Merge branch 'gdbstub' into wii-network
Conflicts:
	Source/Core/Core/Src/ConfigManager.cpp
2013-01-08 21:21:05 +13:00
Matthew Parlane 5b96fb766f Merge branch 'master' into wii-network 2013-01-08 21:18:48 +13:00
Matthew Parlane 0ec7ef4b99 Merge branch 'master' into gdbstub 2013-01-08 20:27:34 +13:00
Ryan Houdek d0301ca89d Revert 30dd9c2 e9d00bf db5f4c8 and bff0fae 2013-01-07 13:47:34 -06:00
skidau 6df1dacca8 OpenAL for Windows initial commit 2013-01-07 12:16:04 +11:00
Matthew Parlane b7fd1225ba Started gdb stub support. 2013-01-06 23:28:27 +13:00
Matthew Parlane 67d0e66af4 Add generate id support.
Add hollywood id to config file.
SSL and WC24 have their own logs now.
2013-01-04 22:36:44 +13:00
Glenn Rice 9b51c99c6b Make sure the null character is not included in the string. 2013-01-03 19:49:19 -06:00
Glenn Rice 12a606501c Fix the name and description truncation issue in a cleaner way. 2013-01-03 19:21:20 -06:00
Glenn Rice 3da05af30a Fix truncated names and descriptions in the game list on linux. 2013-01-03 10:35:07 -06:00
Matthew Parlane e0c9a1fd09 Merge branch 'master' into wii-network
Conflicts:
	Source/Core/Common/Src/CommonPaths.h
	Source/Core/Core/CMakeLists.txt
	Source/Core/Core/Src/Boot/Boot_BS2Emu.cpp
	Source/Core/Core/Src/IPC_HLE/WII_IPC_HLE_Device_es.cpp
	Source/Core/Core/Src/IPC_HLE/WII_IPC_HLE_Device_net.cpp
2013-01-01 23:28:46 +13:00
Matthew Parlane d3f199273b Fix warning level... someone let me commit this to master ;D 2013-01-01 19:23:45 +13:00
Matthew Parlane 86acde92e0 Merge branch 'master' into wii-usb 2012-12-30 17:09:35 +13:00
Matthew Parlane 539bf405f2 In memory of calc84.
http://dolphin-emu.org
2012-12-30 16:31:38 +13:00
Matthew Parlane 13bd235c11 Merge branch 'master' into wii-usb 2012-12-29 17:47:52 +13:00
Ryan Houdek 225d29f3f6 Fix this annoying warning in ChunkFile.h 2012-12-27 23:43:59 -06:00
rog 94116bf89c Always use the right user dir on windows. 2012-12-26 19:55:45 -05:00
Ryan Houdek 67c1c6b062 Merge branch 'GLES-software' 2012-12-26 12:54:58 -06:00
Ryan Houdek 01953ff64a Rename the interface files and hopefully fix OSX building. 2012-12-25 19:08:24 -06:00
degasus bff0faea2d Merge branch 'immediate-removal'
Conflicts:
	Source/Plugins/Plugin_VideoOGL/Src/Render.cpp
2012-12-25 12:39:00 +01:00
NeoBrainX e3e14af0dd Revert "VertexShaderGen: Fix a shader compilation error.". I'm an idiot :p
This reverts commit 4d868705fd.
2012-12-24 21:29:24 +01:00
NeoBrainX 4d868705fd VertexShaderGen: Fix a shader compilation error. 2012-12-24 19:50:16 +01:00
degasus 78ff8a769c Merge branch 'osx-savegame-fix' 2012-12-24 13:30:59 +01:00
Matthew Parlane f6418bd093 Merge branch 'master' into wii-usb 2012-12-24 12:58:15 +13:00
Matthew Parlane 59ec1fe180 Fix some random warnings. 2012-12-24 07:37:50 +13:00
degasus bd0abb3d2f revert last commit, add CheckInvalidState to VideoBackend 2012-12-23 13:32:23 +01:00
Matthew Parlane a8ddc3e069 Function definition was not updated. 2012-12-24 00:00:25 +13:00
Ryan Houdek 2db4549174 Fix a memory leak based on Lioncash's patches. 2012-12-18 23:35:28 -06:00
Ryan Houdek b78f5debe6 Initial push of GLES and GLUtil file breakup. 2012-12-17 14:54:20 -06:00
LPFaint99 351979795c revert changes to banner background color 2012-12-16 15:29:25 -08:00
Ryan Houdek 3b559d89ec If the HOME environment variable isn't set, fall back on to PWD. Closes 5584. 2012-12-14 11:47:12 -06:00
Ryan Houdek 532fdada96 Adds the Wii Korean settings file. It was handled in the wii-network branch in rev c42a6f156e. Master handles the settings files differently. Until wii-network merges in to master, this closes issue 5642. 2012-12-14 11:37:26 -06:00
degasus d0c4332d99 don't update vbo, if there are no changes in Renderer::Swap
Signed-off-by: Ryan Houdek <Sonicadvance1@gmail.com>
2012-12-13 15:28:13 -06:00
Glenn Rice e85438cba0 Clean up gcc/g++ compiler warnings that have accumulated. 2012-12-10 00:40:28 -06:00
rog 3d9712a99e Remove more unused code. 2012-11-26 03:48:04 -05:00
rog 97f5b1665f what is this even... 2012-11-26 02:11:52 -05:00
Matthew Parlane d8b879a4ee Movd back to libusb for full support on windows 2012-11-15 01:09:25 +13:00
Matthew Parlane 0caf693d1c Merge branch 'master' into wii-usb 2012-11-12 19:19:05 +13:00
sulokuTDCmago d032c40a58 - Added a new wilcard for importing savegames, which basically shows all saves (gci, gcs and sav). This is set as default (I really got frustrated of having to change the type every single time when making tests for GCMM, and I think it makes more sense at user level to just show all saves regardless the format)
- In icon retrieving I removed the "format check" as it shouldn't really matter to have mixed icon formats. Also removed the "Time splitters hack" as there's no reason for it since we are only checking the last 3 bits and I'm pretty sure having bits 1 and 2 set is the same as having them unset.
- Icon retrieving uses AnimSpeed as stop signal (every icon must have an speed set, the first speed that is 0 means there are no more icons)
- Also, in icon retrieving I added support for "blank frames"(Luigi's Mansion and Pikmin that I know of). With this the base for icon animation is complete.
- Fixed PSOIII savegame patch which was wrong before.

Signed-off-by: LPFaint99 <lpfaint99@gmail.com>
2012-10-29 21:02:59 -07:00
Sonicadvance1 5dd49edaec Badaboom. Add in Memory include to CDUtils.cpp 2012-10-30 02:45:42 +00:00
Sonicadvance1 8fed3b76c8 If setting videobackend back to null strings, Just set it to the front of the list. Fixes loading game specific INI files that don't load back the "default" video backend which is nothing. 2012-09-25 00:47:37 +00:00
Ryan Houdek b4ae200d0d This changes a mmap in MemArena so you don't need 786MB of memory free to actually allocate the 1GB memory space in Linux 32bit. I was also running in to this issue in my development. Kudos to plbl4ster to actually taking the time to research this. Closes issue 5625. 2012-09-23 10:08:13 -05:00
Pierre Bourdon 90af798d3d Partially revert be200074e9 for OS X systems
/dev/shm is not a tmpfs mountpoint on that operating system. Use /tmp but keep
the unlinking to avoid useless disk IO.
2012-08-25 03:30:37 +02:00
Ryan Houdek be200074e9 [Linux] Change from using /tmp to /dev/shm in MemArena so we don't cause any disk IO, also unlink file while it is open to allow multiple instances running. This was discussed months ago, but was never implemented for whatever reason. 2012-08-22 23:39:50 -05:00
Pierre Bourdon 54fc4029dd Use do { ... } while (0) for the *_LOG macros
Without this patch, such code would not compile:

if (cond)
    WARN_LOG(FOO, "msg");
else
    WARN_LOG(FOO, "msg2");
2012-08-20 13:12:49 +02:00
NeoBrainX 08a9c66037 Revert the recent zcomploc changes including the Graphic_Fixes merge.
Reason:
- It's wrong, zcomploc can't be emulated perfectly in HW backends without severely impacting performance.
- It provides virtually no advantages over the previous hack while introducing lots of code.
- There is a better alternative: If people insist on having some sort of valid zcomploc emulation, I suggest rendering each primitive separately while using a _clean_ dual-pass approach to emulate zcomploc.

This reverts commit 0efd4e5c29.
This reverts commit b4ec836aca.
This reverts commit bb4c9e2205.
This reverts commit 146b02615c.
2012-08-10 20:12:02 +02:00
sktsqrl 8dd11bd1c0 fixes issue 5507 2012-07-11 20:54:50 -07:00
Pierre Bourdon e550623b11 Added a button to dump the FakeVMEM from the memory debugger if the game uses it 2012-06-19 13:51:29 +02:00
Pierre Bourdon 988bd53b5f Support ANSI color codes in the console logger for Linux/Mac 2012-06-19 12:11:15 +02:00
skidau b0d271db3c Changed MOVDDUP to use MOVSD on non-SSE3 CPU's.
Added DMA wait time under DSP HLE mode.

Fixes Knockout Kings 2003.
2012-06-02 10:06:47 +10:00
Pierre Bourdon 1efabea9b4 Fix compilation errors with g++4.7 2012-05-26 08:09:50 +02:00
skidau 146b02615c Merge rodolfoosvaldobogado's zcomploc code (Graphic_Fixes branch) 2012-05-26 13:47:07 +10:00
nitsuja 99b202fd2e savestate vertexmanager (base) since it affects VertexLoader::RunVertices which affects g_pVideoData 2012-05-26 13:18:08 +10:00
nitsuja a81631b58e made savestates synchronous and immediate. this allows saving or loading while the emulator is paused, fixes issues where savestate hotkeys would get ignored if pressed too close together, might speed up savestates in some cases, and hopefully makes savestates more stable too.
the intent is to replace the haphazard scheduling and finger-crossing associated with saving/loading with the correct and minimal necessary wait for each thread to reach a known safe location before commencing the savestate operation, and for any already-paused components to not need to be resumed to do so.
2012-05-26 13:09:38 +10:00
nitsuja 152351d96c implement PointerWrap::Do(std::map<unsigned int, T>) 2012-05-26 12:59:07 +10:00
nitsuja aa674a65f1 implement PointerWrap::DoLinkedList and use it to simplify saving CoreTiming events 2012-05-26 12:59:06 +10:00
skidau a54e72640f Merge branch 'misc-speedups'
* misc-speedups:
  fixed and reenabled and slightly optimized the JIT version of fcmpo/fcmpu.
  slightly more precise speed percent display (this is really minor)
  a small thread synchronization speedup for dual core mode. it's most noticeable in games where the CPU is running behind compared to the GPU.

Conflicts:
	Source/Core/Core/Src/PowerPC/Jit64/Jit.cpp

The Fifo.cpp changes from rdaefb3b550e2 was not merged as there was no performance benefit.
2012-05-26 12:35:08 +10:00
Pierre Bourdon fdff4cb1ff Merge branch 'master' into wii-network
Conflicts:
	Source/Core/Core/Src/IPC_HLE/WII_IPC_HLE.cpp
	Source/Core/Core/Src/IPC_HLE/WII_IPC_HLE_Device_FileIO.cpp
	Source/Core/Core/Src/IPC_HLE/WII_IPC_HLE_Device_es.cpp
	Source/VSProps/Dolphin.Win32.props
	Source/VSProps/Dolphin.x64.props
2012-05-16 09:27:37 +02:00
Shawn Hoffman 26521aa66a force VolumeDirectory to align files to 32KB (only streaming audio files really need to be aligned...) 2012-04-23 00:50:44 -07:00
Matthew Parlane 0fc390b552 Modify state.dat before launching wads. Fixes Liight, maybe others. If in doubt, install the wad to the nand. 2012-04-21 16:21:13 +12:00
Jordan Woyak 722480cb2e Fix compilation with g++ 4.7 and some warnings. Fixes issue 5347. 2012-04-07 15:45:32 -05:00
Matthew Parlane 9bf67d4bb1 Implemented /dev/usb/hid as libusb, but this will not work on mac. Code started for using hidapi instead. 2012-04-04 19:53:05 +12:00
rodolfoosvaldobogado 5650b3b5f6 more fixes. take in account when depth textures are used and alpha test fails :)( i really forgot that). 2012-04-03 15:08:58 -03:00
rodolfoosvaldobogado 4fafbd0700 Fix for my last commit thanks to Lolaker for pointing the error 2012-04-03 09:56:11 -03:00
rodolfoosvaldobogado 6a446efd5f Second Stage: re implement zcomplock and correct all the logic error in PixelShaderGen.cpp. i disable fastzcomlock for the moment to avoid confusions.
please test for regressions
2012-04-03 00:08:36 -03:00
NeoBrainX 460610ea0e Revert Rodolfo's recent zcomploc commits until they actually work correctly.
This reverts commit 402006a83a.
This reverts commit 48d8d71391.
This reverts commit 450dcc9d2c.
2012-03-30 01:57:53 +02:00
rodolfoosvaldobogado 402006a83a more fixes to zcomplock and opengl implementation 2012-03-29 18:26:58 -03:00
Shawn Hoffman 2ee5e5cebc Merge branch 'scons-removal' 2012-03-28 00:02:04 -07:00
rodolfoosvaldobogado 450dcc9d2c As requested, this is my implementation of zcomploc using a multi-pass algorithm. My apologize to the others devs for committing in the main branch but is the only way to get this tested as soon as possible.
please test for regressions, speed and for other issues fixed, as a example, the black color in water splash in super mario galaxy are fixed with this rev.
please as soon as yo find a bug let me know.
2012-03-27 15:44:58 -03:00
Shawn Hoffman d15740daf1 Merge branch 'wxw3-update' 2012-03-25 12:27:38 -07:00
rodolfoosvaldobogado 9ed83765e6 long time no commits :)
a little code cleaning to avoid duplicated execution of AlphaPreTest and a little correction to some comments from the previous commits.
this change must behave exactly like last revision, if something is broken please let me know
2012-03-25 00:01:47 -03:00
Pierre Bourdon c662b8ee2f Bump the shader cache version 2012-03-24 20:46:40 +01:00
NeoBrainX 7a1744575d D3D9: Fix texel to pixel mapping when sampling textures properly. 2012-03-24 17:23:03 +01:00
NeoBrainX fee98b426b Revert r41bcf657f89d, r3a9fed0ba285, r9adc119e3c2f and re58692653afd (all of them are wrong). 2012-03-24 15:58:44 +01:00
Shawn Hoffman 36f3962551 small fix for last commit - didn't notice that was an #elif instead of #if 2012-03-22 18:57:30 -07:00
Shawn Hoffman 56b1373baf Remove scons-related files 2012-03-25 12:55:02 -07:00
Shawn Hoffman f7423a0a4f Merge branch 'master' into wxw3-update
Conflicts:
	Source/Core/DolphinWX/Src/LogWindow.cpp
2012-03-22 17:57:38 -07:00
skidau a60a0825a3 Merged 'FifoBusy' branch. Thanks
to marcosvitali.

Added an external exception check when the CPU writes to the FIFO.  This allows
the CPU time to service FIFO overflows.  Fixes random hangs caused by FIFO
overflows and desyncs like in "The Last Story" and "Battalion Wars 2".  Thanks
to marcosvitali for the research.

Added some code to unlink invalidated blocks so that the recompiled block can be
linked (speed-up).

This release still fixed the hangs produced by fifo overflow without sacrifice
performance. For example you can test Tutorial moves at the beginning of The last history now
is fluid 30/60.

Fixed possibles random hangs in DC mode.
Fixed hangs in DC mode in (Simpsons, Monkey Island, Pokemon XD, etc)
Implemented accurate management of Pixel Engine Interrupts.  Now the GPU loop
is stopped when a PE Interrupt needs to be managed and resumed when Pixel Engine
finish.

Fixed Metroid Prime 3 and 2 desync. And other games with desync because of
FIFO Reset. That happens because  FIFO_RW_DISTANCE_HI must be written first, for checking
fifo.CPReadWriteDistance == 0, so some fifo resets was not managed in the right
way.

Fixed Super Monkey Ball in some cases when the game write the
WriteReadDistance need to be safe like the SafeCPRead.

Improved the CheckException for the GatherPipe writes in JIT, now only the
External Exceptions are processed.

Fixed definitely Pokemon XD in dual core mode. This game is doing something
not allowed. It attach to CPU the same fifo attached to the GPU in multibuffer
mode. I added a check to prevent overwrite the GPU FIFO with the CPU FIFO. If
the game do that on breakpoint the solution can fail.

Fixed ReadWriteDistance calc when CPRead > CPWrite.

Added Token and Finish cause to GP Jit checking.

Additional cleanup in CommandProcessor.



Fixes issue 5209
Fixes issue 5055
Fixes issue 4889
Fixes issue 4061
Fixes issue 4010
Fixes issue 3902
2012-03-20 19:37:25 +11:00
Shawn Hoffman 483d15a9c3 fix Common lib re-linking all the time
rename wxBase28 project to wxWidgets
2012-03-18 05:47:55 -07:00
skidau cfbcaa2cc6 Linux build fix 2012-03-18 23:37:38 +11:00
skidau 8ed6ea3b07 Sped up the Dolphin debugger in JIT mode by splitting a block only while stepping or when it contains a breakpoint. The block is invalidated when a breakpoint is set or cleared.
Fixed a bug in the JitCache where the JIT icache was not being invalidated when a block containing the instruction was destroyed.
2012-03-15 21:48:19 +11:00
marcosvitali b0f75f17ae This release still fixed the hangs produced by fifo overflow without sacrifice performance.
For example you can test Tutorial moves at the beginning of The last history now is fluid 30/60.
Shuffle2: I've delete the hacky line, I think is not necessary anymore. Additional some clean in CommandProcessor.
Please test The Last Story and others games affected in the previous commits and give me a feedback.
2012-03-05 02:40:10 -03:00
Henrik Rydgard f5d4fe0bfe Fix some minor bugs pointed out by PVS Studio (thanks!) 2012-03-03 20:07:20 +01:00
Shawn Hoffman 6eb2cb2666 Merge branch 'master' into wii-network 2012-02-27 22:36:41 -08:00
Jordan Woyak ee09def802 Merge branch 'cpp11' 2012-02-28 00:28:13 -06:00
Jordan Woyak 38823b6371 Add comment here so people know what's up. 2012-02-28 00:27:16 -06:00
NeoBrainX c3293b1a1c Improvement to revision b8bef29bcc .. :P 2012-02-25 10:59:00 +01:00
skidau b8bef29bcc Fixed a divide by zero error in the hash functions 2012-02-25 20:36:49 +11:00
Jordan Woyak 8a8dc77ef1 enable c++11 compilation in cmakelists 2012-02-24 14:19:24 -06:00
Jordan Woyak f15aeb26b3 Use an auto typed variable in IniFile.cpp 2012-02-24 19:20:17 -06:00
NeoBrainX 3a9fed0ba2 PixelShaderGen: Fix a bug introduced in revision 9adc119e3c.
D3D11: Fix shader constant mapping.
2012-02-21 12:51:41 +01:00
NeoBrainX 9adc119e3c PixelShaderGen: For custom textures and scaled EFB copies, use correct texel to pixel mapping when sampling textures
(D3D9 only)

This is basically the same as revision e58692653a, just for scaled textures and with a LOT more work...
2012-02-20 20:32:08 +01:00
NeoBrainX e58692653a PixelShaderGen: Use correct texel to pixel mapping when sampling textures
(D3D9 only)

Fixes issue 2068.
Fixes issue 5158.
2012-02-17 17:09:17 +01:00
Shawn Hoffman bad1c7e67a fixup net/ncd/manage 2012-02-09 23:37:50 -08:00
Shawn Hoffman ac0883044e move SettingsHandler to Common lib 2012-02-09 21:04:07 -08:00
skidau 25eae39b7c Rearranged the SSE detection. Patch by lordlyhobo.
Fixes issue 5172.
2012-02-06 20:51:24 +11:00
LPFaint99 a0d6d68243 sysconf SetArayData use the minimum of the buffersize or the dataLength 2012-02-01 00:04:18 -08:00
calc84maniac 79ca43226c Added SHRD/SHLD x86 emitters, further optimized srawx 2012-01-09 00:10:13 -05:00
nitsuja 31ff1907a4 added an option to log to the attached Windows debugger (so e.g. NOTICE_LOG messages can show up in Visual Studio's output window) 2012-01-07 23:04:18 -08:00
nitsuja 9ab69febe5 fix for stack corruption caused by certain DSP LLE JIT ABI calls.
if you were getting crashes or freezes as a result of using the "DSP LLE on Thread" option, this might fix that.
2012-01-07 20:46:41 -08:00
nitsuja daefb3b550 a small thread synchronization speedup for dual core mode.
it's most noticeable in games where the CPU is running behind compared to the GPU.
2012-01-07 20:22:48 -08:00
calc84maniac 5a15d58964 Added emitters for BT/BTR/BTS/BTC x86 instructions, optimized extended arithmetic PowerPC instructions 2012-01-05 22:36:27 -05:00
nitsuja 39613a95a8 initialize the uninitialized 2012-01-04 01:36:09 -08:00
nitsuja 81a1efab8e fixed an issue where the CPU sometimes single-steps an extra time after pausing 2012-01-04 01:33:38 -08:00
skidau b9547a07f5 Updated the Gecko code handler to the latest version from Gecko OS 1.9.3.1.
Added a check to ensure that the number of codes fits in memory (maximum 231 codes).
Store a copy of codehandler.bin in the Sys directory.
2012-01-03 01:24:17 -05:00
skidau 69b2d4ddc1 Changed the Gecko code handling to the native code handler. This provides full compatibility with all Gecko codes.
To use the native code handler, place the kenobiwii.bin file into the Sys directory.  Dolphin will silently fall-back to the emulated code handler if the file is not there.

Fixes issue 4561.
2012-01-03 01:24:14 -05:00
Pierre Bourdon 59e93bff78 Fix a crash at startup with Dolphin on Linux compiled in debug mode
Use the clobber list instead of the stack to save rbx when executing the cpuid
instruction with inline assembly. This avoids breaking GCC assumptions about
the stack pointer location.
2012-01-02 00:59:37 +01:00
nitsuja f0d7b8122f increased fault tolerance of shader cache files.
more specifically: if the emulator stops unexpectedly, it is quite possible that one of the shader cache files will have some bytes near the end that never got their values filled in. this change adds an index number at the end of each entry as extra verification that the entry is valid, so that invalid entries can be ignored (and eventually overwritten) instead of causing crashes.
2012-01-01 14:28:20 -08:00
skidau 1df7af35e9 Reset errno to zero before testing it after the strtoul call. Fixes issue 5078. 2011-12-29 12:05:36 +11:00
LPFaint99 de4e3e7462 add wstring name(s)/description to the cachefile, use when available in gamelist and properties window 2011-12-18 22:01:46 -08:00
nitsuja c68c8c388c made savestate loads less fragile by adding some markers and rolling back on a mismatch.
This should make it so if you try to load an incompatible save, it simply doesn't load, instead of crashing dolphin. (I can't guarantee no crash but it's much less likely now)
2011-12-18 00:22:06 -08:00
Maarten ter Huurne ed1bfdf293 Merge branch 'cmake-osx2' 2011-12-17 16:30:02 +01:00
Maarten ter Huurne 27bda2c054 Fixed range check on TryParse() for u32, again.
The code from 748be364e5 incorrectly accepted -0x100000000 on x86_64.

Also if ERANGE is returned by strtoul(), reject the parsed value regardless
of what that value is. This fixes invalid values being returned when compiling
with Visual C++. Thanks to "cotton" for testing this.
2011-12-13 02:08:34 +01:00
Maarten ter Huurne ee5a29e6f2 For CPUID, save EBX on the stack instead of in a register.
This fixes GCC running out of registers when compiling for x86
in release mode.

Thanks to kiesel.
2011-12-12 02:14:56 +01:00
Maarten ter Huurne 7423c74deb Force the "ebx" argument to be mapped to a register (not necessarily EBX).
Fixes crash on x86 under OS X.
Thanks to kiesel for the fix and to shuffle2 for remembering the problem.
2011-12-12 00:43:23 +01:00
Shawn Hoffman b0ffa72e37 Merge branch 'large-mram' 2011-12-10 18:48:35 -08:00
Maarten ter Huurne 748be364e5 Fixed range check on TryParse() for u32.
On x86-64, "unsigned long" is 64 bits wide, so it is possible for a number
to not trigger a range error on strtoul() but still not fit inside an u32.
An extra check is added to ensure that 32-bit and 64-bit builds will accept
the same numbers.
2011-12-02 02:24:43 +01:00
Maarten ter Huurne 29865e6366 Avoid virtual memory range collision between JIT and emulated RAM.
Passing MAP_FIXED to mmap causes already mapped pages in the requested
region to be replaced. On Mac OS X this caused pages for JIT-generatd
code to appear in the memory range previously auto-allocated for the RAM
of the emulated machine. This led to a hang at boot time. The same problem
can probably occur on FreeBSD, but not on Linux since MAP_32BIT is used
there instead of MAP_FIXED.

The solution is to not use MAP_FIXED, but instead rely on the OS honoring
the hinted address which is below 4 GB: we don't need an exact match,
just a low address.
2011-11-30 00:37:57 +01:00
Shawn Hoffman b62cac2ca9 Allow modifying main ram size at compile time by changing Memory::REALRAM_SIZE. 2011-11-27 19:52:05 -08:00
Shawn Hoffman d8def74dd1 add portaudio headers and windows static libs to Externals, enable by default in windows build. 2011-10-03 23:45:59 -07:00
Jordan Woyak d3e639a397 fix build issue with intel compiler and fix some unsafe string usages, patch by FilthyMonkey 2011-10-01 21:31:43 -05:00
NeoBrainX 0e1383b788 Bump disk cache version. 2011-09-29 22:55:28 +02:00
NeoBrainX 81c614fa07 Clean up various things. 2011-09-29 23:32:39 +02:00
NeoBrainX 5dcb212fc7 Fix Windows build. 2011-09-29 23:32:38 +02:00
NeoBrainX 8c691767da Various changes which improve FreeBSD support.
Patches by martymac, all credits go to him ;)
2011-09-29 23:32:38 +02:00
NeoBrainX b28348066e Improve the shader UID debugging stuff and merge it to VideoCommon, effectively enabling it in D3D9 and D3D11 as well. 2011-09-09 00:32:04 +02:00
NeoBrainX 349a3ae91d Merge remote-tracking branch 'remotes/origin/master' into new-shadercache-uids 2011-09-08 02:14:18 +02:00
NeoBrainX 6c7bda6851 Various fixes and cleanups. 2011-09-08 02:09:44 +02:00
NeoBrainX 3939f9595a Add runtime checks to make sure we aren't overoptimizing the pixel shader cache. 2011-09-07 21:15:09 +02:00
Shawn Hoffman 95517a9741 vs2010: Disable LTCG for realz 2011-09-05 09:43:23 -07:00
Shawn 7f56842a79 fixup scons (osx) to generate scmrev.h and build.
hopefully this will be the last code change committed directly to master for a while... :/
next is cmake to replace scons on osx hopefully. pointers anyone? (soren?)
2011-08-23 03:50:06 -07:00
Jordan Woyak 1528c95fe9 Remove hash from revision description for cmake and windows. 2011-08-22 20:06:17 -05:00
Jordan Woyak 6a80b9989a remove hash from rev description 2011-08-22 13:11:45 -05:00
Jordan Woyak a910f97c39 minor cleanup of make_scmrev.h.js 2011-08-22 13:11:42 -05:00
Shawn Hoffman cdaa5ea5d2 make sure the jscript is actually executed at build time 2011-08-21 20:00:30 -07:00
Shawn Hoffman 82dfee1642 make_scmrev.h.js needs to compare the full file instead of just the HEAD hash.
remove refs to deleted files from Common project
2011-08-21 19:53:09 -07:00
Shawn Hoffman fc12633055 Make the jscript for writing out scmrev.h work on windows.
Add scmrev.h to .gitignore
Remove some SubWCRev.exe and it's template
2011-08-21 19:15:50 -07:00
Jordan Woyak e8fe15c3f7 Make titlebar and about dialog fancy for cmake build.
Windows needs fixing.
2011-08-21 17:43:05 -05:00
Shawn Hoffman 6bc81f5ac4 git compat:
add git support to cmake and make_svnrev.h.js
add .gitignore
2011-08-14 13:17:57 -07:00
Shawn Hoffman 82b635b799 vs2010: build dsptool again
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7681 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-07-17 08:38:08 +00:00
Glenn Rice b853d7de3d Oops. Forgot to add the CriticalAlert definitions for windows.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7679 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-07-15 16:50:54 +00:00
Glenn Rice a5a45992ad Add a new type of message box (CRITICAL style) which can not be disabled. Then use that message box to display shader compilation errors in the OpenGL backend to maintain consistency with the behaviour of the DirectX backends.
Also fix the wxMessageAlert called from non-gui threads in the WXGTK build to use the passed caption.

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7678 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-07-15 14:49:34 +00:00
Shawn Hoffman 2b9b4a3306 Make PatchAddEdit complain and not modify entry if fields are invalid instead of just filling in zeros. Fixes issue 4291.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7672 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-07-09 21:00:30 +00:00
pierre 383d12185f JIT: Use RAX instead of INVALID_REG for offsetOrBaseReg in MScaled
Fixes asserts triggering in WriteRex with 32bits.

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7656 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-06-30 19:17:53 +00:00
pierre 6cdb40a194 JIT: Add support for memory accesses with scaled index register but without base register
This is mostly useful for removing SHLs by constant 1, 2, 3, which this
commit implements in one place.

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7652 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-06-29 22:40:01 +00:00
Shawn Hoffman 2309e36b28 Revert changes made for 3.0 release 2011-08-20 14:05:43 -07:00
NeoBrainX 35d1599724 Tag Dolphin 3.0
git-svn-id: https://dolphin-emu.googlecode.com/svn/tags/3.0@7615 8ced0084-cf51-0410-be5f-012b33b47a6e

3.0: Removed SVNRevGen stuff; changed revision string to 3.0; Removed installer since it was vastly outdated; Bumped CMake major version to 3

git-svn-id: https://dolphin-emu.googlecode.com/svn/tags/3.0@7616 8ced0084-cf51-0410-be5f-012b33b47a6e

3.0: Add the languages which were chosen to be release-worthy.
Uhm, unless I forgot something important, I guess we can declare 3.0 as officially released now and stuff. Cheers ;)

git-svn-id: https://dolphin-emu.googlecode.com/svn/tags/3.0@7617 8ced0084-cf51-0410-be5f-012b33b47a6e

3.0: Fix SCons build

git-svn-id: https://dolphin-emu.googlecode.com/svn/tags/3.0@7627 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-06-23 23:11:12 +00:00
LPFaint99 1d29204ae6 Windows: Sets the cwd to the folder that dolphin.exe resides in.
Removes the ugliness that was the portable file, and now creating a shortcut or file association is less of a pain
it is still necessary to modify the file association from ".../dolphin.exe" "%1" to ".../dolphin.exe" /e "%1"

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7593 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-06-11 20:45:09 +00:00
NeoBrainX 8244efcc02 Revert r7421 and r7422.
Should fix issue 4413.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7592 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-06-11 19:37:21 +00:00
pierre 3bcb406c46 Improve WII state saves by saving /tmp and IPC request/reply queues
mp3:c stores temporary files in /tmp and needs them restored to
resume properly.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7564 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-05-27 19:55:07 +00:00
Rodolfo Osvaldo Bogado 0e225a5ad1 some code cleanup i have left in my folder :)
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7560 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-05-25 18:14:29 +00:00
LPFaint99 e4fa493a27 Adds the option to change the path to the wii nand root
when nand root is changed the current sysconf is saved,
and the sysconf in the new location is either loaded (if exists)
or the default sysconf is created
wii menu item is updated when the root changes
small fix to saving gamelist paths to .ini paths that are removed from the gui are now removed from the ini instead of simply changing the number of paths

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7555 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-05-24 19:12:18 +00:00
LPFaint99 1236e584e0 NAND:Consolidate Wad/Directory loading in CNANDContentLoader to one function
add ticket to CNANDContentLoader
move wad installer to CNANDContentManager
system menu can now be launched from a wad file without being installed first, (return to system menu from another title will still only work if system menu is installed)
cdb.vff: flushed to disc immediately, creates if the file exists but is too small, moved creation to Boot_WiiWad

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7530 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-05-09 05:47:29 +00:00
LPFaint99 423db843b7 typo/ put back a log that i removed
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7522 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-05-07 03:52:32 +00:00
LPFaint99 69645d421b Move the HLE hack of setting.txt file redirection to the BS2Emu
we already copy the file to memory here, now we also copy the file to 
1/2/data/
 This should really fix issue 4287.
Thanks to hosigumayuugi for finding the exact cause of the issue

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7521 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-05-07 03:48:27 +00:00
LPFaint99 c88126233b Update the country code in SysConf when wii system language is changed.
remove annoying assert for invalid loaders on disc titles.
Fixes issue 4287.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7514 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-05-05 22:38:07 +00:00
pierre 35026f9de1 Core/Common: Allow LEA(32,...) with M() OpArgs exceeding the 2G range.
Fixes JitIL in debug builds.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7478 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-04-22 15:51:40 +00:00
Glenn Rice 37beef5a35 Fix sysconf generation. Fixes issue 4348.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7449 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-04-11 15:57:45 +00:00
Jordan Woyak 021193b22f Use mutexes in LogManager to make it threadsafe, as suggested by beistin's patch. Change some LogManager function names to be consistent with Dolphin's naming conventions.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7433 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-04-01 07:43:02 +00:00
nakeee bebd66078f Create sys conf if it doesn't exists instead of asking questions
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7427 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-31 11:07:31 +00:00
Jordan Woyak 306c3570d1 Eliminated a memcpy in DX11's vertex shader disk cache loading. Maybe games will boot faster now, who knows?
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7422 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-30 10:46:27 +00:00
Jordan Woyak f8620fcd0b Fixed some memory leaks. Only one was mine ;P
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7392 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-22 07:27:23 +00:00
gnick79 017735b9ff * GUI Video-Settings changes:
- Removed recent ghanges about separate per-game Video Settings
  - Added "One Window 3-State Support" (very close to full implementation)

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7391 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-21 19:57:31 +00:00
Jordan Woyak 068855bbd6 Moved per-game graphics configuration to the game-list right click menu. It will be too difficult to make the "profiles" drop-down thing work with 3-state vs 2-state checkboxes. The per-game settings now have "undetermined" states, except for the radio buttons(I'll fix that later). It's super hacky right now. Video config (probably all config stuff) could be redone.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7386 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-21 05:46:33 +00:00
Soren Jorvang 215baff4c8 Simplify the SCons build:
With wxWidgets 2.9.2 now in Externals, SCons was the only
external dependency other than Xcode and building just SCons
from Macports caused a fair mount of extra stuff to be built
unnecessarily, so just include a copy of scons-local.

Always build wxWidgets from Externals which allows us to get
rid of the home-grown autoconf machinery in SconsTests.

The main use case for args.cache was the wxconfig option,
which is no longer relevant after the above changes and
caching options has a lot of potential for confusion,
especially since other build systems don't tend to do this,
so we no longer do it now.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7381 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-20 18:35:07 +00:00
j4ck.fr0st 205637ccc3 Hide DX11 on WinXP (fixes Issue 3719)
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7379 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-19 12:58:55 +00:00
Soren Jorvang 9198e83ae1 Hack Misc.cpp into building on OS X.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7362 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-16 22:58:24 +00:00
sl1nk3.s 571013acd8 Fix the video software backend. (closes issue 4269)
Some warning fixes and cleanup.

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7361 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-16 22:48:17 +00:00
Jordan Woyak 2692ba2697 Make "GetLastErrorMsg" thread safe.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7359 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-16 21:08:20 +00:00
Jordan Woyak 41c98f982e A bit of cleanup to Core Init/Stop, Frame, and Main. Cleanup XAudio2 to attempt to fix the crash on stop(didn't help :p). For some reason CFrame::DoStop is called twice.(might be the issue)
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7353 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-15 23:09:12 +00:00
Soren Jorvang bfe7b028ce pthread_mutexattr_t's must be initialized before the type can be set.
Fixes issue 4243.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7344 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-14 15:06:06 +00:00
Jordan Woyak 26b6a9af61 The data from strdup must be deallocated with free, not delete. I got rid of that ugly strdup and replaced the A though Z cdrom drive letter searching with Windows API stuffs.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7335 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-12 06:50:20 +00:00
Glenn Rice 0cc8eda124 Re-enable the std::mutex try_lock on linux and use it for the Host_GetKeyState keystate_lock mutex. This reduces the number of application crashes on linux during emulation.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7334 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-12 01:19:04 +00:00
Glenn Rice 1b583a0441 Fix things so that those who wish to compile with -std=c++0x can. To active this with the cmake build add CXXFLAGS="-std=c++0x" before cmake on the command line, or export that variable. This enables the experimental features like std::thread, std::mutex, etc., that are provided by g++ instead of using the implementation in dolphin.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7333 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-12 00:01:33 +00:00
Glenn Rice 5706abf4a1 Hack up hack number 7328, just to get things to compile.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7329 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-11 12:56:26 +00:00
Jordan Woyak 59fd1008ca Wrapped fopen/close/read/write functions inside a simple "IOFile" class. Reading, writing, and error checking became simpler in most cases. It should be near impossible to forget to close a file now that the destructor takes care of it. (I hope this fixes Issue 3635) I have tested the functionality of most things, but it is possible I broke something. :p
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7328 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-11 10:21:46 +00:00
Soren Jorvang 4f69672b2b Remove the need for the less than standard strnlen()/strndup().
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7326 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-11 00:37:37 +00:00
Nolan Check 6e348a2731 DX11: Add real XFB mode support. May not work perfectly yet. I'm working on a set of fairly big VI-related changes. When I'm done, it should improve animation smoothness for all the backends, especially when virtual or real XFB mode is enabled.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7319 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-08 07:39:36 +00:00
gnick79 89f636cc08 - Little fix on CPUDetect.cpp about the correct detection related to new AVX extensions (bug/fix reported&suggested by debian.micove)
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7314 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-07 16:12:20 +00:00
Jordan Woyak 5f87642f23 problem: TryAcquireSRWLockExclusive requires Windows 7 :/. solution kinda: use std::recursive_mutex (CriticalSection on windows) where try_lock is used. Dolphin should work on Vista x64 again.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7313 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-07 00:16:38 +00:00
Glenn Rice a734b3f057 Somewhat experimental. If the SYSCONF file is not found or is invalid then generate one. For now ask the user if this should be done. The generated SYSCONF file works for me with the games I have tested, but this needs further testing. Unfortunately, most users will never use this as they will have the SYSCONF file anyway. Eventually we could perhaps remove the distributed SYSCONF, and generate it the first time dolphin is run.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7311 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-06 16:57:58 +00:00
Jordan Woyak 9095dad009 Fix preprocessor prob.(recursive mutexes were being used where not necessary) Hopefully fix Common::Event to handle spurious wakeups since it uses condition variables now.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7307 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-06 00:52:04 +00:00
Glenn Rice 7bc2ae01f2 Fix Common::Barrier and fix the deadlock by making Common::Event check to see if an event has already been set or not.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7305 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-05 22:17:28 +00:00
Glenn Rice 024a87af7a Fix the Host_GetKeyState deadlock caused by Billiard's latest changes.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7304 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-05 21:58:54 +00:00
gnick79 4f0705fd70 * Italian translation update
+ minor GUI adjustements, CPUID Detect cleanup... video profile selection is disabled if a game is running

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7302 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-05 16:36:47 +00:00
Jordan Woyak 423018f811 Replaced Common::CriticalSection with a std::mutex implementation. 64bit Windows builds now use SRWLocks and ConditionVariables(requires Vista/7, x64 builds will no longer work on Windows XP x64). Tell me if you hate that. Removed Common::EventEx. Common::Event now uses a std::condition_variable impl.(using ConditionVariables on Windows x64, Events on x86, or posix condition variables elsewhere). I experience slight speed improvements with these changes.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7294 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-05 06:11:26 +00:00
Rodolfo Osvaldo Bogado c569b33829 First Revert my changes to VertexLoader.cpp, i don't own the games that get error so i revert the changes until i can test it myself.
Second:
A experiment. implemented parallelization in texture decoding using openmp. is most a experiment to test the performance in different os/plataforms. in my system (windows x64 amd 1055t) give a speedup in large textures, but i tested in in intel dual core and gives a slowdown. o i limited the use for large textures and cpus with more than 3 cores.
please test an let me know if it improves or degrades the speed.
please for linux and osx user. to enable this you will have to enable your compiler support for openmp to test this code.

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7284 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-04 22:48:54 +00:00
Glenn Rice 756c40163d Merge the log window CreateGUIControls and LoadSettings methods. This allows the settings from the ini file to be applied when the controls are created rather than setting a default, and then changing the settings later. In particular word wrap is applied when the text control is created. This works around the crash at application start that users are reporting in issue 4196.
Also change the for loops in SysConf to use iterators to placate godisgovernment and billiard. :P


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7283 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-03 22:47:48 +00:00
Soren Jorvang 05719ac81a Move SConscript files out from the Src subdirectories to be
consistent with the other build systems.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7282 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-03 19:44:56 +00:00
Soren Jorvang 540238cf79 Prepare for the release of Xcode 4, which has working LTO
with static libraries.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7280 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-03 04:35:03 +00:00
Glenn Rice 1ae59b6dc3 When reloading the sysconf file make sure that the m_Entries vector is cleared.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7278 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-03 01:15:25 +00:00
Shawn Hoffman bda0794adb Reload sysconf file on stop in order to preserve changes committed during emulation
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7277 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-03 00:07:33 +00:00
Glenn Rice 12cd2d41ec Change YieldCPU to sleep(0) like on windows. Time trials show this to be the most effective. Also, when using usleep(1) and dsp on thread the emulator is painfully slow. With the old _mm_pause() the emulator hangs on shutdown. With sleep(0) the emulator is faster, and doesn't hang on shutdown.
Also fix a possible undefined operation (according to gcc).


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7275 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-02 22:19:56 +00:00
Glenn Rice df809630c5 Pass std::string's by reference when possible.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7268 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-01 05:16:32 +00:00
Glenn Rice a5b471f490 More conversion from char * to std::string.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7266 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-03-01 03:06:14 +00:00
Glenn Rice ba54fac9eb Convert GetUserPath to return a std::string instead of a const char *. This simplifies its usage in most cases.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7265 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-28 20:40:15 +00:00
Rodolfo Osvaldo Bogado ccc12c6950 a little simplification for the dlist id and a little correction to YieldProcessor in windows.
in windows sleep(0) behaves more like what is defined in the yield instruction so use it instead. In my amd 6 core system brings a nice 8% speedup so please test I'm interested in knowing the behavior in different systems.

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7261 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-27 18:06:55 +00:00
skidau 960748b184 Added an option for opening up the wiki entry in the compatibility list. The option is in the right click menu of the games list. The game entries in the wiki are currently manually added by the administrator.
Based on an idea by JPeterson.

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7250 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-25 23:33:11 +00:00
Glenn Rice 992f8be5b0 If video backend initialization fails, have the emulator die gracefully instead of crashing the application. Also a little clean up of the passage of the video window handle to the backend and back.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7248 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-25 21:14:13 +00:00
Rodolfo Osvaldo Bogado eef715b1cf added the possibility to allocate aligned memory, an use it to allocate the buffer utilized in texture decoding, this will make a little easy to use aligned writes when possible in sse2/3 optimized algorithms.
some code additions for future use ;).
please gcc user test this as i don't have opportunity to test it myself i only use reference code to.

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7247 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-25 20:35:05 +00:00
Soren Jorvang 7c959d9655 vector::erase needs a non-const iterator.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7243 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-25 12:27:38 +00:00
Shawn Hoffman 832df18c0f more memcheck stuff
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7242 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-25 11:03:49 +00:00
Shawn Hoffman d7a9dc7df8 debugger: better saving/loading of breakpoints/memchecks to file
no more softice style :(

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7240 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-25 09:35:56 +00:00
Glenn Rice 2f14598687 Clean up the debugger gui a bit. In general do not call SetSizeHints on a window unless it is a top level window. It isn't supposed to do anything for non top level windows, but it causes glitches on linux. Removing these calls does not affect the end result on windows.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7233 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-24 05:05:25 +00:00
Glenn Rice 1eaad0966c Still didn't quite have the wiimote connection stuff right. This probably needs to be heavily revised.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7232 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-23 16:00:01 +00:00
Soren Jorvang 2b6a8c1cf8 Build Speaker.cpp.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7226 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-22 14:06:06 +00:00
Shawn Hoffman 6e4923399e revert r7212 (express users must modify a single line, instead)
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7220 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-21 15:17:41 +00:00
Shawn Hoffman 62cb8ebe46 Force dolphin to use the windows7.1sdk (the windows7.1sdk installer is silly and refuses to recognize that vs2010 exists).
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7212 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-20 18:08:20 +00:00
Soren Jorvang 1795da46ab std::locale("") seems to be broken not only on OS X, but also
on FreeBSD and Linux when building with clang.

I think it would be best to only use wxWidgets for localization.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7207 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-19 22:06:29 +00:00
pierre e57406dbcc Core/Common: Add support for low 8 bit parts of SI,DI,BP on 64 bit in x64Emitter
In addition protect against their use on 32 bit and the use of [ABCD]H
together with a REX prefix on 64 bit.

This assumes that the customOp parameter of WriteREX and operandReg of
OpArg always are registers, and thus needs to give something valid to
WriteREX when that is not the case (WriteShift).

In addition to the patch i sent to the ML, there are a few changes to the
error reporting(mostly whitespace).



git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7202 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-19 14:20:52 +00:00
Marcos Vitali c7ae0eb0d1 Big Fifo Commit Part2: Now the fifo is more stable than my first commit, so is time...
- ReImplementing Single Core Mode like Dual Core Mode Style.

- Stage 1: My goal is, we have the Fifo, CommandProccessor code the more clear, maintenible and documented possible. When I quit dolphin I want any developer can continue with the work only reading the code.
	
* Big Refactoring: A lot of functions was changed the names, and modularized.
Now the FifoLoop and CatchUpGPU does not exist, was replaced by RunGpu() and RunGpuLoop().
The general idea is modeling the code like the real HW. The fifo is only a buffer where the Write Gather Pipe write the commands and from the Graphic Processor read these.
* Big Clean UP a lot of obsolete code and comments was deleted, like DcFakeWachDog, "Fifo very soon hack", etc.

In the stage 2, I will refactoring more code doing emphasis in the division of CommandProcessor, Fifo, Gpu Emulation. Beside I will comment all functions and variables in the code (Don't worry I will ask for English help for this part ;) )

Please test a lot SC mode and DC mode :)
Thank you so much for testing always and the patience. I don't like broke your favorite game but... you must believe me this part is very sensible, I only try to contribute for have a better and stable dolphin emulator.

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7185 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-17 04:25:21 +00:00
Soren Jorvang d19c97dbe1 The pkg-config name of libpng is "libpng", not just "png".
Things break if both a shared and static libpng are linked
in, presumably because it has some global state. Several of
the gtk-ish libraries often, but not always, link in libpng
transitively, so it is important that we find it ourselves
first, even if it is not in the linker's search path.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7178 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-15 21:27:15 +00:00
Glenn Rice 0ae8d33149 Some work on changing comments, log messages, and variable and function names to reflect that the plugins are not plugins anymore.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7170 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-14 02:18:03 +00:00
NeoBrainX b776ac3d6f Add per-game "configuration profiles" for video backend configuration:
This allows ALL settings in the gfx configuration dialog to be adjusted _per game_ in a more user-friendly way than before.
Obsoletes the gfx related options in the ISO properties, but I kept those since the configuration profiles use different ini file keys (i.e. convert the game inis to the new naming, please!).


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7167 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-13 22:36:12 +00:00
Marcos Vitali be193088ca - FIX RE0 GFX fifo errors :D
- This game read the CPRead pointer when the GP is processing data and after detach the fifo  and attach again an use this pointer for continue, so implement fifo.SafeCPReadPointer pointer.
- fifo.SafeCPReadPointer is updated when (FAKE_GetFifoEndPtr() - g_pVideoData) == 0) to have a pointer without GFX Commands Cut in the beginning of 32 block.
- Reset video buffer when the CPReadWriteDistance is written by the software.
- This commit is experimental please test a lot your games.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7165 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-13 15:08:37 +00:00
Marcos Vitali 05feabdb49 - Reimplemented FifoReset in other way, only call to GPFifo::ResetGatherPipe() ResetVideoBuffer() in FIFO_RW_DISTANCE_LO when this is equal to "0"
- In the Command Processor Control Register when GPReadEnable is OFF, wait until the fifo lopp finish with thi actual 32 bytes block. This is necessary to have Safe Disabble GP Read in this way AbortFrame is performed by the software, beside this can help to have accurate GPReadEnable OFF.
Please test Metroid Prime 1/2, Guilty Gear XX, X men gc, SMG, and shuffle you can test Harry Potter Prince for WII. :)

PD: The fifo code need a clean very soon.

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7158 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-13 02:21:11 +00:00
pierre e81ccd7f33 Common: Change cpuid code again
Looks like compilers tend to use EBX for parameters if not told otherwise and
don't bother to update SP in leaf functions, so PUSH/POP kill local variables.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7151 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-12 18:40:02 +00:00
smelenchuk b0fa0a83f8 * Dump AVI output on every VI (fixes issue #4064).
* Add audio dumping (fixes issue #1638).


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7131 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-11 18:59:42 +00:00
Shawn Hoffman e480ab2b10 drop vs2008 projects in favor of vs2010
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7129 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-11 15:43:05 +00:00
skidau af139f4661 Used usleep(1) instead of _mm_pause on Linux and Mac OSX. This reduces the CPU usage in the video thread's idle loop. Added YieldCPU to the DSP LLE loop.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7125 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-10 12:56:21 +00:00
Marcos Vitali 86278642dc Experimental commit and one fix for my last commit.
I think that isFifoBusy bring better sync with VI (video interface) because the CPU emulated threads are waiting for DrawDone in BP Register. So, I do some modifications.
1) Rename "IsFifoBusy" by "isPossibleWaitingSetDrawDone"
2) Only activate isPossibleWaitingSetDrawDone when bFF_GPLinkEnable is true in fifo loop "Inmediate mode" that is because in theory this drawsync function is using in this mode.
3) Deactivate isPossibleWaitingSetDrawDone also in SetFinish in PixelEngine, beside when 32 block is finish.

Please regression in yours games thats can bring some FPS more above all with VPS frame limiter ON (Auto, 60, 50, etc).

- Fix waiting in AbortFrame(), please test mp1/mp2 is fixed again.

Good look! 

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7123 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-10 04:47:02 +00:00
Rodolfo Osvaldo Bogado 1f1c9132a6 revert some some of the soren changes to make dolphin compile in vs2008 again until sw plugin is completely fixed.
some correction to dlist caching

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7117 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-08 14:51:53 +00:00
Soren Jorvang 8c41d31651 Fix Plugin_VideoSoftware build.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7113 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-08 11:02:34 +00:00
skidau 855f97841d Paused the video thread while a save state was being created or loaded. Performed the save state operation after the fifo became idle. Saved the interrupt status of the video thread into the save state. This helps stabilise the save states in dual core mode in games like Super Mario Galaxy.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7112 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-08 10:37:47 +00:00
Shawn Hoffman a34b81cc01 vs2010:
buildfix
move much of the build settings to .props files
-please use them as much as possible in the future, instead of changing individual projects
NOTE: to avoid left over blobs, clean your builds *before* applying these changes.
TODO: add DebugFast target for projects that are lacking it. Lack of DebugFast targets cause the linker to use LTCG when we don't want it.
please test for regressions which could be caused by being too happy with compiler flags :)

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7109 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-08 04:03:48 +00:00
gnick79 f48c283294 - CPUID
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7103 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-07 21:03:10 +00:00
gnick79 795cf08bbf CPU... (yes)..ID -.-'
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7102 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-07 20:31:28 +00:00
gnick79 05ef2c1337 - again CPUID :°D
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7101 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-07 20:19:21 +00:00
gnick79 d373258517 - CPUID asm changes for x64 systems.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7100 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-07 20:14:22 +00:00
gnick79 a4754956cb - CPUID
restored inline assembly code

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7099 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-07 19:08:19 +00:00
gnick79 b1a63e3e8e - CPUID 2nd Attempt
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7098 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-07 18:35:01 +00:00
gnick79 bba19bb36b * CPUID changes:
- Added full ability to recognize true Intel HTT CPU capability (support to discriminate Intel Core 2 Duo...)
  - Attempt to fix a register trashing (issue 4022 generally, linux and mac systems)

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7097 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-07 18:25:55 +00:00
baby.lueshi 145559424c Fixed the new texture hashing functions to take samples into consideration. Fixes issue 4058
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7091 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-06 08:05:18 +00:00
hrydgard 1f42061163 fix silly string in CPUDetect
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7085 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-05 20:28:23 +00:00
hrydgard 3201b61b52 LTCG (link time code gen) was off in some projects, so turn it off in all of them so that the linker doesn't have to restart halfway through.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7084 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-05 20:14:23 +00:00
Soren Jorvang 98e24f5873 The compiler need not obey the static keyword, so to avoid linker
problems, whole functions in .h files need to also be static in
case they are included in several .cpp files.

Also a few other minor LTO fixes.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7082 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-05 16:06:05 +00:00
baby.lueshi 888cd78724 Changes to hi-res textures. Textures now load correctly when loading/saving a savestate, and can be toggled on and off in game.
Changed non-hi-res textures to use MurmurHash3, which has better performance that the previous hash.

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7080 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-05 10:08:06 +00:00
baby.lueshi 40ac272691 32-bit fix.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7068 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-05 00:31:35 +00:00
gnick79 d29b3e612a * Italian translation update
+ some little GUI adjustements

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7066 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-04 23:44:11 +00:00
baby.lueshi cd9e6a8d23 Change the recent speedup to the hashing function to fall back to the old version for custom textures.
Re-fixed custom textures higher than 1024x1024. (It must have accidentally got reverted somewhere during the video plugin merge)

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7064 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-04 22:51:17 +00:00
skidau d698e022f5 Changed the hash algorithm to CRC32 utilising the SSE4.2 instruction. The algorithm will automatically be used for the Accurate Texture Cache, EFB to RAM and texture id's when a SSE4.2 capable CPU is detected. It will fallback to the old algorithm if SSE4.2 is not detected. Using CRC32 speeds up the hash algorithm by around 2X.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7060 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-04 08:37:58 +00:00
Soren Jorvang cc289a05bb Turn back on unit tests in SCons.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7057 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-04 01:02:06 +00:00
Soren Jorvang 6d70c14d12 In the SCons build, skip the generation of static libraries
and just operate on lists of object files instead.

This helps with LTO since LLVM/clang LTO is completely broken
by static libraries. It also helps identify symbol clashes
between components like the former plugins.

Many linkers also expect static libraries to form a strict DAG
which turns out be a difficult rule to uphold in practice,
especially since some of our platforms aren't picky about this.

LTO builds currently appears to crash at runtime because of
the static wx libs.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7056 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-04 00:46:56 +00:00
Shawn Hoffman ac3f2d9c19 Remove OpenAL for windows.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7053 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-03 21:35:26 +00:00
Soren Jorvang 1619e176ff Use brute force to link the software plugin.
Not yet functional.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7050 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-03 19:55:30 +00:00
Soren Jorvang a3ba93d9ce Thread affinity on OS X and *BSD.
Keep building the software plugin to prevent rot.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7045 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-02 21:52:43 +00:00
Soren Jorvang 9c21d003af Remove the global namespace a bit and remove some dead code.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7043 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-02 18:21:20 +00:00
Glenn Rice 8b309e26dc Remove PluginSpecs.h. Merge the few needed enums from that file into Common.h for now. I am up for suggestions on a better place for those.
Fix frame dumping on linux.
Make sure that on screen messages get cleared between games.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7039 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-02 04:40:27 +00:00
gnick79 ebc8f02885 * Better fix for CPUID (and this time is the right time)
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7038 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-02 04:08:52 +00:00
gnick79 0f0adb4aee * Quick CPUID fix
- this should fix a detecting problem related to some AMD CPU


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7037 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-02 02:05:57 +00:00
skidau f2f9df90e1 VS2008 build fix
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7035 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-01 07:34:08 +00:00
Shawn Hoffman af9ef060c0 vs2010: Enable LTCG only for release builds.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7032 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-01 04:45:29 +00:00
Jordan Woyak 53ae9e9e8f Fixed vs2010 SVNRevGen project. (Also changed "make_svnrev.h.vbs" to jscript and gave it some comments :p) Removed some old plugin stuff.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7030 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-02-01 04:20:51 +00:00
Glenn Rice d932bdf480 Fix the rest of the tooltips for linux.
Also remove some unneeded linkage since the merge.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7026 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-31 22:19:30 +00:00
Shawn Hoffman 118d623a18 vs2010:
fix all build targets (they've all built here - you may have to manually delete the intermediate directories if you have conflicts after this commit).
set the debug path to $(TargetDir)

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7022 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-31 15:53:54 +00:00
skidau 5beb892d65 VS2008 build fix
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7017 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-31 09:10:18 +00:00
Shawn Hoffman 67a4ac0bf6 VS2010: Actually make SVNRevGen be processed all the time. Had to add a dummy output file, or VS would ignore it.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7014 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-31 08:14:28 +00:00
Shawn Hoffman 3b36e06571 svn eol-style:native on the filters...
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7013 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-31 07:58:59 +00:00
Shawn Hoffman 7ae1340179 vs2010 add filters for everything (...except wxw projects...). Try to fix SVNRevGen, but I'm not sure it's working...
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7012 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-31 07:51:37 +00:00
Soren Jorvang e0e4a3ae02 Allow changing the fullscreen resolution on OS X.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7011 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-31 07:38:36 +00:00
Shawn Hoffman 0e91e5b238 fix windows (vs2010) build
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7010 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-31 06:08:46 +00:00
Soren Jorvang 8822674653 Fix *BSD build.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7002 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-31 03:02:23 +00:00
Glenn Rice f1e8da63ec Linux build fix.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6999 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-31 02:13:10 +00:00
Soren Jorvang 18bb65b300 Fix OS X build.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6997 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-31 01:53:57 +00:00
Jordan Woyak fbaf965995 Eliminated the plugin interface. Merged DX9/DX11/OGL video plugins into Dolphin. It could still use a lot of cleanup. Lots of things are still named "plugin". Software renderer is temporarily disabled until it gets some namespaces. I only updated vs08/10, Linux/OSX builds are broken.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6996 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-31 01:28:32 +00:00
Glenn Rice cde1c5bd60 Remove the PIC linker flag for DSP on linux.
Fix some debugger issues.  Still need to get sound window working, but the invalid id panic alert is fixed.
Also, a ";" as a comment in an ini file is now only allowed at the beginning of a line.  The debugger has settings strings with semicolons in them.  That completely broke the debugger.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6989 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-30 17:04:12 +00:00
Soren Jorvang 2de8742368 Equip any new threads with an NSAutoreleasePool.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6978 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-29 23:46:26 +00:00
Soren Jorvang 043e324789 A few compiler warnings.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6975 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-29 22:48:33 +00:00
gnick79 3078db08c7 * Changed the Projection Hack option in game properties to "Custom Projection Hack"
- dislocating all sensible stuff related to "values per game/pattern" outside the sourcecode.
  - giving more control to end-users across the user-friendly interface.
  - deleting/cleaning some dead variables.
  - updating all gameconfig.ini data to reflect new PHack concept (pending upload).

* Updated Italian translation
  - Includes corrections, a better strings translating and suggestions directly by Google Code's people.

+ Minor old pending changes...

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6973 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-29 21:13:56 +00:00
Soren Jorvang 1287a9bb9f Be a little more careful about the use of SSE.
We really need to adopt the GCC model of one instruction set
per compilation unit.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6965 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-29 11:40:20 +00:00
donkopunchstania d5e5730fef If perspective divide is enabled and texture coordinate Z is 0 then leave texture coordinates alone. Fixes issue 3676.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6964 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-29 08:34:57 +00:00
Soren Jorvang d002a97575 RTLD_SELF is a recent addition on Linux.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6959 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-29 05:08:52 +00:00
Soren Jorvang 1bcad428ea Link the video plugin statically into the main binary on OS X.
This makes the OS X build more robust and should help pave the
way for the integration of the video plugins as well as LTO.

There are now no more global class level namespace conflicts left,
as evidenced by the fact that Dolphin can be linked with -all_load,
not that you would want to.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6958 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-29 04:52:19 +00:00
Rodolfo Osvaldo Bogado 4c58c7ea03 initial implementation of fog range adjust, I don't think is correct or work right but is a start.
some tweaks and fixes.

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6957 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-29 04:31:56 +00:00
sl1nk3.s a8e2e9ec54 Fix the Audio tab and merge the DSP config into one.
Unify the DSP settings into DSP.ini

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6955 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-29 04:16:05 +00:00
Soren Jorvang 08b923a163 Fix OS X build.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6951 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-28 21:27:49 +00:00
Glenn Rice f283041970 Linux build fix.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6950 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-28 20:07:32 +00:00
hrydgard 0df636ca39 a little more cleanup.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6949 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-28 19:55:21 +00:00
hrydgard 419d6a244b DSP plugin merge - the two DSP plugins are now gone and all the code has been merged into Dolphin.
This WILL temporarily break the Linux and MacOSX builds but should be easy to fix.

Things left to do:
  * The UI on the new Audio tab for the LLE/HLE choice is ugly
  * At times the code still look "plugin-y" and needs cleanup
  * The two plugins should be merged further. DSPHLE should use the emulated memory etc of DSPLLE as much as possible, so that simply saving the DSPLLE state is enough. This would also bring the possibility of savestate compatibility between the two plugins.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6947 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-28 18:39:30 +00:00
Jordan Woyak 2c05c49a04 Replaced Common::Thread with a partial implementation of std::thread. (rvalue references are used if available, <thread> is used if possible) Eliminates the need to use dynamic memory allocation for threads, so it's impossible to forget to delete a thread or set a pointer to NULL. Enables use of type-safe thread functions, no need to cast to and from void*. I've made sure the code compiles in vs08 and tested the functionality of "StdThread.h" on Linux so I'm hoping everything will work :p. In the future "StdThread.h" can be removed (maybe when OS X ships with gcc 4.4 and vs2015 is released :p).
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6933 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-27 20:47:58 +00:00
Jordan Woyak 66cd497dfe Added "DebugFast" configs to vs2010 projects. Removed solution folders.(vs express doesn't like them)
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6931 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-27 10:41:26 +00:00
Soren Jorvang 0288742565 Various minor fixes to allow building with clang on OS X.
Fixes issue 3992. 

wxWidgets patch at http://trac.wxwidgets.org/ticket/12332 .


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6929 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-27 05:01:00 +00:00
Jordan Woyak cbc520a70a Committing Visual Studio 2010 solution/project files. (not switching from 2008 just yet, just making 2010 an option) Still need to add a "DebugFast" config and change optimization settings.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6927 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-27 00:14:29 +00:00
hrydgard 48b7658c8a Detect cpu features AVX and AES, both are present on Sandy Bridge. For future use :P
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6925 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-26 21:27:26 +00:00
Rodolfo Osvaldo Bogado 4c704be0ed second try, a compilable :) fix for issue 3976 and some optimizations to color loading that will not mess with colors.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6917 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-25 22:30:15 +00:00
Jordan Woyak d2044a7a23 Removed extra space character in "Use FPS For Limiting". Changed "Frame Stepping" to "Frame Advance". Some minor preprocessor cleanup.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6913 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-25 11:14:11 +00:00
Rodolfo Osvaldo Bogado 470ed118f5 little fix for issue 3976.
some optimization for vertex color loading, please test  for any change in game color, this is a optimization so nothing should change :)

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6908 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-24 21:26:39 +00:00
Soren Jorvang 9f48012442 Inform SCons of the svnrev.h dependency so it isn't subject
to a race with the creation of Build/foo/Source/Common/Src.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6899 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-23 21:28:04 +00:00
Glenn Rice 1f722be056 Add a hack to match the *.* wildcard in a file search on non windows platforms. This fixes Metroid Other M on linux, and probably other games. Fixes issue 3966.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6895 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-22 18:19:42 +00:00
Soren Jorvang fecf10173b Use std::locale() on OS X and std::locale("") elsewhere.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6894 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-22 03:57:03 +00:00
Soren Jorvang 392a589092 Drop support for building on OS X 10.5. It is too much hassle to
work around the limitations of the no longer maintained Xcode 3.1.4
for Leopard. Running a 10.6-built app on 10.5 works fine through
through the use of the 10.5 SDK.

std::locale() seems to be the generally safer way to specify the
default locale and works on Linux and OS X at least. Thanks to
dasmetzelmaennchen for the pointer.

Remove some obsolete SCons related svn:ignores.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6893 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-22 02:18:25 +00:00
Soren Jorvang 1a3cd2d34c Remove the __APPLE__ workaround for reading config files from a ctor.
'#' is a fairly accepted comment character for .ini files along with
the more official ';', but '//' isn't.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6872 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-18 00:04:29 +00:00
Soren Jorvang e429d75489 Clean up nowx and stop cocoaApp busy-waiting in the main loop.
Set up an exit(3) task to shut down real wiimotes. This shouldn't
really be necessary, but we do currently handle a number of error
conditions by calling exit(3).

Retire the inputuicommon library.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6852 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-15 10:33:07 +00:00
pierre fb1ebd8022 Core/DSPCore: Consolidation of register accesses(except for the four hw
stacks), addition of a register cache(currently accumulators on 64bit only).

It feels a bit slower, but the numbers are about the same.
Caching accumulators doesn't change speed either.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6848 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-14 18:00:25 +00:00
Glenn Rice a747cb548c Clean up translator callback.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6842 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-14 00:15:08 +00:00
Glenn Rice 984b0d14d2 Translate PanicAlert captions too.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6841 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-13 20:53:37 +00:00
Glenn Rice c6e0ea59b9 Removed my previous PanicAlert translation hack. Fixed with a better method suggested by BhaaL. The translation is done by a callback in the MsgHandler routine that is set at program start. Added macros PanicAlertT, SuccessAlertT, PanicYesNoT, and AskYesNoT that are identical to the non T versions except those strings will be added by gettext to the po files to be translated. These can and should be used anywhere in the code for strings that should be translated.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6838 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-13 02:05:58 +00:00
Soren Jorvang 9ed3862c0a Executable memory above 2GB is okay on a 32-bit machine.
Fixes issue 3913.

The underlying problem, however, is that PanicAlert GUI popups
are broken on 32-bit Linux. I haven't looked into why that is.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6836 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-12 21:25:33 +00:00
Glenn Rice fcd72bdba9 Fix the panic alert hack for windows and osx. The macro needed to be defined after HAVE_WX is defined. That explains why windows accepted the string concatenation that I thought it wouldn't.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6829 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-12 18:09:16 +00:00
Glenn Rice a4dd8c41a8 Add a little hack to make it so panic alerts and questions can be translated if they are in the wxWidgets portion of the code, as well as make a few strings in the config dialog translatable.
Add Hungarian translations by Delirious.
Update Italian translations by RebuMan.
Update German translations by JackyCola and LucasX.
Update Greek translations by Gpower2.
Update Frensh translations by Pascal.
Make sure the game list is refreshed when the GC language is changed.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6826 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-12 13:14:50 +00:00
Soren Jorvang 6de6cf6d46 Don't bother quickly flashing the full pathname to the file loaded
in the title bar. It is more usefully displayed using the overlay
and long pathnames are not suitable for title bars and probably not
even safe depending on the underlying windowing system.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6817 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-11 16:19:15 +00:00
xsacha 3f5d1afc6a Use alignment for ReadDataU32XN. Revert james temp fix.
Should provide some form of a speedup.

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6812 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-11 04:54:35 +00:00
Soren Jorvang d78be40be9 Print the performance status in exactly one place.
Placing the render window at position 0,0 makes it unmovable on OS X.

Use the conventional r1234 format for SVN revision numbers.

Delete mis-copied .svn directories from the application bundle.
 
Only warn about a failed low-memory allocation if one was requested.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6811 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-11 04:09:11 +00:00
Glenn Rice 9bbed569d9 Add the last few languages added to the windows build.
Make pthreads linkage precise for the nowx build.  Fixes issue 3875.
Fall back to pkg-config for gtk+-2.0 if cmake is version 2.8.2.  That version has a bug that doesn't detect gdk-pixbuf-2.0.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6810 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-11 02:18:34 +00:00
NeoBrainX 81638396c0 Some more work on CMake on Windows:
- add support for precompiled headers with MSVC
- compile with _FILE_OFFSET_BITS=64 and _LARGEFILE_SOURCE only for our sources, some dependencies seem to have problems with it enabled...
- disable -Wall for MSVC too prevent warning flood
- rename aes_cbc.c and aes_core.c to cpp files since it makes stuff a lot easier and there's really no reason not to do it since they had been compiled as C++ before anyway

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6797 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-09 16:36:19 +00:00
Rodolfo Osvaldo Bogado d47d2a05d2 some little optimizations and some cleaning.
now lighting should be fully functional again in SM 2.0 cards

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6794 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-09 14:13:24 +00:00
Soren Jorvang d4158f076a Allocate low executable memory on OS X as on Windows and Linux.
Even with LoadStorePaired accounted for, there are still some
niggling 64-bit cleanliness bugs left that are not practical
to weed out on a single platform. We should probably have an
option to use >2GB memory only on all platforms for debugging.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6792 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-09 14:09:27 +00:00
Rodolfo Osvaldo Bogado f869281301 normalize the efb to texture process for color textures to make it work the same in all the plugins and with the same accuracy as real hardware (almost :))
please test for regressions and fixes.
some little changes to make pixel shader more dx9 sm2.0 friendly. the condition is not to use pixel lighting ( sorry no hardware support for the quantity of parameters needed).

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6777 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-07 19:23:57 +00:00
Soren Jorvang 95b6d3f445 Kill HAVE_OPENCL.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6756 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-06 01:11:32 +00:00
Soren Jorvang 4bf07838a8 Use abspath when deleting the old Source..svnrev.h.
Makes no difference for me with SCons 2.0.1,
but maybe it does with other versions.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6717 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-01 22:47:29 +00:00
Soren Jorvang 6ffdbe8482 Use the public svn_rev_str for the kernel.bin header instead of
the private SVN_REV_STR which relies on finicky build mechanics.

With SCons, kill the old svnrev.h in Source if still present.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6715 8ced0084-cf51-0410-be5f-012b33b47a6e
2011-01-01 21:08:30 +00:00
nitsuja- a55925af79 fixed crash when compressing 4+gb isos on some builds
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6700 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-12-31 10:40:49 +00:00
Jordan Woyak 2c4f9825ca Fix issue with LinearDiskCache where only new files could be written to, Append() would fail on previously existing cache files.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6690 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-12-30 07:32:16 +00:00
pierre fc1db5eaa0 Core/DSPCore: Reorganize register layout for accessing accumulators
(acc and ax) and product register with one read/write.

Gives a minuscule speedup of not more than 4%. In exchange, breaks all
your out-of-tree changes to dsp. Tests are not building again, yet.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6680 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-12-29 02:12:06 +00:00
pierre c33f46406e Core/DSPCore: Improve Interpreter address register add/sub, convert to
assembler for JIT. Replace JIT ToMask() with a different variant. Remove
 superfluous zeroWriteBackLog calls(added by me).
Core/Common: Don't bother creating a string and calling into a Logs trigger()
 when there is noone listening. Change AtomicLoadAcquire for gcc to just
 make the compiler not reorder memory accesses around it instead of doing
 a full memory barrier, per the comment in the win32 variant.
Core/AudioCommon: Fix a use of uninitialized variable inside libalsa.

Microbenchmarking results for ToMask variants:(1 000 000 000 iterations):
             cpu\variant| shifts | bit scan
intel mobile C2D@2.5GHz | 5.5s   | 4.0s
amd athlon64x2@3GHz     | 6.1s   | 6.4s
(including some constant overhead identical to both variants)



git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6667 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-12-27 15:05:18 +00:00
Soren Jorvang 64d43211c9 Use the same code for populating user data directories one by one
on OS X as on other Unices so OS X initial installs aren't so easily
broken by files being created in constructors.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6661 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-12-27 00:26:52 +00:00
LPFaint99 547c18fb55 Add the ability to Get / Set Array data from SysConf
wiimote bd's are now read from (or added to if < 4 exist) SysConf
in theory you should be able to use any valid sysconf file now,
but i would advise against using a dolphin edited SysConf on a wii

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6646 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-12-22 08:00:08 +00:00
Soren Jorvang 3d68608024 Fix Unix build.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6645 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-12-22 06:45:59 +00:00
LPFaint99 6c556786fb Move AES to common lib
move pch includes to vcproj file for discio

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6643 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-12-22 06:00:36 +00:00
LPFaint99 9584b5b335 Update Wii save import / export to use the same replace list as FileIO
add a couple of country codes I found through redump.org database

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6640 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-12-22 00:48:59 +00:00
blubberdiblub 38e80fe094 Fixes some file handling in IPC_HLE
* change File::GetSize to fetch the size directly from the open file instead
  of stat'ing it when challed with a FILE*
* use changed File::GetSize(FILE *f) instead of calling with file name in two
  places
* remove "seek_pos % file_size" hack for ZTP, so one can seek to the end of
  file again. Please check Zelda: Twilight Princess for regressions
* return error codes when reading or writing from/to a file

A lot of those changes are from j4ck.fr0st, so kudos to him.

I did not change the file open mode for ISFS_OPEN_WRITE to "wb". While that
would probably be more correct, it says in the comment that it might affect
Mario Kart Wii. I would prefer somebody with that game try that change
locally first.

Please check your games for regressions (or even improvement). Some games that
may be affected are Zelda - Twilight Princess and Metroid Prime 3.

Fixes issue 1749



git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6634 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-12-21 18:03:44 +00:00
Rodolfo Osvaldo Bogado 3749c3e57d update shader cache version to force regeneration
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6623 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-12-19 22:28:22 +00:00
nitsuja- 6492b84ca5 this probably doesn't fix anything noticeable, but, it seems like a bug that C_COLORMATRIX+4 overlapped with C_PLIGHTS
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6620 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-12-19 21:09:29 +00:00
nitsuja- 98fe8437ae reduced frequency of dx9 ps_2_0 pixel generation errors, and made dx9 efb depth peek of 16-bit depth buffer not use 24-bit adjustment factor. shouldn't affect other the plugins.
(probably nobody else cares, but I need at least one video plugin that actually works on this computer)

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6618 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-12-19 20:59:23 +00:00
Soren Jorvang 98e89c9329 OS X std::locale only supports the "C" locale and will give an exception
on any other, including "" when a different one is specified through the
POSIX locale environment variables.

This is not normally a problem since these variables are stripped out from
the environment when an application is launched by the Finder. This is not
the case when running the binary directly from the command line, such as
when debugging.

I have temporarily disabled the use of std::locale("") on OS X while I try
to come up with a better solution.

Fixes issue 3598.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6615 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-12-19 16:11:55 +00:00
gnick79 c68ae8e91e Related to CPUID detecting:
* fixed a bug on display info for AMD CPUs.

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6612 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-12-19 15:06:30 +00:00
Glenn Rice 05ad8d01d3 Fix TextureDecoder.cl to work on both NVidia and ATI video cards.
To do so I had to re-add the casting bloat removed in revision 6102.  Also, for some odd reason the NVidia OpenCL drivers don't like 8 bit rotations, but are okay with 2, 4 bit rotations.  These are apparently bugs in the NVidia drivers that are hopefully fixed in future versions.
Also, on linux make sure the TextureDecoder.cl file is copied from the shared data directory to the users directory.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6611 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-12-19 14:59:57 +00:00
Glenn Rice d1631bec3f Build fix for linux. svnrev.h was not found when compiling OCLTextureDecoder.cpp as that include directory was only used in Core/Common.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6610 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-12-19 14:02:43 +00:00
skidau 9114c96c78 Cached the compiled OpenCL kernels to disk (User/OpenCL/kernel.bin). This reduces the start up delay in OpenCL mode. Added a 10 byte header to the file which contains the current svn rev string. This will recompile the OpenCL kernels with every new revision.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6608 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-12-19 11:03:09 +00:00
gnick79 522746b2c2 **Changes**
* More formats recognition for "Clear Screen" step. Improved the ability handling the alpha channel (% color translucency).
* Related to CPUID detecting:
	- Added support displaying correct SysInfo for recent multicore Intel CPUs x86-64 with HT/SMT (Core i3/i5/i7 and Xeon) based on Nehalem architecture.

+ minor and passive changes.

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6604 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-12-18 18:23:22 +00:00
Orphis 42e40b46c0 OpenCL: Fix error reporting when the build log is too long
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6603 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-12-18 04:54:16 +00:00