* Avoid the generation of memory barrier (mfence)
* Based on the fact that it used to work on previous code without any
barrier
v2:
* keep basic code in reset path
* use relaxed access for isBusy. The variable doesn't carry load/store
dependency but is instead an hint to optimize semaphore post
The TLS buffers used by the FastFormatUnicode and FastFormatAscii
classes seem to be responsible for PCSX2 not terminating properly on
Windows under certain conditions (using MTVU before commit
1111e03901, using CDVDgigaherz without a
disc, possibly other conditions).
When PCSX2 shut downs and the FastFormatBuffers are being cleaned up,
the call to pthread_key_delete() would end up calling
WaitForSingleObject(e, INFINITE) and waiting indefinitely for an event
to trigger. It never does get triggered (for reasons unknown) and
therefore PCSX2 doesn't terminate properly.
Remove the usage of TLS buffers in the FastFormatString classes - it
fixes the termination issue on Windows and doesn't seem to have much
effect on performance.
Buttons done, configuration initialization done.
Still need to add Gamepad and Joysticks configuration frames.
Require png file for the moment (the embedded picture will be fixed after).
New Onepad GUI based on wxWidget (Main frame almost finish)
Background picture is now embedded
Button binding works
Loading and saving works
Need to add feedback and gamepad, joysticks configuration frame
Modification of the onepad CMakeList.txt
Automatic generation of images headers using perl script
Modification of the test feedback function
Basically it creates a /tmp/perf-`pid`.map file which will contains
a mapping of the x86 code with the EE/IOP/VU code
* You need to enable the profiler with a define
* You can split the profiling by block (inside a recomp buffer)
v2: add new file to VS xml files
v3: remove useless include
Let's the kernel manage the memory either with builtin lazy allocation or
swapped memory.
Avoid to handle SIGSEGV manually (nicer for debug) and removes 250 lines of code.
CID 147010 (#1 of 1): Uninitialized pointer field (UNINIT_CTOR)4. uninit_member: Non-static class member Enabled is not initialized in this constructor nor in any functions that it calls.
It might help to fix those 2 coverity reports.
CID 151744 (#1 of 1): Useless call (USELESS_CALL)
side_effect_free: Calling EnumAssert(id) is only useful for its return value, which is ignored
CID 151745 (#1 of 1): Useless call (USELESS_CALL)
side_effect_free: Calling EnumAssert(id) is only useful for its return value, which is ignored.
Console.Error() can trigger some exceptions (like out of memory)
v2:
Add a default fallback catch(...) in case someone badly add a new
exception in the codebase
Coverity:
CID 147021 (#1 of 1): Uninitialized scalar field (UNINIT_CTOR)i
2. uninit_member: Non-static class member m_handled is not initialized in this constructor nor in any functions that it calls.
This could have caused issues where e.g. Fixed100(59.94) differed from
Fixed100::fromString("59.94") due to precision compilation flags
(the former could, and did on Devel builds, end up with Raw == 5993, which
differs from the value constructed from the string at the ini file,
and then it would be incorrectly identified as a custom rate).
Rounding seems the more likely intention when effectively decreasing the
precision of a value.
Unlikely that we have code which depends on truncating behavior, though not
impossible.
Out-of-bounds memory is no longer accessed if the realloc size is larger.
If reallocation fails, the old memory will not be freed and a memcpy
will not take place.
This should match the Windows _aligned_realloc behaviour, except that an
extra parameter is used.
All refer to memcpy, and only memcpy_fast is used, so there's no point
keeping them.
Also remove the _memset16_unaligned function prototype since there's no
function definition for it.