[AMDGPU] Tidy up some simple expressions for clarity NFC
Slight refactor for clarity. Change-Id: Ib25e7f4582c67a7c57f066cfd5382c1405d7d4c5 Differential Revision: https://reviews.llvm.org/D101610
This commit is contained in:
parent
417b1164c2
commit
a67a377014
@ -4244,7 +4244,7 @@ bool SIInstrInfo::verifyInstruction(const MachineInstr &MI,
|
||||
unsigned AddrComponents = (BaseOpcode->Coordinates ? Dim->NumCoords : 0) +
|
||||
(BaseOpcode->LodOrClampOrMip ? 1 : 0);
|
||||
if (IsA16)
|
||||
AddrWords += (AddrComponents + 1) / 2;
|
||||
AddrWords += divideCeil(AddrComponents, 2);
|
||||
else
|
||||
AddrWords += AddrComponents;
|
||||
|
||||
@ -4252,7 +4252,7 @@ bool SIInstrInfo::verifyInstruction(const MachineInstr &MI,
|
||||
if (PackDerivatives)
|
||||
// There are two gradients per coordinate, we pack them separately.
|
||||
// For the 3d case, we get (dy/du, dx/du) (-, dz/du) (dy/dv, dx/dv) (-, dz/dv)
|
||||
AddrWords += (Dim->NumGradients / 2 + 1) / 2 * 2;
|
||||
AddrWords += alignTo<2>(Dim->NumGradients / 2);
|
||||
else
|
||||
AddrWords += Dim->NumGradients;
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user