Re: x86 Segment register use

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, 2006-07-10 at 04:14 -0700, Tim Prince wrote:
> David Fernandez wrote:
> > 	Hi there,
> > 
> > 	Could anyone there tell which segment registers does the compiler use
> > (CS, DS, ES, FS, GS), or if it doesn't use any at all and rely on the
> > default segments all the time?
> > 
> > 	Is there any way to tell it that a specific variable resides, or is
> > addressable only through a specific segment register?
> > 
> As only you know enough details about your compiler, 
> application,platform, operating system, etc,
>   you should consider generating .s code or using objdump -S to answer these
> questions yourself.
> 

Ooops, sorry for the lack of details... I'm using gcc:

> [root@software ~]# gcc -v
> Using built-in specs.
> Target: i386-redhat-linux
> Configured with: ../configure --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --enable-shared --enable-threads=posix --enable-checking=release --with-system-zlib --enable-__cxa_atexit --disable-libunwind-exceptions --enable-libgcj-multifile --enable-languages=c,c++,objc,java,f95,ada --enable-java-awt=gtk --with-java-home=/usr/lib/jvm/java-1.4.2-gcj-1.4.2.0/jre --host=i386-redhat-linux
> Thread model: posix
> gcc version 4.0.2 20051125 (Red Hat 4.0.2-8)

running under Fedora Core 4 (the gcc that comes with it).

I haven't seen any reference to segment registers so far, but I haven't
tries every kind of program under gcc.

... And I was just wondering if some-(gcc developer, perhaps)-one knows about that.

David.


[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux