xref: /illumos-gate/usr/src/lib/crt/amd64/crti.s (revision 5e0a5eb736a773e9ab13bae98d1998788ce0f4f9)
13e76f9d6SRichard Lowe/*
23e76f9d6SRichard Lowe * CDDL HEADER START
33e76f9d6SRichard Lowe *
43e76f9d6SRichard Lowe * The contents of this file are subject to the terms of the
53e76f9d6SRichard Lowe * Common Development and Distribution License (the "License").
63e76f9d6SRichard Lowe * You may not use this file except in compliance with the License.
73e76f9d6SRichard Lowe *
83e76f9d6SRichard Lowe * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
93e76f9d6SRichard Lowe * or http://www.opensolaris.org/os/licensing.
103e76f9d6SRichard Lowe * See the License for the specific language governing permissions
113e76f9d6SRichard Lowe * and limitations under the License.
123e76f9d6SRichard Lowe *
133e76f9d6SRichard Lowe * When distributing Covered Code, include this CDDL HEADER in each
143e76f9d6SRichard Lowe * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
153e76f9d6SRichard Lowe * If applicable, add the following below this CDDL HEADER, with the
163e76f9d6SRichard Lowe * fields enclosed by brackets "[]" replaced with your own identifying
173e76f9d6SRichard Lowe * information: Portions Copyright [yyyy] [name of copyright owner]
183e76f9d6SRichard Lowe *
193e76f9d6SRichard Lowe * CDDL HEADER END
203e76f9d6SRichard Lowe */
213e76f9d6SRichard Lowe/*
223e76f9d6SRichard Lowe * Copyright 2004 Sun Microsystems, Inc.  All rights reserved.
233e76f9d6SRichard Lowe * Use is subject to license terms.
243e76f9d6SRichard Lowe */
253e76f9d6SRichard Lowe
263e76f9d6SRichard Lowe	.file	"crti.s"
27*5e0a5eb7SRichard Lowe	.ident	""
283e76f9d6SRichard Lowe
293e76f9d6SRichard Lowe/*
303e76f9d6SRichard Lowe * These crt*.o modules are provided as the bare minimum required
313e76f9d6SRichard Lowe * from a crt*.o for inclusion in building low level system
323e76f9d6SRichard Lowe * libraries.  The are only be to included in libraries which
333e76f9d6SRichard Lowe * contain *no* C++ code and want to avoid the startup code
343e76f9d6SRichard Lowe * that the C++ runtime has introduced into the crt*.o modules.
353e76f9d6SRichard Lowe *
363e76f9d6SRichard Lowe * For further details - see bug#4433015
373e76f9d6SRichard Lowe */
383e76f9d6SRichard Lowe
393e76f9d6SRichard Lowe/*
403e76f9d6SRichard Lowe * _init function prologue
413e76f9d6SRichard Lowe */
423e76f9d6SRichard Lowe	.section	.init,"ax"
433e76f9d6SRichard Lowe	.globl	_init
443e76f9d6SRichard Lowe	.type	_init,@function
453e76f9d6SRichard Lowe	.align	16
463e76f9d6SRichard Lowe_init:
473e76f9d6SRichard Lowe	pushq	%rbp
483e76f9d6SRichard Lowe	movq	%rsp, %rbp
493e76f9d6SRichard Lowe
503e76f9d6SRichard Lowe/*
513e76f9d6SRichard Lowe * _fini function prologue
523e76f9d6SRichard Lowe */
533e76f9d6SRichard Lowe	.section	.fini,"ax"
543e76f9d6SRichard Lowe	.globl	_fini
553e76f9d6SRichard Lowe	.type	_fini,@function
563e76f9d6SRichard Lowe	.align	16
573e76f9d6SRichard Lowe_fini:
583e76f9d6SRichard Lowe	pushq	%rbp
593e76f9d6SRichard Lowe	movq	%rsp, %rbp
60