public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
* Register Pressure in Instruction Level Parallelism
@ 2009-06-28 12:37 Michael Kruse
  2009-06-28 19:06 ` Dave Korn
  2009-06-29 16:27 ` Vladimir Makarov
  0 siblings, 2 replies; 20+ messages in thread
From: Michael Kruse @ 2009-06-28 12:37 UTC (permalink / raw)
  To: gcc

[-- Attachment #1: Type: text/plain, Size: 2463 bytes --]

Hello GCC developers,

I am going to write a Master's Thesis about instruction scheduling based 
on the technique presented in [1]. This will also include a implementation.

The basic idea is to have an additional pass on the data dependency 
graph before instruction scheduling and register allocation takes place. 
It estimates the minimal (register sufficiency) and maximal number of 
registers (register saturation) required by schedules based on that graph.

If the register sufficiency is higher than the physical number of 
registers, spill code is added to the graph.

If the register saturation is higher than the physical number of 
registers, artificial dependencies are added to the graph, such that the 
instruction scheduler is forced to generate a schedule with less registers.

The aim is that the instruction scheduler can focus on the optimal 
arrangement of instructions to exploit a maximal amount of instruction 
level parallelism. [1] also suggests heuristics for all these problems. 
According to the author, these are "nearly optimal" in practice. The 
heuristics for estimating register sufficiency and saturation are both 
optimistic, meaning that it might still be necessary to add more spill 
code to the final code. Hence, this this technique is just an 
optimization pass and doesn't replace existing register allocation or 
instruction scheduling passes.

[1] also has a part about loop scheduling, but my thesis will be about 
basic blocks only. See [2] for an presentation of this technique.

So, now my questions: How much do you think could this could improve 
compiled code speed? Would the current GCC/YARA benefit from such an 
optimization pass at all? What are the chances that this could get into 
the main GCC tree if it shows up to be an improvement?

There has been a short discussion on this mailing list already [3] some 
years ago (Note if you read this: intLP has been used to compare the 
heuristic to the optimal result only). To my knowledge, there hasn't 
been any more on this topic yet (anywhere).

I'd prefer to implement this for the gcc, but my advisor wants me to do 
it for the university's own compiler. Therefore I could also need 
arguments why to do it for the GCC.

Regards,
Michael Kruse

[1] http://www.prism.uvsq.fr/~touati/thesis.html
[2] http://tel.archives-ouvertes.fr/docs/00/04/72/88/ANNEX/tel-00007405.ppt
[3] http://gcc.gnu.org/ml/gcc/2002-07/msg00565.html

-- 
Tardyzentrismus verboten!


[-- Attachment #2: S/MIME Cryptographic Signature --]
[-- Type: application/x-pkcs7-signature, Size: 4401 bytes --]

^ permalink raw reply	[flat|nested] 20+ messages in thread

end of thread, other threads:[~2009-07-02 21:53 UTC | newest]

Thread overview: 20+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-06-28 12:37 Register Pressure in Instruction Level Parallelism Michael Kruse
2009-06-28 19:06 ` Dave Korn
2009-06-28 22:53   ` Albert Cohen
2009-06-28 23:56     ` Dave Korn
2009-06-29  6:13       ` Albert Cohen
2009-06-29 18:04       ` Vladimir Makarov
2009-07-01  6:09         ` Jeff Law
2009-07-02 21:53           ` Vladimir Makarov
2009-07-01  5:58       ` Jeff Law
2009-06-29  0:30     ` Michael Kruse
     [not found]     ` <303e1d290906281549t4ebfce81m5152069742fa9a1@mail.gmail.com>
2009-06-29  6:28       ` Fwd: " Kenneth Zadeck
2009-06-28 23:01   ` Michael Kruse
2009-06-29  0:03     ` Dave Korn
2009-06-29 17:05   ` Vladimir Makarov
2009-06-29 16:27 ` Vladimir Makarov
2009-06-29 20:03   ` Michael Kruse
2009-06-29 20:40     ` Vladimir Makarov
2009-06-29 21:04       ` Michael Kruse
2009-06-30 15:01       ` Albert Cohen
2009-07-01  6:06   ` Jeff Law

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).