return -1;
}
-#if defined(__i386__) || defined(__x86_64)
+#if defined(__i386__) || defined(__x86_64__)
/* No Architectural Performance Monitoring Leaf returned by CPUID */
if (get_cpuid_info ()->cpi_maxeax < 0xa)
return (-1);
{
#if defined(__aarch64__) || defined(__riscv)
return "";
-#elif defined(__i386__) || defined(__x86_64)
+#elif defined(__i386__) || defined(__x86_64__)
switch (cpuid_getmodel ())
{
case 60: /* Haswell */
#define COL_CPUFREQ_SCALING 0x0001
#define COL_CPUFREQ_TURBO 0x0002
-#if defined(__i386__) || defined(__x86_64)
+#if defined(__i386__) || defined(__x86_64__)
// XXXX This is a rough table to estimate frequency increment due to intel turbo boost.
// CPU with different stepping and different core number have different turbo increment.
// It is used internally here, and is not implemented on SPARC
{
char temp[1024];
int cpu = -1;
-#if defined(__i386__) || defined(__x86_64)
+#if defined(__i386__) || defined(__x86_64__)
int model = -1;
int family = -1;
#endif
char *val = strchr (temp, ':');
cpu = val ? atoi (val + 1) : -1;
}
-#if defined(__i386__) || defined(__x86_64)
+#if defined(__i386__) || defined(__x86_64__)
else if (strncmp (temp, "model", strlen ("model")) == 0
&& strstr (temp, "name") == 0)
{
frequency_scaling = 1;
if (tmpmhz > 1000)
{
-#if defined(__i386__) || defined(__x86_64)
+#if defined(__i386__) || defined(__x86_64__)
if (family == 6)
{
// test turbo mode
Foundation, 51 Franklin Street - Fifth Floor, Boston,
MA 02110-1301, USA. */
-#if defined(__i386__) || defined(__x86_64)
+#if defined(__i386__) || defined(__x86_64__)
#include <cpuid.h> /* GCC-provided */
#elif defined(__aarch64__)
#if !defined(ATTRIBUTE_UNUSED)
} cpuid_info_t;
-#if defined(__i386__) || defined(__x86_64)
+#if defined(__i386__) || defined(__x86_64__)
static uint_t
cpuid_vendorstr_to_vendorcode (char *vendorstr)
{
Tprintf (DBG_LT0, "cpuid.c:%d read_cpuid_id() MIDR_EL1==0x%016x cpi_vendor=%d cpi_model=%d\n",
__LINE__, (unsigned int) reg, cpi->cpi_vendor, cpi->cpi_model);
-#elif defined(__i386__) || defined(__x86_64)
+#elif defined(__i386__) || defined(__x86_64__)
cpuid_regs_t regs;
my_cpuid (0, ®s);
cpi->cpi_maxeax = regs.eax;
#if defined(sparc) || defined(__sparcv9)
#define ARCH_SPARC 1
-#elif defined(__i386__) || defined(__x86_64)
+#elif defined(__i386__) || defined(__x86_64__)
#define ARCH_Intel 1
#elif defined(__aarch64__)
#define ARCH_Aarch64 1
#error "Undefined platform"
#endif
-#if defined(__sparcv9) || defined(__x86_64) || defined(__aarch64__) || defined(__riscv)
+#if defined(__sparcv9) || defined(__x86_64__) || defined(__aarch64__) || defined(__riscv)
#define WSIZE_64 1
#else
#define WSIZE_32 1
{NULL, NULL, 0, NULL, 0, 0, 0, 0, ABST_NONE}
};
-#if defined(__i386__) || defined(__x86_64)
+#if defined(__i386__) || defined(__x86_64__)
/* Kernel profiling pseudo-chip, OBSOLETE (To support 12.3 and earlier, TBR) */
static Hwcentry kproflist[] = {
{"kcycles", "kcycles", 0, STXT ("KCPU Cycles"), PRELOADS_5, 1, ABST_NONE},
{"insts1", "EX_retired_instr_w_excp_intr", 1, NULL, PRELOADS_8, 0, ABST_NONE},
{NULL, NULL, 0, NULL, 0, 0, 0, 0, ABST_NONE}
};
-#endif /* __i386__ or __x86_64 */
+#endif /* __i386__ or __x86_64__ */
#define INIT_HWC(nm, mtr, cfg, ty) .name = (nm), .metric = (mtr), \
.config = (cfg), .type = ty, .use_perf_event_type = 1, \
{NULL, NULL, 0, NULL, 0, 0, 0, 0, ABST_NONE}
};
-#if defined(__i386__) || defined(__x86_64)
+#if defined(__i386__) || defined(__x86_64__)
#include "hwc_amd_zen3.h"
#include "hwc_amd_zen4.h"
#include "hwc_intel_icelake.h"
* If the string is not formatted that way, -h hi and -h lo will fail
*/
static cpu_list_t cputabs[] = {
-#if defined(__i386__) || defined(__x86_64)
+#if defined(__i386__) || defined(__x86_64__)
{CPC_PENTIUM_PRO_MMX, pentiumIIlist, {"insts", 0}},
{CPC_PENTIUM_PRO, pentiumIIIlist, {"insts", 0}},
{CPC_PENTIUM_4, pentium4, {"insts", 0}},
Foundation, 51 Franklin Street - Fifth Floor, Boston,
MA 02110-1301, USA. */
-#if defined(__i386__) || defined(__x86_64)
+#if defined(__i386__) || defined(__x86_64__)
#include "opcodes/i386-dis.c"
#undef _
__collector_getpc ()
{
void *r;
-#if defined(__x86_64)
+#if defined(__x86_64__)
__asm__ __volatile__("lea (%%rip), %0" : "=r" (r));
#else
__asm__ __volatile__("call 1f \n"