Revert " [LoongArch][ISel] Check the number of sign bits in `PatGprGpr_32` (#107432)"
[llvm-project.git] / llvm / lib / Target / SPIRV / SPIRVRegisterInfo.cpp
blobcf8a967d59c4fcaf602078002e1a4092a4e47b4b
1 //===-- SPIRVRegisterInfo.cpp - SPIR-V Register Information -----*- C++ -*-===//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
8 //
9 // This file contains the SPIR-V implementation of the TargetRegisterInfo class.
11 //===----------------------------------------------------------------------===//
13 #include "SPIRVRegisterInfo.h"
14 #include "SPIRV.h"
15 #include "SPIRVSubtarget.h"
16 #include "llvm/CodeGen/MachineFunction.h"
18 #define GET_REGINFO_TARGET_DESC
19 #include "SPIRVGenRegisterInfo.inc"
20 using namespace llvm;
22 SPIRVRegisterInfo::SPIRVRegisterInfo() : SPIRVGenRegisterInfo(SPIRV::ID0) {}
24 BitVector SPIRVRegisterInfo::getReservedRegs(const MachineFunction &MF) const {
25 return BitVector(getNumRegs());
28 const MCPhysReg *
29 SPIRVRegisterInfo::getCalleeSavedRegs(const MachineFunction *MF) const {
30 static const MCPhysReg CalleeSavedReg = {0};
31 return &CalleeSavedReg;