mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2026-04-25 15:56:00 +03:00
[PR #347] [CLOSED] Op arg float as default #1500
Labels
No labels
Bloodborne
bug
contributor wanted
documentation
enhancement
frontend
good first issue
help wanted
linux
pull-request
question
release
verification progress
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/shadPS4#1500
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/shadps4-emu/shadPS4/pull/347
Author: @viniciuslrangel
Created: 7/31/2024
Status: ❌ Closed
Base:
main← Head:op-arg-float-as-default📝 Commits (3)
501bc70shader_recompiler: GetSrc as float by default except when explicit523fc24shader_recompiler: rewrite GetSrc api to allow compile-time check of types813e1efshader_recompiler: renamed SrcValue to SrcValue & added simple docs📊 Changes
7 files changed (+258 additions, -191 deletions)
View changed files
📝
src/shader_recompiler/frontend/translate/data_share.cpp(+3 -3)📝
src/shader_recompiler/frontend/translate/scalar_alu.cpp(+4 -4)📝
src/shader_recompiler/frontend/translate/translate.cpp(+85 -35)📝
src/shader_recompiler/frontend/translate/translate.h(+30 -4)📝
src/shader_recompiler/frontend/translate/vector_alu.cpp(+69 -63)📝
src/shader_recompiler/ir/ir_emitter.cpp(+53 -75)📝
src/shader_recompiler/ir/ir_emitter.h(+14 -7)📄 Description
After removing the 'force_flt' assumption based on input modifications, some games stopped running due to an early MOV operation that restricted the parser from inferring the value as a float, so I thought we should keep all values as float by default and force to integer only when needed by I32 OPs.
However I started getting a lot of errors from invalid types and had to run, wait to crash, and fix. So I changed the GetSrc implementation to infer the correct value based on return type, not only cleaning the code but making it easier for new OP to be implemented without needing to handle type conversion from GetSrc, including 64-bit types.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.