8 * The "storage" that underlies an incoming/outgoing pseudo. It's
9 * basically the backing store for a pseudo, and may be a real hardware
10 * register, a stack slot or a static symbol. Or nothing at all,
11 * since some pseudos can just be recalculated on the fly.
29 DECLARE_PTR_LIST(storage_ptr_list
, struct storage
*);
32 enum storage_type type
;
34 struct storage_ptr_list
*users
;
42 DECLARE_PTR_LIST(storage_list
, struct storage
);
45 struct basic_block
*bb
;
47 enum inout_enum inout
;
48 struct storage
*storage
;
52 DECLARE_PTR_LIST(storage_hash_list
, struct storage_hash
);
54 extern struct storage_hash_list
*gather_storage(struct basic_block
*, enum inout_enum
);
55 extern void free_storage(void);
56 extern const char *show_storage(struct storage
*);
57 extern void set_up_storage(struct entrypoint
*);
58 struct storage
*lookup_storage(struct basic_block
*, pseudo_t
, enum inout_enum
);
59 void add_storage(struct storage
*, struct basic_block
*, pseudo_t
, enum inout_enum
);
61 DECLARE_ALLOCATOR(storage
);
62 DECLARE_ALLOCATOR(storage_hash
);
64 static inline struct storage
*alloc_storage(void)
66 return __alloc_storage(0);
69 static inline struct storage_hash
*alloc_storage_hash(struct storage
*s
)
71 struct storage_hash
*entry
= __alloc_storage_hash(0);
72 struct storage
**usep
= &entry
->storage
;
75 add_ptr_list(&s
->users
, usep
);
79 #endif /* STORAGE_H */