2N/A * The contents of this file are subject to the terms of the 2N/A * Common Development and Distribution License (the "License"). 2N/A * You may not use this file except in compliance with the License. 2N/A * See the License for the specific language governing permissions 2N/A * and limitations under the License. 2N/A * When distributing Covered Code, include this CDDL HEADER in each 2N/A * If applicable, add the following below this CDDL HEADER, with the 2N/A * fields enclosed by brackets "[]" replaced with your own identifying 2N/A * information: Portions Copyright [yyyy] [name of copyright owner] 2N/A * Copyright 2006 Sun Microsystems, Inc. All rights reserved. 2N/A * Use is subject to license terms. 2N/A#
pragma ident "%Z%%M% %I% %E% SMI" 2N/A * The absolute minimum content is si_signo and si_code. 2N/A * A siginfo generated by user level is structured 2N/A * differently from one generated by the kernel. 2N/A * This is a little sketchy: we have three types of values stored 2N/A * in an auxv (long, void *, and void (*)()) so the only sign-extension 2N/A * issue is with the long. We could case on all possible AT_* types, 2N/A * but this seems silly since currently none of the types which use 2N/A * a_un.a_val actually use negative numbers as a value. For this 2N/A * reason, it seems simpler to just do an unsigned expansion for now. 2N/A for (i = 0; i <
8; i++) {
2N/A for (i = 0; i <
32; i++)
2N/A * We deliberately do not convert pr_qcnt or pr_q because it is a long- 2N/A * standing /proc bug that this information is not exported, and another 2N/A * bug further caused these values to be returned as uninitialized data 2N/A * when the 64-bit kernel exported them for a 32-bit process with en=0. 2N/A * Converting from the tag field to the compressed fctw is easy. 2N/A * If the two tag bits are 3, then the register is empty and we 2N/A * clear the bit in fctw. Otherwise we set the bit. 2N/A for (i = 0; i <
8; i++)
2N/A * The absolute minimum content is si_signo and si_code. 2N/A * A siginfo generated by user level is structured 2N/A * differently from one generated by the kernel. 2N/A for (i = 0; i <
32; i++)
2N/A * AMD64 stores the tag in a compressed form. It is 2N/A * necessary to extract the original 2-bit tag value. 2N/A * See AMD64 Architecture Programmer's Manual Volume 2: 2N/A * System Programming, Chapter 11. 2N/A for (i = 0; i <
8; i++) {
2N/A * Recall that we need to use the current TOP-of-stack value to 2N/A * associate the _st[] index back to a physical register number, 2N/A * since tag word indices are physical register numbers. Then 2N/A * to get the tag value, we shift over two bits for each tag 2N/A * index, and then grab the bottom two bits. 2N/A * Union for overlaying _fpreg structure on to quad-precision 2N/A * floating-point value (long double).