1 /* Common subexpression elimination for GNU compiler.
2 Copyright (C) 1987, 1988, 1989, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
3 1999 Free Software Foundation, Inc.
5 This file is part of GNU CC.
7 GNU CC is free software; you can redistribute it and/or modify
8 it under the terms of the GNU General Public License as published by
9 the Free Software Foundation; either version 2, or (at your option)
12 GNU CC is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 GNU General Public License for more details.
17 You should have received a copy of the GNU General Public License
18 along with GNU CC; see the file COPYING. If not, write to
19 the Free Software Foundation, 59 Temple Place - Suite 330,
20 Boston, MA 02111-1307, USA. */
22 /* Describe a value. */
23 typedef struct cselib_val_struct
29 /* A VALUE rtx that points back to this structure. */
31 /* Used to keep a list of free cselib_val structures. */
32 struct cselib_val_struct
*next_free
;
35 /* All rtl expressions that hold this value at the current time during a
37 struct elt_loc_list
*locs
;
38 /* If this value is used as an address, points to a list of values that
39 use it as an address in a MEM. */
40 struct elt_list
*addr_list
;
43 /* A list of rtl expressions that hold the same value. */
46 /* Next element in the list. */
47 struct elt_loc_list
*next
;
48 /* An rtl expression that holds the value. */
50 /* The insn that made the equivalence. */
54 /* A list of cselib_val structures. */
57 struct elt_list
*next
;
61 extern cselib_val
*cselib_lookup
PARAMS ((rtx
, enum machine_mode
, int));
62 extern void cselib_update_varray_sizes
PARAMS ((void));
63 extern void cselib_init
PARAMS ((void));
64 extern void cselib_finish
PARAMS ((void));
65 extern void cselib_process_insn
PARAMS ((rtx
));
66 extern int rtx_equal_for_cselib_p
PARAMS ((rtx
, rtx
));
67 extern int references_value_p
PARAMS ((rtx
, int));