Commit Graph

28542 Commits

Author SHA1 Message Date
spycrab daebbabb35 Qt/GameList: Greatly improve performance (List view) 2018-06-15 12:05:11 +02:00
Léo Lam 58606702f7
Merge pull request #7107 from lioncash/mac
Common/Network: Get rid of out parameters for MAC address utilities
2018-06-14 19:44:09 +02:00
Léo Lam c7280707ec
Merge pull request #7113 from lioncash/mask
Gekko: Centralize bitmasking of the FPSCR within UReg_FPSCR
2018-06-14 18:28:11 +02:00
Léo Lam 59cd9a5af7
Merge pull request #7118 from lioncash/hotkey-str
HotkeyManager: Minor changes
2018-06-14 18:26:03 +02:00
Léo Lam 0f0823f4a4
Merge pull request #7119 from lioncash/random
Common/Random: Add convenience template for simple arithmetic values
2018-06-14 18:25:21 +02:00
Lioncash 189d277cfc Common/Random: Add convenience template for simple arithmetic values
In cases where we just want a random value for a primitive arithmetic
type, we can wrap this in a template to allow convenient direct
assignment instead of keeping declaration and initialization separate
(making it more difficult to use values uninitialized). This also allows
the use of Common::Random with functions such as std::generate, making
it more flexible in how random values can be generated.
2018-06-14 10:31:13 -04:00
spycrab e69c6cdaab
Merge pull request #7114 from Techjar/patch-3
Qt/GameCubePane: Fix memcard browsing starting in working directory instead of User/GC/ directory
2018-06-14 16:13:21 +02:00
Lioncash 410792d922 HotkeyManager: Add missing s_ prefixes to internally-linked file-scope variables
Previously there was an intermixing of no prefixing and prefixing. This
makes the notation consistent.
2018-06-14 10:07:22 -04:00
Lioncash d22d32372e HotkeyManager: Use std::array where applicable 2018-06-14 10:07:01 -04:00
Lioncash aae06f1cf7 HotkeyManager: Move HotkeyGroupInfo struct into the cpp file
This is only ever used internally. Also change the std::string name over
to a const char*, so that we don't need to potentially allocate anything
on the heap at immediate runtime.
2018-06-14 09:12:19 -04:00
Techjar 027fc6efd5 Qt/GameCubePane: Fix memcard browsing starting in working directory instead of User/GC/ directory 2018-06-14 09:11:54 -04:00
Lioncash d459470fee HotkeyManager: Convert file-scope std::string array to constexpr const char* array
Previously, a total of 114 std::string instances would need to construct
(allocating on the heap for larger strings that can't be stored with
small string optimizations). We can just use an array of const char*
strings instead, which allows us to avoid this.
2018-06-14 09:04:57 -04:00
Markus Wick 1f49a9c87c
Merge pull request #7116 from lioncash/log
JitCommon/JitBase: Rename x86-specific logging define to be platform agnostic
2018-06-14 15:00:34 +02:00
Markus Wick 3307474c95
Merge pull request #7117 from lioncash/unused
JitBase: Remove unused rewriteStart data member from JitState
2018-06-14 14:59:31 +02:00
Lioncash 065aba43e2 JitBase: Remove unused rewriteStart data member from JitState 2018-06-14 08:46:34 -04:00
Lioncash ace24c2932 JitCommon/JitBase: Rename x86-specific logging define to be platform agnostic
Given JitBase shouldn't include platform specifics, we can generalize this
preprocessor define and allow any JIT to use it to indicate that generated code should be logged.

While we're at it, also move these defines beneath the includes with the
rest of the defines.
2018-06-14 08:35:35 -04:00
spycrab e8c1e5af63
Merge pull request #7112 from spycrab/qt_macos_layout
Qt/macOS: Make configuration layout consistent with other platforms
2018-06-14 12:29:24 +02:00
spycrab 09df03382d
Merge pull request #7094 from spycrab/qt_fs_fixes
Qt: Fix multiple fullscreen issues
2018-06-12 22:46:29 +02:00
Lioncash 0049ef3a2a Gekko: Centralize bitmasking of the FPSCR within UReg_FPSCR
Rather than introduce this handling in every system instruction that modifies
the FPSCR directly, we can instead just handle it within the data structure
instead, which avoids duplicating mask handling across instructions.

This also allows handling proper masking from the debugger register
windows themselves without duplicating masking behavior there either.
2018-06-12 14:15:50 -04:00
Pierre Bourdon 8a3679bebc
Merge pull request #7111 from spycrab/update_gtest
Externals/GTest: Update to latest master
2018-06-12 16:19:59 +02:00
spycrab f2c6a97916 Qt/macOS: Make configuration layout consistent with other platforms 2018-06-12 15:45:33 +02:00
spycrab 4d55cb745c UnitTests: Fix MSVC compilation 2018-06-12 15:28:59 +02:00
spycrab ccf9ecbb03 UnitTests/VertexLoaderTest: Fix compilation on newer GTest versions 2018-06-12 14:59:57 +02:00
spycrab fe6e46f846 Externals/GTest: Update to latest master 2018-06-12 14:52:43 +02:00
Léo Lam f3a18db9e0
Merge pull request #7106 from lioncash/name
WiimoteDevice: Amend variable naming
2018-06-11 11:12:08 +02:00
Lioncash 59846378b3 BTReal: Handle case where a link key may be invalid within LoadLinkKeys()
This can only occur if a user purposely corrupts their config file, but
still, we may as well protect users from themselves.
2018-06-10 16:11:36 -04:00
Lioncash ce69201f33 Common/Network: Get rid of out parameters for MAC address utilities
Given we have std::array and std::optional, we can use these in
conjunction with one another to avoid the need for out parameters.
2018-06-10 15:43:26 -04:00
Mat M b6592723a7
Merge pull request #7103 from leoetlino/master
BTReal: Fix unsafe reinterpret_casts
2018-06-10 14:27:19 -04:00
Lioncash 925348cdd1 WiimoteDevice: Amend variable naming for class member variables
Gets rid of inconsistencies related to class variables concerning casing
and the lack of prefixes on some variables, while others contain them.
2018-06-10 14:23:36 -04:00
Lioncash eaace415d3 WiimoteDevice: Amend variable naming for non-class member variables
This file is quite out of sync when it comes to our naming conventions,
this brings it back in line with it.
2018-06-10 14:23:31 -04:00
Markus Wick 70417c8d16
Merge pull request #7096 from lioncash/jit-buffer
JitBase: Centralize location of code buffer
2018-06-10 17:59:41 +02:00
Markus Wick 88f8df0ad9
Merge pull request #7105 from lioncash/cast
WiimoteDevice: Remove unnecessary cast
2018-06-10 17:57:45 +02:00
Lioncash 0d0f58005b WiimoteDevice: Make channel reference const qualified
This is only used for reading data, not modifying it, so make the type
system enforce that.
2018-06-10 09:08:33 -04:00
Lioncash 5548316d32 WiimoteDevice: Remove unnecessary cast in ExecuteL2capCmd()
pData is already a u8*, so a cast isn't necessary here.
2018-06-10 09:04:42 -04:00
Léo Lam 69f079b371
Merge pull request #7098 from Ebola16/ElfDolMessage
Android: Add AlertDialog for files without Game IDs in Game Settings
2018-06-10 14:36:46 +02:00
Léo Lam fca6d80740
Merge pull request #7101 from lioncash/ios
WiimoteDevice: Minor changes
2018-06-10 14:35:41 +02:00
Léo Lam 6da3c4a6d0
Merge pull request #7102 from lioncash/chunk
ChunkFile: Remove unnecessary includes
2018-06-10 14:35:16 +02:00
Léo Lam 8bb08d1ca6 BTReal: Fix unsafe reinterpret_casts
Using reinterpret_cast like that is possibly UB.
Replace them with structs/memcpy calls where applicable.
2018-06-09 23:04:04 +02:00
Lioncash c825eecbc9 ChunkFile: Remove unnecessary includes
ChunkFile doesn't use any of the file utilities, so we can drop these
headers to avoid pulling in unnecessary dependencies. This also
uncovered a few indirect inclusions.
2018-06-09 16:49:59 -04:00
Lioncash 647da59679 WiimoteDevice: Move channel state booleans into a struct
These were essentially duplicated for both channels, when they could be
implemented in terms of a struct, which allows for simplifying the reset
case.
2018-06-09 16:35:32 -04:00
Lioncash 94fd8505d6 WiimoteDevice: Make DoesChannelExist() a const member function
This only queries internal class state, it doesn't modify it.
2018-06-09 16:35:32 -04:00
Lioncash f906785e88 WiimoteDevice: Make EventPagingChanged() a const member function
This only queries internal state, it doesn't modify it. With minor
adjustments to BTEmu, this also allows us to make its usage instance a
constant reference.
2018-06-09 16:35:32 -04:00
Lioncash 38d155f993 WiimoteDevice: Make ConnectionState enum an enum class
Avoids polluting class scope and makes it strongly typed.
2018-06-09 16:35:27 -04:00
Léo Lam f564c28040
Merge pull request #7099 from lioncash/compiler
Common: Add Compiler.h header for compiler-specifics
2018-06-09 20:19:49 +02:00
Léo Lam 5d1b35e867
Merge pull request #7100 from lioncash/table
WiimoteHIDAttr: Make file-scope packet data arrays immutable
2018-06-09 20:18:07 +02:00
Lioncash b5d89294f7 WiimoteHIDAttr: Make file-scope packet data arrays immutable
Given these are only ever returned from a function as const u8*, we can
go ahead and make these fully immutable.
2018-06-09 13:46:28 -04:00
Lioncash 7b11ce3dd2 Compiler: Use [[maybe_unused]] in the Windows DOLPHIN_UNUSED macro
The required version of MSVC already supports [[maybe_unused]], so we
can utilize this here. When GCC 7 and clang 3.9 become hard
requirements, we can eliminate this macro entirely and replace it with
[[maybe_unused]].
2018-06-09 12:20:29 -04:00
Lioncash d8f6d60189 Compiler: Rename UNUSED macro to DOLPHIN_UNUSED
UNUSED is quite a generic macro name and has potential to clash with
other libraries, so rename it to DOLPHIN_UNUSED to prevent that, as well
as make its naming consistent with the force inline macro
2018-06-09 12:20:29 -04:00
Lioncash 3f210836ad Compiler: Rename __forceinline define to DOLPHIN_FORCE_INLINE
This is much better as prefixed double underscores are reserved for the
implementation when it comes to identifiers. Another reason its better,
is that, on Windows, where __forceinline is a compiler built-in, with
the previous define, header inclusion software that detects unnecessary
includes will erroneously flag usages of Compiler.h as unnecessary
(despite being necessary on other platforms). So we define a macro
that's used by Windows and other platforms to ensure this doesn't
happen.
2018-06-09 12:20:25 -04:00
Lioncash 03414e8e84 Common: Add header for compiler-specifics
Instead of globbing things under an ambiguous Common.h header, move
compiler-specifics over to Compiler.h. This gives us a dedicated home
for anything related to compilers that we want to make functional across
all compilers that we support.

This moves us a little closer to eliminating Common.h entirely.
2018-06-09 12:10:05 -04:00