combining two procedures?

"Mark Harrison" <>
7 Feb 1999 00:12:15 -0500

          From comp.compilers

Related articles
combining two procedures? (Mark Harrison) (1999-02-07)
| List of all articles for this month |

From: "Mark Harrison" <>
Newsgroups: comp.compilers
Date: 7 Feb 1999 00:12:15 -0500
Keywords: optimize, question, parallel

I am looking for an algorithm for combining the statements
of two procedures into one. I think this can be done
by making a poset of the ordered statements, and then
using one of the total orders of the poset.

As a trivial case, combining
        proc p1 { s1; s2; s3}
        proc p2 { t1; t2; t3}
could result in the orders
        { s1; s2; s3; t1; t2; t3 }, { s1; t1; s2; t2; s3; t3 }, etc.

I'm interested in understanding how control flow (loops,
conditionals, etc) affects this. Does it simply become
a matter of ordering blocks rather than statements?

Any ideas appreciated,

Mark Harrison
AsiaInfo Computer Networks
Beijing, China / Santa Clara, CA

Post a followup to this message

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