Page 1 of 1

GDT and IDT memory locations

Posted: Sat Dec 25, 2004 5:51 am
by ManOfSteel
Hello,
I would like to know, in your opinion, where is the best locations (pro and cons) for the GDT and the IDT: at a fixed memory location (for example, bases = 0x500 and 0xD00) or along with the kernel code (bases = GDT and IDT first entries).
I ask this because I've tried them both and while both of them worked fine on any real computer, the fixed location technique caused me a lot of troubles on Bochs, like tripple faulting for no clear reason when loading the kernel at 1mb and using any interrupt or adding entries to the GDT (new segments and call-gates).
Thanks in advance.

Re:GDT and IDT memory locations

Posted: Fri Dec 31, 2004 4:27 pm
by ManOfSteel
Is my question so silly that noone here wants to answer it or is it me who didn't ask it in the right way?

Re:GDT and IDT memory locations

Posted: Fri Dec 31, 2004 7:13 pm
by Mr. L
well, it is new years eve/day so I guess everyone is out partying. ;D

Re:GDT and IDT memory locations

Posted: Sat Jan 01, 2005 3:18 am
by Neo
I dont see anything wrong with either approach.
But using the fixed address method may prove a hindrance sometime later on if you accidentally overwrite etc. or use it in some other way (Hmm... actually this makes me think it might be better if it was fixed as it would be easier to debug).
Ah Well... I guess it your choice after all.