<commit_before>/********************************************************************
 *                                                                  *
 * THIS FILE IS PART OF THE OggTheora SOFTWARE CODEC SOURCE CODE.   *
 * USE, DISTRIBUTION AND REPRODUCTION OF THIS LIBRARY SOURCE IS     *
 * GOVERNED BY A BSD-STYLE SOURCE LICENSE INCLUDED WITH THIS SOURCE *
 * IN 'COPYING'. PLEASE READ THESE TERMS BEFORE DISTRIBUTING.       *
 *                                                                  *
 * THE Theora SOURCE CODE IS COPYRIGHT (C) 2002-2008                *
 * by the Xiph.Org Foundation http://www.xiph.org/                  *
 *                                                                  *
 ********************************************************************
 
 CPU capability detection for x86 processors.
  Originally written by <NAME>.
  
 function:
  last mod: $Id$

 ********************************************************************/

#if !defined(USE_ASM)

ogg_uint32_t oc_cpu_flags_get(void){
  return 0;
}

#else /* USE_ASM */

# if defined(_MSC_VER)
/*  Visual C cpuid helper function. For VS2005 we could
    as well use the _cpuid builtin, but that wouldn't work
    for VS2003 users, so we do it in inline assembler */

static void oc_cpuid_helper (ogg_uint32_t * CpuInfo, ogg_uint32_t op){
  _asm {
    mov eax, [op]
    mov esi, CpuInfo
    cpuid
    mov [esi + 0], eax
    mov [esi + 4], ebx
    mov [esi + 8], ecx<commit_msg>re-include cpu.h in cpu.c (which in turn includes internal.h, and config.h). Was removed in r14714<commit_after>/********************************************************************
 *                                                                  *
 * THIS FILE IS PART OF THE OggTheora SOFTWARE CODEC SOURCE CODE.   *
 * USE, DISTRIBUTION AND REPRODUCTION OF THIS LIBRARY SOURCE IS     *
 * GOVERNED BY A BSD-STYLE SOURCE LICENSE INCLUDED WITH THIS SOURCE *
 * IN 'COPYING'. PLEASE READ THESE TERMS BEFORE DISTRIBUTING.       *
 *                                                                  *
 * THE Theora SOURCE CODE IS COPYRIGHT (C) 2002-2008                *
 * by the Xiph.Org Foundation http://www.xiph.org/                  *
 *                                                                  *
 ********************************************************************
 
 CPU capability detection for x86 processors.
  Originally written by <NAME>.
  
 function:
  last mod: $Id$

 ********************************************************************/

#include "cpu.h"

#if !defined(USE_ASM)

ogg_uint32_t oc_cpu_flags_get(void){
  return 0;
}

#else /* USE_ASM */

# if defined(_MSC_VER)
/*  Visual C cpuid helper function. For VS2005 we could
    as well use the _cpuid builtin, but that wouldn't work
    for VS2003 users, so we do it in inline assembler */

static void oc_cpuid_helper (ogg_uint32_t * CpuInfo, ogg_uint32_t op){
  _asm {
    mov eax, [op]
    mov esi, CpuInfo
    cpuid
    mov [esi + 0], eax
    mov [esi + 4], ebx
    mov [esi + 8], ecx
{'fraction_non_alphanumeric': 0.20078869536641472, 'fraction_numerical': 0.020046007229707525, 'mean_word_length': 2.053159478435306, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 12, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4504414', 'n_tokens_mistral': 898, 'n_tokens_neox': 790, 'n_words': 279}