Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(453)

Side by Side Diff: src/fast-codegen.h

Issue 523052: More cleanup of slot handling in the nonoptimizing code generator.... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: '' Created 10 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/arm/fast-codegen-arm.cc ('k') | src/ia32/fast-codegen-ia32.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2009 the V8 project authors. All rights reserved. 1 // Copyright 2009 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 201 matching lines...) Expand 10 before | Expand all | Expand 10 after
212 212
213 213
214 int SlotOffset(Slot* slot); 214 int SlotOffset(Slot* slot);
215 void Move(Expression::Context destination, Register source); 215 void Move(Expression::Context destination, Register source);
216 void MoveTOS(Expression::Context destination); 216 void MoveTOS(Expression::Context destination);
217 void Move(Expression::Context destination, Slot* source, Register scratch); 217 void Move(Expression::Context destination, Slot* source, Register scratch);
218 void Move(Expression::Context destination, Literal* source); 218 void Move(Expression::Context destination, Literal* source);
219 void Move(Slot* dst, Register source, Register scratch1, Register scratch2); 219 void Move(Slot* dst, Register source, Register scratch1, Register scratch2);
220 void Move(Register dst, Slot* source); 220 void Move(Register dst, Slot* source);
221 221
222 // Templated to allow for Operand on intel and MemOperand on ARM. 222 // Return an operand used to read/write to a known (ie, non-LOOKUP) slot.
223 template <typename MemoryLocation> 223 // May emit code to traverse the context chain, destroying the scratch
224 MemoryLocation CreateSlotOperand(Slot* slot, Register scratch); 224 // register.
225 MemOperand EmitSlotSearch(Slot* slot, Register scratch);
225 226
226 // Drop the TOS, and store source to destination. 227 // Drop the TOS, and store source to destination.
227 // If destination is TOS, just overwrite TOS with source. 228 // If destination is TOS, just overwrite TOS with source.
228 void DropAndMove(Expression::Context destination, 229 void DropAndMove(Expression::Context destination,
229 Register source, 230 Register source,
230 int drop_count = 1); 231 int drop_count = 1);
231 232
232 // Test the JavaScript value in source as if in a test context, compile 233 // Test the JavaScript value in source as if in a test context, compile
233 // control flow to a pair of labels. 234 // control flow to a pair of labels.
234 void TestAndBranch(Register source, Label* true_label, Label* false_label); 235 void TestAndBranch(Register source, Label* true_label, Label* false_label);
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after
321 322
322 friend class NestedStatement; 323 friend class NestedStatement;
323 324
324 DISALLOW_COPY_AND_ASSIGN(FastCodeGenerator); 325 DISALLOW_COPY_AND_ASSIGN(FastCodeGenerator);
325 }; 326 };
326 327
327 328
328 } } // namespace v8::internal 329 } } // namespace v8::internal
329 330
330 #endif // V8_FAST_CODEGEN_H_ 331 #endif // V8_FAST_CODEGEN_H_
OLDNEW
« no previous file with comments | « src/arm/fast-codegen-arm.cc ('k') | src/ia32/fast-codegen-ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698