1994-06-24 11:31:16 +00:00
|
|
|
/* $Id$ */
|
1987-03-09 19:15:41 +00:00
|
|
|
/*
|
|
|
|
* (c) copyright 1987 by the Vrije Universiteit, Amsterdam, The Netherlands.
|
|
|
|
* See the copyright notice in the ACK home directory, in the file "Copyright".
|
|
|
|
*/
|
1984-11-26 14:35:32 +00:00
|
|
|
|
|
|
|
/* C O N S T A N T P R O P A G A T I O N */
|
|
|
|
|
2019-10-31 22:05:22 +00:00
|
|
|
line_p unique_def(line_p use, bblock_p b, short *defnr_out);
|
|
|
|
/*
|
1984-11-26 14:35:32 +00:00
|
|
|
* See if there is a unique explicit definition
|
|
|
|
* of the variable used by 'use' that
|
|
|
|
* reaches 'use'.
|
|
|
|
*/
|
2019-10-31 22:05:22 +00:00
|
|
|
bool value_known(line_p def, offset *val_out);
|
|
|
|
/*
|
1984-11-26 14:35:32 +00:00
|
|
|
* See if the value stored by definition 'def'
|
|
|
|
* is known statically (i.e. is a constant).
|
|
|
|
*/
|
2019-10-31 22:05:22 +00:00
|
|
|
void fold_const(line_p l, bblock_p b, offset val);
|
|
|
|
/*
|
1984-11-26 14:35:32 +00:00
|
|
|
* Perform the substitutions required for
|
|
|
|
* constant folding.
|
|
|
|
*/
|
2019-10-31 22:05:22 +00:00
|
|
|
bool is_use(line_p l); /*
|
1984-11-26 14:35:32 +00:00
|
|
|
* See if 'l' is a use of a variable.
|
|
|
|
*/
|
2019-10-31 22:05:22 +00:00
|
|
|
bool affected(line_p use, short v, line_p l);
|
|
|
|
/*
|
1984-11-26 14:35:32 +00:00
|
|
|
* See if the variable referenced by 'use' may
|
|
|
|
* be changed by instruction l, which is
|
|
|
|
* either a cal, cai or an indirect assignment.
|
|
|
|
*/
|