1 /* Copyright (C) 2021 Free Software Foundation, Inc.
4 This file is part of GNU Binutils.
6 This program is free software; you can redistribute it and/or modify
7 it under the terms of the GNU General Public License as published by
8 the Free Software Foundation; either version 3, or (at your option)
11 This program is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
16 You should have received a copy of the GNU General Public License
17 along with this program; if not, write to the Free Software
18 Foundation, 51 Franklin Street - Fifth Floor, Boston,
19 MA 02110-1301, USA. */
25 #include <sys/param.h>
28 #include "DbeSession.h"
29 #include "Experiment.h"
30 #include "Expression.h"
33 Metric::Metric (BaseMetric *item, SubType st) : BaseMetric (*item)
41 if (item->get_type () == DERIVED)
45 Metric::Metric (const Metric& item) : BaseMetric (item)
47 baseMetric = item.baseMetric;
48 subtype = item.subtype;
49 name = dbe_strdup (item.name);
50 abbr = dbe_strdup (item.abbr);
51 abbr_unit = dbe_strdup (item.abbr_unit);
52 visbits = item.visbits;
62 // Note that BaseMetric::get_vtype() has the base value type.
63 // Here, we get the value type for the displayed metric,
64 // which may be different if comparison is used.
69 ValueTag vtype = get_vtype ();
70 if (visbits & VAL_DELTA)
74 case VT_ULLONG: return VT_LLONG;
75 default: return vtype;
78 if (visbits & VAL_RATIO)
86 case VT_DOUBLE: return VT_DOUBLE;
87 default: return vtype;
94 Metric::set_subtype (SubType st)
107 abbr_unit = dbe_strdup (GTXT ("sec."));
110 name = dbe_strdup (GTXT ("Exclusive User CPU Time"));
111 abbr = dbe_strdup (GTXT ("Excl. User CPU"));
113 else if (st == INCLUSIVE)
115 name = dbe_strdup (GTXT ("Inclusive User CPU Time"));
116 abbr = dbe_strdup (GTXT ("Incl. User CPU"));
118 else if (st == ATTRIBUTED)
120 name = dbe_strdup (GTXT ("Attributed User CPU Time"));
121 abbr = dbe_strdup (GTXT ("Attr. User CPU"));
125 name = dbe_sprintf (GTXT ("Unexpected CP_LMS_USER metric subtype %d"),
127 abbr = dbe_strdup (NTXT ("??"));
132 case CP_LMS_WAIT_CPU:
133 abbr_unit = dbe_strdup (GTXT ("sec."));
136 name = dbe_strdup (GTXT ("Exclusive Wait CPU Time"));
137 abbr = dbe_strdup (GTXT ("Excl. Wait CPU"));
139 else if (st == INCLUSIVE)
141 name = dbe_strdup (GTXT ("Inclusive Wait CPU Time"));
142 abbr = dbe_strdup (GTXT ("Incl. Wait CPU"));
144 else if (st == ATTRIBUTED)
146 name = dbe_strdup (GTXT ("Attributed Wait CPU Time"));
147 abbr = dbe_strdup (GTXT ("Attr. Wait CPU"));
151 name = dbe_sprintf (GTXT ("Unexpected CP_LMS_WAIT_CPU metric subtype %d"),
153 abbr = dbe_strdup (NTXT ("??"));
157 case CP_LMS_USER_LOCK:
158 abbr_unit = dbe_strdup (GTXT ("sec."));
161 name = dbe_strdup (GTXT ("Exclusive User Lock Time"));
162 abbr = dbe_strdup (GTXT ("Excl. User Lock"));
164 else if (st == INCLUSIVE)
166 name = dbe_strdup (GTXT ("Inclusive User Lock Time"));
167 abbr = dbe_strdup (GTXT ("Incl. User Lock"));
169 else if (st == ATTRIBUTED)
171 name = dbe_strdup (GTXT ("Attributed User Lock Time"));
172 abbr = dbe_strdup (GTXT ("Attr. User Lock"));
176 name = dbe_sprintf (GTXT ("Unexpected CP_LMS_USER_LOCK metric subtype %d"),
178 abbr = dbe_strdup (NTXT ("??"));
183 abbr_unit = dbe_strdup (GTXT ("sec."));
186 name = dbe_strdup (GTXT ("Exclusive System CPU Time"));
187 abbr = dbe_strdup (GTXT ("Excl. Sys. CPU"));
189 else if (st == INCLUSIVE)
191 name = dbe_strdup (GTXT ("Inclusive System CPU Time"));
192 abbr = dbe_strdup (GTXT ("Incl. Sys. CPU"));
194 else if (st == ATTRIBUTED)
196 name = dbe_strdup (GTXT ("Attributed System CPU Time"));
197 abbr = dbe_strdup (GTXT ("Attr. Sys. CPU"));
201 name = dbe_sprintf (GTXT ("Unexpected CP_LMS_SYSTEM metric subtype %d"),
203 abbr = dbe_strdup (NTXT ("??"));
208 abbr_unit = dbe_strdup (GTXT ("sec."));
211 name = dbe_strdup (GTXT ("Exclusive Sync Wait Time"));
212 abbr = dbe_strdup (GTXT ("Excl. Sync Wait"));
214 else if (st == INCLUSIVE)
216 name = dbe_strdup (GTXT ("Inclusive Sync Wait Time"));
217 abbr = dbe_strdup (GTXT ("Incl. Sync Wait"));
219 else if (st == ATTRIBUTED)
221 name = dbe_strdup (GTXT ("Attributed Sync Wait Time"));
222 abbr = dbe_strdup (GTXT ("Attr. Sync Wait"));
226 name = dbe_sprintf (GTXT ("Unexpected LWT metric subtype %d"), st);
227 abbr = dbe_strdup (NTXT ("??"));
232 abbr_unit = dbe_strdup (GTXT ("sec."));
235 name = dbe_strdup (GTXT ("Exclusive Text Page Fault Time"));
236 abbr = dbe_strdup (GTXT ("Excl. Text Fault"));
238 else if (st == INCLUSIVE)
240 name = dbe_strdup (GTXT ("Inclusive Text Page Fault Time"));
241 abbr = dbe_strdup (GTXT ("Incl. Text Fault"));
243 else if (st == ATTRIBUTED)
245 name = dbe_strdup (GTXT ("Attributed Text Page Fault Time"));
246 abbr = dbe_strdup (GTXT ("Attr. Text Fault"));
250 name = dbe_sprintf (GTXT ("Unexpected CP_LMS_TFAULT metric subtype %d"),
252 abbr = dbe_strdup (NTXT ("??"));
257 abbr_unit = dbe_strdup (GTXT ("sec."));
260 name = dbe_strdup (GTXT ("Exclusive Data Page Fault Time"));
261 abbr = dbe_strdup (GTXT ("Excl. Data Fault"));
263 else if (st == INCLUSIVE)
265 name = dbe_strdup (GTXT ("Inclusive Data Page Fault Time"));
266 abbr = dbe_strdup (GTXT ("Incl. Data Fault"));
268 else if (st == ATTRIBUTED)
270 name = dbe_strdup (GTXT ("Attributed Data Page Fault Time"));
271 abbr = dbe_strdup (GTXT ("Attr. Data Fault"));
275 name = dbe_sprintf (GTXT ("Unexpected CP_LMS_DFAULT metric subtype %d"),
277 abbr = dbe_strdup (NTXT ("??"));
282 abbr_unit = dbe_strdup (GTXT ("sec."));
285 name = dbe_strdup (GTXT ("Exclusive Kernel CPU Time"));
286 abbr = dbe_strdup (GTXT ("Excl. Kernel CPU"));
288 else if (st == INCLUSIVE)
290 name = dbe_strdup (GTXT ("Inclusive Kernel CPU Time"));
291 abbr = dbe_strdup (GTXT ("Incl. Kernel CPU"));
293 else if (st == ATTRIBUTED)
295 name = dbe_strdup (GTXT ("Attributed Kernel CPU Time"));
296 abbr = dbe_strdup (GTXT ("Attr. Kernel CPU"));
300 name = dbe_sprintf (GTXT ("Unexpected CP_KERNEL_CPU metric subtype %d"),
302 abbr = dbe_strdup (NTXT ("??"));
308 char *sstr, *estr1, *estr2;
309 if (get_hw_ctr () == NULL)
311 sstr = get_username ();
314 estr1 = GTXT ("Exclusive ");
315 estr2 = GTXT ("Excl. ");
317 else if (st == INCLUSIVE)
319 estr1 = GTXT ("Inclusive ");
320 estr2 = GTXT ("Incl. ");
322 else if (st == ATTRIBUTED)
324 estr1 = GTXT ("Attributed ");
325 estr2 = GTXT ("Attr. ");
327 else if (st == DATASPACE)
329 estr1 = GTXT ("Data-derived ");
330 estr2 = GTXT ("Data. ");
334 estr1 = dbe_sprintf (GTXT ("Unexpected hwc %s metric subtype %d"),
336 estr2 = dbe_strdup (NTXT ("??"));
338 name = dbe_sprintf (NTXT ("%s%s"), estr1, sstr);
339 abbr = dbe_sprintf (NTXT ("%s%s"), estr2, sstr);
348 name = dbe_sprintf (GTXT ("Exclusive %s"), get_username ());
349 abbr = dbe_sprintf (GTXT ("Excl. %s"), get_cmd ());
352 name = dbe_sprintf (GTXT ("Inclusive %s"), get_username ());
353 abbr = dbe_sprintf (GTXT ("Incl. %s"), get_cmd ());
356 name = dbe_sprintf (GTXT ("Attributed %s"), get_username ());
357 abbr = dbe_sprintf (GTXT ("Attr. %s"), get_cmd ());
360 name = dbe_sprintf (GTXT ("Unexpected derived %s metric subtype %d"),
361 get_username (), st);
362 abbr = dbe_strdup (NTXT ("??"));
368 case OMP_MASTER_THREAD:
369 abbr_unit = dbe_strdup (GTXT ("sec."));
372 name = dbe_strdup (GTXT ("Exclusive Master Thread Time"));
373 abbr = dbe_strdup (GTXT ("Excl. Master Thread"));
375 else if (st == INCLUSIVE)
377 name = dbe_strdup (GTXT ("Inclusive Master Thread Time"));
378 abbr = dbe_strdup (GTXT ("Incl. Master Thread"));
380 else if (st == ATTRIBUTED)
382 name = dbe_strdup (GTXT ("Attributed Master Thread Time"));
383 abbr = dbe_strdup (GTXT ("Attr. Master Thread"));
387 name = dbe_sprintf (GTXT ("Unexpected Master Thread metric subtype %d"),
389 abbr = dbe_strdup (NTXT ("??"));
394 abbr_unit = dbe_strdup (GTXT ("sec."));
397 name = dbe_strdup (GTXT ("Exclusive Total Thread Time"));
398 abbr = dbe_strdup (GTXT ("Excl. Total Thread"));
400 else if (st == INCLUSIVE)
402 name = dbe_strdup (GTXT ("Inclusive Total Thread Time"));
403 abbr = dbe_strdup (GTXT ("Incl. Total Thread"));
405 else if (st == ATTRIBUTED)
407 name = dbe_strdup (GTXT ("Attributed Total Thread Time"));
408 abbr = dbe_strdup (GTXT ("Attr. Total Thread"));
412 name = dbe_sprintf (GTXT ("Unexpected TOTAL metric subtype %d"), st);
413 abbr = dbe_strdup (NTXT ("??"));
417 case SYNC_WAIT_COUNT:
420 name = dbe_strdup (GTXT ("Exclusive Sync Wait Count"));
421 abbr = dbe_strdup (GTXT ("Excl. Sync Wait Count"));
423 else if (st == INCLUSIVE)
425 name = dbe_strdup (GTXT ("Inclusive Sync Wait Count"));
426 abbr = dbe_strdup (GTXT ("Incl. Sync Wait Count"));
428 else if (st == ATTRIBUTED)
430 name = dbe_strdup (GTXT ("Attributed Sync Wait Count"));
431 abbr = dbe_strdup (GTXT ("Attr. Sync Wait Count"));
435 name = dbe_sprintf (GTXT ("Unexpected LWCNT metric subtype %d"), st);
436 abbr = dbe_strdup (NTXT ("??"));
441 abbr_unit = dbe_strdup (GTXT ("sec."));
444 name = dbe_strdup (GTXT ("Exclusive Total CPU Time"));
445 abbr = dbe_strdup (GTXT ("Excl. Total CPU"));
447 else if (st == INCLUSIVE)
449 name = dbe_strdup (GTXT ("Inclusive Total CPU Time"));
450 abbr = dbe_strdup (GTXT ("Incl. Total CPU"));
452 else if (st == ATTRIBUTED)
454 name = dbe_strdup (GTXT ("Attributed Total CPU Time"));
455 abbr = dbe_strdup (GTXT ("Attr. Total CPU"));
459 name = dbe_sprintf (GTXT ("Unexpected TOTAL_CPU metric subtype %d"),
461 abbr = dbe_strdup (NTXT ("??"));
465 abbr_unit = dbe_strdup (GTXT ("sec."));
468 name = dbe_strdup (GTXT ("Exclusive Trap CPU Time"));
469 abbr = dbe_strdup (GTXT ("Excl. Trap CPU"));
471 else if (st == INCLUSIVE)
473 name = dbe_strdup (GTXT ("Inclusive Trap CPU Time"));
474 abbr = dbe_strdup (GTXT ("Incl. Trap CPU"));
476 else if (st == ATTRIBUTED)
478 name = dbe_strdup (GTXT ("Attributed Trap CPU Time"));
479 abbr = dbe_strdup (GTXT ("Attr. Trap CPU"));
483 name = dbe_sprintf (GTXT ("Unexpected CP_LMS_TRAP metric subtype %d"),
485 abbr = dbe_strdup (NTXT ("??"));
490 abbr_unit = dbe_strdup (GTXT ("sec."));
493 name = dbe_strdup (GTXT ("Exclusive Kernel Page Fault Time"));
494 abbr = dbe_strdup (GTXT ("Excl. Kernel Page Fault"));
496 else if (st == INCLUSIVE)
498 name = dbe_strdup (GTXT ("Inclusive Kernel Page Fault Time"));
499 abbr = dbe_strdup (GTXT ("Incl. Kernel Page Fault"));
501 else if (st == ATTRIBUTED)
503 name = dbe_strdup (GTXT ("Attributed Kernel Page Fault Time"));
504 abbr = dbe_strdup (GTXT ("Attr. Kernel Page Fault"));
508 name = dbe_sprintf (GTXT ("Unexpected CP_LMS_KFAULT metric subtype %d"),
510 abbr = dbe_strdup (NTXT ("??"));
515 abbr_unit = dbe_strdup (GTXT ("sec."));
518 name = dbe_strdup (GTXT ("Exclusive Sleep Time"));
519 abbr = dbe_strdup (GTXT ("Excl. Sleep"));
521 else if (st == INCLUSIVE)
523 name = dbe_strdup (GTXT ("Inclusive Sleep Time"));
524 abbr = dbe_strdup (GTXT ("Incl. Sleep"));
526 else if (st == ATTRIBUTED)
528 name = dbe_strdup (GTXT ("Attributed Sleep Time"));
529 abbr = dbe_strdup (GTXT ("Attr. Sleep"));
533 name = dbe_sprintf (GTXT ("Unexpected CP_LMS_SLEEP metric subtype %d"),
535 abbr = dbe_strdup (NTXT ("??"));
540 abbr_unit = dbe_strdup (GTXT ("sec."));
543 name = dbe_strdup (GTXT ("Exclusive Stopped Time"));
544 abbr = dbe_strdup (GTXT ("Excl. Stopped"));
546 else if (st == INCLUSIVE)
548 name = dbe_strdup (GTXT ("Inclusive Stopped Time"));
549 abbr = dbe_strdup (GTXT ("Incl. Stopped"));
551 else if (st == ATTRIBUTED)
553 name = dbe_strdup (GTXT ("Attributed Stopped Time"));
554 abbr = dbe_strdup (GTXT ("Attr. Stopped"));
558 name = dbe_sprintf (GTXT ("Unexpected CP_LMS_STOPPED metric subtype %d"),
560 abbr = dbe_strdup (NTXT ("??"));
564 case HEAP_ALLOC_BYTES:
567 name = dbe_strdup (GTXT ("Exclusive Bytes Allocated"));
568 abbr = dbe_strdup (GTXT ("Excl. Bytes Allocated"));
570 else if (st == INCLUSIVE)
572 name = dbe_strdup (GTXT ("Inclusive Bytes Allocated"));
573 abbr = dbe_strdup (GTXT ("Incl. Bytes Allocated"));
575 else if (st == ATTRIBUTED)
577 name = dbe_strdup (GTXT ("Attributed Bytes Allocated"));
578 abbr = dbe_strdup (GTXT ("Attr. Bytes Allocated"));
582 name = dbe_sprintf (GTXT ("Unexpected BYTES_MALLOCD metric subtype %d"),
584 abbr = dbe_strdup (NTXT ("??"));
591 name = dbe_strdup (GTXT ("Exclusive Allocations"));
592 abbr = dbe_strdup (GTXT ("Excl. Allocations"));
594 else if (st == INCLUSIVE)
596 name = dbe_strdup (GTXT ("Inclusive Allocations"));
597 abbr = dbe_strdup (GTXT ("Incl. Allocations"));
599 else if (st == ATTRIBUTED)
601 name = dbe_strdup (GTXT ("Attributed Allocations"));
602 abbr = dbe_strdup (GTXT ("Attr. Allocations"));
606 name = dbe_sprintf (GTXT ("Unexpected MALLOCS metric subtype %d"), st);
607 abbr = dbe_strdup (NTXT ("??"));
611 case HEAP_LEAK_BYTES:
614 name = dbe_strdup (GTXT ("Exclusive Bytes Leaked"));
615 abbr = dbe_strdup (GTXT ("Excl. Bytes Leaked"));
617 else if (st == INCLUSIVE)
619 name = dbe_strdup (GTXT ("Inclusive Bytes Leaked"));
620 abbr = dbe_strdup (GTXT ("Incl. Bytes Leaked"));
622 else if (st == ATTRIBUTED)
624 name = dbe_strdup (GTXT ("Attributed Bytes Leaked"));
625 abbr = dbe_strdup (GTXT ("Attr. Bytes Leaked"));
629 name = dbe_sprintf (GTXT ("Unexpected BYTES_LEAKED metric subtype %d"),
631 abbr = dbe_strdup (NTXT ("??"));
638 name = dbe_strdup (GTXT ("Exclusive Leaks"));
639 abbr = dbe_strdup (GTXT ("Excl. Leaks"));
641 else if (st == INCLUSIVE)
643 name = dbe_strdup (GTXT ("Inclusive Leaks"));
644 abbr = dbe_strdup (GTXT ("Incl. Leaks"));
646 else if (st == ATTRIBUTED)
648 name = dbe_strdup (GTXT ("Attributed Leaks"));
649 abbr = dbe_strdup (GTXT ("Attr. Leaks"));
653 name = dbe_sprintf (GTXT ("Unexpected LEAKS metric subtype %d"), st);
654 abbr = dbe_strdup (NTXT ("??"));
661 name = dbe_strdup (GTXT ("Exclusive Read Bytes"));
662 abbr = dbe_strdup (GTXT ("Excl. Read Bytes"));
664 else if (st == INCLUSIVE)
666 name = dbe_strdup (GTXT ("Inclusive Read Bytes"));
667 abbr = dbe_strdup (GTXT ("Incl. Read Bytes"));
669 else if (st == ATTRIBUTED)
671 name = dbe_strdup (GTXT ("Attributed Read Bytes"));
672 abbr = dbe_strdup (GTXT ("Attr. Read Bytes"));
676 name = dbe_sprintf (GTXT ("Unexpected READ_BYTES metric subtype %d"), st);
677 abbr = dbe_strdup (NTXT ("??"));
684 name = dbe_strdup (GTXT ("Exclusive Write Bytes"));
685 abbr = dbe_strdup (GTXT ("Excl. Write Bytes"));
687 else if (st == INCLUSIVE)
689 name = dbe_strdup (GTXT ("Inclusive Write Bytes"));
690 abbr = dbe_strdup (GTXT ("Incl. Write Bytes"));
692 else if (st == ATTRIBUTED)
694 name = dbe_strdup (GTXT ("Attributed Write Bytes"));
695 abbr = dbe_strdup (GTXT ("Attr. Write Bytes"));
699 name = dbe_sprintf (GTXT ("Unexpected WRITE_BYTES metric subtype %d"), st);
700 abbr = dbe_strdup (NTXT ("??"));
707 name = dbe_strdup (GTXT ("Exclusive Read Count"));
708 abbr = dbe_strdup (GTXT ("Excl. Read Count"));
710 else if (st == INCLUSIVE)
712 name = dbe_strdup (GTXT ("Inclusive Read Count"));
713 abbr = dbe_strdup (GTXT ("Incl. Read Count"));
715 else if (st == ATTRIBUTED)
717 name = dbe_strdup (GTXT ("Attributed Read Count"));
718 abbr = dbe_strdup (GTXT ("Attr. Read Count"));
722 name = dbe_sprintf (GTXT ("Unexpected READCNT metric subtype %d"), st);
723 abbr = dbe_strdup (NTXT ("??"));
730 name = dbe_strdup (GTXT ("Exclusive Write Count"));
731 abbr = dbe_strdup (GTXT ("Excl. Write Count"));
733 else if (st == INCLUSIVE)
735 name = dbe_strdup (GTXT ("Inclusive Write Count"));
736 abbr = dbe_strdup (GTXT ("Incl. Write Count"));
738 else if (st == ATTRIBUTED)
740 name = dbe_strdup (GTXT ("Attributed Write Count"));
741 abbr = dbe_strdup (GTXT ("Attr. Write Count"));
745 name = dbe_sprintf (GTXT ("Unexpected WRITECNT metric subtype %d"), st);
746 abbr = dbe_strdup (NTXT ("??"));
753 name = dbe_strdup (GTXT ("Exclusive Other I/O Count"));
754 abbr = dbe_strdup (GTXT ("Excl. Other I/O Count"));
756 else if (st == INCLUSIVE)
758 name = dbe_strdup (GTXT ("Inclusive Other I/O Count"));
759 abbr = dbe_strdup (GTXT ("Incl. Other I/O Count"));
761 else if (st == ATTRIBUTED)
763 name = dbe_strdup (GTXT ("Attributed Other I/O Count"));
764 abbr = dbe_strdup (GTXT ("Attr. Other I/O Count"));
768 name = dbe_sprintf (GTXT ("Unexpected OTHERIOCNT metric subtype %d"), st);
769 abbr = dbe_strdup (NTXT ("??"));
776 name = dbe_strdup (GTXT ("Exclusive I/O Error Count"));
777 abbr = dbe_strdup (GTXT ("Excl. I/O Error Count"));
779 else if (st == INCLUSIVE)
781 name = dbe_strdup (GTXT ("Inclusive I/O Error Count"));
782 abbr = dbe_strdup (GTXT ("Incl. I/O Error Count"));
784 else if (st == ATTRIBUTED)
786 name = dbe_strdup (GTXT ("Attributed I/O Error Count"));
787 abbr = dbe_strdup (GTXT ("Attr. I/O Error Count"));
791 name = dbe_sprintf (GTXT ("Unexpected IOERRORCNT metric subtype %d"), st);
792 abbr = dbe_strdup (NTXT ("??"));
797 abbr_unit = dbe_strdup (GTXT ("sec."));
800 name = dbe_strdup (GTXT ("Exclusive Read Time"));
801 abbr = dbe_strdup (GTXT ("Excl. Read Time"));
803 else if (st == INCLUSIVE)
805 name = dbe_strdup (GTXT ("Inclusive Read Time"));
806 abbr = dbe_strdup (GTXT ("Incl. Read Time"));
808 else if (st == ATTRIBUTED)
810 name = dbe_strdup (GTXT ("Attributed Read Time"));
811 abbr = dbe_strdup (GTXT ("Attr. Read Time"));
815 name = dbe_sprintf (GTXT ("Unexpected READ_TIME metric subtype %d"), st);
816 abbr = dbe_strdup (NTXT ("??"));
821 abbr_unit = dbe_strdup (GTXT ("sec."));
824 name = dbe_strdup (GTXT ("Exclusive Write Time"));
825 abbr = dbe_strdup (GTXT ("Excl. Write Time"));
827 else if (st == INCLUSIVE)
829 name = dbe_strdup (GTXT ("Inclusive Write Time"));
830 abbr = dbe_strdup (GTXT ("Incl. Write Time"));
832 else if (st == ATTRIBUTED)
834 name = dbe_strdup (GTXT ("Attributed Write Time"));
835 abbr = dbe_strdup (GTXT ("Attr. Write Time"));
839 name = dbe_sprintf (GTXT ("Unexpected WRITE_TIME metric subtype %d"), st);
840 abbr = dbe_strdup (NTXT ("??"));
845 abbr_unit = dbe_strdup (GTXT ("sec."));
848 name = dbe_strdup (GTXT ("Exclusive Other I/O Time"));
849 abbr = dbe_strdup (GTXT ("Excl. Other I/O Time"));
851 else if (st == INCLUSIVE)
853 name = dbe_strdup (GTXT ("Inclusive Other I/O Time"));
854 abbr = dbe_strdup (GTXT ("Incl. Other I/O Time"));
856 else if (st == ATTRIBUTED)
858 name = dbe_strdup (GTXT ("Attributed Other I/O Time"));
859 abbr = dbe_strdup (GTXT ("Attr. Other I/O Time"));
863 name = dbe_sprintf (GTXT ("Unexpected OTHERIO_TIME metric subtype %d"), st);
864 abbr = dbe_strdup (NTXT ("??"));
869 abbr_unit = dbe_strdup (GTXT ("sec."));
872 name = dbe_strdup (GTXT ("Exclusive I/O Error Time"));
873 abbr = dbe_strdup (GTXT ("Excl. I/O Error Time"));
875 else if (st == INCLUSIVE)
877 name = dbe_strdup (GTXT ("Inclusive I/O Error Time"));
878 abbr = dbe_strdup (GTXT ("Incl. I/O Error Time"));
880 else if (st == ATTRIBUTED)
882 name = dbe_strdup (GTXT ("Attributed I/O Error Time"));
883 abbr = dbe_strdup (GTXT ("Attr. I/O Error Time"));
887 name = dbe_sprintf (GTXT ("Unexpected IOERROR_TIME metric subtype %d"), st);
888 abbr = dbe_strdup (NTXT ("??"));
893 name = dbe_strdup (GTXT ("Size"));
894 abbr = dbe_strdup (GTXT ("Size"));
895 abbr_unit = dbe_strdup (GTXT ("bytes"));
899 name = dbe_strdup (GTXT ("PC Address"));
900 abbr = dbe_strdup (GTXT ("PC Addr."));
904 name = dbe_strdup (GTXT ("Name"));
905 abbr = dbe_strdup (GTXT ("Name"));
909 abbr_unit = dbe_strdup (GTXT ("sec."));
912 name = dbe_strdup (GTXT ("Exclusive Non-OpenMP Time"));
913 abbr = dbe_strdup (GTXT ("Excl. Non-OMP"));
915 else if (st == INCLUSIVE)
917 name = dbe_strdup (GTXT ("Inclusive Non-OpenMP Time"));
918 abbr = dbe_strdup (GTXT ("Incl. Non-OMP"));
920 else if (st == ATTRIBUTED)
922 name = dbe_strdup (GTXT ("Attributed Non-OpenMP Time"));
923 abbr = dbe_strdup (GTXT ("Attr. Non-OMP"));
927 name = dbe_sprintf (GTXT ("Unexpected Non-OpenMP metric subtype %d"), st);
928 abbr = dbe_strdup (NTXT ("??"));
932 abbr_unit = dbe_strdup (GTXT ("sec."));
935 name = dbe_strdup (GTXT ("Exclusive OpenMP Overhead Time"));
936 abbr = dbe_strdup (GTXT ("Excl. OMP ovhd."));
938 else if (st == INCLUSIVE)
940 name = dbe_strdup (GTXT ("Inclusive OpenMP Overhead Time"));
941 abbr = dbe_strdup (GTXT ("Incl. OMP ovhd."));
943 else if (st == ATTRIBUTED)
945 name = dbe_strdup (GTXT ("Attributed OpenMP Overhead Time"));
946 abbr = dbe_strdup (GTXT ("Attr. OMP ovhd."));
950 name = dbe_sprintf (GTXT ("Unexpected OpenMP Overhead metric subtype %d"), st);
951 abbr = dbe_strdup (NTXT ("??"));
955 abbr_unit = dbe_strdup (GTXT ("sec."));
958 name = dbe_strdup (GTXT ("Exclusive OpenMP Work Time"));
959 abbr = dbe_strdup (GTXT ("Excl. OMP Work"));
961 else if (st == INCLUSIVE)
963 name = dbe_strdup (GTXT ("Inclusive OpenMP Work Time"));
964 abbr = dbe_strdup (GTXT ("Incl. OMP Work"));
966 else if (st == ATTRIBUTED)
968 name = dbe_strdup (GTXT ("Attributed OpenMP Work Time"));
969 abbr = dbe_strdup (GTXT ("Attr. OMP Work"));
973 name = dbe_sprintf (GTXT ("Unexpected OpenMP Work metric subtype %d"), st);
974 abbr = dbe_strdup (NTXT ("??"));
978 abbr_unit = dbe_strdup (GTXT ("sec."));
981 name = dbe_strdup (GTXT ("Exclusive OpenMP Implicit Barrier Time"));
982 abbr = dbe_strdup (GTXT ("Excl. OMP i-barr."));
984 else if (st == INCLUSIVE)
986 name = dbe_strdup (GTXT ("Inclusive OpenMP Implicit Barrier Time"));
987 abbr = dbe_strdup (GTXT ("Incl. OMP i-barr."));
989 else if (st == ATTRIBUTED)
991 name = dbe_strdup (GTXT ("Attributed OpenMP Implicit Barrier Time"));
992 abbr = dbe_strdup (GTXT ("Attr. OMP i-barr."));
996 name = dbe_sprintf (GTXT ("Unexpected OpenMP Implicit Barrier metric subtype %d"), st);
997 abbr = dbe_strdup (NTXT ("??"));
1001 abbr_unit = dbe_strdup (GTXT ("sec."));
1002 if (st == EXCLUSIVE)
1004 name = dbe_strdup (GTXT ("Exclusive OpenMP Explicit Barrier Time"));
1005 abbr = dbe_strdup (GTXT ("Excl. OMP e-barr."));
1007 else if (st == INCLUSIVE)
1009 name = dbe_strdup (GTXT ("Inclusive OpenMP Explicit Barrier Time"));
1010 abbr = dbe_strdup (GTXT ("Incl. OMP e-barr."));
1012 else if (st == ATTRIBUTED)
1014 name = dbe_strdup (GTXT ("Attributed OpenMP Explicit Barrier Time"));
1015 abbr = dbe_strdup (GTXT ("Attr. OMP e-barr."));
1019 name = dbe_sprintf (GTXT ("Unexpected OpenMP Explicit Barrier metric subtype %d"), st);
1020 abbr = dbe_strdup (NTXT ("??"));
1024 abbr_unit = dbe_strdup (GTXT ("sec."));
1025 if (st == EXCLUSIVE)
1027 name = dbe_strdup (GTXT ("Exclusive OpenMP Wait Time"));
1028 abbr = dbe_strdup (GTXT ("Excl. OMP Wait"));
1030 else if (st == INCLUSIVE)
1032 name = dbe_strdup (GTXT ("Inclusive OpenMP Wait Time"));
1033 abbr = dbe_strdup (GTXT ("Incl. OMP Wait"));
1035 else if (st == ATTRIBUTED)
1037 name = dbe_strdup (GTXT ("Attributed OpenMP Wait Time"));
1038 abbr = dbe_strdup (GTXT ("Attr. OMP Wait"));
1042 name = dbe_sprintf (GTXT ("Unexpected OpenMP Wait metric subtype %d"), st);
1043 abbr = dbe_strdup (NTXT ("??"));
1047 abbr_unit = dbe_strdup (GTXT ("sec."));
1048 if (st == EXCLUSIVE)
1050 name = dbe_strdup (GTXT ("Exclusive OpenMP Serial Time"));
1051 abbr = dbe_strdup (GTXT ("Excl. OMP serl"));
1053 else if (st == INCLUSIVE)
1055 name = dbe_strdup (GTXT ("Inclusive OpenMP Serial Time"));
1056 abbr = dbe_strdup (GTXT ("Incl. OMP serl"));
1058 else if (st == ATTRIBUTED)
1060 name = dbe_strdup (GTXT ("Attributed OpenMP Serial Time"));
1061 abbr = dbe_strdup (GTXT ("Attr. OMP serl"));
1065 name = dbe_sprintf (GTXT ("Unexpected OpenMP Slave Idle metric subtype %d"), st);
1066 abbr = dbe_strdup (NTXT ("??"));
1070 abbr_unit = dbe_strdup (GTXT ("sec."));
1071 if (st == EXCLUSIVE)
1073 name = dbe_strdup (GTXT ("Exclusive OpenMP Reduction Time"));
1074 abbr = dbe_strdup (GTXT ("Excl. OMP rduc"));
1076 else if (st == INCLUSIVE)
1078 name = dbe_strdup (GTXT ("Inclusive OpenMP Reduction Time"));
1079 abbr = dbe_strdup (GTXT ("Incl. OMP rduc"));
1081 else if (st == ATTRIBUTED)
1083 name = dbe_strdup (GTXT ("Attributed OpenMP Reduction Time"));
1084 abbr = dbe_strdup (GTXT ("Attr. OMP rduc"));
1088 name = dbe_sprintf (GTXT ("Unexpected OpenMP Reduction metric subtype %d"), st);
1089 abbr = dbe_strdup (NTXT ("??"));
1093 abbr_unit = dbe_strdup (GTXT ("sec."));
1094 if (st == EXCLUSIVE)
1096 name = dbe_strdup (GTXT ("Exclusive OpenMP Lock Wait Time"));
1097 abbr = dbe_strdup (GTXT ("Excl. OMP lkwt"));
1099 else if (st == INCLUSIVE)
1101 name = dbe_strdup (GTXT ("Inclusive OpenMP Lock Wait Time"));
1102 abbr = dbe_strdup (GTXT ("Incl. OMP lkwt"));
1104 else if (st == ATTRIBUTED)
1106 name = dbe_strdup (GTXT ("Attributed OpenMP Lock Wait Time"));
1107 abbr = dbe_strdup (GTXT ("Attr. OMP lkwt"));
1111 name = dbe_sprintf (GTXT ("Unexpected OpenMP Lock Wait metric subtype %d"), st);
1112 abbr = dbe_strdup (NTXT ("??"));
1116 abbr_unit = dbe_strdup (GTXT ("sec."));
1117 if (st == EXCLUSIVE)
1119 name = dbe_strdup (GTXT ("Exclusive OpenMP Critical Section Wait Time"));
1120 abbr = dbe_strdup (GTXT ("Excl. OMP ctwt"));
1122 else if (st == INCLUSIVE)
1124 name = dbe_strdup (GTXT ("Inclusive OpenMP Critical Section Wait Time"));
1125 abbr = dbe_strdup (GTXT ("Incl. OMP ctwt"));
1127 else if (st == ATTRIBUTED)
1129 name = dbe_strdup (GTXT ("Attributed OpenMP Critical Section Wait Time"));
1130 abbr = dbe_strdup (GTXT ("Attr. OMP ctwt"));
1134 name = dbe_sprintf (GTXT ("Unexpected OpenMP Critical Section Wait metric subtype %d"), st);
1135 abbr = dbe_strdup (NTXT ("??"));
1139 abbr_unit = dbe_strdup (GTXT ("sec."));
1140 if (st == EXCLUSIVE)
1142 name = dbe_strdup (GTXT ("Exclusive OpenMP Ordered Section Wait Time"));
1143 abbr = dbe_strdup (GTXT ("Excl. OMP odwt"));
1145 else if (st == INCLUSIVE)
1147 name = dbe_strdup (GTXT ("Inclusive OpenMP Ordered Section Wait Time"));
1148 abbr = dbe_strdup (GTXT ("Incl. OMP odwt"));
1150 else if (st == ATTRIBUTED)
1152 name = dbe_strdup (GTXT ("Attributed OpenMP Ordered Section Wait Time"));
1153 abbr = dbe_strdup (GTXT ("Attr. OMP odwt"));
1157 name = dbe_sprintf (GTXT ("Unexpected OpenMP Ordered Section Wait metric subtype %d"), st);
1158 abbr = dbe_strdup (NTXT ("??"));
1162 abbr_unit = dbe_strdup (GTXT ("sec."));
1163 if (st == EXCLUSIVE)
1165 name = dbe_strdup (GTXT ("Exclusive OpenMP Master Serial Time"));
1166 abbr = dbe_strdup (GTXT ("Excl. OMP ser."));
1168 else if (st == INCLUSIVE)
1170 name = dbe_strdup (GTXT ("Inclusive OpenMP Master Serial Time"));
1171 abbr = dbe_strdup (GTXT ("Incl. OMP ser."));
1173 else if (st == ATTRIBUTED)
1175 name = dbe_strdup (GTXT ("Attributed OpenMP Master Serial Time"));
1176 abbr = dbe_strdup (GTXT ("Attr. OMP ser."));
1180 name = dbe_sprintf (GTXT ("Unexpected OpenMP Master Serial metric subtype %d"), st);
1181 abbr = dbe_strdup (NTXT ("??"));
1185 abbr_unit = dbe_strdup (GTXT ("sec."));
1186 if (st == EXCLUSIVE)
1188 name = dbe_strdup (GTXT ("Exclusive OpenMP Single Region Time"));
1189 abbr = dbe_strdup (GTXT ("Excl. OMP sngl"));
1191 else if (st == INCLUSIVE)
1193 name = dbe_strdup (GTXT ("Inclusive OpenMP Single Region Time"));
1194 abbr = dbe_strdup (GTXT ("Incl. OMP sngl"));
1196 else if (st == ATTRIBUTED)
1198 name = dbe_strdup (GTXT ("Attributed OpenMP Single Region Time"));
1199 abbr = dbe_strdup (GTXT ("Attr. OMP sngl"));
1203 name = dbe_sprintf (GTXT ("Unexpected OpenMP Single Region metric subtype %d"), st);
1204 abbr = dbe_strdup (NTXT ("??"));
1208 abbr_unit = dbe_strdup (GTXT ("sec."));
1209 if (st == EXCLUSIVE)
1211 name = dbe_strdup (GTXT ("Exclusive OpenMP Ordered Region Time"));
1212 abbr = dbe_strdup (GTXT ("Excl. OMP ordd"));
1214 else if (st == INCLUSIVE)
1216 name = dbe_strdup (GTXT ("Inclusive OpenMP Ordered Region Time"));
1217 abbr = dbe_strdup (GTXT ("Incl. OMP ordd"));
1219 else if (st == ATTRIBUTED)
1221 name = dbe_strdup (GTXT ("Attributed OpenMP Ordered Region Time"));
1222 abbr = dbe_strdup (GTXT ("Attr. OMP ordd"));
1226 name = dbe_sprintf (GTXT ("Unexpected OpenMP Ordered Region metric subtype %d"), st);
1227 abbr = dbe_strdup (NTXT ("??"));
1231 if (st == EXCLUSIVE)
1233 name = dbe_strdup (GTXT ("Exclusive Race Accesses"));
1234 abbr = dbe_strdup (GTXT ("Excl. Race Accesses"));
1236 else if (st == INCLUSIVE)
1238 name = dbe_strdup (GTXT ("Inclusive Race Accesses"));
1239 abbr = dbe_strdup (GTXT ("Incl. Race Accesses"));
1241 else if (st == ATTRIBUTED)
1243 name = dbe_strdup (GTXT ("Attributed Race Accesses"));
1244 abbr = dbe_strdup (GTXT ("Attr. Race Accesses"));
1248 name = dbe_sprintf (GTXT ("Unexpected Race Access metric subtype %d"), st);
1249 abbr = dbe_strdup (NTXT ("??"));
1253 if (st == EXCLUSIVE)
1255 name = dbe_strdup (GTXT ("Exclusive Deadlocks"));
1256 abbr = dbe_strdup (GTXT ("Excl. Deadlocks"));
1258 else if (st == INCLUSIVE)
1260 name = dbe_strdup (GTXT ("Inclusive Deadlocks"));
1261 abbr = dbe_strdup (GTXT ("Incl. Deadlocks"));
1263 else if (st == ATTRIBUTED)
1265 name = dbe_strdup (GTXT ("Attributed Deadlocks"));
1266 abbr = dbe_strdup (GTXT ("Attr. Deadlocks"));
1270 name = dbe_sprintf (GTXT ("Unexpected Deadlocks metric subtype %d"), st);
1271 abbr = dbe_strdup (NTXT ("??"));
1277 } //Metric::set_subtype
1280 is_width_ok (int lines, size_t width, size_t *tlen, int last)
1283 for (int i = 0; i <= last; i++)
1287 if (len + tlen[i] > width)
1299 Metric::legend_width (HistMetric *hitem, int gap)
1301 size_t tlen[MAX_LEN];
1302 char *tok[MAX_LEN], buf[MAX_LEN], unit[MAX_LEN];
1303 hitem->width = hitem->maxtime_width;
1304 if (hitem->maxvalue_width > 0)
1306 if (hitem->width > 0)
1308 hitem->width += hitem->maxvalue_width;
1312 if (hitem->width > 0)
1316 hitem->width += 6; // adjust to change format from xx.yy%
1318 snprintf (buf, sizeof (buf), "%s", get_abbr ());
1319 size_t max_len = hitem->width;
1322 size_t legend_len = strlen (legend);
1323 if (max_len < legend_len)
1324 max_len = legend_len;
1328 for (int i = 0;; i++)
1333 while (buf[i + 1] == ' ')
1335 tlen[last] = strlen (tok[last]);
1336 if (max_len < tlen[last])
1337 max_len = tlen[last];
1339 tok[last] = buf + i + 1;
1341 else if (buf[i] == '\0')
1343 tlen[last] = strlen (tok[last]);
1344 if (max_len < tlen[last])
1345 max_len = tlen[last];
1346 if (tlen[last] == 0 && last > 0)
1352 *unit = '\0'; // get the extra unit tokens
1356 char *s = GTXT ("sec.");
1357 if ((get_visbits () & VAL_DELTA) != 0)
1359 else if ((get_visbits () & VAL_RATIO) != 0)
1361 long len = strlen (s);
1362 if (hitem->maxtime_width < len)
1364 hitem->width += len - hitem->maxtime_width;
1365 hitem->maxtime_width = len;
1367 snprintf (unit, sizeof (unit), "%*s", (int) hitem->maxtime_width, s);
1371 char *s = NTXT ("");
1372 if (!is_tvisible ())
1374 if ((get_visbits () & VAL_DELTA) != 0)
1376 else if ((get_visbits () & VAL_RATIO) != 0)
1378 else if ((get_value_styles () & VAL_TIMEVAL) != 0 && !is_time_val ())
1381 long len = strlen (s);
1382 if (hitem->maxvalue_width < len)
1384 hitem->width += len - hitem->maxvalue_width;
1385 hitem->maxvalue_width = len;
1390 len = strlen (unit);
1391 snprintf (unit + len, sizeof (unit) - len, " %*s",
1392 (int) hitem->maxvalue_width, s);
1395 snprintf (unit, sizeof (unit), "%*s", (int) hitem->maxvalue_width, s);
1402 size_t len = strlen (unit);
1403 snprintf (unit + len, sizeof (unit) - len, GTXT (" %%"));
1406 snprintf (unit, sizeof (unit), GTXT (" %%"));
1408 for (size_t i = strlen (unit); i > 0;)
1409 { // remove trailing spaces
1419 tlen[last] = strlen (unit);
1421 if (max_len < tlen[last])
1422 max_len = tlen[last];
1423 if (max_lines == 3 && *unit == ' ')
1428 tlen[last] = strlen (str);
1433 int last1 = max_lines == 3 ? last : last - 1;
1434 while (!is_width_ok (max_lines, max_len, tlen, last1))
1436 hitem->width = max_len + gap;
1439 legends[0] = hitem->legend1;
1440 legends[1] = hitem->legend2;
1441 legends[2] = hitem->legend3;
1442 for (int i = 0, ind = 0; i < 3; i++)
1444 char *str = legends[i];
1446 for (; ind <= last; ind++)
1448 if (*unit && (ind == last))
1450 // Try to put 'unit' in 'legend3'
1453 tok[last] = unit; // restore a formated 'unit'
1457 size_t len = strlen (str);
1460 if (len + 1 + tlen[ind] > max_len)
1462 snprintf (str + len, MAX_LEN - len, NTXT (" %s"), tok[ind]);
1466 if (len + tlen[ind] > max_len)
1468 snprintf (str + len, MAX_LEN - len, NTXT ("%s"), tok[ind]);
1475 Metric::get_real_visbits ()
1478 if (!is_time_val () && (visbits & (VAL_TIMEVAL | VAL_VALUE)) != 0)
1480 v &= ~(VAL_TIMEVAL | VAL_VALUE);
1481 v |= (get_value_styles () & (VAL_TIMEVAL | VAL_VALUE));
1487 Metric::get_vis_string (int vis)
1490 if (subtype == STATIC)
1491 vis_str = NTXT ("");
1496 v = vis & (VAL_TIMEVAL | VAL_VALUE | VAL_PERCENT);
1499 v = vis & VAL_PERCENT;
1500 if ((vis & (VAL_TIMEVAL | VAL_VALUE)) != 0)
1501 v |= (get_value_styles () & (VAL_TIMEVAL | VAL_VALUE));
1506 vis_str = NTXT (".");
1509 vis_str = NTXT ("+");
1511 case VAL_TIMEVAL | VAL_VALUE:
1512 vis_str = NTXT (".+");
1515 vis_str = NTXT ("%");
1517 case VAL_TIMEVAL | VAL_PERCENT:
1518 vis_str = NTXT (".%");
1520 case VAL_VALUE | VAL_PERCENT:
1521 vis_str = NTXT ("+%");
1523 case VAL_TIMEVAL | VAL_VALUE | VAL_PERCENT:
1524 vis_str = NTXT (".+%");
1527 vis_str = NTXT ("!");
1535 Metric::get_vis_str ()
1537 char *vis_str = NULL;
1540 // unitialized, return all possible with a trailing -
1541 if (subtype == STATIC)
1542 vis_str = NTXT (".-");
1543 else if (is_time_val ())
1544 vis_str = NTXT (".+%-");
1546 vis_str = NTXT (".%-");
1549 vis_str = get_vis_string (get_real_visbits ());
1554 Metric::set_dmetrics_visbits (int dmetrics_visbits)
1556 visbits = VAL_NA; // clear global state
1558 // process the "show" bits
1559 int _visbits = dmetrics_visbits & ~VAL_HIDE_ALL;
1560 assert (_visbits != -1);
1562 return; // done. (Ignore VAL_HIDE_ALL since there's nothing to hide.)
1563 if (get_subtype () == STATIC)
1564 // percent, time value not applicable
1565 visbits = VAL_VALUE;
1568 // now or in the bits, but manage . and + according to the is_time_val setting
1569 if (is_time_val () == 0)
1571 if ((_visbits & VAL_VALUE) || (_visbits & VAL_TIMEVAL))
1572 visbits |= VAL_VALUE;
1575 visbits |= (_visbits & (VAL_VALUE | VAL_TIMEVAL));
1576 visbits |= (_visbits & (VAL_PERCENT | VAL_RATIO | VAL_DELTA));
1578 // process the "hide" bit
1579 if (dmetrics_visbits & VAL_HIDE_ALL)
1580 visbits |= VAL_HIDE_ALL;
1584 Metric::set_vvisible (bool set)
1588 visbits |= VAL_VALUE;
1589 visbits &= ~VAL_HIDE_ALL;
1592 visbits &= ~VAL_VALUE;
1596 Metric::set_tvisible (bool set)
1600 visbits |= VAL_TIMEVAL;
1601 visbits &= ~VAL_HIDE_ALL;
1604 visbits &= ~VAL_TIMEVAL;
1608 Metric::set_pvisible (bool set)
1612 visbits |= VAL_PERCENT;
1613 visbits &= ~VAL_HIDE_ALL;
1616 visbits &= ~VAL_PERCENT;
1620 Metric::get_mcmd (bool allPossible)
1622 char *sc = NTXT (""); // subtype == STATIC
1624 char *vis = get_vis_string (allPossible ? get_value_styles ()
1625 : get_real_visbits ());
1626 if (subtype == INCLUSIVE)
1628 else if (subtype == EXCLUSIVE)
1630 else if (subtype == ATTRIBUTED)
1632 else if (subtype == DATASPACE)
1636 else if (visbits == VAL_NA || (visbits & VAL_HIDE_ALL) != 0)
1641 char *mcmd = get_cmd ();
1642 return dbe_sprintf (GTXT ("%s%s%s%s"), sc, hide, vis, mcmd);
1649 BaseMetric *bm = (BaseMetric *) this;
1650 char *s = bm->dump ();
1651 char *msg = dbe_sprintf ("%s\n%*c subtype=%d time_val=%d vis=%d tvis=%d"
1652 " pvis=%d\n%*c abbr='%s' cmd='%s' name='%s'\n",
1653 STR (s), len, ' ', get_subtype (), is_time_val (),
1654 is_visible (), is_tvisible (), is_pvisible (),
1655 len, ' ', STR (get_abbr ()), STR (get_cmd ()),