mirror of
https://github.com/hrydgard/ppsspp.git
synced 2025-04-02 11:01:50 -04:00
Fix a -unsigned warning.
Looks ugly, but (u32)-(s32)val is what we really want here. Also make a __FUNCTION__ redeclaration warning go away.
This commit is contained in:
parent
4a89e2e74f
commit
f165a15eff
2 changed files with 6 additions and 4 deletions
|
@ -38,7 +38,9 @@
|
|||
|
||||
// __FUNCTION__ is misused a lot below, it's no longer a string literal but a virtual
|
||||
// variable so this use fails in some compilers. Just define it away for now.
|
||||
#ifndef _MSC_VER
|
||||
#define __FUNCTION__ "(n/a)"
|
||||
#endif
|
||||
|
||||
namespace ArmGen
|
||||
{
|
||||
|
@ -166,8 +168,8 @@ void ARMXEmitter::ADDI2R(ARMReg rd, ARMReg rs, u32 val, ARMReg scratch)
|
|||
// Decompose into two additions.
|
||||
ADD(rd, rs, Operand2((u8)(val >> 8), 12)); // rotation right by 12*2 == rotation left by 8
|
||||
ADD(rd, rd, Operand2((u8)(val), 0));
|
||||
} else if (((-(u32)(s32)val) & 0xFFFF0000) == 0) {
|
||||
val = -(u32)(s32)val;
|
||||
} else if ((((u32)-(s32)val) & 0xFFFF0000) == 0) {
|
||||
val = (u32)-(s32)val;
|
||||
SUB(rd, rs, Operand2((u8)(val >> 8), 12));
|
||||
SUB(rd, rd, Operand2((u8)(val), 0));
|
||||
} else {
|
||||
|
|
|
@ -169,8 +169,8 @@ void MIPSState::DoState(PointerWrap &p) {
|
|||
p.Do(lo);
|
||||
p.Do(fpcond);
|
||||
if (s <= 1) {
|
||||
u32 fcr0_unusued = 0;
|
||||
p.Do(fcr0_unusued);
|
||||
u32 fcr0_unused = 0;
|
||||
p.Do(fcr0_unused);
|
||||
}
|
||||
p.Do(fcr31);
|
||||
p.Do(rng.m_w);
|
||||
|
|
Loading…
Add table
Reference in a new issue