LLVM  8.0.1
Public Member Functions | List of all members
llvm::PBQP::Solution Class Reference

Represents a solution to a PBQP problem. More...

#include "llvm/CodeGen/PBQP/Solution.h"

Public Member Functions

 Solution ()=default
 Initialise an empty solution. More...
 
void setSelection (GraphBase::NodeId nodeId, unsigned selection)
 Set the selection for a given node. More...
 
unsigned getSelection (GraphBase::NodeId nodeId) const
 Get a node's selection. More...
 

Detailed Description

Represents a solution to a PBQP problem.

To get the selection for each node in the problem use the getSelection method.

Definition at line 27 of file Solution.h.

Constructor & Destructor Documentation

◆ Solution()

llvm::PBQP::Solution::Solution ( )
default

Initialise an empty solution.

Member Function Documentation

◆ getSelection()

unsigned llvm::PBQP::Solution::getSelection ( GraphBase::NodeId  nodeId) const
inline

Get a node's selection.

Parameters
nodeIdNode id.
Returns
The selection for nodeId;

Definition at line 46 of file Solution.h.

References assert().

Referenced by llvm::PBQP::backpropagate(), and isACalleeSavedRegister().

◆ setSelection()

void llvm::PBQP::Solution::setSelection ( GraphBase::NodeId  nodeId,
unsigned  selection 
)
inline

Set the selection for a given node.

Parameters
nodeIdNode id.
selectionSelection for nodeId.

Definition at line 39 of file Solution.h.

Referenced by llvm::PBQP::backpropagate().


The documentation for this class was generated from the following file: