aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/linearize.h
diff options
authorLinus Torvalds <torvalds@ppc970.osdl.org>2004-11-25 18:49:10 -0700
committerLinus Torvalds <torvalds@ppc970.osdl.org>2005-04-07 21:04:54 -0700
commit3578ab8fd2d9d4b35806926ac0de01c30deb2fb8 (patch)
tree1493c9d82c4b5f874c6c109931f0293ce4047c70 /linearize.h
parent46577fc50347e401d8d2e8890a9512b5a5962f7c (diff)
downloadsparse-dev-3578ab8fd2d9d4b35806926ac0de01c30deb2fb8.tar.gz
Do early CSE before even doing the symbol simplification.
This allows us to notice when a symbol address usage is trivially dead, and optimize such a symbol better since we don't have to worry about the address being used to access it.
Diffstat (limited to 'linearize.h')
-rw-r--r--linearize.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/linearize.h b/linearize.h
index 237e8960..adc900ae 100644
--- a/linearize.h
+++ b/linearize.h
@@ -58,8 +58,8 @@ struct instruction {
struct pseudo_list *phi_list;
};
struct /* unops */ {
- struct symbol *orig_type; /* casts */
pseudo_t src;
+ struct symbol *orig_type; /* casts */
unsigned int offset; /* memops */
};
struct /* binops */ {
@@ -73,8 +73,8 @@ struct instruction {
int begin, end;
};
struct /* setval */ {
+ pseudo_t symbol; /* Subtle: same offset as "src" !! */
struct expression *val;
- struct symbol *symbol;
};
struct /* call */ {
pseudo_t func;