Tue Sep 13 17:57:00 1994 Jeff Law (law@snake.cs.utah.edu)
+ * som.c (som_fixup_formats): Case R_ENTRY (0xb3), set both
+ 'T' and 'U' to grab all the unwind information.
+ (som_set_reloc_info): Make 'U' unwind bits persist across
+ multiple SOM relocations. Set the addend field of an R_ENTRY
+ relocation to the value in 'T'; set the addend field on an
+ R_EXIT relocation to the value in 'U'.
+
* som.h (som_symbol_type): Delete unwind field.
* som.c (som_write_fixups): For R_ENTRY fixups, get 32bits of
O = stack operation
R = parameter relocation bits
S = symbol index
- U = 64 bits of stack unwind and frame size info (we only keep 32 bits)
+ T = first 32 bits of stack unwind information
+ U = second 32 bits of stack unwind information
V = a literal constant (usually used in the next relocation)
P = a previous relocation
/* R_BREAKPOINT */
0, "L4=", /* 0xb2 */
/* R_ENTRY */
- 0, "Ui=", /* 0xb3 */
+ 0, "Te=Ue=", /* 0xb3 */
1, "Uf=", /* 0xb4 */
/* R_ALT_ENTRY */
0, "", /* 0xb5 */
const struct fixup_format *fp;
char *cp;
unsigned char *save_fixup;
- int variables[26], stack[20], c, v, count, prev_fixup, *sp;
+ int variables[26], stack[20], c, v, count, prev_fixup, *sp, saved_unwind_bits;
const int *subop;
arelent *rptr= internal_relocs;
unsigned int offset = 0;
memset (stack, 0, sizeof (stack));
count = 0;
prev_fixup = 0;
+ saved_unwind_bits = 0;
sp = stack;
while (fixup < end_fixups)
into D. */
var ('L') = 0;
var ('D') = fp->D;
+ var ('U') = saved_unwind_bits;
/* Get the opcode format. */
cp = fp->format;
++subop;
--subop;
break;
+ /* The lower 32unwind bits must be persistent. */
+ case 'U':
+ saved_unwind_bits = var ('U');
+ break;
+
default:
break;
}
/* Done with a single reloction. Loop back to the top. */
if (! just_count)
{
- rptr->addend = var ('V');
+ if (som_hppa_howto_table[op].type == R_ENTRY)
+ rptr->addend = var ('T');
+ else if (som_hppa_howto_table[op].type == R_EXIT)
+ rptr->addend = var ('U');
+ else
+ rptr->addend = var ('V');
rptr++;
}
count++;