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

Side by Side Diff: src/assembler.cc

Issue 8404030: Version 3.7.1 (Closed) Base URL: http://v8.googlecode.com/svn/trunk/
Patch Set: Created 9 years, 1 month 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/assembler.h ('k') | src/ast.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 Sun Microsystems Inc. 1 // Copyright (c) 2011 Sun Microsystems Inc.
2 // All Rights Reserved. 2 // All Rights Reserved.
3 // 3 //
4 // Redistribution and use in source and binary forms, with or without 4 // Redistribution and use in source and binary forms, with or without
5 // modification, are permitted provided that the following conditions are 5 // modification, are permitted provided that the following conditions are
6 // met: 6 // met:
7 // 7 //
8 // - Redistributions of source code must retain the above copyright notice, 8 // - Redistributions of source code must retain the above copyright notice,
9 // this list of conditions and the following disclaimer. 9 // this list of conditions and the following disclaimer.
10 // 10 //
(...skipping 816 matching lines...) Expand 10 before | Expand all | Expand 10 after
827 } 827 }
828 828
829 829
830 ExternalReference ExternalReference::keyed_lookup_cache_field_offsets( 830 ExternalReference ExternalReference::keyed_lookup_cache_field_offsets(
831 Isolate* isolate) { 831 Isolate* isolate) {
832 return ExternalReference( 832 return ExternalReference(
833 isolate->keyed_lookup_cache()->field_offsets_address()); 833 isolate->keyed_lookup_cache()->field_offsets_address());
834 } 834 }
835 835
836 836
837 ExternalReference ExternalReference::roots_address(Isolate* isolate) { 837 ExternalReference ExternalReference::roots_array_start(Isolate* isolate) {
838 return ExternalReference(isolate->heap()->roots_address()); 838 return ExternalReference(isolate->heap()->roots_array_start());
839 } 839 }
840 840
841 841
842 ExternalReference ExternalReference::address_of_stack_limit(Isolate* isolate) { 842 ExternalReference ExternalReference::address_of_stack_limit(Isolate* isolate) {
843 return ExternalReference(isolate->stack_guard()->address_of_jslimit()); 843 return ExternalReference(isolate->stack_guard()->address_of_jslimit());
844 } 844 }
845 845
846 846
847 ExternalReference ExternalReference::address_of_real_stack_limit( 847 ExternalReference ExternalReference::address_of_real_stack_limit(
848 Isolate* isolate) { 848 Isolate* isolate) {
(...skipping 281 matching lines...) Expand 10 before | Expand all | Expand 10 after
1130 BUILTIN_FP_INT_CALL)); 1130 BUILTIN_FP_INT_CALL));
1131 } 1131 }
1132 1132
1133 1133
1134 static int native_compare_doubles(double y, double x) { 1134 static int native_compare_doubles(double y, double x) {
1135 if (x == y) return EQUAL; 1135 if (x == y) return EQUAL;
1136 return x < y ? LESS : GREATER; 1136 return x < y ? LESS : GREATER;
1137 } 1137 }
1138 1138
1139 1139
1140 bool EvalComparison(Token::Value op, double op1, double op2) {
1141 ASSERT(Token::IsCompareOp(op));
1142 switch (op) {
1143 case Token::EQ:
1144 case Token::EQ_STRICT: return (op1 == op2);
1145 case Token::NE: return (op1 != op2);
1146 case Token::LT: return (op1 < op2);
1147 case Token::GT: return (op1 > op2);
1148 case Token::LTE: return (op1 <= op2);
1149 case Token::GTE: return (op1 >= op2);
1150 default:
1151 UNREACHABLE();
1152 return false;
1153 }
1154 }
1155
1156
1140 ExternalReference ExternalReference::double_fp_operation( 1157 ExternalReference ExternalReference::double_fp_operation(
1141 Token::Value operation, Isolate* isolate) { 1158 Token::Value operation, Isolate* isolate) {
1142 typedef double BinaryFPOperation(double x, double y); 1159 typedef double BinaryFPOperation(double x, double y);
1143 BinaryFPOperation* function = NULL; 1160 BinaryFPOperation* function = NULL;
1144 switch (operation) { 1161 switch (operation) {
1145 case Token::ADD: 1162 case Token::ADD:
1146 function = &add_two_doubles; 1163 function = &add_two_doubles;
1147 break; 1164 break;
1148 case Token::SUB: 1165 case Token::SUB:
1149 function = &sub_two_doubles; 1166 function = &sub_two_doubles;
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
1231 assembler_->RecordRelocInfo(RelocInfo::POSITION, state_.current_position); 1248 assembler_->RecordRelocInfo(RelocInfo::POSITION, state_.current_position);
1232 state_.written_position = state_.current_position; 1249 state_.written_position = state_.current_position;
1233 written = true; 1250 written = true;
1234 } 1251 }
1235 1252
1236 // Return whether something was written. 1253 // Return whether something was written.
1237 return written; 1254 return written;
1238 } 1255 }
1239 1256
1240 } } // namespace v8::internal 1257 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/assembler.h ('k') | src/ast.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698