]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
(TRAMPOLINE_TEMPLATE): Add unwind info.
authorUlrich Drepper <drepper@redhat.com>
Fri, 5 Apr 2002 23:27:31 +0000 (23:27 +0000)
committerUlrich Drepper <drepper@redhat.com>
Fri, 5 Apr 2002 23:27:31 +0000 (23:27 +0000)
(RTLD_START): Ditto.
(__ia64_init_bootstrap_fdesc_table): Insert stop bit to avoid RAW
dependency violation.

sysdeps/ia64/dl-machine.h

index 2af418c1223757643986551645f929186db4a848..ed93ab61a667edb49ba034332185a33c74a6d2d7 100644 (file)
@@ -61,7 +61,7 @@ __ia64_init_bootstrap_fdesc_table (struct link_map *map)
   Elf64_Addr *boot_table;
 
   /* careful: this will be called before got has been relocated... */
-  asm ("addl %0 = @gprel (__ia64_boot_fptr_table), gp" : "=r"(boot_table));
+  asm (";; addl %0 = @gprel (__ia64_boot_fptr_table), gp" : "=r"(boot_table));
 
   map->l_mach.fptr_table_len = IA64_BOOT_FPTR_TABLE_LEN;
   map->l_mach.fptr_table = boot_table;
@@ -179,13 +179,18 @@ elf_machine_runtime_setup (struct link_map *l, int lazy, int profile)
 "      .proc " #tramp_name "#\n"                                            \
 #tramp_name ":\n"                                                           \
 "      { .mmi\n"                                                            \
+"        .prologue\n"                                                       \
+"        .save ar.pfs, r40\n"                                               \
 "        alloc loc0 = ar.pfs, 8, 6, 3, 0\n"                                 \
 "        adds r2 = -144, r12\n"                                             \
 "        adds r3 = -128, r12\n"                                             \
 "      }\n"                                                                 \
 "      { .mii\n"                                                            \
+"        .fframe 160\n"                                                     \
 "        adds r12 = -160, r12\n"                                            \
+"        .save rp, r41\n"                                                   \
 "        mov loc1 = b0\n"                                                   \
+"        .body\n"                                                           \
 "        mov out2 = b0         /* needed by fixup_profile */\n"             \
 "        ;;\n"                                                              \
 "      }\n"                                                                 \
@@ -249,6 +254,7 @@ elf_machine_runtime_setup (struct link_map *l, int lazy, int profile)
 "      { .mmi\n"                                                            \
 "        ldf.fill f14 = [r2], 32\n"                                         \
 "        ldf.fill f15 = [r3], 32\n"                                         \
+"        .restore sp           /* pop the unwind frame state */\n"          \
 "        adds r12 = 160, r12\n"                                             \
 "        ;;\n"                                                              \
 "      }\n"                                                                 \
@@ -265,6 +271,8 @@ elf_machine_runtime_setup (struct link_map *l, int lazy, int profile)
 "      /* An alloc is needed for the break system call to work.\n"          \
 "         We don't care about the old value of the pfs register.  */\n"     \
 "      { .mmb\n"                                                            \
+"        .prologue\n"                                                       \
+"        .body\n"                                                           \
 "        alloc r2 = ar.pfs, 0, 0, 8, 0\n"                                   \
 "        br.sptk.many b6\n"                                                 \
 "        ;;\n"                                                              \
@@ -292,7 +300,11 @@ elf_machine_runtime_setup (struct link_map *l, int lazy, int profile)
 "      .proc _start#\n"                                                      \
 "_start:\n"                                                                  \
 "0:    { .mii\n"                                                             \
+"        .prologue\n"                                                        \
+"        .save ar.pfs, r32\n"                                                \
+"        .save rp, r0\n"                                                     \
 "        alloc loc0 = ar.pfs, 0, 3, 4, 0\n"                                  \
+"        .body\n"                                                            \
 "        mov r2 = ip\n"                                                      \
 "        addl r3 = @gprel(0b), r0\n"                                         \
 "        ;;\n"                                                               \
@@ -319,6 +331,10 @@ elf_machine_runtime_setup (struct link_map *l, int lazy, int profile)
 "      .global _dl_start_user#\n"                                            \
 "      .proc _dl_start_user#\n"                                              \
 "_dl_start_user:\n"                                                          \
+"        .prologue\n"                                                        \
+"        .save ar.pfs, r32\n"                                                \
+"        .save rp, r0\n"                                                     \
+"        .body\n"                                                            \
 "      { .mii\n"                                                             \
 "        /* Save the pointer to the user entry point fptr in loc2.  */\n"    \
 "        mov loc2 = ret0\n"                                                  \