diff options
author | Linus Torvalds <torvalds@ppc970.osdl.org> | 2004-11-28 14:34:33 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@ppc970.osdl.org> | 2005-04-07 21:05:12 -0700 |
commit | 726a641eadca60a59c580744f1277bb29fd7acf7 (patch) | |
tree | 3243ed1aab568697f785a448452c7b07e685a5b1 /memops.c | |
parent | Fix entrypoint branch rewriting.. (diff) | |
download | sparse-726a641eadca60a59c580744f1277bb29fd7acf7.tar.gz sparse-726a641eadca60a59c580744f1277bb29fd7acf7.tar.bz2 sparse-726a641eadca60a59c580744f1277bb29fd7acf7.zip |
Fix test for entrypoint. Since we can rewrite branches
to it, it's not correct to assume that a bb without parents
is the entrypoint.
Diffstat (limited to 'memops.c')
-rw-r--r-- | memops.c | 6 |
1 files changed, 5 insertions, 1 deletions
@@ -22,7 +22,11 @@ static int find_dominating_parents(pseudo_t pseudo, struct instruction *insn, { struct basic_block *parent; - if (!bb->parents) + /* + * The entrypoint is special - it dominates all non-local + * pseudos, but no local ones. + */ + if (bb == bb->ep->entry) return !!local; if (bb_list_size(bb->parents) > 1) |