summaryrefslogtreecommitdiff
path: root/src/common
AgeCommit message (Collapse)Author
2021-06-24Merge pull request #6519 from Wunkolo/mem-size-literalbunnei
common: Replace common_sizes into user-literals
2021-06-24common: Replace common_sizes into user-literalsWunkolo
Removes common_sizes.h in favor of having `_KiB`, `_MiB`, `_GiB`, etc user-literals within literals.h. To keep the global namespace clean, users will have to use: ``` using namespace Common::Literals; ``` to access these literals.
2021-06-24general: Add missing #pragma once directivesMorph
2021-06-23Merge pull request #6517 from lioncash/fmtlibbunnei
externals: Update fmt to 8.0.0
2021-06-23General: Resolve fmt specifiers to adhere to 8.0.0 API where applicableLioncash
Also removes some deprecated API usages.
2021-06-23Merge pull request #6465 from FernandoS27/sex-on-the-beachMai M
GPU: Implement a garbage collector for GPU Caches (project Reaper+)
2021-06-22Merge pull request #6512 from ReinUsesLisp/wait-detached-stasksMai M
common/detached_tasks: Wait for tasks before shutting down
2021-06-22common: fs: Add a description of a regular file in IsFileMorph
This provides a more concrete example of what a regular file is and isn't.
2021-06-22common: fs: Amend IsFile check in FileOpen / (Write/Append)StringToFileMorph
This check was preventing files with the Write or Append file access modes from being created, as per the documented behavior in FileAccessMode. This amends the check to test for the existence of a filesystem object prior to checking whether it is a regular file. Thanks to liushuyu for pointing out that removing the check altogether would not guard against attempting to open non-regular files such as directories, symlinks, FIFO (pipes), sockets, block devices, or character devices. The documentation has also been updated for these functions to clarify that a file refers to a regular file.
2021-06-22common: fs: file: Remove [[nodiscard]] attribute from FlushMorph
Similarly, Flush() is typically called to attempt to flush a file into the disk. In the one case where this is used, we do not care whether the flush has succeeded or not, making [[nodiscard]] unnecessary.
2021-06-22common: fs: Remove [[nodiscard]] attribute on Remove* functionsMorph
There are a lot of scenarios where we don't particularly care whether or not the removal operation and just simply attempt a removal. As such, removing the [[nodiscard]] attribute is best for these functions.
2021-06-22common/detached_tasks: Wait for tasks before shutting downRodrigo Locatti
If this is not waited on, the synchronization primitives are destroyed whe main exits and the detached task ends up signalling garbage and not properly finishing.
2021-06-21Merge pull request #6499 from FernandoS27/we-were-on-a-breakbunnei
Update dynarmic and add new unsafe CPU option.
2021-06-21Merge pull request #6475 from ameerj/unlimit-fpsbunnei
nvflinger: Add experimental toggle to disable buffer swap interval limits
2021-06-20Update dynarmic and add new unsafe CPU option.Fernando Sahmkow
2021-06-19host_memory: Correct MEM_RESERVE_PLACEHOLDERlat9nq
Microsoft defines `MEM_RESERVE_PLACEHOLDER` as `0x00040000`, but our manually imported version of it drops the last zero.
2021-06-17nvflinger: Add toggle to disable buffer swap interval limitsameerj
Enabling this setting will allow some titles to present more frames to the screen as they become available in the nvflinger buffer queue.
2021-06-16Reaper: Address Feedback.Fernando Sahmkow
2021-06-16Reaper: Setup settings and final tuning.Fernando Sahmkow
2021-06-16Merge pull request #6464 from ameerj/disable-astcbunnei
textures: Add a toggle for GPU Accelerated ASTC decoder
2021-06-16Merge pull request #6460 from Morph1984/fs-access-log-fixMorph
fsp_srv: Fix filesystem access logging
2021-06-16common: fs: file: Remove redundant call to WriteStringToFileMorph
The Append open mode will create a new file if said file does not exist at a given path, making this call redundant.
2021-06-16fsp_srv: Fix filesystem access loggingMorph
This introduces a new setting Enable FS Access Log which saves the filesystem access log to sdmc:/FsAccessLog.txt If this setting is not enabled, this will indicate to FS to not call OutputAccessLogToSdCard. Fixes softlocks during loading in Xenoblade Chronicles 2 when certain DLC is enabled.
2021-06-15Merge pull request #6462 from Morph1984/proper-flushbunnei
common: fs: file: Flush the file to the disk when Flush() is called
2021-06-15configure_graphics: Add Accelerate ASTC decoding settingameerj
2021-06-14Merge pull request #6448 from Morph1984/recursive-dir-iteratorFernando Sahmkow
common: fs: Use the normal directory iterator in *Recursively functions
2021-06-13common: logging: Restructure backend codeMorph
2021-06-13common: logging: backend: Wrap IOFile in a unique_ptrMorph
Allows us to forward declare Common::FS::IOFile.
2021-06-13common: fs: file: Flush the file to the disk when Flush() is calledMorph
std::fflush does not guarantee that file buffers are flushed to the disk. Use _commit on Windows and fsync on all other OSes to ensure that the file is flushed to the disk.
2021-06-12common: fs: Use the normal directory iterator in *Recursively functionsMorph
MSVC's implementation of recursive_directory_iterator throws an exception on an error despite a std::error_code being passed into its constructor. This is most likely a bug in MSVC's implementation since directory_iterator does not throw an exception on an error. We can replace the usage of recursive_directory_iterator for now until MSVC fixes their implementation of it.
2021-06-11common/host_memory: Implement a fallback if fastmem fails.Markus Wick
This falls back to the old approach of using a virtual buffer. Windows is untested, but this build should fix support for Windows < 10 v1803. However without fastmem support at all.
2021-06-11common/host_shader: Load Windows 10 functions dynamicallyReinUsesLisp
Workaround old headers and libraries shipped on MinGW.
2021-06-11host_memory: Support staged VirtualProtect callsReinUsesLisp
2021-06-11General: Add settings for fastmem and disabling adress space check.FernandoS27
2021-06-11common/host_memory: Optimize for huge tables.Markus Wick
In theory, if we have 2 MB continously mapped, this should save one layer of TLB. Let's make it at least more likely by aligning the memory.
2021-06-11core: Make use of fastmemMarkus Wick
2021-06-11common/host_memory: Add Linux implementationMarkus Wick
2021-06-11common/host_memory: Add interface and Windows implementationReinUsesLisp
2021-06-09src/common/CMakeLists.txt: fix variable escapingliushuyu
2021-06-08common/fs/path_util: Remove [[nodiscard]] from function with void returnLioncash
We can't make use of the return value here, since we don't a return value to work with.
2021-06-02Merge pull request #6395 from lioncash/result-moveMorph
common_funcs: Move R_ macros to result.h
2021-06-02common: fs: fs_util: Move PathToUTF8String to fs_utilMorph
2021-06-02common: fs: fs_util: Add more string conversion functionsMorph
2021-05-31common_funcs: Move R_ macros to result.hLioncash
These macros all interact with the result code type, so they should ideally be within this file as well, so all the common_funcs machinery doesn't need to be pulled in just to use them.
2021-05-30Merge pull request #6385 from degasus/save_memory_accessbunnei
core/memory: Check our memory fallbacks for out-of-bound behavior.
2021-05-29core/memory: Check our memory fallbacks for out-of-bound behavior.Markus Wick
This makes it by far harder to crash yuzu. Also implement the 48bit masking of AARCH64 while touching this code.
2021-05-28common: Extract point into a common structLioncash
This is generic enough that it can be moved into the Common class for reuse.
2021-05-28common/fs/file: Explicitly delete copy constructorsLioncash
Relocates them to the same place the move equivalents are at for consistent viewing.
2021-05-28common/fs/file: Devirtualize destructorLioncash
IOFile is a final class, so there's no need for a virtual destructor.
2021-05-28common/fs/file: Default initialize IOFile membersLioncash
Prevents a potential uninitialized read vector in the move constructor.