summaryrefslogtreecommitdiffstats
path: root/src/video_core/renderer_vulkan/vk_buffer_cache.cpp (follow)
Commit message (Collapse)AuthorAgeFilesLines
* vk_buffer_cache: Make use of designated initializers where applicableLioncash2020-07-161-30/+33
| | | | | Note: An array within CopyFrom() cannot be converted over yet, as it ICEs MSVC when converted over.
* gl_buffer_cache: Copy to buffers created as STREAM_READ before downloadingReinUsesLisp2020-06-261-3/+3
| | | | | | | | After marking buffers as resident, Nvidia's driver seems to take a slow path. To workaround this issue, copy to a STREAM_READ buffer and then call GetNamedBufferSubData on it. This is a temporary solution until we have asynchronous flushing.
* buffer_cache: Use buffer methods instead of cache virtual methodsReinUsesLisp2020-06-241-43/+46
|
* gl_buffer_cache: Mark buffers as residentReinUsesLisp2020-06-241-2/+2
| | | | | | Make stream buffer and cached buffers as resident and query their address. This allows us to use GPU addresses for several proprietary Nvidia extensions.
* buffer_cache: Avoid passing references of shared pointers and misc style changesReinUsesLisp2020-06-091-13/+9
| | | | | | | | | Instead of using as template argument a shared pointer, use the underlying type and manage shared pointers explicitly. This can make removing shared pointers from the cache more easy. While we are at it, make some misc style changes and general improvements (like insert_or_assign instead of operator[] + operator=).
* buffer_cache: Use boost::intrusive::set for cachingReinUsesLisp2020-05-211-0/+1
| | | | | | | | Instead of using boost::icl::interval_map for caching, use boost::intrusive::set. interval_map is intended as a container where the keys can overlap with one another; we don't need this for caching buffers and a std::set-like data structure that allows us to search with lower_bound is enough.
* vulkan: Remove unnecessary includesLioncash2020-04-291-4/+0
| | | | | | | Reduces some header churn and reduces rebuilds when some header internals change. While we're at it we can also resolve a missing include in buffer_cache.
* buffer_cache: Return handles instead of pointer to handlesReinUsesLisp2020-04-161-6/+6
| | | | | | | | | | | The original idea of returning pointers is that handles can be moved. The problem is that the implementation didn't take that in mind and made everything harder to work with. This commit drops pointer to handles and returns the handles themselves. While it is still true that handles can be invalidated, this way we get an old handle instead of a dangling pointer. This problem can be solved in the future with sparse buffers.
* renderer_vulkan: Drop Vulkan-HppReinUsesLisp2020-04-111-60/+89
|
* Buffer Cache: Use vAddr instead of physical memory.Fernando Sahmkow2020-04-061-4/+4
|
* vk_stream_buffer/vk_buffer_cache: Avoid halting and use generic cacheReinUsesLisp2020-01-061-0/+143
| | | | | | | | | | | | | | | | The stream buffer before this commit once it was full (no more bytes to write before looping) waiting for all previous operations to finish. This was a temporary solution and had a noticeable performance penalty in performance (from what a profiler showed). To avoid this mark with fences usages of the stream buffer and once it loops wait for them to be signaled. On average this will never wait. Each fence knows where its usage finishes, resulting in a non-paged stream buffer. On the other side, the buffer cache is reimplemented using the generic buffer cache. It makes use of the staging buffer pool and the new stream buffer.
* vk_buffer_cache: Temporarily remove buffer cacheReinUsesLisp2020-01-061-122/+0
| | | | This is intended for a follow up commit to avoid circular dependencies.
* core/memory: Migrate over GetPointer()Lioncash2019-11-271-3/+3
| | | | | With all of the interfaces ready for migration, it's trivial to migrate over GetPointer().
* core: Prepare various classes for memory read/write migrationLioncash2019-11-271-1/+3
| | | | | | | | | | Amends a few interfaces to be able to handle the migration over to the new Memory class by passing the class by reference as a function parameter where necessary. Notably, within the filesystem services, this eliminates two ReadBlock() calls by using the helper functions of HLERequestContext to do that for us.
* vk_scheduler: Drop execution context in favor of viewsReinUsesLisp2019-07-071-2/+2
| | | | | | | | | | | | | | Instead of passing by copy an execution context through out the whole Vulkan call hierarchy, use a command buffer view and fence view approach. This internally dereferences the command buffer or fence forcing the user to be unable to use an outdated version of it on normal usage. It is still possible to keep store an outdated if it is casted to VKFence& or vk::CommandBuffer. While changing this file, add an extra parameter for Flush and Finish to allow releasing the fence from this calls.
* video_core/engines: Remove unnecessary inclusions where applicableLioncash2019-04-061-0/+1
| | | | | | Replaces header inclusions with forward declarations where applicable and also removes unused headers within the cpp file. This reduces a few more dependencies on core/memory.h
* video_core: Amend constructor initializer list order where applicableLioncash2019-03-271-2/+2
| | | | | | | Specifies the members in the same order that initialization would take place in. This also silences -Wreorder warnings.
* gpu: Move GPUVAddr definition to common_types.bunnei2019-03-211-2/+1
|
* gpu: Use host address for caching instead of guest address.bunnei2019-03-151-10/+17
|
* video_core/engines: Remove unnecessary includesLioncash2019-03-061-1/+1
| | | | | | | | | Removes a few unnecessary dependencies on core-related machinery, such as the core.h and memory.h, which reduces the amount of rebuilding necessary if those files change. This also uncovered some indirect dependencies within other source files. This also fixes those.
* vk_buffer_cache: Implement a buffer cacheReinUsesLisp2019-03-011-0/+116
This buffer cache is just like OpenGL's buffer cache with some minor style changes. It uses VKStreamBuffer.