aboutsummaryrefslogtreecommitdiff
path: root/src/video_core/gpu.cpp
AgeCommit message (Collapse)Author
2023-06-03core: frontend: Refactor GraphicsContext to its own module.bunnei
2023-05-07GPU: Add Reactive flushingFernando Sahmkow
2023-03-05core_timing: Use higher precision sleeps on WindowsMorph
The precision of sleep_for and wait_for is limited to 1-1.5ms on Windows. Using SleepForOneTick() allows us to sleep for exactly one interval of the current timer resolution. This allows us to take advantage of systems that have a timer resolution of 0.5ms to reduce CPU overhead in the event loop.
2023-02-07Remove OnCommandListEndCommandBehunin
Call rasterizer->ReleaseFences() directly
2022-12-13renderer_opengl: refactor context acquireLiam
2022-10-06General: address feedbackFernando Sahmkow
2022-10-06VideoCore: Refactor fencing system.Fernando Sahmkow
2022-10-06NVDRV: Further refactors and eliminate old code.Fernando Sahmkow
2022-10-06NVDRV: Refactor Host1xFernando Sahmkow
2022-10-06VideoCore: Refactor syncing.Fernando Sahmkow
2022-10-06Texture cache: Fix the remaining issues with memory mnagement and unmapping.Fernando Sahmkow
2022-10-06NVHOST_CTRl: Implement missing method and fix some stuffs.Fernando Sahmkow
2022-10-06VideoCore: implement channels on gpu caches.Fernando Sahmkow
2022-04-23general: Convert source file copyright comments over to SPDXMorph
This formats all copyright comments according to SPDX formatting guidelines. Additionally, this resolves the remaining GPLv2 only licensed files by relicensing them to GPLv2.0-or-later.
2022-04-07video_core: Replace lock_guard with scoped_lockMerry
2022-02-01Rasterizer: Refactor inlineToMemory.Fernando Sahmkow
2022-01-29GPU: Improve syncing.Fernando Sahmkow
2022-01-29Rasterizer: Implement Inline2Memory Acceleration.Fernando Sahmkow
2022-01-04Merge pull request #7636 from vonchenplus/buffer_queue_querybunnei
core:hle:service:nvflinger Implement few type in bufferqueue query method
2022-01-03gpu: Add shut down method to synchronize threads before destructionameerj
2022-01-03Revert "Merge pull request #7668 from ameerj/fence-stop-token"ameerj
This reverts commit e7733544779f2706d108682dd027d44e7fa5ff4b, reversing changes made to abbbdc2bc027ed7af236625ae8427a46df63f7e7.
2022-01-03gpu: Use std::stop_token in WaitFence for VSync threadameerj
Fixes a hang that may occur when stopping emulation and the VSync thread is blocked on the syncpoint condition variable.
2021-12-28Remove invalid header includeFeng Chen
2021-12-05Address feedbackFeng Chen
2021-12-02Support multiple videos playingFeng Chen
2021-10-03nvhost_ctrl: Refactor usage of gpu.LockSync()ameerj
This seems to only be used to protect a later gpu function call. So we can move the lock into that call instead.
2021-10-03gpu: Migrate implementation to the cpp fileameerj
2021-09-15gpu: Use std::jthread for async gpu threadameerj
2021-07-11accelerateDMA: Accelerate Buffer Copies.Fernando Sahmkow
2021-07-09Fence Manager: Add fences on Reference Count.Fernando Sahmkow
2021-05-29video_core: gpu: WaitFence: Do not block threads during shutdown.bunnei
- Fixes a hang on shutdown when NVFlinger thread is waiting on a syncpoint that will never occur. - Commonly observed when stopping emulation in Super Mario Odyssey.
2021-05-15perf_stats: Rework FPS counter to be more accurateameerj
The FPS counter was based on metrics in the nvdisp swapbuffers call. This metric would be accurate if the gpu thread/renderer were synchronous with the nvdisp service, but that's no longer the case. This commit moves the frame counting responsibility onto the concrete renderers after their frame draw calls. Resulting in more meaningful metrics. The displayed FPS is now made up of the average framerate between the previous and most recent update, in order to avoid distracting FPS counter updates when framerate is oscillating between close values. The status bar update frequency was also changed from 2 seconds to 500ms.
2021-04-24nvhost_vic: Fix device closureameerj
Implements the OnClose method of the nvhost_vic device, and removes the remnants of an older implementation. Also cleans up some of the surrounding code.
2021-04-16Merge pull request #6125 from ogniK5377/nvdec-close-devbunnei
nvdrv: Cleanup CDMA Processor on device closure
2021-04-16Address issuesChloe Marcec
2021-04-14common: Move settings to common from core.bunnei
- Removes a dependency on core and input_common from common.
2021-04-07video_core/gpu_thread: Implement a ShutDown method.Markus Wick
This was implicitly done by `is_powered_on = false`, however the explicit method allows us to block until the GPU is actually gone. This should fix a race condition while removing the other subsystems while the GPU is still active.
2021-03-30nvdrv: Cleanup CDMA Processor on device closureChloe Marcec
Brings us a step closer to unifying all channels to share a common interface.
2021-02-28gpu_thread: Remove Async NVDEC placeholdersameerj
This commit removes early placeholders for an implementation of async nvdec. With recent changes to the source code, the placeholders are no longer accurate, and can cause a nullptr dereference due to the nature of the cdma_pusher lifetime.
2021-02-13 rebase, fix name shadowing, more constameerj
2021-02-13nvdec cleanupameerj
2021-02-13gpu: Report renderer errors with exceptionsReinUsesLisp
Instead of using a two step initialization to report errors, initialize the GPU renderer and rasterizer on the constructor and report errors through std::runtime_error.
2020-12-28video_core: gpu: Implement synchronous mode using threaded GPU.bunnei
2020-12-28video_core: gpu: Refactor out synchronous/asynchronous GPU implementations.bunnei
- We must always use a GPU thread now, even with synchronous GPU.
2020-12-07video_core: Remove unnecessary enum class casting in logging messagesLioncash
fmt now automatically prints the numeric value of an enum class member by default, so we don't need to use casts any more. Reduces the line noise a bit.
2020-12-04video_core: Resolve more variable shadowing scenariosLioncash
Resolves variable shadowing scenarios up to the end of the OpenGL code to make it nicer to review. The rest will be resolved in a following commit.
2020-11-24nvdrv, video_core: Don't index out of bounds when given invalid syncpoint IDcomex
- Use .at() instead of raw indexing when dealing with untrusted indices. - For the special case of WaitFence with syncpoint id UINT32_MAX, instead of crashing, log an error and ignore. This is what I get when running Super Mario Maker 2.
2020-11-01video_core: gpu: Implement WaitFence and IncrementSyncPoint.bunnei
2020-10-26video_core: NVDEC Implementationameerj
This commit aims to implement the NVDEC (Nvidia Decoder) functionality, with video frame decoding being handled by the FFmpeg library. The process begins with Ioctl commands being sent to the NVDEC and VIC (Video Image Composer) emulated devices. These allocate the necessary GPU buffers for the frame data, along with providing information on the incoming video data. A Submit command then signals the GPU to process and decode the frame data. To decode the frame, the respective codec's header must be manually composed from the information provided by NVDEC, then sent with the raw frame data to the ffmpeg library. Currently, H264 and VP9 are supported, with VP9 having some minor artifacting issues related mainly to the reference frame composition in its uncompressed header. Async GPU is not properly implemented at the moment. Co-Authored-By: David <25727384+ogniK5377@users.noreply.github.com>
2020-09-06video_core: Remove all Core::System references in rendererReinUsesLisp
Now that the GPU is initialized when video backends are initialized, it's no longer needed to query components once the game is running: it can be done when yuzu is booting. This allows us to pass components between constructors and in the process remove all Core::System references in the video backend.