title: IA-32e 64-bit IDT Gate Descriptor
body: <p>There is a Segment Selector in Intel's 64-bit IDT Gate Descriptor. However, from my understanding across the 5 part Intel manuals, the Linear Address of the Interrupt Handler is loaded into RIP from the 64-bit offset specified in the IDT Gate Descriptor.</p>
  
  <p>The only use of the segment selector is to check:</p>
  
  <ol>
  <li>if there is a change in privilege levels</li>
  <li>the Interrupt Handler is truly pointing to a code segment</li>
  </ol>
  
  <p>My questions then is:</p>
  
  <ol>
  <li>Is RIP taken from the 64-bit offset only? Or is RIP = offset(sign extended to 64-bits) + segment selector base?</li>
  <li>Is the base address pointed to by the segment selector in the IDT Gate Descriptor ignored? Or does it have a use?</li>
  </ol>
  
  <p>Many thanks in advance!</p>