comparison src/cpu/sparc/vm/vm_version_sparc.cpp @ 647:bd441136a5ce

Merge
author kvn
date Thu, 19 Mar 2009 09:13:24 -0700
parents c771b7f43bbf
children f6da6f0174ac
comparison
equal deleted inserted replaced
640:ba50942c8138 647:bd441136a5ce
1 /* 1 /*
2 * Copyright 1997-2008 Sun Microsystems, Inc. All Rights Reserved. 2 * Copyright 1997-2009 Sun Microsystems, Inc. All Rights Reserved.
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 * 4 *
5 * This code is free software; you can redistribute it and/or modify it 5 * This code is free software; you can redistribute it and/or modify it
6 * under the terms of the GNU General Public License version 2 only, as 6 * under the terms of the GNU General Public License version 2 only, as
7 * published by the Free Software Foundation. 7 * published by the Free Software Foundation.
70 if (!is_niagara1_plus()) { 70 if (!is_niagara1_plus()) {
71 if (FLAG_IS_DEFAULT(UseCompressedOops)) { 71 if (FLAG_IS_DEFAULT(UseCompressedOops)) {
72 FLAG_SET_ERGO(bool, UseCompressedOops, false); 72 FLAG_SET_ERGO(bool, UseCompressedOops, false);
73 } 73 }
74 } 74 }
75 // 32-bit oops don't make sense for the 64-bit VM on sparc
76 // since the 32-bit VM has the same registers and smaller objects.
77 Universe::set_narrow_oop_shift(LogMinObjAlignmentInBytes);
75 #endif // _LP64 78 #endif // _LP64
76 #ifdef COMPILER2 79 #ifdef COMPILER2
77 // Indirect branch is the same cost as direct 80 // Indirect branch is the same cost as direct
78 if (FLAG_IS_DEFAULT(UseJumpTables)) { 81 if (FLAG_IS_DEFAULT(UseJumpTables)) {
79 UseJumpTables = true; 82 UseJumpTables = true;
87 OptoLoopAlignment = 4; 90 OptoLoopAlignment = 4;
88 } 91 }
89 #endif 92 #endif
90 } 93 }
91 94
95 // Use hardware population count instruction if available.
96 if (has_hardware_popc()) {
97 if (FLAG_IS_DEFAULT(UsePopCountInstruction)) {
98 UsePopCountInstruction = true;
99 }
100 }
101
92 char buf[512]; 102 char buf[512];
93 jio_snprintf(buf, sizeof(buf), "%s%s%s%s%s%s%s%s%s", 103 jio_snprintf(buf, sizeof(buf), "%s%s%s%s%s%s%s%s%s%s%s%s",
94 (has_v8() ? ", has_v8" : ""), 104 (has_v8() ? ", has_v8" : ""),
95 (has_v9() ? ", has_v9" : ""), 105 (has_v9() ? ", has_v9" : ""),
106 (has_hardware_popc() ? ", popc" : ""),
96 (has_vis1() ? ", has_vis1" : ""), 107 (has_vis1() ? ", has_vis1" : ""),
97 (has_vis2() ? ", has_vis2" : ""), 108 (has_vis2() ? ", has_vis2" : ""),
98 (is_ultra3() ? ", is_ultra3" : ""), 109 (is_ultra3() ? ", is_ultra3" : ""),
99 (is_sun4v() ? ", is_sun4v" : ""), 110 (is_sun4v() ? ", is_sun4v" : ""),
100 (is_niagara1() ? ", is_niagara1" : ""), 111 (is_niagara1() ? ", is_niagara1" : ""),
101 (!has_hardware_int_muldiv() ? ", no-muldiv" : ""), 112 (is_niagara1_plus() ? ", is_niagara1_plus" : ""),
113 (!has_hardware_mul32() ? ", no-mul32" : ""),
114 (!has_hardware_div32() ? ", no-div32" : ""),
102 (!has_hardware_fsmuld() ? ", no-fsmuld" : "")); 115 (!has_hardware_fsmuld() ? ", no-fsmuld" : ""));
103 116
104 // buf is started with ", " or is empty 117 // buf is started with ", " or is empty
105 _features_str = strdup(strlen(buf) > 2 ? buf + 2 : buf); 118 _features_str = strdup(strlen(buf) > 2 ? buf + 2 : buf);
106 119