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

Side by Side Diff: src/IceCfgNode.cpp

Issue 692633004: Subzero: Remove Variable::NeedsStackSlot. (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: Code review changes Created 6 years, 1 month 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/IceOperand.h » ('j') | no next file with comments »
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 416 matching lines...) Expand 10 before | Expand all | Expand 10 after
427 // the "X=A" assignment in the cycle because it will have to 427 // the "X=A" assignment in the cycle because it will have to
428 // be rewritten as "X=tmp". 428 // be rewritten as "X=tmp".
429 for (size_t J = 0; !Found && J < NumPhis; ++J) { 429 for (size_t J = 0; !Found && J < NumPhis; ++J) {
430 if (Desc[J].Processed) 430 if (Desc[J].Processed)
431 continue; 431 continue;
432 Operand *OtherSrc = Desc[J].Src; 432 Operand *OtherSrc = Desc[J].Src;
433 if (Desc[J].NumPred && sameVarOrReg(Dest, OtherSrc)) { 433 if (Desc[J].NumPred && sameVarOrReg(Dest, OtherSrc)) {
434 SizeT VarNum = Func->getNumVariables(); 434 SizeT VarNum = Func->getNumVariables();
435 Variable *Tmp = Func->makeVariable( 435 Variable *Tmp = Func->makeVariable(
436 OtherSrc->getType(), "__split_" + std::to_string(VarNum)); 436 OtherSrc->getType(), "__split_" + std::to_string(VarNum));
437 Tmp->setNeedsStackSlot();
438 Assignments.push_back(InstAssign::create(Func, Tmp, OtherSrc)); 437 Assignments.push_back(InstAssign::create(Func, Tmp, OtherSrc));
439 Desc[J].Src = Tmp; 438 Desc[J].Src = Tmp;
440 Found = true; 439 Found = true;
441 } 440 }
442 } 441 }
443 assert(Found); 442 assert(Found);
444 } 443 }
445 // Now that a cycle (if any) has been broken, create the actual 444 // Now that a cycle (if any) has been broken, create the actual
446 // assignment. 445 // assignment.
447 Assignments.push_back(InstAssign::create(Func, Dest, Src)); 446 Assignments.push_back(InstAssign::create(Func, Dest, Src));
(...skipping 564 matching lines...) Expand 10 before | Expand all | Expand 10 after
1012 if (!First) 1011 if (!First)
1013 Str << ", "; 1012 Str << ", ";
1014 First = false; 1013 First = false;
1015 Str << "%" << I->getName(); 1014 Str << "%" << I->getName();
1016 } 1015 }
1017 Str << "\n"; 1016 Str << "\n";
1018 } 1017 }
1019 } 1018 }
1020 1019
1021 } // end of namespace Ice 1020 } // end of namespace Ice
OLDNEW
« no previous file with comments | « no previous file | src/IceOperand.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698