mirror of
https://github.com/clearlinux/graphene.git
synced 2026-09-05 13:21:37 +00:00
[LibOS, Pal] add .file directive to .S file to make debug easier
gas includes dwarf info about compilation unit into .o compiled from .S. Hoever, without .file directive, gnu linker drops dwarf compilation unit info about .S. from .so (libpal.so libsysdb.so). As result gdb fails to open .S when debugging .S file. Add .file directive to .S files to make debug .S easier. My ld version is > $ ld --version > GNU ld (GNU Binutils for Ubuntu) 2.30 Signed-off-by: Isaku Yamahata <isaku.yamahata@gmail.com>
This commit is contained in:
@@ -16,6 +16,7 @@
|
||||
...
|
||||
NULL
|
||||
*/
|
||||
.file "start.S"
|
||||
.text
|
||||
.globl shim_start
|
||||
.type shim_start,@function
|
||||
|
||||
@@ -24,6 +24,7 @@
|
||||
|
||||
#include "asm-offsets.h"
|
||||
|
||||
.file "syscallas.S"
|
||||
.global syscalldb
|
||||
.type syscalldb, @function
|
||||
.extern shim_table, debug_unsupp
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
.file "vdso-data.S"
|
||||
.section .rodata
|
||||
|
||||
.global vdso_so
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
.file "vdso-note.S"
|
||||
/* This .note section informs dynamic linker about vDSO */
|
||||
.section .note.Linux, "a", @note
|
||||
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
#include "sgx_arch.h"
|
||||
#include "asm-offsets.h"
|
||||
|
||||
.file "enclave_entry.S"
|
||||
|
||||
# In some cases, like bogus parameters passed to enclave_entry, it's tricky to
|
||||
# return cleanly (passing the correct return address to EEXIT, OCALL_EXIT can
|
||||
# be interrupted, etc.). Since those cases should only ever happen with a
|
||||
|
||||
@@ -3,6 +3,8 @@
|
||||
|
||||
#include "asm-offsets.h"
|
||||
|
||||
.file "sgx_entry.S"
|
||||
|
||||
.extern tcs_base
|
||||
|
||||
.global sgx_ecall
|
||||
|
||||
@@ -30,6 +30,8 @@
|
||||
|
||||
#include "sysdep-x86_64.h"
|
||||
|
||||
.file "clone-x86_64.S"
|
||||
|
||||
#define CLONE_VM 0x00000100
|
||||
#define CLONE_THREAD 0x00010000
|
||||
|
||||
|
||||
@@ -26,6 +26,8 @@
|
||||
|
||||
#include "sysdep-x86_64.h"
|
||||
|
||||
.file "gettimeofday-x86_64.S"
|
||||
|
||||
/* For the calculation see asm/vsyscall.h. */
|
||||
#define VSYSCALL_ADDR_vgettimeofday 0xffffffffff600000
|
||||
|
||||
|
||||
@@ -17,6 +17,7 @@
|
||||
NULL
|
||||
*/
|
||||
|
||||
.file "user_start.S"
|
||||
.text
|
||||
.globl _start
|
||||
.type _start,@function
|
||||
|
||||
Reference in New Issue
Block a user