7 typedef ModelList<FuncInst *> func_inst_list_mt;
14 uint32_t get_func_id() { return func_id; }
15 const char * get_func_name() { return func_name; }
16 void set_func_id(uint32_t id) { func_id = id; }
17 void set_func_name(const char * name) { func_name = name; }
19 FuncInst * get_or_add_action(ModelAction *act);
21 HashTable<const char *, FuncInst *, uintptr_t, 4, model_malloc, model_calloc, model_free> * getFuncInstMap() { return &func_inst_map; }
22 func_inst_list_mt * get_inst_list() { return &inst_list; }
23 func_inst_list_mt * get_entry_insts() { return &entry_insts; }
24 void add_entry_inst(FuncInst * inst);
26 void group_reads_by_loc(FuncInst * inst);
31 const char * func_name;
33 /* Use source line number as the key of hashtable, to check if
34 * atomic operation with this line number has been added or not
36 * To do: cds_atomic_compare_exchange contains three atomic operations
37 * that are feeded with the same source line number by llvm pass
39 HashTable<const char *, FuncInst *, uintptr_t, 4, model_malloc, model_calloc, model_free> func_inst_map;
41 /* list of all atomic actions in this function */
42 func_inst_list_mt inst_list;
44 /* possible entry atomic actions in this function */
45 func_inst_list_mt entry_insts;
47 /* group atomic read actions by memory location */
48 HashTable<void *, func_inst_list_mt *, uintptr_t, 4, model_malloc, model_calloc, model_free> reads_by_loc;