Commit Graph

5712 Commits (0e13d9cb7b04bee397f4f3ed7a02e78685b1b386)

Author SHA1 Message Date
Subv 72b5c448cf GPU: Implemented nvhost-as-gpu's UnmapBuffer ioctl.
It removes a mapping previously created with the MapBufferEx ioctl.
8 years ago
Sebastian Valle 03388c3071
Merge pull request #450 from Subv/shader_link_error
GLRenderer: Log the shader source code when program linking fails.
8 years ago
Sebastian Valle 353e1dd7e4
Merge pull request #443 from ogniK5377/ipc-500
Added IPC RequestWithContext & ControlWithContext
8 years ago
greggameplayer a215f63235 Add and correct some Error Modules (#444)
* Add and correct some Error Modules
8 years ago
Subv 2a35a36251 Kernel/SVC: Signal the highest priority threads first in svcSignalProcessWideKey. 8 years ago
Subv c74f2555b6 Kernel/Threads: Reschedule the proper core when operating on that core's threads. 8 years ago
Subv fab3dd98fe SVC: Removed unused WaitSynchronization1 function 8 years ago
Subv c50393e066 Qt/WaitTree: Display the callstack for each thread in the wait tree widget. 8 years ago
Subv a056d5ad8c ShadersDecompiler: Added decoding for the PSETP instruction. 8 years ago
Subv 98b143c2d6 GLRenderer: Remove unused hw_vao_enabled_attributes variable. 8 years ago
Subv 370ab5df9b GLRenderer: Remove unused vertex buffer and increase the size of the stream buffer to 128 MB.
The stream buffer is where all the vertex data is copied, some games require this to be much bigger than the 4 MB we used to have.
8 years ago
Subv 21959ddfef GLRenderer: Log the shader source code when program linking fails. 8 years ago
greggameplayer abe79b2724
rename fatal:u functions & add ThrowFatal 8 years ago
greggameplayer 536cfb13e6
Properly update fatal.h void name 8 years ago
greggameplayer e35cfc1b03
Properly rename fatal module functions 8 years ago
David Marcec fd86cdb2e2 Added RequestWithContext & ControlWithContext 8 years ago
Hexagon12 0984e9d601 Updated nfp with more service names 8 years ago
bunnei 1b5c02fc37
Merge pull request #436 from bunnei/multi-core
Initial support for multi-core
8 years ago
David Marcec e7b0e8a3cc More accurate GetTPCMasks impl 8 years ago
bunnei 811dae12f9 core: Add several missing docstrings. 8 years ago
bunnei 46ec9a9bc9 thread: Rename mask to affinity_masks. 8 years ago
bunnei edc52250b8 core: Run all CPU cores separately, even in single-thread mode. 8 years ago
bunnei fbd7afefaa thread: Support core change on ResumeFromWait and improve ChangeCore. 8 years ago
bunnei 91af2f94e8 scheduler: Protect scheduling functions with a global mutex. 8 years ago
bunnei e6671190a5 wait_tree: Add ideal core and affinity mask. 8 years ago
bunnei 4822765fef thread: Initialize ideal_core and mask members. 8 years ago
bunnei 8aa5d25f82 threading: Reschedule only on cores that are necessary. 8 years ago
bunnei d6e3cd9a17 svc: Implement GetThreadCoreMask and SetThreadCoreMask. 8 years ago
bunnei 6ea8b3ef60 thread: Implement ChangeCore function. 8 years ago
bunnei 1c36f2a798 svc: SignalProcessWideKey should apply to all cores. 8 years ago
bunnei 6a890023e9 svc: Implement GetCurrentProcessorNumber. 8 years ago
bunnei 5c0421ebd8 wait_tree: Show all threads on all schedulers. 8 years ago
bunnei 9bf2a428f9 core: Add a configuration setting for use_multi_core. 8 years ago
bunnei cba69fdcd4 core: Support session close with multicore. 8 years ago
bunnei a434fdcb10 core: Implement multicore support. 8 years ago
bunnei 9776ff9179 core: Create a thread for each CPU core, keep in lock-step with a barrier. 8 years ago
bunnei 5590245930 core: Move common CPU core things to its own class. 8 years ago
Hexagon12 5e9c547952 Stubs for QLaunch (#428)
* Stubs for QLaunch

* Wiped unrelated stuff

* Addressed comment

* Dropped GetPopFromGeneralChannelEvent
8 years ago
Max Thomas 266703b50e hid: Tweaks, Analog Sticks (#435)
* hid: Update mouse/keyboard state

* hid: Working analog sticks

* hid: Nits

* hid: Nits

* hid: Update mystery sections

* hid: Tweaks
8 years ago
bunnei 9eccb5de9d
Merge pull request #434 from lioncash/vdtor
memory_hook: Default virtual destructor in the cpp file
8 years ago
Lioncash 732a77d0e8
memory_hook: Default virtual destructor in the cpp file
Prevents creating multiple copies of the vtable in every translation unit that uses the class.
Also silences a -Wweak-vtables warning
8 years ago
Lioncash 9f3641755e
core_timing: Don't include the log header in core timing's header
Avoids propagating logging macros and facilities to files that may not need them.
This also allows hiding an internal constant.
8 years ago
bunnei 1147db9dd1
Merge pull request #431 from lioncash/fmt
general: Make formatting of logged hex values more straightforward
8 years ago
bunnei b1a8e5914b
Merge pull request #430 from lioncash/vec
vector_math: Ensure members are always initialized
8 years ago
Lioncash 7c9644646f
general: Make formatting of logged hex values more straightforward
This makes the formatting expectations more obvious (e.g. any zero padding specified
is padding that's entirely dedicated to the value being printed, not any pretty-printing
that also gets tacked on).
8 years ago
bunnei fadab1d5f3 ipc: Add support for PopIpcInterface() method.
- This can be used for domain objects as inputs to service functions.
8 years ago
Lioncash acc10c7ee2 vector_math: Ensure members are always initialized
Ensures that values are always in a well-defined state.
8 years ago
bunnei 8262aeeac8
Merge pull request #429 from Subv/ioctl_corruption
GPU: Don't write to invalid memory locations when handling ioctls that don't have an output.
8 years ago
David ff2f0d980a GetSharedFontInOrderOfPriority (#381)
* GetSharedFontInOrderOfPriority

* Update pl_u.cpp

* Ability to use ReadBuffer and WriteBuffer with different buffer indexes, fixed up GetSharedFontInOrderOfPriority

* switched to NGLOG

* Update pl_u.cpp

* Update pl_u.cpp

* language_code is actually language code and not index

* u32->u64

* final cleanups
8 years ago
Subv 0c8b7c00e8 GPU: Don't write to invalid memory locations when handling ioctls that don't have an output. 8 years ago
Lioncash 0197e28cc9
core_timing: Namespace all functions and constants in core_timing's header
All of these variables and functions are related to timings and should be within the namespace.
8 years ago
bunnei 81a0082f6b
Merge pull request #424 from lioncash/string
string_util: Remove StringFromFormat() and related functions
8 years ago
bunnei 225ff1130f
Merge pull request #422 from bunnei/shader-mov
Shader instructions MOV_C, MOV_R, and several minor GPU things
8 years ago
Lioncash 3abba08080
string_util: Remove StringFromFormat() and related functions
Given we utilize fmt, we don't need to provide our own functions for formatting anymore
8 years ago
Lioncash e8bbafb746
file_util: Make move constructor/assignment operator and related functions noexcept
Without this, it's possible to get compilation failures in the (rare) scenario where
a container is used to store a bunch of live IOFile instances, as they may be using
std::move_if_noexcept under the hood. Given these definitely don't throw exceptions
this is also not incorrect to add either.
8 years ago
Lioncash 40d2dcabd7
file_util: Add static assertions to ReadBytes() and WriteBytes()
Ensure that the actual types being passed in are trivially copyable. The internal
call to ReadArray() and WriteArray() will always succeed, since they're passed a pointer to char*
which is always trivially copyable.
8 years ago
bunnei f41eb95e13 maxwell_3d: Reset vertex counts after drawing. 8 years ago
bunnei 08b8fcbe6d gl_shader_decompiler: Implement MOV_R. 8 years ago
bunnei 316327f487 maxwell_to_gl: Implement type SignedNorm, Size_8_8_8_8. 8 years ago
bunnei c7ce472eeb shader_bytecode: Add decoding for FMNMX instruction. 8 years ago
Subv da32c648bf Shaders: Implemented predicate condition 3 (LessEqual) in the fset and fsetp instructions. 8 years ago
bunnei a71346cd7c gl_shader_decompiler: Implement MOV_C. 8 years ago
bunnei 6c464a2a4a
Merge pull request #416 from bunnei/shader-ints-p3
gl_shader_decompiler: Implement MOV32I, partially implement I2I, I2F
8 years ago
bunnei 49d92aa661
Merge pull request #417 from bunnei/lang-codes
set/am: Fix code for getting language codes
8 years ago
bunnei 334e859ab1 am: Fix GetDesiredLanguage implementation. 8 years ago
bunnei 17b16cf6f6 set: Fix GetAvailableLanguageCodes implementation. 8 years ago
bunnei f87ea8fa8b fermi_2d: Fix surface copy block height. 8 years ago
bunnei 0c01c34eff gl_shader_decompiler: Partially implement I2I_R, and I2F_R. 8 years ago
bunnei e73927cfc2 gl_shader_decompiler: More cleanups, etc. with how we handle register types. 8 years ago
bunnei c691fa4074 GLSLRegister: Simplify register declarations, etc. 8 years ago
bunnei f2dcb39049 shader_bytecode: Add decodings for i2i instructions. 8 years ago
bunnei a7b5ab4d9a gl_shader_decompiler: Implement MOV32_IMM instruction. 8 years ago
Lioncash 5d9ee12b1a
file_util: Remove compiler version checks around is_trivially_copyable()
The minimum clang/GCC versions we support already support this. We can also
remove is_standard_layout(), as fread and fwrite only require the type to be
trivially copyable.
8 years ago
Lioncash d43c49264f
log: Remove old logging macros and functions
Now that the old macros are no longer used, we can remove all functionality related to them.
8 years ago
bunnei 6b365f7703
Merge pull request #408 from bunnei/shader-ints-p2
gl_shader_decompiler: Add GLSLRegisterManager class to track register state.
8 years ago
Lioncash 16198f979e
renderer_opengl: Replace usages of LOG_GENERIC with fmt-capable equivalents 8 years ago
Lioncash 843dd62c81
core: Replace usages of LOG_GENERIC with new fmt-capable equivalents 8 years ago
bunnei e6242ab5e6 gl_shader_decompiler: Add GLSLRegisterManager class to track register state. 8 years ago
Lioncash 8475496630
general: Convert assertion macros over to be fmt-compatible 8 years ago
bunnei 3c40496409
Merge pull request #380 from ogniK5377/service-impl
Implemented some useful interfaces needed for games.
8 years ago
David Marcec abc23416e8 Switched to NGLOG_WARNING 8 years ago
bunnei 4f120a9ec0
Merge pull request #406 from lioncash/frontend
frontends: Move logging macros over to new fmt-capable ones
8 years ago
bunnei 18f8012233
Merge pull request #407 from lioncash/common
common: Move logging macros over to new fmt-capable macros where applicable
8 years ago
Lioncash 3cfe77ae75
common: Move logging macros over to new fmt-capable macros where applicable 8 years ago
Lioncash 3062eb52f4
frontends: Move logging macros over to new fmt-capable ones 8 years ago
Lioncash 376f6397c6
input_common: Move old logging macros over to fmt-capable ones 8 years ago
bunnei 6a3d59fdc1
Merge pull request #402 from lioncash/core
core: Replace remaining old non-generic logger usages with fmt-capable equivalents
8 years ago
bunnei bc43946140
Merge pull request #399 from bunnei/shader-ints
Shader decompiler prep for integer instructions
8 years ago
David Marcec 7391741a20 Merge branch 'master' of https://github.com/yuzu-emu/yuzu into service-impl 8 years ago
David Marcec f1f7f2cba9 Added PREPO to logging backend, Removed comments from SaveReportWithUser 8 years ago
Lioncash c33755e2b9
core: Replace remaining old non-generic logger usages with fmt-capable equivalents
LOG_GENERIC usages will be amended in a follow-up to keep API changes separate from
interface changes, as it will require removing a parameter from the relevant function
in the VMManager class.
8 years ago
Lioncash 87a92ef062
common: Remove chunk_file.h and linear_disk_cache.h
These are unused (and given chunk_file references Dolphin's >SVN< I doubt they were going to be used).
8 years ago
bunnei c9d7abe9c9 gl_shader_decompiler: Boilerplate for handling integer instructions. 8 years ago
bunnei 37fa9a15cd gl_shader_decompiler: Move color output to EXIT instruction. 8 years ago
Lioncash 623d772476
core/gdbstub: Move logging macros to new fmt-compatible ones 8 years ago
Lioncash 08da0b7acc
core/hw: Move logging macros over to fmt-capable ones 8 years ago
bunnei f81b915fd8
Merge pull request #396 from Subv/shader_ops
Shaders: Implemented the FSET instruction.
8 years ago
bunnei dd6c67c627
Merge pull request #398 from lioncash/kernel
kernel: Migrate logging macros to fmt-compatible ones
8 years ago
bunnei 42d43ea741
Merge pull request #387 from Subv/maxwell_2d
GPU: Partially implemented the 2D surface copy engine
8 years ago
bunnei d0825c9519
Merge pull request #395 from lioncash/file-sys
file-sys: Move logging macros over to the new fmt-capable ones
8 years ago
Lioncash 1913cf4783
kernel/shared_memory: Remove unnecessary semicolon at end of ConvertPermissions()
Functions don't need to be terminated by semicolons.
8 years ago
Lioncash 40dee76c57
kernel: Migrate logging macros to fmt-compatible ones 8 years ago
bunnei 23d68a07dc
Merge pull request #390 from mailwl/pctl-module
Service/PCTL: convert to module, add services, stub
8 years ago
bunnei 60746e4e52
Merge pull request #397 from lioncash/core
core/memory: Move logging macros over to the new fmt-capable ones
8 years ago
Subv 20d86d8a36 GPU: Partially implemented the Fermi2D surface copy operation.
The hardware allows for some rather complicated operations to be performed on the data during the copy, this is not implemented.
Only same-format same-size raw copies are implemented for now.
8 years ago
Subv e9ad8e9185 Shaders: Added bit decodings for the I2I instruction. 8 years ago
Subv 1740aa5444 Shaders: Implemented the FSET instruction.
This instruction is similar to the FSETP instruction, but it doesn't set a predicate, it sets the destination register to 1.0 if the condition holds, and 0 otherwise.
8 years ago
Subv 5ab597041f Memory: Added a missing shortcut for Memory::CopyBlock for the current process. 8 years ago
Subv 1dd4861d38 GPU: Make the Textures::CopySwizzledData function accessible from the outside of the file. 8 years ago
Subv a6da2b93c1 GPU: Added a function to retrieve the bytes per pixel of the render target formats. 8 years ago
Subv 378c881427 GPU: Added surface copy registers to Fermi2D 8 years ago
Subv b1109931b9 GPU: Added boilerplate code for the Fermi2D engine 8 years ago
Subv c16cfbbc6c GPU: Reduce the number of registers of Maxwell3D to 0xE00.
The rest are just macro shim registers.
8 years ago
Subv a994446b6e GPU: Move the Maxwell3D macro uploading code to the inside of the Maxwell3D processor.
It doesn't belong in the PFIFO handler.
8 years ago
Subv e2f2a49d2d GPU: Corrected the upper bound of the PFIFO method ids in the command processor. 8 years ago
Lioncash 3f78a61f09
file-sys: convert a StringFromFormat call into fmt::format in GetFullPath()
Lessens the amount to read and gets rid of the PRIX64 macro, allowing us to use a single string
for the whole path, making it easier to read.
8 years ago
Lioncash 5aafc83cc9
file-sys: Move logging macros over to the new fmt-capable ones 8 years ago
Lioncash 6d00780045
core/memory: Amend address widths in asserts
Addresses are 64-bit, these formatting specifiers are simply holdovers from citra. Adjust them to be the correct width.
8 years ago
Lioncash 59dae03dbe
core/memory: Move logging macros over to new fmt-capable ones
While we're at it, correct addresses to print all 64 bits where applicable, which were holdovers from citra.
8 years ago
Lioncash b7551e457b
video-core: Move logging macros over to new fmt-capable ones 8 years ago
mailwl 2ba4e2263c Service/PCTL: convert to module, add services, stub
PCTL::CreateServiceWithoutInitialize and IParentalControlService::Initialize, required by Kirby Star Allies
8 years ago
Subv 0369ee7248 Shaders: Added decodings for the FSET instructions. 8 years ago
bunnei ea3151f475
Merge pull request #388 from bunnei/refactor-rasterizer-cache
Refactor rasterizer cache
8 years ago
bunnei c30cd898fc renderer_opengl: Use correct byte order for framebuffer pixel format ABGR8. 8 years ago
bunnei f1a4a004fb gl_rasterizer_cache: Use CHAR_BIT for bpp conversions instead of 8. 8 years ago
bunnei 0a023cfb4f gl_rasterizer_cache: Use GPU PAGE_BITS/SIZE, not CPU. 8 years ago
bunnei 9022d926eb gl_rasterizer_cache: Use new logger. 8 years ago
bunnei fbb3cd110c gl_rasterizer_cache: Add a function for finding framebuffer GPU address. 8 years ago
bunnei bc0f1896fc gl_rasterizer_cache: Handle compressed texture sizes. 8 years ago
bunnei 4415e00181 gl_rasterizer_cache: Update to be based on GPU addresses, not CPU addresses. 8 years ago
Lioncash cc2e14ec2a
loader: Move old logging macros over to new fmt-capable ones 8 years ago
bunnei 10c6d89119 memory_manager: Add implement CpuToGpuAddress. 8 years ago
bunnei 239ac8abe2 memory_manager: Make GpuToCpuAddress return an optional. 8 years ago
bunnei 9e11a76e92 memory_manager: Use GPUVAdddr, not PAddr, for GPU addresses. 8 years ago
bunnei e8c2bb24b2
Merge pull request #386 from Subv/gpu_query
GPU: Added asserts to our code for handling the QUERY_GET GPU command.
8 years ago
bunnei b7953d2ebf
Merge pull request #392 from lioncash/log
service: Move logging macros over to the new fmt-compatible ones
8 years ago
Lioncash d08cfb55fe
service: Move logging macros over to new fmt-compatible ones 8 years ago
Lioncash 88eb612718
vi: Move logging macros over to new fmt-compatible ones 8 years ago
Lioncash bd9c2aa51f
time: Move logging macros over to new fmt-compatible ones 8 years ago
Lioncash bfe49edb2a
ssl: Move logging macros over to new fmt-compatible ones 8 years ago
Lioncash 82413a6c89
spl: Move logging macros over to new fmt-compatible ones 8 years ago
Lioncash 62c69f4a1e
sockets: Move logging macros over to new fmt-compatible ones 8 years ago
Lioncash 2a3f3bf977
sm: Move logging macros over to new fmt-compatible ones 8 years ago
Lioncash 32ece18bb6
set: Move logging macros over to new fmt-compatible ones 8 years ago
Lioncash 13f9cf2bd0
pctl: Move logging macros over to new fmt-compatible ones 8 years ago
Lioncash 72b497e876
nvflinger: Move logging macros over to new fmt-compatible ones 8 years ago
Lioncash 285d8d8b7d
nvdrv: Move logging macros over to new fmt-compatible ones 8 years ago
Lioncash 022fc59dcd
ns: Move logging macros over to new fmt-compatible ones 8 years ago
Lioncash 47054327c2
nifm: Move logging macros over to new fmt-compatible ones 8 years ago
Lioncash 28b92db7fd
nfp: Move logging macros over to new fmt-compatible ones 8 years ago
Lioncash dabfd90dfe
lm: Move logging macros over to new fmt-compatible ones 8 years ago
Lioncash 9cd7485cd7
hid: Move logging macros over to new fmt-compatible ones 8 years ago
Lioncash 8fc4003dab
friend: Move logging macros over to new fmt-compatible ones 8 years ago
Lioncash b5b613ea29
filesystem: Move logging macros over to new fmt-compatible ones 8 years ago
Lioncash d1b23b2b51
renderer_opengl: Silence a -Wdangling-else warning in DrawScreenTriangles() 8 years ago
Lioncash c6a740d7c2
fatal: Move logging macros over to new fmt-compatible ones 8 years ago
Lioncash 8d32bf9a96
audio: Move logging macros over to new fmt-compatible ones 8 years ago
Lioncash d652e41365
apm: Move logging macros over to new fmt-compatible ones 8 years ago
Lioncash e74dbfc572
aoc: Move logging macros over to new fmt-compatible ones 8 years ago
Lioncash 5483c08b44
am: Move logging macros over to new fmt-compatible ones 8 years ago
Lioncash f85d880ac6
acc: Move logging macros over to new fmt-compatible ones 8 years ago
mailwl a0179e5ca5 Service/FS: implement IFileSystem::RenameFile 8 years ago
bunnei 07dc0bbf3e
Merge pull request #379 from Subv/multi_buffers
GPU: Support multiple enabled vertex arrays.
8 years ago
Subv f208953585 GPU: Added asserts to our code for handling the QUERY_GET GPU command.
This is based on research from nouveau. Many things are currently unknown and will require hwtests in the future.
This commit also stubs QueryMode::Write2 to do the same as Write. Nouveau code treats them interchangeably, it is currently unknown what the difference is.
8 years ago
bunnei 0214351f4f
Merge pull request #370 from Subv/sync_primitives
Kernel: Reworked the new kernel synchronization primitives.
8 years ago
bunnei bf25299272
Merge pull request #384 from Subv/nvhost-remap
Nvdrv/nvhost-as-gpu: Implemented the ioctl REMAP command.
8 years ago
bunnei d4f87e9af4
Merge pull request #385 from Subv/unimpl_ioctls
Nvdrv: Assert when receiving an unimplemented ioctl in the nv* handlers.
8 years ago
bunnei 3967f9c6ef
Merge pull request #383 from Subv/gpu_mmu
GPU: Make the GPU virtual memory manager use 16 page bits and 10 pagetable bits.
8 years ago
Subv 9531a29283 GPU: Support multiple enabled vertex arrays.
The vertex arrays will be copied to the stream buffer one after the other, and the attributes will be set using the ARB_vertex_attrib_binding extension.

yuzu now thus requires OpenGL 4.3 or the ARB_vertex_attrib_binding extension.
8 years ago
Subv 46572d027d Kernel: Implemented mutex priority inheritance.
Verified with a hwtest and implemented based on reverse engineering.

Thread A's priority will get bumped to the highest priority among all the threads that are waiting for a mutex that A holds.
Once A releases the mutex and ownership is transferred to B, A's priority will return to normal and B's priority will be bumped.
8 years ago
Subv 0d6eafe11a NvDrv/nvhost-as-gpu: Ensure that the object passed to MapBufferEx has already been allocated.
Also added a consistency check and a comment for the case when the object id is different than its handle. The real nvservices doesn't make a distinction between ids and handles, each object gets an unique handle which doubles as its id.
8 years ago
Subv e4bd0bddea Nvdrv/nvhost-as-gpu: Implemented the ioctl REMAP command.
It takes a previously-reserved (AllocateSpace) GPU memory address and maps it to the address of the nvmap object passed to Remap.
8 years ago
Subv e862c50a70 Nvdrv: Assert when receiving an unimplemented ioctl in the nv* handlers. 8 years ago
Subv f823c1d599 GPU: Make the GPU virtual memory manager use 16 page bits and 10 page table bits.
Also removed some dead code and added memory map consistency asserts.
8 years ago
Subv 010227e149 GPU: Implement the RGB10_A2 RenderTarget format, it will use the same format as the A2BGR10 texture format. 8 years ago
David Marcec 27650499bc GetIUserInterface->CreateUserInterface, Added todos and stub logs. Playreport->PlayReport. 8 years ago
David df669bc540
lioncash proposed changes 8 years ago
David Marcec f3137d3bc1 Implemented GetIUserInterface properly, Playreport and SSL::SetInterfaceVersion. Fixed ipc issues with IAudioDevice(wrong ids) 8 years ago
Subv c079cf4eec GPU: Implement the A2BGR10 texture format. 8 years ago
bunnei 62937798a0
Merge pull request #377 from adityaruplaha/sdl2-fullscreen
SDL2: Implement fullscreen. (Original PR: citra-emu/citra#3607)
8 years ago
adityaruplaha f48d5e4c4c SDL2: Implement fullscreen. (Original PR: citra-emu/citra#3607) 8 years ago
bunnei f8764bb5d3
Merge pull request #376 from bunnei/shader-decoder
Shader opcode decoding
8 years ago
bunnei f8a037ead4
Merge pull request #375 from lioncash/header
opengl: Remove unnecessary header inclusions
8 years ago
bunnei d08fd7e86d gl_shader_decompiler: Skip RRO instruction. 8 years ago
bunnei 8b28dc55e6 gl_shader_decompiler: Cleanup error logging. 8 years ago
bunnei e1630c4d43 shader_bytecode: Add several more instruction decodings. 8 years ago
bunnei 9f6d305eab shader_bytecode: Decode instructions based on bit strings. 8 years ago
bunnei 8ac3a3f45e
Merge pull request #369 from Subv/shader_instr2
ShaderGen: Implemented fsetp/kil and predicated instruction execution.
8 years ago
bunnei 634d9ee18b
Merge pull request #374 from lioncash/noexcept
gl_resource_manager: Add missing noexcept specifiers to move constructors and assignment operators
8 years ago
bunnei ba6f3e8f9f
Merge pull request #373 from lioncash/enum2
gl_rasterizer_cache: Make MatchFlags an enum class
8 years ago
Subv 17a0ef1e1e ShaderGen: Implemented the KIL instruction, which is equivalent to 'discard'. 8 years ago
Subv c3a8ea76f1 ShaderGen: Implemented predicated instruction execution.
Each predicated instruction will be wrapped in an `if (predicate) { instruction_body; }` in the GLSL, where `predicate` is one of the predicate boolean variables previously set by fsetp.
8 years ago
Subv 0a5e01b710 ShaderGen: Implemented the fsetp instruction.
Predicate variables are now added to the generated shader code in the form of 'pX' where X is the predicate id.
These predicate variables are initialized to false on shader startup and are set via the fsetp instructions.

TODO:

* Not all the comparison types are implemented.
* Only the single-predicate version is implemented.
8 years ago
Subv a70ed9c8ae Kernel: Use 0x2C as default main thread priority for homebrew and lone NRO/NSOs 8 years ago
Subv 013778aa21 Qt: Update the WaitTree widget to show info about the current mutex of each thread. 8 years ago
Subv be155f4d9d Kernel: Remove unused ConditionVariable class. 8 years ago
Subv 5fdfbfe25a Kernel: Remove old and unused Mutex code. 8 years ago
Subv b18ccf9399 Kernel: Properly implemented svcWaitProcessWideKey and svcSignalProcessWideKey
They work in tandem with guest code to provide synchronization primitives along with svcArbitrateLock/Unlock
8 years ago
Subv e81a2080eb Kernel: Corrected the implementation of svcArbitrateLock and svcArbitrateUnlock.
Switch mutexes are no longer kernel objects, they are managed in userland and only use the kernel to handle the contention case.
Mutex addresses store a special flag value (0x40000000) to notify the guest code that there are still some threads waiting for the mutex to be released. This flag is updated when a thread calls ArbitrateUnlock.

TODO:
* Fix svcWaitProcessWideKey
* Fix svcSignalProcessWideKey
* Remove the Mutex class.
8 years ago
bunnei 1723b4d8d4
Merge pull request #372 from lioncash/enum
resource_limit: Make ResourceTypes an enum class
8 years ago
Lioncash eafdcc1b8a opengl: Remove unnecessary header inclusions 8 years ago
Lioncash ab71997b2c gl_resource_manager: Add missing noexcept specifiers to move constructors and assignment operators
Standard library containers may use std::move_if_noexcept to perform
move operations. If a move cannot be performed under these
circumstances, then a copy is attempted. Given we only intend for these
types to be move-only this can be somewhat problematic. By defining
these to be noexcept we prevent cases where copies may be attempted.
8 years ago
Lioncash 7db0b8d74f gl_rasterizer_cache: Make MatchFlags an enum class
Prevents implicit conversions and scope pollution.
8 years ago
Lioncash 659a612368 core: Relocate g_service_manager to the System class
Converts the service manager from a global into an instance-based
variable.
8 years ago
Lioncash bec05db746 resource_limit: Make ResourceTypes an enum class
Prevents enum identifiers from leaking into the surrounding scope.
8 years ago
bunnei 1df3a7710e
Merge pull request #340 from mailwl/vi-update
Service/VI: stub SetLayerVisibility, fix GetDisplayResolution output
8 years ago
Subv d03fc77475 ShaderGen: Register id 255 is special and is hardcoded to return 0 (SR_ZERO). 8 years ago
Subv 2e0a9f66a0 ShaderGen: Ignore the 'sched' instruction when generating shaders.
The 'sched' instruction has a very convoluted encoding, but fortunately it seems to only appear on a fixed interval (once every 4 instructions).
8 years ago
bunnei 326b044c19
Merge pull request #367 from lioncash/clamp
math_util: Remove the Clamp() function
8 years ago
bunnei 87f89ac82d
Merge pull request #361 from lioncash/common
common_types: Minor changes
8 years ago
Lioncash fae2dd0344
math_util: Remove the Clamp() function
C++17 adds clamp() to the standard library, so we can remove ours in
favor of it.
8 years ago
bunnei b11f6f90e7
Merge pull request #360 from lioncash/namespaces
service: Use nested namespace specifiers where applicable
8 years ago
bunnei 4d96997447
Merge pull request #364 from lioncash/thread-local
common/thread: Remove unnecessary feature checking for thread_local
8 years ago
bunnei b5c204ac6f
Merge pull request #362 from lioncash/snprintf
common_funcs: Remove check for VS versions that we don't even support
8 years ago
bunnei 701dd649e6
Merge pull request #363 from lioncash/array-size
common_funcs: Remove ARRAY_SIZE macro
8 years ago
bunnei 79c1ed80e9
Merge pull request #366 from lioncash/vec
vector_math: Remove AsArray() and Write() functions from Vec[2,3,4]
8 years ago
bunnei cb267093bb
Merge pull request #365 from lioncash/codeblock
common: Remove code_block.h
8 years ago
Lioncash 956e200f12 vector_math: Remove AsArray() and Write() functions from Vec[2,3,4]
These are all unused and the Write() ones should arguably not even be in the interface. There are better ways to provide this if we ever need it (like iterators).
8 years ago
Lioncash 0eba5911f2 common: Remove code_block.h
We use dynarmic, so this is unued. Anything else we need will likely use Xbyak, so
this header isn't necessary any more.
8 years ago
Lioncash b134e6afcf common/thread: Remove unnecessary feature checking for thread_local
Every compiler we require already supports it.
8 years ago
Lioncash d9e316e353 common_funcs: Remove ARRAY_SIZE macro
C++17 has non-member size() which we can just call where necessary.
8 years ago
Lioncash 902fc61ef8 common_funcs: Remove check for VS versions that we don't even support
We don't support any VS versions that don't already have snprintf in the
standard library implementation.
8 years ago
Lioncash 16ffecd8fb common_types: Convert typedefs to using aliases
May as well while we're making changes to this file.
8 years ago
Lioncash e8e5041955 common_types: Remove unnecessary check for whether or not__func__ is defined
VS has supported this for quite a while.
8 years ago
Lioncash ccca5e7c28 service: Use nested namespace specifiers where applicable
Tidies up namespace declarations
8 years ago
bunnei 2c8afe1140
Merge pull request #357 from lioncash/guard
renderer_opengl: Add missing header guards
8 years ago
bunnei 2ef04f69b2
Merge pull request #358 from lioncash/explicit
disk_filesystem: Minor changes
8 years ago
Lioncash 3990da488b vi: Remove redundant initializers in the constructors 8 years ago
Lioncash 80982748c8 disk_filesystem: Remove unused total_entries_in_directory member from Disk_Directory 8 years ago
Lioncash e61a4dd485 disk_filesystem: Remove redundant initializer in Disk_Directory's constructor 8 years ago
Lioncash b05f8ea5b5 disk_filesystem: Make constructors explicit where applicable 8 years ago
Lioncash 3841ec4200 renderer_opengl: Add missing header guards 8 years ago
bunnei 17ad56c1dc
Merge pull request #356 from lioncash/shader
glsl_shader_decompiler: Minor API changes to ShaderWriter
8 years ago
bunnei f633b0c875
Merge pull request #355 from Subv/shader_instr
ShaderGen: Fixed TEXS overriding its own texcoords and implemented fmul32i
8 years ago
Lioncash e3b6f6c016 glsl_shader_decompiler: Use std::string_view instead of std::string for AddLine()
This function doesn't need to take ownership of the string data being
given to it, considering all we do is append the characters to the
internal string instance.

Instead, use a string view to simply reference the string data without
any potential heap allocation.

Now anything that is a raw const char* won't need to be converted to a
std::string before appending.
8 years ago
Lioncash 412b31ad72 glsl_shader_decompiler: Add AddNewLine() function to ShaderWriter
Avoids constructing a std::string just to append a newline character
8 years ago
Lioncash aa26baa3db glsl_shader_decompiler: Add char overload for ShaderWriter's AddLine()
Avoids constructing a std::string just to append a character.
8 years ago
Lioncash 4ef392906b glsl_shader_decompiler: Append indentation without constructing a separate std::string
The interface of std::string already lets us append N copies of a
character to an existing string.
8 years ago
Subv fe84842137 ShaderGen: Implemented the fmul32i shader instruction. 8 years ago
Subv 5367935d35 ShaderGen: Fixed a case where the TEXS instruction would use the same registers for the input and the output.
It will now save the coords before writing the outputs in a subscope.
8 years ago
N00byKing 8a47e7e493 Implement Pull #3528 from citra: use nvidia graphics automatically on laptops with optimus (with AMD support) (#271)
* Port 3528: use nvidia graphics automatically on laptops with optimus

* Force dedicated AMD Card for switchable Graphics

* Ran clang-format
8 years ago
James Rowe e90a12f80c
Merge pull request #352 from bunnei/fix-microprofile
nvflinger: Call MicroProfileFlip on NVFlinger::Compose.
8 years ago
Subv 057170928c GPU: Add support for the DXT23 and DXT45 compressed texture formats. 8 years ago
bunnei de18592179 nvflinger: Call MicroProfileFlip on NVFlinger::Compose. 8 years ago
bunnei 60e6e8953e
Merge pull request #351 from Subv/tex_formats
GPU: Implemented the B5G6R5 format.
8 years ago
Subv 2985056340 GPU: Implemented the B5G6R5 format. 8 years ago
bunnei ce4f159b1c
gl_shader_gen: Support vertical/horizontal viewport flipping. (#347)
* gl_shader_gen: Support vertical/horizontal viewport flipping.

* fixup! gl_shader_gen: Support vertical/horizontal viewport flipping.
8 years ago
Subv 43d98ca8fe GLCache: Added boilerplate code to make supporting configurable texture component types.
For now only the UNORM type is supported.
8 years ago
Subv 5b3fab6766 GLCache: Unify texture and framebuffer formats when converting to OpenGL. 8 years ago
Subv b2c1672e10 GPU: Texture format 8 and framebuffer format 0xD5 are actually ABGR8. 8 years ago