1.1 --- a/src/cpu/ppc/vm/vm_version_ppc.hpp Thu Sep 05 18:40:52 2019 +0800 1.2 +++ b/src/cpu/ppc/vm/vm_version_ppc.hpp Thu Sep 05 18:52:27 2019 +0800 1.3 @@ -1,6 +1,6 @@ 1.4 /* 1.5 - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. 1.6 - * Copyright 2012, 2014 SAP AG. All rights reserved. 1.7 + * Copyright (c) 1997, 2018, Oracle and/or its affiliates. All rights reserved. 1.8 + * Copyright 2012, 2018 SAP AG. All rights reserved. 1.9 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 1.10 * 1.11 * This code is free software; you can redistribute it and/or modify it 1.12 @@ -42,8 +42,11 @@ 1.13 fcfids, 1.14 vand, 1.15 dcba, 1.16 + lqarx, 1.17 vcipher, 1.18 vpmsumb, 1.19 + mfdscr, 1.20 + vsx, 1.21 num_features // last entry to count features 1.22 }; 1.23 enum Feature_Flag_Set { 1.24 @@ -58,8 +61,11 @@ 1.25 fcfids_m = (1 << fcfids ), 1.26 vand_m = (1 << vand ), 1.27 dcba_m = (1 << dcba ), 1.28 + lqarx_m = (1 << lqarx ), 1.29 vcipher_m = (1 << vcipher), 1.30 vpmsumb_m = (1 << vpmsumb), 1.31 + mfdscr_m = (1 << mfdscr ), 1.32 + vsx_m = (1 << vsx ), 1.33 all_features_m = -1 1.34 }; 1.35 static int _features; 1.36 @@ -69,6 +75,7 @@ 1.37 1.38 static void print_features(); 1.39 static void determine_features(); // also measures cache line size 1.40 + static void config_dscr(); // Power 8: Configure Data Stream Control Register. 1.41 static void determine_section_size(); 1.42 static void power6_micro_bench(); 1.43 public: 1.44 @@ -87,8 +94,11 @@ 1.45 static bool has_fcfids() { return (_features & fcfids_m) != 0; } 1.46 static bool has_vand() { return (_features & vand_m) != 0; } 1.47 static bool has_dcba() { return (_features & dcba_m) != 0; } 1.48 + static bool has_lqarx() { return (_features & lqarx_m) != 0; } 1.49 static bool has_vcipher() { return (_features & vcipher_m) != 0; } 1.50 static bool has_vpmsumb() { return (_features & vpmsumb_m) != 0; } 1.51 + static bool has_mfdscr() { return (_features & mfdscr_m) != 0; } 1.52 + static bool has_vsx() { return (_features & vsx_m) != 0; } 1.53 1.54 static const char* cpu_features() { return _features_str; } 1.55 1.56 @@ -97,6 +107,9 @@ 1.57 // Assembler testing 1.58 static void allow_all(); 1.59 static void revert(); 1.60 + 1.61 + // POWER 8: DSCR current value. 1.62 + static uint64_t _dscr_val; 1.63 }; 1.64 1.65 #endif // CPU_PPC_VM_VM_VERSION_PPC_HPP