Date: Wed, 01 Jun 2011 14:19:27 +0000 From: xxp@FreeBSD.org To: svn-soc-all@FreeBSD.org Subject: socsvn commit: r222672 - in soc2011/xxp/xxp-head: lib/libc/i386/gen lib/libc/i386/string lib/libc/i386/sys sys/i386/include sys/sys Message-ID: <20110601141927.D2500106566C@hub.freebsd.org>
index | next in thread | raw e-mail
Author: xxp Date: Wed Jun 1 14:19:27 2011 New Revision: 222672 URL: http://svnweb.FreeBSD.org/socsvn/?view=rev&rev=222672 Log: Annotation to libc-i386 Modified: soc2011/xxp/xxp-head/lib/libc/i386/gen/_ctx_start.S soc2011/xxp/xxp-head/lib/libc/i386/gen/modf.S soc2011/xxp/xxp-head/lib/libc/i386/gen/rfork_thread.S soc2011/xxp/xxp-head/lib/libc/i386/gen/setjmp.S soc2011/xxp/xxp-head/lib/libc/i386/gen/sigsetjmp.S soc2011/xxp/xxp-head/lib/libc/i386/string/bcmp.S soc2011/xxp/xxp-head/lib/libc/i386/string/bcopy.S soc2011/xxp/xxp-head/lib/libc/i386/string/bzero.S soc2011/xxp/xxp-head/lib/libc/i386/string/index.S soc2011/xxp/xxp-head/lib/libc/i386/string/memchr.S soc2011/xxp/xxp-head/lib/libc/i386/string/memset.S soc2011/xxp/xxp-head/lib/libc/i386/string/rindex.S soc2011/xxp/xxp-head/lib/libc/i386/string/strcat.S soc2011/xxp/xxp-head/lib/libc/i386/string/strchr.S soc2011/xxp/xxp-head/lib/libc/i386/string/strcpy.S soc2011/xxp/xxp-head/lib/libc/i386/string/strncmp.S soc2011/xxp/xxp-head/lib/libc/i386/string/strrchr.S soc2011/xxp/xxp-head/lib/libc/i386/string/swab.S soc2011/xxp/xxp-head/lib/libc/i386/string/wcschr.S soc2011/xxp/xxp-head/lib/libc/i386/string/wcscmp.S soc2011/xxp/xxp-head/lib/libc/i386/string/wmemchr.S soc2011/xxp/xxp-head/lib/libc/i386/sys/Ovfork.S soc2011/xxp/xxp-head/lib/libc/i386/sys/cerror.S soc2011/xxp/xxp-head/lib/libc/i386/sys/exect.S soc2011/xxp/xxp-head/lib/libc/i386/sys/getcontext.S soc2011/xxp/xxp-head/lib/libc/i386/sys/setlogin.S soc2011/xxp/xxp-head/lib/libc/i386/sys/syscall.S soc2011/xxp/xxp-head/sys/i386/include/asm.h soc2011/xxp/xxp-head/sys/sys/cdefs.h Modified: soc2011/xxp/xxp-head/lib/libc/i386/gen/_ctx_start.S ============================================================================== --- soc2011/xxp/xxp-head/lib/libc/i386/gen/_ctx_start.S Wed Jun 1 13:15:24 2011 (r222671) +++ soc2011/xxp/xxp-head/lib/libc/i386/gen/_ctx_start.S Wed Jun 1 14:19:27 2011 (r222672) @@ -40,12 +40,14 @@ */ ENTRY(_ctx_start) popl %eax /* get start function */ + cfi_adjust_cfa_offset(-4) call *%eax /* call start function */ PIC_PROLOGUE movl %esi, %esp /* * setup stack for completion routine; * ucp is now at top of stack */ + cfi_register(%esi,%esp) call PIC_PLT(_ctx_done) /* should never return */ call PIC_PLT(abort) /* fubar */ ret Modified: soc2011/xxp/xxp-head/lib/libc/i386/gen/modf.S ============================================================================== --- soc2011/xxp/xxp-head/lib/libc/i386/gen/modf.S Wed Jun 1 13:15:24 2011 (r222671) +++ soc2011/xxp/xxp-head/lib/libc/i386/gen/modf.S Wed Jun 1 14:19:27 2011 (r222672) @@ -48,7 +48,10 @@ ENTRY(modf) pushl %ebp + cfi_adjust_cfa_offset(4) + cfi_offset(%ebp,-8) movl %esp,%ebp + cfi_register(%esp,%ebp) /* Check for Inf/NaN */ movl 12(%ebp),%eax andl $0x7fffffff,%eax @@ -56,6 +59,7 @@ jae 1f /* Finite value */ subl $16,%esp + cfi_adjust_cfa_offset(16) fnstcw -12(%ebp) movw -12(%ebp),%dx orw $3072,%dx Modified: soc2011/xxp/xxp-head/lib/libc/i386/gen/rfork_thread.S ============================================================================== --- soc2011/xxp/xxp-head/lib/libc/i386/gen/rfork_thread.S Wed Jun 1 13:15:24 2011 (r222671) +++ soc2011/xxp/xxp-head/lib/libc/i386/gen/rfork_thread.S Wed Jun 1 14:19:27 2011 (r222672) @@ -45,8 +45,13 @@ ENTRY(rfork_thread) pushl %ebp + cfi_adjust_cfa_offset(4) + cfi_offset(%ebp,-8) movl %esp, %ebp + cif_register(%esp,%ebp) pushl %esi + cfi_adjust_cfa_offset(4) + cfi_offset(%ebp,-12) /* * Push thread info onto the new thread's stack @@ -65,7 +70,9 @@ * Prepare and execute the thread creation syscall */ pushl 8(%ebp) + cfi_adjust_cfa_offset(4) pushl $0 + cfi_adjust_cfa_offset(4) movl $SYS_rfork, %eax KERNCALL jb 2f @@ -76,9 +83,14 @@ cmpl $0, %edx jnz 1f addl $8, %esp + cfi_adjust_cfa_offset(-8) popl %esi + cfi_adjust_cfa_offset(4) + cfi_restore(%esi) movl %ebp, %esp + cfi_offset(%ebp,%esp) popl %ebp + cfi_adjust_cfa_offset(-4) ret .p2align 2 @@ -89,15 +101,20 @@ */ 1: movl %esi,%esp + cfi_offset(%esi,%esp) popl %eax + cfi_adjust_cfa_offset(-4) call *%eax addl $4, %esp + cfi_adjust_cfa_offset(-4) /* * Exit system call */ pushl %eax + cfi_adjust_cfa_offset(4) pushl $0 + cfi_adjust_cfa_offset(4) #ifdef SYS_exit movl $SYS_exit, %eax #else @@ -110,9 +127,13 @@ */ 2: addl $8, %esp + cfi_adjust_cfa_offset(-8) popl %esi + cfi_adjust_cfa_offset(-4) movl %ebp, %esp + cfi_register(%ebp, %esp) popl %ebp + cfi_adjust_cfa_offset(-4) PIC_PROLOGUE jmp PIC_PLT(HIDENAME(cerror)) END(rfork_thread) Modified: soc2011/xxp/xxp-head/lib/libc/i386/gen/setjmp.S ============================================================================== --- soc2011/xxp/xxp-head/lib/libc/i386/gen/setjmp.S Wed Jun 1 13:15:24 2011 (r222671) +++ soc2011/xxp/xxp-head/lib/libc/i386/gen/setjmp.S Wed Jun 1 14:19:27 2011 (r222672) @@ -53,10 +53,15 @@ PIC_PROLOGUE leal 28(%ecx), %eax pushl %eax /* (sigset_t*)oset */ + cfi_adjust_cfa_offset(4) + cfi_offset(%eax,-8) pushl $0 /* (sigset_t*)set */ + cfi_adjust_cfa_offset(4) pushl $1 /* SIG_BLOCK */ + cfi_adjust_cfa_offset(4) call PIC_PLT(CNAME(_sigprocmask)) addl $12,%esp + cfi_adjust_cfa_offset(-12) PIC_EPILOGUE movl 4(%esp),%ecx movl 0(%esp),%edx @@ -77,11 +82,16 @@ movl 4(%esp),%edx PIC_PROLOGUE pushl $0 /* (sigset_t*)oset */ + cfi_adjust_cfa_offset(4) leal 28(%edx), %eax pushl %eax /* (sigset_t*)set */ + cfi_adjust_cfa_offset(4) + cfi_offset(%eax,-8) pushl $3 /* SIG_SETMASK */ + cfi_adjust_cfa_offset(4) call PIC_PLT(CNAME(_sigprocmask)) addl $12,%esp + cfi_adjust_cfa_offset(-12) PIC_EPILOGUE movl 4(%esp),%edx movl 8(%esp),%eax Modified: soc2011/xxp/xxp-head/lib/libc/i386/gen/sigsetjmp.S ============================================================================== --- soc2011/xxp/xxp-head/lib/libc/i386/gen/sigsetjmp.S Wed Jun 1 13:15:24 2011 (r222671) +++ soc2011/xxp/xxp-head/lib/libc/i386/gen/sigsetjmp.S Wed Jun 1 14:19:27 2011 (r222672) @@ -62,10 +62,15 @@ PIC_PROLOGUE leal 28(%ecx), %eax pushl %eax /* (sigset_t*)oset */ + cfi_adjust_cfa_offset(4) + cfi_offset(%eax,-8) pushl $0 /* (sigset_t*)set */ + cfi_adjust_cfa_offset(4) pushl $1 /* SIG_BLOCK */ + cfi_adjust_cfa_offset(4) call PIC_PLT(CNAME(_sigprocmask)) addl $12,%esp + cfi_adjust_cfa_offset(-12) PIC_EPILOGUE movl 4(%esp),%ecx 2: movl 0(%esp),%edx @@ -88,11 +93,16 @@ jz 2f PIC_PROLOGUE pushl $0 /* (sigset_t*)oset */ + cfi_adjust_cfa_offset(4) leal 28(%edx), %eax pushl %eax /* (sigset_t*)set */ + cfi_adjust_cfa_offset(4) + cfi_offset(%eax,-12) pushl $3 /* SIG_SETMASK */ + cfi_adjust_cfa_offset(4) call PIC_PLT(CNAME(_sigprocmask)) addl $12,%esp + cfi_adjust_cfa_offset(-12) PIC_EPILOGUE movl 4(%esp),%edx 2: movl 8(%esp),%eax Modified: soc2011/xxp/xxp-head/lib/libc/i386/string/bcmp.S ============================================================================== --- soc2011/xxp/xxp-head/lib/libc/i386/string/bcmp.S Wed Jun 1 13:15:24 2011 (r222671) +++ soc2011/xxp/xxp-head/lib/libc/i386/string/bcmp.S Wed Jun 1 14:19:27 2011 (r222672) @@ -40,7 +40,11 @@ ENTRY(bcmp) pushl %edi + cfi_adjust_cfa_offset(4) + cfi_offset(%edi,-8) pushl %esi + cfi_offset(%esi,-12) + cfi_adjust_cfa_offset(4) movl 12(%esp),%edi movl 16(%esp),%esi cld /* set compare direction forward */ @@ -59,7 +63,11 @@ setne %al movsbl %al,%eax popl %esi + cfi_adjust_cfa_offset(-4) + cfi_restore(%esi) popl %edi + cfi_adjust_cfa_offset(-4) + cfi_restore(%edi) ret END(bcmp) Modified: soc2011/xxp/xxp-head/lib/libc/i386/string/bcopy.S ============================================================================== --- soc2011/xxp/xxp-head/lib/libc/i386/string/bcopy.S Wed Jun 1 13:15:24 2011 (r222671) +++ soc2011/xxp/xxp-head/lib/libc/i386/string/bcopy.S Wed Jun 1 14:19:27 2011 (r222672) @@ -51,7 +51,11 @@ #endif #endif pushl %esi + cfi_adjust_cfa_offset(4) + cfi_offset(%esi,-8) pushl %edi + cfi_adjust_cfa_offset(4) + cfi_offset(%esi,-12) #if defined(MEMCOPY) || defined(MEMMOVE) movl 12(%esp),%edi movl 16(%esp),%esi @@ -75,7 +79,9 @@ rep movsb popl %edi + cfi_adjust_cfa_offset(-4) popl %esi + cfi_adjust_cfa_offset(-4) ret 1: addl %ecx,%edi /* copy backwards. */ @@ -94,7 +100,11 @@ rep movsl popl %edi + cfi_adjust_cfa_offset(-4) + cfi_restore(%edi) popl %esi + cfi_restore(%esi) + cfi_adjust_cfa_offset(-4) cld ret #ifdef MEMCOPY Modified: soc2011/xxp/xxp-head/lib/libc/i386/string/bzero.S ============================================================================== --- soc2011/xxp/xxp-head/lib/libc/i386/string/bzero.S Wed Jun 1 13:15:24 2011 (r222671) +++ soc2011/xxp/xxp-head/lib/libc/i386/string/bzero.S Wed Jun 1 14:19:27 2011 (r222672) @@ -41,7 +41,11 @@ ENTRY(bzero) pushl %edi + cfi_adjust_cfa_offset(4) + cfi_offset(%edi,-8) pushl %ebx + cfi_adjust_cfa_offset(4) + cfi_offset(%edi,-12) movl 12(%esp),%edi movl 16(%esp),%ecx @@ -77,7 +81,11 @@ stosb popl %ebx + cfi_adjust_cfa_offset(-4) + cfi_restore(%ebx) popl %edi + cfi_adjust_cfa_offset(-4) + cfi_restore(%edi) ret END(bzero) Modified: soc2011/xxp/xxp-head/lib/libc/i386/string/index.S ============================================================================== --- soc2011/xxp/xxp-head/lib/libc/i386/string/index.S Wed Jun 1 13:15:24 2011 (r222671) +++ soc2011/xxp/xxp-head/lib/libc/i386/string/index.S Wed Jun 1 14:19:27 2011 (r222672) @@ -47,6 +47,8 @@ ENTRY(index) pushl %ebx + cfi_adjust_cfa_offset(4) + cfi_offset(%ebx,-8) movl 8(%esp),%eax movb 12(%esp),%cl .align 2,0x90 @@ -60,6 +62,8 @@ xorl %eax,%eax L2: popl %ebx + cfi_adjust_cfa_offset(-4) + cfi_restore(%ebx) ret END(index) Modified: soc2011/xxp/xxp-head/lib/libc/i386/string/memchr.S ============================================================================== --- soc2011/xxp/xxp-head/lib/libc/i386/string/memchr.S Wed Jun 1 13:15:24 2011 (r222671) +++ soc2011/xxp/xxp-head/lib/libc/i386/string/memchr.S Wed Jun 1 14:19:27 2011 (r222672) @@ -41,6 +41,8 @@ ENTRY(memchr) pushl %edi + cfi_adjust_cfa_offset(4) + cfi_offset(%edi,-8) movl 8(%esp),%edi /* string address */ movl 12(%esp),%eax /* set character to search for */ movl 16(%esp),%ecx /* set length of search */ @@ -55,6 +57,8 @@ .align 2,0x90 L1: xorl %eax,%eax popl %edi + cfi_adjust_cfa_offset(-4) + cfi_restore(%edi) ret END(memchr) Modified: soc2011/xxp/xxp-head/lib/libc/i386/string/memset.S ============================================================================== --- soc2011/xxp/xxp-head/lib/libc/i386/string/memset.S Wed Jun 1 13:15:24 2011 (r222671) +++ soc2011/xxp/xxp-head/lib/libc/i386/string/memset.S Wed Jun 1 14:19:27 2011 (r222672) @@ -42,11 +42,17 @@ ENTRY(memset) pushl %edi + cfi_adjust_cfa_offset(4) + cfi_offset(%edi,-8) pushl %ebx + cfi_adjust_cfa_offset(4) + cfi_offset(%edi,-12) movl 12(%esp),%edi movzbl 16(%esp),%eax /* unsigned char, zero extend */ movl 20(%esp),%ecx pushl %edi /* push address of buffer */ + cfi_adjust_cfa_offset(4) + cfi_offset(%edi,-16) cld /* set fill direction forward */ @@ -84,8 +90,13 @@ stosb popl %eax /* pop address of buffer */ + cfi_adjust_cfa_offset(-4) popl %ebx + cfi_adjust_cfa_offset(-4) + cfi_restore(%ebx) popl %edi + cfi_adjust_cfa_offset(-4) + cfi_restore(%edi) ret END(memset) Modified: soc2011/xxp/xxp-head/lib/libc/i386/string/rindex.S ============================================================================== --- soc2011/xxp/xxp-head/lib/libc/i386/string/rindex.S Wed Jun 1 13:15:24 2011 (r222671) +++ soc2011/xxp/xxp-head/lib/libc/i386/string/rindex.S Wed Jun 1 14:19:27 2011 (r222672) @@ -47,6 +47,8 @@ ENTRY(rindex) pushl %ebx + cfi_adjust_cfa_offset(4) + cfi_offset(%ebx,-8) movl 8(%esp),%edx movb 12(%esp),%cl xorl %eax,%eax /* init pointer to null */ @@ -61,6 +63,8 @@ testb %bl,%bl /* null terminator??? */ jne L1 popl %ebx + cfi_adjust_cfa_offset(-4) + cfi_restore(%ebx) ret END(rindex) Modified: soc2011/xxp/xxp-head/lib/libc/i386/string/strcat.S ============================================================================== --- soc2011/xxp/xxp-head/lib/libc/i386/string/strcat.S Wed Jun 1 13:15:24 2011 (r222671) +++ soc2011/xxp/xxp-head/lib/libc/i386/string/strcat.S Wed Jun 1 14:19:27 2011 (r222672) @@ -48,9 +48,13 @@ ENTRY(strcat) pushl %edi /* save edi */ + cfi_adjust_cfa_offset(4) + cfi_offset(%edi,-8) movl 8(%esp),%edi /* dst address */ movl 12(%esp),%edx /* src address */ pushl %edi /* push destination address */ + cfi_adjust_cfa_offset(4) + cfi_offset(%edi,-12) cld /* set search forward */ xorl %eax,%eax /* set search for null terminator */ @@ -96,7 +100,10 @@ testb %al,%al jne L1 L2: popl %eax /* pop destination address */ + cfi_adjust_cfa_offset(-4) popl %edi /* restore edi */ + cfi_adjust_cfa_offset(-4) + cfi_restore(%edi) ret END(strcat) Modified: soc2011/xxp/xxp-head/lib/libc/i386/string/strchr.S ============================================================================== --- soc2011/xxp/xxp-head/lib/libc/i386/string/strchr.S Wed Jun 1 13:15:24 2011 (r222671) +++ soc2011/xxp/xxp-head/lib/libc/i386/string/strchr.S Wed Jun 1 14:19:27 2011 (r222672) @@ -47,6 +47,8 @@ ENTRY(strchr) pushl %ebx + cfi_adjust_cfa_offset(4) + cfi_offset(%ebx,-8) movl 8(%esp),%eax movb 12(%esp),%cl .align 2,0x90 @@ -60,6 +62,8 @@ xorl %eax,%eax L2: popl %ebx + cfi_adjust_cfa_offset(-4) + cfi_restore(%ebx) ret END(strchr) Modified: soc2011/xxp/xxp-head/lib/libc/i386/string/strcpy.S ============================================================================== --- soc2011/xxp/xxp-head/lib/libc/i386/string/strcpy.S Wed Jun 1 13:15:24 2011 (r222671) +++ soc2011/xxp/xxp-head/lib/libc/i386/string/strcpy.S Wed Jun 1 14:19:27 2011 (r222672) @@ -49,6 +49,8 @@ movl 4(%esp),%ecx /* dst address */ movl 8(%esp),%edx /* src address */ pushl %ecx /* push dst address */ + cfi_adjust_cfa_offset(4) + cfi_offset(%ecx,-8) .align 2,0x90 L1: movb (%edx),%al /* unroll loop, but not too much */ @@ -86,6 +88,8 @@ testb %al,%al jne L1 L2: popl %eax /* pop dst address */ + cfi_adjust_cfa_offset(-4) + cfi_restore(%eax) ret END(strcpy) Modified: soc2011/xxp/xxp-head/lib/libc/i386/string/strncmp.S ============================================================================== --- soc2011/xxp/xxp-head/lib/libc/i386/string/strncmp.S Wed Jun 1 13:15:24 2011 (r222671) +++ soc2011/xxp/xxp-head/lib/libc/i386/string/strncmp.S Wed Jun 1 14:19:27 2011 (r222672) @@ -55,6 +55,8 @@ ENTRY(strncmp) pushl %ebx + cfi_adjust_cfa_offset(4) + cfi_offset(%ebx,-8) movl 8(%esp),%eax movl 12(%esp),%ecx movl 16(%esp),%edx @@ -159,10 +161,14 @@ movzbl (%ecx),%ecx subl %ecx,%eax popl %ebx + cfi_adjust_cfa_offset(-4) + cfi_restore(%ebx) ret .align 2,0x90 L4: xorl %eax,%eax popl %ebx + cfi_adjust_cfa_offset(-4) + cfi_restore(%ebx) ret END(strncmp) Modified: soc2011/xxp/xxp-head/lib/libc/i386/string/strrchr.S ============================================================================== --- soc2011/xxp/xxp-head/lib/libc/i386/string/strrchr.S Wed Jun 1 13:15:24 2011 (r222671) +++ soc2011/xxp/xxp-head/lib/libc/i386/string/strrchr.S Wed Jun 1 14:19:27 2011 (r222672) @@ -47,6 +47,8 @@ ENTRY(strrchr) pushl %ebx + cfi_adjust_cfa_offset(4) + cfi_offset(%ebx,-8) movl 8(%esp),%edx movb 12(%esp),%cl xorl %eax,%eax /* init pointer to null */ @@ -61,6 +63,8 @@ testb %bl,%bl /* null terminator??? */ jne L1 popl %ebx + cfi_adjust_cfa_offset(-4) + cfi_restore(%ebx) ret END(strrchr) Modified: soc2011/xxp/xxp-head/lib/libc/i386/string/swab.S ============================================================================== --- soc2011/xxp/xxp-head/lib/libc/i386/string/swab.S Wed Jun 1 13:15:24 2011 (r222671) +++ soc2011/xxp/xxp-head/lib/libc/i386/string/swab.S Wed Jun 1 14:19:27 2011 (r222672) @@ -46,7 +46,11 @@ ENTRY(swab) pushl %esi + cfi_adjust_cfa_offset(4) + cfi_offset(%esi,-8) pushl %edi + cfi_adjust_cfa_offset(4) + cfi_offset(%edi,-12) movl 12(%esp),%esi movl 16(%esp),%edi movl 20(%esp),%ecx @@ -95,7 +99,11 @@ jnz L3 L4: popl %edi + cfi_adjust_cfa_offset(-4) + cfi_restore(%edi) popl %esi + cfi_adjust_cfa_offset(-4) + cfi_restore(%esi) ret END(swab) Modified: soc2011/xxp/xxp-head/lib/libc/i386/string/wcschr.S ============================================================================== --- soc2011/xxp/xxp-head/lib/libc/i386/string/wcschr.S Wed Jun 1 13:15:24 2011 (r222671) +++ soc2011/xxp/xxp-head/lib/libc/i386/string/wcschr.S Wed Jun 1 14:19:27 2011 (r222672) @@ -37,6 +37,8 @@ movl 4(%esp),%ecx /* String */ movl 8(%esp),%eax /* Character */ pushl %ebx + cfi_adjust_cfa_offset(4) + cfi_offset(%ebx,-8) .p2align 4,0x90 L1: movl (%ecx),%ebx cmpl %eax,%ebx @@ -68,10 +70,14 @@ found1: leal 4(%ecx),%ecx .p2align 2,0x90 found0: popl %ebx + cfi_adjust_cfa_offset(-4) + cfi_restore(%ebx) movl %ecx,%eax ret .p2align 2,0x90 no: popl %ebx + cfi_adjust_cfa_offset(-4) + cfi_restore(%ebx) xorl %eax,%eax ret END(wcschr) Modified: soc2011/xxp/xxp-head/lib/libc/i386/string/wcscmp.S ============================================================================== --- soc2011/xxp/xxp-head/lib/libc/i386/string/wcscmp.S Wed Jun 1 13:15:24 2011 (r222671) +++ soc2011/xxp/xxp-head/lib/libc/i386/string/wcscmp.S Wed Jun 1 14:19:27 2011 (r222672) @@ -35,7 +35,11 @@ */ ENTRY(wcscmp) pushl %edi + cfi_adjust_cfa_offset(4) + cfi_offset(%edi,-8) pushl %esi + cfi_adjust_cfa_offset(4) + cfi_offset(%esi,-12) movl 12(%esp),%edi /* s1 */ movl 16(%esp),%esi /* s2 */ .p2align 4,0x90 @@ -64,7 +68,11 @@ .p2align 2,0x90 same: xorl %eax,%eax popl %esi + cfi_adjust_cfa_offset(-4) + cfi_restore(%esi) popl %edi + cfi_adjust_cfa_offset(-4) + cfi_restore(%edi) ret .p2align 2,0x90 no12: leal 4(%esi),%esi @@ -75,7 +83,11 @@ .p2align 2,0x90 no0: subl (%esi),%eax popl %esi + cfi_adjust_cfa_offset(-4) + cfi_restore(%esi) popl %edi + cfi_adjust_cfa_offset(-4) + cfi_restore(%edi) ret END(wcscmp) Modified: soc2011/xxp/xxp-head/lib/libc/i386/string/wmemchr.S ============================================================================== --- soc2011/xxp/xxp-head/lib/libc/i386/string/wmemchr.S Wed Jun 1 13:15:24 2011 (r222671) +++ soc2011/xxp/xxp-head/lib/libc/i386/string/wmemchr.S Wed Jun 1 14:19:27 2011 (r222672) @@ -36,7 +36,11 @@ */ ENTRY(wmemchr) pushl %edi + cfi_adjust_cfa_offset(4) + cfi_offset(%edi,-8) pushl %ebx + cfi_adjust_cfa_offset(4) + cfi_offset(%ebx,-12) movl 12(%esp),%edi /* Buffer */ movl 16(%esp),%eax /* Wide character */ movl 20(%esp),%ecx /* Length of buffer */ @@ -101,7 +105,11 @@ jnz smltop no: xorl %eax,%eax popl %ebx + cfi_adjust_cfa_offset(-4) + cfi_restore(%ebx) popl %edi + cfi_adjust_cfa_offset(-4) + cfi_restore(%edi) ret END(wmemchr) Modified: soc2011/xxp/xxp-head/lib/libc/i386/sys/Ovfork.S ============================================================================== --- soc2011/xxp/xxp-head/lib/libc/i386/sys/Ovfork.S Wed Jun 1 13:15:24 2011 (r222671) +++ soc2011/xxp/xxp-head/lib/libc/i386/sys/Ovfork.S Wed Jun 1 14:19:27 2011 (r222672) @@ -44,12 +44,14 @@ .set vfork,__sys_vfork ENTRY(__sys_vfork) popl %ecx /* my rta into ecx */ + cfi_adjust_cfa_offset(-4) mov $SYS_vfork,%eax KERNCALL jb 1f jmp *%ecx 1: pushl %ecx + cfi_adjust_cfa_offset(4) PIC_PROLOGUE jmp PIC_PLT(HIDENAME(cerror)) END(__sys_vfork) Modified: soc2011/xxp/xxp-head/lib/libc/i386/sys/cerror.S ============================================================================== --- soc2011/xxp/xxp-head/lib/libc/i386/sys/cerror.S Wed Jun 1 13:15:24 2011 (r222671) +++ soc2011/xxp/xxp-head/lib/libc/i386/sys/cerror.S Wed Jun 1 14:19:27 2011 (r222672) @@ -49,14 +49,17 @@ .type CNAME(__error),@function HIDENAME(cerror): pushl %eax + cfi_adjust_cfa_offset(4) #ifdef PIC /* The caller must execute the PIC prologue before jumping to cerror. */ call PIC_PLT(CNAME(__error)) popl %ecx + cfi_adjust_cfa_offset(-4) PIC_EPILOGUE #else call CNAME(__error) popl %ecx + cfi_adjust_cfa_offset(-4) #endif movl %ecx,(%eax) movl $-1,%eax Modified: soc2011/xxp/xxp-head/lib/libc/i386/sys/exect.S ============================================================================== --- soc2011/xxp/xxp-head/lib/libc/i386/sys/exect.S Wed Jun 1 13:15:24 2011 (r222671) +++ soc2011/xxp/xxp-head/lib/libc/i386/sys/exect.S Wed Jun 1 14:19:27 2011 (r222672) @@ -42,10 +42,14 @@ ENTRY(exect) mov $SYS_execve,%eax pushf + cfi_adjust_cfa_offset(2) popl %edx + cfi_adjust_cfa_offset(-4) orl $ PSL_T,%edx pushl %edx + cfi_adjust_cfa_offset(4) popf + cfi_adjust_cfa_offset(-2) KERNCALL PIC_PROLOGUE jmp PIC_PLT(HIDENAME(cerror)) /* exect(file, argv, env); */ Modified: soc2011/xxp/xxp-head/lib/libc/i386/sys/getcontext.S ============================================================================== --- soc2011/xxp/xxp-head/lib/libc/i386/sys/getcontext.S Wed Jun 1 13:15:24 2011 (r222671) +++ soc2011/xxp/xxp-head/lib/libc/i386/sys/getcontext.S Wed Jun 1 14:19:27 2011 (r222672) @@ -44,6 +44,7 @@ KERNCALL jb 1f addl $4,%esp /* remove stale (setcontext) return address */ + cfi_adjust_cfa_offset(-4) jmp *%ecx /* restore return address */ 1: PIC_PROLOGUE Modified: soc2011/xxp/xxp-head/lib/libc/i386/sys/setlogin.S ============================================================================== --- soc2011/xxp/xxp-head/lib/libc/i386/sys/setlogin.S Wed Jun 1 13:15:24 2011 (r222671) +++ soc2011/xxp/xxp-head/lib/libc/i386/sys/setlogin.S Wed Jun 1 14:19:27 2011 (r222672) @@ -44,9 +44,11 @@ #ifdef PIC PIC_PROLOGUE pushl %eax + cfi_adjust_cfa_offset(4) movl PIC_GOT(CNAME(_logname_valid)),%eax movl $0,(%eax) popl %eax + cfi_adjust_cfa_offset(-4) PIC_EPILOGUE #else movl $0,CNAME(_logname_valid) Modified: soc2011/xxp/xxp-head/lib/libc/i386/sys/syscall.S ============================================================================== --- soc2011/xxp/xxp-head/lib/libc/i386/sys/syscall.S Wed Jun 1 13:15:24 2011 (r222671) +++ soc2011/xxp/xxp-head/lib/libc/i386/sys/syscall.S Wed Jun 1 14:19:27 2011 (r222672) @@ -40,11 +40,15 @@ ENTRY(syscall) pop %ecx /* rta */ + cfi_adjust_cfa_offset(-4) pop %eax /* syscall number */ + cfi_adjust_cfa_offset(-4) push %ecx + cfi_adjust_cfa_offset(4) KERNCALL push %ecx /* need to push a word to keep stack frame intact upon return; the word must be the return address. */ + cfi_adjust_cfa_offset(4) jb 1f ret 1: Modified: soc2011/xxp/xxp-head/sys/i386/include/asm.h ============================================================================== --- soc2011/xxp/xxp-head/sys/i386/include/asm.h Wed Jun 1 13:15:24 2011 (r222671) +++ soc2011/xxp/xxp-head/sys/i386/include/asm.h Wed Jun 1 14:19:27 2011 (r222672) @@ -41,12 +41,15 @@ #ifdef PIC #define PIC_PROLOGUE \ pushl %ebx; \ + cfi_adjust_cfa_offset(4); \ call 1f; \ 1: \ popl %ebx; \ + cfi_adjust_cfa_offset(-4); \ addl $_GLOBAL_OFFSET_TABLE_+[.-1b],%ebx #define PIC_EPILOGUE \ - popl %ebx + popl %ebx \ + cfi_adjust_cfa_offset(-4); \ #define PIC_PLT(x) x@PLT #define PIC_GOT(x) x@GOT(%ebx) #else @@ -70,19 +73,29 @@ #define _START_ENTRY .text; .p2align 2,0x90 #define _ENTRY(x) _START_ENTRY; \ - .globl CNAME(x); .type CNAME(x),@function; CNAME(x): -#define END(x) .size x, . - x + .globl CNAME(x); .type CNAME(x),@function; CNAME(x):; \ + cfi_startproc; +#define END(x) cfi_endproc; \ + .size x, . - x #ifdef PROF #define ALTENTRY(x) _ENTRY(x); \ - pushl %ebp; movl %esp,%ebp; \ + pushl %ebp; \ + cfi_adjust_cfa_offset(4); cfi_offset(%ebp,-4); \ + movl %esp,%ebp; \ + cfi_register(%esp,%ebp); \ call PIC_PLT(HIDENAME(mcount)); \ popl %ebp; \ + cfi_def_cfa(%esp,4); cfi_restore(%ebp); \ jmp 9f #define ENTRY(x) _ENTRY(x); \ - pushl %ebp; movl %esp,%ebp; \ + pushl %ebp; \ + cfi_adjust_cfa_offset(4); cfi_offset(%ebp,-4); \ + movl %esp,%ebp; \ + cfi_register(%esp,%ebp); cfi_def_cfa_register(%ebp); \ call PIC_PLT(HIDENAME(mcount)); \ popl %ebp; \ + cfi_def_cfa(%esp,4); cfi_restore(%ebp); \ 9: #else #define ALTENTRY(x) _ENTRY(x) Modified: soc2011/xxp/xxp-head/sys/sys/cdefs.h ============================================================================== --- soc2011/xxp/xxp-head/sys/sys/cdefs.h Wed Jun 1 13:15:24 2011 (r222671) +++ soc2011/xxp/xxp-head/sys/sys/cdefs.h Wed Jun 1 14:19:27 2011 (r222672) @@ -574,4 +574,22 @@ #endif #endif +/* Macros to generate eh_frame unwind information. */ +# define cfi_startproc .cfi_startproc +# define cfi_endproc .cfi_endproc +# define cfi_def_cfa(reg, off) .cfi_def_cfa reg, off +# define cfi_def_cfa_register(reg) .cfi_def_cfa_register reg +# define cfi_def_cfa_offset(off) .cfi_def_cfa_offset off +# define cfi_adjust_cfa_offset(off) .cfi_adjust_cfa_offset off +# define cfi_offset(reg, off) .cfi_offset reg, off +# define cfi_rel_offset(reg, off) .cfi_rel_offset reg, off +# define cfi_register(r1, r2) .cfi_register r1, r2 +# define cfi_return_column(reg) .cfi_return_column reg +# define cfi_restore(reg) .cfi_restore reg +# define cfi_same_value(reg) .cfi_same_value reg +# define cfi_undefined(reg) .cfi_undefined reg +# define cfi_remember_state .cfi_remember_state +# define cfi_restore_state .cfi_restore_state +# define cfi_window_save .cfi_window_save + #endif /* !_SYS_CDEFS_H_ */help
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20110601141927.D2500106566C>
