diff options
Diffstat (limited to 'gas/config/tc-tic6x.h')
-rw-r--r-- | gas/config/tc-tic6x.h | 45 |
1 files changed, 38 insertions, 7 deletions
diff --git a/gas/config/tc-tic6x.h b/gas/config/tc-tic6x.h index 087b9e9..0285db4 100644 --- a/gas/config/tc-tic6x.h +++ b/gas/config/tc-tic6x.h @@ -37,19 +37,26 @@ ? "elf32-tic6x-be" \ : "elf32-tic6x-le") -typedef struct +typedef struct tic6x_label_list { - /* Number of instructions in the current execute packet. */ - unsigned int num_execute_packet_insns; + struct tic6x_label_list *next; + symbolS *label; +} tic6x_label_list; - /* Whether a label has been seen since the last instruction or data - (in which case a following instruction may not have parallel - bars, but must start a new execute packet). */ - bfd_boolean seen_label; +typedef struct +{ + /* Any labels seen since the last instruction or data. If not NULL, + a following instruction may not have parallel bars, but must + start a new execute packet. */ + tic6x_label_list *label_list; /* Whether compact instructions are forbidden here. */ bfd_boolean nocmp; + /* If there is a current execute packet, the frag being used for + that execute packet. */ + fragS *execute_packet_frag; + /* If there is a current execute packet, a pointer to the least-significant byte of the last instruction in it (for setting the p-bit). */ @@ -70,6 +77,20 @@ typedef struct typedef struct { + /* Whether this machine-dependent frag is used for instructions (as + opposed to code alignment). */ + bfd_boolean is_insns; + + /* For a frag used for instructions, whether it is may cross a fetch + packet boundary (subject to alignment requirements). */ + bfd_boolean can_cross_fp_boundary; +} tic6x_frag_info; +#define TC_FRAG_TYPE tic6x_frag_info +#define TC_FRAG_INIT(fragP) tic6x_frag_init (fragP) +extern void tic6x_frag_init (fragS *fragp); + +typedef struct +{ /* Whether this fix was for an ADDA instruction. If so, a constant resulting from resolving the fix should be implicitly shifted left (it represents a value to be encoded literally in the @@ -91,6 +112,16 @@ extern void tic6x_cleanup (void); #define md_cons_align(n) tic6x_cons_align (n) extern void tic6x_cons_align (int n); +#define md_do_align(n, fill, len, max, label) \ + do { \ + if (tic6x_do_align (n, fill, len, max)) \ + goto label; \ + } while (0) +extern bfd_boolean tic6x_do_align (int n, char *fill, int len, int max); + +#define md_end() tic6x_end (); +extern void tic6x_end (void); + #define md_parse_name(name, exprP, mode, nextcharP) \ tic6x_parse_name (name, exprP, mode, nextcharP) extern int tic6x_parse_name (const char *name, expressionS *exprP, |