[haiku-commits] Re: BRANCH xyzzy-github.x86_64 - src/system/boot/platform/bios_ia32 src/system/kernel/arch/x86_64 headers/private/kernel/arch/x86_64 src/system/kernel/arch/x86

  • From: Axel Dörfler <axeld@xxxxxxxxxxxxxxxx>
  • To: haiku-commits@xxxxxxxxxxxxx
  • Date: Thu, 28 Jun 2012 16:21:28 +0200

On 27.06.2012 21:02, Ingo Weinhold wrote:
Axel Dörfler wrote:
Either that, or have the architecture dependent code set a static offset
that applies to all FixedWidthPointers. That would have the surprising
element that you'd have to set it twice, in the boot loader, and the
kernel, as the static code changes in between, though.
I don't quite understand what you mean. What I had in mind was to change the 
implementation of FixedWidthPointer::Pointer() to something like:

Yes, and that's probably the better idea, too :-)

What I meant was something like (in pseudo code):
        FixedWidthPointer::SetPointerOffset(x)
        {
                sOffset = x;
        }

        FixedWidthPointer::Pointer()
        {
                return fValue + sOffset;
        }

Besides that, it's almost certain that there will be other 64 bit
architectures in the future, indeed :-)
Sure. I expect a 32 bit boot loader and 64 bit kernel to be the exception, 
though.

Definitely, though they will all share the FixedWidthPointer.

Bye,
   Axel.

Other related posts: