1*86db9970Skamil.\" $NetBSD: core.5,v 1.33 2019/12/06 18:03:49 kamil Exp $ 2649dfd17Sthorpej.\" 3649dfd17Sthorpej.\" Copyright (c) 2002 The NetBSD Foundation, Inc. 4649dfd17Sthorpej.\" All rights reserved. 5649dfd17Sthorpej.\" 6649dfd17Sthorpej.\" This code is derived from software contributed to The NetBSD Foundation 7649dfd17Sthorpej.\" by Jason R. Thorpe. 8649dfd17Sthorpej.\" 9649dfd17Sthorpej.\" Redistribution and use in source and binary forms, with or without 10649dfd17Sthorpej.\" modification, are permitted provided that the following conditions 11649dfd17Sthorpej.\" are met: 12649dfd17Sthorpej.\" 1. Redistributions of source code must retain the above copyright 13649dfd17Sthorpej.\" notice, this list of conditions and the following disclaimer. 14649dfd17Sthorpej.\" 2. Redistributions in binary form must reproduce the above copyright 15649dfd17Sthorpej.\" notice, this list of conditions and the following disclaimer in the 16649dfd17Sthorpej.\" documentation and/or other materials provided with the distribution. 17649dfd17Sthorpej.\" 18649dfd17Sthorpej.\" THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS 19649dfd17Sthorpej.\" ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED 20649dfd17Sthorpej.\" TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR 21649dfd17Sthorpej.\" PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS 22649dfd17Sthorpej.\" BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 23649dfd17Sthorpej.\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 24649dfd17Sthorpej.\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 25649dfd17Sthorpej.\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 26649dfd17Sthorpej.\" CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 27649dfd17Sthorpej.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 28649dfd17Sthorpej.\" POSSIBILITY OF SUCH DAMAGE. 29b5930afcSjtc.\" 30b5930afcSjtc.\" Copyright (c) 1980, 1991, 1993 31b5930afcSjtc.\" The Regents of the University of California. All rights reserved. 3261f28255Scgd.\" 3361f28255Scgd.\" Redistribution and use in source and binary forms, with or without 3461f28255Scgd.\" modification, are permitted provided that the following conditions 3561f28255Scgd.\" are met: 3661f28255Scgd.\" 1. Redistributions of source code must retain the above copyright 3761f28255Scgd.\" notice, this list of conditions and the following disclaimer. 3861f28255Scgd.\" 2. Redistributions in binary form must reproduce the above copyright 3961f28255Scgd.\" notice, this list of conditions and the following disclaimer in the 4061f28255Scgd.\" documentation and/or other materials provided with the distribution. 41075022b3Sagc.\" 3. Neither the name of the University nor the names of its contributors 4261f28255Scgd.\" may be used to endorse or promote products derived from this software 4361f28255Scgd.\" without specific prior written permission. 4461f28255Scgd.\" 4561f28255Scgd.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND 4661f28255Scgd.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 4761f28255Scgd.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 4861f28255Scgd.\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE 4961f28255Scgd.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 5061f28255Scgd.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 5161f28255Scgd.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 5261f28255Scgd.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 5361f28255Scgd.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 5461f28255Scgd.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 5561f28255Scgd.\" SUCH DAMAGE. 5661f28255Scgd.\" 57b5930afcSjtc.\" @(#)core.5 8.3 (Berkeley) 12/11/93 5861f28255Scgd.\" 59*86db9970Skamil.Dd December 6, 2019 6061f28255Scgd.Dt CORE 5 617a1aea16Sgarbled.Os 6261f28255Scgd.Sh NAME 6361f28255Scgd.Nm core 6461f28255Scgd.Nd memory image file format 6561f28255Scgd.Sh SYNOPSIS 66472351e1Swiz.In sys/param.h 67649dfd17Sthorpej.Pp 68649dfd17SthorpejFor a.out-format core files: 69649dfd17Sthorpej.Pp 70472351e1Swiz.In sys/core.h 71649dfd17Sthorpej.Pp 72649dfd17SthorpejFor ELF-format core files: 73649dfd17Sthorpej.Pp 74472351e1Swiz.In sys/exec.h 75472351e1Swiz.In sys/exec_elf.h 7661f28255Scgd.Sh DESCRIPTION 7761f28255ScgdA small number of signals which cause abnormal termination of a process 7861f28255Scgdalso cause a record of the process's in-core state to be written 799dfae77aSjdolecekto disk for later examination by one of the available debuggers 809dfae77aSjdolecek(see 819dfae77aSjdolecek.Xr signal 7 ) . 8271e62d7dSlukem.Pp 83510907edSbouyerThis memory image is written to a file named from a per-process template; 84510907edSbouyerprovided the terminated process had write permission, and provided the 85510907edSbouyerabnormality did not cause a system crash. 8661f28255Scgd(In this event, the decision to save the core file is arbitrary, see 8761f28255Scgd.Xr savecore 8 . ) 88510907edSbouyerThe file is named from a per-process template, mapped to the sysctl 89510907edSbouyervariable 9001869ca4Swiz.Em proc.<pid>.corename 9101869ca4Swiz(where <pid> has to be replaced by the pid in decimal format of the 92510907edSbouyerprocess). 93510907edSbouyerThis template is either an absolute or relative path name, in which format 946abe6d18Swizcharacters can be used, preceded by the percent character 9571e62d7dSlukem.Pq Dq \&% . 96816c57a9SwizThe following characters are recognized as format and substituted: 9771e62d7dSlukem.Bl -tag -width 4n -offset indent -compact 9871e62d7dSlukem.It Sy n 9971e62d7dSlukemThe process's name 10071e62d7dSlukem.It Sy p 10171e62d7dSlukemThe PID of the process (in decimal) 10271e62d7dSlukem.It Sy t 10371e62d7dSlukemThe process's creation date (a la 104510907edSbouyer.Xr time 3 , 105510907edSbouyerin decimal) 10671e62d7dSlukem.It Sy u 10771e62d7dSlukemThe login name, as returned by 108510907edSbouyer.Xr getlogin 2 109510907edSbouyer.El 11061f28255Scgd.Pp 111510907edSbouyerBy default, the per-process template string points to the default core name 112510907edSbouyertemplate, which is mapped to the sysctl variable 113510907edSbouyer.Em kern.defcorename . 114510907edSbouyerChanging this value on a live system will change the core name template for 115510907edSbouyerall processes which didn't have a per-process template set. 116510907edSbouyerThe default value of the default core name template is 117510907edSbouyer.Nm %n.core 118510907edSbouyerand can be changed at compile-time with the kernel configuration option 119510907edSbouyer.Cd options DEFCORENAME 120510907edSbouyer(see 121510907edSbouyer.Xr options 4 ) 122510907edSbouyer.Pp 123510907edSbouyerThe per-process template string is inherited on process creation, but is reset 124510907edSbouyerto point to the default core name template on execution of a set-id binary. 125510907edSbouyer.Pp 126510907edSbouyerThe maximum size of a core file is limited by 12761f28255Scgd.Xr setrlimit 2 . 12861f28255ScgdFiles which would be larger than the limit are not created. 129649dfd17Sthorpej.Ss ELF CORE FORMAT 130649dfd17SthorpejELF-format core files are described by a standard ELF exec header and 131054f9547Swiza series of ELF program headers. 132054f9547SwizEach program header describes a range 133649dfd17Sthorpejof the virtual address space of the process. 134649dfd17Sthorpej.Pp 135649dfd17SthorpejIn addition, 136649dfd17Sthorpej.Nx 137649dfd17SthorpejELF core files include an ELF note section which provides additional 138054f9547Swizinformation about the process. 139054f9547SwizThe first note in the note section has a note name of 140649dfd17Sthorpej.Dq NetBSD-CORE 141649dfd17Sthorpejand a note type of 142d806e2a1Swiz.Dv ELF_NOTE_NETBSD_CORE_PROCINFO ( 1 ) , 143d806e2a1Swizand contains the following 144649dfd17Sthorpejstructure: 145649dfd17Sthorpej.Bd -literal 146649dfd17Sthorpejstruct netbsd_elfcore_procinfo { 147649dfd17Sthorpej uint32_t cpi_version; /* netbsd_elfcore_procinfo version */ 148649dfd17Sthorpej uint32_t cpi_cpisize; /* sizeof(netbsd_elfcore_procinfo) */ 149649dfd17Sthorpej uint32_t cpi_signo; /* killing signal */ 150649dfd17Sthorpej uint32_t cpi_sigcode; /* signal code */ 151649dfd17Sthorpej uint32_t cpi_sigpend[4]; /* pending signals */ 152649dfd17Sthorpej uint32_t cpi_sigmask[4]; /* blocked signals */ 153649dfd17Sthorpej uint32_t cpi_sigignore[4]; /* blocked signals */ 154649dfd17Sthorpej uint32_t cpi_sigcatch[4]; /* blocked signals */ 155649dfd17Sthorpej int32_t cpi_pid; /* process ID */ 156649dfd17Sthorpej int32_t cpi_ppid; /* parent process ID */ 157649dfd17Sthorpej int32_t cpi_pgrp; /* process group ID */ 158649dfd17Sthorpej int32_t cpi_sid; /* session ID */ 159649dfd17Sthorpej uint32_t cpi_ruid; /* real user ID */ 160649dfd17Sthorpej uint32_t cpi_euid; /* effective user ID */ 161649dfd17Sthorpej uint32_t cpi_svuid; /* saved user ID */ 162649dfd17Sthorpej uint32_t cpi_rgid; /* real group ID */ 163649dfd17Sthorpej uint32_t cpi_egid; /* effective group ID */ 164649dfd17Sthorpej uint32_t cpi_svgid; /* saved group ID */ 165649dfd17Sthorpej uint32_t cpi_nlwps; /* number of LWPs */ 166649dfd17Sthorpej int8_t cpi_name[32]; /* copy of p->p_comm */ 1673c1e0232Skamil int32_t cpi_siglwp; /* LWP target of killing signal */ 168649dfd17Sthorpej}; 169649dfd17Sthorpej.Ed 170649dfd17Sthorpej.Pp 171649dfd17SthorpejThe fields of 172649dfd17Sthorpej.Fa struct netbsd_elfcore_procinfo 173649dfd17Sthorpejare as follows: 174649dfd17Sthorpej.Bl -tag -width cpi_sigignoreXX 175649dfd17Sthorpej.It cpi_version 176054f9547SwizThe version of this structure. 177054f9547SwizThe current version is defined by the 178054f9547Swiz.Dv NETBSD_ELFCORE_PROCINFO_VERSION 179054f9547Swizconstant. 180649dfd17Sthorpej.It cpi_cpisize 181649dfd17SthorpejThe size of this structure. 182649dfd17Sthorpej.It cpi_signo 183649dfd17SthorpejSignal that caused the process to dump core. 184649dfd17Sthorpej.It cpi_sigcode 185649dfd17SthorpejSignal-specific code, if any, corresponding to 186649dfd17Sthorpej.Va cpi_signo . 187649dfd17Sthorpej.It cpi_sigpend 188054f9547SwizA mask of signals pending delivery to the process. 189054f9547SwizThis may be examined by copying it to a 190649dfd17Sthorpej.Fa sigset_t . 191649dfd17Sthorpej.It cpi_sigmask 192054f9547SwizThe set of signals currently blocked by the process. 193054f9547SwizThis may be examined by copying it to a 194649dfd17Sthorpej.Fa sigset_t . 195649dfd17Sthorpej.It cpi_sigignore 196054f9547SwizThe set of signals currently being ignored by the process. 197054f9547SwizThis may be examined by copying it to a 198649dfd17Sthorpej.Fa sigset_t . 199649dfd17Sthorpej.It cpi_sigcatch 200054f9547SwizThe set of signals with registers signals handlers for the process. 201054f9547SwizThis may be examined by copying it to a 202649dfd17Sthorpej.Fa sigset_t . 203649dfd17Sthorpej.It cpi_pid 204649dfd17SthorpejProcess ID of the process. 205649dfd17Sthorpej.It cpi_ppid 206649dfd17SthorpejProcess ID of the parent process. 207649dfd17Sthorpej.It cpi_pgrp 208649dfd17SthorpejProcess group ID of the process. 209649dfd17Sthorpej.It cpi_sid 210649dfd17SthorpejSession ID of the process. 211649dfd17Sthorpej.It cpi_ruid 212649dfd17SthorpejReal user ID of the process. 213649dfd17Sthorpej.It cpi_euid 214649dfd17SthorpejEffective user ID of the process. 215649dfd17Sthorpej.It cpi_svuid 216649dfd17SthorpejSaved user ID of the process. 217649dfd17Sthorpej.It cpi_rgid 218649dfd17SthorpejReal group ID of the process. 219649dfd17Sthorpej.It cpi_egid 220649dfd17SthorpejEffective group ID of the process. 221649dfd17Sthorpej.It cpi_svgid 222649dfd17SthorpejSaved group ID of the process. 223649dfd17Sthorpej.It cpi_nlwps 224649dfd17SthorpejNumber of kernel-visible execution contexts (LWPs) of the process. 225649dfd17Sthorpej.It cpi_name 226649dfd17SthorpejProcess name, copied from the p_comm field of 227649dfd17Sthorpej.Fa struct proc . 2283c1e0232Skamil.It cpi_siglwp 2293c1e0232SkamilLWP target of killing signal. 230649dfd17Sthorpej.El 231649dfd17Sthorpej.Pp 2323c1e0232SkamilThe second note with name 2333c1e0232Skamil.Dq NetBSD-CORE 2343c1e0232Skamilis a note type of 235d806e2a1Swiz.Dv ELF_NOTE_NETBSD_CORE_AUXV ( 2 ) , 2363c1e0232Skamiland contains an array of AuxInfo structures. 2373c1e0232Skamil.Pp 238649dfd17SthorpejThe note section also contains additional notes for each 239649dfd17Sthorpejkernel-visible execution context of the process (LWP). 240649dfd17SthorpejThese notes have names of the form 241649dfd17Sthorpej.Dq NetBSD-CORE@nn 242649dfd17Sthorpejwhere 243649dfd17Sthorpej.Dq nn 244649dfd17Sthorpejis the LWP ID of the execution context, for example: 245649dfd17Sthorpej.Dq NetBSD-CORE@1 . 246649dfd17SthorpejThese notes contain register and other per-execution context 247649dfd17Sthorpejdata in the same format as is used by the 248649dfd17Sthorpej.Xr ptrace 2 249054f9547Swizsystem call. 250054f9547SwizThe note types correspond to the 251649dfd17Sthorpej.Xr ptrace 2 252054f9547Swizrequest numbers that return the same data. 253054f9547SwizFor example, 254649dfd17Sthorpeja note with a note type of PT_GETREGS would contain a 255649dfd17Sthorpej.Fa struct reg 256816c57a9Swizwith the register contents of the execution context. 257649dfd17SthorpejFor a complete list of available 258649dfd17Sthorpej.Xr ptrace 2 259649dfd17Sthorpejrequest types for a given architecture, refer to that architecture's 2603994db83Swiz.Aq Pa machine/ptrace.h 261649dfd17Sthorpejheader file. 262649dfd17Sthorpej.Ss A.OUT CORE FORMAT 263b765c01aSnathanwThe core file consists of a core header followed by a number of 264054f9547Swizsegments. 265054f9547SwizEach segment is preceded by a core segment header. 2660b6e7eefSnathanwBoth the core header and core segment header are defined in 2675e015e5eSjoerg.In sys/core.h . 26842704c41Swiz.Pp 2690b6e7eefSnathanwThe core header, 2700b6e7eefSnathanw.Fa struct core , 2710b6e7eefSnathanwspecifies the lengths of the core header itself and 2720b6e7eefSnathanweach of the following core segment headers to allow for any machine 2730b6e7eefSnathanwdependent alignment requirements. 2740b6e7eefSnathanw.Bd -literal 2750b6e7eefSnathanwstruct core { 276fd18408bSperry uint32_t c_midmag; /* magic, id, flags */ 277fd18408bSperry uint16_t c_hdrsize; /* Size of this header (machdep algn) */ 278fd18408bSperry uint16_t c_seghdrsize; /* Size of a segment header */ 279fd18408bSperry uint32_t c_nseg; /* # of core segments */ 28001869ca4Swiz char c_name[MAXCOMLEN+1]; /* Copy of p->p_comm */ 281fd18408bSperry uint32_t c_signo; /* Killing signal */ 2820b6e7eefSnathanw u_long c_ucode; /* Signal code */ 2830b6e7eefSnathanw u_long c_cpusize; /* Size of machine dependent segment */ 2840b6e7eefSnathanw u_long c_tsize; /* Size of traditional text segment */ 2850b6e7eefSnathanw u_long c_dsize; /* Size of traditional data segment */ 2860b6e7eefSnathanw u_long c_ssize; /* Size of traditional stack segment */ 2870b6e7eefSnathanw}; 2880b6e7eefSnathanw.Ed 2890b6e7eefSnathanw.Pp 2900b6e7eefSnathanwThe fields of 2910b6e7eefSnathanw.Fa struct core 2920b6e7eefSnathanware as follows: 2930b6e7eefSnathanw.Bl -tag -width XXXc_seghdrsize 2940b6e7eefSnathanw.It c_midmag 2950b6e7eefSnathanwCore file machine ID, magic value, and flags. 2960b6e7eefSnathanwThese values may be extracted with the 2970b6e7eefSnathanw.Fn CORE_GETMID , 2980b6e7eefSnathanw.Fn CORE_GETMAGIC , 2990b6e7eefSnathanwand 3000b6e7eefSnathanw.Fn CORE_GETFLAG 301054f9547Swizmacros. 302054f9547SwizThe machine ID values are listed in 3035e015e5eSjoerg.In sys/exec_aout.h . 3040b6e7eefSnathanwFor a valid core file, the magic value in the header must be 3050b6e7eefSnathanw.Dv COREMAGIC . 3060b6e7eefSnathanwNo flags are defined for the core header. 3070b6e7eefSnathanw.It c_hdrsize 3080b6e7eefSnathanwSize of this data structure. 3090b6e7eefSnathanw.It c_seghdrsize 3100b6e7eefSnathanwSize of a segment header. 3110b6e7eefSnathanw.It c_nseg 3120b6e7eefSnathanwNumber of segments that follow this header. 3130b6e7eefSnathanw.It c_name 3140b6e7eefSnathanwProcess name, copied from the p_comm field of 3150b6e7eefSnathanw.Fa struct proc . 3160b6e7eefSnathanw.It c_signo 3170b6e7eefSnathanwSignal that caused the process to dump core. 3180b6e7eefSnathanw.It c_ucode 3190b6e7eefSnathanwCode associated with the signal. 3200b6e7eefSnathanw.It c_cpusize 3210b6e7eefSnathanwSize of the segment containing CPU-specific information. 3220b6e7eefSnathanwThis segment will have the 3230b6e7eefSnathanw.Dv CORE_CPU 3240b6e7eefSnathanwflag set. 3250b6e7eefSnathanw.It c_tsize 3260b6e7eefSnathanwSize of the segment containing the program text. 3270b6e7eefSnathanw.It c_dsize 3280b6e7eefSnathanwSize of the segment containing the program's traditional data area. 3290b6e7eefSnathanw.It c_ssize 3300b6e7eefSnathanwSize of the segment containing the program's traditional stack area. 3310b6e7eefSnathanwThis segment will have the 3320b6e7eefSnathanw.Dv CORE_STACK 3330b6e7eefSnathanwflag set. 3340b6e7eefSnathanw.El 3350b6e7eefSnathanwThe header is followed by 3360b6e7eefSnathanw.Fa c_nseg 3370b6e7eefSnathanwsegments, each of which is preceded with a segment header, 3380b6e7eefSnathanw.Fa struct coreseg : 3390b6e7eefSnathanw.Bd -literal 3400b6e7eefSnathanwstruct coreseg { 341fd18408bSperry uint32_t c_midmag; /* magic, id, flags */ 3420b6e7eefSnathanw u_long c_addr; /* Virtual address of segment */ 3430b6e7eefSnathanw u_long c_size; /* Size of this segment */ 3440b6e7eefSnathanw}; 3450b6e7eefSnathanw.Ed 3460b6e7eefSnathanw.Pp 3470b6e7eefSnathanwThe fields of 3480b6e7eefSnathanw.Fa struct coreseg 3490b6e7eefSnathanware as follows: 3500b6e7eefSnathanw.Bl -tag -width XXXc_midmag 3510b6e7eefSnathanw.It c_midmag 3520b6e7eefSnathanwCore segment magic value and flags. 3530b6e7eefSnathanwThese values may be extracted with the 3540b6e7eefSnathanw.Fn CORE_GETMAGIC 3550b6e7eefSnathanwand 3560b6e7eefSnathanw.Fn CORE_GETFLAG 3570b6e7eefSnathanwmacros. 3580b6e7eefSnathanwThe magic value in the segment header must be 3590b6e7eefSnathanw.Dv CORESEGMAGIC . 360aae59958SrumbleExactly one of the flags 3610b6e7eefSnathanw.Dv CORE_CPU , 3620b6e7eefSnathanw.Dv CORE_DATA , 3630b6e7eefSnathanwor 3640b6e7eefSnathanw.Dv CORE_STACK 3650b6e7eefSnathanwwill be set to indicate the segment type. 3660b6e7eefSnathanw.It c_addr 3670b6e7eefSnathanwVirtual address of the segment in the program image. 3680b6e7eefSnathanwMeaningless if the segment type is 3690b6e7eefSnathanw.Dv CORE_CPU . 3700b6e7eefSnathanw.It c_size 3710b6e7eefSnathanwSize of the segment, not including this header. 3720b6e7eefSnathanw.El 37361f28255Scgd.Sh SEE ALSO 37461f28255Scgd.Xr gdb 1 , 3759dfae77aSjdolecek.Xr setrlimit 2 , 376510907edSbouyer.Xr sysctl 3 , 37780cb79a9Swiz.Xr a.out 5 , 37880cb79a9Swiz.Xr elf 5 , 3799dfae77aSjdolecek.Xr signal 7 , 380510907edSbouyer.Xr sysctl 8 38161f28255Scgd.Sh HISTORY 38261f28255ScgdA 383b5930afcSjtc.Nm core 38461f28255Scgdfile format appeared in 3858a189553Ssevan.At v1 . 386649dfd17SthorpejThe 387649dfd17Sthorpej.Nx 388649dfd17Sthorpeja.out core file format was introduced in 389649dfd17Sthorpej.Nx 1.0 . 390649dfd17SthorpejThe 391649dfd17Sthorpej.Nx 392649dfd17SthorpejELF core file format was introduced in 393649dfd17Sthorpej.Nx 1.6 . 394649dfd17Sthorpej.Pp 395649dfd17SthorpejIn releases previous to 396649dfd17Sthorpej.Nx 1.6 , 397649dfd17SthorpejELF program images produced a.out-format core files. 3983c1e0232Skamil.Pp 3993c1e0232SkamilThe 4003c1e0232Skamil.Dv cpi_siglwp 4013c1e0232Skamilmember of the 4023c1e0232Skamil.Dv netbsd_elfcore_procinfo 4033c1e0232Skamilstructure first appeared in 4043c1e0232Skamil.Nx 2.0 . 4053c1e0232SkamilHowever it retained the procinfo version 1, 4063c1e0232Skamilstored in 4073c1e0232Skamil.Dv cpi_version . 4083c1e0232Skamil.Pp 4093c1e0232Skamil.Dv ELF_NOTE_NETBSD_CORE_AUXV 4103c1e0232Skamilwas added in 4113c1e0232Skamil.Nx 8.0 . 4120b6e7eefSnathanw.Sh BUGS 4130b6e7eefSnathanwThere is no standard location or name for the 4146abe6d18SwizCPU-dependent data structure stored in the 4150b6e7eefSnathanw.Dv CORE_CPU 4160b6e7eefSnathanwsegment. 417