/*
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
* Common Development and Distribution License (the "License").
* You may not use this file except in compliance with the License.
*
* You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
* See the License for the specific language governing permissions
* and limitations under the License.
*
* When distributing Covered Code, include this CDDL HEADER in each
* file and include the License file at usr/src/OPENSOLARIS.LICENSE.
* If applicable, add the following below this CDDL HEADER, with the
* fields enclosed by brackets "[]" replaced with your own identifying
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
*/
/*
* Copyright (c) 1988 AT&T
* All Rights Reserved
*
*
* Global include file for all sgs ia32 based machine dependent macros,
* constants and declarations.
*/
#ifndef _MACHDEP_X86_H
#define _MACHDEP_X86_H
#include <link.h>
#ifdef __cplusplus
extern "C" {
#endif
/*
* Elf header information.
*/
#ifdef _ELF64
#else
#endif
#define M_FLAGSPLUS 0
/*
* Page boundary Macros: truncate to previous page boundary and round to
* next page boundary (refer to generic macros in ../sgs.h also).
*/
/*
* Segment boundary macros: truncate to previous segment boundary and round
* to next page boundary.
*/
#if defined(_ELF64)
#else
#endif
/*
* Relocation type macros.
*/
#if defined(_ELF64)
#else
#endif
/*
* TLS static segments must be rounded to the following requirements,
* due to libthread stack allocation.
*/
#if defined(_ELF64)
#else
#endif
/*
* Other machine dependent entities
*/
#if defined(_ELF64)
#else
#endif
/*
* Values for IA32 objects
*/
/*
* Instruction encodings.
*/
/* elf_rtbndr() address */
#ifdef _ELF64
/*
* Provide default starting addresses. 64-bit programs can also be restricted
* to a 32-bit address space (SF1_SUNW_ADDR32), and these programs provide an
* alternative origin.
*/
/* origin */
#else
#endif
/*
* Make common relocation information transparent to the common code
*/
#if defined(_ELF64)
#else /* _ELF32 */
#endif /* ELF32 */
/*
* Make common relocation types transparent to the common code
*/
#if defined(_ELF64)
#else
#endif
/*
* The following are defined as M_R_NONE so that checks
* for these relocations can be performed in common code - although
* the checks are really only relevant to SPARC.
*/
/*
* DT_REGISTER is not valid on i386 or amd64
*/
/*
* Make plt section information transparent to the common code.
*/
/*
* Make default data segment and stack flags transparent to the common code.
*/
#ifdef _ELF64
#else
#endif
/*
* Define a set of identifies for special sections. These allow the sections
* to be ordered within the output file image. These values should be
* maintained consistently, where appropriate, in each platform specific header
* file.
*
* - null identifies that this section does not need to be added to the
* output image (ie. shared object sections or sections we're going to
* recreate (sym tables, string tables, relocations, etc.)).
*
* - any user defined section will be first in the associated segment.
*
* - interp and capabilities sections are next, as these are accessed
* immediately the first page of the image is mapped.
*
* - objects that do not provide an interp normally have a read-only
* .dynamic section that comes next (in this case, there is no need to
* update a DT_DEBUG entry at runtime).
*
* - the syminfo, hash, dynsym, dynstr and rel's are grouped together as
* these will all be accessed together by ld.so.1 to perform relocations.
*
* - the got and dynamic are grouped together as these may also be
* accessed first by ld.so.1 to perform relocations, fill in DT_DEBUG
* (executables only), and .got[0].
*
* - unknown sections (stabs, comments, etc.) go at the end.
*
* Note that .tlsbss/.bss are given the largest identifiers. This insures that
* if any unknown sections become associated to the same segment as the .bss,
* the .bss sections are always the last section in the segment.
*/
/* DT_DEBUG is required */
/* M_ID_USER 0x01 dual entry - listed above */
/* M_ID_DYNAMIC 0x06 dual entry - listed above */
/* M_ID_UNWIND 0x08 dual entry - listed above */
#ifdef __cplusplus
}
#endif
#endif /* _MACHDEP_X86_H */