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

Side by Side Diff: src/IceCfgNode.cpp

Issue 1141213004: Subzero: Fold icmp into br/select lowering. (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: Remove unnecessary break statement Created 5 years, 7 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
« no previous file with comments | « no previous file | src/IceClFlags.cpp » ('j') | src/IceTargetLoweringX8632.h » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 //===- subzero/src/IceCfgNode.cpp - Basic block (node) implementation -----===// 1 //===- subzero/src/IceCfgNode.cpp - Basic block (node) implementation -----===//
2 // 2 //
3 // The Subzero Code Generator 3 // The Subzero Code Generator
4 // 4 //
5 // This file is distributed under the University of Illinois Open Source 5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details. 6 // License. See LICENSE.TXT for details.
7 // 7 //
8 //===----------------------------------------------------------------------===// 8 //===----------------------------------------------------------------------===//
9 // 9 //
10 // This file implements the CfgNode class, including the complexities 10 // This file implements the CfgNode class, including the complexities
(...skipping 498 matching lines...) Expand 10 before | Expand all | Expand 10 after
509 Target->doNopInsertion(); 509 Target->doNopInsertion();
510 } 510 }
511 511
512 // Drives the target lowering. Passes the current instruction and the 512 // Drives the target lowering. Passes the current instruction and the
513 // next non-deleted instruction for target lowering. 513 // next non-deleted instruction for target lowering.
514 void CfgNode::genCode() { 514 void CfgNode::genCode() {
515 TargetLowering *Target = Func->getTarget(); 515 TargetLowering *Target = Func->getTarget();
516 LoweringContext &Context = Target->getContext(); 516 LoweringContext &Context = Target->getContext();
517 // Lower the regular instructions. 517 // Lower the regular instructions.
518 Context.init(this); 518 Context.init(this);
519 Target->initNodeForLowering(this);
519 while (!Context.atEnd()) { 520 while (!Context.atEnd()) {
520 InstList::iterator Orig = Context.getCur(); 521 InstList::iterator Orig = Context.getCur();
521 if (llvm::isa<InstRet>(*Orig)) 522 if (llvm::isa<InstRet>(*Orig))
522 setHasReturn(); 523 setHasReturn();
523 Target->lower(); 524 Target->lower();
524 // Ensure target lowering actually moved the cursor. 525 // Ensure target lowering actually moved the cursor.
525 assert(Context.getCur() != Orig); 526 assert(Context.getCur() != Orig);
526 } 527 }
527 // Do preliminary lowering of the Phi instructions. 528 // Do preliminary lowering of the Phi instructions.
528 Target->prelowerPhis(); 529 Target->prelowerPhis();
(...skipping 673 matching lines...) Expand 10 before | Expand all | Expand 10 after
1202 if (!First) 1203 if (!First)
1203 Str << ", "; 1204 Str << ", ";
1204 First = false; 1205 First = false;
1205 Str << "%" << I->getName(); 1206 Str << "%" << I->getName();
1206 } 1207 }
1207 Str << "\n"; 1208 Str << "\n";
1208 } 1209 }
1209 } 1210 }
1210 1211
1211 } // end of namespace Ice 1212 } // end of namespace Ice
OLDNEW
« no previous file with comments | « no previous file | src/IceClFlags.cpp » ('j') | src/IceTargetLoweringX8632.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698