Lines Matching defs:unwind

45 /* Must be at least the size of the largest unwind opcode (currently two).  */
77 } unwind;
4093 /* Directives: AEABI stack-unwind tables. */
4101 if (unwind.proc_start)
4108 unwind.proc_start = expr_build_dot ();
4110 /* Reset the rest of the unwind info. */
4111 unwind.opcode_count = 0;
4112 unwind.table_entry = NULL;
4113 unwind.personality_routine = NULL;
4114 unwind.personality_index = -1;
4115 unwind.frame_size = 0;
4116 unwind.fp_offset = 0;
4117 unwind.fp_reg = REG_SP;
4118 unwind.fp_used = 0;
4119 unwind.sp_restored = 0;
4130 if (!unwind.proc_start)
4133 if (unwind.table_entry)
4151 if (!unwind.proc_start)
4158 if (unwind.table_entry == NULL)
4164 start_unwind_section (unwind.saved_seg, 1);
4173 fix_new (frag_now, where, 4, unwind.proc_start, 0, 1,
4180 if (unwind.personality_index >= 0 && unwind.personality_index < 3
4181 && !(marked_pr_dependency & (1 << unwind.personality_index)))
4189 symbolS *pr = symbol_find_or_make (name[unwind.personality_index]);
4192 |= 1 << unwind.personality_index;
4200 fix_new (frag_now, where + 4, 4, unwind.table_entry, 0, 1,
4204 subseg_set (unwind.saved_seg, unwind.saved_subseg);
4206 unwind.proc_start = NULL;
4216 if (!unwind.proc_start)
4219 if (unwind.personality_routine || unwind.personality_index != -1)
4222 unwind.personality_index = -2;
4233 if (!unwind.proc_start)
4236 if (unwind.personality_routine || unwind.personality_index != -1)
4249 unwind.personality_index = exp.X_add_number;
4262 if (!unwind.proc_start)
4265 if (unwind.personality_routine || unwind.personality_index != -1)
4272 unwind.personality_routine = symbol_find_or_make (name);
4300 if (unwind.sp_restored && unwind.fp_reg == 12
4303 unwind.opcode_count--;
4304 unwind.sp_restored = 0;
4306 unwind.pending_offset = 0;
4350 unwind.frame_size += 4;
4400 unwind.frame_size += num_regs * 12;
4452 unwind.frame_size += count * 8;
4489 unwind.frame_size += count * 8 + 4;
4552 unwind.frame_size += 8;
4556 likes to output separate unwind directives for a single block of
4558 if (unwind.opcode_count > 0)
4560 i = unwind.opcodes[unwind.opcode_count - 1];
4570 unwind.opcode_count--;
4573 else if (i == 6 && unwind.opcode_count >= 2)
4575 i = unwind.opcodes[unwind.opcode_count - 2];
4586 unwind.opcode_count -= 2;
4686 unwind.frame_size += 4;
4706 if (!unwind.proc_start)
4775 if (!unwind.proc_start)
4803 if (unwind.fp_reg != REG_SP)
4811 unwind.fp_reg = reg;
4812 unwind.fp_offset = unwind.frame_size - offset;
4813 unwind.sp_restored = 1;
4823 if (!unwind.proc_start)
4837 unwind.frame_size += offset;
4838 unwind.pending_offset += offset;
4852 if (!unwind.proc_start)
4879 if (sp_reg != REG_SP && sp_reg != unwind.fp_reg)
4887 unwind.fp_reg = fp_reg;
4888 unwind.fp_used = 1;
4890 unwind.fp_offset = unwind.frame_size - offset;
4892 unwind.fp_offset -= offset;
4905 if (!unwind.proc_start)
4912 unwind.frame_size += exp.X_add_number;
4932 as_bad (_("unwind opcode too long"));
4937 as_bad (_("invalid unwind opcode"));
26871 /* Link an unlinked unwind index table section to the .text section. */
26891 /* Generate any deferred unwind frame offset. */
26898 offset = unwind.pending_offset;
26899 unwind.pending_offset = 0;
26912 if (unwind.pending_offset)
26915 unwind.sp_restored = 0;
26917 if (unwind.opcode_count + length > unwind.opcode_alloc)
26919 unwind.opcode_alloc += ARM_OPCODE_CHUNK_SIZE;
26920 if (unwind.opcodes)
26921 unwind.opcodes = XRESIZEVEC (unsigned char, unwind.opcodes,
26922 unwind.opcode_alloc);
26924 unwind.opcodes = XNEWVEC (unsigned char, unwind.opcode_alloc);
26929 unwind.opcodes[unwind.opcode_count] = op & 0xff;
26931 unwind.opcode_count++;
26935 /* Add unwind opcodes to adjust the stack pointer. */
26997 /* Finish the list of unwind opcodes for this function. */
27004 if (unwind.fp_used)
27007 unwind.pending_offset += unwind.fp_offset - unwind.frame_size;
27011 op = 0x90 | unwind.fp_reg;
27088 /* Start an unwind table entry. HAVE_DATA is nonzero if we have additional
27106 unwind.saved_seg = now_seg;
27107 unwind.saved_subseg = now_subseg;
27111 if (unwind.personality_routine == NULL)
27113 if (unwind.personality_index == -2)
27121 if (unwind.personality_index == -1)
27123 if (unwind.opcode_count > 3)
27124 unwind.personality_index = 1;
27126 unwind.personality_index = 0;
27130 if (unwind.personality_index == 0)
27132 if (unwind.opcode_count > 3)
27133 as_bad (_("too many unwind opcodes for personality routine 0"));
27140 while (unwind.opcode_count > 0)
27142 unwind.opcode_count--;
27143 data = (data << 8) | unwind.opcodes[unwind.opcode_count];
27157 size = unwind.opcode_count - 2;
27161 /* PR 16765: Missing or misplaced unwind directives can trigger this. */
27162 if (unwind.personality_index != -1)
27164 as_bad (_("attempt to recreate an unwind entry"));
27169 size = unwind.opcode_count + 1;
27174 as_bad (_("too many unwind opcodes"));
27178 unwind.table_entry = expr_build_dot ();
27186 switch (unwind.personality_index)
27191 fix_new (frag_now, where, 4, unwind.personality_routine, 0, 1,
27212 data = ((0x80 + unwind.personality_index) << 8) | size;
27223 while (unwind.opcode_count > 0)
27232 unwind.opcode_count--;
27234 data = (data << 8) | unwind.opcodes[unwind.opcode_count];
27258 /* Initialize the DWARF-2 unwind information for this procedure. */