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

Side by Side Diff: src/IceRegAlloc.h

Issue 1216963007: Doxygenize the documentation comments (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: Created 5 years, 5 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
OLDNEW
1 //===- subzero/src/IceRegAlloc.h - Linear-scan reg. allocation --*- C++ -*-===// 1 //===- subzero/src/IceRegAlloc.h - Linear-scan reg. allocation --*- 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 LinearScan data structure used during 10 // This file declares the LinearScan data structure used during
(...skipping 20 matching lines...) Expand all
31 void init(RegAllocKind Kind); 31 void init(RegAllocKind Kind);
32 void scan(const llvm::SmallBitVector &RegMask, bool Randomized); 32 void scan(const llvm::SmallBitVector &RegMask, bool Randomized);
33 void dump(Cfg *Func) const; 33 void dump(Cfg *Func) const;
34 34
35 private: 35 private:
36 typedef std::vector<Variable *> OrderedRanges; 36 typedef std::vector<Variable *> OrderedRanges;
37 typedef std::vector<Variable *> UnorderedRanges; 37 typedef std::vector<Variable *> UnorderedRanges;
38 38
39 void initForGlobal(); 39 void initForGlobal();
40 void initForInfOnly(); 40 void initForInfOnly();
41 // Move an item from the From set to the To set. From[Index] is 41 /// Move an item from the From set to the To set. From[Index] is
42 // pushed onto the end of To[], then the item is efficiently removed 42 /// pushed onto the end of To[], then the item is efficiently removed
43 // from From[] by effectively swapping it with the last item in 43 /// from From[] by effectively swapping it with the last item in
44 // From[] and then popping it from the back. As such, the caller is 44 /// From[] and then popping it from the back. As such, the caller is
45 // best off iterating over From[] in reverse order to avoid the need 45 /// best off iterating over From[] in reverse order to avoid the need
46 // for special handling of the iterator. 46 /// for special handling of the iterator.
47 void moveItem(UnorderedRanges &From, SizeT Index, UnorderedRanges &To) { 47 void moveItem(UnorderedRanges &From, SizeT Index, UnorderedRanges &To) {
48 To.push_back(From[Index]); 48 To.push_back(From[Index]);
49 From[Index] = From.back(); 49 From[Index] = From.back();
50 From.pop_back(); 50 From.pop_back();
51 } 51 }
52 52
53 Cfg *const Func; 53 Cfg *const Func;
54 OrderedRanges Unhandled; 54 OrderedRanges Unhandled;
55 // UnhandledPrecolored is a subset of Unhandled, specially collected 55 /// UnhandledPrecolored is a subset of Unhandled, specially collected
56 // for faster processing. 56 /// for faster processing.
57 OrderedRanges UnhandledPrecolored; 57 OrderedRanges UnhandledPrecolored;
58 UnorderedRanges Active, Inactive, Handled; 58 UnorderedRanges Active, Inactive, Handled;
59 std::vector<InstNumberT> Kills; 59 std::vector<InstNumberT> Kills;
60 bool FindPreference = false; 60 bool FindPreference = false;
61 bool FindOverlap = false; 61 bool FindOverlap = false;
62 // TODO(stichnot): We're not really using FindOverlap yet, but we 62 // TODO(stichnot): We're not really using FindOverlap yet, but we
63 // may want a flavor of register allocation where FindPreference is 63 // may want a flavor of register allocation where FindPreference is
64 // useful but we didn't want to initialize VMetadata with VMK_All 64 // useful but we didn't want to initialize VMetadata with VMK_All
65 // and therefore we can't safely allow overlap. 65 // and therefore we can't safely allow overlap.
66 }; 66 };
67 67
68 } // end of namespace Ice 68 } // end of namespace Ice
69 69
70 #endif // SUBZERO_SRC_ICEREGALLOC_H 70 #endif // SUBZERO_SRC_ICEREGALLOC_H
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698