| 1 | //===- InlineSpiller.h - Inline spiller helpers -----------------*- 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 | #ifndef LLVM_LIB_CODEGEN_INLINESPILLER_H |
| 10 | #define LLVM_LIB_CODEGEN_INLINESPILLER_H |
| 11 | |
| 12 | #include "llvm/CodeGen/Register.h" |
| 13 | |
| 14 | namespace llvm { |
| 15 | |
| 16 | class MachineInstr; |
| 17 | |
| 18 | /// Return whether we can guarantee physical register assignment if VReg's value |
| 19 | /// is rematerialized immediately before its use in MI. The new live range must |
| 20 | /// be assignable without further spilling. For example, if MI is a pseudo |
| 21 | /// instruction that has more register operands than available physical |
| 22 | /// registers, rematerializing VReg may leave the new live range unassignable. |
| 23 | bool canGuaranteeAssignmentAfterRemat(Register VReg, const MachineInstr &MI); |
| 24 | |
| 25 | } // end namespace llvm |
| 26 | |
| 27 | #endif // LLVM_LIB_CODEGEN_INLINESPILLER_H |
| 28 | |