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

Side by Side Diff: src/IceTargetLoweringX8632Traits.h

Issue 1575873006: Subzero: Fix g++ warnings. (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: Code review changes Created 4 years, 11 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/IceTargetLoweringX8632Traits.h - x86-32 traits -*- C++ -*-=// 1 //===- subzero/src/IceTargetLoweringX8632Traits.h - x86-32 traits -*- 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 /// \file 10 /// \file
(...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after
109 return static_cast<GPRRegister>(encoding_at(1) & 7); 109 return static_cast<GPRRegister>(encoding_at(1) & 7);
110 } 110 }
111 111
112 int8_t disp8() const { 112 int8_t disp8() const {
113 assert(length_ >= 2); 113 assert(length_ >= 2);
114 return static_cast<int8_t>(encoding_[length_ - 1]); 114 return static_cast<int8_t>(encoding_[length_ - 1]);
115 } 115 }
116 116
117 int32_t disp32() const { 117 int32_t disp32() const {
118 assert(length_ >= 5); 118 assert(length_ >= 5);
119 return bit_copy<int32_t>(encoding_[length_ - 4]); 119 // TODO(stichnot): This method is not currently used. Delete it along
120 // with other unused methods, or use a safe version of bitCopy().
121 llvm::report_fatal_error("Unexpected call to disp32()");
122 // return Utils::bitCopy<int32_t>(encoding_[length_ - 4]);
120 } 123 }
121 124
122 AssemblerFixup *fixup() const { return fixup_; } 125 AssemblerFixup *fixup() const { return fixup_; }
123 126
124 protected: 127 protected:
125 Operand() : fixup_(nullptr), length_(0) {} // Needed by subclass Address. 128 Operand() : fixup_(nullptr), length_(0) {} // Needed by subclass Address.
126 129
127 void SetModRM(int mod, GPRRegister rm) { 130 void SetModRM(int mod, GPRRegister rm) {
128 assert((mod & ~3) == 0); 131 assert((mod & ~3) == 0);
129 encoding_[0] = (mod << 6) | rm; 132 encoding_[0] = (mod << 6) | rm;
(...skipping 810 matching lines...) Expand 10 before | Expand all | Expand 10 after
940 943
941 static uint8_t InstSegmentPrefixes[]; 944 static uint8_t InstSegmentPrefixes[];
942 }; 945 };
943 946
944 using Traits = ::Ice::X8632::TargetX8632Traits; 947 using Traits = ::Ice::X8632::TargetX8632Traits;
945 } // end of namespace X8632 948 } // end of namespace X8632
946 949
947 } // end of namespace Ice 950 } // end of namespace Ice
948 951
949 #endif // SUBZERO_SRC_ICETARGETLOWERINGX8632TRAITS_H 952 #endif // SUBZERO_SRC_ICETARGETLOWERINGX8632TRAITS_H
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698