diff --git a/src/alloy/compiler/passes/constant_propagation_pass.cc b/src/alloy/compiler/passes/constant_propagation_pass.cc index 471bc2633..072530db9 100644 --- a/src/alloy/compiler/passes/constant_propagation_pass.cc +++ b/src/alloy/compiler/passes/constant_propagation_pass.cc @@ -317,8 +317,13 @@ int ConstantPropagationPass::Run(HIRBuilder* builder) { } } } - i->Replace(&OPCODE_ASSIGN_info, 0); - i->set_src1(ca); + if (i->dest->type == ca->type) { + i->Replace(&OPCODE_ASSIGN_info, 0); + i->set_src1(ca); + } else { + i->Replace(&OPCODE_ZERO_EXTEND_info, 0); + i->set_src1(ca); + } } break; case OPCODE_SUB: diff --git a/src/alloy/frontend/ppc/ppc_emit_alu.cc b/src/alloy/frontend/ppc/ppc_emit_alu.cc index da8bf65a6..8638a0216 100644 --- a/src/alloy/frontend/ppc/ppc_emit_alu.cc +++ b/src/alloy/frontend/ppc/ppc_emit_alu.cc @@ -478,7 +478,7 @@ XEEMITTER(subfmex, 0x7C0001D0, XO)(PPCHIRBuilder& f, InstrData& i) { XEEMITTER(subfzex, 0x7C000190, XO)(PPCHIRBuilder& f, InstrData& i) { // RT <- ¬(RA) + CA Value* v = f.AddWithCarry(f.Not(f.LoadGPR(i.XO.RA)), f.LoadZero(INT64_TYPE), - f.LoadCA()); + f.LoadCA(), ARITHMETIC_SET_CARRY); if (i.XO.OE) { assert_always(); // e.update_xer_with_overflow_and_carry(b.CreateExtractValue(v, 1)); diff --git a/src/xenia/gpu/d3d11/d3d11_window.cc b/src/xenia/gpu/d3d11/d3d11_window.cc index eb1e50d5b..c99cdc421 100644 --- a/src/xenia/gpu/d3d11/d3d11_window.cc +++ b/src/xenia/gpu/d3d11/d3d11_window.cc @@ -138,4 +138,3 @@ bool D3D11Window::OnResize(uint32_t width, uint32_t height) { return true; } - diff --git a/src/xenia/kernel/xboxkrnl_rtl.cc b/src/xenia/kernel/xboxkrnl_rtl.cc index c15ff783c..8616c5474 100644 --- a/src/xenia/kernel/xboxkrnl_rtl.cc +++ b/src/xenia/kernel/xboxkrnl_rtl.cc @@ -341,7 +341,7 @@ SHIM_CALL RtlNtStatusToDosError_shim(PPCContext* ppc_state, } // TODO(benvanik): implement lookup table. - XELOGE("RtlNtStatusToDosError lookup NOT SHIMEMENTED"); + XELOGE("RtlNtStatusToDosError lookup NOT IMPLEMENTED"); uint32_t result = 317; // ERROR_MR_MID_NOT_FOUND