question about ia-32e compatibility mode
Posted: Mon Dec 26, 2011 1:36 am
In x86-64, there are 2 sub-modes for ia-32e mode:
1> the compatibility mode
2> the 64-bit mode
My questions are:
1> why should we use a compatibility mode? Can't we just use ia32 protected mode if we wanna run 32-bit apps?
2> when transferring from 64-bit mode back to real mode, we must first enter the compatibility mode, why?
3> the intel manual says that in 64-bit mode, segmentation is generally disabled(for cs, ds, ss, gs), but in the structure of segment descriptor, there's a bit - bit21, and in 3.4.5 of Software Developer’s Manual 3A, description of this bit is: "In IA-32e mode, bit 21 of the second doubleword of the segment descriptor indicates whether a code segment contains native 64-bit code. A value of 1 indicates instructions in this code segment are executed in 64-bit mode. A value of 0 indicates the instructions in this code segment are executed in compatibility mode." So, if we do not use segment in 64-bit mode, why we need a segment descriptor like this?
Well, I'm muddled, and hope someone may help.
Thanks a lot!
1> the compatibility mode
2> the 64-bit mode
My questions are:
1> why should we use a compatibility mode? Can't we just use ia32 protected mode if we wanna run 32-bit apps?
2> when transferring from 64-bit mode back to real mode, we must first enter the compatibility mode, why?
3> the intel manual says that in 64-bit mode, segmentation is generally disabled(for cs, ds, ss, gs), but in the structure of segment descriptor, there's a bit - bit21, and in 3.4.5 of Software Developer’s Manual 3A, description of this bit is: "In IA-32e mode, bit 21 of the second doubleword of the segment descriptor indicates whether a code segment contains native 64-bit code. A value of 1 indicates instructions in this code segment are executed in 64-bit mode. A value of 0 indicates the instructions in this code segment are executed in compatibility mode." So, if we do not use segment in 64-bit mode, why we need a segment descriptor like this?
Well, I'm muddled, and hope someone may help.
Thanks a lot!