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

Unified Diff: src/IceOperand.cpp

Issue 691693003: Subzero: Improve the representation and handling of the FakeKill instruction. (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: Add an assert 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/IceInst.cpp ('k') | src/IceTargetLoweringX8632.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/IceOperand.cpp
diff --git a/src/IceOperand.cpp b/src/IceOperand.cpp
index e1faf0fa668cbfa2f404b12a08101c2e9e2c509b..8cf181afff3f67927c941fa8d004e23bfc39b2d7 100644
--- a/src/IceOperand.cpp
+++ b/src/IceOperand.cpp
@@ -350,18 +350,8 @@ void VariablesMetadata::addNode(CfgNode *Node) {
for (Inst *I : Node->getInsts()) {
if (I->isDeleted())
continue;
- if (InstFakeKill *Kill = llvm::dyn_cast<InstFakeKill>(I)) {
- // A FakeKill instruction indicates certain Variables (usually
- // physical scratch registers) are redefined, so we register
- // them as defs.
- for (SizeT SrcNum = 0; SrcNum < I->getSrcSize(); ++SrcNum) {
- Variable *Var = llvm::cast<Variable>(I->getSrc(SrcNum));
- SizeT VarNum = Var->getIndex();
- assert(VarNum < Metadata.size());
- Metadata[VarNum].markDef(Kind, Kill, Node);
- }
- continue; // no point in executing the rest
- }
+ // Note: The implicit definitions (and uses) from InstFakeKill are
+ // deliberately ignored.
if (Variable *Dest = I->getDest()) {
SizeT DestNum = Dest->getIndex();
assert(DestNum < Metadata.size());
« no previous file with comments | « src/IceInst.cpp ('k') | src/IceTargetLoweringX8632.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698