From 25bab8b1fb2fc851ea3f1f630b3de65ca6afdc22 Mon Sep 17 00:00:00 2001 From: Ash Wolf Date: Wed, 14 Dec 2022 00:16:59 +0000 Subject: haha it's been a while since i last committed, hasn't it --- includes/compiler/Alias.h | 53 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) (limited to 'includes/compiler/Alias.h') diff --git a/includes/compiler/Alias.h b/includes/compiler/Alias.h index 39f7220..08dbb00 100644 --- a/includes/compiler/Alias.h +++ b/includes/compiler/Alias.h @@ -3,4 +3,57 @@ #include "compiler/common.h" +#ifdef __MWERKS__ +#pragma options align=mac68k +#endif +typedef struct AliasMember AliasMember; + +typedef enum AliasType { + AliasType0, + AliasType1, + AliasType2 +} AliasType; + +struct Alias { + Alias *next; + Alias *hashNext; + AliasMember *children; + AliasMember *parents; + Object *object; + SInt32 offset; + SInt32 size; + int valuenumber; + PCode *valuepcode; + UInt32 *vec24; + int index; + AliasType type; +}; + +struct AliasMember { + AliasMember *nextParent; + AliasMember *nextChild; + Alias *parent; + Alias *child; +}; +#ifdef __MWERKS__ +#pragma options align=reset +#endif + +extern Alias *worst_case; +extern Object worst_case_obj; + +extern void initialize_aliases(void); +extern Alias *make_alias(Object *object, SInt32 offset, SInt32 size); +extern Alias *make_alias_set(void); +extern void add_alias_member(Alias *parent, Alias *child); +extern Alias *make_alias_set_from_IR(void); +extern void gather_alias_info(void); +extern Boolean may_alias(PCode *a, PCode *b); +extern Boolean uniquely_aliases(PCode *a, PCode *b); +extern Boolean may_alias_worst_case(PCode *pcode); +extern Boolean may_alias_object(PCode *pcode, Object *object); +extern void initialize_alias_values(void); +extern void update_alias_value(Alias *alias, PCode *pcode); +extern void update_all_alias_values(void); + #endif -- cgit v1.2.3