Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | decoder/texture: Eliminate narrowing conversion in GetTldCode() | Lioncash | 2020-09-17 | 1 | -1/+1 |
| | | | | The assignment was previously truncating a u64 value to a bool. | ||||
* | shader/texture: Join separate image and sampler pairs offline | ReinUsesLisp | 2020-06-05 | 1 | -18/+37 |
| | | | | | | | | | | | | | | | | | | | | | | | | | | Games using D3D idioms can join images and samplers when a shader executes, instead of baking them into a combined sampler image. This is also possible on Vulkan. One approach to this solution would be to use separate samplers on Vulkan and leave this unimplemented on OpenGL, but we can't do this because there's no consistent way of determining which constant buffer holds a sampler and which one an image. We could in theory find the first bit and if it's in the TIC area, it's an image; but this falls apart when an image or sampler handle use an index of zero. The used approach is to track for a LOP.OR operation (this is done at an IR level, not at an ISA level), track again the constant buffers used as source and store this pair. Then, outside of shader execution, join the sample and image pair with a bitwise or operation. This approach won't work on games that truly use separate samplers in a meaningful way. For example, pooling textures in a 2D array and determining at runtime what sampler to use. This invalidates OpenGL's disk shader cache :) - Used mostly by D3D ports to Switch | ||||
* | shader/texture: Support multiple unknown sampler properties | ReinUsesLisp | 2020-04-23 | 1 | -51/+74 |
| | | | | | | | | | This allows deducing some properties from the texture instruction before asking the runtime. By doing this we can handle type mismatches in some instructions from the renderer instead of the shader decoder. Fixes texelFetch issues with games using 2D texture instructions on a 1D sampler. | ||||
* | shader_ir: Turn classes into data structures | ReinUsesLisp | 2020-04-23 | 1 | -49/+50 |
| | |||||
* | decode/texture: Resolve unused variable warnings. | Lioncash | 2020-04-17 | 1 | -5/+7 |
| | | | | | | | | Some variables aren't used, so we can remove these. Unfortunately, diagnostics are still reported on structured bindings even when annotated with [[maybe_unused]], so we need to unpack the elements that we want to use manually. | ||||
* | decode/texture: Collapse loop down into std::generate | Lioncash | 2020-04-17 | 1 | -3/+1 |
| | | | | Same behavior, less code. | ||||
* | decode/texture: Eliminate trivial missing field initializer warnings | Lioncash | 2020-04-17 | 1 | -3/+4 |
| | | | | We can just specify the initializers. | ||||
* | shader/texture: Remove type mismatches management from shader decoder | ReinUsesLisp | 2020-04-10 | 1 | -14/+0 |
| | | | | | | | Since commit e22816a5bb we handle type mismatches from the CPU. We don't need to hack our shader decoder due to game bugs anymore. Removed in this commit. | ||||
* | video_core: Rename "const buffer locker" to "registry" | ReinUsesLisp | 2020-03-09 | 1 | -2/+3 |
| | |||||
* | shader/texture: Fix illegal 3D texture assert | ReinUsesLisp | 2020-02-21 | 1 | -1/+1 |
| | | | | | Fix typo in the illegal 3D texture assert logic. We care about catching arrayed 3D textures or 3D shadow textures, not regular 3D textures. | ||||
* | shader/texture: Allow 2D shadow arrays and simplify code | ReinUsesLisp | 2020-02-15 | 1 | -43/+28 |
| | | | | | | | Shadow sampler 2D arrays are supported on OpenGL, so there's no reason to forbid these. Enable textureLod usage on these. Minor style changes. | ||||
* | shader: Remove curly braces initializers on shared pointers | ReinUsesLisp | 2020-02-02 | 1 | -2/+2 |
| | |||||
* | Shader_IR: Address feedback. | Fernando Sahmkow | 2020-01-25 | 1 | -1/+2 |
| | |||||
* | Shader_IR: Change name of TrackSampler function so it does not confuse with the type. | Fernando Sahmkow | 2020-01-24 | 1 | -1/+1 |
| | |||||
* | Shader_IR: Propagate bindless index into the GL compiler. | Fernando Sahmkow | 2020-01-24 | 1 | -16/+24 |
| | |||||
* | Shader_IR: deduce size of indexed samplers | Fernando Sahmkow | 2020-01-24 | 1 | -4/+5 |
| | |||||
* | Shader_IR: Setup Indexed Samplers on the IR | Fernando Sahmkow | 2020-01-24 | 1 | -20/+46 |
| | |||||
* | Merge pull request #3273 from FernandoS27/txd-array | bunnei | 2020-01-24 | 1 | -5/+12 |
|\ | | | | | Shader_IR: Implement TXD Array. | ||||
| * | Shader_IR: Implement TXD Array. | Fernando Sahmkow | 2020-01-04 | 1 | -5/+12 |
| | | | | | | | | | | This commit extends the compilation of TXD to support array samplers on TXD. | ||||
* | | shader_ir/texture: Simplify AOFFI code | ReinUsesLisp | 2020-01-09 | 1 | -10/+6 |
|/ | |||||
* | Merge pull request #3228 from ReinUsesLisp/ptp | bunnei | 2019-12-27 | 1 | -33/+75 |
|\ | | | | | shader/texture: Implement AOFFI and PTP for TLD4 and TLD4S | ||||
| * | shader/texture: Implement TLD4.PTP | ReinUsesLisp | 2019-12-16 | 1 | -18/+56 |
| | | |||||
| * | shader/texture: Enable arrayed TLD4 | ReinUsesLisp | 2019-12-16 | 1 | -1/+0 |
| | | |||||
| * | shader/texture: Implement AOFFI for TLD4S | ReinUsesLisp | 2019-12-16 | 1 | -13/+18 |
| | | |||||
| * | shader/texture: Remove unnecesary parenthesis | ReinUsesLisp | 2019-12-16 | 1 | -2/+2 |
| | | |||||
* | | shader/texture: Properly shrink unused entries in size mismatches | ReinUsesLisp | 2019-12-18 | 1 | -4/+9 |
|/ | | | | | | | When a image format mismatches we were inserting zeroes to the texture itself. This was not handling cases were the mismatch uses less coordinates than the guest shader code. Address that by resizing the vector. | ||||
* | Shader_IR: Correct TLD4S Depth Compare. | Fernando Sahmkow | 2019-12-12 | 1 | -5/+12 |
| | |||||
* | Shader_Ir: Correct TLD4S encoding and implement f16 flag. | Fernando Sahmkow | 2019-12-12 | 1 | -9/+12 |
| | |||||
* | Shader_Ir: default failed tracks on bindless samplers to null values. | Fernando Sahmkow | 2019-12-12 | 1 | -22/+75 |
| | |||||
* | Merge pull request #3109 from FernandoS27/new-instr | bunnei | 2019-12-07 | 1 | -7/+46 |
|\ | | | | | Implement FLO & TXD Instructions on GPU Shaders | ||||
| * | Shader_IR: Address Feedback | Fernando Sahmkow | 2019-11-18 | 1 | -5/+2 |
| | | |||||
| * | Shader_IR: Implement TXD instruction. | Fernando Sahmkow | 2019-11-14 | 1 | -7/+49 |
| | | |||||
* | | shader/texture: Handle TLDS texture type mismatches | ReinUsesLisp | 2019-11-23 | 1 | -1/+10 |
| | | | | | | | | | | | | | | | | | | | | Some games like "Fire Emblem: Three Houses" bind 2D textures to offsets used by instructions of 1D textures. To handle the discrepancy this commit uses the the texture type from the binding and modifies the emitted code IR to build a valid backend expression. E.g.: Bound texture is 2D and instruction is 1D, the emitted IR samples a 2D texture in the coordinate ivec2(X, 0). | ||||
* | | shader/texture: Deduce texture buffers from locker | ReinUsesLisp | 2019-11-23 | 1 | -61/+41 |
|/ | | | | | Instead of specializing shaders to separate texture buffers from 1D textures, use the locker to deduce them while they are being decoded. | ||||
* | shader/texture: Remove NODEP warnings | ReinUsesLisp | 2019-11-07 | 1 | -35/+0 |
| | | | | | These warnings don't offer meaningful information while decoding shaders. Remove them. | ||||
* | Merge pull request #3039 from ReinUsesLisp/cleanup-samplers | Rodrigo Locatti | 2019-11-06 | 1 | -28/+31 |
|\ | | | | | shader/node: Unpack bindless texture encoding | ||||
| * | shader/node: Unpack bindless texture encoding | ReinUsesLisp | 2019-10-30 | 1 | -28/+31 |
| | | | | | | | | | | | | | | | | | | Bindless textures were using u64 to pack the buffer and offset from where they come from. Drop this in favor of separated entries in the struct. Remove the usage of std::set in favor of std::list (it's not std::vector to avoid reference invalidations) for samplers and images. | ||||
* | | Shader_IR: Fix regression on TLD4 | Fernando Sahmkow | 2019-10-31 | 1 | -4/+3 |
| | | | | | | | | | | | | Originally on the last commit I thought TLD4 acted the same as TLD4S and didn't have a mask. It actually does have a component mask. This commit corrects that. | ||||
* | | Shader_IR: Fix TLD4 and add Bindless Variant. | Fernando Sahmkow | 2019-10-30 | 1 | -8/+24 |
|/ | | | | | | This commit fixes an issue where not all 4 results of tld4 were being written, the color component was defaulted to red, among other things. It also implements the bindless variant. | ||||
* | Merge pull request #2976 from FernandoS27/cache-fast-brx-rebased | Rodrigo Locatti | 2019-10-26 | 1 | -20/+50 |
|\ | | | | | Implement Fast BRX, fix TXQ and addapt the Shader Cache for it | ||||
| * | Shader_IR: Address Feedback. | Fernando Sahmkow | 2019-10-26 | 1 | -22/+16 |
| | | |||||
| * | Shader_IR: allow lookup of texture samplers within the shader_ir for instructions that don't provide it | Fernando Sahmkow | 2019-10-25 | 1 | -18/+54 |
| | | |||||
* | | Shader_Ir: Fix TLD4S from using a component mask. | Fernando Sahmkow | 2019-10-22 | 1 | -4/+4 |
|/ | | | | | | TLD4S always outputs 4 values, the previous code checked a component mask and omitted those values that weren't part of it. This commit corrects that and makes sure all 4 values are set. | ||||
* | shader_ir: Rename Get/SetTemporal to Get/SetTemporary | Lioncash | 2019-07-17 | 1 | -13/+13 |
| | | | | | | This is more accurate in terms of describing what the functions are actually doing. Temporal relates to time, not the setting of a temporary itself. | ||||
* | shader: Allow tracking of indirect buffers without variable offset | ReinUsesLisp | 2019-07-15 | 1 | -6/+2 |
| | | | | | | While changing this code, simplify tracking code to allow returning the base address node, this way callers don't have to manually rebuild it on each invocation. | ||||
* | shader/texture: Add F16 support for TLDS | ReinUsesLisp | 2019-07-07 | 1 | -1/+7 |
| | |||||
* | decode/texture: Address feedback | ReinUsesLisp | 2019-06-24 | 1 | -0/+1 |
| | |||||
* | shader: Implement texture buffers | ReinUsesLisp | 2019-06-21 | 1 | -0/+44 |
| | |||||
* | shader: Use shared_ptr to store nodes and move initialization to file | ReinUsesLisp | 2019-06-06 | 1 | -4/+5 |
| | | | | | | | | | Instead of having a vector of unique_ptr stored in a vector and returning star pointers to this, use shared_ptr. While changing initialization code, move it to a separate file when possible. This is a first step to allow code analysis and node generation beyond the ShaderIR class. | ||||
* | video_core/shader/decode/texture: Remove unused variable from GetTld4Code() | Lioncash | 2019-05-10 | 1 | -1/+0 |
| | |||||
* | shader/decode/texture: Remove unused variable | Lioncash | 2019-05-04 | 1 | -1/+0 |
| | | | | This isn't used anywhere, so we can get rid of it. | ||||
* | shader_ir/texture: Fix sampler const buffer key shift | ReinUsesLisp | 2019-04-26 | 1 | -1/+1 |
| | |||||
* | Adapt Bindless to work with AOFFI | Fernando Sahmkow | 2019-04-08 | 1 | -7/+18 |
| | |||||
* | Move ConstBufferAccessor to Maxwell3d, correct mistakes and clang format. | Fernando Sahmkow | 2019-04-08 | 1 | -1/+2 |
| | |||||
* | Fix TMML | Fernando Sahmkow | 2019-04-08 | 1 | -5/+7 |
| | |||||
* | Refactor GetTextureCode and GetTexCode to use an optional instead of optional parameters | Fernando Sahmkow | 2019-04-08 | 1 | -23/+24 |
| | |||||
* | Implement TXQ_B | Fernando Sahmkow | 2019-04-08 | 1 | -2/+8 |
| | |||||
* | Implement TMML_B | Fernando Sahmkow | 2019-04-08 | 1 | -5/+10 |
| | |||||
* | Corrections to TEX_B | Fernando Sahmkow | 2019-04-08 | 1 | -4/+5 |
| | |||||
* | Unify both sampler types. | Fernando Sahmkow | 2019-04-08 | 1 | -10/+12 |
| | |||||
* | Implement Bindless Samplers and TEX_B in the IR. | Fernando Sahmkow | 2019-04-08 | 1 | -6/+52 |
| | |||||
* | shader_ir/decode: Silent implicit sign conversion warning | Mat M | 2019-03-31 | 1 | -2/+2 |
| | | | Co-Authored-By: ReinUsesLisp <reinuseslisp@airmail.cc> | ||||
* | shader_ir/decode: Implement AOFFI for TEX and TLD4 | ReinUsesLisp | 2019-03-30 | 1 | -24/+88 |
| | |||||
* | shader/decode: Remove extras from MetaTexture | ReinUsesLisp | 2019-02-26 | 1 | -14/+23 |
| | |||||
* | shader/decode: Split memory and texture instructions decoding | ReinUsesLisp | 2019-02-26 | 1 | -0/+525 |