| OLD | NEW |
| 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 /// \file | 10 /// \file |
| (...skipping 792 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 803 // breaking strict-aliasing rules. | 803 // breaking strict-aliasing rules. |
| 804 typename T::PrimitiveIntType RawValue; | 804 typename T::PrimitiveIntType RawValue; |
| 805 memcpy(&RawValue, &Value, sizeof(Value)); | 805 memcpy(&RawValue, &Value, sizeof(Value)); |
| 806 char buf[30]; | 806 char buf[30]; |
| 807 int CharsPrinted = | 807 int CharsPrinted = |
| 808 snprintf(buf, llvm::array_lengthof(buf), T::PrintfString, RawValue); | 808 snprintf(buf, llvm::array_lengthof(buf), T::PrintfString, RawValue); |
| 809 assert(CharsPrinted >= 0 && | 809 assert(CharsPrinted >= 0 && |
| 810 (size_t)CharsPrinted < llvm::array_lengthof(buf)); | 810 (size_t)CharsPrinted < llvm::array_lengthof(buf)); |
| 811 (void)CharsPrinted; // avoid warnings if asserts are disabled | 811 (void)CharsPrinted; // avoid warnings if asserts are disabled |
| 812 Const->emitPoolLabel(Str, Ctx); | 812 Const->emitPoolLabel(Str, Ctx); |
| 813 Str << ":\n\t" << T::AsmTag << "\t" << buf << "\t# " << T::TypeName << " " | 813 Str << ":\n\t" << T::AsmTag << "\t" << buf << "\t/* " << T::TypeName << " " |
| 814 << Value << "\n"; | 814 << Value << " */\n"; |
| 815 } | 815 } |
| 816 } | 816 } |
| 817 | 817 |
| 818 void TargetDataX8632::lowerConstants() { | 818 void TargetDataX8632::lowerConstants() { |
| 819 if (Ctx->getFlags().getDisableTranslation()) | 819 if (Ctx->getFlags().getDisableTranslation()) |
| 820 return; | 820 return; |
| 821 // No need to emit constants from the int pool since (for x86) they are | 821 // No need to emit constants from the int pool since (for x86) they are |
| 822 // embedded as immediates in the instructions, just emit float/double. | 822 // embedded as immediates in the instructions, just emit float/double. |
| 823 switch (Ctx->getFlags().getOutFileType()) { | 823 switch (Ctx->getFlags().getOutFileType()) { |
| 824 case FT_Elf: { | 824 case FT_Elf: { |
| (...skipping 171 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 996 // case the high-level table has extra entries. | 996 // case the high-level table has extra entries. |
| 997 #define X(tag, sizeLog2, align, elts, elty, str) \ | 997 #define X(tag, sizeLog2, align, elts, elty, str) \ |
| 998 static_assert(_table1_##tag == _table2_##tag, \ | 998 static_assert(_table1_##tag == _table2_##tag, \ |
| 999 "Inconsistency between ICETYPEX8632_TABLE and ICETYPE_TABLE"); | 999 "Inconsistency between ICETYPEX8632_TABLE and ICETYPE_TABLE"); |
| 1000 ICETYPE_TABLE | 1000 ICETYPE_TABLE |
| 1001 #undef X | 1001 #undef X |
| 1002 } // end of namespace dummy3 | 1002 } // end of namespace dummy3 |
| 1003 } // end of anonymous namespace | 1003 } // end of anonymous namespace |
| 1004 | 1004 |
| 1005 } // end of namespace Ice | 1005 } // end of namespace Ice |
| OLD | NEW |