Home | History | Annotate | Download | only in compiler

Lines Matching refs:node

40   InstructionOperand DefineAsRegister(Node* node) {
41 return Define(node,
43 GetVReg(node)));
46 InstructionOperand DefineSameAsFirst(Node* node) {
47 return Define(node,
49 GetVReg(node)));
52 InstructionOperand DefineAsFixed(Node* node, Register reg) {
53 return Define(node, UnallocatedOperand(UnallocatedOperand::FIXED_REGISTER,
54 reg.code(), GetVReg(node)));
57 InstructionOperand DefineAsFixed(Node* node, DoubleRegister reg) {
58 return Define(node,
60 reg.code(), GetVReg(node)));
63 InstructionOperand DefineAsConstant(Node* node) {
64 selector()->MarkAsDefined(node);
65 int virtual_register = GetVReg(node);
66 sequence()->AddConstant(virtual_register, ToConstant(node));
70 InstructionOperand DefineAsLocation(Node* node, LinkageLocation location,
72 return Define(node, ToUnallocatedOperand(location, rep, GetVReg(node)));
75 InstructionOperand DefineAsDualLocation(Node* node,
78 return Define(node,
80 primary_location, secondary_location, GetVReg(node)));
83 InstructionOperand Use(Node* node) {
84 return Use(node, UnallocatedOperand(UnallocatedOperand::NONE,
86 GetVReg(node)));
89 InstructionOperand UseAny(Node* node) {
90 return Use(node, UnallocatedOperand(UnallocatedOperand::ANY,
92 GetVReg(node)));
95 InstructionOperand UseRegister(Node* node) {
96 return Use(node, UnallocatedOperand(UnallocatedOperand::MUST_HAVE_REGISTER,
98 GetVReg(node)));
101 InstructionOperand UseUniqueSlot(Node* node) {
102 return Use(node, UnallocatedOperand(UnallocatedOperand::MUST_HAVE_SLOT,
103 GetVReg(node)));
106 // Use register or operand for the node. If a register is chosen, it won't
108 InstructionOperand UseUnique(Node* node) {
109 return Use(node,
110 UnallocatedOperand(UnallocatedOperand::NONE, GetVReg(node)));
113 // Use a unique register for the node that does not alias any temporary or
115 InstructionOperand UseUniqueRegister(Node* node) {
116 return Use(node, UnallocatedOperand(UnallocatedOperand::MUST_HAVE_REGISTER,
117 GetVReg(node)));
120 InstructionOperand UseFixed(Node* node, Register reg) {
121 return Use(node, UnallocatedOperand(UnallocatedOperand::FIXED_REGISTER,
122 reg.code(), GetVReg(node)));
125 InstructionOperand UseFixed(Node* node, DoubleRegister reg) {
126 return Use(node,
128 reg.code(), GetVReg(node)));
142 InstructionOperand UseImmediate(Node* node) {
143 return sequence()->AddImmediate(ToConstant(node));
146 InstructionOperand UseLocation(Node* node, LinkageLocation location,
148 return Use(node, ToUnallocatedOperand(location, rep, GetVReg(node)));
204 int GetVReg(Node* node) const { return selector_->GetVirtualRegister(node); }
206 static Constant ToConstant(const Node* node) {
207 switch (node->opcode()) {
209 return Constant(OpParameter<int32_t>(node));
211 return Constant(OpParameter<int64_t>(node));
213 return Constant(OpParameter<float>(node));
216 return Constant(OpParameter<double>(node));
218 return Constant(OpParameter<ExternalReference>(node));
220 return Constant(OpParameter<Handle<HeapObject>>(node));
228 UnallocatedOperand Define(Node* node, UnallocatedOperand operand) {
229 DCHECK_NOT_NULL(node);
230 DCHECK_EQ(operand.virtual_register(), GetVReg(node));
231 selector()->MarkAsDefined(node);
235 UnallocatedOperand Use(Node* node, UnallocatedOperand operand) {
236 DCHECK_NOT_NULL(node);
237 DCHECK_EQ(operand.virtual_register(), GetVReg(node));
238 selector()->MarkAsUsed(node);
306 // Creates a new flags continuation from the given condition and result node.
307 FlagsContinuation(FlagsCondition condition, Node* result)
319 Node* result() const {
360 Node* result_; // Only valid if mode_ == kFlags_set.