Skip to content

Commit 81059dc

Browse files
committed
.grow no longer required
1 parent 7b26935 commit 81059dc

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

llvm/lib/Target/AMDGPU/SIMachineFunctionInfo.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -696,8 +696,8 @@ class SIMachineFunctionInfo final : public AMDGPUMachineFunction,
696696

697697
void setFlag(Register Reg, uint8_t Flag) {
698698
assert(Reg.isVirtual());
699-
VRegFlags.grow(Reg);
700-
VRegFlags[Reg] |= Flag;
699+
if (VRegFlags.inBounds(Reg))
700+
VRegFlags[Reg] |= Flag;
701701
}
702702

703703
bool checkFlag(Register Reg, uint8_t Flag) const {

0 commit comments

Comments
 (0)