[project @ 1996-07-19 18:36:04 by partain]
[ghc-hetmet.git] / ghc / misc / spat-analysers / show_icounts
1 #! /usr/local/bin/perl
2 #
3 %Datum = ();
4
5 &init();
6
7 $BigTotal = 0;
8
9 while (<>) {
10     chop;
11     next if ! /^\s*(\d+): (.*)/;
12     $op_code = $1;
13     @num = split(/\s+/, $2);
14
15     $op_category = $Opcode2Cat{$op_code};
16
17     die "num = $#num\n" if $#num != 21;
18
19     for($i = 0; $i <= $#num; $i++) {
20         next if $num[$i] == 0;
21
22         $act = $ActivityName[$i];
23
24         $Datum{"$act/$op_category"} += $num[$i];
25         $TotPerCat{$op_category}    += $num[$i];
26         $BigTotal                   += $num[$i];
27     }
28 }
29
30 #print a header
31 printf STDOUT "%12s", "";
32 foreach $opcat (@ListOfCats) { printf STDOUT " %11s", $opcat; }
33 printf STDOUT " %11s %s\n", 'TOTAL', " \%age";
34
35 # print the collected goods
36 %tot_for_opcat = ();
37 foreach $act ( @ListOfActivities ) {
38     printf STDOUT "%-12s", $act;
39     $tot_for_act = 0;
40
41     foreach $opcat (@ListOfCats) {
42         $datum = $Datum{"$act/$opcat"};
43         printf STDOUT " %11s", &commas($datum);
44         $tot_for_act           += $datum;
45         $tot_for_opcat{$opcat} += $datum;
46     }
47     printf STDOUT "%12s %5.1f%%\n", &commas($tot_for_act), (($tot_for_act / $BigTotal) * 100.0);
48 }
49
50 foreach $k ( keys %TotPerCat ) {
51     die "category ($k) totals don't match: $TotPerCat{$k} != $tot_for_opcat{$k}\n"
52         if $TotPerCat{$k} != $tot_for_opcat{$k};
53 }
54 foreach $k ( keys %tot_for_opcat ) {
55     die "category ($k) totals don't match: $TotPerCat{$k} != $tot_for_opcat{$k}\n"
56         if $TotPerCat{$k} != $tot_for_opcat{$k};
57 }
58
59 #print totals by category and percentages
60 printf STDOUT "\n%-12s", '*Totals*';
61 $tot_to_chk = 0;
62 foreach $opcat (@ListOfCats) {
63     printf STDOUT " %11s", &commas($TotPerCat{$opcat});
64     $tot_to_chk += $TotPerCat{$opcat};
65 }
66
67 printf STDOUT "%12s\n%-12s", &commas($BigTotal), '';
68
69 die "Totals don't match: $tot_to_chk != $BigTotal\n" if $tot_to_chk != $BigTotal;
70
71 foreach $opcat (@ListOfCats) {
72     printf STDOUT " %10.1f%%", (($TotPerCat{$opcat} / $BigTotal) * 100.0);
73 }
74 printf STDOUT "\n";
75
76 # utils:
77
78 sub commas {    # put commas into long integer numbers
79     local($_) = @_;
80
81     s/^\+//;
82
83     s/(\d)(\d\d\d)$/$1,$2/;
84     while ( /\d\d\d\d,/ ) {
85         s/(\d)(\d\d\d)\,/$1,$2,/;
86     }
87     $_;
88 }
89
90 sub init {
91     # order is important!
92     @ActivityName = ( 'UNKNOWN', 'GC', 'OTHER_REDN', 'ASTK_STUB',
93             'FILL_IN_HEAP', 'HEAP_CHK', 'RETURN',
94             'UPDATE', 'PUSH_UPDF', 'ARGS_CHK', 'UPDATE_PAP',
95             'INDIRECT', 'XXX_12', 'XXX_13', 'OVERHEAD', 'TAILCALL',
96             'CALL', 'STKADJ', 'ASTK', 'BSTK', 'RETREG', 'ARGREGS' );
97
98     @ListOfActivities = ( # print order
99             'ASTK_STUB', 'FILL_IN_HEAP', 'HEAP_CHK',
100             'RETURN', 'TAILCALL', 'UPDATE', 'PUSH_UPDF', 'UPDATE_PAP',
101             'INDIRECT', 'ARGS_CHK',
102             'CALL', 'STKADJ', 'ASTK', 'BSTK', 'RETREG', 'ARGREGS',
103             'OTHER_REDN', 'GC', 'UNKNOWN', 'OVERHEAD' );
104
105     @ListOfCats = ('LD', 'ST', 'ARITH', 'BR', 'SETHI', 'NOP', 'OTHER'); # 'FL-PT', 
106     %Opcode2Cat = ();
107
108     $Opcode2Cat{'0'} =  'ARITH';    # IH_ADD
109     $Opcode2Cat{'1'} =  'ARITH';    # IH_ADDCC
110     $Opcode2Cat{'2'} =  'ARITH';    # IH_ADDX
111     $Opcode2Cat{'3'} =  'ARITH';    # IH_ADDXCC
112     $Opcode2Cat{'4'} =  'ARITH';    # IH_AND
113     $Opcode2Cat{'5'} =  'ARITH';    # IH_ANDCC
114     $Opcode2Cat{'6'} =  'ARITH';    # IH_ANDN
115     $Opcode2Cat{'7'} =  'ARITH';    # IH_ANDNCC
116     $Opcode2Cat{'8'} =  'BR';       # IH_BA
117     $Opcode2Cat{'9'} =  'BR';       # IH_BAA
118     $Opcode2Cat{'10'} = 'BR';       # IH_BCC
119     $Opcode2Cat{'11'} = 'BR';       # IH_BCCA
120     $Opcode2Cat{'12'} = 'BR';       # IH_BCS
121     $Opcode2Cat{'13'} = 'BR';       # IH_BCSA
122     $Opcode2Cat{'14'} = 'BR';       # IH_BE
123     $Opcode2Cat{'15'} = 'BR';       # IH_BEA
124     $Opcode2Cat{'16'} = 'BR';       # IH_BG
125     $Opcode2Cat{'17'} = 'BR';       # IH_BGA
126     $Opcode2Cat{'18'} = 'BR';       # IH_BGE
127     $Opcode2Cat{'19'} = 'BR';       # IH_BGEA
128     $Opcode2Cat{'20'} = 'BR';       # IH_BGU
129     $Opcode2Cat{'21'} = 'BR';       # IH_BGUA
130     $Opcode2Cat{'22'} = 'BR';       # IH_BL
131     $Opcode2Cat{'23'} = 'BR';       # IH_BLA
132     $Opcode2Cat{'24'} = 'BR';       # IH_BLE
133     $Opcode2Cat{'25'} = 'BR';       # IH_BLEA
134     $Opcode2Cat{'26'} = 'BR';       # IH_BLEU
135     $Opcode2Cat{'27'} = 'BR';       # IH_BLEUA
136     $Opcode2Cat{'28'} = 'BR';       # IH_BN
137     $Opcode2Cat{'29'} = 'BR';       # IH_BNA
138     $Opcode2Cat{'30'} = 'BR';       # IH_BNE
139     $Opcode2Cat{'31'} = 'BR';       # IH_BNEA
140     $Opcode2Cat{'32'} = 'BR';       # IH_BNEG
141     $Opcode2Cat{'33'} = 'BR';       # IH_BNEGA
142     $Opcode2Cat{'34'} = 'BR';       # IH_BPOS
143     $Opcode2Cat{'35'} = 'BR';       # IH_BPOSA
144     $Opcode2Cat{'36'} = 'BR';       # IH_BVC
145     $Opcode2Cat{'37'} = 'BR';       # IH_BVCA
146     $Opcode2Cat{'38'} = 'BR';       # IH_BVS
147     $Opcode2Cat{'39'} = 'BR';       # IH_BVSA
148     $Opcode2Cat{'40'} = 'BR';       # IH_CALL
149     $Opcode2Cat{'41'} = 'OTHER';    # IH_CB0
150     $Opcode2Cat{'42'} = 'OTHER';    # IH_CB0A
151     $Opcode2Cat{'43'} = 'OTHER';    # IH_CB01
152     $Opcode2Cat{'44'} = 'OTHER';    # IH_CB01A
153     $Opcode2Cat{'45'} = 'OTHER';    # IH_CB012
154     $Opcode2Cat{'46'} = 'OTHER';    # IH_CB012A
155     $Opcode2Cat{'47'} = 'OTHER';    # IH_CB013
156     $Opcode2Cat{'48'} = 'OTHER';    # IH_CB013A
157     $Opcode2Cat{'49'} = 'OTHER';    # IH_CB02
158     $Opcode2Cat{'50'} = 'OTHER';    # IH_CB02A
159     $Opcode2Cat{'51'} = 'OTHER';    # IH_CB023
160     $Opcode2Cat{'52'} = 'OTHER';    # IH_CB023A
161     $Opcode2Cat{'53'} = 'OTHER';    # IH_CB03
162     $Opcode2Cat{'54'} = 'OTHER';    # IH_CB03A
163     $Opcode2Cat{'55'} = 'OTHER';    # IH_CB1
164     $Opcode2Cat{'56'} = 'OTHER';    # IH_CB1A
165     $Opcode2Cat{'57'} = 'OTHER';    # IH_CB12
166     $Opcode2Cat{'58'} = 'OTHER';    # IH_CB12A
167     $Opcode2Cat{'59'} = 'OTHER';    # IH_CB123
168     $Opcode2Cat{'60'} = 'OTHER';    # IH_CB123A
169     $Opcode2Cat{'61'} = 'OTHER';    # IH_CB13
170     $Opcode2Cat{'62'} = 'OTHER';    # IH_CB13A
171     $Opcode2Cat{'63'} = 'OTHER';    # IH_CB2
172     $Opcode2Cat{'64'} = 'OTHER';    # IH_CB2A
173     $Opcode2Cat{'65'} = 'OTHER';    # IH_CB23
174     $Opcode2Cat{'66'} = 'OTHER';    # IH_CB23A
175     $Opcode2Cat{'67'} = 'OTHER';    # IH_CB3
176     $Opcode2Cat{'68'} = 'OTHER';    # IH_CB3A
177     $Opcode2Cat{'69'} = 'OTHER';    # IH_CBA
178     $Opcode2Cat{'70'} = 'OTHER';    # IH_CBAA
179     $Opcode2Cat{'71'} = 'OTHER';    # IH_CBN
180     $Opcode2Cat{'72'} = 'OTHER';    # IH_CBNA
181     $Opcode2Cat{'73'} = 'OTHER';    # IH_CPOP1
182     $Opcode2Cat{'74'} = 'OTHER';    # IH_CPOP2
183     $Opcode2Cat{'75'} = 'OTHER'; # 'FL-PT';    # IH_FABSS
184     $Opcode2Cat{'76'} = 'OTHER'; # 'FL-PT';    # IH_FADDD
185     $Opcode2Cat{'77'} = 'OTHER'; # 'FL-PT';    # IH_FADDQ
186     $Opcode2Cat{'78'} = 'OTHER'; # 'FL-PT';    # IH_FADDS
187     $Opcode2Cat{'79'} = 'OTHER'; # 'FL-PT';    # IH_FBA
188     $Opcode2Cat{'80'} = 'OTHER'; # 'FL-PT';    # IH_FBAA
189     $Opcode2Cat{'81'} = 'OTHER'; # 'FL-PT';    # IH_FBE
190     $Opcode2Cat{'82'} = 'OTHER'; # 'FL-PT';    # IH_FBEA
191     $Opcode2Cat{'83'} = 'OTHER'; # 'FL-PT';    # IH_FBG
192     $Opcode2Cat{'84'} = 'OTHER'; # 'FL-PT';    # IH_FBGA
193     $Opcode2Cat{'85'} = 'OTHER'; # 'FL-PT';    # IH_FBGE
194     $Opcode2Cat{'86'} = 'OTHER'; # 'FL-PT';    # IH_FBGEA
195     $Opcode2Cat{'87'} = 'OTHER'; # 'FL-PT';    # IH_FBL
196     $Opcode2Cat{'88'} = 'OTHER'; # 'FL-PT';    # IH_FBLA
197     $Opcode2Cat{'89'} = 'OTHER'; # 'FL-PT';    # IH_FBLE
198     $Opcode2Cat{'90'} = 'OTHER'; # 'FL-PT';    # IH_FBLEA
199     $Opcode2Cat{'91'} = 'OTHER'; # 'FL-PT';    # IH_FBLG
200     $Opcode2Cat{'92'} = 'OTHER'; # 'FL-PT';    # IH_FBLGA
201     $Opcode2Cat{'93'} = 'OTHER'; # 'FL-PT';    # IH_FBN
202     $Opcode2Cat{'94'} = 'OTHER'; # 'FL-PT';    # IH_FBNA
203     $Opcode2Cat{'95'} = 'OTHER'; # 'FL-PT';    # IH_FBNE
204     $Opcode2Cat{'96'} = 'OTHER'; # 'FL-PT';    # IH_FBNEA
205     $Opcode2Cat{'97'} = 'OTHER'; # 'FL-PT';    # IH_FBO
206     $Opcode2Cat{'98'} = 'OTHER'; # 'FL-PT';    # IH_FBOA
207     $Opcode2Cat{'99'} = 'OTHER'; # 'FL-PT';    # IH_FBU
208     $Opcode2Cat{'100'} =    'OTHER'; # 'FL-PT'; # IH_FBUA
209     $Opcode2Cat{'101'} =    'OTHER'; # 'FL-PT'; # IH_FBUE
210     $Opcode2Cat{'102'} =    'OTHER'; # 'FL-PT'; # IH_FBUEA
211     $Opcode2Cat{'103'} =    'OTHER'; # 'FL-PT'; # IH_FBUG
212     $Opcode2Cat{'104'} =    'OTHER'; # 'FL-PT'; # IH_FBUGA
213     $Opcode2Cat{'105'} =    'OTHER'; # 'FL-PT'; # IH_FBUGE
214     $Opcode2Cat{'106'} =    'OTHER'; # 'FL-PT'; # IH_FBUGEA
215     $Opcode2Cat{'107'} =    'OTHER'; # 'FL-PT'; # IH_FBUL
216     $Opcode2Cat{'108'} =    'OTHER'; # 'FL-PT'; # IH_FBULA
217     $Opcode2Cat{'109'} =    'OTHER'; # 'FL-PT'; # IH_FBULE
218     $Opcode2Cat{'110'} =    'OTHER'; # 'FL-PT'; # IH_FBULEA
219     $Opcode2Cat{'111'} =    'OTHER'; # 'FL-PT'; # IH_FCMPD
220     $Opcode2Cat{'112'} =    'OTHER'; # 'FL-PT'; # IH_FCMPED
221     $Opcode2Cat{'113'} =    'OTHER'; # 'FL-PT'; # IH_FCMPEQ
222     $Opcode2Cat{'114'} =    'OTHER'; # 'FL-PT'; # IH_FCMPES
223     $Opcode2Cat{'115'} =    'OTHER'; # 'FL-PT'; # IH_FCMPQ
224     $Opcode2Cat{'116'} =    'OTHER'; # 'FL-PT'; # IH_FCMPS
225     $Opcode2Cat{'117'} =    'OTHER'; # 'FL-PT'; # IH_FDIVD
226     $Opcode2Cat{'118'} =    'OTHER'; # 'FL-PT'; # IH_FDIVQ
227     $Opcode2Cat{'119'} =    'OTHER'; # 'FL-PT'; # IH_FDIVS
228     $Opcode2Cat{'120'} =    'OTHER'; # 'FL-PT'; # IH_FDMULQ
229     $Opcode2Cat{'121'} =    'OTHER'; # 'FL-PT'; # IH_FDTOI
230     $Opcode2Cat{'122'} =    'OTHER'; # 'FL-PT'; # IH_FDTOQ
231     $Opcode2Cat{'123'} =    'OTHER'; # 'FL-PT'; # IH_FDTOS
232     $Opcode2Cat{'124'} =    'OTHER'; # 'FL-PT'; # IH_FITOD
233     $Opcode2Cat{'125'} =    'OTHER'; # 'FL-PT'; # IH_FITOQ
234     $Opcode2Cat{'126'} =    'OTHER'; # 'FL-PT'; # IH_FITOS
235     $Opcode2Cat{'127'} =    'OTHER';    # IH_FLUSH
236     $Opcode2Cat{'128'} =    'OTHER'; # 'FL-PT'; # IH_FMOVS
237     $Opcode2Cat{'129'} =    'OTHER'; # 'FL-PT'; # IH_FMULD
238     $Opcode2Cat{'130'} =    'OTHER'; # 'FL-PT'; # IH_FMULQ
239     $Opcode2Cat{'131'} =    'OTHER'; # 'FL-PT'; # IH_FMULS
240     $Opcode2Cat{'132'} =    'OTHER'; # 'FL-PT'; # IH_FNEGS
241     $Opcode2Cat{'133'} =    'OTHER'; # 'FL-PT'; # IH_FQTOD
242     $Opcode2Cat{'134'} =    'OTHER'; # 'FL-PT'; # IH_FQTOI
243     $Opcode2Cat{'135'} =    'OTHER'; # 'FL-PT'; # IH_FQTOS
244     $Opcode2Cat{'136'} =    'OTHER'; # 'FL-PT'; # IH_FSMULD
245     $Opcode2Cat{'137'} =    'OTHER'; # 'FL-PT'; # IH_FSQRTD
246     $Opcode2Cat{'138'} =    'OTHER'; # 'FL-PT'; # IH_FSQRTQ
247     $Opcode2Cat{'139'} =    'OTHER'; # 'FL-PT'; # IH_FSQRTS
248     $Opcode2Cat{'140'} =    'OTHER'; # 'FL-PT'; # IH_FSTOD
249     $Opcode2Cat{'141'} =    'OTHER'; # 'FL-PT'; # IH_FSTOI
250     $Opcode2Cat{'142'} =    'OTHER'; # 'FL-PT'; # IH_FSTOQ
251     $Opcode2Cat{'143'} =    'OTHER'; # 'FL-PT'; # IH_FSUBD
252     $Opcode2Cat{'144'} =    'OTHER'; # 'FL-PT'; # IH_FSUBQ
253     $Opcode2Cat{'145'} =    'OTHER'; # 'FL-PT'; # IH_FSUBS
254     $Opcode2Cat{'146'} =    'BR';       # IH_JMPL
255     $Opcode2Cat{'147'} =    'LD';   # IH_LD
256     $Opcode2Cat{'148'} =    'LD';   # IH_LDA
257     $Opcode2Cat{'149'} =    'LD';   # IH_LDC
258     $Opcode2Cat{'150'} =    'LD';   # IH_LDCSR
259     $Opcode2Cat{'151'} =    'LD';   # IH_LDD
260     $Opcode2Cat{'152'} =    'LD';   # IH_LDDA
261     $Opcode2Cat{'153'} =    'LD';   # IH_LDDC
262     $Opcode2Cat{'154'} =    'LD';   # IH_LDDF
263     $Opcode2Cat{'155'} =    'LD';   # IH_LDF
264     $Opcode2Cat{'156'} =    'LD';   # IH_LDFSR
265     $Opcode2Cat{'157'} =    'LD';   # IH_LDSB
266     $Opcode2Cat{'158'} =    'LD';   # IH_LDSBA
267     $Opcode2Cat{'159'} =    'LD';   # IH_LDSH
268     $Opcode2Cat{'160'} =    'LD';   # IH_LDSHA
269     $Opcode2Cat{'161'} =    'LD';   # IH_LDSTUB
270     $Opcode2Cat{'162'} =    'LD';   # IH_LDSTUBA
271     $Opcode2Cat{'163'} =    'LD';   # IH_LDUB
272     $Opcode2Cat{'164'} =    'LD';   # IH_LDUBA
273     $Opcode2Cat{'165'} =    'LD';   # IH_LDUH
274     $Opcode2Cat{'166'} =    'LD';   # IH_LDUHA
275     $Opcode2Cat{'167'} =    'ARITH';   # IH_MULSCC
276     $Opcode2Cat{'168'} =    'NOP';   # IH_NOP
277     $Opcode2Cat{'169'} =    'ARITH';    # IH_OR
278     $Opcode2Cat{'170'} =    'ARITH';    # IH_ORCC
279     $Opcode2Cat{'171'} =    'ARITH';    # IH_ORN
280     $Opcode2Cat{'172'} =    'ARITH';    # IH_ORNCC
281     $Opcode2Cat{'173'} =    'OTHER';    # IH_RDASR
282     $Opcode2Cat{'174'} =    'OTHER';    # IH_RDPSR
283     $Opcode2Cat{'175'} =    'OTHER';    # IH_RDTBR
284     $Opcode2Cat{'176'} =    'OTHER';    # IH_RDWIM
285     $Opcode2Cat{'177'} =    'OTHER';    # IH_RDY
286     $Opcode2Cat{'178'} =    'OTHER';    # IH_RESTORE
287     $Opcode2Cat{'179'} =    'OTHER';    # IH_RETT
288     $Opcode2Cat{'180'} =    'OTHER';    # IH_SAVE
289     $Opcode2Cat{'181'} =    'ARITH';    # IH_SDIV
290     $Opcode2Cat{'182'} =    'ARITH';    # IH_SDIVCC
291     $Opcode2Cat{'183'} =    'SETHI';    # IH_SETHI
292     $Opcode2Cat{'184'} =    'ARITH';    # IH_SLL
293     $Opcode2Cat{'185'} =    'ARITH';    # IH_SMUL
294     $Opcode2Cat{'186'} =    'ARITH';    # IH_SMULCC
295     $Opcode2Cat{'187'} =    'ARITH';    # IH_SRA
296     $Opcode2Cat{'188'} =    'ARITH';    # IH_SRL
297     $Opcode2Cat{'189'} =    'ST';   # IH_ST
298     $Opcode2Cat{'190'} =    'ST';   # IH_STA
299     $Opcode2Cat{'191'} =    'ST';   # IH_STB
300     $Opcode2Cat{'192'} =    'ST';   # IH_STBA
301     $Opcode2Cat{'193'} =    'ST';   # IH_STBAR
302     $Opcode2Cat{'194'} =    'ST';   # IH_STC
303     $Opcode2Cat{'195'} =    'ST';   # IH_STCSR
304     $Opcode2Cat{'196'} =    'ST';   # IH_STD
305     $Opcode2Cat{'197'} =    'ST';   # IH_STDA
306     $Opcode2Cat{'198'} =    'ST';   # IH_STDC
307     $Opcode2Cat{'199'} =    'ST';   # IH_STDCQ
308     $Opcode2Cat{'200'} =    'ST';   # IH_STDF
309     $Opcode2Cat{'201'} =    'ST';   # IH_STDFQ
310     $Opcode2Cat{'202'} =    'ST';   # IH_STF
311     $Opcode2Cat{'203'} =    'ST';   # IH_STFSR
312     $Opcode2Cat{'204'} =    'ST';   # IH_STH
313     $Opcode2Cat{'205'} =    'ST';   # IH_STHA
314     $Opcode2Cat{'206'} =    'ARITH';    # IH_SUB
315     $Opcode2Cat{'207'} =    'ARITH';    # IH_SUBCC
316     $Opcode2Cat{'208'} =    'ARITH';    # IH_SUBX
317     $Opcode2Cat{'209'} =    'ARITH';    # IH_SUBXCC
318     $Opcode2Cat{'210'} =    'OTHER';    # IH_SWAP
319     $Opcode2Cat{'211'} =    'OTHER';    # IH_SWAPA
320     $Opcode2Cat{'212'} =    'OTHER';    # IH_TA
321     $Opcode2Cat{'213'} =    'OTHER';    # IH_TADDCC
322     $Opcode2Cat{'214'} =    'OTHER';    # IH_TADDCCTV
323     $Opcode2Cat{'215'} =    'OTHER';    # IH_TCC
324     $Opcode2Cat{'216'} =    'OTHER';    # IH_TCS
325     $Opcode2Cat{'217'} =    'OTHER';    # IH_TE
326     $Opcode2Cat{'218'} =    'OTHER';    # IH_TG
327     $Opcode2Cat{'219'} =    'OTHER';    # IH_TGE
328     $Opcode2Cat{'220'} =    'OTHER';    # IH_TGU
329     $Opcode2Cat{'221'} =    'OTHER';    # IH_TL
330     $Opcode2Cat{'222'} =    'OTHER';    # IH_TLE
331     $Opcode2Cat{'223'} =    'OTHER';    # IH_TLEU
332     $Opcode2Cat{'224'} =    'OTHER';    # IH_TN
333     $Opcode2Cat{'225'} =    'OTHER';    # IH_TNE
334     $Opcode2Cat{'226'} =    'OTHER';    # IH_TNEG
335     $Opcode2Cat{'227'} =    'OTHER';    # IH_TPOS
336     $Opcode2Cat{'228'} =    'OTHER';    # IH_TSUBCC
337     $Opcode2Cat{'229'} =    'OTHER';    # IH_TSUBCCTV
338     $Opcode2Cat{'230'} =    'OTHER';    # IH_TVC
339     $Opcode2Cat{'231'} =    'OTHER';    # IH_TVS
340     $Opcode2Cat{'232'} =    'ARITH';    # IH_UDIV
341     $Opcode2Cat{'233'} =    'ARITH';    # IH_UDIVCC
342     $Opcode2Cat{'234'} =    'ARITH';    # IH_UMUL
343     $Opcode2Cat{'235'} =    'ARITH';    # IH_UMULCC
344     $Opcode2Cat{'236'} =    'OTHER';    # IH_UNIMP
345     $Opcode2Cat{'237'} =    'OTHER';    # IH_WRASR
346     $Opcode2Cat{'238'} =    'OTHER';    # IH_WRPSR
347     $Opcode2Cat{'239'} =    'OTHER';    # IH_WRTBR
348     $Opcode2Cat{'240'} =    'OTHER';    # IH_WRWIM
349     $Opcode2Cat{'241'} =    'OTHER';    # IH_WRY
350     $Opcode2Cat{'242'} =    'ARITH';    # IH_XNOR
351     $Opcode2Cat{'243'} =    'ARITH';    # IH_XNORCC
352     $Opcode2Cat{'244'} =    'ARITH';    # IH_XOR
353     $Opcode2Cat{'245'} =    'ARITH';    # IH_XORCC
354 }