'\" te .\" Copyright (c) 2003, Sun Microsystems, Inc. All Rights Reserved. .\" 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 or http://www.opensolaris.org/os/licensing. 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] .TH getcpuid 3C "16 Apr 2003" "SunOS 5.11" "Standard C Library Functions" .SH NAME getcpuid, gethomelgroup \- obtain information on scheduling decisions .SH SYNOPSIS .LP .nf #include \fBprocessorid_t\fR \fBgetcpuid\fR(\fBvoid\fR); .fi .LP .nf \fBushort_t\fR \fBgethomelgroup\fR(\fBvoid\fR); .fi .SH DESCRIPTION .sp .LP The \fBgetcpuid()\fR function returns the processor ID on which the calling thread is currently executing. .sp .LP The \fBgethomelgroup()\fR function returns the home locality group ID of the calling thread. .SH RETURN VALUES .sp .LP See \fBDESCRIPTION\fR. .SH ERRORS .sp .LP No errors are defined. .SH USAGE .sp .LP Both the current CPU and the home locality group can change at any time. .SH ATTRIBUTES .sp .LP See \fBattributes\fR(5) for descriptions of the following attributes: .sp .sp .TS tab() box; cw(2.75i) |cw(2.75i) lw(2.75i) |lw(2.75i) . ATTRIBUTE TYPEATTRIBUTE VALUE _ Interface StabilityT{ \fBgetcpuid()\fR is Stable; \fBgethomelgroup()\fR is Obsolete. T} _ MT-LevelMT-Safe .TE .SH SEE ALSO .sp .LP \fBpsradm\fR(1M), \fBpsrinfo\fR(1M), \fBpsrset\fR(1M), \fBp_online\fR(2), \fBprocessor_bind\fR(2), \fBprocessor_info\fR(2), \fBpset_assign\fR(2), \fBpset_bind\fR(2), \fBpset_info\fR(2), \fBmeminfo\fR(2), \fBlgrp_home\fR(3LGRP), \fBsysconf\fR(3C), \fBattributes\fR(5) .SH NOTES .sp .LP The \fBgethomelgroup()\fR function is obsolete and might be removed in a future release. It has been replaced by \fBlgrp_home\fR(3LGRP).