summaryrefslogtreecommitdiffstats
path: root/src/video_core/shader/decode/arithmetic_integer.cpp (unfollow)
Commit message (Collapse)AuthorFilesLines
2021-07-23shader: Remove old shader managementReinUsesLisp1-375/+0
2020-12-07video_core: Remove unnecessary enum class casting in logging messagesLioncash1-1/+1
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-05video_core: Resolve more variable shadowing scenarios pt.3Lioncash1-3/+4
Cleans out the rest of the occurrences of variable shadowing and makes any further occurrences of shadowing compiler errors.
2020-07-21video_core: Allow copy elision to take place where applicableLioncash1-3/+3
Removes const from some variables that are returned from functions, as this allows the move assignment/constructors to execute for them.
2020-04-28shader/arithmetic_integer: Fix tracking issue in temporaryReinUsesLisp1-4/+0
This temporary is not needed as we mark Rd.CC + IADD.X as unimplemented. It caused issues when tracking global buffers.
2020-04-26shader/arithmetic_integer: Fix edge case and mark IADD.X Rd.CC as unimplementedReinUsesLisp1-1/+6
IADD.X Rd.CC requires some extra logic that is not currently implemented. Abort when this is hit.
2020-04-26shader/arithmetic_integer: Change IAdd to UAdd to avoid signed overflowReinUsesLisp1-2/+2
Signed integer addition overflow might be undefined behavior. It's free to change operations to UAdd and use unsigned integers to avoid potential bugs.
2020-04-26shader/arithmetic_integer: Implement IADD.XReinUsesLisp1-0/+6
IADD.X takes the carry flag and adds it to the result. This is generally used to emulate 64-bit operations with 32-bit registers.
2020-04-26shader/arithmetic_integer: Implement CC for IADDReinUsesLisp1-3/+19
2020-04-21shader/arithmetic_integer: Fix LEA_IMM encodingReinUsesLisp1-2/+2
The operand order in LEA_IMM was flipped compared to nvdisasm. Fix that using nxas as reference: https://github.com/ReinUsesLisp/nxas/blob/8dbc38995711cc12206aa370145a3a02665fd989/table.h#L122
2020-03-28shader/lea: Simplify generated LEA codeReinUsesLisp1-3/+2
2020-03-27shader/lea: Fix op_a and op_b usagesReinUsesLisp1-2/+2
They were swapped.
2020-03-27shader/lea: Remove const and use move when possibleReinUsesLisp1-11/+5
2020-02-21nit: add const to where it need.Nguyen Dac Nam1-14/+14
2020-02-21shader: implement LOP3 fast replace for old functionNguyen Dac Nam1-36/+58
ref: https://devtalk.nvidia.com/default/topic/1070081/cuda-programming-and-performance/reverse-lut-for-lop3-lut/
2020-02-05shader/decode: Fix constant buffer offsetsReinUsesLisp1-2/+2
Some instances were using cbuf34.offset instead of cbuf34.GetOffset(). This returned the an invalid offset. Address those instances and rename offset to "shifted_offset" to avoid future bugs.
2020-02-02shader: Remove curly braces initializers on shared pointersReinUsesLisp1-1/+1
2019-11-18Shader_IR: Address FeedbackFernando Sahmkow1-5/+6
2019-11-14Shader_IR: Implement FLO instruction.Fernando Sahmkow1-0/+18
2019-10-24video_core/shader: Resolve instances of variable shadowingLioncash1-3/+3
Silences a few -Wshadow warnings.
2019-09-21Shader_IR: ICMP corrections and fixesFernando Sahmkow1-6/+9
2019-09-20Shader_IR: Implement ICMP.Fernando Sahmkow1-0/+26
2019-06-06shader: Use shared_ptr to store nodes and move initialization to fileReinUsesLisp1-0/+1
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.
2019-02-11Fix incorrect value for CC bit in IADDFernando Sahmkow1-2/+2
2019-02-03shader_ir: Rename BasicBlock to NodeBlockReinUsesLisp1-2/+2
It's not always used as a basic block. Rename it for consistency.
2019-02-03shader_ir: Pass decoded nodes as a whole instead of per basic blocksReinUsesLisp1-1/+1
Some games call LDG at the top of a basic block, making the tracking heuristic to fail. This commit lets the heuristic the decoded nodes as a whole instead of per basic blocks. This may lead to some false positives but allows it the heuristic to track cases it previously couldn't.
2019-01-30shader_ir: Unify constant buffer offset valuesReinUsesLisp1-1/+1
Constant buffer values on the shader IR were using different offsets if the access direct or indirect. cbuf34 has a non-multiplied offset while cbuf36 does. On shader decoding this commit multiplies it by four on cbuf34 queries.
2019-01-15shader_ir: Pass to decoder functions basic block's codeReinUsesLisp1-1/+1
2019-01-15shader_decode: Improve zero flag implementationReinUsesLisp1-17/+14
2019-01-15shader_decode: Use BitfieldExtract instead of shift + andReinUsesLisp1-3/+2
2019-01-15shader_decode: Implement POPCReinUsesLisp1-0/+10
2019-01-15shader_decode: Implement LEAReinUsesLisp1-0/+55
2019-01-15shader_decode: Implement IADD3ReinUsesLisp1-0/+61
2019-01-15shader_decode: Implement LOP3ReinUsesLisp1-0/+60
2019-01-15shader_decode: Implement IMNMXReinUsesLisp1-0/+16
2019-01-15shader_decode: Implement ISCADDReinUsesLisp1-0/+15
2019-01-15shader_decode: Implement LOPReinUsesLisp1-0/+15
2019-01-15shader_decode: Implement SELReinUsesLisp1-0/+8
2019-01-15shader_decode: Implement IADDReinUsesLisp1-1/+28
2019-01-15shader_ir: Initial implementationReinUsesLisp1-0/+24