home *** CD-ROM | disk | FTP | other *** search
- Xref: sparky gnu.gcc.help:1759 comp.sys.sun.hardware:3487 comp.sys.sun.misc:3279 comp.unix.solaris:105
- Newsgroups: gnu.gcc.help,comp.sys.sun.hardware,comp.sys.sun.misc,comp.unix.solaris
- Path: sparky!uunet!gatech!destroyer!caen!nic.umass.edu!amherst!amhux1.amherst.edu!twpierce
- From: twpierce@amhux1.amherst.edu (Tim Pierce)
- Subject: SPARC assember directive ".text" generated by GCC 1.40
- Message-ID: <1992Jul22.194602.17372@amhux2.amherst.edu>
- Sender: usenet@amhux2.amherst.edu (USENET News System)
- Nntp-Posting-Host: amhux1.amherst.edu
- Organization: Amherst College, Amherst MA
- Date: Wed, 22 Jul 1992 19:46:02 GMT
- Lines: 35
-
- My apologies if the crossposting (gnu.gcc.help, comp.sys.sun.hardware,
- comp.sys.sun.misc, comp.unix.solaris) is inappropriate, but I'm not
- sure whether my question relates to my compiler, my assembler, or my
- hardware.
-
- My senior thesis is in compiler design and code generation for RISC
- architectures. I'm working with GCC 1.40 on a SPARCstation ELC
- running SunOS 4.1.2 (and Sun-supplied as), and examining the assembler
- output from GCC's -S switch to get a handle on code generation
- techniques.
-
- GCC generates a ".text" assembler directive at the beginning of
- programs that utilize constant strings, apparently to inform the
- assembler that the following section of the program stores text.
- Example, from a program that includes the statement
- "printf ("%d\n", i)":
-
- gcc_compiled.:
- .text
- LC0:
- .ascii "%d\12\0"
- .align 4
- .global _main
- .proc 1
- ...
-
- I cannot find mention of the .text directive anywhere in the Sun-4
- assembler manual, nor in the SPARC Architecture Manual from SPARC
- international (a less likely place, I admit). Can anyone enlighten me
- on the care and feeding of this mysterious assembler pseudo-op?
-
- --
- ____ Tim Pierce / "You mean there are TWO of you, Pierce?
- \ / twpierce@amherst.edu / God help us all."
- \/ (BITnet: TWPIERCE@AMHERST) / -- Major Charles Emerson Winchester III
-