Joel Linn
dbbf401205
[Base] Align test memory
2022-01-25 12:55:10 -06:00
Joel Linn
e4ae1d8b2f
[Base] Fix copy_and_swap_16_in_32_aligned
2022-01-22 16:18:54 +03:00
Joel Linn
0316d1a054
[Base] Tests for copy_and_swap_16_in_32_aligned
2022-01-22 16:18:54 +03:00
Joel Linn
4a288dc6bd
[Base, aarch64] Add copy_and_swap NEON impls
2022-01-22 16:18:54 +03:00
Joel Linn
bfaad055a2
[Base] Add easier to debug copy_and_swap tests
2022-01-22 16:18:54 +03:00
gibbed
5384e0e174
[Base] Fix MICROPROFILE_PRINTF.
2022-01-11 06:09:26 -06:00
Wunkolo
13a48e13bd
[Base] Add operator<< string conversion for vec128_t
...
This allows `catch` to print out the contents of a particular vector when diagnosing how a `REQUIRE` expression has failed.
2022-01-02 15:14:58 -06:00
Wunkolo
f645c3ba31
[Base] Fix to_hex_string out-of-indexing for vec128_t type
...
Trying to print five `{:08X}` when vec128_t only has four values. 🥴
2022-01-02 15:14:58 -06:00
Wunkolo
1a8068b151
[Base] Add user-literals for several memory sizes
...
Rather than using `n * 1024 * 1024`, this adds a convenient `_MiB`/`_KiB` user-literal to the new `literals.h` header to concisely describe units of memory in a much more readable way. Any other useful literals can be added to this header. These literals exist in the `xe::literals` namespace so they are opt-in, similar to `std::chrono` literals, and require a `using namespace xe::literals` statement to utilize it within the current scope.
I've done a pass through the codebase to replace trivial instances of `1024 * 1024 * ...` expressions being used but avoided anything that added additional casting complexity from `size_t` to `uint32_t` and such to keep this commit concise.
2022-01-02 11:51:31 -06:00
Triang3l
701300e8e9
[Linux] Use sched_yield instead of the deprecated pthread_yield
2021-12-18 19:43:17 +03:00
Conrad Kramer
2962a266b5
Fix xenia-core build on macOS
2021-10-25 00:48:53 +03:00
Joel Linn
247cb91ac5
[Base] Replace GCC workaround (loop opt bug)
...
Previous workaround was dangerous, this one is more sane.
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100801#c3
2021-09-27 13:43:57 +03:00
Triang3l
f91b895c9a
[Base] Don't use raw clock where unsupported
2021-09-13 23:13:02 +03:00
Triang3l
7aeac37eb6
[Base/UI] Android globals initialization + WindowedAppContext parts
2021-09-13 23:09:28 +03:00
Triang3l
acbd22840d
[Base] Android log sink + sink cleanup
2021-09-13 22:53:19 +03:00
Triang3l
6986d6c7e8
[Config] Use locale-neutral fmt instead of to_string
2021-08-28 18:26:18 -05:00
Triang3l
6ce5330f5f
[UI] Loop thread to main thread WindowedAppContext
2021-08-28 19:38:24 +03:00
gibbed
ed0a15dcc8
Use AppVeyor vars for extended version info.
2021-08-18 16:44:41 -05:00
sephiroth99
4861022158
[Base] Fix fpfs with GCC/Clang
...
The fpfs function is using strtof to convert a string to floating point
value, but the type may be a double. Using strtof in that case won't
provide enough precision, so switch to using strtod. When the type is a
float, the double will be down-converted to the correct value.
2021-08-08 10:23:52 -05:00
Triang3l
1cf12ec70b
[UI/HID] ui::VirtualKey enum
2021-07-01 23:32:26 +03:00
Joel Linn
480791a056
[Base] Implement message boxes on Linux
2021-06-29 20:41:20 -05:00
gibbed
f2a68e4b85
[Base] ByteStream assert cleanup.
2021-06-28 20:32:52 -05:00
gibbed
a12f775c23
[Base] LaunchWebBrowser now takes a string view.
2021-06-28 20:32:52 -05:00
gibbed
f4cfa65c7a
[Base] Fix natvis for new endian_store.
2021-06-28 20:32:52 -05:00
gibbed
92242f3f7d
[Base] Attach console on cvar help/failure.
...
[Base] Attempt attaching to console on cvar help/failure.
2021-06-28 11:57:06 -05:00
gibbed
80cafd9358
[Base] Clean up simple message box utility.
2021-06-28 11:57:06 -05:00
ztjohnst
bf5f700f9e
[Base] Fix invalid cvar args causing silent exit.
...
[Base] Fix invalid cvar arguments causing Xenia to silently exit.
2021-06-28 10:31:18 -05:00
ztjohnst
a77ed6f4a7
[Base] Add ShowInfoMB / ShowErrorMB functions.
...
[Base] Add ShowInfoMessageBox / ShowErrorMessageBox functions.
2021-06-28 10:31:18 -05:00
ztjohnst
be1a666066
[Base] Change behavior of has_console_attached().
...
[Base] Change has_console_attached() so that it no longer proves true
if Xenia is launched from a Windows Terminal.
2021-06-28 10:31:18 -05:00
gibbed
5c516cc341
Add missing break in logging.
2021-06-26 12:44:21 -05:00
gibbed
6bd96a5091
Remove unconditional block in logging.
...
Remove unconditional block in logging. This was done so the previous
commit shows an actual useful diff.
2021-06-26 12:26:10 -05:00
gibbed
458dbba4ae
Ensure that logging waits before shutting down.
...
- Ensure that logging waits until everything is written before shutting
down.
- Fix a bug where a new log line would not be written until the next
log line had been appended.
2021-06-26 12:26:10 -05:00
Gliniak
1cc0c1c985
Added more UTF-8 path tests (fnfp & fbnfp).
...
Added more UTF-8 path tests (find_name_from_path &
find_base_name_from_path).
2021-06-25 23:35:56 -05:00
Rick Gibbed
0d3ef65dcd
Add more UTF-8 path tests.
...
Add more UTF-8 path tests to catch newly discovered issues.
2021-06-25 23:07:57 -05:00
Gliniak
dcffc1a4d5
[Base] Remove multiple trailing separators in path
2021-06-25 23:07:57 -05:00
Joel Linn
f6e48d5386
[Base] Fix Clock platform functions on POSIX.
2021-06-18 16:10:19 +03:00
Triang3l
866a29e153
[Base] saturate_signed NaN comment
2021-06-05 15:04:06 +03:00
Triang3l
3c20a83972
[Base] Float clamping cleanup
2021-06-05 14:55:55 +03:00
Joel Linn
10ff77a24f
[Base] Add workaround for GCC bug
...
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100801
2021-06-02 22:28:43 -05:00
Joel Linn
ceb382f8ec
Update Catch2 test framework
...
- Use their main() method to fix command line options. Fix CLion testing
- Change to correct tag syntax.
2021-06-02 22:28:43 -05:00
Joel Linn
0e019f96b4
[Base, Linux] Make thread exit non returning
...
- Use pthread_exit() instead of pthread_cancel() if current thread
- Modify tests to ensure Exit does not return
2021-06-02 22:28:43 -05:00
Joel Linn
d40dfa11c5
[Base] Use pragma pack for non msvc as well.
...
- Pack attributes may be ignored by GCC
2021-06-02 22:28:43 -05:00
Joel Linn
d55192ea30
[Base] Refactor byte_swap
...
- Use builtins on non MSVC compilers
- Use `if constexpr` to reduce explicit overloads and SFINAE overhead
2021-06-02 22:28:43 -05:00
Joel Linn
4800194f0d
[Base] Add faster bit_count variants
...
- Use C++20 `popcount()` when available
- Else use compiler specific built-ins
2021-06-02 22:28:43 -05:00
Joel Linn
e58686c9df
[Base] Add le<> type
...
- Addition to `be<>` type
2021-06-02 22:28:43 -05:00
Joel Linn
28ca58c0e9
[Base] Fix HighResolutionTimer
...
- Test was failing on Linux 5.11 and GLIBC 2.33
- `timer_t(0)` is a valid handle, so a `valid_` flag was added to guard
destruction
- Similar behaviour on Windows was fixed as well. The invalid values for
`HANDLE` are API dependent.
2021-06-02 22:28:43 -05:00
Joel Linn
86722be9ca
[Base] Make Arena alignment aware
...
- Add align parameter
- Templated Alloc() implicitly aligns type correctly
- Rewind may leak padding that was added due to alignment
2021-06-02 22:28:43 -05:00
Joel Linn
d8cfeac79f
[Base] Remove redundant copy and move operators
...
- Compiler is smart enough to use 128bit vector regs by itself
2021-06-02 22:28:43 -05:00
Joel Linn
4d0d3f3ad4
[Base] Fix semaphore test
...
- Was using `Sleep()`
- Replaced with atomic value and bool flag
2021-06-02 22:28:43 -05:00
Joel Linn
2d9462f02b
[Base] Fix unitialized variable in threading test
2021-06-02 22:28:43 -05:00