diff options
author | Mike Frysinger <vapier@gentoo.org> | 2006-05-15 22:49:35 +0000 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2006-05-15 22:49:35 +0000 |
commit | 569755ce4e6db9ce7b3de5d2256a1cb68b9b43f3 (patch) | |
tree | 99b8701d8046c4c60d5a6307968582c67978e9dc /libc/sysdeps/linux/bfin/crti.S | |
parent | 7ebb2e4369d611641b67a2f15265742c73b1d8f3 (diff) |
updates from Bernd Schmidt to sync with blackfin cvs
Diffstat (limited to 'libc/sysdeps/linux/bfin/crti.S')
-rw-r--r-- | libc/sysdeps/linux/bfin/crti.S | 73 |
1 files changed, 59 insertions, 14 deletions
diff --git a/libc/sysdeps/linux/bfin/crti.S b/libc/sysdeps/linux/bfin/crti.S index 56b268a28..7c10392d8 100644 --- a/libc/sysdeps/linux/bfin/crti.S +++ b/libc/sysdeps/linux/bfin/crti.S @@ -1,17 +1,62 @@ - .section .init - .section .fini +/* Specialized code needed to support construction and destruction of + file-scope objects in C++ and Java code, and to support exception handling. + Copyright (C) 1999 Free Software Foundation, Inc. + Contributed by Charles-Antoine Gauthier (charles.gauthier@iit.nrc.ca). -.text; -.align 2 -.global __init; -.type __init, STT_FUNC; -__init: - LINK 0; - SP += -12; +This file is part of GCC. + +GCC is free software; you can redistribute it and/or modify +it under the terms of the GNU General Public License as published by +the Free Software Foundation; either version 2, or (at your option) +any later version. + +GCC is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with GCC; see the file COPYING. If not, write to +the Free Software Foundation, 59 Temple Place - Suite 330, +Boston, MA 02111-1307, USA. */ -.align 2 -.global __fini; -.type __fini, STT_FUNC; +/* As a special exception, if you link this library with files + compiled with GCC to produce an executable, this does not cause + the resulting executable to be covered by the GNU General Public License. + This exception does not however invalidate any other reasons why + the executable file might be covered by the GNU General Public License. */ + +/* + * This file just supplies function prologues for the .init and .fini + * sections. It is linked in before crtbegin.o. + */ + + .file "crti.o" + .ident "GNU C crti.o" + + .section .init + .globl __init + .type __init,@function +__init: +#if defined __ID_SHARED_LIB__ + [--SP] = P5; +#elif defined __BFIN_FDPIC__ + [--SP] = P3; +#endif + LINK 12; +#if defined __ID_SHARED_LIB__ + P5 = [P5 + _current_shared_library_p5_offset_] +#endif + .section .fini + .globl __fini + .type __fini,@function __fini: - LINK 0; - SP += -12; +#if defined __ID_SHARED_LIB__ + [--SP] = P5; +#elif defined __BFIN_FDPIC__ + [--SP] = P3; +#endif + LINK 12; +#if defined __ID_SHARED_LIB__ + P5 = [P5 + _current_shared_library_p5_offset_] +#endif |