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

Side by Side Diff: src/mips/macro-assembler-mips.cc

Issue 12505004: MIPS: Fixed faulty branch condition handling for doubles. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 9 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 | Annotate | Revision Log
« no previous file with comments | « src/mips/lithium-codegen-mips.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 1107 matching lines...) Expand 10 before | Expand all | Expand 10 after
1118 if (nan) { 1118 if (nan) {
1119 c(UN, D, cmp1, cmp2); 1119 c(UN, D, cmp1, cmp2);
1120 bc1t(nan); 1120 bc1t(nan);
1121 } 1121 }
1122 1122
1123 if (target) { 1123 if (target) {
1124 // Here NaN cases were either handled by this function or are assumed to 1124 // Here NaN cases were either handled by this function or are assumed to
1125 // have been handled by the caller. 1125 // have been handled by the caller.
1126 // Unsigned conditions are treated as their signed counterpart. 1126 // Unsigned conditions are treated as their signed counterpart.
1127 switch (cc) { 1127 switch (cc) {
1128 case Uless: 1128 case lt:
1129 case less:
1130 c(OLT, D, cmp1, cmp2); 1129 c(OLT, D, cmp1, cmp2);
1131 bc1t(target); 1130 bc1t(target);
1132 break; 1131 break;
1133 case Ugreater: 1132 case gt:
1134 case greater:
1135 c(ULE, D, cmp1, cmp2); 1133 c(ULE, D, cmp1, cmp2);
1136 bc1f(target); 1134 bc1f(target);
1137 break; 1135 break;
1138 case Ugreater_equal: 1136 case ge:
1139 case greater_equal:
1140 c(ULT, D, cmp1, cmp2); 1137 c(ULT, D, cmp1, cmp2);
1141 bc1f(target); 1138 bc1f(target);
1142 break; 1139 break;
1143 case Uless_equal: 1140 case le:
1144 case less_equal:
1145 c(OLE, D, cmp1, cmp2); 1141 c(OLE, D, cmp1, cmp2);
1146 bc1t(target); 1142 bc1t(target);
1147 break; 1143 break;
1148 case eq: 1144 case eq:
1149 c(EQ, D, cmp1, cmp2); 1145 c(EQ, D, cmp1, cmp2);
1150 bc1t(target); 1146 bc1t(target);
1151 break; 1147 break;
1148 case ueq:
1149 c(UEQ, D, cmp1, cmp2);
1150 bc1t(target);
1151 break;
1152 case ne: 1152 case ne:
1153 c(EQ, D, cmp1, cmp2); 1153 c(EQ, D, cmp1, cmp2);
1154 bc1f(target); 1154 bc1f(target);
1155 break; 1155 break;
1156 case nue:
1157 c(UEQ, D, cmp1, cmp2);
1158 bc1f(target);
1159 break;
1156 default: 1160 default:
1157 CHECK(0); 1161 CHECK(0);
1158 }; 1162 };
1159 } 1163 }
1160 1164
1161 if (bd == PROTECT) { 1165 if (bd == PROTECT) {
1162 nop(); 1166 nop();
1163 } 1167 }
1164 } 1168 }
1165 1169
(...skipping 4365 matching lines...) Expand 10 before | Expand all | Expand 10 after
5531 opcode == BGTZL); 5535 opcode == BGTZL);
5532 opcode = (cond == eq) ? BEQ : BNE; 5536 opcode = (cond == eq) ? BEQ : BNE;
5533 instr = (instr & ~kOpcodeMask) | opcode; 5537 instr = (instr & ~kOpcodeMask) | opcode;
5534 masm_.emit(instr); 5538 masm_.emit(instr);
5535 } 5539 }
5536 5540
5537 5541
5538 } } // namespace v8::internal 5542 } } // namespace v8::internal
5539 5543
5540 #endif // V8_TARGET_ARCH_MIPS 5544 #endif // V8_TARGET_ARCH_MIPS
OLDNEW
« no previous file with comments | « src/mips/lithium-codegen-mips.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698