Lines Matching defs:frame

121 /* The maximum distance between the top of the stack frame and the
139 part of the frame. */
353 /* Information about a function's frame layout. */
355 /* The size of the frame in bytes. */
385 save slots from the top of the frame, or zero if no such slots are
392 /* Likewise, but giving offsets from the bottom of the frame. */
401 /* The offset of arg_pointer_rtx from the bottom of the frame. */
404 /* The offset of hard_frame_pointer_rtx from the bottom of the frame. */
417 This area is allocated by the callee at the very top of the frame. */
420 /* The current frame information, calculated by mips_compute_frame_info. */
421 struct mips_frame_info frame;
1432 /* Nested functions must use the same frame pointer as their
2321 hard frame pointer, both of which are usually valid base registers.
8855 to be in terms of the virtual frame pointer (stack pointer before
8857 the frame pointer to be the stack pointer after the initial
8859 is eliminated) points to the virtual frame pointer, while the frame
8876 offset -= cfun->machine->frame.total_size;
8878 offset += cfun->machine->frame.hard_frame_pointer_offset;
9388 /* Make the last instruction frame-related and note that it performs
9403 /* Return a frame-related rtx that stores REG at MEM.
9537 frame-pointer access. */
9540 required_offset = cfun->machine->frame.total_size + argno * UNITS_PER_WORD;
9542 required_offset -= cfun->machine->frame.hard_frame_pointer_offset;
9587 if (!BITSET_P (cfun->machine->frame.mask, regno))
9658 gcc_assert (cfun->machine->frame.num_fp == 0);
10249 /* The function's prologue will need to set the frame pointer if
10370 struct mips_frame_info *frame;
10396 frame = &cfun->machine->frame;
10397 memset (frame, 0, sizeof (*frame));
10404 target-independent frame size is nonzero, we have already committed to
10410 looks like we are trying to create a second frame pointer to the
10413 frame->args_size = REG_PARM_STACK_SPACE (cfun->decl);
10415 frame->args_size = 0;
10416 frame->cprestore_size = 0;
10420 frame->args_size = crtl->outgoing_args_size;
10421 frame->cprestore_size = MIPS_GP_SAVE_AREA_SIZE;
10423 offset = frame->args_size + frame->cprestore_size;
10426 frame->var_size = MIPS_STACK_ALIGN (size);
10427 offset += frame->var_size;
10433 frame->num_gp++;
10434 frame->mask |= 1 << (regno - GP_REG_FIRST);
10442 frame->num_gp++;
10443 frame->mask |= 1 << (EH_RETURN_DATA_REGNO (i) - GP_REG_FIRST);
10451 mips16e_mask_registers (&frame->mask, mips16e_s2_s8_regs,
10452 ARRAY_SIZE (mips16e_s2_s8_regs), &frame->num_gp);
10453 mips16e_mask_registers (&frame->mask, mips16e_a0_a3_regs,
10454 ARRAY_SIZE (mips16e_a0_a3_regs), &frame->num_gp);
10458 if (frame->num_gp > 0)
10460 offset += MIPS_STACK_ALIGN (frame->num_gp * UNITS_PER_WORD);
10461 frame->gp_sp_offset = offset - UNITS_PER_WORD;
10470 frame->num_fp += MAX_FPRS_PER_FMT;
10471 frame->fmask |= ~(~0 << MAX_FPRS_PER_FMT) << (regno - FP_REG_FIRST);
10475 if (frame->num_fp > 0)
10477 offset += MIPS_STACK_ALIGN (frame->num_fp * UNITS_PER_FPREG);
10478 frame->fp_sp_offset = offset - UNITS_PER_HWFPVALUE;
10487 frame->num_acc++;
10488 frame->acc_mask |= (1 << 0);
10495 frame->num_acc++;
10496 frame->acc_mask |= 1 << (((i - DSP_ACC_REG_FIRST) / 2) + 1);
10500 frame->num_cop0_regs++;
10504 frame->num_cop0_regs++;
10508 if (frame->num_acc > 0)
10511 offset += frame->num_acc * 2 * UNITS_PER_WORD;
10512 frame->acc_sp_offset = offset - UNITS_PER_WORD;
10516 if (frame->num_cop0_regs > 0)
10518 offset += frame->num_cop0_regs * UNITS_PER_WORD;
10519 frame->cop0_sp_offset = offset - UNITS_PER_WORD;
10524 frame->arg_pointer_offset = offset;
10528 frame->total_size = offset;
10530 /* Work out the offsets of the save areas from the top of the frame. */
10531 if (frame->gp_sp_offset > 0)
10532 frame->gp_save_offset = frame->gp_sp_offset - offset;
10533 if (frame->fp_sp_offset > 0)
10534 frame->fp_save_offset = frame->fp_sp_offset - offset;
10535 if (frame->acc_sp_offset > 0)
10536 frame->acc_save_offset = frame->acc_sp_offset - offset;
10537 if (frame->num_cop0_regs > 0)
10538 frame->cop0_save_offset = frame->cop0_sp_offset - offset;
10540 /* MIPS16 code offsets the frame pointer by the size of the outgoing
10544 frame->hard_frame_pointer_offset = frame->args_size;
10571 use the frame pointer to access the static parts of the frame. */
10575 /* In MIPS16 mode, we need a frame pointer for a large frame; otherwise,
10582 if (!SMALL_OPERAND (cfun->machine->frame.total_size))
10589 /* Make sure that we're not trying to eliminate to the wrong hard frame
10598 /* Implement INITIAL_ELIMINATION_OFFSET. FROM is either the frame pointer
10599 or argument pointer. TO is either the stack pointer or hard frame
10614 offset = (cfun->machine->frame.args_size
10615 + cfun->machine->frame.cprestore_size
10616 + cfun->machine->frame.var_size);
10622 offset = cfun->machine->frame.arg_pointer_offset;
10630 offset -= cfun->machine->frame.hard_frame_pointer_offset;
10659 previous frame. */
10662 mips_return_addr (int count, rtx frame ATTRIBUTE_UNUSED)
10679 gcc_assert (BITSET_P (cfun->machine->frame.mask, RETURN_ADDR_REGNUM));
10681 cfun->machine->frame.gp_sp_offset);
10691 && cfun->machine->frame.cprestore_size > 0);
10703 const struct mips_frame_info *frame;
10705 frame = &cfun->machine->frame;
10706 /* .cprestore always uses the stack pointer instead of the frame pointer.
10710 (early) scheduling freedom, but using the frame pointer would
10715 Loads must always use the frame pointer in functions that call
10721 *offset = frame->args_size - frame->hard_frame_pointer_offset;
10726 *offset = frame->args_size;
10826 of the frame. */
10834 offset = cfun->machine->frame.acc_sp_offset - sp_offset;
10835 if (BITSET_P (cfun->machine->frame.acc_mask, 0))
10844 if (BITSET_P (cfun->machine->frame.acc_mask,
10852 /* Save register REG to MEM. Make the instruction frame-related. */
10976 of the frame. */
10984 const struct mips_frame_info *frame = &cfun->machine->frame;
10992 offset = frame->gp_sp_offset - sp_offset;
10993 mask = frame->mask;
11003 cfun->machine->frame.ra_fp_offset = offset + sp_offset;
11010 offset = cfun->machine->frame.fp_sp_offset - sp_offset;
11015 if (BITSET_P (cfun->machine->frame.fmask, regno - FP_REG_FIRST))
11071 is specifically not frame-related; only the split version is. */
11148 /* Output MIPS-specific frame information. */
11151 const struct mips_frame_info *frame;
11153 frame = &cfun->machine->frame;
11155 /* .frame FRAMEREG, FRAMESIZE, RETREG. */
11157 "\t.frame\t%s," HOST_WIDE_INT_PRINT_DEC ",%s\t\t"
11166 ? frame->total_size - frame->hard_frame_pointer_offset
11167 : frame->total_size),
11169 frame->var_size,
11170 frame->num_gp, frame->num_fp,
11171 frame->args_size,
11172 frame->cprestore_size);
11176 frame->mask, frame->gp_save_offset);
11180 frame->fmask, frame->fp_save_offset);
11249 /* Emit an optimisation barrier for accesses to the current frame. */
11471 const struct mips_frame_info *frame;
11490 frame = &cfun->machine->frame;
11491 size = frame->total_size;
11511 if (((frame->mask | frame->fmask | frame->acc_mask) != 0)
11512 || frame->num_cop0_regs > 0)
11526 mask = frame->mask;
11567 /* Allocate the first part of the frame. */
11575 offset = frame->cop0_sp_offset - size;
11641 /* Allocate the rest of the frame. */
11654 from the stack pointer, so use the frame pointer as a
11655 temporary. We should always be using a frame pointer
11677 /* Set up the frame pointer, if we're using one. */
11682 offset = frame->hard_frame_pointer_offset;
11820 BASE + OFFSET is NEW_FRAME_SIZE bytes below the top of the frame.
11872 const struct mips_frame_info *frame;
11889 /* Split the frame into two. STEP1 is the amount of stack we should
11894 frame = &cfun->machine->frame;
11895 step1 = frame->total_size;
11898 /* Work out which register holds the frame address. */
11904 step1 -= frame->hard_frame_pointer_offset;
11912 if ((frame->mask | frame->fmask | frame->acc_mask) != 0
11913 || frame->num_cop0_regs > 0)
11935 if (GENERATE_MIPS16E_SAVE_RESTORE && frame->mask != 0)
11942 mask = frame->mask;
11954 of the frame. */
11962 mips_for_each_saved_acc (frame->total_size - step2, mips_restore_reg);
11963 mips_for_each_saved_gpr_and_fpr (frame->total_size - step2,
11971 offset = frame->cop0_sp_offset - (frame->total_size - step2);
12011 /* Deallocate the final bit of the frame. */
12056 && BITSET_P (frame->mask, RETURN_ADDR_REGNUM))
12118 return cfun->machine->frame.total_size == 0;
15497 /* Check for references to the stack frame. It doesn't really matter
15498 how much of the frame has been allocated at INSN; -mr10k-cache-barrier
15499 allows us to assume that accesses to any part of the eventual frame
15503 && offset_val >= -cfun->machine->frame.total_size
15504 && offset_val < cfun->machine->frame.args_size)
18624 if (cfun->machine->frame.ra_fp_offset == 0)
18630 cfun->machine->frame.ra_fp_offset,