Resend: Missing hotspot changes after Initial updates for ios x86_64 causes GCC error in linux build

Ali Ebrahimi ali.ebrahimi1781 at gmail.com
Sat Apr 9 10:13:37 UTC 2016


Hi,
These casts added by changest "8042893: compiler:
PRAGMA_FORMAT_MUTE_WARNINGS_FOR_GCC needs to be removed from source files"
and still remains in all other openjdk repos that I have locally: jake,
jdk9-dev, valhalla, panama,...

I have testing all of this in win, linux and macosx.
gcc is 5.2.1
VS 2013
Xcode 7.2

2016-04-09 14:05 GMT+04:30 gary.adams at oracle.com <gary.adams at oracle.com>:

> Those casts were removed back in Dec when we sync'ed with the mainstream
> jdk9/dev repos.
> Which version of the compiler are you using that still complains?
>
>
> On 4/9/16 4:40 AM, Ali Ebrahimi wrote:
>
>> After first mobile-related push some changes missed specifically in file
>> hotspot/src/os_cpu/linux_x86/vm/os_linux_x86.cpp.
>>
>> I restored these changes in following patch, with this patch GCC error
>> disappears.
>>
>> diff -r 9ec65e87a0ec src/os_cpu/linux_x86/vm/os_linux_x86.cpp
>> --- a/src/os_cpu/linux_x86/vm/os_linux_x86.cpp Fri Apr 01 10:22:38 2016
>> -0400
>> +++ b/src/os_cpu/linux_x86/vm/os_linux_x86.cpp Sat Apr 02 22:34:02 2016
>> +0430
>> @@ -824,32 +824,32 @@
>>     const ucontext_t *uc = (const ucontext_t*)context;
>>     st->print_cr("Registers:");
>>   #ifdef AMD64
>> -  st->print(  "RAX=" INTPTR_FORMAT, uc->uc_mcontext.CTX_REG_AX);
>> -  st->print(", RBX=" INTPTR_FORMAT, uc->uc_mcontext.CTX_REG_BX);
>> -  st->print(", RCX=" INTPTR_FORMAT, uc->uc_mcontext.CTX_REG_CX);
>> -  st->print(", RDX=" INTPTR_FORMAT, uc->uc_mcontext.CTX_REG_DX);
>> +  st->print(  "RAX=" INTPTR_FORMAT,
>> (intptr_t)uc->uc_mcontext.CTX_REG_AX);
>> +  st->print(", RBX=" INTPTR_FORMAT,
>> (intptr_t)uc->uc_mcontext.CTX_REG_BX);
>> +  st->print(", RCX=" INTPTR_FORMAT,
>> (intptr_t)uc->uc_mcontext.CTX_REG_CX);
>> +  st->print(", RDX=" INTPTR_FORMAT,
>> (intptr_t)uc->uc_mcontext.CTX_REG_DX);
>>     st->cr();
>> -  st->print(  "RSP=" INTPTR_FORMAT, uc->uc_mcontext.CTX_REG_SP);
>> -  st->print(", RBP=" INTPTR_FORMAT, uc->uc_mcontext.CTX_REG_BP);
>> -  st->print(", RSI=" INTPTR_FORMAT, uc->uc_mcontext.CTX_REG_SI);
>> -  st->print(", RDI=" INTPTR_FORMAT, uc->uc_mcontext.CTX_REG_DI);
>> +  st->print(  "RSP=" INTPTR_FORMAT,
>> (intptr_t)uc->uc_mcontext.CTX_REG_SP);
>> +  st->print(", RBP=" INTPTR_FORMAT,
>> (intptr_t)uc->uc_mcontext.CTX_REG_BP);
>> +  st->print(", RSI=" INTPTR_FORMAT,
>> (intptr_t)uc->uc_mcontext.CTX_REG_SI);
>> +  st->print(", RDI=" INTPTR_FORMAT,
>> (intptr_t)uc->uc_mcontext.CTX_REG_DI);
>>     st->cr();
>> -  st->print(  "R8 =" INTPTR_FORMAT, uc->uc_mcontext.CTX_REG_R8);
>> -  st->print(", R9 =" INTPTR_FORMAT, uc->uc_mcontext.CTX_REG_R9);
>> -  st->print(", R10=" INTPTR_FORMAT, uc->uc_mcontext.CTX_REG_R10);
>> -  st->print(", R11=" INTPTR_FORMAT, uc->uc_mcontext.CTX_REG_R11);
>> +  st->print(  "R8 =" INTPTR_FORMAT,
>> (intptr_t)uc->uc_mcontext.CTX_REG_R8);
>> +  st->print(", R9 =" INTPTR_FORMAT,
>> (intptr_t)uc->uc_mcontext.CTX_REG_R9);
>> +  st->print(", R10=" INTPTR_FORMAT,
>> (intptr_t)uc->uc_mcontext.CTX_REG_R10);
>> +  st->print(", R11=" INTPTR_FORMAT,
>> (intptr_t)uc->uc_mcontext.CTX_REG_R11);
>>     st->cr();
>> -  st->print(  "R12=" INTPTR_FORMAT, uc->uc_mcontext.CTX_REG_R12);
>> -  st->print(", R13=" INTPTR_FORMAT, uc->uc_mcontext.CTX_REG_R13);
>> -  st->print(", R14=" INTPTR_FORMAT, uc->uc_mcontext.CTX_REG_R14);
>> -  st->print(", R15=" INTPTR_FORMAT, uc->uc_mcontext.CTX_REG_R15);
>> +  st->print(  "R12=" INTPTR_FORMAT,
>> (intptr_t)uc->uc_mcontext.CTX_REG_R12);
>> +  st->print(", R13=" INTPTR_FORMAT,
>> (intptr_t)uc->uc_mcontext.CTX_REG_R13);
>> +  st->print(", R14=" INTPTR_FORMAT,
>> (intptr_t)uc->uc_mcontext.CTX_REG_R14);
>> +  st->print(", R15=" INTPTR_FORMAT,
>> (intptr_t)uc->uc_mcontext.CTX_REG_R15);
>>     st->cr();
>> -  st->print(  "RIP=" INTPTR_FORMAT, uc->uc_mcontext.CTX_REG_PC);
>> -  st->print(", EFLAGS=" INTPTR_FORMAT, uc->uc_mcontext.CTX_REG_FL);
>> -  st->print(", CSGSFS=" INTPTR_FORMAT, uc->uc_mcontext.CTX_REG_CSGSFS);
>> -  st->print(", ERR=" INTPTR_FORMAT, uc->uc_mcontext.CTX_REG_ERR);
>> +  st->print(  "RIP=" INTPTR_FORMAT,
>> (intptr_t)uc->uc_mcontext.CTX_REG_PC);
>> +  st->print(", EFLAGS=" INTPTR_FORMAT,
>> (intptr_t)uc->uc_mcontext.CTX_REG_FL);
>> +  st->print(", CSGSFS=" INTPTR_FORMAT,
>> (intptr_t)uc->uc_mcontext.CTX_REG_CSGSFS);
>> +  st->print(", ERR=" INTPTR_FORMAT,
>> (intptr_t)uc->uc_mcontext.CTX_REG_ERR);
>>     st->cr();
>> -  st->print("  TRAPNO=" INTPTR_FORMAT, uc->uc_mcontext.CTX_REG_TRAPNO);
>> +  st->print("  TRAPNO=" INTPTR_FORMAT,
>> (intptr_t)uc->uc_mcontext.CTX_REG_TRAPNO);
>>   #else
>>     st->print(  "EAX=" INTPTR_FORMAT, (int) uc->uc_mcontext.CTX_REG_AX);
>>     st->print(", EBX=" INTPTR_FORMAT, (int) uc->uc_mcontext.CTX_REG_BX);
>>
>>
>>
>


-- 

Best Regards,
Ali Ebrahimi


More information about the mobile-dev mailing list