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

Side by Side Diff: src/IceTargetLoweringX8632.cpp

Issue 649463002: Handle "Mov" which is mov, movss, movsd, and used for nacl.read.tp. (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: fixups 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/IceOperand.h ('k') | src/PNaClTranslator.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.cpp - x86-32 lowering -----------===// 1 //===- subzero/src/IceTargetLoweringX8632.cpp - x86-32 lowering -----------===//
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 implements the TargetLoweringX8632 class, which 10 // This file implements the TargetLoweringX8632 class, which
(...skipping 1040 matching lines...) Expand 10 before | Expand all | Expand 10 after
1051 } 1051 }
1052 if (OperandX8632Mem *Mem = llvm::dyn_cast<OperandX8632Mem>(Operand)) { 1052 if (OperandX8632Mem *Mem = llvm::dyn_cast<OperandX8632Mem>(Operand)) {
1053 Constant *Offset = Mem->getOffset(); 1053 Constant *Offset = Mem->getOffset();
1054 if (Offset == NULL) 1054 if (Offset == NULL)
1055 Offset = Ctx->getConstantInt32(IceType_i32, 4); 1055 Offset = Ctx->getConstantInt32(IceType_i32, 4);
1056 else if (ConstantInteger32 *IntOffset = 1056 else if (ConstantInteger32 *IntOffset =
1057 llvm::dyn_cast<ConstantInteger32>(Offset)) { 1057 llvm::dyn_cast<ConstantInteger32>(Offset)) {
1058 Offset = Ctx->getConstantInt32(IceType_i32, 4 + IntOffset->getValue()); 1058 Offset = Ctx->getConstantInt32(IceType_i32, 4 + IntOffset->getValue());
1059 } else if (ConstantRelocatable *SymOffset = 1059 } else if (ConstantRelocatable *SymOffset =
1060 llvm::dyn_cast<ConstantRelocatable>(Offset)) { 1060 llvm::dyn_cast<ConstantRelocatable>(Offset)) {
1061 assert(!Utils::WouldOverflowAdd(SymOffset->getOffset(), 4));
1061 Offset = Ctx->getConstantSym(IceType_i32, 4 + SymOffset->getOffset(), 1062 Offset = Ctx->getConstantSym(IceType_i32, 4 + SymOffset->getOffset(),
1062 SymOffset->getName()); 1063 SymOffset->getName());
1063 } 1064 }
1064 return OperandX8632Mem::create(Func, IceType_i32, Mem->getBase(), Offset, 1065 return OperandX8632Mem::create(Func, IceType_i32, Mem->getBase(), Offset,
1065 Mem->getIndex(), Mem->getShift(), 1066 Mem->getIndex(), Mem->getShift(),
1066 Mem->getSegmentRegister()); 1067 Mem->getSegmentRegister());
1067 } 1068 }
1068 llvm_unreachable("Unsupported operand type"); 1069 llvm_unreachable("Unsupported operand type");
1069 return NULL; 1070 return NULL;
1070 } 1071 }
(...skipping 3439 matching lines...) Expand 10 before | Expand all | Expand 10 after
4510 } else if (IsConstant || IsExternal) 4511 } else if (IsConstant || IsExternal)
4511 Str << "\t.zero\t" << Size << "\n"; 4512 Str << "\t.zero\t" << Size << "\n";
4512 // Size is part of .comm. 4513 // Size is part of .comm.
4513 4514
4514 if (IsConstant || HasInitializer || IsExternal) 4515 if (IsConstant || HasInitializer || IsExternal)
4515 Str << "\t.size\t" << MangledName << ", " << Size << "\n"; 4516 Str << "\t.size\t" << MangledName << ", " << Size << "\n";
4516 // Size is part of .comm. 4517 // Size is part of .comm.
4517 } 4518 }
4518 4519
4519 } // end of namespace Ice 4520 } // end of namespace Ice
OLDNEW
« no previous file with comments | « src/IceOperand.h ('k') | src/PNaClTranslator.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698