[RS4GC] Simplify attribute handling code NFC

Avoids use of AttributeList::getNumSlots, making it easier to change the
underlying implementation.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@301671 91177308-0d34-0410-b5e6-96231b3b80d8
1 file changed