From 0a8ee148bb628735c706337e21614f08dc381753 Mon Sep 17 00:00:00 2001 From: Matt Arsenault Date: Sat, 26 Sep 2015 04:53:30 +0000 Subject: [PATCH] AMDGPU: Don't handle invalid reg classes in helper functions No tests hit these and it would be better to have checks like this explicit where they are used. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@248655 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Target/AMDGPU/SIRegisterInfo.h | 6 ------ 1 file changed, 6 deletions(-) diff --git a/lib/Target/AMDGPU/SIRegisterInfo.h b/lib/Target/AMDGPU/SIRegisterInfo.h index a70d086cb52..c59c0147e8a 100644 --- a/lib/Target/AMDGPU/SIRegisterInfo.h +++ b/lib/Target/AMDGPU/SIRegisterInfo.h @@ -48,17 +48,11 @@ public: /// \returns true if this class contains only SGPR registers bool isSGPRClass(const TargetRegisterClass *RC) const { - if (!RC) - return false; - return !hasVGPRs(RC); } /// \returns true if this class ID contains only SGPR registers bool isSGPRClassID(unsigned RCID) const { - if (static_cast(RCID) == -1) - return false; - return isSGPRClass(getRegClass(RCID)); } -- 2.34.1