proc64_id.h revision fad5204e207119133cdc503293923b09417b233b
2N/A/*
2N/A * CDDL HEADER START
2N/A *
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 *
2N/A * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
2N/A * or http://www.opensolaris.org/os/licensing.
2N/A * See the License for the specific language governing permissions
2N/A * and limitations under the License.
2N/A *
2N/A * When distributing Covered Code, include this CDDL HEADER in each
2N/A * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
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 *
2N/A * CDDL HEADER END
2N/A */
2N/A
2N/A/*
2N/A * Copyright (c) 2008, Intel Corporation
2N/A * All rights reserved.
2N/A */
2N/A
2N/A/*
2N/A * Portions Copyright 2009 Advanced Micro Devices, Inc.
2N/A */
2N/A
2N/A#ifndef _PROC64_ID_H
2N/A#define _PROC64_ID_H
2N/A
2N/A#include <sys/x86_archext.h>
2N/A
2N/A#ifdef __cplusplus
2N/Aextern "C" {
2N/A#endif
2N/A
2N/A/*
2N/A * Defines to determine what SSE instructions can be used for memops or strops.
2N/A */
2N/A#define NO_SSE 0x00 /* Default -- Don't use SSE instructions */
2N/A#define USE_SSE2 0x01 /* SSE2 */
2N/A#define USE_SSE3 0x02 /* SSE3 */
2N/A#define USE_SSSE3 0x04 /* Supplemental SSE3 */
2N/A#define USE_SSE4_1 0x08 /* SSE 4.1 */
2N/A#define USE_SSE4_2 0x10 /* SSE 4.2 */
2N/A
2N/A/*
2N/A * Cache size defaults for Core 2 Duo
2N/A */
2N/A#define INTEL_DFLT_L1_CACHE_SIZE (32 * 1024)
2N/A#define INTEL_DFLT_L2_CACHE_SIZE (4 * 1024 * 1024)
2N/A#define INTEL_DFLT_LARGEST_CACHE_SIZE (4 * 1024 * 1024)
2N/A
2N/A/*
2N/A * Cache size defaults for AMD SledgeHammer
2N/A */
2N/A#define AMD_DFLT_L1_CACHE_SIZE (64 * 1024)
2N/A#define AMD_DFLT_L2_CACHE_SIZE (1024 * 1024)
2N/A
2N/A#ifdef _ASM
2N/A .extern .memops_method
2N/A#else
2N/A
2N/Avoid __libc_get_cpuid(int cpuid_function, void *out_reg, int cache_index);
2N/Avoid __intel_set_memops_method(long sse_level);
2N/Avoid __set_cache_sizes(long l1_cache_size, long l2_cache_size,
2N/A long largest_level_cache);
2N/A
2N/A#endif /* _ASM */
2N/A
2N/A#ifdef __cplusplus
2N/A}
2N/A#endif
2N/A
2N/A#endif /* _PROC64_ID_H */
2N/A