Re: Inlining and global references (David Keppel)
Sun, 5 May 91 22:31:13 GMT

          From comp.compilers

Related articles
Re: Inlining and global references (1991-05-03)
Re: Inlining and global references (1991-05-05)
| List of all articles for this month |

Newsgroups: comp.compilers
From: (David Keppel)
Keywords: architecture, optimize
Organization: Computer Science & Engineering, U. of Washington, Seattle
References: <> <> <>
Date: Sun, 5 May 91 22:31:13 GMT writes:
>>[Accessing globals may be no faster than accessing locals]

In article <> writes:
>[Locals may be faster: 2-instruction sequence instead of one
> sp-relative instruction.]

John Levine writes:
>[On many CISCs, the stack reference is shorter than absolute.]

The MIPS compilers try to pack global references together so that
global data can be referenced with a single-instruction offset from a
`globals area' pointer that is assigned to a physical register. I
don't have any data about how well the technique works, but the net
result if it does work is that global and local references take the
same space and time. If the instruction set can make N-bit offsets in
a single instruction, then the technique only works for less than 2^N
bytes of data.

Hence my original claim ``may be no faster'' :-)

;-D on ( Byteing the data that feeds you ) Pardo

Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.