| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
| |
Allows the use of the macro in constexpr-contexts.
Also avoids some potential problems when nesting braces inside it.
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
| |
Adds the PushModes Try and Wait to allow producers to specify how they want to push their data to the queue if the queue is full.
If the queue is full:
- Try will fail to push to the queue, returning false. Try only returns true if it successfully pushes to the queue. This may result in items not being pushed into the queue.
- Wait will wait until a slot is available to push to the queue, resulting in potential for deadlock if a consumer is not running.
|
|
|
|
| |
Provides a simplified SPSC, MPSC, and MPMC bounded queue implementation using mutexes.
|
|\
| |
| | |
gpu_thread: Use bounded queue
|
| | |
|
|/
|
|
| |
And also demote Audren and CoreTiming to High thread priority.
|
|
|
|
| |
Call rasterizer->ReleaseFences() directly
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
The bounded MPSCQueue implementation causes crashes in Fire Emblem Three Houses, use the previous implementation for now.
|
| |
|
| |
|
|
|
|
|
| |
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.
|
| |
|
| |
|
| |
|
|
|
|
| |
- Removes a dependency on core and input_common from common.
|
|
|
|
| |
There is no need for a busy loop here. Let's just use a condition variable to save some power.
|
|
|
|
|
| |
Else the fence might get submited out-of-order into the queue, which makes testing them pointless.
Overhead should be tiny as the mutex is just moved from the queue to the writing code.
|
|
|
|
|
|
| |
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.
|
|
|
|
|
|
|
| |
It shall block until there is something to consume in the queue.
And use it for the GPU emulation instead of the spin loop.
This is only in booting the emulator, however in BOTW this is the case for about 1 second.
|
|
|
|
| |
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.
|
| |
|
| |
|
|
|
|
|
|
| |
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.
|
| |
|
| |
|
| |
|
|
|
|
|
|
| |
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.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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>
|
|
|
|
| |
Silences several compiler warnings about unused variables.
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Changes the GraphicsContext to be managed by the GPU core. This
eliminates the need for the frontends to fool around with tricky
MakeCurrent/DoneCurrent calls that are dependent on the settings (such
as async gpu option).
This also refactors out the need to use QWidget::fromWindowContainer as
that caused issues with focus and input handling. Now we use a regular
QWidget and just access the native windowHandle() directly.
Another change is removing the debug tool setting in FrameMailbox.
Instead of trying to block the frontend until a new frame is ready, the
core will now take over presentation and draw directly to the window if
the renderer detects that its hooked by NSight or RenderDoc
Lastly, since it was in the way, I removed ScopeAcquireWindowContext and
replaced it with a simple subclass in GraphicsContext that achieves the
same result
|
| |
|
|
|
|
|
| |
We can just use std::nullopt and std::make_optional to make this a
little bit less noisy.
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
| |
This commit uses guest fences on vSync event instead of an articial fake
fence we had.
It also corrects to keep signaling display events while loading the game
as the OS is suppose to send buffers to vSync during that time.
|
| |
|
| |
|
| |
|
|
|
|
| |
Async GPU: Always invalidate synced.
|
|
|
|
|
| |
Makes the interface more type-safe and consistent in terms of return
values.
|
|
|
|
|
| |
With C++17's deduction guides, the type doesn't need to be explicitly
specified within locking primitives anymore.
|
|
|
|
|
|
|
|
|
| |
Instead of retrieving the data from the std::variant instance, we can
just check if the variant contains that type of data.
This is essentially the same behavior, only it returns a bool indicating
whether or not the type in the variant is currently active, instead of
actually retrieving the data.
|
|
|
|
|
|
|
|
|
| |
Like with CPU emulation, we generally don't want to fire off the threads
immediately after the relevant classes are initialized, we want to do
this after all necessary data is done loading first.
This splits the thread creation into its own interface member function
to allow controlling when these threads in particular get created.
|
|
|
|
|
|
|
| |
Since c5d41fd812d7eb1a04f36b76c08fe971cee0868c callback parameters were
changed to use an s64 to represent late cycles instead of an int, so
this was causing a truncation warning to occur here. Changing it to s64
is sufficient to silence the warning.
|
| |
|
|
|
|
|
|
| |
The pusher instance is only ever used in the constructor of the
ThreadManager for creating the thread that the ThreadManager instance
contains. Aside from that, the member is unused, so it can be removed.
|
| |
|
| |
|
| |
|
| |
|
|
|