1146 } else if (UseFastStosb) { 1147 warning("fast-string operations are not available on this CPU"); 1148 FLAG_SET_DEFAULT(UseFastStosb, false); 1149 } 1150 1151 #ifdef COMPILER2 1152 if (FLAG_IS_DEFAULT(AlignVector)) { 1153 // Modern processors allow misaligned memory operations for vectors. 1154 AlignVector = !UseUnalignedLoadStores; 1155 } 1156 #endif // COMPILER2 1157 1158 if( AllocatePrefetchInstr == 3 && !supports_3dnow_prefetch() ) AllocatePrefetchInstr=0; 1159 if( !supports_sse() && supports_3dnow_prefetch() ) AllocatePrefetchInstr = 3; 1160 1161 // Allocation prefetch settings 1162 intx cache_line_size = prefetch_data_size(); 1163 if( cache_line_size > AllocatePrefetchStepSize ) 1164 AllocatePrefetchStepSize = cache_line_size; 1165 1166 assert(AllocatePrefetchLines > 0, "invalid value"); 1167 if( AllocatePrefetchLines < 1 ) // set valid value in product VM 1168 AllocatePrefetchLines = 3; 1169 assert(AllocateInstancePrefetchLines > 0, "invalid value"); 1170 if( AllocateInstancePrefetchLines < 1 ) // set valid value in product VM 1171 AllocateInstancePrefetchLines = 1; 1172 1173 AllocatePrefetchDistance = allocate_prefetch_distance(); 1174 AllocatePrefetchStyle = allocate_prefetch_style(); 1175 1176 if (is_intel() && cpu_family() == 6 && supports_sse3()) { 1177 if (AllocatePrefetchStyle == 2) { // watermark prefetching on Core 1178 #ifdef _LP64 1179 AllocatePrefetchDistance = 384; 1180 #else 1181 AllocatePrefetchDistance = 320; 1182 #endif 1183 } 1184 if (supports_sse4_2() && supports_ht()) { // Nehalem based cpus 1185 AllocatePrefetchDistance = 192; 1186 AllocatePrefetchLines = 4; 1187 } 1188 #ifdef COMPILER2 1189 if (supports_sse4_2()) { 1190 if (FLAG_IS_DEFAULT(UseFPUForSpilling)) { 1191 FLAG_SET_DEFAULT(UseFPUForSpilling, true); 1192 } 1193 } 1194 #endif 1195 } 1196 1197 #ifdef _LP64 1198 // Prefetch settings 1199 PrefetchCopyIntervalInBytes = prefetch_copy_interval_in_bytes(); 1200 PrefetchScanIntervalInBytes = prefetch_scan_interval_in_bytes(); 1201 PrefetchFieldsAhead = prefetch_fields_ahead(); 1202 #endif 1203 1204 if (FLAG_IS_DEFAULT(ContendedPaddingWidth) && 1205 (cache_line_size > ContendedPaddingWidth)) 1206 ContendedPaddingWidth = cache_line_size; | 1146 } else if (UseFastStosb) { 1147 warning("fast-string operations are not available on this CPU"); 1148 FLAG_SET_DEFAULT(UseFastStosb, false); 1149 } 1150 1151 #ifdef COMPILER2 1152 if (FLAG_IS_DEFAULT(AlignVector)) { 1153 // Modern processors allow misaligned memory operations for vectors. 1154 AlignVector = !UseUnalignedLoadStores; 1155 } 1156 #endif // COMPILER2 1157 1158 if( AllocatePrefetchInstr == 3 && !supports_3dnow_prefetch() ) AllocatePrefetchInstr=0; 1159 if( !supports_sse() && supports_3dnow_prefetch() ) AllocatePrefetchInstr = 3; 1160 1161 // Allocation prefetch settings 1162 intx cache_line_size = prefetch_data_size(); 1163 if( cache_line_size > AllocatePrefetchStepSize ) 1164 AllocatePrefetchStepSize = cache_line_size; 1165 1166 AllocatePrefetchDistance = allocate_prefetch_distance(); 1167 AllocatePrefetchStyle = allocate_prefetch_style(); 1168 1169 if (is_intel() && cpu_family() == 6 && supports_sse3()) { 1170 if (AllocatePrefetchStyle == 2) { // watermark prefetching on Core 1171 #ifdef _LP64 1172 AllocatePrefetchDistance = 384; 1173 #else 1174 AllocatePrefetchDistance = 320; 1175 #endif 1176 } 1177 if (supports_sse4_2() && supports_ht()) { // Nehalem based cpus 1178 AllocatePrefetchDistance = 192; 1179 if (FLAG_IS_DEFAULT(AllocatePrefetchLines)) { 1180 FLAG_SET_DEFAULT(AllocatePrefetchLines, 4); 1181 } 1182 } 1183 #ifdef COMPILER2 1184 if (supports_sse4_2()) { 1185 if (FLAG_IS_DEFAULT(UseFPUForSpilling)) { 1186 FLAG_SET_DEFAULT(UseFPUForSpilling, true); 1187 } 1188 } 1189 #endif 1190 } 1191 1192 #ifdef _LP64 1193 // Prefetch settings 1194 PrefetchCopyIntervalInBytes = prefetch_copy_interval_in_bytes(); 1195 PrefetchScanIntervalInBytes = prefetch_scan_interval_in_bytes(); 1196 PrefetchFieldsAhead = prefetch_fields_ahead(); 1197 #endif 1198 1199 if (FLAG_IS_DEFAULT(ContendedPaddingWidth) && 1200 (cache_line_size > ContendedPaddingWidth)) 1201 ContendedPaddingWidth = cache_line_size; |