RE: Re: Intel vs AMD x86-64

From: Nakajima, Jun
Date: Wed Feb 25 2004 - 15:13:29 EST


For near branches (CALL, RET, JCC, JCXZ, JMP, etc.), the operand size is
forced to 64 bits on both processors in 64-bit mode, basically meaning
RIP is updated.

Compilers would typically use a JMP short for "intraprocedural jumps",
which requires just an 8-bit displacement relative to RIP.

Jun
>-----Original Message-----
>From: linux-kernel-owner@xxxxxxxxxxxxxxx [mailto:linux-kernel-
>owner@xxxxxxxxxxxxxxx] On Behalf Of H. Peter Anvin
>Sent: Wednesday, February 25, 2004 8:17 AM
>To: linux-kernel@xxxxxxxxxxxxxxx
>Subject: Re: Intel vs AMD x86-64
>
>Followup to: <403CCBE0.7050100@xxxxxxxxxxxxxx>
>By author: Timothy Miller <miller@xxxxxxxxxxxxxx>
>In newsgroup: linux.dev.kernel
>>
>>
>> Nakajima, Jun wrote:
>> > No, it's not a problem. Branches with 16-bit operand size are not
>useful
>> > for compilers.
>>
>> From AMD's documentation, I got the impression that 66H caused near
>> branches to be 32 bits in long mode (default is 64).
>>
>> So, Intel makes it 16 bits, and AMD makes it 32 bits?
>>
>> Either way, I don't see much use for either one.
>>
>
>Both claims are pretty bogus. Shorter branches are quite nice for
>intraprocedural jumps; it reduces the cache footprint.
>
> -hpa
>
>-
>To unsubscribe from this list: send the line "unsubscribe linux-kernel"
in
>the body of a message to majordomo@xxxxxxxxxxxxxxx
>More majordomo info at http://vger.kernel.org/majordomo-info.html
>Please read the FAQ at http://www.tux.org/lkml/
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/