aboutsummaryrefslogtreecommitdiff
path: root/src/common
Commit message (Collapse)AuthorAgeFilesLines
* string_util: Remove ArrayToString()Lioncash2018-11-132-21/+0
| | | | | | | | An old function from Dolphin. This is also unused, and pretty inflexible when it comes to printing out different data types (for example, one might not want to print out an array of u8s but a different type instead. Given we use fmt, there's no need to keep this implementation of the function around.
* string_util: Remove TryParse()Lioncash2018-11-132-54/+3
| | | | | | This is an unused hold-over from Dolphin that was primarily used to parse values out of the .ini files. Given we already have libraries that do this for us, we don't need to keep this around.
* string_util: Remove ThousandSeparate()Lioncash2018-11-131-14/+0
| | | | | This is currently unused and doesn't really provide much value to keep around either.
* Merge pull request #1441 from CarlKenner/DebuggerLogbunnei2018-11-052-2/+23
|\ | | | | logging: Add DebuggerBackend for logging to Visual Studio
| * logging: Add DebuggerBackend for logging to Visual StudioCarl Kenner2018-10-072-2/+23
| |
* | compatdb: Use a seperate endpoint for testcase submissionfearlessTobi2018-10-281-0/+4
| |
* | logging/backend: Add missing services to the log filtersLioncash2018-10-232-0/+5
| | | | | | | | Just a few overlooked services.
* | common: Remove memory_util.cpp/.hLioncash2018-10-233-200/+0
| | | | | | | | | | | | | | | | Everything from here is completely unused and also written with the notion of supporting 32-bit architecture variants in mind. Given the Switch itself is on a 64-bit architecture, we won't be supporting 32-bit architectures. If we need specific allocation functions in the future, it's likely more worthwhile to new functions for that purpose.
* | only redefine 64 bit file operation for MSVCWeiyi Wang2018-10-231-5/+8
| | | | | | | | MinGW provides POSIX functions
* | service: Add skeleton for psm serviceZach Hilman2018-10-201-0/+1
| | | | | | | | Seems to be the power controller. Listed in switchbrew under the category PTM services.
* | common: Add function for checking word alignment to alignment.hLioncash2018-10-181-0/+6
| | | | | | | | | | This will be used in a following change to svcArbitrateLock() and svcArbitrateUnlock()
* | common: Move Is4KBAligned() to alignment.hLioncash2018-10-181-0/+6
| | | | | | | | | | Aligning on 4KB pages isn't a Switch-specific thing, so this can be moved to common so it can be used with other things as well.
* | web_backend: Make Client use the PImpl idiomLioncash2018-10-101-0/+1
| | | | | | | | | | | | Like with TelemetryJson, we can make the implementation details private and avoid the need to expose httplib to external libraries that need to use the Client class.
* | Merge pull request #1424 from DarkLordZach/ips-witchbunnei2018-10-082-0/+24
|\ \ | | | | | | ips_layer: Add support for IPSwitch executable patches
| * | ips_layer: Deduplicate resource usageZach Hilman2018-10-042-2/+2
| | |
| * | hex_util: Add HexVectorToString and HexStringToVectorZach Hilman2018-10-042-0/+24
| | | | | | | | | | | | Converts between bytes and strings when the size is not known at compile time.
* | | Merge pull request #1453 from FearlessTobi/port-4311bunnei2018-10-061-1/+1
|\ \ \ | | | | | | | | Port citra-emu/citra#4311: "Remove "#" in the version number"
| * | | Remove "#" in the version numberfearlessTobi2018-10-061-1/+1
| | |/ | |/| | | | | | | So that people can stop using it in issue/pr comments and randomly link some other issue/pr unintentionally.
* / | citra_qt/configuration: misc input tab improvementszhupengfei2018-10-062-1/+19
|/ / | | | | | | | | | | | | | | * Added a context menu on the buttons including Clear & Restore Default * Allow clearing (unsetting) inputs. Added a Clear All button * Allow restoring a single input to default (instead of all)
* | Merge pull request #1332 from FearlessTobi/port-web-backendbunnei2018-10-064-0/+108
|\ \ | | | | | | Port web_service from Citra
| * | Review comments - part 5fearlessTobi2018-10-021-0/+1
| | |
| * | Address a bunch of review commentsfearlessTobi2018-10-021-1/+1
| | |
| * | Port web_service from CitrafearlessTobi2018-10-024-0/+107
| | |
* | | Merge pull request #1442 from lioncash/formatbunnei2018-10-051-1/+1
|\ \ \ | |_|/ |/| | text_formatter: Avoid unnecessary string temporary creation in PrintMessage()
| * | text_formatter: Avoid unnecessary string temporary creation in PrintMessage()Lioncash2018-10-041-1/+1
| |/ | | | | | | | | | | | | | | | | operator+ for std::string creates an entirely new string, which is kind of unnecessary here if we just want to append a null terminator to the existing one. Reduces the total amount of potential allocations that need to be done in the logging path.
* | string_util: unify UTF8<->UTF16 conversion to codecvtWeiyi Wang2018-10-021-109/+6
| |
* | string_util: remove TString conversion for windowsWeiyi Wang2018-10-022-19/+1
| | | | | | | | First of all they are foundamentally broken. As our convention is that std::string is always UTF-8, these functions assume that the multi-byte character version of TString (std::string) from windows is also in UTF-8, which is almost always wrong. We are not going to build multi-byte character build, and even if we do, this dirty work should be handled by frontend framework early.
* | string_util: remove ShiftJIS/CP1252 conversion functionWeiyi Wang2018-10-022-22/+0
|/ | | | We always use unicode internally. Any dirty work of conversion with other codec should be handled by frontend framework (Qt). Further more, ShiftJIS/CP1252 are not special (they are not code set used by 3ds, or any guest/host dependencies we have), so there is no reason to specifically include them
* Merge pull request #1365 from DarkLordZach/lfsbunnei2018-09-253-0/+6
|\ | | | | file_sys: Add support for LayeredFS mods
| * common_paths: Add Load and Dump dirsZach Hilman2018-09-213-0/+6
| |
* | Stubbed IRS (#1349)David2018-09-232-0/+2
| | | | | | | | | | | | | | | | | | | | * Stubbed IRS Currently we have no ideal way of implementing IRS. For the time being we should have the functions stubbed until we come up with a way to emulate IRS properly. * Added IRS to logging backend * Forward declared shared memory for irs
* | common/thread: remove YieldCPU()Weiyi Wang2018-09-221-8/+0
|/ | | | simply use the standard library yield()
* ring_buffer: Use std::atomic_size_t in a static assertLioncash2018-09-181-1/+1
| | | | Avoids the need to repeat "std::" twice
* ring_buffer: Use std::hardware_destructive_interference_size to determine ↵Lioncash2018-09-181-2/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | alignment size for avoiding false sharing MSVC 19.11 (A.K.A. VS 15.3)'s C++ standard library implements P0154R1 (http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2016/p0154r1.html) which defines two new constants within the <new> header, std::hardware_destructive_interference_size and std::hardware_constructive_interference_size. std::hardware_destructive_interference_size defines the minimum recommended offset between two concurrently-accessed objects to avoid performance degradation due to contention introduced by the implementation (with the lower-bound being at least alignof(max_align_t)). In other words, the minimum offset between objects necessary to avoid false-sharing. std::hardware_constructive_interference_size on the other hand defines the maximum recommended size of contiguous memory occupied by two objects accessed wth temporal locality by concurrent threads (also defined to be at least alignof(max_align_t)). In other words the maximum size to promote true-sharing. So we can simply use this facility to determine the ideal alignment size. Unfortunately, only MSVC supports this right now, so we need to enclose it within an ifdef for the time being.
* Port #4182 from Citra: "Prefix all size_t with std::"fearlessTobi2018-09-1523-135/+140
|
* common: Implement a ring bufferMerryMage2018-09-082-0/+112
|
* Better Title Bar DisplayCaptV0rt3x2018-09-073-5/+25
|
* common/logging: Amend documentation commentsLioncash2018-09-042-6/+6
| | | | | | | Multi-line doc comments still need the '<' after the ///, otherwise it's treated as a regular comment and makes the original doc comment broken in viewers, IDEs, etc. While we're at it, also fix some typos in the comments.
* common/logging/filter: Replace C-style case with C++ static_castLioncash2018-09-041-1/+1
|
* common/logging/filter: Make constructor explicitLioncash2018-09-041-1/+1
| | | | Implicit conversions aren't desirable here.
* Merge pull request #1170 from lioncash/retbunnei2018-08-271-1/+1
|\ | | | | file_util: Correct return value in early exit of ReadFileToString()
| * file_util: Correct return value in early exit of ReadFileToString()Lioncash2018-08-241-1/+1
| | | | | | | | | | While still essentially being zero, we should be returning a numeric value here, not a boolean typed value.
* | hex_util: Replace logic_errors with LOG_CRITICALZach Hilman2018-08-231-5/+17
|/ | | | Makes it so malformed hex strings do not crash the entire program.
* logging/text_formatter: Use empty braces for initializing ↵Lioncash2018-08-211-1/+1
| | | | | | | | | CONSOLE_SCREEN_BUFFER_INFO instance The previous form of initializing done here is a C-ism, an empty set of braces is sufficient for initializing (and doesn't potentially cause missing brace warnings, given the first member of the struct is a COORD struct).
* bit_field: Convert ToBool() into explicit operator boolLioncash2018-08-211-2/+1
| | | | Gets rid of a TODO that is long overdue.
* Merge pull request #1064 from lioncash/telemetrybunnei2018-08-202-0/+77
|\ | | | | common/telemetry: Migrate core-independent info gathering to common
| * common/telemetry: Migrate core-independent info gathering to commonLioncash2018-08-142-0/+77
| | | | | | | | | | | | | | | | | | | | | | | | Previously core itself was the library containing the code to gather common information (build info, CPU info, and OS info), however all of this isn't core-dependent and can be moved to the common code and use the common interfaces. We can then just call those functions from the core instead. This will allow replacing our CPU detection with Xbyak's which has better detection facilities than ours. It also keeps more architecture-dependent code in common instead of core.
* | common: Namespace hex_util.h/.cppLioncash2018-08-152-0/+8
| | | | | | | | | | It's in the common code, so it should be under the Common namespace like everything else.
* | Merge pull request #1005 from DarkLordZach/registered-fmtbunnei2018-08-155-0/+74
|\ \ | | | | | | file_sys: Add support for registration format
| * | file_sys: Comply to style guidelinesZach Hilman2018-08-111-0/+2
| | |