summaryrefslogtreecommitdiff
path: root/gcc/df.h
diff options
context:
space:
mode:
authoraoliva <aoliva@138bc75d-0d04-0410-961f-82ee72b054a4>2012-04-13 15:56:21 +0000
committeraoliva <aoliva@138bc75d-0d04-0410-961f-82ee72b054a4>2012-04-13 15:56:21 +0000
commit2abb79fc589e6dbb9f7f7c5cb4c095dd6764dffa (patch)
tree283216c0c3a9019c8feb931e55ba7d5c90f81f3e /gcc/df.h
parent9f5c85ce4e04151ad5abda92119c06e560921f7e (diff)
downloadgcc-2abb79fc589e6dbb9f7f7c5cb4c095dd6764dffa.tar.gz
PR debug/48866
* df.h (enum debug_temp_where): New. (dead_debug_init, dead_debug_finish) Declare. (dead_debug_add, dead_debug_insert_temp): Declare. (struct dead_debug_use, struct dead_debug): Moved from... * df-problems.c: ... here. (df_set_unused_notes_for_mw): Bind debug uses of unused regno to a debug temp. (df_create_unused_note): Likewise. (df_set_dead_notes_for_mw): Move comment where it belongs. (dead_debug_init): Export. (dead_debug_reset_uses): New, factored out of... (dead_debug_finish): ...this. Export. (dead_debug_reset): Remove. (dead_debug_add): Export. (dead_debug_insert_before): Rename to... (dead_debug_insert_temp): ... this. Add where argument. Export. Locate stored value for BEFORE_WITH_VALUE. Avoid repeat inserts. Return insertion count. (df_note_bb_compute): Adjust. * dce.c (word_dce_process_block): Adjust dead debug uses. (dce_process_block): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@186422 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/df.h')
-rw-r--r--gcc/df.h42
1 files changed, 42 insertions, 0 deletions
diff --git a/gcc/df.h b/gcc/df.h
index aec97883ee5..c0fabb9e2b7 100644
--- a/gcc/df.h
+++ b/gcc/df.h
@@ -1101,4 +1101,46 @@ extern void union_defs (df_ref, struct web_entry *,
unsigned int *used, struct web_entry *,
bool (*fun) (struct web_entry *, struct web_entry *));
+/* Debug uses of dead regs. */
+
+/* Node of a linked list of uses of dead REGs in debug insns. */
+struct dead_debug_use
+{
+ df_ref use;
+ struct dead_debug_use *next;
+};
+
+/* Linked list of the above, with a bitmap of the REGs in the
+ list. */
+struct dead_debug
+{
+ struct dead_debug_use *head;
+ bitmap used;
+ bitmap to_rescan;
+};
+
+/* This type controls the behavior of dead_debug_insert_temp WRT
+ UREGNO and INSN. */
+enum debug_temp_where
+ {
+ /* Bind a newly-created debug temporary to a REG for UREGNO, and
+ insert the debug insn before INSN. REG is expected to die at
+ INSN. */
+ DEBUG_TEMP_BEFORE_WITH_REG = -1,
+ /* Bind a newly-created debug temporary to the value INSN stores
+ in REG, and insert the debug insn before INSN. */
+ DEBUG_TEMP_BEFORE_WITH_VALUE = 0,
+ /* Bind a newly-created debug temporary to a REG for UREGNO, and
+ insert the debug insn after INSN. REG is expected to be set at
+ INSN. */
+ DEBUG_TEMP_AFTER_WITH_REG = 1
+ };
+
+extern void dead_debug_init (struct dead_debug *, bitmap);
+extern void dead_debug_finish (struct dead_debug *, bitmap);
+extern void dead_debug_add (struct dead_debug *, df_ref, unsigned int);
+extern int dead_debug_insert_temp (struct dead_debug *,
+ unsigned int uregno, rtx insn,
+ enum debug_temp_where);
+
#endif /* GCC_DF_H */