Commit Graph

311 Commits

Author SHA1 Message Date
gibbed
0b3cdf2aaa [Base] Fix non-Windows bit_scan_forward. 2020-02-09 16:37:52 -06:00
Silent
684f9fedec [Base] Remove kMaxPath from Windows, it should not be used
All instances of kMaxPath or MAX_PATH being used have been removed,
and removing this constant is supposed to encourage writing code
without artificial constraints on path length.
2020-02-09 14:02:37 -06:00
Silent
96a9397349 [Base] Remove MAX_PATH limit from GetUserFolder
Replace SHGetFolderPath with SHGetKnownFolderPath to remove the limit
2020-02-09 14:01:39 -06:00
Silent
6f2c39d8d1 [Base] Remove MAX_PATH limit from to_absolute_path
Let _wfullpath allocate memory by itself to remove the limit
2020-02-09 14:01:39 -06:00
Justin Moore
96a7908c28 [Base] Fix formatting errors accidentally introduced 2020-02-08 16:30:17 -06:00
Justin Moore
7ed6296bb2 [Base] Call SetThreadDescription to name threads on versions of Windows that support it. 2020-02-08 21:12:42 +00:00
noshbar
2ce455fc73 [Base] Initialize file 'open_access' flag before using it.
In the 'OpenExisting' function, 'open_access' is used to create the flags for opening the file.
However, it is not set to zero, so could end up being incorrect file modes, potentially even emptying the file for appending, which would be bad.

This simply initialises it to zero first.
2020-02-08 14:43:46 -06:00
Joel Linn
922f1f220a [CPU] Implement mftb instruction natively.
When the cvars clock_no_scaling and clock_source_raw are set, tick counts will be directly calculated in the emitted code.
2019-12-01 17:11:58 -06:00
Joel Linn
15d422d988 [Base] Optional raw Clock source.
New cvar clock_source_raw allows to use the cpu cycle counter itself as an alternative time source, if system timing resolution is to low and causes problems.
2019-12-01 17:11:58 -06:00
Joel Linn
f88d46cead [Base] Optional Clock scaling bypass.
New cvar clock_no_scaling bypasses all time scaling code.
Clock state is non dynamic.
Timing is always derived from host.
2019-12-01 17:11:58 -06:00
Joel Linn
7e244e0488 [Base] Clock state now unaltered by threading.
- Removed tick and time values from ThreadSavedState.
- Removed affiliated get/set code from Save and Restore.
- Removed dangerous SetGuestTickCount method.
2019-12-01 17:11:58 -06:00
Joel Linn
d6ce72ddc9 [Base] Clock reworked.
- Time progression is now equal and in sync on all threads.
- Floating point imprecisions do not interfere with timing.
2019-12-01 17:11:58 -06:00
Triang3l
a9ed73bdd1 [GPU] Remove most hardcoded register/instruction layouts from common and D3D12 code 2019-10-20 19:40:37 +03:00
gibbed
c22f76e87f [Base] Const-ize store and store_and_swap templates.
[Base] Make value argument for store and store_and_swap templates
const&.
2019-09-04 19:58:17 -05:00
gibbed
3e6c2bb47c Fix up handling of positional options in cvar handling.
- Fix up handling of positional options in cvar handling so that executables
  other than app can handle them properly.
- Fix command-line arguments for xenia-vfs-dump.
2019-08-24 07:41:55 -05:00
gibbed
35e79d1979 [Base] Fix checks in cvar string escaping. 2019-08-04 21:55:06 -05:00
gibbed
306f358c07 [Base] Drop inline on string_util/vec128 implementations for now because clang is whining. 2019-08-04 12:00:04 -05:00
gibbed
36bd0df586 [Base] Move float/double to_hex_string implementation out of header. Maybe fix Travis complaining. 2019-08-04 11:38:01 -05:00
gibbed
4248f9ed19 [Base] Fix formatting in string_util.cc. 2019-08-04 07:32:24 -05:00
gibbed
693958f8b7 [Base] Fix escaping quote runs. 2019-08-04 07:29:29 -05:00
gibbed
bee55ce5bb [Base/Core] Work on config/cvars. Properly escape string values when saving config. 2019-08-04 07:09:05 -05:00
gibbed
82f85c98f0 [Base] Add wide version of split_path. 2019-08-04 06:47:09 -05:00
gibbed
01c656b77b [Base] Add split_string. 2019-08-04 06:46:07 -05:00
gibbed
2048239f30 [Base] Move implementation out of header where appropriate, and qualify std namespace. 2019-08-04 04:40:19 -05:00
gibbed
40cc8c52d7 [Base] Qualify std namespace. 2019-08-04 04:39:22 -05:00
gibbed
8b1f728d85 [Base] Use vwsprintf instead of _vsnwprintf. 2019-08-04 03:44:08 -05:00
gibbed
b685211b96 [Base] Add wide versions of FatalError. 2019-08-04 03:26:18 -05:00
gibbed
85b4b561bf [Base] Fix Travis complaints with cvar code. 2019-08-04 02:52:28 -05:00
gibbed
f360053198 [Base/Core] Bring cvar/config code in line with the style guide. 2019-08-04 02:17:22 -05:00
gibbed
7ba460552c [Base/Core] Add support for transient cvars. 2019-08-04 02:12:46 -05:00
gibbed
b2f62b1982 Clean up cvars (rename, recategorize). 2019-08-03 23:46:03 -05:00
Triang3l
352f12f92e [D3D12] Switch from gflags to cvars 2019-08-03 16:53:23 +03:00
Jonathan Goyvaerts
2a1d67eada [Base] Fix snprintf not working correctly
This seems to be an issue with Microsoft declaring a snprintf macro which causes issues.
Related issues:
- https://github.com/nlohmann/json/issues/1408
- https://github.com/kodi-pvr/pvr.vuplus/issues/162
2019-08-03 02:34:19 +02:00
Jonathan Goyvaerts
81fe22f1c8 Get rid of gflags alltogether 2019-08-03 02:34:19 +02:00
Jonathan Goyvaerts
c1af632562 Replace all gflag implementations with cvar implementations 2019-08-03 02:34:07 +02:00
Jonathan Goyvaerts
bedd8ea40f [Base] Add cvar class, a better, more flexible implementation of storing configuration variables than gflags 2019-08-03 02:33:56 +02:00
Jonathan Goyvaerts
bc6c047152 [Base] Add generic implementation for converting from string to T, and add specific implementation for string to bool 2019-08-03 02:33:40 +02:00
Triang3l
68b2ddee86 Merge branch 'master' into d3d12 2019-07-31 23:09:44 +03:00
Triang3l
e466687f11 [Base] Fix tzcnt logic 2019-07-31 23:08:41 +03:00
Triang3l
4aceeb73c4 [Memory] Move new watches to heap-aware Memory from MMIOHandler 2019-07-30 08:00:20 +03:00
Triang3l
2350810f4e [Base] Add typename to sat_add/sub 2019-07-20 16:14:13 +03:00
Triang3l
26c24b4726 [CPU] Move saturating add/sub to base/math.h 2019-07-19 23:12:11 +03:00
gibbed
0bed6e565b [Base/GPU] Fix some usage of xe::find_base_path. 2019-07-18 18:37:47 -05:00
gibbed
887609ba44 [Base] Only attempt to create non-empty base paths in CreateParentFolder. 2019-07-18 18:32:04 -05:00
gibbed
706c810a3a [Base] Fix find_base_path returning original string with no separator is found. 2019-07-18 18:31:21 -05:00
gibbed
9a8d77137c [Base] Fix Windows CreateFolder so it creates the entire path properly. 2019-07-18 17:47:25 -05:00
Rick Gibbed
e51686bbac Merge pull request #1369 from jgoyvaerts/logger_fix
[Base] Flush the logger before exiting on a fatal error.
2019-05-11 11:45:00 -05:00
Jonathan Goyvaerts
eb5baa41bb Shutdown logging when a fatal error occurs, this fixes the error not showing up in the log file 2019-05-11 14:58:34 +02:00
Rick Gibbed
00e061c4e4 Merge pull request #1316 from chris-hawley/master
[Base] Remove hacky fix for missing codecvt on linux.
2019-05-04 11:40:33 -05:00
Rick Gibbed
9bb20bfc36 Merge pull request #1254 from Wildenhaus/master
Games on Demand / Multi-file STFS (SVOD) support.
2019-05-04 11:30:48 -05:00