8181503: Can't compile hotspot with c++11

Fixed 5 unique c++14 compiler issues

Reviewed-by: coleenp, dholmes, kbarrett
This commit is contained in:
Gerard Ziemski 2018-01-31 11:12:12 -06:00
parent 7660d97e2e
commit 2cb1917bac
7 changed files with 8 additions and 23 deletions

@ -279,11 +279,11 @@
address os::current_stack_pointer() {
#if defined(__clang__) || defined(__llvm__)
register void *esp;
__asm__("mov %%"SPELL_REG_SP", %0":"=r"(esp));
__asm__("mov %%" SPELL_REG_SP ", %0":"=r"(esp));
return (address) esp;
#elif defined(SPARC_WORKS)
register void *esp;
__asm__("mov %%"SPELL_REG_SP", %0":"=r"(esp));
__asm__("mov %%" SPELL_REG_SP ", %0":"=r"(esp));
return (address) ((char*)esp + sizeof(long)*2);
#else
register void *esp __asm__ (SPELL_REG_SP);
@ -415,7 +415,7 @@ frame os::get_sender_for_C_frame(frame* fr) {
intptr_t* _get_previous_fp() {
#if defined(SPARC_WORKS) || defined(__clang__) || defined(__llvm__)
register intptr_t **ebp;
__asm__("mov %%"SPELL_REG_FP", %0":"=r"(ebp));
__asm__("mov %%" SPELL_REG_FP ", %0":"=r"(ebp));
#else
register intptr_t **ebp __asm__ (SPELL_REG_FP);
#endif

@ -224,7 +224,7 @@ bool CompiledIC::set_to_megamorphic(CallInfo* call_info, Bytecodes::Code bytecod
assert(bytecode == Bytecodes::_invokeinterface, "");
int itable_index = call_info->itable_index();
entry = VtableStubs::find_itable_stub(itable_index);
if (entry == false) {
if (entry == NULL) {
return false;
}
#ifdef ASSERT

@ -296,7 +296,7 @@ void LogConfiguration::disable_logging() {
notify_update_listeners();
}
void LogConfiguration::configure_stdout(LogLevelType level, bool exact_match, ...) {
void LogConfiguration::configure_stdout(LogLevelType level, int exact_match, ...) {
size_t i;
va_list ap;
LogTagLevelExpression expr;

@ -102,7 +102,7 @@ class LogConfiguration : public AllStatic {
// (exact_match=false is the same as "-Xlog:<tags>*=<level>", and exact_match=true is "-Xlog:<tags>=<level>").
// Tags should be specified using the LOG_TAGS macro, e.g.
// LogConfiguration::configure_stdout(LogLevel::<level>, <true/false>, LOG_TAGS(<tags>));
static void configure_stdout(LogLevelType level, bool exact_match, ...);
static void configure_stdout(LogLevelType level, int exact_match, ...);
// Parse command line configuration. Parameter 'opts' is the string immediately following the -Xlog: argument ("gc" for -Xlog:gc).
static bool parse_command_line_arguments(const char* opts = "all");

@ -40,7 +40,7 @@ class LogTagLevelExpression : public StackObj {
static const size_t MaxCombinations = 256;
private:
friend void LogConfiguration::configure_stdout(LogLevelType, bool, ...);
friend void LogConfiguration::configure_stdout(LogLevelType, int, ...);
static const char* DefaultExpressionString;

@ -172,18 +172,3 @@ namespace AccessInternal {
Copy::conjoint_jlongs_atomic(src, dst, length);
}
}
template void AccessInternal::arraycopy_conjoint<jbyte>(jbyte* src, jbyte* dst, size_t length);
template void AccessInternal::arraycopy_conjoint<jshort>(jshort* src, jshort* dst, size_t length);
template void AccessInternal::arraycopy_conjoint<jint>(jint* src, jint* dst, size_t length);
template void AccessInternal::arraycopy_conjoint<jlong>(jlong* src, jlong* dst, size_t length);
template void AccessInternal::arraycopy_arrayof_conjoint<jbyte>(jbyte* src, jbyte* dst, size_t length);
template void AccessInternal::arraycopy_arrayof_conjoint<jshort>(jshort* src, jshort* dst, size_t length);
template void AccessInternal::arraycopy_arrayof_conjoint<jint>(jint* src, jint* dst, size_t length);
template void AccessInternal::arraycopy_arrayof_conjoint<jlong>(jlong* src, jlong* dst, size_t length);
template void AccessInternal::arraycopy_conjoint_atomic<jbyte>(jbyte* src, jbyte* dst, size_t length);
template void AccessInternal::arraycopy_conjoint_atomic<jshort>(jshort* src, jshort* dst, size_t length);
template void AccessInternal::arraycopy_conjoint_atomic<jint>(jint* src, jint* dst, size_t length);
template void AccessInternal::arraycopy_conjoint_atomic<jlong>(jlong* src, jlong* dst, size_t length);

@ -480,7 +480,7 @@ void VMError::report(outputStream* st, bool _verbose) {
STEP("printing type of error")
switch(_id) {
switch(static_cast<unsigned int>(_id)) {
case OOM_MALLOC_ERROR:
case OOM_MMAP_ERROR:
if (_size) {