www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1996/08/01/10:20:29

Date: Thu, 1 Aug 1996 16:16:43 +0200 (MET DST)
From: Mark Habersack <grendel AT ananke DOT amu DOT edu DOT pl>
To: "Alaric B. Williams" <alaric AT abwillms DOT demon DOT co DOT uk>
cc: djgpp AT delorie DOT com
Subject: Re: __attribute__((section))
In-Reply-To: <838840319.11194.2@abwillms.demon.co.uk>
Message-ID: <Pine.NEB.3.93.960801161121.10145A-100000@ananke.amu.edu.pl>
MIME-Version: 1.0

On Wed, 31 Jul 1996, Alaric B. Williams wrote:

>Mark Habersack <grendel AT ananke DOT amu DOT edu DOT pl> wrote:
>
>>segment when proggy is loaded? If so, you have to use far pointers/switch DS
>>selector if you want to access the data - BY HAND.
>
>Is this really true?
>
>I mean, will the stub actually allocate seperate selectors with DPMI
>for other sections, or just load all those sections into the same
>virtual address space, as I thought?
You're right, but what about automatic locking of the section at
startup? [continued below]

>I managed that... without changing the ld script, so ld just put my
>section into a section of the same name in the output file (ie, didn't
The loader code needs to know where does the section to be locked begin/end.

>group it). No need for different .ld scripts unless you want to
>control the placement of this section in the load image.
So you have to create a separate .ld script anyway to initialize variables
properly - just like it's done with .dtor .ctor sections. Note that the LIBC
source contains only extern declarations of the __djgpp_first_ctor/dtor and
__djgpp_last_ctor/dtor - they are actually created in .ld script. 

Mark

/*******************************/
/** So here I am once more... **************************************/
/** When you grown up and leave your playground, where you kissed **/
/** your Prince and found your Frog - remember the Jester that    **/
/** showed you tears, a Script for Tears... ************************/
/*********************************************/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019