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

Side by Side Diff: src/IceInst.h

Issue 672393003: Subzero: Minor refactoring/additions in preparation for phi edge splitting. (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: Remove deprecated advanceBackward method Created 6 years, 2 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 | « src/IceClFlags.h ('k') | src/IceInstX8632.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/IceInst.h - High-level instructions ----------*- C++ -*-===// 1 //===- subzero/src/IceInst.h - High-level instructions ----------*- C++ -*-===//
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 declares the Inst class and its target-independent 10 // This file declares the Inst class and its target-independent
(...skipping 536 matching lines...) Expand 10 before | Expand all | Expand 10 after
547 class InstPhi : public InstHighLevel { 547 class InstPhi : public InstHighLevel {
548 InstPhi(const InstPhi &) = delete; 548 InstPhi(const InstPhi &) = delete;
549 InstPhi &operator=(const InstPhi &) = delete; 549 InstPhi &operator=(const InstPhi &) = delete;
550 550
551 public: 551 public:
552 static InstPhi *create(Cfg *Func, SizeT MaxSrcs, Variable *Dest) { 552 static InstPhi *create(Cfg *Func, SizeT MaxSrcs, Variable *Dest) {
553 return new (Func->allocateInst<InstPhi>()) InstPhi(Func, MaxSrcs, Dest); 553 return new (Func->allocateInst<InstPhi>()) InstPhi(Func, MaxSrcs, Dest);
554 } 554 }
555 void addArgument(Operand *Source, CfgNode *Label); 555 void addArgument(Operand *Source, CfgNode *Label);
556 Operand *getOperandForTarget(CfgNode *Target) const; 556 Operand *getOperandForTarget(CfgNode *Target) const;
557 CfgNode *getLabel(SizeT Index) const { return Labels[Index]; }
557 void livenessPhiOperand(LivenessBV &Live, CfgNode *Target, 558 void livenessPhiOperand(LivenessBV &Live, CfgNode *Target,
558 Liveness *Liveness); 559 Liveness *Liveness);
559 Inst *lower(Cfg *Func); 560 Inst *lower(Cfg *Func);
560 void dump(const Cfg *Func) const override; 561 void dump(const Cfg *Func) const override;
561 static bool classof(const Inst *Inst) { return Inst->getKind() == Phi; } 562 static bool classof(const Inst *Inst) { return Inst->getKind() == Phi; }
562 563
563 private: 564 private:
564 InstPhi(Cfg *Func, SizeT MaxSrcs, Variable *Dest); 565 InstPhi(Cfg *Func, SizeT MaxSrcs, Variable *Dest);
565 void destroy(Cfg *Func) override { 566 void destroy(Cfg *Func) override {
566 Func->deallocateArrayOf<CfgNode *>(Labels); 567 Func->deallocateArrayOf<CfgNode *>(Labels);
(...skipping 243 matching lines...) Expand 10 before | Expand all | Expand 10 after
810 InstTarget(Cfg *Func, InstKind Kind, SizeT MaxSrcs, Variable *Dest) 811 InstTarget(Cfg *Func, InstKind Kind, SizeT MaxSrcs, Variable *Dest)
811 : Inst(Func, Kind, MaxSrcs, Dest) { 812 : Inst(Func, Kind, MaxSrcs, Dest) {
812 assert(Kind >= Target); 813 assert(Kind >= Target);
813 } 814 }
814 ~InstTarget() override {} 815 ~InstTarget() override {}
815 }; 816 };
816 817
817 } // end of namespace Ice 818 } // end of namespace Ice
818 819
819 #endif // SUBZERO_SRC_ICEINST_H 820 #endif // SUBZERO_SRC_ICEINST_H
OLDNEW
« no previous file with comments | « src/IceClFlags.h ('k') | src/IceInstX8632.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698