Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement missing opcode V_CVT_PK_I16_I32 #2046

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

AnthonyH26
Copy link

This helps with shadps4-emu/shadps4-game-compatibility#1864 where the opcode is missing, This now continues but errors within disc_map.cpp

The game compatability issue will be updated with new details

Added definition of V_CVT_PK_U16_U32
@georgemoralis
Copy link
Collaborator

This helps with shadps4-emu/shadps4-game-compatibility#1864 where the opcode is missing, This now continues but errors within disc_map.cpp

The game compatability issue will be updated with new details

The pr fails on clang format , your error also can be improved using lle discmap module

const IR::U32 src0{GetSrc(inst.src[0])};
const IR::U32 src1{GetSrc(inst.src[1])};
//Clamp the underflow then clamp the overflow from the result
IR::U32 lo = ir.IMax(src0, ir.Imm32(0x8000), true);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I assume this is supposed to be -1 in 16-bits. If these are being used as Imm32 values for 32-bit signed max/min, shouldn't they be 32-bit negative values instead? 0x8000 as a 32-bit immediate would just be 32768 instead.

@georgemoralis georgemoralis requested a review from psucien January 20, 2025 16:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants