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

Side by Side Diff: src/IceTargetLoweringX8632.h

Issue 413053002: Lower the fcmp instruction for <4 x float> operands. (Closed) Base URL: https://gerrit.chromium.org/gerrit/p/native_client/pnacl-subzero.git@master
Patch Set: Improve table formatting and X macro parameter names Created 6 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
« no previous file with comments | « src/IceInstX8632.def ('k') | src/IceTargetLoweringX8632.cpp » ('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/IceTargetLoweringX8632.h - x86-32 lowering ---*- C++ -*-===// 1 //===- subzero/src/IceTargetLoweringX8632.h - x86-32 lowering ---*- 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 TargetLoweringX8632 class, which 10 // This file declares the TargetLoweringX8632 class, which
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after
101 Operand *Desired); 101 Operand *Desired);
102 void lowerAtomicRMW(Variable *Dest, uint32_t Operation, Operand *Ptr, 102 void lowerAtomicRMW(Variable *Dest, uint32_t Operation, Operand *Ptr,
103 Operand *Val); 103 Operand *Val);
104 void lowerCountZeros(bool Cttz, Type Ty, Variable *Dest, Operand *FirstVal, 104 void lowerCountZeros(bool Cttz, Type Ty, Variable *Dest, Operand *FirstVal,
105 Operand *SecondVal); 105 Operand *SecondVal);
106 106
107 typedef void (TargetX8632::*LowerBinOp)(Variable *, Operand *); 107 typedef void (TargetX8632::*LowerBinOp)(Variable *, Operand *);
108 void expandAtomicRMWAsCmpxchg(LowerBinOp op_lo, LowerBinOp op_hi, 108 void expandAtomicRMWAsCmpxchg(LowerBinOp op_lo, LowerBinOp op_hi,
109 Variable *Dest, Operand *Ptr, Operand *Val); 109 Variable *Dest, Operand *Ptr, Operand *Val);
110 110
111 void eliminateNextVectorSextInstruction(Variable *SignExtendedResult);
112
111 // Operand legalization helpers. To deal with address mode 113 // Operand legalization helpers. To deal with address mode
112 // constraints, the helpers will create a new Operand and emit 114 // constraints, the helpers will create a new Operand and emit
113 // instructions that guarantee that the Operand kind is one of those 115 // instructions that guarantee that the Operand kind is one of those
114 // indicated by the LegalMask (a bitmask of allowed kinds). If the 116 // indicated by the LegalMask (a bitmask of allowed kinds). If the
115 // input Operand is known to already meet the constraints, it may be 117 // input Operand is known to already meet the constraints, it may be
116 // simply returned as the result, without creating any new 118 // simply returned as the result, without creating any new
117 // instructions or operands. 119 // instructions or operands.
118 enum OperandLegalization { 120 enum OperandLegalization {
119 Legal_None = 0, 121 Legal_None = 0,
120 Legal_Reg = 1 << 0, // physical register, not stack location 122 Legal_Reg = 1 << 0, // physical register, not stack location
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after
205 } 207 }
206 void _cdq(Variable *Dest, Operand *Src0) { 208 void _cdq(Variable *Dest, Operand *Src0) {
207 Context.insert(InstX8632Cdq::create(Func, Dest, Src0)); 209 Context.insert(InstX8632Cdq::create(Func, Dest, Src0));
208 } 210 }
209 void _cmov(Variable *Dest, Operand *Src0, InstX8632::BrCond Condition) { 211 void _cmov(Variable *Dest, Operand *Src0, InstX8632::BrCond Condition) {
210 Context.insert(InstX8632Cmov::create(Func, Dest, Src0, Condition)); 212 Context.insert(InstX8632Cmov::create(Func, Dest, Src0, Condition));
211 } 213 }
212 void _cmp(Operand *Src0, Operand *Src1) { 214 void _cmp(Operand *Src0, Operand *Src1) {
213 Context.insert(InstX8632Icmp::create(Func, Src0, Src1)); 215 Context.insert(InstX8632Icmp::create(Func, Src0, Src1));
214 } 216 }
217 void _cmpps(Variable *Dest, Operand *Src0,
218 InstX8632Cmpps::CmppsCond Condition) {
219 Context.insert(InstX8632Cmpps::create(Func, Dest, Src0, Condition));
220 }
215 void _cmpxchg(Operand *DestOrAddr, Variable *Eax, Variable *Desired, 221 void _cmpxchg(Operand *DestOrAddr, Variable *Eax, Variable *Desired,
216 bool Locked) { 222 bool Locked) {
217 Context.insert( 223 Context.insert(
218 InstX8632Cmpxchg::create(Func, DestOrAddr, Eax, Desired, Locked)); 224 InstX8632Cmpxchg::create(Func, DestOrAddr, Eax, Desired, Locked));
219 // Mark eax as possibly modified by cmpxchg. 225 // Mark eax as possibly modified by cmpxchg.
220 Context.insert( 226 Context.insert(
221 InstFakeDef::create(Func, Eax, llvm::dyn_cast<Variable>(DestOrAddr))); 227 InstFakeDef::create(Func, Eax, llvm::dyn_cast<Variable>(DestOrAddr)));
222 } 228 }
223 void _cmpxchg8b(OperandX8632 *Addr, Variable *Edx, Variable *Eax, 229 void _cmpxchg8b(OperandX8632 *Addr, Variable *Edx, Variable *Eax,
224 Variable *Ecx, Variable *Ebx, bool Locked) { 230 Variable *Ecx, Variable *Ebx, bool Locked) {
(...skipping 230 matching lines...) Expand 10 before | Expand all | Expand 10 after
455 virtual ~TargetGlobalInitX8632() {} 461 virtual ~TargetGlobalInitX8632() {}
456 }; 462 };
457 463
458 template <> void ConstantInteger::emit(GlobalContext *Ctx) const; 464 template <> void ConstantInteger::emit(GlobalContext *Ctx) const;
459 template <> void ConstantFloat::emit(GlobalContext *Ctx) const; 465 template <> void ConstantFloat::emit(GlobalContext *Ctx) const;
460 template <> void ConstantDouble::emit(GlobalContext *Ctx) const; 466 template <> void ConstantDouble::emit(GlobalContext *Ctx) const;
461 467
462 } // end of namespace Ice 468 } // end of namespace Ice
463 469
464 #endif // SUBZERO_SRC_ICETARGETLOWERINGX8632_H 470 #endif // SUBZERO_SRC_ICETARGETLOWERINGX8632_H
OLDNEW
« no previous file with comments | « src/IceInstX8632.def ('k') | src/IceTargetLoweringX8632.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698