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

Side by Side Diff: src/cfg.cc

Issue 165127: Factor out some platform-independent code into the shared cfg.cc. (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 11 years, 4 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/cfg-arm.cc ('k') | src/ia32/cfg-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 212 matching lines...) Expand 10 before | Expand all | Expand 10 after
223 void ReturnInstr::FastAllocate(TempLocation* temp) { 223 void ReturnInstr::FastAllocate(TempLocation* temp) {
224 ASSERT(temp->where() == TempLocation::NOT_ALLOCATED); 224 ASSERT(temp->where() == TempLocation::NOT_ALLOCATED);
225 if (temp == value_) { 225 if (temp == value_) {
226 temp->set_where(TempLocation::ACCUMULATOR); 226 temp->set_where(TempLocation::ACCUMULATOR);
227 } else { 227 } else {
228 temp->set_where(TempLocation::STACK); 228 temp->set_where(TempLocation::STACK);
229 } 229 }
230 } 230 }
231 231
232 232
233 void PositionInstr::Compile(MacroAssembler* masm) {
234 if (FLAG_debug_info && pos_ != RelocInfo::kNoPosition) {
235 masm->RecordStatementPosition(pos_);
236 masm->RecordPosition(pos_);
237 }
238 }
239
240
241 void MoveInstr::Compile(MacroAssembler* masm) {
242 location()->Move(masm, value());
243 }
244
245
233 // The expression builder should not be used for declarations or statements. 246 // The expression builder should not be used for declarations or statements.
234 void ExpressionBuilder::VisitDeclaration(Declaration* decl) { UNREACHABLE(); } 247 void ExpressionBuilder::VisitDeclaration(Declaration* decl) { UNREACHABLE(); }
235 248
236 #define DEFINE_VISIT(type) \ 249 #define DEFINE_VISIT(type) \
237 void ExpressionBuilder::Visit##type(type* stmt) { UNREACHABLE(); } 250 void ExpressionBuilder::Visit##type(type* stmt) { UNREACHABLE(); }
238 STATEMENT_NODE_LIST(DEFINE_VISIT) 251 STATEMENT_NODE_LIST(DEFINE_VISIT)
239 #undef DEFINE_VISIT 252 #undef DEFINE_VISIT
240 253
241 254
242 // Macros (temporarily) handling unsupported expression types. 255 // Macros (temporarily) handling unsupported expression types.
(...skipping 423 matching lines...) Expand 10 before | Expand all | Expand 10 after
666 void ExitNode::Print() { 679 void ExitNode::Print() {
667 if (!is_marked_) { 680 if (!is_marked_) {
668 is_marked_ = true; 681 is_marked_ = true;
669 PrintF("L%d:\nExit\n\n", number()); 682 PrintF("L%d:\nExit\n\n", number());
670 } 683 }
671 } 684 }
672 685
673 #endif // DEBUG 686 #endif // DEBUG
674 687
675 } } // namespace v8::internal 688 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/arm/cfg-arm.cc ('k') | src/ia32/cfg-ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698