hns - 日記自動生成システム - Version 2.19.9

先月 2007年08月 来月
1 2 3 4
5 6 7 8 9 10 11
12 13 14 15 16 17 18
19 20 21 22 23 24 25
26 27 28 29 30 31
Namazu for hns による簡易全文検索
詳しくは 詳細指定/ヘルプを参照して下さい
検索式:

2007年08月23日(木) 旧暦 [n年日記] [更新:"2007/08/23 14:55:48"]

#1 [Lang] width of 'count' exceeds its type

次のように言われるのは、どういうことが考えられるでしょうか ?
In file included from ../../src/gcc/crtstuff.c:71:
src/gcc/unwind-dw2-fde.h:65: error: width of 'count' exceeds its type
関係する部分は次の通りです
 46  struct object
 47  {
 48    void *pc_begin;
 49    void *tbase;
 50    void *dbase;
 51    union {
 52      const struct dwarf_fde *single;
 53      struct dwarf_fde **array;
 54      struct fde_vector *sort;
 55    } u;
 56  
 57    union {
 58      struct {
 59        unsigned long sorted : 1;
 60        unsigned long from_array : 1;
 61        unsigned long mixed_encoding : 1;
 62        unsigned long encoding : 8;
 63        /* ??? Wish there was an easy way to detect a 64-bit host here;
 64           we've got 32 bits left to play with...  */
 65        unsigned long count : 21;
 66      } b;
 67      size_t i;
 68    } s;
 69  
 70  #ifdef DWARF2_OBJECT_END_PTR_EXTENSION
 71    char *fde_end;
 72  #endif
 73  
 74    struct object *next;
 75  };
  • 65 行目の 21 を 16 にすると、上の誤りは表示されません (でもそうすると、後で Segfault します)。
  • 65 行目の unsigned long を unsigned long long としても上と同じ
  • its type って言っているけれど、「その型」とは、どういう型 ?
  • この部分は、gcc 4.1.1 4.2.1 のどちらでも同じ、実績のある記述です (unwind-dw2-fde.h 等、何も変更していません)
  • 当然別のどこかを変にいじっているから問題な訳だけれど、どうやって ここに影響する ?
  • unsigned long の型を変更している ?
  • unsigned long が 16 bit で unsigned int が 8 bit (?)
gcc/crtstuff.c
    60  #include "auto-host.h"
    61  #undef gid_t
    62  #undef pid_t
    63  #undef rlim_t
    64  #undef ssize_t
    65  #undef uid_t
    66  #undef vfork
    67  #include "tconfig.h"
    68  #include "tsystem.h"
    69  #include "coretypes.h"
    70  #include "tm.h"
    71  #include "unwind-dw2-fde.h"
かなりありそう ... 青字は生成されるもの



最近の日記
2024年03月10日
停電 (瞬電)
2024年03月03日
the second try on bare-metal
useradd
2024年02月29日
opendkim and senmail
2024年01月24日
chat/iam 0.0.8
2024年01月21日
uselocale vs setlocale (textproc/R-readxl)
以上、1 日分です。
タイトル一覧
カテゴリ分類
Powered by hns-2.19.9, HyperNikkiSystem Project

Count.cgi (since 2000/02/05)