亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? bitset_stats.c

?? bison 2.0 主要可以用來做語法分析用的
?? C
?? 第 1 頁 / 共 2 頁
字號:
/* Bitset statistics.   Copyright (C) 2002, 2003, 2004 Free Software Foundation, Inc.   Contributed by Michael Hayes (m.hayes@elec.canterbury.ac.nz).   This program is free software; you can redistribute it and/or modify   it under the terms of the GNU General Public License as published by   the Free Software Foundation; either version 2 of the License, or   (at your option) any later version.   This program is distributed in the hope that it will be useful,   but WITHOUT ANY WARRANTY; without even the implied warranty of   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the   GNU General Public License for more details.   You should have received a copy of the GNU General Public License   along with this program; if not, write to the Free Software   Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.*//* This file is a wrapper bitset implementation for the other bitset   implementations.  It provides bitset compatibility checking and   statistics gathering without having to instrument the bitset   implementations.  When statistics gathering is enabled, the bitset   operations get vectored through here and we then call the appropriate   routines.*/#ifdef HAVE_CONFIG_H#include "config.h"#endif#include "bbitset.h"#include "abitset.h"#include "ebitset.h"#include "lbitset.h"#include "vbitset.h"#include "bitset_stats.h"#include <stdlib.h>#include <string.h>#include <stdio.h>#include "gettext.h"#define _(Msgid)  gettext (Msgid)/* Configuration macros.  */#define BITSET_STATS_FILE "bitset.dat"#define BITSET_LOG_COUNT_BINS 10#define BITSET_LOG_SIZE_BINS  16#define BITSET_DENSITY_BINS  20/* Accessor macros.  */#define BITSET_STATS_ALLOCS_INC(TYPE)	 		\    bitset_stats_info->types[(TYPE)].allocs++#define BITSET_STATS_FREES_INC(BSET) 			\    bitset_stats_info->types[BITSET_TYPE_ (BSET)].frees++#define BITSET_STATS_SETS_INC(BSET) 			\    bitset_stats_info->types[BITSET_TYPE_ (BSET)].sets++#define BITSET_STATS_CACHE_SETS_INC(BSET) 		\    bitset_stats_info->types[BITSET_TYPE_ (BSET)].cache_sets++#define BITSET_STATS_RESETS_INC(BSET) 			\    bitset_stats_info->types[BITSET_TYPE_ (BSET)].resets++#define BITSET_STATS_CACHE_RESETS_INC(BSET) 		\    bitset_stats_info->types[BITSET_TYPE_ (BSET)].cache_resets++#define BITSET_STATS_TESTS_INC(BSET) 			\    bitset_stats_info->types[BITSET_TYPE_ (BSET)].tests++#define BITSET_STATS_CACHE_TESTS_INC(BSET) 		\    bitset_stats_info->types[BITSET_TYPE_ (BSET)].cache_tests++#define BITSET_STATS_LISTS_INC(BSET) 			\    bitset_stats_info->types[BITSET_TYPE_ (BSET)].lists++#define BITSET_STATS_LIST_COUNTS_INC(BSET, I) 		\    bitset_stats_info->types[BITSET_TYPE_ (BSET)].list_counts[(I)]++#define BITSET_STATS_LIST_SIZES_INC(BSET, I) 		\    bitset_stats_info->types[BITSET_TYPE_ (BSET)].list_sizes[(I)]++#define BITSET_STATS_LIST_DENSITY_INC(BSET, I) 		\    bitset_stats_info->types[BITSET_TYPE_ (BSET)].list_density[(I)]++struct bitset_type_info_struct{  unsigned int allocs;  unsigned int frees;  unsigned int lists;  unsigned int sets;  unsigned int cache_sets;  unsigned int resets;  unsigned int cache_resets;  unsigned int tests;  unsigned int cache_tests;  unsigned int list_counts[BITSET_LOG_COUNT_BINS];  unsigned int list_sizes[BITSET_LOG_SIZE_BINS];  unsigned int list_density[BITSET_DENSITY_BINS];};struct bitset_stats_info_struct{  unsigned int runs;  struct bitset_type_info_struct types[BITSET_TYPE_NUM];};struct bitset_stats_info_struct bitset_stats_info_data;struct bitset_stats_info_struct *bitset_stats_info;bool bitset_stats_enabled = false;/* Print a percentage histogram with message MSG to FILE.  */static voidbitset_percent_histogram_print (FILE *file, const char *name, const char *msg,				unsigned int n_bins, unsigned int *bins){  unsigned int i;  unsigned int total;  total = 0;  for (i = 0; i < n_bins; i++)    total += bins[i];  if (!total)    return;  fprintf (file, "%s %s", name, msg);  for (i = 0; i < n_bins; i++)    fprintf (file, "%.0f-%.0f%%\t%8u (%5.1f%%)\n",	     i * 100.0 / n_bins,	     (i + 1) * 100.0 / n_bins, bins[i],	     (100.0 * bins[i]) / total);}/* Print a log histogram with message MSG to FILE.  */static voidbitset_log_histogram_print (FILE *file, const char *name, const char *msg,			    unsigned int n_bins, unsigned int *bins){  unsigned int i;  unsigned int total;  unsigned int max_width;  total = 0;  for (i = 0; i < n_bins; i++)    total += bins[i];  if (!total)    return;  /* Determine number of useful bins.  */  for (i = n_bins; i > 3 && ! bins[i - 1]; i--)     continue;  n_bins = i;  /* 2 * ceil (log10 (2) * (N - 1)) + 1.  */  max_width = 2 * (unsigned int) (0.30103 * (n_bins - 1) + 0.9999) + 1;  fprintf (file, "%s %s", name, msg);  for (i = 0; i < 2; i++)    fprintf (file, "%*d\t%8u (%5.1f%%)\n",	     max_width, i, bins[i], 100.0 * bins[i] / total);  for (; i < n_bins; i++)    fprintf (file, "%*lu-%lu\t%8u (%5.1f%%)\n",	     max_width - ((unsigned int) (0.30103 * (i) + 0.9999) + 1),	     1UL << (i - 1),	     (1UL << i) - 1,	     bins[i],	     (100.0 * bins[i]) / total);}/* Print bitset statistics to FILE.  */static voidbitset_stats_print_1 (FILE *file, const char *name,		      struct bitset_type_info_struct *stats){  if (!stats)    return;  fprintf (file, "%s:\n", name);  fprintf (file, _("%u bitset_allocs, %u freed (%.2f%%).\n"),	   stats->allocs, stats->frees,	   stats->allocs ? 100.0 * stats->frees / stats->allocs : 0);  fprintf (file, _("%u bitset_sets, %u cached (%.2f%%)\n"),	   stats->sets, stats->cache_sets,	   stats->sets ? 100.0 * stats->cache_sets / stats->sets : 0);  fprintf (file, _("%u bitset_resets, %u cached (%.2f%%)\n"),	   stats->resets, stats->cache_resets,	   stats->resets ? 100.0 * stats->cache_resets / stats->resets : 0);  fprintf (file, _("%u bitset_tests, %u cached (%.2f%%)\n"),	   stats->tests, stats->cache_tests,	   stats->tests ? 100.0 * stats->cache_tests / stats->tests : 0);  fprintf (file, _("%u bitset_lists\n"), stats->lists);  bitset_log_histogram_print (file, name, _("count log histogram\n"),			      BITSET_LOG_COUNT_BINS, stats->list_counts);  bitset_log_histogram_print (file, name, _("size log histogram\n"),			      BITSET_LOG_SIZE_BINS, stats->list_sizes);  bitset_percent_histogram_print (file, name, _("density histogram\n"),				  BITSET_DENSITY_BINS, stats->list_density);}/* Print all bitset statistics to FILE.  */static voidbitset_stats_print (FILE *file, bool verbose ATTRIBUTE_UNUSED){  int i;  if (!bitset_stats_info)    return;  fprintf (file, _("Bitset statistics:\n\n"));  if (bitset_stats_info->runs > 1)    fprintf (file, _("Accumulated runs = %u\n"), bitset_stats_info->runs);  for (i = 0; i < BITSET_TYPE_NUM; i++)    bitset_stats_print_1 (file, bitset_type_names[i],			  &bitset_stats_info->types[i]);}/* Initialise bitset statistics logging.  */voidbitset_stats_enable (void){  if (!bitset_stats_info)    bitset_stats_info = &bitset_stats_info_data;  bitset_stats_enabled = true;}voidbitset_stats_disable (void){  bitset_stats_enabled = false;}/* Read bitset statistics file.  */voidbitset_stats_read (const char *filename){  FILE *file;  if (!bitset_stats_info)    return;  if (!filename)    filename = BITSET_STATS_FILE;  file = fopen (filename, "r");  if (file)    {      if (fread (&bitset_stats_info_data, sizeof (bitset_stats_info_data),		 1, file) != 1)	{	  if (ferror (file))	    perror (_("Could not read stats file."));	  else	    fprintf (stderr, _("Bad stats file size.\n"));	}      if (fclose (file) != 0)	perror (_("Could not read stats file."));    }  bitset_stats_info_data.runs++;}/* Write bitset statistics file.  */voidbitset_stats_write (const char *filename){  FILE *file;  if (!bitset_stats_info)    return;  if (!filename)    filename = BITSET_STATS_FILE;  file = fopen (filename, "w");  if (file)    {      if (fwrite (&bitset_stats_info_data, sizeof (bitset_stats_info_data),		  1, file) != 1)	perror (_("Could not write stats file."));      if (fclose (file) != 0)	perror (_("Could not write stats file."));    }  else    perror (_("Could not open stats file for writing."));}/* Dump bitset statistics to FILE.  */voidbitset_stats_dump (FILE *file){  bitset_stats_print (file, false);}/* Function to be called from debugger to print bitset stats.  */voiddebug_bitset_stats (void){  bitset_stats_print (stderr, true);}static voidbitset_stats_set (bitset dst, bitset_bindex bitno){  bitset bset = dst->s.bset;  bitset_windex wordno = bitno / BITSET_WORD_BITS;  bitset_windex offset = wordno - bset->b.cindex;  BITSET_STATS_SETS_INC (bset);  if (offset < bset->b.csize)    {      bset->b.cdata[offset] |= (bitset_word) 1 << (bitno % BITSET_WORD_BITS);      BITSET_STATS_CACHE_SETS_INC (bset);    }  else    BITSET_SET_ (bset, bitno);}static voidbitset_stats_reset (bitset dst, bitset_bindex bitno){  bitset bset = dst->s.bset;  bitset_windex wordno = bitno / BITSET_WORD_BITS;  bitset_windex offset = wordno - bset->b.cindex;  BITSET_STATS_RESETS_INC (bset);  if (offset < bset->b.csize)    {      bset->b.cdata[offset] &=	~((bitset_word) 1 << (bitno % BITSET_WORD_BITS));      BITSET_STATS_CACHE_RESETS_INC (bset);    }  else    BITSET_RESET_ (bset, bitno);}static boolbitset_stats_toggle (bitset src, bitset_bindex bitno){    return BITSET_TOGGLE_ (src->s.bset, bitno);}static boolbitset_stats_test (bitset src, bitset_bindex bitno){  bitset bset = src->s.bset;  bitset_windex wordno = bitno / BITSET_WORD_BITS;  bitset_windex offset = wordno - bset->b.cindex;  BITSET_STATS_TESTS_INC (bset);

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
亚洲h精品动漫在线观看| 国产精品久久久久国产精品日日 | 色av成人天堂桃色av| 韩国欧美一区二区| 国内精品免费**视频| 激情综合五月婷婷| 国产精品一区二区免费不卡 | 国产亚洲福利社区一区| 精品国产免费一区二区三区四区| 日韩一区二区免费电影| 日韩欧美精品在线视频| 日韩欧美区一区二| 国产三级一区二区| 亚洲精品午夜久久久| 亚洲成a人片在线观看中文| 免费高清不卡av| 国产激情精品久久久第一区二区| 成人小视频免费观看| 日韩欧美成人一区| 国产喷白浆一区二区三区| 国产精品看片你懂得| 亚洲美女精品一区| 麻豆国产91在线播放| 国产成人免费视频网站| 91成人免费在线视频| 日韩欧美国产综合一区 | 五月天激情综合网| 蓝色福利精品导航| 4438x亚洲最大成人网| 日韩写真欧美这视频| 国产精品无码永久免费888| 夜夜嗨av一区二区三区四季av| 男女男精品网站| 一本色道久久综合亚洲aⅴ蜜桃 | 色综合久久中文字幕综合网| 欧美人牲a欧美精品| 国产欧美日韩综合| 午夜欧美在线一二页| 成人妖精视频yjsp地址| 国产精品麻豆一区二区| 午夜av电影一区| 国产成人精品免费网站| 欧美久久久一区| 中文字幕一区二区三区在线不卡| 日本vs亚洲vs韩国一区三区| 91色porny| 欧美激情在线一区二区三区| 污片在线观看一区二区| 99视频热这里只有精品免费| 欧美大白屁股肥臀xxxxxx| 一个色妞综合视频在线观看| 国产电影一区在线| 日韩一区二区免费在线电影| 麻豆一区二区三| 欧美体内she精视频| 国产日韩欧美a| 黄色日韩网站视频| 日韩欧美色电影| 日韩高清不卡在线| 欧美色图激情小说| 亚洲精品中文在线| 97久久超碰国产精品| 国产欧美精品一区aⅴ影院 | 日韩欧美一卡二卡| 国产福利一区在线观看| 欧美一区二区三区色| 亚洲国产精品久久久久秋霞影院| va亚洲va日韩不卡在线观看| 国产嫩草影院久久久久| 国产成人在线电影| 亚洲国产成人私人影院tom| 国产精品自拍毛片| 国产日韩三级在线| 丰满岳乱妇一区二区三区| 久久亚洲精品国产精品紫薇| 激情综合色综合久久综合| 精品剧情在线观看| 国内精品视频一区二区三区八戒| 精品国产一区二区三区不卡| 91丨porny丨中文| 亚洲欧美一区二区三区国产精品| 99在线精品一区二区三区| 亚洲视频中文字幕| 色吧成人激情小说| 日韩高清欧美激情| 欧美mv日韩mv| 成人黄色国产精品网站大全在线免费观看 | 欧洲一区在线电影| 日日噜噜夜夜狠狠视频欧美人| 欧美精品九九99久久| aaa亚洲精品| 一区二区欧美在线观看| 欧美影片第一页| 青椒成人免费视频| 久久久美女毛片| 不卡大黄网站免费看| 亚洲夂夂婷婷色拍ww47| 日韩欧美高清一区| 成人少妇影院yyyy| 亚洲一区二区三区中文字幕| 欧美一区二区三区免费在线看 | 91丨九色丨国产丨porny| 一区二区三区四区不卡在线| 欧美激情一区二区| 在线中文字幕一区| 韩日精品视频一区| 亚洲免费观看在线视频| 欧美一卡2卡三卡4卡5免费| 国产v综合v亚洲欧| 午夜影院久久久| 国产视频视频一区| 欧美日本韩国一区| 高清在线观看日韩| 日韩精品电影在线| 国产精品中文字幕一区二区三区| 中文字幕在线免费不卡| 大陆成人av片| 亚洲成人中文在线| 亚洲精品一区二区三区蜜桃下载 | 日本不卡视频在线观看| 国产亚洲一区二区三区在线观看| 91国产视频在线观看| 国产一区二区三区高清播放| 亚洲一区在线播放| 国产精品九色蝌蚪自拍| 精品国产污污免费网站入口| 日韩亚洲欧美成人一区| 97久久精品人人做人人爽| 国产乱码精品一区二区三| 日韩av一级电影| 一区二区三区在线视频播放| 国产午夜亚洲精品不卡| 欧美成人三级在线| 欧美日韩色一区| 91福利在线看| 97精品超碰一区二区三区| 精品一区二区综合| 午夜av一区二区| 亚洲一区二区三区爽爽爽爽爽| 欧美国产一区二区在线观看| 欧美精品一区二区久久婷婷| 欧美一级欧美三级在线观看| 精品剧情v国产在线观看在线| 欧美日韩精品一区二区天天拍小说 | 亚洲免费观看高清完整版在线观看熊| 久久久亚洲高清| 欧美不卡在线视频| 日韩亚洲欧美一区二区三区| 欧美高清精品3d| 欧美喷潮久久久xxxxx| 91福利在线免费观看| 91福利社在线观看| 欧美天堂亚洲电影院在线播放| 在线免费不卡视频| 欧美日韩精品三区| 欧美精品色一区二区三区| 欧美性生活一区| 亚洲国产精品成人综合色在线婷婷| 日韩欧美综合在线| 2023国产精品自拍| 久久久久综合网| 国产精品的网站| 亚洲精品久久7777| 亚洲综合视频在线观看| 日韩中文字幕亚洲一区二区va在线| 亚洲大片在线观看| 捆绑调教一区二区三区| 国产精品羞羞答答xxdd| gogogo免费视频观看亚洲一| 91麻豆福利精品推荐| 欧美午夜不卡视频| 精品国偷自产国产一区| 亚洲国产成人在线| 亚洲va欧美va国产va天堂影院| 日韩精品电影在线观看| 91老师片黄在线观看| 9191国产精品| 国产亚洲人成网站| 一区二区欧美在线观看| 男女男精品网站| av在线不卡免费看| 在线播放亚洲一区| 欧美国产欧美综合| 午夜精品久久久久久久99水蜜桃| 国产一区二区三区在线观看免费视频 | 成人av在线资源网| 91黄色小视频| 国产丝袜在线精品| 午夜精品久久久久久不卡8050| 国产一区二区看久久| 欧洲国产伦久久久久久久| 亚洲精品在线观| 亚洲第四色夜色| av在线不卡免费看| 精品国产乱码久久久久久蜜臀 | 欧美精品久久99| 国产精品免费久久| 美女一区二区三区在线观看| 97se亚洲国产综合自在线观| 欧美大片一区二区三区|