366 if (!FLAG_IS_DEFAULT(UseUnalignedAccesses)) |
367 if (!FLAG_IS_DEFAULT(UseUnalignedAccesses)) |
367 warning("Unaligned memory access is not available on this CPU"); |
368 warning("Unaligned memory access is not available on this CPU"); |
368 FLAG_SET_DEFAULT(UseUnalignedAccesses, false); |
369 FLAG_SET_DEFAULT(UseUnalignedAccesses, false); |
369 } |
370 } |
370 |
371 |
371 if (PrintMiscellaneous && Verbose) { |
372 if (log_is_enabled(Info, os, cpu)) { |
372 tty->print_cr("L1 data cache line size: %u", L1_data_cache_line_size()); |
373 ResourceMark rm; |
373 tty->print_cr("L2 data cache line size: %u", L2_data_cache_line_size()); |
374 outputStream* log = Log(os, cpu)::info_stream(); |
374 tty->print("Allocation"); |
375 log->print_cr("L1 data cache line size: %u", L1_data_cache_line_size()); |
|
376 log->print_cr("L2 data cache line size: %u", L2_data_cache_line_size()); |
|
377 log->print("Allocation"); |
375 if (AllocatePrefetchStyle <= 0) { |
378 if (AllocatePrefetchStyle <= 0) { |
376 tty->print_cr(": no prefetching"); |
379 log->print(": no prefetching"); |
377 } else { |
380 } else { |
378 tty->print(" prefetching: "); |
381 log->print(" prefetching: "); |
379 if (AllocatePrefetchInstr == 0) { |
382 if (AllocatePrefetchInstr == 0) { |
380 tty->print("PREFETCH"); |
383 log->print("PREFETCH"); |
381 } else if (AllocatePrefetchInstr == 1) { |
384 } else if (AllocatePrefetchInstr == 1) { |
382 tty->print("BIS"); |
385 log->print("BIS"); |
383 } |
386 } |
384 if (AllocatePrefetchLines > 1) { |
387 if (AllocatePrefetchLines > 1) { |
385 tty->print_cr(" at distance %d, %d lines of %d bytes", (int) AllocatePrefetchDistance, (int) AllocatePrefetchLines, (int) AllocatePrefetchStepSize); |
388 log->print_cr(" at distance %d, %d lines of %d bytes", (int) AllocatePrefetchDistance, (int) AllocatePrefetchLines, (int) AllocatePrefetchStepSize); |
386 } else { |
389 } else { |
387 tty->print_cr(" at distance %d, one line of %d bytes", (int) AllocatePrefetchDistance, (int) AllocatePrefetchStepSize); |
390 log->print_cr(" at distance %d, one line of %d bytes", (int) AllocatePrefetchDistance, (int) AllocatePrefetchStepSize); |
388 } |
391 } |
389 } |
392 } |
390 if (PrefetchCopyIntervalInBytes > 0) { |
393 if (PrefetchCopyIntervalInBytes > 0) { |
391 tty->print_cr("PrefetchCopyIntervalInBytes %d", (int) PrefetchCopyIntervalInBytes); |
394 log->print_cr("PrefetchCopyIntervalInBytes %d", (int) PrefetchCopyIntervalInBytes); |
392 } |
395 } |
393 if (PrefetchScanIntervalInBytes > 0) { |
396 if (PrefetchScanIntervalInBytes > 0) { |
394 tty->print_cr("PrefetchScanIntervalInBytes %d", (int) PrefetchScanIntervalInBytes); |
397 log->print_cr("PrefetchScanIntervalInBytes %d", (int) PrefetchScanIntervalInBytes); |
395 } |
398 } |
396 if (PrefetchFieldsAhead > 0) { |
399 if (PrefetchFieldsAhead > 0) { |
397 tty->print_cr("PrefetchFieldsAhead %d", (int) PrefetchFieldsAhead); |
400 log->print_cr("PrefetchFieldsAhead %d", (int) PrefetchFieldsAhead); |
398 } |
401 } |
399 if (ContendedPaddingWidth > 0) { |
402 if (ContendedPaddingWidth > 0) { |
400 tty->print_cr("ContendedPaddingWidth %d", (int) ContendedPaddingWidth); |
403 log->print_cr("ContendedPaddingWidth %d", (int) ContendedPaddingWidth); |
401 } |
404 } |
402 } |
405 } |
403 } |
406 } |
404 |
407 |
405 void VM_Version::print_features() { |
408 void VM_Version::print_features() { |
406 tty->print_cr("Version:%s", _features); |
409 tty->print_cr("Version:%s", _features); |
407 } |
410 } |
408 |
411 |
409 int VM_Version::determine_features() { |
412 int VM_Version::determine_features() { |
410 if (UseV8InstrsOnly) { |
413 if (UseV8InstrsOnly) { |
411 if (PrintMiscellaneous && Verbose) { tty->print_cr("Version is Forced-V8"); } |
414 log_info(os, cpu)("Version is Forced-V8"); |
412 return generic_v8_m; |
415 return generic_v8_m; |
413 } |
416 } |
414 |
417 |
415 int features = platform_features(unknown_m); // platform_features() is os_arch specific |
418 int features = platform_features(unknown_m); // platform_features() is os_arch specific |
416 |
419 |
417 if (features == unknown_m) { |
420 if (features == unknown_m) { |
418 features = generic_v9_m; |
421 features = generic_v9_m; |
419 warning("Cannot recognize SPARC version. Default to V9"); |
422 log_info(os)("Cannot recognize SPARC version. Default to V9"); |
420 } |
423 } |
421 |
424 |
422 assert(is_T_family(features) == is_niagara(features), "Niagara should be T series"); |
425 assert(is_T_family(features) == is_niagara(features), "Niagara should be T series"); |
423 if (UseNiagaraInstrs) { // Force code generation for Niagara |
426 if (UseNiagaraInstrs) { // Force code generation for Niagara |
424 if (is_T_family(features)) { |
427 if (is_T_family(features)) { |
425 // Happy to accomodate... |
428 // Happy to accomodate... |
426 } else { |
429 } else { |
427 if (PrintMiscellaneous && Verbose) { tty->print_cr("Version is Forced-Niagara"); } |
430 log_info(os, cpu)("Version is Forced-Niagara"); |
428 features |= T_family_m; |
431 features |= T_family_m; |
429 } |
432 } |
430 } else { |
433 } else { |
431 if (is_T_family(features) && !FLAG_IS_DEFAULT(UseNiagaraInstrs)) { |
434 if (is_T_family(features) && !FLAG_IS_DEFAULT(UseNiagaraInstrs)) { |
432 if (PrintMiscellaneous && Verbose) { tty->print_cr("Version is Forced-Not-Niagara"); } |
435 log_info(os, cpu)("Version is Forced-Not-Niagara"); |
433 features &= ~(T_family_m | T1_model_m); |
436 features &= ~(T_family_m | T1_model_m); |
434 } else { |
437 } else { |
435 // Happy to accomodate... |
438 // Happy to accomodate... |
436 } |
439 } |
437 } |
440 } |