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

Side by Side Diff: src/assembler.cc

Issue 39973003: Merge bleeding_edge. (Closed) Base URL: https://v8.googlecode.com/svn/branches/experimental/parser
Patch Set: again Created 7 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) 1994-2006 Sun Microsystems Inc. 1 // Copyright (c) 1994-2006 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 80 matching lines...) Expand 10 before | Expand all | Expand 10 after
91 struct DoubleConstant BASE_EMBEDDED { 91 struct DoubleConstant BASE_EMBEDDED {
92 double min_int; 92 double min_int;
93 double one_half; 93 double one_half;
94 double minus_one_half; 94 double minus_one_half;
95 double minus_zero; 95 double minus_zero;
96 double zero; 96 double zero;
97 double uint8_max_value; 97 double uint8_max_value;
98 double negative_infinity; 98 double negative_infinity;
99 double canonical_non_hole_nan; 99 double canonical_non_hole_nan;
100 double the_hole_nan; 100 double the_hole_nan;
101 double uint32_bias;
101 }; 102 };
102 103
103 static DoubleConstant double_constants; 104 static DoubleConstant double_constants;
104 105
105 const char* const RelocInfo::kFillerCommentString = "DEOPTIMIZATION PADDING"; 106 const char* const RelocInfo::kFillerCommentString = "DEOPTIMIZATION PADDING";
106 107
107 static bool math_exp_data_initialized = false; 108 static bool math_exp_data_initialized = false;
108 static Mutex* math_exp_data_mutex = NULL; 109 static Mutex* math_exp_data_mutex = NULL;
109 static double* math_exp_constants_array = NULL; 110 static double* math_exp_constants_array = NULL;
110 static double* math_exp_log_table_array = NULL; 111 static double* math_exp_log_table_array = NULL;
(...skipping 790 matching lines...) Expand 10 before | Expand all | Expand 10 after
901 void ExternalReference::SetUp() { 902 void ExternalReference::SetUp() {
902 double_constants.min_int = kMinInt; 903 double_constants.min_int = kMinInt;
903 double_constants.one_half = 0.5; 904 double_constants.one_half = 0.5;
904 double_constants.minus_one_half = -0.5; 905 double_constants.minus_one_half = -0.5;
905 double_constants.minus_zero = -0.0; 906 double_constants.minus_zero = -0.0;
906 double_constants.uint8_max_value = 255; 907 double_constants.uint8_max_value = 255;
907 double_constants.zero = 0.0; 908 double_constants.zero = 0.0;
908 double_constants.canonical_non_hole_nan = OS::nan_value(); 909 double_constants.canonical_non_hole_nan = OS::nan_value();
909 double_constants.the_hole_nan = BitCast<double>(kHoleNanInt64); 910 double_constants.the_hole_nan = BitCast<double>(kHoleNanInt64);
910 double_constants.negative_infinity = -V8_INFINITY; 911 double_constants.negative_infinity = -V8_INFINITY;
912 double_constants.uint32_bias =
913 static_cast<double>(static_cast<uint32_t>(0xFFFFFFFF)) + 1;
911 914
912 math_exp_data_mutex = new Mutex(); 915 math_exp_data_mutex = new Mutex();
913 } 916 }
914 917
915 918
916 void ExternalReference::InitializeMathExpData() { 919 void ExternalReference::InitializeMathExpData() {
917 // Early return? 920 // Early return?
918 if (math_exp_data_initialized) return; 921 if (math_exp_data_initialized) return;
919 922
920 LockGuard<Mutex> lock_guard(math_exp_data_mutex); 923 LockGuard<Mutex> lock_guard(math_exp_data_mutex);
(...skipping 157 matching lines...) Expand 10 before | Expand all | Expand 10 after
1078 } 1081 }
1079 1082
1080 1083
1081 ExternalReference ExternalReference::get_make_code_young_function( 1084 ExternalReference ExternalReference::get_make_code_young_function(
1082 Isolate* isolate) { 1085 Isolate* isolate) {
1083 return ExternalReference(Redirect( 1086 return ExternalReference(Redirect(
1084 isolate, FUNCTION_ADDR(Code::MakeCodeAgeSequenceYoung))); 1087 isolate, FUNCTION_ADDR(Code::MakeCodeAgeSequenceYoung)));
1085 } 1088 }
1086 1089
1087 1090
1091 ExternalReference ExternalReference::get_mark_code_as_executed_function(
1092 Isolate* isolate) {
1093 return ExternalReference(Redirect(
1094 isolate, FUNCTION_ADDR(Code::MarkCodeAsExecuted)));
1095 }
1096
1097
1088 ExternalReference ExternalReference::date_cache_stamp(Isolate* isolate) { 1098 ExternalReference ExternalReference::date_cache_stamp(Isolate* isolate) {
1089 return ExternalReference(isolate->date_cache()->stamp_address()); 1099 return ExternalReference(isolate->date_cache()->stamp_address());
1090 } 1100 }
1091 1101
1092 1102
1093 ExternalReference ExternalReference::stress_deopt_count(Isolate* isolate) { 1103 ExternalReference ExternalReference::stress_deopt_count(Isolate* isolate) {
1094 return ExternalReference(isolate->stress_deopt_count_address()); 1104 return ExternalReference(isolate->stress_deopt_count_address());
1095 } 1105 }
1096 1106
1097 1107
(...skipping 228 matching lines...) Expand 10 before | Expand all | Expand 10 after
1326 reinterpret_cast<void*>(&double_constants.canonical_non_hole_nan)); 1336 reinterpret_cast<void*>(&double_constants.canonical_non_hole_nan));
1327 } 1337 }
1328 1338
1329 1339
1330 ExternalReference ExternalReference::address_of_the_hole_nan() { 1340 ExternalReference ExternalReference::address_of_the_hole_nan() {
1331 return ExternalReference( 1341 return ExternalReference(
1332 reinterpret_cast<void*>(&double_constants.the_hole_nan)); 1342 reinterpret_cast<void*>(&double_constants.the_hole_nan));
1333 } 1343 }
1334 1344
1335 1345
1346 ExternalReference ExternalReference::record_object_allocation_function(
1347 Isolate* isolate) {
1348 return ExternalReference(
1349 Redirect(isolate,
1350 FUNCTION_ADDR(HeapProfiler::RecordObjectAllocationFromMasm)));
1351 }
1352
1353
1354 ExternalReference ExternalReference::address_of_uint32_bias() {
1355 return ExternalReference(
1356 reinterpret_cast<void*>(&double_constants.uint32_bias));
1357 }
1358
1359
1336 #ifndef V8_INTERPRETED_REGEXP 1360 #ifndef V8_INTERPRETED_REGEXP
1337 1361
1338 ExternalReference ExternalReference::re_check_stack_guard_state( 1362 ExternalReference ExternalReference::re_check_stack_guard_state(
1339 Isolate* isolate) { 1363 Isolate* isolate) {
1340 Address function; 1364 Address function;
1341 #if V8_TARGET_ARCH_X64 1365 #if V8_TARGET_ARCH_X64
1342 function = FUNCTION_ADDR(RegExpMacroAssemblerX64::CheckStackGuardState); 1366 function = FUNCTION_ADDR(RegExpMacroAssemblerX64::CheckStackGuardState);
1343 #elif V8_TARGET_ARCH_IA32 1367 #elif V8_TARGET_ARCH_IA32
1344 function = FUNCTION_ADDR(RegExpMacroAssemblerIA32::CheckStackGuardState); 1368 function = FUNCTION_ADDR(RegExpMacroAssemblerIA32::CheckStackGuardState);
1345 #elif V8_TARGET_ARCH_ARM 1369 #elif V8_TARGET_ARCH_ARM
(...skipping 348 matching lines...) Expand 10 before | Expand all | Expand 10 after
1694 assembler_->RecordRelocInfo(RelocInfo::POSITION, state_.current_position); 1718 assembler_->RecordRelocInfo(RelocInfo::POSITION, state_.current_position);
1695 state_.written_position = state_.current_position; 1719 state_.written_position = state_.current_position;
1696 written = true; 1720 written = true;
1697 } 1721 }
1698 1722
1699 // Return whether something was written. 1723 // Return whether something was written.
1700 return written; 1724 return written;
1701 } 1725 }
1702 1726
1703 } } // namespace v8::internal 1727 } } // 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