Commit Graph
100 Commits
Author SHA1 Message Date
gdkchanandGitHub 96951b7d04 Fix regression caused by wrong SB descriptor offset (#1316) 2020-06-22 13:48:32 +02:00
gdkchanandGitHub 44d7fcff39 Implement FIFO semaphore (#1286)
* Implement FIFO semaphore

* New enum for FIFO semaphore operation
2020-05-29 10:51:10 +02:00
gdkchanandGitHub 12cfaf56f0 Add new depth-stencil formats (#1284) 2020-05-29 09:01:18 +10:00
gdkchanandGitHub a15b951721 Fix wrong face culling once and for all (#1277)
* Viewport swizzle support on NV and clip origin

* Initialize default viewport swizzle state, emulate viewport swizzle on shaders when not supported

* Address PR feedback
2020-05-28 09:03:07 +10:00
gdkchanandGitHub 5795bb1528 Support separate textures and samplers (#1216)
* Support separate textures and samplers

* Add missing bindless flag, fix SNORM format on buffer textures

* Add missing separation

* Add comments about the new handles
2020-05-27 16:07:10 +02:00
gdkchanandGitHub 0b6d206daa Omit image format if possible, and fix BA bit (#1280)
* Omit image format if possible, and fix BA bit

* Match extension name
2020-05-27 11:00:21 +02:00
gdkchanandGitHub 5011640b30 Spanify Graphics Abstraction Layer (#1226)
* Spanify Graphics Abstraction Layer

* Be explicit about BufferHandle size
2020-05-23 11:46:09 +02:00
gdkchanandGitHub 96c7988671 Remove CpuId IR instruction (#1227) 2020-05-13 15:30:21 +10:00
gdkchanandGitHub 1e687c4eea Fix block iteration on kernel MemoryManager InsertBlock function (#1184) 2020-05-06 22:48:57 +10:00
gdkchanandGitHub b8eb6abecc Refactor shader GPU state and memory access (#1203)
* Refactor shader GPU state and memory access

* Fix NVDEC project build

* Address PR feedback and add missing XML comments
2020-05-06 11:02:28 +10:00
gdkchanandGitHub 15d1cc806b Move kernel state out of the Horizon class (#1107)
* Move kernel state from Horizon to KernelContext

* Merge syscalls partial classes, split 32 and 64-bit variants

* Sort usings
2020-05-04 13:41:29 +10:00
gdkchanandGitHub f77694e4f7 Implement a new physical memory manager and replace DeviceMemory (#856)
* Implement a new physical memory manager and replace DeviceMemory

* Proper generic constraints

* Fix debug build

* Add memory tests

* New CPU memory manager and general code cleanup

* Remove host memory management from CPU project, use Ryujinx.Memory instead

* Fix tests

* Document exceptions on MemoryBlock

* Fix leak on unix memory allocation

* Proper disposal of some objects on tests

* Fix JitCache not being set as initialized

* GetRef without checks for 8-bits and 16-bits CAS

* Add MemoryBlock destructor

* Throw in separate method to improve codegen

* Address PR feedback

* QueryModified improvements

* Fix memory write tracking not marking all pages as modified in some cases

* Simplify MarkRegionAsModified

* Remove XML doc for ghost param

* Add back optimization to avoid useless buffer updates

* Add Ryujinx.Cpu project, move MemoryManager there and remove MemoryBlockWrapper

* Some nits

* Do not perform address translation when size is 0

* Address PR feedback and format NativeInterface class

* Remove ghost parameter description

* Update Ryujinx.Cpu to .NET Core 3.1

* Address PR feedback

* Fix build

* Return a well defined value for GetPhysicalAddress with invalid VA, and do not return unmapped ranges as modified

* Typo
2020-05-04 08:54:50 +10:00
gdkchanandGitHub 1758424208 Use correct swizzle on depth-stencil textures (#1196) 2020-05-03 23:18:00 +02:00
gdkchanandGitHub ea3d5fde73 Remove buffer invalidation (#1194) 2020-05-03 23:07:42 +02:00
gdkchanandGitHub 10a2b9dca3 Fix shadow RAM affecting MME methods (#1168) 2020-04-27 08:22:18 +10:00
gdkchanandGitHub 9261ec6bc8 Fix MME shadow RAM implementation (#1051) 2020-04-25 23:56:56 +10:00
gdkchanandGitHub 1c9aba6de1 Fix mode and Reg08.H1 decoding on XMAD instruction (#1156) 2020-04-25 23:40:29 +10:00
gdkchanandGitHub 34d19f381c Fix texture level offset/size calculation when sparse tile width is > 1 (#1142)
* Fix texture level offset/size calculation when sparse tile width is > 1

* Sparse tile width affects layer size alignment aswell
2020-04-25 23:40:20 +10:00
gdkchanandGitHub bcc5b0d21e Fix kernel memory allocator block coalescing (#1155)
* Fix kernel memory allocator block coalescing

* Fix and move clear bit logic to a separate method
2020-04-25 23:25:22 +10:00
gdkchanandGitHub 3cb1fa0e85 Implement texture buffers (#1152)
* Implement texture buffers

* Throw NotSupportedException where appropriate
2020-04-25 23:02:18 +10:00
gdkchanandGitHub fe5bb439f1 Do temp constant copy for CompareAndSwap, other improvements to PreAllocator (#1126)
* Do temp constant copy for CompareAndSwap, other improvements to PreAllocator

* Nit
2020-04-25 23:00:54 +10:00
gdkchanandGitHub ff86494d68 Remove leftover of debugging code for shader texture format (#1141) 2020-04-22 16:02:07 +02:00
gdkchanandGitHub 6bfe4715f0 Initial conditional rendering support (#1012)
* Initial conditional rendering support

* Properly reset state

* Support conditional modes and skeleton a counter cache for future host conditional rendering

* Address PR feedback
2020-04-22 16:00:11 +10:00
gdkchanandGitHub 03711dd7b5 Implement SULD shader instruction (#1117)
* Implement SULD shader instruction

* Some nits
2020-04-22 09:35:28 +10:00
gdkchanandGitHub 91fa1debd4 Report more realistic GPU timestamps when FastGpuTime is enabled (#1139) 2020-04-20 22:41:07 +10:00
gdkchanandGitHub 92cc37e365 Fix negation of HADD2 constant buffer source (#1116) 2020-04-15 09:01:26 +10:00
gdkchanandGitHub e93ca84b14 Better IPA shader instruction implementation (#1082)
* Fix varying interpolation on fragment shader

* Some nits

* Alignment
2020-04-03 11:20:47 +11:00
gdkchanandGitHub 5b5239ab5b Remove output interpolation qualifier (#1070) 2020-04-02 12:24:55 +11:00
gdkchanandGitHub d599fba711 Implement FCMP shader instruction (#1067) 2020-03-30 12:04:00 +02:00
gdkchanandGitHub 9948a7be53 Support constant attributes (with a value of zero) (#1066)
* Support constant attributes (with a value of zero)

* Remove extra line
2020-03-30 13:11:24 +11:00
gdkchanandGitHub b18ef8e3a0 Workaround for AMD and Intel view format bug (#1050)
* Workaround for Intel view format bug

* Dispose of the intermmediate texture aswell

* Apply workaround on AMD aswell
2020-03-29 23:48:39 +11:00
gdkchanandGitHub ab4867505e Implement GPU scissors (#1058)
* Implement GPU scissors

* Remove unused using

* Add missing changes for Clear
2020-03-29 14:02:58 +11:00
gdkchanandGitHub 1586450a38 Implement VMNMX shader instruction (#1032)
* Implement VMNMX shader instruction

* No need for the gap on the enum

* Fix typo
2020-03-25 15:49:10 +01:00
gdkchanandGitHub 6edc929894 Implement ICMP shader instruction (#1010) 2020-03-23 17:32:30 +01:00
gdkchanandGitHub 9a208c4fb5 Keep sRGB enabled for texture blits (#1009) 2020-03-23 09:34:26 +11:00
gdkchanandGitHub 49d7b1c7d8 Implement textureQueryLevels (#1007) 2020-03-23 08:31:31 +11:00
gdkchanandGitHub 8e64984158 Support partial invalidation on texture access (#1000)
* Support partial invalidation on texture access

* Fix typo

* PR feedback

* Fix modified size clamping
2020-03-20 14:17:11 +11:00
gdkchanandGitHub 8bb64ac69c Improve shader sampler type selection (#989) 2020-03-15 11:24:45 +11:00
gdkchanandGitHub ff2bac9c90 Implement MME shadow RAM (#987) 2020-03-13 12:30:26 +11:00
gdkchanandGitHub c26f3774bd Implement VMULL, VMLSL, VRSHR, VQRSHRN, VQRSHRUN AArch32 instructions + other fixes (#977)
* Implement VMULL, VMLSL, VQRSHRN, VQRSHRUN AArch32 instructions plus other fixes

* Re-align opcode table

* Re-enable undefined, use subclasses to fix checks

* Add test and fix VRSHR instruction

* PR feedback
2020-03-11 11:49:27 +11:00
gdkchanandGitHub 89ccec197e Implement VMOVL and VORR.I32 AArch32 SIMD instructions (#960)
* Implement VMOVL and VORR.I32 AArch32 SIMD instructions

* Rename <dt> to <size> on test description

* Rename Widen to Long and improve VMOVL implementation a bit
2020-03-10 16:17:30 +11:00
gdkchanandGitHub 61d79facd1 Optimize x64 loads and stores using complex addressing modes (#972)
* Optimize x64 loads and stores using complex addressing modes

* This was meant to be used for testing
2020-03-10 09:29:34 +11:00
gdkchanandGitHub ab3b6ea6d4 A64 SIMD LDP and STP with size = 0b11 is undefined (#971) 2020-03-07 13:39:52 +11:00
gdkchanandGitHub d9ed827696 Don't decode blocks starting outside mapped memory & undefined instead of throw on invalid sysreg coprocessor (#964)
* Don't decode blocks in invalid memory locations.

* Emit undefined instruction on invalid coprocessor

...rather than throwing.

* Call undefined instruction directly.
2020-03-04 16:25:27 -03:00
gdkchanandGitHub dc97457bf0 Initial support for double precision shader instructions. (#963)
* Implement DADD, DFMA and DMUL shader instructions

* Rename FP to FP32

* Correct double immediate

* Classic mistake
2020-03-03 15:02:08 +01:00
7d1a294eae Implement SMULWB, SMULWT, SMLAWB, SMLAWT (AArch32) (#953)
* Implement SMULWB, SMULWT, SMLAWB, SMLAWT, and add tests for some multiply instructions

* Improve test descriptions

* Rename SMULH to SMUL__

Co-authored-by: jduncanator <1518948+jduncanator@users.noreply.github.com>
2020-03-01 18:47:05 +11:00
gdkchanandGitHub fb0939f9b6 Add SSAT, SSAT16, USAT and USAT16 ARM32 instructions (#954)
* Implement SMULWB, SMULWT, SMLAWB, SMLAWT, and add tests for some multiply instructions

* Improve test descriptions

* Rename SMULH to SMUL__

* Add SSAT, SSAT16, USAT and USAT16 ARM32 instructions

* Fix new tests

* Replace AND 0xFFFF with 16-bits zero extension (more efficient)
2020-03-01 07:51:55 +11:00
gdkchanandGitHub b8ee5b15ab Implement FACGE and FACGT (Scalar and Vector) AArch64 SIMD instructions (#956) 2020-03-01 07:51:17 +11:00
gdkchanandGitHub 6204f0e47a Set Undefined instruction emitter for Undefined property on InstDescriptor (#957) 2020-02-29 12:12:15 +01:00
gdkchanandGitHub e5f78fb1d4 Replace LinkedList by IntrusiveList to avoid allocations on JIT (#931)
* Replace LinkedList by IntrusiveList to avoid allocations on JIT

* Fix wrong replacements
2020-02-17 22:30:54 +01:00
gdkchanandGitHub 9e4f668f6c Update bindless to indexed conversion code pattern match (#938)
* Update bindless to indexed conversion code pattern match

* Correct index shift
2020-02-14 11:29:58 +01:00
gdkchanandGitHub 5a9dba0756 Sign-extend shader memory instruction offsets (#934) 2020-02-14 01:48:07 +01:00
gdkchanandGitHub 7e4d986a73 Support compute uniform buffers emulated with global memory (#924) 2020-02-11 01:10:05 +01:00
gdkchanandGitHub 796e5d14b4 Use correct shader local memory size instead of a hardcoded size (#914)
* Use correct shader local size instead of a hardcoded size

* Remove unused uniform block

* Update XML doc

* Local memory size has 23 bits on maxwell

* Generate compute QMD struct from nv open doc header

* Remove dummy arrays when shared or local memory is not used, other improvements
2020-02-02 14:25:52 +11:00
gdkchanandGitHub f373f870f7 Support configurable point size (#916) 2020-02-02 10:19:46 +11:00
gdkchanandGitHub a1a5341baf Support flat interpolation qualifier on shaders (#915) 2020-02-02 10:18:58 +11:00
gdkchanandGitHub 0202f150d4 Enable stencil texturing (fixes #866) (#910) 2020-01-31 14:42:03 +11:00
gdkchanandGitHub 793f38b9aa Discard higher 32-bits of IPC message magic and command number (#911) 2020-01-30 21:43:47 +01:00
gdkchanandThog 532ccf929a Ignore exit flag on branch delay slot (#899) 2020-01-22 02:11:43 +01:00
gdkchanandThog 81cca88bcd Fix shader output color buffer index when non-sequential render targets are used (#895) 2020-01-19 00:09:46 +01:00
gdkchanandThog 595e7716d8 Support audio effect output status (#890)
* Support audio effect output status

* Remove extra line
2020-01-17 10:07:27 +01:00
gdkchanandThog a5e20a8fd1 Add sampler border color support on the GPU (#893) 2020-01-17 09:55:38 +01:00
gdkchanandjduncanator b8e3909d80 Add a GetSpan method to the memory manager and use it on GPU (#877) 2020-01-13 10:27:50 +11:00
gdkchanandjduncanator 8b90924c1e Support instanced draw of quads" (#881) 2020-01-13 09:14:50 +11:00
gdkchanandjduncanator 2bb39ff03e Replace glFinish with barrier for WaitForIdle (#878) 2020-01-13 09:12:40 +11:00
gdkchanandThog 80707f9311 Add runtime identifiers to new projects 2020-01-09 02:13:00 +01:00
gdkchanandThog 29a825b43b Address PR feedback
Removes a useless null check

Aligns some values to improve readability
2020-01-09 02:13:00 +01:00
gdkchanandThog 912e43e979 Remove some unused args on the shader translator 2020-01-09 02:13:00 +01:00
gdkchanandThog 6407729a1d Fix FADD32I check for Ra negation 2020-01-09 02:13:00 +01:00
gdkchanandThog e3c919f086 Remove FFMPEG dependency from README 2020-01-09 02:13:00 +01:00
gdkchanandThog 18814d44b2 Address PR feedback
Add TODO comment for GL_EXT_polygon_offset_clamp
2020-01-09 02:13:00 +01:00
gdkchanandThog 383452f5cf Fix some shader disposal issues 2020-01-09 02:13:00 +01:00
gdkchanandThog a11f6f5235 Fix some spelling mistakes
Thanks to LDj3SNuD for spotting these
2020-01-09 02:13:00 +01:00
gdkchanandThog 23d8516763 Fix ShaderTools 2020-01-09 02:13:00 +01:00
gdkchanandThog 92703af555 Address PR feedback 2020-01-09 02:13:00 +01:00
gdkchanandThog 40ef18d759 Target .NET Core 3.0 for NVDEC project 2020-01-09 02:13:00 +01:00
gdkchanandThog 0dbfe3c23e Re-add NVDEC project (not integrated) 2020-01-09 02:13:00 +01:00
gdkchanandThog 6e092c0558 More code cleanup 2020-01-09 02:13:00 +01:00
gdkchanandThog 9bfb373bdf Remove more unused code 2020-01-09 02:13:00 +01:00
gdkchanandThog 59fdaa744b GPU resource disposal 2020-01-09 02:13:00 +01:00
gdkchanandThog f7bcc884e4 Add XML documentation to Ryujinx.Graphics.Gpu 2020-01-09 02:13:00 +01:00
gdkchanandThog 4a4e2f7c72 Add XML documentation to Ryujinx.Graphics.Gpu.Engine 2020-01-09 02:13:00 +01:00
gdkchanandThog d1c0a64e6a Add XML documentation to Ryujinx.Graphics.Gpu.State 2020-01-09 02:13:00 +01:00
gdkchanandThog 430faeb8ef Add XML documentation to Ryujinx.Graphics.Gpu.Shader 2020-01-09 02:13:00 +01:00
gdkchanandThog e58b540c4e Add XML documentation to Ryujinx.Graphics.Gpu.Memory 2020-01-09 02:13:00 +01:00
gdkchanandThog 80ff2eab29 Change GPU errors to debug and reduce log messages 2020-01-09 02:13:00 +01:00
gdkchanandThog bacb278dc1 Fix typos pointed out by LDj3SNuD 2020-01-09 02:13:00 +01:00
gdkchanandThog c5b9088914 Remove some error logging to avoid log spam 2020-01-09 02:13:00 +01:00
gdkchanandThog ffaad0eaac Fix missing S8 format on texture compatibility check 2020-01-09 02:13:00 +01:00
gdkchanandThog 32764f9560 Add XML documentation to Ryujinx.Graphics.Gpu.Image 2020-01-09 02:13:00 +01:00
gdkchanandThog 53bbc1311f Fix AstcDecoder Success property never being set to true 2020-01-09 02:13:00 +01:00
gdkchanandThog 654e617fe7 Some code cleanup 2020-01-09 02:13:00 +01:00
gdkchanandThog af8498d679 Add basic error logging to the GPU 2020-01-09 02:13:00 +01:00
gdkchanandThog 947e14d3be Reimplement limited bindless textures support 2020-01-09 02:13:00 +01:00
gdkchanandThog 647d0962df Initialize GPU physical memory accessor from KProcess, to allow homebrew that never maps anything on the GPU to work 2020-01-09 02:13:00 +01:00
gdkchanandThog 6cf9a04d98 Stop memory modification check when a invalid address is found 2020-01-09 02:13:00 +01:00
gdkchanandThog a718b60d06 Fix exception on shader translator when adding goto temp variable 2020-01-09 02:13:00 +01:00
gdkchanandThog 82957fa96b Support CC on FSET shader instruction, fix CC on ISET.BF shader instruction 2020-01-09 02:13:00 +01:00
gdkchanandThog 9d7a142a48 Support texture rectangle targets (non-normalized coords) 2020-01-09 02:13:00 +01:00
gdkchanandThog 2eccc7023a Partial support for shader memory barriers 2020-01-09 02:13:00 +01:00