00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039
00040
00041
00042
00043
00044
00045
00046
00047 # include "defines.h"
00048
00049 # include "host.m"
00050 # include "host.h"
00051 # include "target.m"
00052 # include "target.h"
00053
00054 # include "globals.m"
00055 # include "tokens.m"
00056 # include "sytb.m"
00057 # include "debug.m"
00058 # include "s_globals.m"
00059 # include "i_cvrt.m"
00060
00061 # include "globals.h"
00062 # include "tokens.h"
00063 # include "sytb.h"
00064 # include "p_globals.h"
00065 # include "s_globals.h"
00066 # include "i_cvrt.h"
00067 #ifdef KEY
00068 #define FOR_I_CVRT
00069 #include "../sgi/cwh_types.h"
00070 #endif
00071 #ifdef KEY
00072 #include "../sgi/decorate_utils.h"
00073 #include "../sgi/cwh_stab.i"
00074 #endif
00075
00076
00077
00078
00079
00080 static void allocate_pdg_link_tbls(void);
00081 static void cvrt_exp_to_pdg(int, fld_type);
00082 static void cvrt_ir_to_pdg(int);
00083 static void cvrt_proc_to_pdg(char *);
00084 static void cvrt_sytb_to_pdg(void);
00085 static void finish_symbolic_expr(void);
00086 static TYPE get_basic_type(int, int, int);
00087 static TYPE get_type_desc(int);
00088 static void send_attr_ntry(int);
00089 static void send_darg_list(int, int);
00090 static TYPE send_derived_type(int);
00091 static void send_dummy_procedure(int);
00092 static void send_label(int);
00093 static void send_label_def(int);
00094 static void send_mod_file_name(void);
00095 static void send_namelist_group(int);
00096 static TYPE send_non_standard_aligned_type(int, int);
00097 static void send_procedure(int, int, int);
00098 static void send_stor_blk(int, int *);
00099
00100
00101
00102
00103
00104 static pdg_type_tbl_type *RESTRICT pdg_type_tbl;
00105
00106 static int data_value_idx;
00107 static int global_attr_idx;
00108 static int blank_pad_text;
00109 static int data_attr;
00110 static int data_character_bit_length;
00111 static boolean stack_data_object;
00112 static boolean whole_subscript;
00113 static boolean whole_substring;
00114 static boolean stack_data_constant;
00115 static boolean symbolic_constant_expr;
00116 static int processing_call;
00117 static int curr_sh;
00118 static int io_type;
00119 static int case_cmic_vpr_idx;
00120 static int guard_cmic_vpr_idx;
00121 static int doparallel_cmic_vpr_idx;
00122 static int parallel_cmic_vpr_idx;
00123 static boolean processing_io_stmt;
00124 static TYPE null_type;
00125 static TYPE pdg_type_void;
00126 static int pdg_type_tbl_idx;
00127 static int pdg_type_tbl_inc;
00128 static int pdg_type_tbl_init_size;
00129 static int pdg_type_tbl_limit = (1 << 16) - 1;
00130 static int pdg_type_tbl_num_wds = HOST_BYTES_TO_WORDS(
00131 (sizeof(pdg_type_tbl_type)));
00132 static int pdg_type_tbl_size;
00133 static int pdg_type_tbl_largest_idx;
00134
00135 static int pdg_basic_type[Num_Basic_Types] = {
00136 Integral,
00137 L_ogical,
00138 Floating_Pt,
00139 C_omplex,
00140 CRI_Pointer,
00141 BT_func_ptr,
00142 CRI_Pointer_Char,
00143 T_ypeless,
00144 Char_Fortran,
00145 S_tructure};
00146
00147 static char *p_proc[] = {
00148 "Unknown_Proc",
00149 "Extern_Proc",
00150 "Intern_Proc_Ref",
00151 "Dummy_Proc",
00152 "Intern_Proc",
00153 "Imported_Proc",
00154 "Module_Proc"};
00155
00156 static char *p_obj_sym_class[] = {
00157 "Unknown_Sym",
00158 "User_Variable",
00159 "Dummy_Arg",
00160 "Function_Rslt",
00161 "Compiler_Temp",
00162 "Cray_Pointee",
00163 "Component",
00164 "Vector_Temp",
00165 "Vector_Maskk",
00166 "Vector_Iota",
00167 "MPP_Object",
00168 "Call_Dummy",
00169 "Dummy_Procedure",
00170 "Hosted_User_Variable",
00171 "Hosted_Dummy_Arg",
00172 "Scratch_Symbol",
00173 "Hosted_Dummy_Procedure",
00174 "Hosted_Compiler_Temp",
00175 "Name" };
00176
00177 static char *p_return[] = {
00178 "Unknown_Return",
00179 "Normal_Return",
00180 "Void_Return",
00181 "Alternate_Return" };
00182
00183 static char *p_atp_pgm_unit[] = {
00184 "Pgm_Unknown",
00185 "C Function",
00186 "ERROR",
00187 "Function",
00188 "Subroutine",
00189 "Program",
00190 "Blockdata",
00191 "Module" };
00192
00193 static char *p_boolean[] = {
00194 "F",
00195 "T"};
00196
00197 static char *p_label[] = {
00198 "Lbl_Unknown",
00199 "Lbl_User",
00200 "Lbl_Format",
00201 "Lbl_Internal",
00202 "Lbl_Debug",
00203 "Lbl_Cstrct" };
00204
00205 static char *p_dbg_label[] = {
00206 "Ldbg_None",
00207 "Ldbg_Stmt_Lbl",
00208 "Ldbg_Exit_Point",
00209 "Ldbg_End_Prologue",
00210 "Ldbg_Start_Epilogue",
00211 "Ldbg_Construct_Name",
00212 "Ldbg_Loop_Lbl",
00213 "Ldbg_User_Lbl" };
00214
00215 static char *p_intent[] = {
00216 "Intent_Unseen",
00217 "Intent_In",
00218 "Intent_Out",
00219 "Intent_Inout" };
00220
00221 static char *p_io[] = {
00222 "Write",
00223 "Read",
00224 "Write_Namelist",
00225 "Read_Namelist" };
00226
00227 static char *p_sequence[] = {
00228 "Unknown_Seq",
00229 "Unsequenced",
00230 "Numeric_Seq",
00231 "Char_Seq",
00232 "Mixed_Seq" };
00233
00234 static char *p_sb_blk_type_str[] = {
00235 "Unknown",
00236 "Static",
00237 "Stack",
00238 "Formal",
00239 "Common",
00240 "Extern",
00241 "Exported",
00242 "Task_Common",
00243 "Soft_External",
00244 "Global_Breg",
00245 "Global_Treg",
00246 "Static_Named",
00247 "Based",
00248 "Equivalenced",
00249 "Restricted",
00250 "Distributed",
00251 "LM_Static",
00252 "LM_Common",
00253 "LM_Extern",
00254 "Auxiliary",
00255 "Static_Local",
00256 "Non_Local_Stack",
00257 "Non_Local_Formal",
00258 "Hosted_Stack",
00259 "Threadprivate",
00260 "Coment" };
00261
00262 static char *p_table_type[] = {
00263 "Unknown",
00264 "Basic",
00265 "Pointer",
00266 "Array",
00267 "Function" };
00268
00269 static char *p_distribution[] = {
00270 "No_Distribution",
00271 "Block_Distribution",
00272 "Cyclic_Distribution",
00273 "Star_Distribution" };
00274
00275 static char *p_basic_type[] = {
00276 "Unknown",
00277 "Logical",
00278 "Typeless",
00279 "Void",
00280 "Char_Fortran",
00281 "Char_C",
00282 "Struct",
00283 "Union",
00284 "Integral",
00285 "Floating_Pt",
00286 "Complex",
00287 "Cray_Pointer",
00288 "Cray_Pointer_Ch",
00289 "Cray_Parcel" };
00290
00291 static char *p_const_class[] = {
00292 "No_Const",
00293 "Arith_Const",
00294 "Addr_Const",
00295 "Pattern_Const",
00296 "Array_Const",
00297 "Struct_Const",
00298 "Null_Arg_Const" };
00299
00300 static char *p_tasking_context[] = {
00301 "Context_None",
00302 "Context_Private",
00303 "Context_Shared",
00304 "Context_Value",
00305 "Context_Iterate",
00306 "Context_Getfirst",
00307 "Context_Control",
00308 "Context_Induction",
00309 "Context_PE_Res_Func",
00310 "Context_PE_Res_Loop",
00311 "Context_Lastlocal",
00312 "Context_Affinity",
00313 "Context_Nest",
00314 "Context_Lastthread",
00315 "Context_Omp_Reduction_Max",
00316 "Context_Omp_Reduction_Min",
00317 "Context_Omp_Reduction_Band",
00318 "Context_Omp_Reduction_Bor",
00319 "Context_Omp_Reduction_Bneqv",
00320 "Context_Omp_Reduction_Plus",
00321 "Context_Omp_Reduction_Mult",
00322 "Context_Omp_Reduction_Minus",
00323 "Context_Omp_Reduction_And",
00324 "Context_Omp_Reduction_Or",
00325 "Context_Omp_Reduction_Eqv",
00326 "Context_Omp_Reduction_Neqv",
00327 "Context_Omp_Private",
00328 "Context_Omp_Shared",
00329 "Context_Omp_Firstprivate",
00330 "Context_Omp_Lastprivate",
00331 "Context_Omp_Copyin",
00332 "Context_Omp_Copyprivate",
00333 "Context_Omp_Affinity",
00334 "Context_Omp_Nest"
00335 };
00336
00337 int pdg_align[8] = {0,
00338 Bit_Align,
00339 Byte_Align,
00340 Parcel_Align,
00341 HWord_Align,
00342 Word_Align,
00343 DWord_Align,
00344 FWord_Align
00345 };
00346
00347
00348
00349
00350
00351
00352
00353
00354
00355
00356
00357
00358
00359
00360
00361
00362
00363 void blank_padding (long64 pad,
00364 long64 offset)
00365
00366 {
00367 # if defined(_HOST_LITTLE_ENDIAN)
00368 long a_blank = (long)' ';
00369 #else
00370 long a_blank = (long)' ' << (sizeof(long)*CHAR_BIT - CHAR_BIT);
00371 # endif
00372 TYPE basic;
00373
00374
00375 TRACE (Func_Entry, "blank_padding", NULL);
00376
00377
00378
00379 basic = get_basic_type(Character_1, Align_Bit, NULL_IDX);
00380
00381 PDG_DBG_PRINT_START
00382 PDG_DBG_PRINT_C("fei_constant");
00383 PDG_DBG_PRINT_T("(1) type", basic);
00384 PDG_DBG_PRINT_S("(2) const class", p_const_class[Pattern_Const]);
00385 PDG_DBG_PRINT_LD("(3) const", a_blank);
00386 PDG_DBG_PRINT_D("(4) bit length", CHAR_BIT);
00387 PDG_DBG_PRINT_END
00388
00389 # ifdef _ENABLE_FEI
00390 fei_constant(basic, Pattern_Const, (char *) &a_blank, (long64) CHAR_BIT);
00391 # endif
00392
00393 PDG_DBG_PRINT_START
00394 PDG_DBG_PRINT_C("fei_static_next_simple_init");
00395 PDG_DBG_PRINT_D("(1) CHAR_BIT", CHAR_BIT);
00396 PDG_DBG_PRINT_LLD("(2) pad", pad);
00397 PDG_DBG_PRINT_LLD("(3) offset", offset);
00398 PDG_DBG_PRINT_D("(4) unused", 0);
00399 PDG_DBG_PRINT_END
00400
00401 # ifdef _ENABLE_FEI
00402 fei_static_next_simple_init((long64) CHAR_BIT,
00403 pad,
00404 offset,
00405 0);
00406 # endif
00407
00408 TRACE (Func_Exit, "blank_padding", NULL);
00409
00410 return;
00411 }
00412
00413
00414
00415
00416
00417
00418
00419
00420
00421
00422
00423
00424
00425
00426
00427
00428
00429
00430
00431
00432 void init_PDGCS(void)
00433
00434 {
00435 char *code_file_name;
00436 char compiler_name[8];
00437 long flags = 0;
00438 char path_name[MAX_FILE_NAME_SIZE];
00439 extern char release_level[8];
00440 extern char *command_name;
00441
00442 TRACE (Func_Entry, "init_PDGCS", NULL);
00443
00444 if (dump_flags.preinline) {
00445 code_file_name = NULL;
00446 }
00447 else if (binary_output) {
00448 code_file_name = bin_file;
00449 }
00450 else if (assembly_output) {
00451 code_file_name = assembly_file;
00452 }
00453 else {
00454 return;
00455 }
00456
00457
00458 if (dump_flags.pdgcs) {
00459 init_debug_file();
00460 }
00461
00462 getcwd (path_name, MAX_FILE_NAME_SIZE);
00463
00464 compiler_name[0] = 'C';
00465 compiler_name[1] = 'F';
00466 compiler_name[2] = 'T';
00467 compiler_name[3] = '9';
00468 compiler_name[4] = '0';
00469 compiler_name[5] = NULL_CHAR;
00470
00471
00472 flags = flags |
00473 ((long) cmd_line_flags.dalign << PDGCS_INITIALIZE_DOUBLE_ALIGN)|
00474 ((long) assembly_output << PDGCS_INITIALIZE_OBJ_FILE)|
00475 ((long) (cmd_line_flags.debug_lvl == Debug_Lvl_1)
00476 << PDGCS_INITIALIZE_PART_DEBUG)|
00477 ((long) (cmd_line_flags.debug_lvl == Debug_Lvl_2)
00478 << PDGCS_INITIALIZE_OPT_DEBUG)|
00479 ((long) on_off_flags.atexpert << PDGCS_INITIALIZE_ATEXPERT)|
00480 ((long) on_off_flags.upper_case_names << PDGCS_INITIALIZE_KERNEL)|
00481 ((long) (cmd_line_flags.debug_lvl <= Debug_Lvl_2)
00482 << PDGCS_INITIALIZE_DBG_TABLES)|
00483 ((long) (!on_off_flags.round_mult_operations)
00484 << PDGCS_INITIALIZE_TRUNCATE)|
00485 (!((cif_flags & MESSAGE_RECS) || opt_flags.msgs)
00486 << PDGCS_INITIALIZE_NO_OPT_MSGS)|
00487 ((long) (cmd_line_flags.solaris_profile || on_off_flags.flowtrace_option)
00488 << PDGCS_INITIALIZE_FLOWTRACE)|
00489 ((long) (opt_flags.unroll_lvl == Unroll_Lvl_2)
00490 << PDGCS_INITIALIZE_MEM_HIER_OPT)|
00491 ((long) cmd_line_flags.small_pic_model << PDGCS_INITIALIZE_SMALL_PIC)|
00492 ((long) cmd_line_flags.large_pic_model << PDGCS_INITIALIZE_BIG_PIC)|
00493 (!opt_flags.neg_msgs << PDGCS_INITIALIZE_NO_NEG_MSGS)|
00494 ((long) dump_flags.mp << PDGCS_INITIALIZE_MP)|
00495 ((long) on_off_flags.MPP_apprentice << PDGCS_INITIALIZE_APPRENTICE)|
00496 ((long) on_off_flags.shared_to_private_coer<< PDGCS_INITIALIZE_S2P_COERCE)|
00497 ((long) opt_flags.jump << PDGCS_INITIALIZE_CCG_JUMPS)|
00498 ((long) opt_flags.opt_info << PDGCS_INITIALIZE_OPT_INFO)|
00499 ((long) on_off_flags.integer_1_and_2 << PDGCS_INITIALIZE_INTEGER_1_2)|
00500 (((long) opt_flags.split_lvl == Split_Lvl_2)
00501 << PDGCS_INITIALIZE_STREAMSPLIT);
00502
00503 PDG_DBG_PRINT_START
00504 PDG_DBG_PRINT_C("PDGCS_initialize");
00505 PDG_DBG_PRINT_S("compiler_name", compiler_name);
00506 PDG_DBG_PRINT_S("(1) language", "PDGCS_Fortran_90");
00507 PDG_DBG_PRINT_LO("(2) flags", flags);
00508 PDG_DBG_PRINT_S("(3) command_name", command_name);
00509 PDG_DBG_PRINT_S("(4) release_level", release_level);
00510 PDG_DBG_PRINT_S("(5) code_file_name", code_file_name);
00511 PDG_DBG_PRINT_S("(6) list_file_name", (char *) &assembly_listing_file);
00512 PDG_DBG_PRINT_D("(7) trunc bits", cmd_line_flags.truncate_bits);
00513 PDG_DBG_PRINT_LD("(8) CCG flags", ccg_dump_flags);
00514 PDG_DBG_PRINT_S("(9) src_path_name", get_src_path_name());
00515 PDG_DBG_PRINT_S("(10) cif_file_name", (char *) &cif_name);
00516 PDG_DBG_PRINT_S("(11) debug_file_name", (char *) &debug_file_name);
00517 PDG_DBG_PRINT_LD("(12) debug file ptr", (long) debug_file);
00518 PDG_DBG_PRINT_LD("(13) cif file ptr", (long) cif_actual_file);
00519 PDG_DBG_PRINT_S("(14) GL_FILE_NAME", GL_FILE_NAME_PTR(1));
00520 PDG_DBG_PRINT_S("(15) path name", path_name);
00521 PDG_DBG_PRINT_D("(16) N$PE", cmd_line_flags.MPP_num_pes);
00522 PDG_DBG_PRINT_D("(17) meta test", dump_flags.pvp_test);
00523 PDG_DBG_PRINT_END
00524
00525 # ifdef _ENABLE_FEI
00526 PDGCS_initialize(Fortran_90,
00527 flags,
00528 command_name,
00529 release_level,
00530 code_file_name,
00531 (char *)&assembly_listing_file,
00532 cmd_line_flags.truncate_bits,
00533 ccg_dump_flags,
00534 get_src_path_name(),
00535 (char *)&cif_name,
00536 (char *)&debug_file_name,
00537 debug_file,
00538 cif_actual_file,
00539 GL_FILE_NAME_PTR(1),
00540 path_name,
00541 cmd_line_flags.MPP_num_pes,
00542 dump_flags.pvp_test);
00543 # endif
00544
00545
00546 TRACE (Func_Exit, "init_PDGCS", NULL);
00547
00548 return;
00549
00550 }
00551
00552
00553
00554
00555
00556
00557
00558
00559
00560
00561
00562
00563
00564
00565
00566
00567
00568
00569
00570
00571
00572 void cvrt_to_pdg (char *compiler_gen_date)
00573
00574 {
00575 int align;
00576 int i;
00577 int bit_size;
00578 int flags;
00579
00580 # if defined(_TARGET_OS_MAX) || defined(_TARGET_OS_UNICOS)
00581 int child_idx;
00582 # endif
00583
00584
00585 TRACE (Func_Entry, "cvrt_to_pdg", NULL);
00586
00587
00588
00589
00590
00591
00592
00593 case_cmic_vpr_idx = NULL_IDX;
00594 guard_cmic_vpr_idx = NULL_IDX;
00595
00596 init_directive(3);
00597
00598 for (i = 1; i <= global_line_tbl_idx; i++) {
00599 PDG_DBG_PRINT_START
00600 PDG_DBG_PRINT_C("cwh_add_to_used_files_table");
00601 PDG_DBG_PRINT_S("(1) path", GL_FILE_NAME_PTR(i));
00602 PDG_DBG_PRINT_D("(2) one", 1);
00603 PDG_DBG_PRINT_END
00604
00605 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
00606 cwh_add_to_used_files_table(GL_FILE_NAME_PTR(i), 1);
00607 # endif
00608 }
00609
00610 PDG_DBG_PRINT_START
00611 PDG_DBG_PRINT_C("fei_descriptor");
00612 PDG_DBG_PRINT_O("(1) flags", 0);
00613 PDG_DBG_PRINT_S("(2) table type", p_table_type[Basic]);
00614 PDG_DBG_PRINT_D("(3) bit_size", 0);
00615 PDG_DBG_PRINT_S("(4) basic type", p_basic_type[V_oid]);
00616 PDG_DBG_PRINT_D("(5) aux info", 0);
00617 PDG_DBG_PRINT_D("(6) alignment", 0);
00618 PDG_DBG_PRINT_END
00619 # ifdef _ENABLE_FEI
00620 pdg_type_void = fei_descriptor(0,
00621 Basic,
00622 0,
00623 V_oid,
00624 0,
00625 0);
00626 # endif
00627 PDG_DBG_PRINT_START
00628 PDG_DBG_PRINT_T("(r) type", pdg_type_void);
00629 PDG_DBG_PRINT_END
00630
00631 pgm_unit_start_line = SH_GLB_LINE(SCP_FIRST_SH_IDX(curr_scp_idx));
00632
00633 # if defined(_TARGET_OS_MAX) || defined(_TARGET_OS_UNICOS)
00634
00635
00636
00637
00638
00639
00640
00641
00642 if (ATP_PGM_UNIT(SCP_ATTR_IDX(curr_scp_idx)) == Module) {
00643 child_idx = SCP_FIRST_CHILD_IDX(curr_scp_idx);
00644 SCP_FIRST_CHILD_IDX(curr_scp_idx) = NULL_IDX;
00645
00646 cvrt_proc_to_pdg(compiler_gen_date);
00647
00648 if (child_idx != NULL_IDX) {
00649 curr_scp_idx = child_idx;
00650 cvrt_proc_to_pdg(compiler_gen_date);
00651 }
00652
00653 curr_scp_idx = MAIN_SCP_IDX;
00654
00655 if (on_off_flags.module_to_mod) {
00656 send_mod_file_name();
00657 create_mod_info_tbl();
00658 output_mod_info_file();
00659 }
00660 else {
00661 send_mod_file_name();
00662 }
00663 free_tables();
00664 }
00665 else {
00666 cvrt_proc_to_pdg(compiler_gen_date);
00667 }
00668
00669 # else
00670 cvrt_proc_to_pdg(compiler_gen_date);
00671 # endif
00672
00673 TBL_FREE(pdg_link_tbl);
00674 TBL_FREE(pdg_type_tbl);
00675
00676 TRACE (Func_Exit, "cvrt_to_pdg", NULL);
00677
00678 return;
00679
00680 }
00681
00682 #ifdef KEY
00683
00684
00685 typedef struct {
00686 const char *id;
00687 int line;
00688 int bind_attr;
00689 } external_name_t;
00690
00691
00692
00693
00694
00695
00696
00697
00698
00699
00700
00701
00702
00703
00704
00705
00706
00707
00708
00709
00710
00711 static void
00712 check_duplicate_external_name(fld_type fld, int idx, const char *ext_name) {
00713 const char *id = (AT_Tbl_Idx == fld) ? AT_OBJ_NAME_PTR(idx) :
00714 SB_NAME_PTR(idx);
00715 int line = (AT_Tbl_Idx == fld) ? AT_DEF_LINE(idx) : SB_DEF_LINE(idx);
00716 int bind_attr = (AT_Tbl_Idx == fld) ? AT_BIND_ATTR(idx) : SB_BIND_ATTR(idx);
00717 external_name_t *prev = get_external_label(ext_name);
00718 if (!prev) {
00719 prev = malloc(sizeof prev);
00720 prev->id = strdup(id);
00721 prev->line = line;
00722 prev->bind_attr = bind_attr;
00723 put_external_label(ext_name, prev);
00724 }
00725
00726 if ((bind_attr || prev->bind_attr) && !!strcmp(prev->id, id)) {
00727 int column = (AT_Tbl_Idx == fld) ? AT_DEF_COLUMN(idx) :
00728 SB_DEF_COLUMN(idx);
00729 char *fal = file_and_line(prev->line);
00730 PRINTMSG(line, 1701, Error, column, id, prev->id, ext_name, fal);
00731 free(fal);
00732 }
00733 }
00734 #endif
00735
00736
00737
00738
00739
00740
00741
00742
00743
00744
00745
00746
00747
00748
00749
00750
00751
00752
00753 static void cvrt_proc_to_pdg (char *compiler_gen_date)
00754
00755 {
00756 boolean check_scp = TRUE;
00757 int mobes_sades;
00758 char *name_ptr;
00759 long opt_flag;
00760 int pgm_attr_idx;
00761 int pgm_code = 0;
00762 int pgm_data = 0;
00763 int save_curr_scp_idx;
00764
00765 extern void dim_reshape_pass_driver(void);
00766 extern void runtime_ptr_chk_driver(void);
00767
00768 TRACE (Func_Entry, "cvrt_proc_to_pdg", NULL);
00769
00770 #ifdef KEY
00771 int attr_idx = SCP_ATTR_IDX(curr_scp_idx);
00772 boolean is_module = (Module == ATP_PGM_UNIT(attr_idx));
00773
00774 if (is_module) {
00775 int lineno = AT_DEF_LINE(attr_idx);
00776 char *file_name = global_to_local_file(lineno);
00777 INT32 local_lineno = global_to_local_line_number(lineno);
00778 cwh_dst_enter_module(AT_OBJ_NAME_PTR(attr_idx), file_name, local_lineno);
00779 }
00780 #endif
00781
00782 PROCESS_SIBLING:
00783
00784
00785
00786
00787 if (SCP_FIRST_CHILD_IDX(curr_scp_idx) != NULL_IDX) {
00788 save_curr_scp_idx = curr_scp_idx;
00789 curr_scp_idx = SCP_FIRST_CHILD_IDX(curr_scp_idx);
00790 cvrt_proc_to_pdg(compiler_gen_date);
00791 curr_scp_idx = save_curr_scp_idx;
00792 }
00793
00794 if (opt_flags.reshape) {
00795 dim_reshape_pass_driver();
00796 }
00797
00798 if (cmd_line_flags.runtime_ptr_chk) {
00799 runtime_ptr_chk_driver();
00800 }
00801
00802
00803 allocate_pdg_link_tbls();
00804
00805 pgm_attr_idx = SCP_ATTR_IDX(curr_scp_idx);
00806 ATP_SCP_ALIVE(pgm_attr_idx) = TRUE;
00807 stmt_start_line = SH_GLB_LINE(SCP_FIRST_SH_IDX(curr_scp_idx));
00808 stmt_start_col = 0;
00809
00810 cvrt_sytb_to_pdg();
00811
00812 name_ptr = &name_pool[ATP_EXT_NAME_IDX(pgm_attr_idx)].name_char;
00813 #ifdef KEY
00814
00815 const char *ext_name = ATP_EXT_NAME_PTR(pgm_attr_idx);
00816 if (Program == ATP_PGM_UNIT(pgm_attr_idx)) {
00817 ext_name = def_main_u;
00818 }
00819 check_duplicate_external_name(AT_Tbl_Idx, pgm_attr_idx, ext_name);
00820 #endif
00821
00822 PDG_DBG_PRINT_START
00823 PDG_DBG_PRINT_C("PDGCS_comp_unit");
00824 PDG_DBG_PRINT_S("(1) name_ptr", name_ptr);
00825 PDG_DBG_PRINT_D("(2) unused", 0);
00826 PDG_DBG_PRINT_END
00827
00828 # ifdef _ENABLE_FEI
00829 PDGCS_comp_unit(name_ptr, NULL_IDX);
00830 # endif
00831
00832 opt_flag =
00833 ((long) opt_flags.aggress << PDGCS_NEW_PROC_IGNORE_THROTTLE)|
00834 ((long) (cmd_line_flags.debug_lvl != Debug_Lvl_0)
00835 << PDGCS_NEW_PROC_ELIM_DEAD_CODE)|
00836 ((long) opt_flags.pattern << PDGCS_NEW_PROC_PATTERN_MATCHING)|
00837 ((long) on_off_flags.reciprical_divide << PDGCS_NEW_PROC_IEEE_RECIPS)|
00838 ((long) (opt_flags.task_lvl == Task_Lvl_3)
00839 << PDGCS_NEW_PROC_TASK_INNER_LOOPS)|
00840 ((long) cmd_line_flags.runtime_conformance << PDGCS_NEW_PROC_CONFORM_CHECK)|
00841 ((long) opt_flags.ieeeconform << PDGCS_NEW_PROC_IEEE_CONFORM)|
00842 ((long) cmd_line_flags.do_UDB_checks << PDGCS_NEW_PROC_DO_UBD_ANALYSIS);
00843
00844 send_attr_ntry(pgm_attr_idx);
00845
00846 mobes_sades = ATP_USES_EREGS(pgm_attr_idx) ? 512 : 0;
00847
00848 PDG_DBG_PRINT_START
00849 PDG_DBG_PRINT_C("PDGCS_new_proc");
00850 PDG_DBG_PRINT_D("(1) num ir", 2000);
00851 PDG_DBG_PRINT_LD("(2) PDG_AT_IDX", PDG_AT_IDX(pgm_attr_idx));
00852 PDG_DBG_PRINT_D("(3) alt entries", SCP_ALT_ENTRY_CNT(curr_scp_idx));
00853 PDG_DBG_PRINT_D("(4) scalar level", opt_flags.scalar_lvl);
00854 PDG_DBG_PRINT_D("(5) vector level", opt_flags.vector_lvl);
00855 PDG_DBG_PRINT_D("(6) task level", opt_flags.task_lvl);
00856 PDG_DBG_PRINT_LO("(7) flags", opt_flag);
00857 PDG_DBG_PRINT_D("(8) user mobes", mobes_sades);
00858 PDG_DBG_PRINT_D("(9) user sades", mobes_sades);
00859 PDG_DBG_PRINT_D("(10) pipeline level", opt_flags.pipeline_lvl);
00860 PDG_DBG_PRINT_D("(11) stream level", opt_flags.stream_lvl);
00861 PDG_DBG_PRINT_END
00862
00863
00864 # ifdef _ENABLE_FEI
00865 PDGCS_new_proc(2000,
00866 PDG_AT_IDX(pgm_attr_idx),
00867 SCP_ALT_ENTRY_CNT(curr_scp_idx),
00868 opt_flags.scalar_lvl,
00869 opt_flags.vector_lvl,
00870 opt_flags.task_lvl,
00871 opt_flag,
00872 mobes_sades,
00873 mobes_sades,
00874 opt_flags.pipeline_lvl,
00875 opt_flags.stream_lvl);
00876 # endif
00877
00878 cvrt_ir_to_pdg(curr_scp_idx);
00879
00880 ATP_SCP_ALIVE(pgm_attr_idx) = FALSE;
00881
00882 if (cmd_line_flags.debug_lvl <= Debug_Lvl_2) {
00883 PDG_DBG_PRINT_START
00884 PDG_DBG_PRINT_C("PDGCS_debug_init");
00885 PDG_DBG_PRINT_S("(1) src path name", get_src_path_name());
00886 PDG_DBG_PRINT_S("(2) gen date", compiler_gen_date);
00887 PDG_DBG_PRINT_END
00888
00889 # ifdef _ENABLE_FEI
00890 PDGCS_debug_init(get_src_path_name(),
00891 compiler_gen_date);
00892 # endif
00893 }
00894
00895 PDG_DBG_PRINT_START
00896 # ifdef _DEBUG
00897 fflush(debug_file);
00898 # endif
00899 PDG_DBG_PRINT_END
00900
00901
00902
00903
00904
00905
00906 if (curr_scp_idx == MAIN_SCP_IDX &&
00907 ATP_PGM_UNIT(SCP_ATTR_IDX(curr_scp_idx)) != Module) {
00908 free_tables();
00909 check_scp = FALSE;
00910 }
00911
00912 # if !defined(_TARGET_OS_MAX) && !defined(_TARGET_OS_UNICOS)
00913 if (curr_scp_idx == MAIN_SCP_IDX &&
00914 ATP_PGM_UNIT(SCP_ATTR_IDX(curr_scp_idx)) == Module) {
00915
00916
00917
00918 send_mod_file_name();
00919 create_mod_info_tbl();
00920 output_mod_info_file();
00921 free_tables();
00922 check_scp = FALSE;
00923 }
00924 # endif
00925
00926
00927 PDG_DBG_PRINT_START
00928 PDG_DBG_PRINT_C("PDGCS_do_proc");
00929 PDG_DBG_PRINT_END
00930
00931 # ifdef _ENABLE_FEI
00932 #ifdef KEY
00933
00934 PDGCS_do_proc(is_module);
00935 #else
00936 PDGCS_do_proc();
00937 #endif
00938 # endif
00939
00940 PDG_DBG_PRINT_START
00941 PDG_DBG_PRINT_C("PDGCS_end_procs");
00942 PDG_DBG_PRINT_D("(1) pgm_code", pgm_code);
00943 PDG_DBG_PRINT_D("(2) pgm_data", pgm_data);
00944 PDG_DBG_PRINT_END
00945
00946 # ifdef _ENABLE_FEI
00947 PDGCS_end_procs(&pgm_code,
00948 &pgm_data);
00949 # endif
00950
00951 PDG_DBG_PRINT_START
00952 PDG_DBG_PRINT_D("(r) pgm_code", pgm_code);
00953 PDG_DBG_PRINT_D("(r) pgm_data", pgm_data);
00954 PDG_DBG_PRINT_END
00955
00956
00957
00958 code_size = code_size + pgm_code;
00959 data_size = data_size + pgm_data;
00960
00961 PDG_DBG_PRINT_START
00962 PDG_DBG_PRINT_C("PDGCS_end_comp_unit");
00963 PDG_DBG_PRINT_END
00964
00965 # ifdef _ENABLE_FEI
00966 PDGCS_end_comp_unit();
00967 # endif
00968
00969 if (check_scp && SCP_SIBLING_IDX(curr_scp_idx) != NULL_IDX) {
00970 curr_scp_idx = SCP_SIBLING_IDX(curr_scp_idx);
00971 goto PROCESS_SIBLING;
00972 }
00973
00974 #ifdef KEY
00975 if (is_module) {
00976 cwh_dst_exit_module();
00977 }
00978 #endif
00979
00980 TRACE (Func_Exit, "cvrt_proc_to_pdg", NULL);
00981
00982 return;
00983
00984 }
00985
00986
00987
00988
00989
00990
00991
00992
00993
00994
00995
00996
00997
00998
00999
01000
01001
01002
01003
01004 void push_data_value (int t_idx)
01005
01006 {
01007 char *new_str_ptr;
01008 char *old_str_ptr;
01009 boolean ignore_types;
01010 long_type target_length;
01011 #ifdef KEY
01012 int idx = 0;
01013 int l_idx = 0;
01014 fld_type fld = NO_Tbl_Idx;
01015 int cn_idx = 0;
01016 #else
01017 int idx;
01018 int l_idx;
01019 fld_type fld;
01020 int cn_idx;
01021 #endif
01022 int type_idx;
01023 int new_str_idx;
01024 long64 len;
01025 #ifdef KEY
01026 long64 rep_count = 0;
01027 long64 stride = 0;
01028 long64 padd = 0;
01029 long64 num_chars = 0;
01030 #else
01031 long64 rep_count;
01032 long64 stride;
01033 long64 padd = 0;
01034 long64 num_chars;
01035 #endif
01036 int i;
01037
01038
01039 TRACE (Func_Entry, "push_data_value", NULL);
01040
01041 if (IL_LIST_CNT(data_value_idx) == 0) {
01042 data_value_idx = IL_NEXT_LIST_IDX(data_value_idx);
01043 }
01044
01045 IL_LIST_CNT(data_value_idx) = IL_LIST_CNT(data_value_idx) - 1;
01046
01047
01048
01049 data_attr = NULL_IDX;
01050 stack_data_object = TRUE;
01051 cvrt_exp_to_pdg(IL_IDX(t_idx),
01052 IL_FLD(t_idx));
01053 stack_data_object = FALSE;
01054
01055 ignore_types = FALSE;
01056
01057 switch (IL_FLD(data_value_idx)) {
01058
01059 case CN_Tbl_Idx :
01060 idx = IL_IDX(data_value_idx);
01061 fld = IL_FLD(data_value_idx);
01062 rep_count = (long64) 1;
01063 stride = (long64) 0;
01064 cn_idx = IL_IDX(data_value_idx);
01065
01066 if (TYP_TYPE(CN_TYPE_IDX(idx)) == Typeless ||
01067 (TYP_TYPE(CN_TYPE_IDX(idx)) == Character &&
01068 TYP_TYPE(ATD_TYPE_IDX(data_attr)) != Character)) {
01069 ignore_types = TRUE;
01070 }
01071 break;
01072
01073 case IR_Tbl_Idx :
01074 if (IR_FLD_R(IL_IDX(data_value_idx)) == CN_Tbl_Idx) {
01075 idx = IR_IDX_R(IL_IDX(data_value_idx));
01076 fld = IR_FLD_R(IL_IDX(data_value_idx));
01077 rep_count = (long64) 1;
01078 stride = (long64) 0;
01079 cn_idx = IR_IDX_R(IL_IDX(data_value_idx));
01080
01081 if (TYP_TYPE(CN_TYPE_IDX(idx)) == Typeless ||
01082 (TYP_TYPE(CN_TYPE_IDX(idx)) == Character &&
01083 TYP_TYPE(ATD_TYPE_IDX(data_attr)) != Character)) {
01084 ignore_types = TRUE;
01085 }
01086 }
01087 else {
01088 idx = IR_IDX_R(IR_IDX_R(IL_IDX(data_value_idx)));
01089 fld = IR_FLD_R(IR_IDX_R(IL_IDX(data_value_idx)));
01090 rep_count = CN_INT_TO_C(IR_IDX_L(IR_IDX_R(IL_IDX(data_value_idx))));
01091 stride = (long64) CHAR_BIT;
01092 cn_idx = CN_INTEGER_ZERO_IDX;
01093 }
01094 break;
01095 }
01096
01097
01098 if ((TYP_TYPE(CN_TYPE_IDX(cn_idx)) == Character) &&
01099 ((IR_OPR(blank_pad_text) == Whole_Substring_Opr) ||
01100 (IR_OPR(blank_pad_text) == Substring_Opr))) {
01101 num_chars = CN_INT_TO_C(TYP_IDX(CN_TYPE_IDX(cn_idx)));
01102 l_idx = IR_IDX_R(blank_pad_text);
01103 l_idx = IL_NEXT_LIST_IDX(l_idx);
01104 l_idx = IL_NEXT_LIST_IDX(l_idx);
01105 padd = CN_INT_TO_C(IL_IDX(l_idx));
01106 padd = padd - num_chars;
01107 }
01108
01109 if (padd < 0) {
01110
01111
01112
01113
01114
01115
01116 target_length = CN_CONST(IL_IDX(l_idx));
01117 CLEAR_TBL_NTRY(type_tbl, TYP_WORK_IDX);
01118 TYP_TYPE(TYP_WORK_IDX) = Character;
01119 TYP_LINEAR(TYP_WORK_IDX) = CHARACTER_DEFAULT_TYPE;
01120 TYP_CHAR_CLASS(TYP_WORK_IDX) = Const_Len_Char;
01121 TYP_FLD(TYP_WORK_IDX) = CN_Tbl_Idx;
01122 TYP_IDX(TYP_WORK_IDX) = ntr_const_tbl(CG_INTEGER_DEFAULT_TYPE,
01123 FALSE,
01124 &target_length);
01125 type_idx = ntr_type_tbl();
01126
01127 new_str_idx = ntr_const_tbl(type_idx, TRUE, NULL);
01128 new_str_ptr = (char *) &CN_CONST(new_str_idx);
01129 old_str_ptr = (char *) &CN_CONST(idx);
01130 len = CN_INT_TO_C(TYP_IDX(type_idx));
01131
01132 for (i = 0; i < len; i++) {
01133 new_str_ptr[i] = old_str_ptr[i];
01134 }
01135
01136 idx = new_str_idx;
01137 }
01138
01139
01140 stack_data_constant = TRUE;
01141 cvrt_exp_to_pdg(idx, fld);
01142 stack_data_constant = FALSE;
01143
01144 PDG_DBG_PRINT_START
01145 PDG_DBG_PRINT_C("fei_static_simple_init");
01146 PDG_DBG_PRINT_LLD("(1) rep_count", rep_count);
01147 PDG_DBG_PRINT_LLD("(2) stride", stride);
01148 PDG_DBG_PRINT_D("(3) ignore_types", ignore_types);
01149 PDG_DBG_PRINT_D("(4) unused", 0);
01150 PDG_DBG_PRINT_END
01151
01152 # ifdef _ENABLE_FEI
01153 fei_static_simple_init(rep_count,
01154 stride,
01155 ignore_types,
01156 0);
01157 # endif
01158
01159 if (padd > 0) {
01160 blank_padding(padd, (long64) (num_chars * CHAR_BIT));
01161 }
01162
01163 TRACE (Func_Exit, "push_data_value", NULL);
01164
01165 return;
01166
01167 }
01168
01169
01170
01171
01172
01173
01174
01175
01176
01177
01178
01179
01180
01181
01182
01183
01184 static void cvrt_sytb_to_pdg(void)
01185 {
01186 int al_idx;
01187 int attr_idx;
01188 int name_idx;
01189 int unused;
01190 int scp_idx;
01191
01192
01193 TRACE (Func_Entry, "cvrt_sytb_to_pdg", NULL);
01194
01195
01196
01197
01198
01199
01200
01201
01202 scp_idx = curr_scp_idx;
01203
01204 while (scp_idx != NULL_IDX) {
01205 attr_idx = SCP_ATTR_IDX(scp_idx);
01206
01207 if (ATP_PGM_UNIT(attr_idx) == Module && scp_idx != curr_scp_idx) {
01208 break;
01209 }
01210
01211 if (AT_OBJ_CLASS(attr_idx) == Pgm_Unit) {
01212 PDG_DBG_PRINT_START
01213 PDG_DBG_PRINT_C("fei_next_func_idx");
01214 PDG_DBG_PRINT_END
01215 # ifdef _ENABLE_FEI
01216 PDG_AT_IDX(attr_idx) = fei_next_func_idx(ATP_PGM_UNIT(attr_idx),
01217 ATP_PROC(attr_idx),
01218 ATP_ALT_ENTRY(attr_idx));
01219 # endif
01220 PDG_DBG_PRINT_START
01221 PDG_DBG_PRINT_LD("(r) PDG_AT_IDX", PDG_AT_IDX(attr_idx));
01222 PDG_DBG_PRINT_END
01223 }
01224 else {
01225 PDG_DBG_PRINT_START
01226 PDG_DBG_PRINT_C("fei_next_symbol");
01227 PDG_DBG_PRINT_END
01228 # ifdef _ENABLE_FEI
01229 PDG_AT_IDX(attr_idx) = fei_next_symbol(TRUE);
01230 # endif
01231 PDG_DBG_PRINT_START
01232 PDG_DBG_PRINT_LD("(r) PDG_AT_IDX", PDG_AT_IDX(attr_idx));
01233 PDG_DBG_PRINT_END
01234 }
01235
01236 al_idx = SCP_ENTRY_IDX(scp_idx);
01237 while (al_idx != NULL_IDX) {
01238 attr_idx = AL_ATTR_IDX(al_idx);
01239
01240 if (AT_OBJ_CLASS(attr_idx) == Pgm_Unit) {
01241 PDG_DBG_PRINT_START
01242 PDG_DBG_PRINT_C("fei_next_func_idx");
01243 PDG_DBG_PRINT_END
01244 # ifdef _ENABLE_FEI
01245 PDG_AT_IDX(attr_idx) = fei_next_func_idx(ATP_PGM_UNIT(attr_idx),
01246 ATP_PROC(attr_idx),
01247 ATP_ALT_ENTRY(attr_idx));
01248 # endif
01249 PDG_DBG_PRINT_START
01250 PDG_DBG_PRINT_LD("(r) PDG_AT_IDX", PDG_AT_IDX(attr_idx));
01251 PDG_DBG_PRINT_END
01252 }
01253 else {
01254 PDG_DBG_PRINT_START
01255 PDG_DBG_PRINT_C("fei_next_symbol");
01256 PDG_DBG_PRINT_END
01257 # ifdef _ENABLE_FEI
01258 PDG_AT_IDX(attr_idx) = fei_next_symbol(TRUE);
01259 # endif
01260 PDG_DBG_PRINT_START
01261 PDG_DBG_PRINT_LD("(r) PDG_AT_IDX", PDG_AT_IDX(attr_idx));
01262 PDG_DBG_PRINT_END
01263 }
01264 al_idx = AL_NEXT_IDX(al_idx);
01265 }
01266 scp_idx = SCP_PARENT_IDX(scp_idx);
01267 }
01268
01269
01270
01271
01272
01273
01274
01275 if (SCP_PARENT_IDX(curr_scp_idx) != NULL_IDX &&
01276 SCP_SB_HOSTED_STACK_IDX(SCP_PARENT_IDX(curr_scp_idx)) != NULL_IDX) {
01277 send_stor_blk(SCP_SB_HOSTED_STACK_IDX(SCP_PARENT_IDX(curr_scp_idx)),
01278 &unused);
01279 }
01280 else if (SCP_SB_HOSTED_STACK_IDX(curr_scp_idx) != NULL_IDX) {
01281 send_stor_blk(SCP_SB_HOSTED_STACK_IDX(curr_scp_idx),
01282 &unused);
01283 }
01284 else {
01285 send_stor_blk(SCP_SB_STACK_IDX(curr_scp_idx),
01286 &unused);
01287 }
01288
01289
01290
01291
01292
01293 send_procedure(SCP_ATTR_IDX(curr_scp_idx),
01294 SCP_ENTRY_IDX(curr_scp_idx),
01295 Definition);
01296
01297 for (name_idx = SCP_LN_FW_IDX(curr_scp_idx) + 1;
01298 name_idx < SCP_LN_LW_IDX(curr_scp_idx); name_idx++) {
01299 attr_idx = LN_ATTR_IDX(name_idx);
01300 send_attr_ntry(attr_idx);
01301 }
01302
01303 al_idx = SCP_ATTR_LIST(curr_scp_idx);
01304 while (al_idx != NULL_IDX) {
01305 send_attr_ntry(AL_ATTR_IDX(al_idx));
01306 al_idx = AL_NEXT_IDX(al_idx);
01307 }
01308
01309
01310 scp_idx = SCP_PARENT_IDX(curr_scp_idx);
01311 while (scp_idx != NULL_IDX &&
01312 ATP_PGM_UNIT(SCP_ATTR_IDX(scp_idx)) != Module) {
01313
01314 send_procedure(SCP_ATTR_IDX(scp_idx),
01315 SCP_ENTRY_IDX(scp_idx),
01316 Parent);
01317
01318 scp_idx = SCP_PARENT_IDX(scp_idx);
01319 }
01320
01321 TRACE (Func_Exit, "cvrt_sytb_to_pdg", NULL);
01322
01323 return;
01324
01325 }
01326
01327
01328 #ifdef KEY
01329
01330
01331
01332
01333
01334 static dv_idx_type
01335 opr_to_dv_hdr_fld(int ir_idx)
01336 {
01337 switch (IR_OPR(ir_idx)) {
01338 case Dv_Set_Base_Addr :
01339 case Dv_Access_Base_Addr :
01340 return DV_BASE_IDX;
01341 break;
01342 case Dv_Set_El_Len :
01343 case Dv_Access_El_Len :
01344 return DV_EL_LEN_IDX;
01345 break;
01346 case Dv_Set_Assoc :
01347 case Dv_Access_Assoc :
01348 return DV_ASSOC_IDX;
01349 break;
01350 case Dv_Set_Ptr_Alloc :
01351 case Dv_Access_Ptr_Alloc :
01352 return DV_PTR_ALLOC_IDX;
01353 break;
01354 case Dv_Set_P_Or_A :
01355 case Dv_Access_P_Or_A :
01356 return DV_P_OR_A_IDX;
01357 break;
01358 case Dv_Set_A_Contig :
01359 case Dv_Access_A_Contig :
01360 return DV_A_CONTIG_IDX;
01361 break;
01362 case Dv_Set_N_Dim :
01363 case Dv_Access_N_Dim :
01364 return DV_NUM_DIMS_IDX;
01365 break;
01366 case Dv_Set_Typ_Code :
01367 case Dv_Access_Typ_Code :
01368 return DV_TYPE_CODE_IDX;
01369 break;
01370 case Dv_Set_Orig_Base :
01371 case Dv_Access_Orig_Base :
01372 return DV_ORIG_BASE_IDX;
01373 break;
01374 case Dv_Set_Orig_Size :
01375 case Dv_Access_Orig_Size :
01376 return DV_ORIG_SIZE_IDX;
01377 break;
01378 default:
01379 PRINTMSG(IR_LINE_NUM(ir_idx), 1044, Internal, IR_COL_NUM(ir_idx),
01380 "opr_to_dv_hdr_fld");
01381 return 0;
01382 break;
01383 }
01384 }
01385 #endif
01386
01387
01388
01389
01390
01391
01392
01393
01394
01395
01396
01397
01398
01399
01400
01401 static void cvrt_exp_to_pdg(int ir_idx,
01402 fld_type field)
01403 {
01404
01405 static boolean high_range_present;
01406 static boolean low_range_present;
01407 static boolean member;
01408 static boolean static_initialization;
01409
01410 long_type loc_value[MAX_WORDS_FOR_NUMERIC];
01411 int attr_idx;
01412 int type_idx;
01413 int base_attr;
01414 TYPE basic;
01415 int col;
01416 TYPE arg_type;
01417 INT32 big_int;
01418 long64 bit_length = 0;
01419 boolean bound_chk;
01420 int bound_idx;
01421 int cn_idx;
01422 int idx;
01423 int constant_class;
01424 int count;
01425 int dim;
01426 long64 end;
01427 long64 flags = 0;
01428 int j;
01429 long64 i;
01430 boolean ignore_types;
01431 long64 inc;
01432 opnd_type l_opnd;
01433 long first_task_idx = NULL_IDX;
01434 long last_task_idx = NULL_IDX;
01435 int line;
01436 int list_array[OPEN_MP_LIST_CNT];
01437 int list_cnt;
01438 int list_idx1;
01439 int list_idx2;
01440 int list_idx3;
01441 int list_idx4;
01442 int name_idx;
01443 int next_idx;
01444 int number_actual_args;
01445 long64 offset;
01446 int path_idx;
01447 long pdg_cn_idx;
01448 long64 rep_count;
01449 int return_kind;
01450 boolean save_symbolic_constant_expr;
01451 int search_idx;
01452 int ss;
01453 long64 start;
01454 INT64 static_subscripts[7];
01455 long64 stride;
01456 int t_idx;
01457 int task_tbl_idx;
01458 long task_maxcpus_idx;
01459 long task_wdist_idx;
01460 long which;
01461 long assertion;
01462 long task_if_idx = 0;
01463 long task_num_threads_idx = 0;
01464 char *criticalname = 0;
01465 long level = 0;
01466 long span = 1;
01467 long point = 0;
01468 long scheduletype = 0;
01469 long schedulechunk = 0;
01470 long schedtype = 0;
01471 long chunkcount = 0;
01472 long threadcount = 0;
01473 long datacount = 0;
01474 long reductioncount = 0;
01475 long ontocount = 0;
01476 long ordered = 0;
01477 long defaultt = 0;
01478 long nowait = 0;
01479 long varcount = 0;
01480 long C_value = 0;
01481 long prefetch_manual = 0;
01482 long prefetch_array = 0;
01483 long redistribute_array = 0;
01484 long context = -1;
01485 long prefetch_size = -1;
01486 long prefetch_kind = -1;
01487 int stride_list = 0;
01488 int level_list = 0;
01489 int cyclic_list = 0;
01490 int onto_list = 0;
01491 long n1 = 0;
01492 long n2 = 0;
01493 long cyclic_exists = 0;
01494 long onto_exists = 0;
01495 int tmp_ir_idx;
01496 int trip;
01497 TYPE type_desc;
01498 boolean unused;
01499 long64 vv;
01500 int fld;
01501 boolean EXPAND = FALSE;
01502 size_offset_type offset1;
01503 size_offset_type offset2;
01504 opnd_type opnd;
01505 size_offset_type result;
01506 int pe_bd_idx;
01507 long64 arith_constant[4];
01508 int arg_idx;
01509 int lhs_idx;
01510 int mask_idx;
01511 int proc_idx;
01512 int rhs_idx;
01513
01514
01515 TRACE (Func_Entry, "cvrt_exp_to_pdg", NULL);
01516
01517 switch (field) {
01518
01519 case NO_Tbl_Idx :
01520
01521 if (processing_call > 0) {
01522 PDG_DBG_PRINT_START
01523 PDG_DBG_PRINT_C("fei_null_expr");
01524 PDG_DBG_PRINT_END
01525
01526 # ifdef _ENABLE_FEI
01527 fei_null_expr();
01528 # endif
01529 }
01530 break;
01531
01532 case SB_Tbl_Idx :
01533 PDG_DBG_PRINT_START
01534 PDG_DBG_PRINT_C("fei_seg_ref");
01535 PDG_DBG_PRINT_S("SB_NAME_PTR", SB_NAME_PTR(ir_idx));
01536 PDG_DBG_PRINT_LD("(1) PDG_SB_IDX", PDG_SB_IDX(ir_idx));
01537 PDG_DBG_PRINT_END
01538
01539 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
01540 # ifdef _ENABLE_FEI
01541 fei_seg_ref(PDG_SB_IDX(ir_idx));
01542 # endif
01543 # endif
01544 break;
01545
01546
01547 case CN_Tbl_Idx :
01548 constant_class = Arith_Const;
01549
01550 if (data_attr != NULL_IDX &&
01551 stack_data_constant &&
01552 (TYP_TYPE(CN_TYPE_IDX(ir_idx)) == Integer ||
01553 TYP_TYPE(CN_TYPE_IDX(ir_idx)) == Real ||
01554 TYP_TYPE(CN_TYPE_IDX(ir_idx)) == Complex) &&
01555 TYP_LINEAR(ATD_TYPE_IDX(data_attr)) != CRI_Ptr_8 &&
01556 TYP_LINEAR(ATD_TYPE_IDX(data_attr)) != CRI_Ch_Ptr_8 &&
01557 TYP_LINEAR(ATD_TYPE_IDX(data_attr)) !=
01558 TYP_LINEAR(CN_TYPE_IDX(ir_idx))) {
01559
01560
01561
01562
01563
01564
01565 type_idx = ATD_TYPE_IDX(data_attr);
01566 line = 1; col = 1;
01567 if (folder_driver( (char *) &CN_CONST(ir_idx),
01568 CN_TYPE_IDX(ir_idx),
01569 NULL,
01570 NULL_IDX,
01571 loc_value,
01572 &type_idx,
01573 line,
01574 col,
01575 1,
01576 Cvrt_Opr))
01577 ir_idx = ntr_const_tbl(type_idx,
01578 FALSE,
01579 loc_value);
01580 }
01581
01582
01583 switch (TYP_TYPE(CN_TYPE_IDX(ir_idx))) {
01584 case Character :
01585 bit_length = CN_INT_TO_C(TYP_IDX(CN_TYPE_IDX(ir_idx)));
01586
01587 if (stack_data_constant &&
01588 data_character_bit_length != 0 &&
01589 IL_FLD(data_character_bit_length) == CN_Tbl_Idx) {
01590 bit_length = CN_INT_TO_C(IL_IDX(data_character_bit_length));
01591 PDG_CN_IDX(ir_idx) = 0;
01592 }
01593
01594 constant_class = Pattern_Const;
01595 bit_length = bit_length * CHAR_BIT;
01596 data_character_bit_length = 0;
01597 break;
01598
01599 case Typeless :
01600 bit_length = TYP_BIT_LEN(CN_TYPE_IDX(ir_idx));
01601 constant_class = Pattern_Const;
01602
01603
01604
01605
01606
01607 if (bit_length == TARGET_BITS_PER_WORD ||
01608 TYP_LINEAR(CN_TYPE_IDX(ir_idx)) == Typeless_4 ||
01609 TYP_LINEAR(CN_TYPE_IDX(ir_idx)) == Typeless_8) {
01610 constant_class = Arith_Const;
01611 }
01612 break;
01613 }
01614
01615
01616
01617
01618
01619
01620
01621
01622
01623 if (PDG_CN_IDX(ir_idx) == 0 || ir_idx >= pdg_link_tbl_size) {
01624 basic = get_basic_type(CN_TYPE_IDX(ir_idx), 0, NULL_IDX);
01625
01626
01627 if (symbolic_constant_expr) {
01628 PDG_DBG_PRINT_START
01629 PDG_DBG_PRINT_C("fei_arith_con");
01630 PDG_DBG_PRINT_T("(1) type", basic);
01631 #if defined(_HOST32) && defined(_TARGET64)
01632 PDG_DBG_PRINT_VD("(2) const", CN_CONST(ir_idx));
01633 #else
01634 PDG_DBG_PRINT_LVD("(2) const", CN_CONST(ir_idx));
01635 #endif
01636 PDG_DBG_PRINT_END
01637
01638 # ifdef _ENABLE_FEI
01639 PDG_CN_IDX(ir_idx) = fei_arith_con(basic,
01640 (long *)&CN_CONST(ir_idx));
01641 # endif
01642 PDG_DBG_PRINT_START
01643 PDG_DBG_PRINT_LD("(r) PDG_CN_IDX", PDG_CN_IDX(ir_idx));
01644 PDG_DBG_PRINT_END
01645
01646 PDG_DBG_PRINT_START
01647 PDG_DBG_PRINT_C("npex_constant");
01648 PDG_DBG_PRINT_LD("(1) PDG_CN_IDX", PDG_CN_IDX(ir_idx));
01649 PDG_DBG_PRINT_END
01650
01651 # ifdef _ENABLE_FEI
01652 npex_constant(PDG_CN_IDX(ir_idx));
01653 # endif
01654 }
01655 else {
01656 PDG_DBG_PRINT_START
01657 PDG_DBG_PRINT_C("fei_constant");
01658 PDG_DBG_PRINT_T("(1) type", basic);
01659 #if defined(_HOST32) && defined(_TARGET64)
01660 PDG_DBG_PRINT_S("(2) class", p_const_class[constant_class]);
01661 PDG_DBG_PRINT_VD("(3) const", CN_CONST(ir_idx));
01662 PDG_DBG_PRINT_VD("(4) bit length", bit_length);
01663 #else
01664 PDG_DBG_PRINT_S("(2) class", p_const_class[constant_class]);
01665 PDG_DBG_PRINT_LVD("(3) const", CN_CONST(ir_idx));
01666 PDG_DBG_PRINT_LLD("(4) bit length", bit_length);
01667 #endif
01668 PDG_DBG_PRINT_END
01669
01670 # ifdef _ENABLE_FEI
01671
01672 # if defined(_TARGET_SV2)
01673 if (constant_class == Arith_Const) {
01674 if (TYP_LINEAR(CN_TYPE_IDX(ir_idx)) == Complex_4 ||
01675 TYP_LINEAR(CN_TYPE_IDX(ir_idx)) == Integer_8 ||
01676 TYP_LINEAR(CN_TYPE_IDX(ir_idx)) == Real_8) {
01677
01678 arith_constant[0] = CN_CONST(ir_idx);
01679 arith_constant[0] = arith_constant[0] << 32;
01680 arith_constant[0] |= CP_CONSTANT(CN_POOL_IDX(ir_idx) + 1);
01681 }
01682 else if (TYP_LINEAR(CN_TYPE_IDX(ir_idx)) == Complex_8 ||
01683 TYP_LINEAR(CN_TYPE_IDX(ir_idx)) == Real_16) {
01684
01685 arith_constant[0] = CN_CONST(ir_idx);
01686 arith_constant[0] = arith_constant[0] << 32;
01687 arith_constant[0] |= CP_CONSTANT(CN_POOL_IDX(ir_idx) + 1);
01688 arith_constant[1] = CP_CONSTANT(CN_POOL_IDX(ir_idx) + 2);
01689 arith_constant[1] = arith_constant[1] << 32;
01690 arith_constant[1] |= CP_CONSTANT(CN_POOL_IDX(ir_idx) + 3);
01691 }
01692 else if (TYP_LINEAR(CN_TYPE_IDX(ir_idx)) == Complex_16) {
01693
01694 arith_constant[0] = CN_CONST(ir_idx);
01695 arith_constant[0] = arith_constant[0] << 32;
01696 arith_constant[0] |= CP_CONSTANT(CN_POOL_IDX(ir_idx) + 1);
01697 arith_constant[1] = CP_CONSTANT(CN_POOL_IDX(ir_idx) + 2);
01698 arith_constant[1] = arith_constant[1] << 32;
01699 arith_constant[1] |= CP_CONSTANT(CN_POOL_IDX(ir_idx) + 3);
01700 arith_constant[2] = CP_CONSTANT(CN_POOL_IDX(ir_idx) + 4);
01701 arith_constant[2] = arith_constant[2] << 32;
01702 arith_constant[2] |= CP_CONSTANT(CN_POOL_IDX(ir_idx) + 5);
01703 arith_constant[3] = CP_CONSTANT(CN_POOL_IDX(ir_idx) + 6);
01704 arith_constant[3] = arith_constant[3] << 32;
01705 arith_constant[3] |= CP_CONSTANT(CN_POOL_IDX(ir_idx) + 7);
01706 }
01707 else {
01708 arith_constant[0] = CN_CONST(ir_idx);
01709 }
01710
01711 pdg_cn_idx = fei_constant(basic,
01712 constant_class,
01713 (char *) &arith_constant,
01714 bit_length);
01715 }
01716 else {
01717 pdg_cn_idx = fei_constant(basic,
01718 constant_class,
01719 (char *) &CN_CONST(ir_idx),
01720 bit_length);
01721 }
01722
01723 # elif defined(_TARGET_OS_MAX)
01724 if (TYP_LINEAR(CN_TYPE_IDX(ir_idx)) == Complex_4) {
01725
01726 i = CN_CONST(ir_idx) << 32;
01727 i |= CP_CONSTANT(CN_POOL_IDX(ir_idx) + 1);
01728 pdg_cn_idx = fei_constant(basic,
01729 constant_class,
01730 (char *) &i,
01731 bit_length);
01732 }
01733 else {
01734 pdg_cn_idx = fei_constant(basic,
01735 constant_class,
01736 (char *) &CN_CONST(ir_idx),
01737 bit_length);
01738 }
01739 # else
01740 pdg_cn_idx = fei_constant(basic,
01741 constant_class,
01742 (char *) &CN_CONST(ir_idx),
01743 bit_length);
01744 # endif
01745
01746 # endif
01747 PDG_DBG_PRINT_START
01748 PDG_DBG_PRINT_LD("(r) PDG_CN_IDX", pdg_cn_idx);
01749 PDG_DBG_PRINT_END
01750
01751 if (ir_idx < pdg_link_tbl_size) {
01752 PDG_CN_IDX(ir_idx) = pdg_cn_idx;
01753 }
01754 }
01755 }
01756 else {
01757 if (constant_class == Pattern_Const) {
01758 PDG_DBG_PRINT_START
01759 PDG_DBG_PRINT_C("fei_push_pattern_con");
01760 PDG_DBG_PRINT_LD("(1) PDG_CN_IDX", PDG_CN_IDX(ir_idx));
01761 PDG_DBG_PRINT_END
01762
01763 # ifdef _ENABLE_FEI
01764 fei_push_pattern_con(PDG_CN_IDX(ir_idx));
01765 # endif
01766 }
01767 else if (symbolic_constant_expr) {
01768 PDG_DBG_PRINT_START
01769 PDG_DBG_PRINT_C("npex_constant");
01770 PDG_DBG_PRINT_LD("(1) PDG_CN_IDX", PDG_CN_IDX(ir_idx));
01771 PDG_DBG_PRINT_END
01772
01773 # ifdef _ENABLE_FEI
01774 npex_constant(PDG_CN_IDX(ir_idx));
01775 # endif
01776 }
01777 else {
01778 PDG_DBG_PRINT_START
01779 PDG_DBG_PRINT_C("fei_push_arith_con");
01780 PDG_DBG_PRINT_LD("(1) PDG_CN_IDX", PDG_CN_IDX(ir_idx));
01781 PDG_DBG_PRINT_END
01782
01783 # ifdef _ENABLE_FEI
01784 fei_push_arith_con(PDG_CN_IDX(ir_idx));
01785 # endif
01786 }
01787 }
01788 break;
01789
01790
01791 case IL_Tbl_Idx :
01792
01793 while (ir_idx != NULL_IDX) {
01794 cvrt_exp_to_pdg(IL_IDX(ir_idx),
01795 IL_FLD(ir_idx));
01796 ir_idx = IL_NEXT_LIST_IDX(ir_idx);
01797 }
01798
01799 break;
01800
01801
01802 case AT_Tbl_Idx :
01803 send_attr_ntry(ir_idx);
01804
01805 # if defined(_TARGET_OS_MAX)
01806
01807 if (AT_OBJ_CLASS(ir_idx) == Data_Obj && ATD_SYMBOLIC_CONSTANT(ir_idx)) {
01808
01809 if (ATD_CLASS(ir_idx) == Variable) {
01810
01811 if (symbolic_constant_expr) {
01812 PDG_DBG_PRINT_START
01813 PDG_DBG_PRINT_C("npex_npes");
01814 PDG_DBG_PRINT_END
01815
01816 # ifdef _ENABLE_FEI
01817 npex_npes();
01818 # endif
01819 }
01820 else {
01821 PDG_DBG_PRINT_START
01822 PDG_DBG_PRINT_C("fei_n_pes");
01823 PDG_DBG_PRINT_END
01824
01825 # ifdef _ENABLE_FEI
01826 fei_n_pes();
01827 # endif
01828 }
01829 }
01830 else {
01831
01832 if (symbolic_constant_expr) {
01833 PDG_DBG_PRINT_START
01834 PDG_DBG_PRINT_C("npex_push");
01835 PDG_DBG_PRINT_D("(1) PDG_AT_IDX", PDG_AT_IDX(ir_idx));
01836 PDG_DBG_PRINT_END
01837
01838 # ifdef _ENABLE_FEI
01839 npex_push(PDG_AT_IDX(ir_idx));
01840 # endif
01841 }
01842 else {
01843 PDG_DBG_PRINT_START
01844 PDG_DBG_PRINT_C("npex_to_expr");
01845 PDG_DBG_PRINT_D("PDG_AT_IDX", PDG_AT_IDX(ir_idx));
01846 PDG_DBG_PRINT_END
01847
01848 # ifdef _ENABLE_FEI
01849 npex_to_expr(PDG_AT_IDX(ir_idx));
01850 # endif
01851 }
01852 }
01853 break;
01854 }
01855 # endif
01856
01857
01858 if (AT_OBJ_CLASS(ir_idx) == Data_Obj) {
01859 if (ATD_CLASS(ir_idx) == Compiler_Tmp &&
01860 ATD_TMP_INIT_NOT_DONE(ir_idx)) {
01861 insert_init_stmt_for_tmp(ir_idx);
01862 }
01863
01864 if (data_attr == NULL_IDX) {
01865 data_attr = ir_idx;
01866 }
01867
01868 if (stack_data_object && member) {
01869 PDG_DBG_PRINT_START
01870 PDG_DBG_PRINT_C("fei_static_member");
01871 PDG_DBG_PRINT_S("AT_OBJ_NAME", AT_OBJ_NAME_PTR(ir_idx));
01872 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX", PDG_AT_IDX(ir_idx));
01873 PDG_DBG_PRINT_END
01874
01875 # ifdef _ENABLE_FEI
01876 fei_static_member(PDG_AT_IDX(ir_idx));
01877 # endif
01878 }
01879 else if (stack_data_object) {
01880 PDG_DBG_PRINT_START
01881 PDG_DBG_PRINT_C("fei_static_base");
01882 PDG_DBG_PRINT_S("AT_OBJ_NAME", AT_OBJ_NAME_PTR(ir_idx));
01883 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX", PDG_AT_IDX(ir_idx));
01884 PDG_DBG_PRINT_END
01885
01886 # ifdef _ENABLE_FEI
01887 fei_static_base(PDG_AT_IDX(ir_idx));
01888 # endif
01889 }
01890 else if (member) {
01891 PDG_DBG_PRINT_START
01892 PDG_DBG_PRINT_C("fei_member_ref");
01893 PDG_DBG_PRINT_S("AT_OBJ_NAME", AT_OBJ_NAME_PTR(ir_idx));
01894 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX", PDG_AT_IDX(ir_idx));
01895 PDG_DBG_PRINT_END
01896
01897 # ifdef _ENABLE_FEI
01898 fei_member_ref(PDG_AT_IDX(ir_idx));
01899 # endif
01900 }
01901 else {
01902 PDG_DBG_PRINT_START
01903 PDG_DBG_PRINT_C("fei_object_ref");
01904 PDG_DBG_PRINT_S("AT_OBJ_NAME", AT_OBJ_NAME_PTR(ir_idx));
01905 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX", PDG_AT_IDX(ir_idx));
01906 PDG_DBG_PRINT_D("(2) whole_subscript", whole_subscript);
01907 PDG_DBG_PRINT_D("(3) whole_substring", whole_substring);
01908 PDG_DBG_PRINT_END
01909
01910 # ifdef _ENABLE_FEI
01911 fei_object_ref(PDG_AT_IDX(ir_idx),
01912 whole_subscript,
01913 whole_substring);
01914 # endif
01915 }
01916 }
01917 else if (AT_OBJ_CLASS(ir_idx) == Namelist_Grp) {
01918 PDG_DBG_PRINT_START
01919 PDG_DBG_PRINT_C("fei_namelist_ref");
01920 PDG_DBG_PRINT_S("AT_OBJ_NAME", AT_OBJ_NAME_PTR(ir_idx));
01921 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX", PDG_AT_IDX(ir_idx));
01922 PDG_DBG_PRINT_END
01923
01924 # ifdef _ENABLE_FEI
01925 fei_namelist_ref(PDG_AT_IDX(ir_idx));
01926 # endif
01927 }
01928 else if (AT_OBJ_CLASS(ir_idx) == Pgm_Unit &&
01929 ATP_PROC(ir_idx) == Dummy_Proc) {
01930 PDG_DBG_PRINT_START
01931 PDG_DBG_PRINT_C("fei_object_ref");
01932 PDG_DBG_PRINT_S("AT_OBJ_NAME", AT_OBJ_NAME_PTR(ir_idx));
01933 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX", PDG_AT_IDX(ir_idx));
01934 PDG_DBG_PRINT_D("(2) whole_subscript", whole_subscript);
01935 PDG_DBG_PRINT_D("(3) whole_substring", whole_substring);
01936 PDG_DBG_PRINT_END
01937
01938 # ifdef _ENABLE_FEI
01939 fei_object_ref(PDG_AT_IDX(ir_idx),
01940 whole_subscript,
01941 whole_substring);
01942 # endif
01943 }
01944 else if (AT_OBJ_CLASS(ir_idx) == Pgm_Unit) {
01945 PDG_DBG_PRINT_START
01946 PDG_DBG_PRINT_C("fei_function_ref");
01947 PDG_DBG_PRINT_S("AT_OBJ_NAME", AT_OBJ_NAME_PTR(ir_idx));
01948 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX", PDG_AT_IDX(ir_idx));
01949 PDG_DBG_PRINT_END
01950
01951 # ifdef _ENABLE_FEI
01952 fei_function_ref(PDG_AT_IDX(ir_idx));
01953 # endif
01954 }
01955 else if (AT_OBJ_CLASS(ir_idx) == Label) {
01956 PDG_DBG_PRINT_START
01957 PDG_DBG_PRINT_C("fei_label_ref");
01958 PDG_DBG_PRINT_S("AT_OBJ_NAME", AT_OBJ_NAME_PTR(ir_idx));
01959 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX", PDG_AT_IDX(ir_idx));
01960 PDG_DBG_PRINT_END
01961
01962 # ifdef _ENABLE_FEI
01963 fei_label_ref(PDG_AT_IDX(ir_idx));
01964 # endif
01965 }
01966
01967 break;
01968
01969
01970
01971 case IR_Tbl_Idx :
01972
01973 # ifdef _DEBUG
01974 if (IR_TYPE_IDX(ir_idx) == NULL_IDX) {
01975 print_ir(ir_idx);
01976 PRINTMSG(IR_LINE_NUM(ir_idx), 993, Internal,
01977 IR_COL_NUM(ir_idx));
01978 }
01979
01980 if (IR_LINE_NUM(ir_idx) <= 0) {
01981 print_ir(ir_idx);
01982 PRINTMSG(1, 1150, Internal, IR_COL_NUM(ir_idx));
01983 }
01984
01985 if ((IR_FLD_L(ir_idx) == AT_Tbl_Idx ||
01986 IR_FLD_L(ir_idx) == CN_Tbl_Idx) &&
01987 IR_LINE_NUM_L(ir_idx) <= 0) {
01988 print_ir(ir_idx);
01989 PRINTMSG(1, 1150, Internal, IR_COL_NUM(ir_idx));
01990 }
01991
01992 if ((IR_FLD_R(ir_idx) == AT_Tbl_Idx ||
01993 IR_FLD_R(ir_idx) == CN_Tbl_Idx) &&
01994 IR_LINE_NUM_R(ir_idx) <= 0) {
01995
01996 print_ir(ir_idx);
01997 PRINTMSG(1, 1150, Internal, IR_COL_NUM(ir_idx));
01998 }
01999
02000 if (IR_FLD_L(ir_idx) == IL_Tbl_Idx) {
02001 list_idx1 = IR_IDX_L(ir_idx);
02002
02003 while (list_idx1) {
02004 if ((IL_FLD(list_idx1) == AT_Tbl_Idx ||
02005 IL_FLD(list_idx1) == CN_Tbl_Idx) &&
02006 IL_LINE_NUM(list_idx1) <= 0) {
02007
02008 print_ir(ir_idx);
02009 PRINTMSG(1, 1150, Internal, IR_COL_NUM(ir_idx));
02010 }
02011 list_idx1 = IL_NEXT_LIST_IDX(list_idx1);
02012 }
02013 }
02014
02015 if (IR_FLD_R(ir_idx) == IL_Tbl_Idx) {
02016 list_idx1 = IR_IDX_R(ir_idx);
02017
02018 while (list_idx1) {
02019 if ((IL_FLD(list_idx1) == AT_Tbl_Idx ||
02020 IL_FLD(list_idx1) == CN_Tbl_Idx) &&
02021 IL_LINE_NUM(list_idx1) <= 0) {
02022
02023 print_ir(ir_idx);
02024 PRINTMSG(1, 1150, Internal, IR_COL_NUM(ir_idx));
02025 }
02026 list_idx1 = IL_NEXT_LIST_IDX(list_idx1);
02027 }
02028 }
02029 # endif
02030
02031 switch (IR_OPR(ir_idx)) {
02032
02033 case Stmt_Expansion_Opr:
02034 # ifdef _DEBUG
02035 PRINTMSG(IR_LINE_NUM(ir_idx), 626, Internal, IR_COL_NUM(ir_idx),
02036 "no Stmt_Expansion_Opr", "cvrt_exp_to_pdg");
02037 # endif
02038
02039 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02040 IR_FLD_L(ir_idx));
02041 break;
02042
02043 case Case_Range_Opr :
02044 if (IR_IDX_L(ir_idx) == NULL_IDX) {
02045 low_range_present = FALSE;
02046 }
02047 else {
02048 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02049 IR_FLD_L(ir_idx));
02050 low_range_present = TRUE;
02051 }
02052
02053 if (IR_IDX_R(ir_idx) == NULL_IDX) {
02054 high_range_present = FALSE;
02055 }
02056 else {
02057 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
02058 IR_FLD_R(ir_idx));
02059 high_range_present = TRUE;
02060 }
02061 break;
02062
02063
02064
02065
02066 case Case_Opr :
02067 if (IR_IDX_L(ir_idx) != NULL_IDX) {
02068 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02069 IR_FLD_L(ir_idx));
02070
02071 big_int = CN_INT_TO_C(IR_IDX_R(ir_idx));
02072
02073 PDG_DBG_PRINT_START
02074 PDG_DBG_PRINT_C("fei_new_select_case");
02075 PDG_DBG_PRINT_S("(1) low_range", p_boolean[low_range_present]);
02076 PDG_DBG_PRINT_S("(2) high_range", p_boolean[high_range_present]);
02077 #if defined(_HOST32) && defined(_TARGET64)
02078 PDG_DBG_PRINT_D("(3) const", big_int);
02079 #else
02080 PDG_DBG_PRINT_VD("(3) const", big_int);
02081 #endif
02082 PDG_DBG_PRINT_END
02083
02084
02085 # ifdef _ENABLE_FEI
02086 fei_new_select_case(low_range_present,
02087 high_range_present,
02088 big_int);
02089 # endif
02090 low_range_present = FALSE;
02091 high_range_present = FALSE;
02092 }
02093 break;
02094
02095
02096
02097
02098
02099 case Select_Opr :
02100 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02101 IR_FLD_L(ir_idx));
02102
02103 list_idx1 = IR_IDX_R(ir_idx);
02104 list_idx2 = IL_NEXT_LIST_IDX(list_idx1);
02105 list_idx3 = IL_NEXT_LIST_IDX(list_idx2);
02106
02107 if (IR_LIST_CNT_R(ir_idx) == 2) {
02108 list_idx3 = list_idx2;
02109 }
02110
02111 send_attr_ntry(IL_IDX(list_idx3));
02112 big_int = CN_INT_TO_C(IL_IDX(list_idx1));
02113
02114 PDG_DBG_PRINT_START
02115 PDG_DBG_PRINT_C("fei_new_select");
02116 #if defined(_HOST32) && defined(_TARGET64)
02117 PDG_DBG_PRINT_D("(1) num cases", big_int);
02118 #else
02119 PDG_DBG_PRINT_VD("(1) num cases", big_int);
02120 #endif
02121 PDG_DBG_PRINT_LD("(2) default label", PDG_AT_IDX(IL_IDX(list_idx3)));
02122 PDG_DBG_PRINT_END
02123
02124 # ifdef _ENABLE_FEI
02125 fei_new_select(big_int,
02126 #ifdef KEY
02127 PDG_AT_IDX(IL_IDX(list_idx2)),
02128 #endif
02129 PDG_AT_IDX(IL_IDX(list_idx3)));
02130 # endif
02131 break;
02132
02133
02134
02135
02136 case Ptr_Asg_Opr :
02137 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02138 IR_FLD_L(ir_idx));
02139
02140 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
02141 IR_FLD_R(ir_idx));
02142
02143 PDG_DBG_PRINT_START
02144 PDG_DBG_PRINT_C("fei_dv_ptr_asg");
02145 PDG_DBG_PRINT_END
02146
02147 # ifdef _ENABLE_FEI
02148 fei_dv_ptr_asg();
02149 # endif
02150 break;
02151
02152
02153
02154
02155
02156
02157 case Length_Opr :
02158 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02159 IR_FLD_L(ir_idx));
02160
02161 PDG_DBG_PRINT_START
02162 PDG_DBG_PRINT_C("fei_length");
02163 PDG_DBG_PRINT_END
02164
02165 # ifdef _ENABLE_FEI
02166 fei_length();
02167 # endif
02168 break;
02169
02170
02171
02172
02173 case Getpos_Opr :
02174 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02175 IR_FLD_L(ir_idx));
02176
02177 PDG_DBG_PRINT_START
02178 PDG_DBG_PRINT_C("fei_getpos");
02179 PDG_DBG_PRINT_END
02180
02181 # ifdef _ENABLE_FEI
02182 fei_getpos();
02183 # endif
02184 break;
02185
02186
02187
02188 case Unit_Opr :
02189 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02190 IR_FLD_L(ir_idx));
02191
02192 PDG_DBG_PRINT_START
02193 PDG_DBG_PRINT_C("fei_unit");
02194 PDG_DBG_PRINT_END
02195
02196 # ifdef _ENABLE_FEI
02197 fei_unit();
02198 # endif
02199 break;
02200
02201
02202
02203
02204
02205
02206 case Index_Opr :
02207 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02208 IR_FLD_L(ir_idx));
02209
02210 PDG_DBG_PRINT_START
02211 PDG_DBG_PRINT_C("fei_index");
02212 PDG_DBG_PRINT_END
02213
02214 # ifdef _ENABLE_FEI
02215 fei_index();
02216 # endif
02217 break;
02218
02219
02220
02221
02222 case Cmplx_Opr :
02223 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02224 IR_FLD_L(ir_idx));
02225
02226 basic = get_basic_type(IR_TYPE_IDX(ir_idx), 0, NULL_IDX);
02227
02228 PDG_DBG_PRINT_START
02229 PDG_DBG_PRINT_C("fei_complex");
02230 PDG_DBG_PRINT_END
02231
02232 # ifdef _ENABLE_FEI
02233 fei_complex(basic);
02234 # endif
02235 break;
02236
02237
02238
02239
02240 case Concat_Opr :
02241 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02242 IR_FLD_L(ir_idx));
02243
02244 PDG_DBG_PRINT_START
02245 PDG_DBG_PRINT_C("fei_concat");
02246 PDG_DBG_PRINT_D("(1) num ops", IR_LIST_CNT_L(ir_idx));
02247 PDG_DBG_PRINT_END
02248
02249 # ifdef _ENABLE_FEI
02250 fei_concat(IR_LIST_CNT_L(ir_idx));
02251 # endif
02252 break;
02253
02254
02255
02256
02257
02258
02259
02260 case Lock_Release_Opr :
02261 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02262 IR_FLD_L(ir_idx));
02263
02264 PDG_DBG_PRINT_START
02265 PDG_DBG_PRINT_C("fei_lock_release");
02266 PDG_DBG_PRINT_END
02267
02268 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
02269 # ifdef _ENABLE_FEI
02270 fei_lock_release();
02271 # endif
02272 # endif
02273
02274 break;
02275
02276
02277
02278
02279 case Omp_Test_Lock_Opr :
02280 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02281 IR_FLD_L(ir_idx));
02282
02283 PDG_DBG_PRINT_START
02284 PDG_DBG_PRINT_C("fei_omp_test_lock");
02285 PDG_DBG_PRINT_END
02286
02287 # ifdef _ENABLE_FEI
02288 fei_omp_test_lock();
02289 # endif
02290 break;
02291
02292
02293
02294
02295 case Omp_Set_Lock_Opr :
02296 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02297 IR_FLD_L(ir_idx));
02298
02299 PDG_DBG_PRINT_START
02300 PDG_DBG_PRINT_C("fei_omp_set_lock");
02301 PDG_DBG_PRINT_END
02302
02303 # ifdef _ENABLE_FEI
02304 fei_omp_set_lock();
02305 # endif
02306 break;
02307
02308
02309
02310
02311
02312 case Omp_Unset_Lock_Opr :
02313 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02314 IR_FLD_L(ir_idx));
02315
02316 PDG_DBG_PRINT_START
02317 PDG_DBG_PRINT_C("fei_omp_unset_lock");
02318 PDG_DBG_PRINT_END
02319
02320 # ifdef _ENABLE_FEI
02321 fei_omp_unset_lock();
02322 # endif
02323 break;
02324
02325
02326
02327
02328
02329
02330 case Synchronize_Opr :
02331 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02332 IR_FLD_L(ir_idx));
02333
02334 PDG_DBG_PRINT_START
02335 PDG_DBG_PRINT_C("fei_synchronize");
02336 PDG_DBG_PRINT_END
02337
02338 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
02339 # ifdef _ENABLE_FEI
02340 fei_synchronize();
02341 # endif
02342 # endif
02343
02344 break;
02345
02346
02347
02348
02349 case Compare_And_Swap_Opr :
02350 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02351 IR_FLD_L(ir_idx));
02352
02353 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
02354
02355 PDG_DBG_PRINT_START
02356 PDG_DBG_PRINT_C("fei_compare_and_swap");
02357 PDG_DBG_PRINT_END
02358
02359 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
02360 # ifdef _ENABLE_FEI
02361 fei_compare_and_swap(basic);
02362 # endif
02363 # endif
02364
02365 break;
02366
02367
02368
02369
02370 case Lock_Test_And_Set_Opr :
02371 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02372 IR_FLD_L(ir_idx));
02373
02374 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
02375
02376 PDG_DBG_PRINT_START
02377 PDG_DBG_PRINT_C("fei_lock_test_and_set");
02378 PDG_DBG_PRINT_END
02379
02380 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
02381 # ifdef _ENABLE_FEI
02382 fei_lock_test_and_set(basic);
02383 # endif
02384 # endif
02385
02386 break;
02387
02388
02389
02390
02391
02392 case Fetch_And_Add_Opr :
02393 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02394 IR_FLD_L(ir_idx));
02395
02396 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
02397
02398 PDG_DBG_PRINT_START
02399 PDG_DBG_PRINT_C("fei_fetch_and_add");
02400 PDG_DBG_PRINT_END
02401
02402 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
02403 # ifdef _ENABLE_FEI
02404 fei_fetch_and_add(basic);
02405 # endif
02406 # endif
02407
02408 break;
02409
02410
02411
02412
02413 case Add_And_Fetch_Opr :
02414 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02415 IR_FLD_L(ir_idx));
02416
02417 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
02418
02419 PDG_DBG_PRINT_START
02420 PDG_DBG_PRINT_C("fei_add_and_fetch");
02421 PDG_DBG_PRINT_END
02422
02423 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
02424 # ifdef _ENABLE_FEI
02425 fei_add_and_fetch(basic);
02426 # endif
02427 # endif
02428
02429 break;
02430
02431
02432
02433
02434
02435 case Fetch_And_And_Opr :
02436 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02437 IR_FLD_L(ir_idx));
02438
02439 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
02440
02441 PDG_DBG_PRINT_START
02442 PDG_DBG_PRINT_C("fei_fetch_and_and");
02443 PDG_DBG_PRINT_END
02444
02445 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
02446 # ifdef _ENABLE_FEI
02447 fei_fetch_and_and(basic);
02448 # endif
02449 # endif
02450
02451 break;
02452
02453
02454
02455
02456
02457 case And_And_Fetch_Opr :
02458 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02459 IR_FLD_L(ir_idx));
02460
02461 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
02462
02463 PDG_DBG_PRINT_START
02464 PDG_DBG_PRINT_C("fei_and_and_fetch");
02465 PDG_DBG_PRINT_END
02466
02467 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
02468 # ifdef _ENABLE_FEI
02469 fei_and_and_fetch(basic);
02470 # endif
02471 # endif
02472
02473 break;
02474
02475
02476
02477
02478
02479 case Fetch_And_Nand_Opr :
02480 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02481 IR_FLD_L(ir_idx));
02482
02483 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
02484
02485 PDG_DBG_PRINT_START
02486 PDG_DBG_PRINT_C("fei_fetch_and_nand");
02487 PDG_DBG_PRINT_END
02488
02489 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
02490 # ifdef _ENABLE_FEI
02491 fei_fetch_and_nand(basic);
02492 # endif
02493 # endif
02494
02495 break;
02496
02497
02498
02499
02500
02501 case Nand_And_Fetch_Opr :
02502 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02503 IR_FLD_L(ir_idx));
02504
02505 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
02506
02507 PDG_DBG_PRINT_START
02508 PDG_DBG_PRINT_C("fei_nand_and_fetch");
02509 PDG_DBG_PRINT_END
02510
02511 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
02512 # ifdef _ENABLE_FEI
02513 fei_nand_and_fetch(basic);
02514 # endif
02515 # endif
02516
02517 break;
02518
02519
02520
02521
02522
02523
02524 case Fetch_And_Or_Opr :
02525 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02526 IR_FLD_L(ir_idx));
02527
02528 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
02529
02530 PDG_DBG_PRINT_START
02531 PDG_DBG_PRINT_C("fei_fetch_and_or");
02532 PDG_DBG_PRINT_END
02533
02534 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
02535 # ifdef _ENABLE_FEI
02536 fei_fetch_and_or(basic);
02537 # endif
02538 # endif
02539
02540 break;
02541
02542
02543
02544
02545 case Or_And_Fetch_Opr :
02546 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02547 IR_FLD_L(ir_idx));
02548
02549 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
02550
02551 PDG_DBG_PRINT_START
02552 PDG_DBG_PRINT_C("fei_or_and_fetch");
02553 PDG_DBG_PRINT_END
02554
02555 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
02556 # ifdef _ENABLE_FEI
02557 fei_or_and_fetch(basic);
02558 # endif
02559 # endif
02560
02561 break;
02562
02563
02564
02565
02566 case Fetch_And_Sub_Opr :
02567 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02568 IR_FLD_L(ir_idx));
02569
02570 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
02571
02572 PDG_DBG_PRINT_START
02573 PDG_DBG_PRINT_C("fei_fetch_sub_add");
02574 PDG_DBG_PRINT_END
02575
02576 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
02577 # ifdef _ENABLE_FEI
02578 fei_fetch_and_sub(basic);
02579 # endif
02580 # endif
02581
02582 break;
02583
02584
02585
02586
02587 case Sub_And_Fetch_Opr :
02588 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02589 IR_FLD_L(ir_idx));
02590
02591 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
02592
02593 PDG_DBG_PRINT_START
02594 PDG_DBG_PRINT_C("fei_sub_and_fetch");
02595 PDG_DBG_PRINT_END
02596
02597 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
02598 # ifdef _ENABLE_FEI
02599 fei_sub_and_fetch(basic);
02600 # endif
02601 # endif
02602
02603 break;
02604
02605
02606
02607
02608
02609
02610 case Fetch_And_Xor_Opr :
02611 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02612 IR_FLD_L(ir_idx));
02613
02614 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
02615
02616 PDG_DBG_PRINT_START
02617 PDG_DBG_PRINT_C("fei_fetch_and_xor");
02618 PDG_DBG_PRINT_END
02619
02620 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
02621 # ifdef _ENABLE_FEI
02622 fei_fetch_and_xor(basic);
02623 # endif
02624 # endif
02625
02626 break;
02627
02628
02629
02630
02631 case Xor_And_Fetch_Opr :
02632 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02633 IR_FLD_L(ir_idx));
02634
02635 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
02636
02637 PDG_DBG_PRINT_START
02638 PDG_DBG_PRINT_C("fei_xor_and_fetch");
02639 PDG_DBG_PRINT_END
02640
02641 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
02642 # ifdef _ENABLE_FEI
02643 fei_xor_and_fetch(basic);
02644 # endif
02645 # endif
02646
02647 break;
02648
02649
02650
02651
02652
02653
02654
02655
02656 case Mmx_Opr :
02657 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02658 IR_FLD_L(ir_idx));
02659
02660 PDG_DBG_PRINT_START
02661 PDG_DBG_PRINT_C("fei_mbmx");
02662 PDG_DBG_PRINT_END
02663
02664 # ifdef _ENABLE_FEI
02665 fei_mbmx();
02666 # endif
02667
02668 break;
02669
02670
02671
02672
02673
02674
02675 case Mldmx_Opr :
02676 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02677 IR_FLD_L(ir_idx));
02678
02679 PDG_DBG_PRINT_START
02680 PDG_DBG_PRINT_C("fei_mbmxl");
02681 PDG_DBG_PRINT_END
02682
02683 # ifdef _ENABLE_FEI
02684 fei_mbmxl();
02685 # endif
02686
02687 break;
02688
02689
02690
02691
02692
02693
02694
02695 case Mld_Opr :
02696 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02697 IR_FLD_L(ir_idx));
02698
02699 PDG_DBG_PRINT_START
02700 PDG_DBG_PRINT_C("fei_mbld");
02701 PDG_DBG_PRINT_END
02702
02703 # ifdef _ENABLE_FEI
02704 fei_mbld();
02705 # endif
02706
02707 break;
02708
02709
02710
02711
02712
02713
02714
02715 case Mul_Opr :
02716 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02717 IR_FLD_L(ir_idx));
02718
02719 PDG_DBG_PRINT_START
02720 PDG_DBG_PRINT_C("fei_mbul");
02721 PDG_DBG_PRINT_END
02722
02723 # ifdef _ENABLE_FEI
02724 fei_mbul();
02725 # endif
02726 break;
02727
02728
02729
02730
02731
02732
02733 case Mcbl_Opr :
02734 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02735 IR_FLD_L(ir_idx));
02736
02737 PDG_DBG_PRINT_START
02738 PDG_DBG_PRINT_C("fei_mbclr");
02739 PDG_DBG_PRINT_END
02740
02741 # ifdef _ENABLE_FEI
02742 fei_mbclr();
02743 # endif
02744
02745 break;
02746
02747
02748
02749
02750
02751
02752
02753
02754 case Real_Div_To_Int_Opr :
02755 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02756 IR_FLD_L(ir_idx));
02757
02758 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
02759 IR_FLD_R(ir_idx));
02760
02761 PDG_DBG_PRINT_START
02762 PDG_DBG_PRINT_C("fei_ridiv");
02763 PDG_DBG_PRINT_END
02764
02765 # ifdef _ENABLE_FEI
02766 fei_ridiv();
02767 # endif
02768
02769 break;
02770
02771
02772
02773
02774
02775
02776
02777
02778
02779
02780
02781 case Modulo_Opr :
02782 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02783 IR_FLD_L(ir_idx));
02784
02785 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
02786
02787 PDG_DBG_PRINT_START
02788 PDG_DBG_PRINT_C("fei_modulo");
02789 PDG_DBG_PRINT_END
02790
02791 # ifdef _ENABLE_FEI
02792 fei_modulo(basic);
02793 # endif
02794
02795 break;
02796
02797
02798
02799
02800
02801
02802
02803
02804 case Len_Trim_Opr :
02805 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02806 IR_FLD_L(ir_idx));
02807
02808 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
02809
02810 PDG_DBG_PRINT_START
02811 PDG_DBG_PRINT_C("fei_len_trim");
02812 PDG_DBG_PRINT_END
02813
02814 # ifdef _ENABLE_FEI
02815 fei_len_trim();
02816 # endif
02817
02818 break;
02819
02820
02821
02822
02823
02824
02825
02826 case Nearest_Opr :
02827 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02828 IR_FLD_L(ir_idx));
02829
02830 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
02831
02832 PDG_DBG_PRINT_START
02833 PDG_DBG_PRINT_C("fei_near");
02834 PDG_DBG_PRINT_END
02835
02836 # ifdef _ENABLE_FEI
02837 fei_near(basic);
02838 # endif
02839
02840 break;
02841
02842
02843
02844
02845
02846
02847 case Rrspacing_Opr :
02848 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02849 IR_FLD_L(ir_idx));
02850
02851 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
02852
02853 PDG_DBG_PRINT_START
02854 PDG_DBG_PRINT_C("fei_rrspace");
02855 PDG_DBG_PRINT_END
02856
02857 # ifdef _ENABLE_FEI
02858 fei_rrspace(basic);
02859 # endif
02860
02861 break;
02862
02863
02864
02865
02866
02867
02868 case Scale_Opr :
02869 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02870 IR_FLD_L(ir_idx));
02871
02872 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
02873
02874 PDG_DBG_PRINT_START
02875 PDG_DBG_PRINT_C("fei_scale");
02876 PDG_DBG_PRINT_END
02877
02878 # ifdef _ENABLE_FEI
02879 fei_scale(basic);
02880 # endif
02881
02882 break;
02883
02884
02885
02886
02887
02888
02889 case Scan_Opr :
02890 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02891 IR_FLD_L(ir_idx));
02892
02893 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
02894
02895 PDG_DBG_PRINT_START
02896 PDG_DBG_PRINT_C("fei_scan");
02897 PDG_DBG_PRINT_END
02898
02899 # ifdef _ENABLE_FEI
02900 fei_scan(basic);
02901 # endif
02902
02903 break;
02904
02905
02906
02907
02908
02909
02910
02911 case Set_Exponent_Opr :
02912 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02913 IR_FLD_L(ir_idx));
02914
02915 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
02916
02917 PDG_DBG_PRINT_START
02918 PDG_DBG_PRINT_C("fei_set_exponent");
02919 PDG_DBG_PRINT_END
02920
02921 # ifdef _ENABLE_FEI
02922 fei_set_exponent(basic);
02923 # endif
02924
02925 break;
02926
02927
02928
02929
02930
02931
02932
02933 case Verify_Opr :
02934 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02935 IR_FLD_L(ir_idx));
02936
02937 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
02938
02939 PDG_DBG_PRINT_START
02940 PDG_DBG_PRINT_C("fei_verify");
02941 PDG_DBG_PRINT_END
02942
02943 # ifdef _ENABLE_FEI
02944 fei_verify(basic);
02945 # endif
02946
02947 break;
02948
02949
02950
02951
02952
02953
02954
02955
02956
02957 case Spacing_Opr :
02958 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02959 IR_FLD_L(ir_idx));
02960
02961 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
02962
02963 PDG_DBG_PRINT_START
02964 PDG_DBG_PRINT_C("fei_space");
02965 PDG_DBG_PRINT_END
02966
02967 # ifdef _ENABLE_FEI
02968 fei_space(basic);
02969 # endif
02970
02971 break;
02972
02973
02974
02975
02976
02977
02978
02979
02980 case Ceiling_Opr :
02981 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
02982 IR_FLD_L(ir_idx));
02983
02984 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
02985
02986 PDG_DBG_PRINT_START
02987 PDG_DBG_PRINT_C("fei_ceiling");
02988 PDG_DBG_PRINT_END
02989
02990 # ifdef _ENABLE_FEI
02991 fei_ceiling(basic);
02992 # endif
02993
02994 break;
02995
02996
02997
02998
02999
03000
03001
03002 case Adjustl_Opr :
03003 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
03004 IR_FLD_L(ir_idx));
03005
03006 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
03007
03008 PDG_DBG_PRINT_START
03009 PDG_DBG_PRINT_C("fei_adjustl");
03010 PDG_DBG_PRINT_END
03011
03012 # ifdef _ENABLE_FEI
03013 fei_adjustl(basic);
03014 # endif
03015
03016 break;
03017
03018
03019
03020
03021
03022 case Adjustr_Opr :
03023 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
03024 IR_FLD_L(ir_idx));
03025
03026 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
03027
03028 PDG_DBG_PRINT_START
03029 PDG_DBG_PRINT_C("fei_adjustr");
03030 PDG_DBG_PRINT_END
03031
03032 # ifdef _ENABLE_FEI
03033 fei_adjustr(basic);
03034 # endif
03035
03036 break;
03037
03038
03039
03040
03041
03042
03043 case Exponent_Opr :
03044 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
03045 IR_FLD_L(ir_idx));
03046
03047 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
03048
03049 PDG_DBG_PRINT_START
03050 PDG_DBG_PRINT_C("fei_exponent");
03051 PDG_DBG_PRINT_END
03052
03053 # ifdef _ENABLE_FEI
03054 fei_exponent(basic);
03055 # endif
03056
03057 break;
03058
03059
03060
03061
03062
03063 case Fraction_Opr :
03064 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
03065 IR_FLD_L(ir_idx));
03066
03067 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
03068
03069 PDG_DBG_PRINT_START
03070 PDG_DBG_PRINT_C("fei_fraction");
03071 PDG_DBG_PRINT_END
03072
03073 # ifdef _ENABLE_FEI
03074 fei_fraction();
03075 # endif
03076
03077 break;
03078
03079
03080
03081
03082
03083
03084
03085
03086 #ifdef KEY
03087 case Cselect_Opr :
03088 #endif
03089 case Cvmgt_Opr :
03090 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
03091 IR_FLD_L(ir_idx));
03092
03093 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
03094
03095 PDG_DBG_PRINT_START
03096 PDG_DBG_PRINT_C("fei_select");
03097 PDG_DBG_PRINT_END
03098
03099 # ifdef _ENABLE_FEI
03100 #ifdef KEY
03101 fei_select(basic, Cselect_Opr == IR_OPR(ir_idx));
03102 #else
03103 fei_select(basic);
03104 #endif
03105 # endif
03106
03107 break;
03108
03109
03110
03111
03112
03113 case Csmg_Opr :
03114 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
03115 IR_FLD_L(ir_idx));
03116
03117 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
03118
03119 PDG_DBG_PRINT_START
03120 PDG_DBG_PRINT_C("fei_mbits");
03121 PDG_DBG_PRINT_END
03122
03123
03124 # ifdef _ENABLE_FEI
03125 fei_mbits(basic);
03126 # endif
03127
03128 break;
03129
03130
03131
03132
03133
03134
03135 case Rtc_Opr :
03136 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
03137
03138 PDG_DBG_PRINT_START
03139 PDG_DBG_PRINT_C("fei_rtc");
03140 PDG_DBG_PRINT_END
03141
03142 # ifdef _ENABLE_FEI
03143 fei_rtc(basic);
03144 # endif
03145
03146 break;
03147
03148
03149
03150
03151 case My_Pe_Opr :
03152 PDG_DBG_PRINT_START
03153 PDG_DBG_PRINT_C("fei_my_pe");
03154 PDG_DBG_PRINT_END
03155
03156 # ifdef _ENABLE_FEI
03157 fei_my_pe();
03158 # endif
03159
03160 break;
03161
03162
03163
03164
03165
03166 case Numarg_Opr :
03167 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
03168 IR_FLD_L(ir_idx));
03169
03170 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
03171
03172 PDG_DBG_PRINT_START
03173 PDG_DBG_PRINT_C("fei_numargs");
03174 PDG_DBG_PRINT_END
03175
03176 # ifdef _ENABLE_FEI
03177 fei_numargs(basic);
03178 # endif
03179
03180 break;
03181
03182
03183
03184
03185
03186
03187 # ifdef _HIGH_LEVEL_DO_LOOP_FORM
03188
03189 case Loop_Info_Opr :
03190 switch (SH_STMT_TYPE(curr_sh)) {
03191 case Do_Iterative_Stmt :
03192
03193
03194
03195 line = (IR_FLD_L(ir_idx) == SH_Tbl_Idx) ?
03196 SH_GLB_LINE(IR_IDX_L(ir_idx)) : 0;
03197
03198 if (IL_FLD(IR_IDX_R(ir_idx)) == IL_Tbl_Idx) {
03199 idx = IL_IDX(IR_IDX_R(ir_idx));
03200 }
03201 else {
03202 idx = IR_IDX_R(ir_idx);
03203 }
03204 cvrt_exp_to_pdg(IL_IDX(idx),
03205 IL_FLD(idx));
03206
03207 idx = IL_NEXT_LIST_IDX(idx);
03208 cvrt_exp_to_pdg(IL_IDX(idx),
03209 IL_FLD(idx));
03210
03211 idx = IL_NEXT_LIST_IDX(idx);
03212 cvrt_exp_to_pdg(IL_IDX(idx),
03213 IL_FLD(idx));
03214
03215 idx = IL_NEXT_LIST_IDX(idx);
03216 cvrt_exp_to_pdg(IL_IDX(idx),
03217 IL_FLD(idx));
03218
03219
03220 PDG_DBG_PRINT_START
03221 PDG_DBG_PRINT_C("fei_doloop");
03222 PDG_DBG_PRINT_D("(1) line", line);
03223 PDG_DBG_PRINT_END
03224
03225 # ifdef _ENABLE_FEI
03226 fei_doloop(line);
03227 # endif
03228 break;
03229
03230
03231 case Do_While_Stmt :
03232 idx = IR_IDX_R(ir_idx);
03233 cvrt_exp_to_pdg(IL_IDX(idx),
03234 IL_FLD(idx));
03235
03236 PDG_DBG_PRINT_START
03237 PDG_DBG_PRINT_C("fei_dowhile");
03238 PDG_DBG_PRINT_END
03239
03240 # ifdef _ENABLE_FEI
03241 fei_dowhile();
03242 # endif
03243 break;
03244
03245
03246 case Do_Infinite_Stmt :
03247 PDG_DBG_PRINT_START
03248 PDG_DBG_PRINT_C("fei_doforever");
03249 PDG_DBG_PRINT_END
03250
03251 # ifdef _ENABLE_FEI
03252 fei_doforever();
03253 # endif
03254 break;
03255
03256 }
03257 break;
03258
03259
03260
03261
03262 case Loop_End_Opr :
03263 PDG_DBG_PRINT_START
03264 PDG_DBG_PRINT_C("fei_enddo");
03265 PDG_DBG_PRINT_END
03266
03267 # ifdef _ENABLE_FEI
03268 fei_enddo();
03269 # endif
03270 break;
03271 # endif
03272
03273
03274
03275
03276
03277 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
03278 case Mvbits_Opr :
03279 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
03280 IR_FLD_L(ir_idx));
03281
03282 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
03283 IR_FLD_R(ir_idx));
03284
03285 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
03286
03287 PDG_DBG_PRINT_START
03288 PDG_DBG_PRINT_C("fei_mvbits");
03289 PDG_DBG_PRINT_END
03290
03291 # ifdef _ENABLE_FEI
03292 fei_mvbits(basic);
03293 # endif
03294
03295 break;
03296
03297
03298 case Ishftc_Opr :
03299 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
03300 IR_FLD_L(ir_idx));
03301
03302 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
03303
03304 PDG_DBG_PRINT_START
03305 PDG_DBG_PRINT_C("fei_ishftc");
03306 PDG_DBG_PRINT_END
03307
03308 # ifdef _ENABLE_FEI
03309 fei_ishftc(basic);
03310 # endif
03311
03312 break;
03313
03314
03315
03316 case Ibits_Opr :
03317 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
03318 IR_FLD_L(ir_idx));
03319
03320 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
03321
03322 PDG_DBG_PRINT_START
03323 PDG_DBG_PRINT_C("fei_ibits");
03324 PDG_DBG_PRINT_END
03325
03326 # ifdef _ENABLE_FEI
03327 fei_ibits(basic);
03328 # endif
03329
03330 break;
03331 # endif
03332
03333
03334
03335
03336 case Abs_Opr :
03337 case Paren_Opr :
03338 case Const_Tmp_Loc_Opr :
03339 case Loc_Opr :
03340 case Ieee_Finite_Opr :
03341 case Ieee_Is_Nan_Opr :
03342 case Ieee_Class_Opr :
03343 case Uplus_Opr :
03344 case Uminus_Opr :
03345 case Not_Opr :
03346 case Bnot_Opr :
03347 case Floor_Opr :
03348 case Clen_Opr :
03349 case Conjg_Opr :
03350 case Mask_Opr :
03351 case Int_Opr :
03352 case Logical_Opr :
03353 case Real_Opr :
03354 case Ichar_Opr :
03355 case Char_Opr :
03356 case Cvrt_Opr :
03357 case Cvrt_Unsigned_Opr :
03358 case Ranget_Opr :
03359 case Ranset_Opr :
03360 case Dim_Opr :
03361 case Aint_Opr :
03362 case Leadz_Opr :
03363 case Poppar_Opr :
03364 case Popcnt_Opr :
03365 case Nint_Opr :
03366 case Anint_Opr :
03367 case Sign_Opr :
03368 case Cot_Opr :
03369 case Exp_Opr :
03370 case Sqrt_Opr :
03371 case Acos_Opr :
03372 case Asin_Opr :
03373 case Atan_Opr :
03374 case Aimag_Opr :
03375 case Atan2_Opr :
03376 case Cosh_Opr :
03377 case Sinh_Opr :
03378 case Tanh_Opr :
03379 case Cos_Opr :
03380 case Sin_Opr :
03381 case Tan_Opr :
03382 case Log_E_Opr :
03383 case Log_10_Opr :
03384 case Cosd_Opr :
03385 case Sind_Opr :
03386 case Tand_Opr :
03387 case Acosd_Opr :
03388 case Asind_Opr :
03389 case Atand_Opr :
03390 case Atan2d_Opr :
03391
03392 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
03393 IR_FLD_L(ir_idx));
03394
03395 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
03396
03397 switch (IR_OPR(ir_idx)) {
03398 case Abs_Opr :
03399 PDG_DBG_PRINT_START
03400 PDG_DBG_PRINT_C("fei_abs");
03401 PDG_DBG_PRINT_END
03402 # ifdef _ENABLE_FEI
03403 fei_abs(basic);
03404 # endif
03405 break;
03406
03407 case Paren_Opr :
03408 PDG_DBG_PRINT_START
03409 PDG_DBG_PRINT_C("fei_paren");
03410 PDG_DBG_PRINT_END
03411 # ifdef _ENABLE_FEI
03412 fei_paren(basic);
03413 # endif
03414 break;
03415
03416 case Const_Tmp_Loc_Opr :
03417 PDG_DBG_PRINT_START
03418 PDG_DBG_PRINT_C("fei_addr_con");
03419 PDG_DBG_PRINT_END
03420 # ifdef _ENABLE_FEI
03421 fei_addr_con(basic);
03422 # endif
03423 break;
03424
03425 case Loc_Opr :
03426 PDG_DBG_PRINT_START
03427 PDG_DBG_PRINT_C("fei_addr");
03428 PDG_DBG_PRINT_END
03429 # ifdef _ENABLE_FEI
03430 fei_addr(basic);
03431 # endif
03432 break;
03433
03434 case Ieee_Finite_Opr :
03435 PDG_DBG_PRINT_START
03436 PDG_DBG_PRINT_C("fei_isfinite");
03437 PDG_DBG_PRINT_END
03438 # ifdef _ENABLE_FEI
03439 fei_isfinite(basic);
03440 # endif
03441 break;
03442
03443 case Ieee_Is_Nan_Opr :
03444 PDG_DBG_PRINT_START
03445 PDG_DBG_PRINT_C("fei_isnan");
03446 PDG_DBG_PRINT_END
03447 # ifdef _ENABLE_FEI
03448 fei_isnan(basic);
03449 # endif
03450 break;
03451
03452 case Ieee_Class_Opr :
03453 PDG_DBG_PRINT_START
03454 PDG_DBG_PRINT_C("fei_fpclass");
03455 PDG_DBG_PRINT_END
03456 # ifdef _ENABLE_FEI
03457 fei_fpclass(basic);
03458 # endif
03459 break;
03460
03461 case Uplus_Opr :
03462 break;
03463
03464 case Uminus_Opr :
03465 PDG_DBG_PRINT_START
03466 PDG_DBG_PRINT_C("fei_uminus");
03467 PDG_DBG_PRINT_END
03468 # ifdef _ENABLE_FEI
03469 fei_uminus(basic);
03470 # endif
03471 break;
03472
03473 case Not_Opr :
03474 PDG_DBG_PRINT_START
03475 PDG_DBG_PRINT_C("fei_lneg");
03476 PDG_DBG_PRINT_END
03477 # ifdef _ENABLE_FEI
03478 fei_lneg(basic);
03479 # endif
03480 break;
03481
03482 case Bnot_Opr :
03483 PDG_DBG_PRINT_START
03484 PDG_DBG_PRINT_C("fei_bneg");
03485 PDG_DBG_PRINT_END
03486 # ifdef _ENABLE_FEI
03487 fei_bneg(basic);
03488 # endif
03489 break;
03490
03491 case Floor_Opr :
03492 PDG_DBG_PRINT_START
03493 PDG_DBG_PRINT_C("fei_floor");
03494 PDG_DBG_PRINT_END
03495 # ifdef _ENABLE_FEI
03496 fei_floor(basic);
03497 # endif
03498 break;
03499
03500 case Clen_Opr :
03501 PDG_DBG_PRINT_START
03502 PDG_DBG_PRINT_C("fei_len");
03503 PDG_DBG_PRINT_END
03504 # ifdef _ENABLE_FEI
03505 fei_len(basic);
03506 # endif
03507 break;
03508
03509 case Conjg_Opr :
03510 PDG_DBG_PRINT_START
03511 PDG_DBG_PRINT_C("fei_conjg");
03512 PDG_DBG_PRINT_END
03513 # ifdef _ENABLE_FEI
03514 fei_conjg(basic);
03515 # endif
03516 break;
03517
03518 case Mask_Opr :
03519 PDG_DBG_PRINT_START
03520 PDG_DBG_PRINT_C("fei_mask");
03521 PDG_DBG_PRINT_END
03522 # ifdef _ENABLE_FEI
03523 fei_mask(basic);
03524 # endif
03525 break;
03526
03527 case Int_Opr :
03528 case Logical_Opr :
03529 case Real_Opr :
03530 case Ichar_Opr :
03531 case Char_Opr :
03532 case Cvrt_Opr :
03533 case Cvrt_Unsigned_Opr :
03534 PDG_DBG_PRINT_START
03535 PDG_DBG_PRINT_C("fei_cvtop");
03536 PDG_DBG_PRINT_END
03537 # ifdef _ENABLE_FEI
03538 fei_cvtop(basic);
03539 # endif
03540 break;
03541
03542 case Ranget_Opr :
03543 PDG_DBG_PRINT_START
03544 PDG_DBG_PRINT_C("fei_ranget");
03545 PDG_DBG_PRINT_END
03546 # ifdef _ENABLE_FEI
03547 fei_ranget(basic);
03548 # endif
03549 break;
03550
03551 case Ranset_Opr :
03552 PDG_DBG_PRINT_START
03553 PDG_DBG_PRINT_C("fei_ranset");
03554 PDG_DBG_PRINT_END
03555 # ifdef _ENABLE_FEI
03556 fei_ranset(basic);
03557 # endif
03558 break;
03559
03560 case Dim_Opr :
03561 PDG_DBG_PRINT_START
03562 PDG_DBG_PRINT_C("fei_pos_diff");
03563 PDG_DBG_PRINT_END
03564 # ifdef _ENABLE_FEI
03565 fei_pos_diff(basic);
03566 # endif
03567 break;
03568
03569 case Aint_Opr :
03570 PDG_DBG_PRINT_START
03571 PDG_DBG_PRINT_C("fei_trunc");
03572 PDG_DBG_PRINT_END
03573 # ifdef _ENABLE_FEI
03574 fei_trunc(basic);
03575 # endif
03576 break;
03577
03578 case Leadz_Opr :
03579 arg_type = null_type;
03580
03581 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
03582 if (IR_FLD_L(ir_idx) == IL_Tbl_Idx) {
03583 arg_idx = IR_IDX_L(ir_idx);
03584
03585 if (IL_FLD(arg_idx) == AT_Tbl_Idx) {
03586 if (AT_OBJ_CLASS(IL_IDX(arg_idx)) == Data_Obj) {
03587 arg_type = get_basic_type(ATD_TYPE_IDX(IL_IDX(arg_idx)),
03588 0,
03589 NULL_IDX);
03590 }
03591 }
03592 else if (IL_FLD(arg_idx) == CN_Tbl_Idx) {
03593 arg_type = get_basic_type(CN_TYPE_IDX(IL_IDX(arg_idx)),
03594 0,
03595 NULL_IDX);
03596 }
03597 else if (IL_FLD(arg_idx) == IR_Tbl_Idx) {
03598 arg_type = get_basic_type(IR_TYPE_IDX(IL_IDX(arg_idx)),
03599 0,
03600 NULL_IDX);
03601 }
03602 }
03603 # endif
03604
03605 PDG_DBG_PRINT_START
03606 PDG_DBG_PRINT_C("fei_leadz");
03607 PDG_DBG_PRINT_END
03608 # ifdef _ENABLE_FEI
03609 fei_leadz(basic, arg_type);
03610 # endif
03611 break;
03612
03613 case Poppar_Opr :
03614 arg_type = null_type;
03615
03616 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
03617 if (IR_FLD_L(ir_idx) == IL_Tbl_Idx) {
03618 arg_idx = IR_IDX_L(ir_idx);
03619
03620 if (IL_FLD(arg_idx) == AT_Tbl_Idx) {
03621 if (AT_OBJ_CLASS(IL_IDX(arg_idx)) == Data_Obj) {
03622 arg_type = get_basic_type(ATD_TYPE_IDX(IL_IDX(arg_idx)),
03623 0,
03624 NULL_IDX);
03625 }
03626 }
03627 else if (IL_FLD(arg_idx) == CN_Tbl_Idx) {
03628 arg_type = get_basic_type(CN_TYPE_IDX(IL_IDX(arg_idx)),
03629 0,
03630 NULL_IDX);
03631 }
03632 else if (IL_FLD(arg_idx) == IR_Tbl_Idx) {
03633 arg_type = get_basic_type(IR_TYPE_IDX(IL_IDX(arg_idx)),
03634 0,
03635 NULL_IDX);
03636 }
03637 }
03638 # endif
03639
03640 PDG_DBG_PRINT_START
03641 PDG_DBG_PRINT_C("fei_poppar");
03642 PDG_DBG_PRINT_END
03643 # ifdef _ENABLE_FEI
03644 fei_poppar(basic, arg_type);
03645 # endif
03646 break;
03647
03648 case Popcnt_Opr :
03649 arg_type = null_type;
03650
03651 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
03652 if (IR_FLD_L(ir_idx) == IL_Tbl_Idx) {
03653 arg_idx = IR_IDX_L(ir_idx);
03654
03655 if (IL_FLD(arg_idx) == AT_Tbl_Idx) {
03656 if (AT_OBJ_CLASS(IL_IDX(arg_idx)) == Data_Obj) {
03657 arg_type = get_basic_type(ATD_TYPE_IDX(IL_IDX(arg_idx)),
03658 0,
03659 NULL_IDX);
03660 }
03661 }
03662 else if (IL_FLD(arg_idx) == CN_Tbl_Idx) {
03663 arg_type = get_basic_type(CN_TYPE_IDX(IL_IDX(arg_idx)),
03664 0,
03665 NULL_IDX);
03666 }
03667 else if (IL_FLD(arg_idx) == IR_Tbl_Idx) {
03668 arg_type = get_basic_type(IR_TYPE_IDX(IL_IDX(arg_idx)),
03669 0,
03670 NULL_IDX);
03671 }
03672 }
03673 # endif
03674
03675 PDG_DBG_PRINT_START
03676 PDG_DBG_PRINT_C("fei_popcnt");
03677 PDG_DBG_PRINT_END
03678 # ifdef _ENABLE_FEI
03679 fei_popcnt(basic, arg_type);
03680 # endif
03681 break;
03682
03683 case Nint_Opr :
03684 case Anint_Opr :
03685 PDG_DBG_PRINT_START
03686 PDG_DBG_PRINT_C("fei_round");
03687 PDG_DBG_PRINT_END
03688 # ifdef _ENABLE_FEI
03689 fei_round(basic);
03690 # endif
03691 break;
03692
03693 case Sign_Opr :
03694 PDG_DBG_PRINT_START
03695 PDG_DBG_PRINT_C("fei_sign_xfer");
03696 PDG_DBG_PRINT_END
03697 # ifdef _ENABLE_FEI
03698 fei_sign_xfer(basic);
03699 # endif
03700 break;
03701
03702 case Cot_Opr :
03703 PDG_DBG_PRINT_START
03704 PDG_DBG_PRINT_C("fei_cot");
03705 PDG_DBG_PRINT_END
03706 # ifdef _ENABLE_FEI
03707 fei_cot(basic);
03708 # endif
03709 break;
03710
03711 case Exp_Opr :
03712 PDG_DBG_PRINT_START
03713 PDG_DBG_PRINT_C("fei_exp");
03714 PDG_DBG_PRINT_END
03715 # ifdef _ENABLE_FEI
03716 fei_exp(basic);
03717 # endif
03718 break;
03719
03720 case Sqrt_Opr :
03721 PDG_DBG_PRINT_START
03722 PDG_DBG_PRINT_C("fei_sqrt");
03723 PDG_DBG_PRINT_END
03724 # ifdef _ENABLE_FEI
03725 fei_sqrt(basic);
03726 # endif
03727 break;
03728
03729 case Acos_Opr :
03730 PDG_DBG_PRINT_START
03731 PDG_DBG_PRINT_C("fei_acos");
03732 PDG_DBG_PRINT_END
03733 # ifdef _ENABLE_FEI
03734 fei_acos(basic);
03735 # endif
03736 break;
03737
03738 case Asin_Opr :
03739 PDG_DBG_PRINT_START
03740 PDG_DBG_PRINT_C("fei_asin");
03741 PDG_DBG_PRINT_END
03742 # ifdef _ENABLE_FEI
03743 fei_asin(basic);
03744 # endif
03745 break;
03746
03747 case Atan_Opr :
03748 PDG_DBG_PRINT_START
03749 PDG_DBG_PRINT_C("fei_atan");
03750 PDG_DBG_PRINT_END
03751 # ifdef _ENABLE_FEI
03752 fei_atan(basic);
03753 # endif
03754 break;
03755
03756 case Aimag_Opr :
03757 PDG_DBG_PRINT_START
03758 PDG_DBG_PRINT_C("fei_imag");
03759 PDG_DBG_PRINT_END
03760 # ifdef _ENABLE_FEI
03761 fei_imag(basic);
03762 # endif
03763 break;
03764
03765 case Atan2_Opr :
03766 PDG_DBG_PRINT_START
03767 PDG_DBG_PRINT_C("fei_atan2");
03768 PDG_DBG_PRINT_END
03769 # ifdef _ENABLE_FEI
03770 fei_atan2(basic);
03771 # endif
03772 break;
03773
03774 case Cosh_Opr :
03775 PDG_DBG_PRINT_START
03776 PDG_DBG_PRINT_C("fei_cosh");
03777 PDG_DBG_PRINT_END
03778 # ifdef _ENABLE_FEI
03779 fei_cosh(basic);
03780 # endif
03781 break;
03782
03783 case Sinh_Opr :
03784 PDG_DBG_PRINT_START
03785 PDG_DBG_PRINT_C("fei_sinh");
03786 PDG_DBG_PRINT_END
03787 # ifdef _ENABLE_FEI
03788 fei_sinh(basic);
03789 # endif
03790 break;
03791
03792 case Tanh_Opr :
03793 PDG_DBG_PRINT_START
03794 PDG_DBG_PRINT_C("fei_tanh");
03795 PDG_DBG_PRINT_END
03796 # ifdef _ENABLE_FEI
03797 fei_tanh(basic);
03798 # endif
03799 break;
03800
03801 case Cos_Opr :
03802 PDG_DBG_PRINT_START
03803 PDG_DBG_PRINT_C("fei_cos");
03804 PDG_DBG_PRINT_END
03805 # ifdef _ENABLE_FEI
03806 fei_cos(basic);
03807 # endif
03808 break;
03809
03810 case Sin_Opr :
03811 PDG_DBG_PRINT_START
03812 PDG_DBG_PRINT_C("fei_sin");
03813 PDG_DBG_PRINT_END
03814 # ifdef _ENABLE_FEI
03815 fei_sin(basic);
03816 # endif
03817 break;
03818
03819 case Tan_Opr :
03820 PDG_DBG_PRINT_START
03821 PDG_DBG_PRINT_C("fei_tan");
03822 PDG_DBG_PRINT_END
03823 # ifdef _ENABLE_FEI
03824 fei_tan(basic);
03825 # endif
03826 break;
03827
03828 case Log_E_Opr :
03829 PDG_DBG_PRINT_START
03830 PDG_DBG_PRINT_C("fei_log");
03831 PDG_DBG_PRINT_END
03832 # ifdef _ENABLE_FEI
03833 fei_log(basic);
03834 # endif
03835 break;
03836
03837 case Log_10_Opr :
03838 PDG_DBG_PRINT_START
03839 PDG_DBG_PRINT_C("fei_log10");
03840 PDG_DBG_PRINT_END
03841 # ifdef _ENABLE_FEI
03842 fei_log10(basic);
03843 # endif
03844 break;
03845
03846 case Cosd_Opr :
03847 PDG_DBG_PRINT_START
03848 PDG_DBG_PRINT_C("fei_cosd");
03849 PDG_DBG_PRINT_END
03850 # ifdef _ENABLE_FEI
03851 fei_cosd(basic);
03852 # endif
03853 break;
03854
03855 case Sind_Opr :
03856 PDG_DBG_PRINT_START
03857 PDG_DBG_PRINT_C("fei_sind");
03858 PDG_DBG_PRINT_END
03859 # ifdef _ENABLE_FEI
03860 fei_sind(basic);
03861 # endif
03862 break;
03863
03864 case Tand_Opr :
03865 PDG_DBG_PRINT_START
03866 PDG_DBG_PRINT_C("fei_tand");
03867 PDG_DBG_PRINT_END
03868 # ifdef _ENABLE_FEI
03869 fei_tand(basic);
03870 # endif
03871 break;
03872
03873 case Acosd_Opr :
03874 PDG_DBG_PRINT_START
03875 PDG_DBG_PRINT_C("fei_acosd");
03876 PDG_DBG_PRINT_END
03877 # ifdef _ENABLE_FEI
03878 fei_acosd(basic);
03879 # endif
03880 break;
03881
03882 case Asind_Opr :
03883 PDG_DBG_PRINT_START
03884 PDG_DBG_PRINT_C("fei_asind");
03885 PDG_DBG_PRINT_END
03886 # ifdef _ENABLE_FEI
03887 fei_asind(basic);
03888 # endif
03889 break;
03890
03891 case Atand_Opr :
03892 PDG_DBG_PRINT_START
03893 PDG_DBG_PRINT_C("fei_atand");
03894 PDG_DBG_PRINT_END
03895 # ifdef _ENABLE_FEI
03896 fei_atand(basic);
03897 # endif
03898 break;
03899
03900 case Atan2d_Opr :
03901 PDG_DBG_PRINT_START
03902 PDG_DBG_PRINT_C("fei_atan2d");
03903 PDG_DBG_PRINT_END
03904 # ifdef _ENABLE_FEI
03905 fei_atan2d(basic);
03906 # endif
03907 break;
03908 }
03909 break;
03910
03911
03912
03913 #ifdef KEY
03914 case Erf_Opr :
03915 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
03916 IR_FLD_L(ir_idx));
03917 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
03918 PDG_DBG_PRINT_START
03919 PDG_DBG_PRINT_C("fei_erf");
03920 PDG_DBG_PRINT_END
03921 # ifdef _ENABLE_FEI
03922 fei_erf(basic, 0);
03923 # endif
03924 break;
03925
03926 case Erfc_Opr :
03927 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
03928 IR_FLD_L(ir_idx));
03929 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
03930 PDG_DBG_PRINT_START
03931 PDG_DBG_PRINT_C("fei_erfc");
03932 PDG_DBG_PRINT_END
03933 # ifdef _ENABLE_FEI
03934 fei_erf(basic, 1);
03935 # endif
03936 break;
03937 #endif
03938
03939
03940
03941
03942
03943
03944 case Alt_Return_Opr :
03945 case Asg_Opr :
03946 case Dv_Whole_Copy_Opr :
03947 case Dv_Def_Asg_Opr :
03948 if ((IR_FLD_L(ir_idx) == AT_Tbl_Idx) &&
03949 (AT_OBJ_CLASS(IR_IDX_L(ir_idx)) == Label)) {
03950
03951 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
03952 IR_FLD_R(ir_idx));
03953
03954 PDG_DBG_PRINT_START
03955 PDG_DBG_PRINT_C("fei_label_addr");
03956 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX", PDG_AT_IDX(IR_IDX_L(ir_idx)));
03957 PDG_DBG_PRINT_END
03958
03959 # ifdef _ENABLE_FEI
03960 fei_label_addr(PDG_AT_IDX(IR_IDX_L(ir_idx)));
03961 # endif
03962 }
03963 else {
03964 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
03965 IR_FLD_L(ir_idx));
03966
03967 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
03968 IR_FLD_R(ir_idx));
03969 }
03970
03971 PDG_DBG_PRINT_START
03972 PDG_DBG_PRINT_C("fei_store");
03973 PDG_DBG_PRINT_END
03974
03975 # ifdef _ENABLE_FEI
03976 fei_store(pdg_type_void);
03977 # endif
03978 break;
03979
03980
03981
03982
03983
03984 case Flat_Array_Asg_Opr :
03985 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
03986 IR_FLD_L(ir_idx));
03987
03988 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
03989 IR_FLD_R(ir_idx));
03990
03991 PDG_DBG_PRINT_START
03992 PDG_DBG_PRINT_C("fei_non_conform_store");
03993 PDG_DBG_PRINT_END
03994
03995 # ifdef _ENABLE_FEI
03996 fei_non_conform_store(pdg_type_void);
03997 # endif
03998 break;
03999
04000
04001 # ifdef _SAVE_IO_STMT
04002 case Start_Io_Opr :
04003 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
04004 IR_FLD_L(ir_idx));
04005
04006 PDG_DBG_PRINT_START
04007 PDG_DBG_PRINT_C("fei_start_ioblock");
04008 PDG_DBG_PRINT_END
04009
04010 # ifdef _ENABLE_FEI
04011 fei_start_ioblock();
04012 # endif
04013 break;
04014
04015
04016
04017 case End_Io_Opr :
04018 PDG_DBG_PRINT_START
04019 PDG_DBG_PRINT_C("fei_end_ioblock");
04020 PDG_DBG_PRINT_END
04021
04022 # ifdef _ENABLE_FEI
04023 fei_end_ioblock();
04024 # endif
04025 break;
04026 # endif
04027
04028
04029
04030
04031 case Readsm_Opr :
04032 PDG_DBG_PRINT_START
04033 PDG_DBG_PRINT_C("fei_readsm");
04034 PDG_DBG_PRINT_END
04035
04036 # ifdef _ENABLE_FEI
04037 fei_readsm();
04038 # endif
04039 break;
04040
04041
04042
04043 case Read_Unformatted_Opr :
04044 io_type = READ_STMT;
04045
04046 processing_call = processing_call + 1;
04047 processing_io_stmt = TRUE;
04048 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
04049 IR_FLD_L(ir_idx));
04050
04051 PDG_DBG_PRINT_START
04052 PDG_DBG_PRINT_C("fei_control_list");
04053 PDG_DBG_PRINT_S("(1) io_type", p_io[io_type]);
04054 PDG_DBG_PRINT_END
04055
04056 # ifdef _ENABLE_FEI
04057 fei_control_list(io_type);
04058 # endif
04059
04060 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
04061 IR_FLD_R(ir_idx));
04062
04063 if (IR_IDX_R(ir_idx) != NULL_IDX) {
04064 list_cnt = IR_LIST_CNT_R(ir_idx);
04065
04066 PDG_DBG_PRINT_START
04067 PDG_DBG_PRINT_C("fei_IO_list");
04068 PDG_DBG_PRINT_D("(1) list_cnt", list_cnt);
04069 PDG_DBG_PRINT_S("(2) io_type", p_io[io_type]);
04070 PDG_DBG_PRINT_END
04071
04072 # ifdef _ENABLE_FEI
04073 fei_IO_list(list_cnt, io_type);
04074 # endif
04075 }
04076
04077 PDG_DBG_PRINT_START
04078 PDG_DBG_PRINT_C("fei_unformatted_read");
04079 PDG_DBG_PRINT_END
04080
04081 # ifdef _ENABLE_FEI
04082 fei_unformatted_read();
04083 # endif
04084
04085 processing_io_stmt = FALSE;
04086 processing_call = processing_call - 1;
04087 break;
04088
04089
04090
04091
04092
04093 case Backspace_Opr:
04094 # if defined(_FILE_IO_OPRS)
04095 processing_call = processing_call + 1;
04096 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
04097 IR_FLD_L(ir_idx));
04098
04099 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
04100 IR_FLD_R(ir_idx));
04101
04102 PDG_DBG_PRINT_START
04103 PDG_DBG_PRINT_C("fei_backspace");
04104 PDG_DBG_PRINT_END
04105
04106 fei_backspace();
04107 processing_call = processing_call - 1;
04108 # endif
04109 break;
04110
04111
04112
04113
04114 case Close_Opr:
04115 # if defined(_FILE_IO_OPRS)
04116 processing_call = processing_call + 1;
04117 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
04118 IR_FLD_L(ir_idx));
04119
04120 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
04121 IR_FLD_R(ir_idx));
04122
04123 PDG_DBG_PRINT_START
04124 PDG_DBG_PRINT_C("fei_close");
04125 PDG_DBG_PRINT_END
04126
04127 fei_close();
04128 processing_call = processing_call - 1;
04129 # endif
04130 break;
04131
04132
04133
04134
04135
04136 case Endfile_Opr:
04137 # if defined(_FILE_IO_OPRS)
04138 processing_call = processing_call + 1;
04139 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
04140 IR_FLD_L(ir_idx));
04141
04142 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
04143 IR_FLD_R(ir_idx));
04144
04145 PDG_DBG_PRINT_START
04146 PDG_DBG_PRINT_C("fei_endfile");
04147 PDG_DBG_PRINT_END
04148
04149 fei_endfile();
04150 processing_call = processing_call - 1;
04151 # endif
04152 break;
04153
04154
04155
04156
04157
04158 case Inquire_Opr:
04159 # if defined(_FILE_IO_OPRS)
04160 processing_call = processing_call + 1;
04161 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
04162 IR_FLD_L(ir_idx));
04163
04164 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
04165 IR_FLD_R(ir_idx));
04166
04167 PDG_DBG_PRINT_START
04168 PDG_DBG_PRINT_C("fei_inquire");
04169 PDG_DBG_PRINT_END
04170
04171 fei_inquire();
04172 processing_call = processing_call - 1;
04173 # endif
04174 break;
04175
04176
04177
04178
04179
04180 case Open_Opr:
04181 # if defined(_FILE_IO_OPRS)
04182 processing_call = processing_call + 1;
04183 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
04184 IR_FLD_L(ir_idx));
04185
04186 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
04187 IR_FLD_R(ir_idx));
04188
04189 PDG_DBG_PRINT_START
04190 PDG_DBG_PRINT_C("fei_open");
04191 PDG_DBG_PRINT_END
04192
04193 fei_open();
04194 processing_call = processing_call - 1;
04195 # endif
04196 break;
04197
04198
04199
04200
04201 case Rewind_Opr:
04202 # if defined(_FILE_IO_OPRS)
04203 processing_call = processing_call + 1;
04204 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
04205 IR_FLD_L(ir_idx));
04206
04207 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
04208 IR_FLD_R(ir_idx));
04209
04210 PDG_DBG_PRINT_START
04211 PDG_DBG_PRINT_C("fei_rewind");
04212 PDG_DBG_PRINT_END
04213
04214 fei_rewind();
04215 processing_call = processing_call - 1;
04216 # endif
04217 break;
04218
04219
04220 case Io_Item_Type_Code_Opr:
04221 make_io_type_code(IR_TYPE_IDX(ir_idx), loc_value);
04222 basic = get_basic_type(IO_TYPE_CODE_TYPE,
04223 type_alignment_tbl[IO_TYPE_CODE_TYPE],
04224 NULL_IDX);
04225
04226 PDG_DBG_PRINT_START
04227 PDG_DBG_PRINT_C("fei_arith_con");
04228 PDG_DBG_PRINT_T("(1) type", basic);
04229 #if defined(_HOST32) && defined(_TARGET64)
04230 PDG_DBG_PRINT_VD("(2) value", loc_value[0]);
04231 #else
04232 PDG_DBG_PRINT_LVD("(2) value", loc_value[0]);
04233 #endif
04234 PDG_DBG_PRINT_END
04235
04236 # ifdef _ENABLE_FEI
04237 pdg_cn_idx = fei_arith_con(basic, (long *)loc_value);
04238 # endif
04239 PDG_DBG_PRINT_START
04240 PDG_DBG_PRINT_LD("(r) PDG_CN_IDX", pdg_cn_idx);
04241 PDG_DBG_PRINT_END
04242
04243 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
04244 IR_FLD_L(ir_idx));
04245
04246
04247 PDG_DBG_PRINT_START
04248 PDG_DBG_PRINT_C("fei_push_arith_con");
04249 PDG_DBG_PRINT_LD("(1) PDG_CN_IDX", pdg_cn_idx);
04250 PDG_DBG_PRINT_END
04251
04252 # ifdef _ENABLE_FEI
04253 fei_push_arith_con(pdg_cn_idx);
04254 # endif
04255
04256 PDG_DBG_PRINT_START
04257 PDG_DBG_PRINT_C("fei_iotype");
04258 PDG_DBG_PRINT_END
04259
04260 # ifdef _ENABLE_FEI
04261 fei_iotype();
04262 # endif
04263 break;
04264
04265
04266
04267 case Write_Unformatted_Opr :
04268 io_type = WRITE_STMT;
04269 processing_call = processing_call + 1;
04270 processing_io_stmt = TRUE;
04271 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
04272 IR_FLD_L(ir_idx));
04273
04274 PDG_DBG_PRINT_START
04275 PDG_DBG_PRINT_C("fei_control_list");
04276 PDG_DBG_PRINT_S("(1) io_type", p_io[io_type]);
04277 PDG_DBG_PRINT_END
04278
04279 # ifdef _ENABLE_FEI
04280 fei_control_list(io_type);
04281 # endif
04282
04283
04284 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
04285 IR_FLD_R(ir_idx));
04286
04287 if (IR_IDX_R(ir_idx) != NULL_IDX) {
04288 list_cnt = IR_LIST_CNT_R(ir_idx);
04289
04290 PDG_DBG_PRINT_START
04291 PDG_DBG_PRINT_C("fei_IO_list");
04292 PDG_DBG_PRINT_D("(1) list_cnt", list_cnt);
04293 PDG_DBG_PRINT_S("(2) io_type", p_io[io_type]);
04294 PDG_DBG_PRINT_END
04295
04296 # ifdef _ENABLE_FEI
04297 fei_IO_list(list_cnt, io_type);
04298 # endif
04299 }
04300
04301 PDG_DBG_PRINT_START
04302 PDG_DBG_PRINT_C("fei_unformatted_write");
04303 PDG_DBG_PRINT_END
04304
04305 # ifdef _ENABLE_FEI
04306 fei_unformatted_write();
04307 # endif
04308
04309 processing_io_stmt = FALSE;
04310 processing_call = processing_call - 1;
04311 break;
04312
04313
04314
04315
04316 case Read_Namelist_Opr :
04317 io_type = READ_NML_STMT;
04318
04319 # if !(defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
04320
04321 list_idx1 = IR_IDX_L(ir_idx);
04322 for (i = 0; i < 7; i++) {
04323 list_idx1 = IL_NEXT_LIST_IDX(list_idx1);
04324 }
04325
04326 IL_FLD(list_idx1) = NO_Tbl_Idx;
04327 IL_IDX(list_idx1) = NULL_IDX;
04328 # endif
04329
04330 processing_call = processing_call + 1;
04331 processing_io_stmt = TRUE;
04332 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
04333 IR_FLD_L(ir_idx));
04334
04335 PDG_DBG_PRINT_START
04336 PDG_DBG_PRINT_C("fei_control_list");
04337 PDG_DBG_PRINT_S("(1) io_type", p_io[io_type]);
04338 PDG_DBG_PRINT_END
04339
04340 # ifdef _ENABLE_FEI
04341 fei_control_list(io_type);
04342 # endif
04343
04344 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
04345 IR_FLD_R(ir_idx));
04346
04347 if (IR_IDX_R(ir_idx) != NULL_IDX) {
04348 list_cnt = IR_LIST_CNT_R(ir_idx);
04349
04350 PDG_DBG_PRINT_START
04351 PDG_DBG_PRINT_C("fei_IO_list");
04352 PDG_DBG_PRINT_D("(1) list_cnt", list_cnt);
04353 PDG_DBG_PRINT_S("(2) io_type", p_io[io_type]);
04354 PDG_DBG_PRINT_END
04355
04356 # ifdef _ENABLE_FEI
04357 fei_IO_list(list_cnt, io_type);
04358 # endif
04359 }
04360
04361 PDG_DBG_PRINT_START
04362 PDG_DBG_PRINT_C("fei_namelist_read");
04363 PDG_DBG_PRINT_END
04364
04365 # ifdef _ENABLE_FEI
04366 fei_namelist_read();
04367 # endif
04368
04369 processing_io_stmt = FALSE;
04370 processing_call = processing_call - 1;
04371 break;
04372
04373
04374
04375
04376
04377
04378 case Write_Namelist_Opr :
04379 io_type = WRITE_NML_STMT;
04380
04381 # if !(defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
04382
04383 list_idx1 = IR_IDX_L(ir_idx);
04384 for (i = 0; i < 7; i++) {
04385 list_idx1 = IL_NEXT_LIST_IDX(list_idx1);
04386 }
04387
04388 IL_FLD(list_idx1) = NO_Tbl_Idx;
04389 IL_IDX(list_idx1) = NULL_IDX;
04390 # endif
04391
04392 processing_call = processing_call + 1;
04393 processing_io_stmt = TRUE;
04394 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
04395 IR_FLD_L(ir_idx));
04396
04397 PDG_DBG_PRINT_START
04398 PDG_DBG_PRINT_C("fei_control_list");
04399 PDG_DBG_PRINT_S("(1) io_type", p_io[io_type]);
04400 PDG_DBG_PRINT_END
04401
04402 # ifdef _ENABLE_FEI
04403 fei_control_list(io_type);
04404 # endif
04405
04406 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
04407 IR_FLD_R(ir_idx));
04408
04409 if (IR_IDX_R(ir_idx) != NULL_IDX) {
04410 list_cnt = IR_LIST_CNT_R(ir_idx);
04411
04412 PDG_DBG_PRINT_START
04413 PDG_DBG_PRINT_C("fei_IO_list");
04414 PDG_DBG_PRINT_D("(1) list count", list_cnt);
04415 PDG_DBG_PRINT_S("(2) io_type", p_io[io_type]);
04416 PDG_DBG_PRINT_END
04417
04418 # ifdef _ENABLE_FEI
04419 fei_IO_list(list_cnt, io_type);
04420 # endif
04421 }
04422
04423 PDG_DBG_PRINT_START
04424 PDG_DBG_PRINT_C("fei_namelist_write");
04425 PDG_DBG_PRINT_END
04426
04427 # ifdef _ENABLE_FEI
04428 fei_namelist_write();
04429 # endif
04430
04431 processing_io_stmt = FALSE;
04432 processing_call = processing_call - 1;
04433 break;
04434
04435
04436
04437
04438
04439 case Read_Formatted_Opr :
04440 io_type = READ_STMT;
04441 processing_call = processing_call + 1;
04442 processing_io_stmt = TRUE;
04443 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
04444 IR_FLD_L(ir_idx));
04445
04446 PDG_DBG_PRINT_START
04447 PDG_DBG_PRINT_C("fei_control_list");
04448 PDG_DBG_PRINT_S("(1) io_type", p_io[io_type]);
04449 PDG_DBG_PRINT_END
04450
04451 # ifdef _ENABLE_FEI
04452 fei_control_list(io_type);
04453 # endif
04454
04455 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
04456 IR_FLD_R(ir_idx));
04457
04458 if (IR_IDX_R(ir_idx) != NULL_IDX) {
04459 list_cnt = IR_LIST_CNT_R(ir_idx);
04460
04461 PDG_DBG_PRINT_START
04462 PDG_DBG_PRINT_C("fei_IO_list");
04463 PDG_DBG_PRINT_D("(1) list_cnt", list_cnt);
04464 PDG_DBG_PRINT_S("(2) io_type", p_io[io_type]);
04465 PDG_DBG_PRINT_END
04466
04467 # ifdef _ENABLE_FEI
04468 fei_IO_list(list_cnt, io_type);
04469 # endif
04470 }
04471
04472 PDG_DBG_PRINT_START
04473 PDG_DBG_PRINT_C("fei_formatted_read");
04474 PDG_DBG_PRINT_END
04475
04476 # ifdef _ENABLE_FEI
04477 fei_formatted_read();
04478 # endif
04479
04480 processing_io_stmt = FALSE;
04481 processing_call = processing_call - 1;
04482 break;
04483
04484
04485
04486
04487
04488
04489 case Write_Formatted_Opr :
04490 io_type = WRITE_STMT;
04491 processing_call = processing_call + 1;
04492 processing_io_stmt = TRUE;
04493 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
04494 IR_FLD_L(ir_idx));
04495
04496 PDG_DBG_PRINT_START
04497 PDG_DBG_PRINT_C("fei_control_list");
04498 PDG_DBG_PRINT_S("(1) io_type", p_io[io_type]);
04499 PDG_DBG_PRINT_END
04500
04501 # ifdef _ENABLE_FEI
04502 fei_control_list(io_type);
04503 # endif
04504
04505 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
04506 IR_FLD_R(ir_idx));
04507
04508 if (IR_IDX_R(ir_idx) != NULL_IDX) {
04509 list_cnt = IR_LIST_CNT_R(ir_idx);
04510
04511 PDG_DBG_PRINT_START
04512 PDG_DBG_PRINT_C("fei_IO_list");
04513 PDG_DBG_PRINT_D("(1) list_cnt", list_cnt);
04514 PDG_DBG_PRINT_S("(2) io_type", p_io[io_type]);
04515 PDG_DBG_PRINT_END
04516
04517 # ifdef _ENABLE_FEI
04518 fei_IO_list(list_cnt, io_type);
04519 # endif
04520 }
04521
04522 PDG_DBG_PRINT_START
04523 PDG_DBG_PRINT_C("fei_formatted_write");
04524 PDG_DBG_PRINT_END
04525
04526 # ifdef _ENABLE_FEI
04527 fei_formatted_write();
04528 # endif
04529
04530 processing_io_stmt = FALSE;
04531 processing_call = processing_call - 1;
04532 break;
04533
04534
04535
04536
04537
04538 case Inquire_Iolength_Opr:
04539 io_type = WRITE_STMT;
04540 processing_call = processing_call + 1;
04541 processing_io_stmt = TRUE;
04542 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
04543 IR_FLD_L(ir_idx));
04544
04545 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
04546 IR_FLD_R(ir_idx));
04547
04548 if (IR_IDX_R(ir_idx) != NULL_IDX) {
04549 list_cnt = IR_LIST_CNT_R(ir_idx);
04550
04551 PDG_DBG_PRINT_START
04552 PDG_DBG_PRINT_C("fei_IO_list");
04553 PDG_DBG_PRINT_D("(1) list_cnt", list_cnt);
04554 PDG_DBG_PRINT_S("(2) io_type", p_io[io_type]);
04555 PDG_DBG_PRINT_END
04556
04557 # ifdef _ENABLE_FEI
04558 fei_IO_list(list_cnt, io_type);
04559 # endif
04560 }
04561
04562 PDG_DBG_PRINT_START
04563 PDG_DBG_PRINT_C("fei_iolength");
04564 PDG_DBG_PRINT_END
04565
04566 # ifdef _ENABLE_FEI
04567 fei_iolength();
04568 # endif
04569
04570 processing_io_stmt = FALSE;
04571 processing_call = processing_call - 1;
04572 break;
04573
04574
04575
04576
04577
04578
04579
04580
04581
04582
04583
04584
04585 case Fcd_Opr :
04586 case Int_Mult_Upper_Opr :
04587 case Ieee_Unordered_Opr :
04588 case Ieee_Remainder_Opr :
04589 case Ieee_Real_Opr :
04590 case Ieee_Int_Opr :
04591 case Ieee_Copy_Sign_Opr :
04592 case Ieee_Exponent_Opr :
04593 case Ieee_Next_After_Opr :
04594 case Ieee_Binary_Scale_Opr :
04595 case Mod_Opr :
04596 case Eq_Opr :
04597 case Ne_Opr :
04598 case Lg_Opr :
04599 case Lt_Opr :
04600 case Llt_Opr :
04601 case Le_Opr :
04602 case Lle_Opr :
04603 case Gt_Opr :
04604 case Lgt_Opr :
04605 case Ge_Opr :
04606 case Lge_Opr :
04607 case And_Opr :
04608 case Band_Opr :
04609 case Or_Opr :
04610 case Bor_Opr :
04611 case Eqv_Opr :
04612 case Neqv_Opr :
04613 case Bneqv_Opr :
04614 case Beqv_Opr :
04615 case Plus_Opr :
04616 case Minus_Opr :
04617 case Div_Opr :
04618 case Mult_Opr :
04619 case Dprod_Opr :
04620 case Power_Opr :
04621 case Shifta_Opr :
04622 case Shiftr_Opr :
04623 case Shiftl_Opr :
04624 case Shift_Opr :
04625 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
04626 IR_FLD_L(ir_idx));
04627
04628 if (IR_FLD_R(ir_idx) != NO_Tbl_Idx) {
04629 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
04630 IR_FLD_R(ir_idx));
04631 }
04632
04633 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
04634
04635 switch (IR_OPR(ir_idx)) {
04636 case Fcd_Opr :
04637 PDG_DBG_PRINT_START
04638 PDG_DBG_PRINT_C("fei_fcd");
04639 PDG_DBG_PRINT_END
04640 # ifdef _ENABLE_FEI
04641 fei_fcd(basic);
04642 # endif
04643 break;
04644
04645 case Int_Mult_Upper_Opr :
04646 PDG_DBG_PRINT_START
04647 PDG_DBG_PRINT_C("fei_multiply_high");
04648 PDG_DBG_PRINT_END
04649 # ifdef _ENABLE_FEI
04650 fei_multiply_high(basic);
04651 # endif
04652 break;
04653
04654 case Ieee_Unordered_Opr :
04655 PDG_DBG_PRINT_START
04656 PDG_DBG_PRINT_C("fei_isunordered");
04657 PDG_DBG_PRINT_END
04658 # ifdef _ENABLE_FEI
04659 fei_isunordered(basic);
04660 # endif
04661 break;
04662
04663 case Ieee_Remainder_Opr :
04664 PDG_DBG_PRINT_START
04665 PDG_DBG_PRINT_C("fei_remainder");
04666 PDG_DBG_PRINT_END
04667 # ifdef _ENABLE_FEI
04668 fei_remainder(basic);
04669 # endif
04670 break;
04671
04672 case Ieee_Real_Opr :
04673 PDG_DBG_PRINT_START
04674 PDG_DBG_PRINT_C("fei_ieee_round");
04675 PDG_DBG_PRINT_END
04676 # ifdef _ENABLE_FEI
04677 fei_ieee_round(basic);
04678 # endif
04679 break;
04680
04681 case Ieee_Int_Opr :
04682 PDG_DBG_PRINT_START
04683 PDG_DBG_PRINT_C("fei_ieee_trunc");
04684 PDG_DBG_PRINT_END
04685 # ifdef _ENABLE_FEI
04686 fei_ieee_trunc(basic);
04687 # endif
04688 break;
04689
04690 case Ieee_Copy_Sign_Opr :
04691 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
04692 PDG_DBG_PRINT_START
04693 PDG_DBG_PRINT_C("fei_ieee_sign_xfer");
04694 PDG_DBG_PRINT_END
04695 # ifdef _ENABLE_FEI
04696 fei_ieee_sign_xfer(basic);
04697 # endif
04698 # else
04699 PDG_DBG_PRINT_START
04700 PDG_DBG_PRINT_C("fei_sign_xfer");
04701 PDG_DBG_PRINT_END
04702 # ifdef _ENABLE_FEI
04703 fei_sign_xfer(basic);
04704 # endif
04705 # endif
04706 break;
04707
04708 case Ieee_Exponent_Opr :
04709 PDG_DBG_PRINT_START
04710 PDG_DBG_PRINT_C("fei_logb");
04711 PDG_DBG_PRINT_END
04712 # ifdef _ENABLE_FEI
04713 fei_logb(basic);
04714 # endif
04715 break;
04716
04717 case Ieee_Next_After_Opr :
04718 PDG_DBG_PRINT_START
04719 PDG_DBG_PRINT_C("fei_nextafter");
04720 PDG_DBG_PRINT_END
04721 # ifdef _ENABLE_FEI
04722 fei_nextafter(basic);
04723 # endif
04724 break;
04725
04726 case Ieee_Binary_Scale_Opr :
04727 PDG_DBG_PRINT_START
04728 PDG_DBG_PRINT_C("fei_scalb");
04729 PDG_DBG_PRINT_END
04730 # ifdef _ENABLE_FEI
04731 fei_scalb(basic);
04732 # endif
04733 break;
04734
04735 case Mod_Opr :
04736 PDG_DBG_PRINT_START
04737 PDG_DBG_PRINT_C("fei_mod");
04738 PDG_DBG_PRINT_END
04739 # ifdef _ENABLE_FEI
04740 fei_mod(basic);
04741 # endif
04742 break;
04743
04744 case Eq_Opr :
04745 PDG_DBG_PRINT_START
04746 PDG_DBG_PRINT_C("fei_eq");
04747 PDG_DBG_PRINT_END
04748 # ifdef _ENABLE_FEI
04749 fei_eq(basic);
04750 # endif
04751 break;
04752
04753 case Ne_Opr :
04754 PDG_DBG_PRINT_START
04755 PDG_DBG_PRINT_C("fei_ne");
04756 PDG_DBG_PRINT_END
04757 # ifdef _ENABLE_FEI
04758 fei_ne(basic);
04759 # endif
04760 break;
04761
04762 case Lg_Opr :
04763 PDG_DBG_PRINT_START
04764 PDG_DBG_PRINT_C("fei_islg");
04765 PDG_DBG_PRINT_END
04766 # ifdef _ENABLE_FEI
04767 fei_islg(basic);
04768 # endif
04769 break;
04770
04771 case Lt_Opr :
04772 case Llt_Opr :
04773 PDG_DBG_PRINT_START
04774 PDG_DBG_PRINT_C("fei_lt");
04775 PDG_DBG_PRINT_END
04776 # ifdef _ENABLE_FEI
04777 fei_lt(basic);
04778 # endif
04779 break;
04780
04781 case Le_Opr :
04782 case Lle_Opr :
04783 PDG_DBG_PRINT_START
04784 PDG_DBG_PRINT_C("fei_le");
04785 PDG_DBG_PRINT_END
04786 # ifdef _ENABLE_FEI
04787 fei_le(basic);
04788 # endif
04789 break;
04790
04791 case Gt_Opr :
04792 case Lgt_Opr :
04793 PDG_DBG_PRINT_START
04794 PDG_DBG_PRINT_C("fei_gt");
04795 PDG_DBG_PRINT_END
04796 # ifdef _ENABLE_FEI
04797 fei_gt(basic);
04798 # endif
04799 break;
04800
04801 case Ge_Opr :
04802 case Lge_Opr :
04803 PDG_DBG_PRINT_START
04804 PDG_DBG_PRINT_C("fei_ge");
04805 PDG_DBG_PRINT_END
04806 # ifdef _ENABLE_FEI
04807 fei_ge(basic);
04808 # endif
04809 break;
04810
04811 case And_Opr :
04812 PDG_DBG_PRINT_START
04813 PDG_DBG_PRINT_C("fei_land");
04814 PDG_DBG_PRINT_END
04815 # ifdef _ENABLE_FEI
04816 fei_land(basic);
04817 # endif
04818 break;
04819
04820 case Band_Opr :
04821 PDG_DBG_PRINT_START
04822 PDG_DBG_PRINT_C("fei_and");
04823 PDG_DBG_PRINT_END
04824 # ifdef _ENABLE_FEI
04825 fei_and(basic);
04826 # endif
04827 break;
04828
04829 case Or_Opr :
04830 PDG_DBG_PRINT_START
04831 PDG_DBG_PRINT_C("fei_lor");
04832 PDG_DBG_PRINT_END
04833 # ifdef _ENABLE_FEI
04834 fei_lor(basic);
04835 # endif
04836 break;
04837
04838 case Bor_Opr :
04839 PDG_DBG_PRINT_START
04840 PDG_DBG_PRINT_C("fei_or");
04841 PDG_DBG_PRINT_END
04842 # ifdef _ENABLE_FEI
04843 fei_or(basic);
04844 # endif
04845 break;
04846
04847 case Eqv_Opr :
04848 PDG_DBG_PRINT_START
04849 PDG_DBG_PRINT_C("fei_leqv");
04850 PDG_DBG_PRINT_END
04851 # ifdef _ENABLE_FEI
04852 fei_leqv(basic);
04853 # endif
04854 break;
04855
04856 case Neqv_Opr :
04857 PDG_DBG_PRINT_START
04858 PDG_DBG_PRINT_C("fei_lxor");
04859 PDG_DBG_PRINT_END
04860 # ifdef _ENABLE_FEI
04861 fei_lxor(basic);
04862 # endif
04863 break;
04864
04865 case Bneqv_Opr :
04866 PDG_DBG_PRINT_START
04867 PDG_DBG_PRINT_C("fei_xor");
04868 PDG_DBG_PRINT_END
04869 # ifdef _ENABLE_FEI
04870 fei_xor(basic);
04871 # endif
04872 break;
04873
04874 case Beqv_Opr :
04875 PDG_DBG_PRINT_START
04876 PDG_DBG_PRINT_C("fei_eqv");
04877 PDG_DBG_PRINT_END
04878 # ifdef _ENABLE_FEI
04879 fei_eqv(basic);
04880 # endif
04881 break;
04882
04883 case Plus_Opr :
04884 PDG_DBG_PRINT_START
04885 PDG_DBG_PRINT_C("fei_plus");
04886 PDG_DBG_PRINT_END
04887 # ifdef _ENABLE_FEI
04888 fei_plus(basic);
04889 # endif
04890 break;
04891
04892 case Minus_Opr :
04893 PDG_DBG_PRINT_START
04894 PDG_DBG_PRINT_C("fei_minus");
04895 PDG_DBG_PRINT_END
04896 # ifdef _ENABLE_FEI
04897 fei_minus(basic);
04898 # endif
04899 break;
04900
04901 case Div_Opr :
04902 PDG_DBG_PRINT_START
04903 PDG_DBG_PRINT_C("fei_div");
04904 PDG_DBG_PRINT_END
04905 # ifdef _ENABLE_FEI
04906 fei_div(basic);
04907 # endif
04908 break;
04909
04910 case Mult_Opr :
04911 case Dprod_Opr :
04912 PDG_DBG_PRINT_START
04913 PDG_DBG_PRINT_C("fei_mult");
04914 PDG_DBG_PRINT_END
04915 # ifdef _ENABLE_FEI
04916 fei_mult(basic);
04917 # endif
04918 break;
04919
04920 case Power_Opr :
04921 PDG_DBG_PRINT_START
04922 PDG_DBG_PRINT_C("fei_exponentiate");
04923 PDG_DBG_PRINT_END
04924 # ifdef _ENABLE_FEI
04925 fei_exponentiate(basic);
04926 # endif
04927 break;
04928
04929 case Shifta_Opr :
04930 PDG_DBG_PRINT_START
04931 PDG_DBG_PRINT_C("fei_ashift");
04932 PDG_DBG_PRINT_END
04933 # ifdef _ENABLE_FEI
04934 fei_ashift(basic);
04935 # endif
04936 break;
04937
04938 case Shiftr_Opr :
04939 PDG_DBG_PRINT_START
04940 PDG_DBG_PRINT_C("fei_rshift");
04941 PDG_DBG_PRINT_END
04942 # ifdef _ENABLE_FEI
04943 fei_rshift(basic);
04944 # endif
04945 break;
04946
04947 case Shiftl_Opr :
04948 PDG_DBG_PRINT_START
04949 PDG_DBG_PRINT_C("fei_lshift");
04950 PDG_DBG_PRINT_END
04951 # ifdef _ENABLE_FEI
04952 fei_lshift(basic);
04953 # endif
04954 break;
04955
04956 case Shift_Opr :
04957 PDG_DBG_PRINT_START
04958 PDG_DBG_PRINT_C("fei_new_binop_cshift");
04959 PDG_DBG_PRINT_END
04960 # ifdef _ENABLE_FEI
04961 fei_new_binop_cshift(basic);
04962 # endif
04963 break;
04964
04965 }
04966 break;
04967
04968
04969
04970
04971
04972
04973
04974
04975
04976
04977
04978
04979 case Entry_Opr :
04980 if (ATP_ALT_ENTRY(IR_IDX_L(ir_idx))) {
04981 PDG_DBG_PRINT_START
04982 PDG_DBG_PRINT_C("fei_entry_pt");
04983 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX", PDG_AT_IDX(IR_IDX_L(ir_idx)));
04984 PDG_DBG_PRINT_END
04985
04986 # ifdef _ENABLE_FEI
04987 fei_entry_pt(PDG_AT_IDX(IR_IDX_L(ir_idx)));
04988 # endif
04989 }
04990 break;
04991
04992
04993 case Label_Opr :
04994 attr_idx = IR_IDX_L(ir_idx);
04995
04996 if (ATL_CLASS(attr_idx) == Lbl_Format ||
04997 (ATL_CLASS(attr_idx) <= Lbl_User && !ATL_EXECUTABLE(attr_idx))) {
04998
04999 }
05000 else {
05001 send_label_def(ir_idx);
05002 }
05003 break;
05004
05005
05006
05007 case Whole_Substring_Opr :
05008 case Substring_Opr :
05009 whole_substring = IR_OPR(ir_idx) == Whole_Substring_Opr;
05010 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
05011 IR_FLD_L(ir_idx));
05012 whole_substring = FALSE;
05013
05014 bound_chk = cmd_line_flags.runtime_substring;
05015
05016 if (IR_BOUNDS_DONE(ir_idx)) {
05017 bound_chk = FALSE;
05018 }
05019
05020 list_idx1 = IR_IDX_R(ir_idx);
05021 list_idx2 = IL_NEXT_LIST_IDX(list_idx1);
05022 list_idx3 = IL_NEXT_LIST_IDX(list_idx2);
05023
05024 if (stack_data_object) {
05025 big_int = CN_INT_TO_C(IL_IDX(list_idx1));
05026
05027 PDG_DBG_PRINT_START
05028 PDG_DBG_PRINT_C("fei_static_substr");
05029 #if defined(_HOST32) && defined(_TARGET64)
05030 PDG_DBG_PRINT_D("(1) constant", big_int);
05031 #else
05032 PDG_DBG_PRINT_VD("(1) constant", big_int);
05033 #endif
05034 PDG_DBG_PRINT_END
05035
05036 # ifdef _ENABLE_FEI
05037 fei_static_substr(big_int);
05038 # endif
05039
05040 data_character_bit_length = list_idx3;
05041 break;
05042 }
05043
05044 cvrt_exp_to_pdg(IL_IDX(list_idx1),
05045 IL_FLD(list_idx1));
05046
05047
05048 cvrt_exp_to_pdg(IL_IDX(list_idx3),
05049 IL_FLD(list_idx3));
05050
05051 PDG_DBG_PRINT_START
05052 PDG_DBG_PRINT_C("fei_substr");
05053 PDG_DBG_PRINT_D("(1) bound_chk", bound_chk);
05054 PDG_DBG_PRINT_END
05055
05056 # ifdef _ENABLE_FEI
05057 fei_substr(bound_chk);
05058 # endif
05059 break;
05060
05061
05062
05063
05064
05065 case Return_Opr :
05066 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
05067 IR_FLD_L(ir_idx));
05068
05069 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
05070 IR_FLD_R(ir_idx));
05071
05072 if (IR_IDX_L(ir_idx) != NULL_IDX) {
05073 return_kind = Alternate_Return;
05074 }
05075 else if (IR_IDX_R(ir_idx) != NULL_IDX) {
05076 return_kind = Normal_Return;
05077 }
05078 else {
05079 return_kind = Void_Return;
05080 }
05081
05082 PDG_DBG_PRINT_START
05083 PDG_DBG_PRINT_C("fei_return");
05084 PDG_DBG_PRINT_S("(1) return_kind", p_return[return_kind]);
05085 PDG_DBG_PRINT_T("(2) type", pdg_type_void);
05086 PDG_DBG_PRINT_END
05087
05088 # ifdef _ENABLE_FEI
05089 fei_return(return_kind, pdg_type_void);
05090 # endif
05091 break;
05092
05093
05094
05095
05096 case Stop_Opr:
05097 # ifdef _STOP_IS_OPR
05098
05099 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
05100 IR_FLD_R(ir_idx));
05101
05102 PDG_DBG_PRINT_START
05103 PDG_DBG_PRINT_C("fei_stop");
05104 PDG_DBG_PRINT_END
05105
05106 # ifdef _ENABLE_FEI
05107 fei_stop();
05108 # endif
05109
05110 # else
05111 PRINTMSG(IR_LINE_NUM(ir_idx), 626, Internal,
05112 IR_COL_NUM(ir_idx),
05113 "no Stop_Opr", "cvrt_exp_to_pdg");
05114 # endif
05115 break;
05116
05117
05118
05119
05120
05121
05122 case Matmul_Opr :
05123 case Spread_Opr :
05124 case Reshape_Opr :
05125 case Transpose_Opr :
05126 case Sum_Opr :
05127 case Eoshift_Opr :
05128 case Maxval_Opr :
05129 case Minval_Opr :
05130 case Maxloc_Opr :
05131 case Minloc_Opr :
05132 case All_Opr :
05133 case Any_Opr :
05134 case Count_Opr :
05135 case Product_Opr :
05136 case Unpack_Opr :
05137 case Pack_Opr :
05138 case Cshift_Opr :
05139 case Dot_Product_Opr :
05140 case Dot_Product_Logical_Opr :
05141 processing_call = processing_call + 1;
05142
05143 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
05144 IR_FLD_L(ir_idx));
05145
05146 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
05147
05148 switch (IR_OPR(ir_idx)) {
05149 case Matmul_Opr :
05150 PDG_DBG_PRINT_START
05151 PDG_DBG_PRINT_C("fei_matmul");
05152 PDG_DBG_PRINT_END
05153 # ifdef _ENABLE_FEI
05154 fei_matmul(basic);
05155 # endif
05156 break;
05157
05158 case Spread_Opr :
05159 PDG_DBG_PRINT_START
05160 PDG_DBG_PRINT_C("fei_spread");
05161 PDG_DBG_PRINT_END
05162 # ifdef _ENABLE_FEI
05163 fei_spread(basic);
05164 # endif
05165 break;
05166
05167 case Reshape_Opr :
05168 PDG_DBG_PRINT_START
05169 PDG_DBG_PRINT_C("fei_reshape");
05170 PDG_DBG_PRINT_END
05171 # ifdef _ENABLE_FEI
05172 fei_reshape(basic);
05173 # endif
05174 break;
05175
05176 case Transpose_Opr :
05177 PDG_DBG_PRINT_START
05178 PDG_DBG_PRINT_C("fei_transpose");
05179 PDG_DBG_PRINT_END
05180 # ifdef _ENABLE_FEI
05181 fei_transpose(basic);
05182 # endif
05183 break;
05184
05185 case Sum_Opr :
05186 PDG_DBG_PRINT_START
05187 PDG_DBG_PRINT_C("fei_sum");
05188 PDG_DBG_PRINT_END
05189 # ifdef _ENABLE_FEI
05190 fei_sum(basic);
05191 # endif
05192 break;
05193
05194 case Eoshift_Opr :
05195 PDG_DBG_PRINT_START
05196 PDG_DBG_PRINT_C("fei_eoshift");
05197 PDG_DBG_PRINT_END
05198 # ifdef _ENABLE_FEI
05199 fei_eoshift(basic);
05200 # endif
05201 break;
05202
05203 case Maxval_Opr :
05204 PDG_DBG_PRINT_START
05205 PDG_DBG_PRINT_C("fei_maxval");
05206 PDG_DBG_PRINT_END
05207 # ifdef _ENABLE_FEI
05208 fei_maxval(basic);
05209 # endif
05210 break;
05211
05212 case Minval_Opr :
05213 PDG_DBG_PRINT_START
05214 PDG_DBG_PRINT_C("fei_minval");
05215 PDG_DBG_PRINT_END
05216 # ifdef _ENABLE_FEI
05217 fei_minval(basic);
05218 # endif
05219 break;
05220
05221 case Maxloc_Opr :
05222 PDG_DBG_PRINT_START
05223 PDG_DBG_PRINT_C("fei__maxloc");
05224 PDG_DBG_PRINT_END
05225 # ifdef _ENABLE_FEI
05226 fei__maxloc(basic);
05227 # endif
05228 break;
05229
05230 case Minloc_Opr :
05231 PDG_DBG_PRINT_START
05232 PDG_DBG_PRINT_C("fei__minloc");
05233 PDG_DBG_PRINT_END
05234 # ifdef _ENABLE_FEI
05235 fei__minloc(basic);
05236 # endif
05237 break;
05238
05239 case All_Opr :
05240 PDG_DBG_PRINT_START
05241 PDG_DBG_PRINT_C("fei_all");
05242 PDG_DBG_PRINT_END
05243 # ifdef _ENABLE_FEI
05244 fei_all(basic);
05245 # endif
05246 break;
05247
05248 case Any_Opr :
05249 PDG_DBG_PRINT_START
05250 PDG_DBG_PRINT_C("fei_any");
05251 PDG_DBG_PRINT_END
05252 # ifdef _ENABLE_FEI
05253 fei_any(basic);
05254 # endif
05255 break;
05256
05257 case Count_Opr :
05258 PDG_DBG_PRINT_START
05259 PDG_DBG_PRINT_C("fei_count");
05260 PDG_DBG_PRINT_END
05261 # ifdef _ENABLE_FEI
05262 fei_count(basic);
05263 # endif
05264 break;
05265
05266 case Product_Opr :
05267 PDG_DBG_PRINT_START
05268 PDG_DBG_PRINT_C("fei_product");
05269 PDG_DBG_PRINT_END
05270 # ifdef _ENABLE_FEI
05271 fei_product(basic);
05272 # endif
05273 break;
05274
05275 case Unpack_Opr :
05276 PDG_DBG_PRINT_START
05277 PDG_DBG_PRINT_C("fei_unpack");
05278 PDG_DBG_PRINT_END
05279 # ifdef _ENABLE_FEI
05280 fei_unpack(basic);
05281 # endif
05282 break;
05283
05284 case Pack_Opr :
05285 PDG_DBG_PRINT_START
05286 PDG_DBG_PRINT_C("fei_pack");
05287 PDG_DBG_PRINT_END
05288 # ifdef _ENABLE_FEI
05289 fei_pack(basic);
05290 # endif
05291 break;
05292
05293 case Cshift_Opr :
05294 PDG_DBG_PRINT_START
05295 PDG_DBG_PRINT_C("fei_cshift");
05296 PDG_DBG_PRINT_END
05297 # ifdef _ENABLE_FEI
05298 fei_cshift(basic);
05299 # endif
05300 break;
05301
05302 case Dot_Product_Opr :
05303 PDG_DBG_PRINT_START
05304 PDG_DBG_PRINT_C("fei_dot_product");
05305 PDG_DBG_PRINT_END
05306 # ifdef _ENABLE_FEI
05307 fei_dot_product(basic);
05308 # endif
05309 break;
05310
05311 case Dot_Product_Logical_Opr :
05312 PDG_DBG_PRINT_START
05313 PDG_DBG_PRINT_C("fei_dot_product_logical)");
05314 PDG_DBG_PRINT_END
05315 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
05316 # ifdef _ENABLE_FEI
05317 fei_dot_product_logical(basic);
05318 # endif
05319 # endif
05320 break;
05321 }
05322
05323 processing_call = processing_call - 1;
05324 break;
05325
05326
05327
05328
05329
05330
05331
05332
05333
05334
05335
05336
05337 case Memory_Barrier_Opr :
05338 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
05339 IR_FLD_L(ir_idx));
05340
05341 PDG_DBG_PRINT_START
05342 PDG_DBG_PRINT_C("fei_loc_cmr");
05343 PDG_DBG_PRINT_END
05344
05345 # ifdef _ENABLE_FEI
05346 fei_loc_cmr();
05347 # endif
05348 break;
05349
05350
05351
05352
05353
05354 case Write_Memory_Barrier_Opr :
05355 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
05356 IR_FLD_L(ir_idx));
05357
05358 PDG_DBG_PRINT_START
05359 PDG_DBG_PRINT_C("fei_wmb");
05360 PDG_DBG_PRINT_END
05361
05362 # ifdef _ENABLE_FEI
05363 fei_wmb();
05364 # endif
05365 break;
05366
05367
05368
05369
05370
05371
05372 case Remote_Write_Barrier_Opr :
05373 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
05374 IR_FLD_L(ir_idx));
05375
05376 PDG_DBG_PRINT_START
05377 PDG_DBG_PRINT_C("fei_rem_cmr");
05378 PDG_DBG_PRINT_END
05379
05380 # ifdef _ENABLE_FEI
05381 fei_rem_cmr();
05382 # endif
05383 break;
05384
05385
05386
05387
05388
05389
05390
05391 case Get_Ieee_Status_Opr :
05392 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
05393 IR_FLD_L(ir_idx));
05394
05395 PDG_DBG_PRINT_START
05396 PDG_DBG_PRINT_C("fei_readsr");
05397 PDG_DBG_PRINT_END
05398
05399 # ifdef _ENABLE_FEI
05400 fei_readsr();
05401 # endif
05402 break;
05403
05404
05405
05406
05407
05408 case Set_Ieee_Status_Opr :
05409 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
05410 IR_FLD_L(ir_idx));
05411
05412 PDG_DBG_PRINT_START
05413 PDG_DBG_PRINT_C("fei_set_ieee_stat");
05414 PDG_DBG_PRINT_END
05415
05416 # ifdef _ENABLE_FEI
05417 fei_set_ieee_stat();
05418 # endif
05419 break;
05420
05421
05422
05423
05424
05425 case Get_Ieee_Exceptions_Opr :
05426 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
05427 IR_FLD_L(ir_idx));
05428
05429 PDG_DBG_PRINT_START
05430 PDG_DBG_PRINT_C("fei_get_all_estat");
05431 PDG_DBG_PRINT_END
05432
05433 # ifdef _ENABLE_FEI
05434 fei_get_all_estat();
05435 # endif
05436 break;
05437
05438
05439
05440
05441
05442 case Set_Ieee_Exceptions_Opr :
05443 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
05444 IR_FLD_L(ir_idx));
05445
05446 PDG_DBG_PRINT_START
05447 PDG_DBG_PRINT_C("fei_set_all_estat");
05448 PDG_DBG_PRINT_END
05449
05450 # ifdef _ENABLE_FEI
05451 fei_set_all_estat();
05452 # endif
05453 break;
05454
05455
05456
05457
05458
05459 case Test_Ieee_Exception_Opr :
05460 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
05461 IR_FLD_L(ir_idx));
05462
05463 PDG_DBG_PRINT_START
05464 PDG_DBG_PRINT_C("fei_test_estat");
05465 PDG_DBG_PRINT_END
05466
05467 # ifdef _ENABLE_FEI
05468 fei_test_estat();
05469 # endif
05470 break;
05471
05472
05473
05474
05475
05476 case Clear_Ieee_Exception_Opr :
05477 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
05478 IR_FLD_L(ir_idx));
05479
05480 PDG_DBG_PRINT_START
05481 PDG_DBG_PRINT_C("fei_set_estat");
05482 PDG_DBG_PRINT_END
05483
05484 # ifdef _ENABLE_FEI
05485 fei_set_estat();
05486 # endif
05487 break;
05488
05489
05490
05491
05492
05493 case Set_Ieee_Exception_Opr :
05494 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
05495 IR_FLD_L(ir_idx));
05496
05497 PDG_DBG_PRINT_START
05498 PDG_DBG_PRINT_C("fei_set_estat");
05499 PDG_DBG_PRINT_END
05500
05501 # ifdef _ENABLE_FEI
05502 fei_set_estat();
05503 # endif
05504 break;
05505
05506
05507
05508
05509
05510 case Get_Ieee_Interrupts_Opr :
05511 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
05512 IR_FLD_L(ir_idx));
05513
05514 PDG_DBG_PRINT_START
05515 PDG_DBG_PRINT_C("fei_get_interupt");
05516 PDG_DBG_PRINT_END
05517
05518 # ifdef _ENABLE_FEI
05519 fei_get_interupt();
05520 # endif
05521 break;
05522
05523
05524
05525
05526 case Set_Ieee_Interrupts_Opr :
05527 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
05528 IR_FLD_L(ir_idx));
05529
05530 PDG_DBG_PRINT_START
05531 PDG_DBG_PRINT_C("fei_set_interupt");
05532 PDG_DBG_PRINT_END
05533
05534 # ifdef _ENABLE_FEI
05535 fei_set_interupt();
05536 # endif
05537 break;
05538
05539
05540
05541
05542
05543 case Test_Ieee_Interrupt_Opr :
05544 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
05545 IR_FLD_L(ir_idx));
05546
05547 PDG_DBG_PRINT_START
05548 PDG_DBG_PRINT_C("fei_test_interupt");
05549 PDG_DBG_PRINT_END
05550
05551 # ifdef _ENABLE_FEI
05552 fei_test_interupt();
05553 # endif
05554 break;
05555
05556
05557
05558
05559
05560
05561
05562
05563 case Enable_Ieee_Interrupt_Opr :
05564 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
05565 IR_FLD_L(ir_idx));
05566
05567 PDG_DBG_PRINT_START
05568 PDG_DBG_PRINT_C("fei_enbl_interupt");
05569 PDG_DBG_PRINT_END
05570
05571 # ifdef _ENABLE_FEI
05572 fei_enbl_interupt();
05573 # endif
05574 break;
05575
05576
05577
05578
05579
05580
05581
05582 case Disable_Ieee_Interrupt_Opr :
05583 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
05584 IR_FLD_L(ir_idx));
05585
05586 PDG_DBG_PRINT_START
05587 PDG_DBG_PRINT_C("fei_dsbl_interupt");
05588 PDG_DBG_PRINT_END
05589
05590 # ifdef _ENABLE_FEI
05591 fei_dsbl_interupt();
05592 # endif
05593 break;
05594
05595
05596
05597
05598
05599 case Get_Ieee_Rounding_Mode_Opr :
05600 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
05601 IR_FLD_L(ir_idx));
05602
05603 PDG_DBG_PRINT_START
05604 PDG_DBG_PRINT_C("fei_get_rmode");
05605 PDG_DBG_PRINT_END
05606
05607 # ifdef _ENABLE_FEI
05608 fei_get_rmode();
05609 # endif
05610 break;
05611
05612
05613
05614
05615 case Set_Ieee_Rounding_Mode_Opr :
05616 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
05617 IR_FLD_L(ir_idx));
05618
05619 PDG_DBG_PRINT_START
05620 PDG_DBG_PRINT_C("fei_set_rmode");
05621 PDG_DBG_PRINT_END
05622
05623 # ifdef _ENABLE_FEI
05624 fei_set_rmode();
05625 # endif
05626 break;
05627
05628
05629
05630
05631
05632
05633
05634
05635
05636
05637
05638
05639
05640
05641
05642
05643
05644
05645
05646
05647
05648
05649 case Alloc_Opr :
05650 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
05651 IR_FLD_L(ir_idx));
05652
05653 PDG_DBG_PRINT_START
05654 PDG_DBG_PRINT_C("fei_alloc");
05655 PDG_DBG_PRINT_END
05656
05657 # ifdef _ENABLE_FEI
05658 fei_alloc();
05659 # endif
05660 break;
05661
05662
05663
05664
05665 case Malloc_Opr :
05666 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
05667 IR_FLD_L(ir_idx));
05668
05669 PDG_DBG_PRINT_START
05670 PDG_DBG_PRINT_C("fei_malloc");
05671 PDG_DBG_PRINT_END
05672
05673 # ifdef _ENABLE_FEI
05674 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
05675 fei_malloc();
05676 # endif
05677 # endif
05678 break;
05679
05680
05681
05682
05683
05684 case SSD_Alloc_Opr :
05685 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
05686 IR_FLD_L(ir_idx));
05687
05688 PDG_DBG_PRINT_START
05689 PDG_DBG_PRINT_C("fei_ssd_alloc");
05690 PDG_DBG_PRINT_END
05691
05692 # ifdef _ENABLE_FEI
05693 fei_ssd_alloc();
05694 # endif
05695 break;
05696
05697
05698
05699
05700 case Symmetric_Alloc_Opr :
05701 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
05702 IR_FLD_L(ir_idx));
05703
05704 PDG_DBG_PRINT_START
05705 PDG_DBG_PRINT_C("fei_mpp_symmetric_alloc");
05706 PDG_DBG_PRINT_END
05707
05708 # ifdef _ENABLE_FEI
05709 fei_mpp_symmetric_alloc();
05710 # endif
05711 break;
05712
05713
05714
05715
05716
05717 case Dealloc_Opr :
05718 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
05719 IR_FLD_L(ir_idx));
05720
05721 PDG_DBG_PRINT_START
05722 PDG_DBG_PRINT_C("fei_free");
05723 PDG_DBG_PRINT_END
05724
05725 # ifdef _ENABLE_FEI
05726 fei_free();
05727 # endif
05728 break;
05729
05730
05731
05732
05733 case Free_Opr :
05734 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
05735 IR_FLD_L(ir_idx));
05736
05737 PDG_DBG_PRINT_START
05738 PDG_DBG_PRINT_C("fei_mfree");
05739 PDG_DBG_PRINT_END
05740
05741 # ifdef _ENABLE_FEI
05742 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
05743 fei_mfree();
05744 # endif
05745 # endif
05746 break;
05747
05748
05749
05750
05751
05752
05753 case SSD_Dealloc_Opr :
05754 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
05755 IR_FLD_L(ir_idx));
05756
05757 PDG_DBG_PRINT_START
05758 PDG_DBG_PRINT_C("fei_ssd_free");
05759 PDG_DBG_PRINT_END
05760
05761 # ifdef _ENABLE_FEI
05762 fei_ssd_free();
05763 # endif
05764 break;
05765
05766
05767
05768 case Symmetric_Dealloc_Opr :
05769 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
05770 IR_FLD_L(ir_idx));
05771
05772 PDG_DBG_PRINT_START
05773 PDG_DBG_PRINT_C("fei_mpp_symmetric_free");
05774 PDG_DBG_PRINT_END
05775
05776 # ifdef _ENABLE_FEI
05777 fei_mpp_symmetric_free();
05778 # endif
05779 break;
05780
05781
05782
05783
05784 case Copyin_Bound_Opr :
05785 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
05786 send_attr_ntry(IR_IDX_L(ir_idx));
05787
05788 PDG_DBG_PRINT_START
05789 PDG_DBG_PRINT_C("fei_copyin_bound");
05790 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX", PDG_AT_IDX(IR_IDX_L(ir_idx)));
05791 PDG_DBG_PRINT_END
05792
05793 # ifdef _ENABLE_FEI
05794 fei_copyin_bound(PDG_AT_IDX(IR_IDX_L(ir_idx)));
05795 # endif
05796 # endif
05797 break;
05798
05799
05800
05801 case Copy_In_Opr :
05802 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
05803 IR_FLD_L(ir_idx));
05804
05805 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
05806 IR_FLD_R(ir_idx));
05807
05808 PDG_DBG_PRINT_START
05809 PDG_DBG_PRINT_C("fei_copyin");
05810 PDG_DBG_PRINT_END
05811
05812 # ifdef _ENABLE_FEI
05813 fei_copyin();
05814 # endif
05815 break;
05816
05817
05818
05819
05820
05821
05822 case Copy_Out_Opr :
05823 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
05824 IR_FLD_L(ir_idx));
05825
05826 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
05827 IR_FLD_R(ir_idx));
05828
05829 PDG_DBG_PRINT_START
05830 PDG_DBG_PRINT_C("fei_copyout");
05831 PDG_DBG_PRINT_END
05832
05833 # ifdef _ENABLE_FEI
05834 fei_copyout();
05835 # endif
05836 break;
05837
05838
05839
05840
05841
05842
05843
05844
05845
05846
05847
05848
05849
05850 case Struct_Opr :
05851 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
05852 IR_FLD_L(ir_idx));
05853
05854 data_attr = NULL_IDX;
05855 member = TRUE;
05856 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
05857 IR_FLD_R(ir_idx));
05858 member = FALSE;
05859
05860 if (stack_data_object) {
05861 break;
05862 }
05863
05864 PDG_DBG_PRINT_START
05865 PDG_DBG_PRINT_C("fei_field_dot");
05866 PDG_DBG_PRINT_END
05867
05868 # ifdef _ENABLE_FEI
05869 fei_field_dot(null_type);
05870 # endif
05871
05872 break;
05873
05874
05875
05876
05877
05878
05879 case Triplet_Opr :
05880 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
05881 IR_FLD_L(ir_idx));
05882
05883 PDG_DBG_PRINT_START
05884 PDG_DBG_PRINT_C("fei_subscr_triplet");
05885 PDG_DBG_PRINT_END
05886
05887 # ifdef _ENABLE_FEI
05888 fei_subscr_triplet(pdg_type_void);
05889 # endif
05890 break;
05891
05892
05893
05894
05895 case Max_Opr :
05896 case Min_Opr :
05897 tmp_ir_idx = IR_IDX_L(ir_idx);
05898 count = 0;
05899 while (tmp_ir_idx != NULL_IDX) {
05900 if (IL_IDX(tmp_ir_idx) != NULL_IDX) {
05901 cvrt_exp_to_pdg(IL_IDX(tmp_ir_idx),
05902 IL_FLD(tmp_ir_idx));
05903
05904 count = count + 1;
05905 }
05906 tmp_ir_idx = IL_NEXT_LIST_IDX(tmp_ir_idx);
05907 }
05908
05909 basic = get_basic_type(IR_TYPE_IDX(ir_idx),0, NULL_IDX);
05910
05911 if (IR_OPR(ir_idx) == Min_Opr) {
05912 PDG_DBG_PRINT_START
05913 PDG_DBG_PRINT_C("fei_min");
05914 PDG_DBG_PRINT_D("(1) count", count);
05915 PDG_DBG_PRINT_T("(2) type", basic);
05916 PDG_DBG_PRINT_END
05917 # ifdef _ENABLE_FEI
05918 fei_min(count, basic);
05919 # endif
05920 }
05921 else {
05922 PDG_DBG_PRINT_START
05923 PDG_DBG_PRINT_C("fei_max");
05924 PDG_DBG_PRINT_D("(1) count", count);
05925 PDG_DBG_PRINT_T("(2) type", basic);
05926 PDG_DBG_PRINT_END
05927 # ifdef _ENABLE_FEI
05928 fei_max(count, basic);
05929 # endif
05930 }
05931 break;
05932
05933
05934
05935
05936
05937
05938
05939 case Implied_Do_Opr :
05940 if (static_initialization) {
05941
05942 search_idx = IL_NEXT_LIST_IDX(IR_IDX_R(ir_idx));
05943
05944 trip = 1;
05945 while (trip != 4) {
05946 if (trip == 1) {
05947 COPY_OPND(l_opnd, IL_OPND(search_idx));
05948 vv = 1;
05949 cn_idx = get_next_array_expr_element(&l_opnd, &vv);
05950 COPY_OPND(IL_OPND(search_idx), l_opnd);
05951 start = CN_INT_TO_C(cn_idx);
05952 }
05953
05954 if (trip == 2) {
05955 COPY_OPND(l_opnd, IL_OPND(search_idx));
05956 vv = 1;
05957 cn_idx = get_next_array_expr_element(&l_opnd, &vv);
05958 COPY_OPND(IL_OPND(search_idx), l_opnd);
05959 end = CN_INT_TO_C(cn_idx);
05960 }
05961
05962 if (trip == 3) {
05963 COPY_OPND(l_opnd, IL_OPND(search_idx));
05964 vv = 1;
05965 cn_idx = get_next_array_expr_element(&l_opnd, &vv);
05966 COPY_OPND(IL_OPND(search_idx), l_opnd);
05967 inc = CN_INT_TO_C(cn_idx);
05968 }
05969
05970 trip = trip + 1;
05971 search_idx = IL_NEXT_LIST_IDX(search_idx);
05972 }
05973
05974
05975
05976
05977 GET_LCV_CONST(IL_IDX(IR_IDX_R(ir_idx)),
05978 loc_value[0],
05979 num_host_wds[TYP_LINEAR(
05980 ATD_TYPE_IDX(IL_IDX(IR_IDX_R(ir_idx))))]);
05981
05982 ATD_FLD(IL_IDX(IR_IDX_R(ir_idx))) = CN_Tbl_Idx;
05983 ATD_TMP_IDX(IL_IDX(IR_IDX_R(ir_idx))) =
05984 ntr_const_tbl(ATD_TYPE_IDX(IL_IDX(IR_IDX_R(ir_idx))),
05985 FALSE,
05986 loc_value);
05987
05988 if (inc > 0) {
05989 for (i = start; i <= end; i = i + inc) {
05990
05991 if (search_idx == NULL_IDX) {
05992 cn_idx = C_INT_TO_CN(NULL_IDX, i);
05993 }
05994 else {
05995 COPY_OPND(l_opnd, IL_OPND(search_idx));
05996 vv = i;
05997 cn_idx = get_next_array_expr_element(&l_opnd, &vv);
05998 COPY_OPND(IL_OPND(search_idx), l_opnd);
05999 }
06000 #ifdef KEY
06001 SET_LCV_CONST(IL_IDX(IR_IDX_R(ir_idx)),
06002 CN_CONST(cn_idx),
06003 num_host_wds[TYP_LINEAR(
06004 ATD_TYPE_IDX(IL_IDX(IR_IDX_R(ir_idx))))],
06005 num_host_wds[TYP_LINEAR(
06006 CN_TYPE_IDX(cn_idx))]);
06007 #else
06008 SET_LCV_CONST(IL_IDX(IR_IDX_R(ir_idx)),
06009 CN_CONST(cn_idx),
06010 num_host_wds[TYP_LINEAR(
06011 ATD_TYPE_IDX(IL_IDX(IR_IDX_R(ir_idx))))]);
06012 #endif
06013
06014 t_idx = IR_IDX_L(ir_idx);
06015 while (t_idx != NULL_IDX) {
06016
06017 if ((IL_FLD(t_idx) == IR_Tbl_Idx) &&
06018 (IR_OPR(IL_IDX(t_idx)) == Implied_Do_Opr)) {
06019 cvrt_exp_to_pdg(IL_IDX(t_idx),
06020 IL_FLD(t_idx));
06021 }
06022 else {
06023 blank_pad_text = IL_IDX(t_idx);
06024 push_data_value(t_idx);
06025 }
06026
06027 t_idx = IL_NEXT_LIST_IDX(t_idx);
06028 }
06029 }
06030 }
06031 else {
06032 for (i = start; i >= end; i = i + inc) {
06033
06034 if (search_idx == NULL_IDX) {
06035 cn_idx = C_INT_TO_CN(NULL_IDX, i);
06036 }
06037 else {
06038 COPY_OPND(l_opnd, IL_OPND(search_idx));
06039 vv = i;
06040 cn_idx = get_next_array_expr_element(&l_opnd, &vv);
06041 COPY_OPND(IL_OPND(search_idx), l_opnd);
06042 }
06043 #ifdef KEY
06044 SET_LCV_CONST(IL_IDX(IR_IDX_R(ir_idx)),
06045 CN_CONST(cn_idx),
06046 num_host_wds[TYP_LINEAR(
06047 ATD_TYPE_IDX(IL_IDX(IR_IDX_R(ir_idx))))],
06048 num_host_wds[TYP_LINEAR(
06049 CN_TYPE_IDX(cn_idx))]);
06050 #else
06051 SET_LCV_CONST(IL_IDX(IR_IDX_R(ir_idx)),
06052 CN_CONST(cn_idx),
06053 num_host_wds[TYP_LINEAR(
06054 ATD_TYPE_IDX(IL_IDX(IR_IDX_R(ir_idx))))]);
06055 #endif
06056
06057 t_idx = IR_IDX_L(ir_idx);
06058 while (t_idx != NULL_IDX) {
06059
06060 if ((IL_FLD(t_idx) == IR_Tbl_Idx) &&
06061 (IR_OPR(IL_IDX(t_idx)) == Implied_Do_Opr)) {
06062 cvrt_exp_to_pdg(IL_IDX(t_idx),
06063 IL_FLD(t_idx));
06064 }
06065 else {
06066 blank_pad_text = IL_IDX(t_idx);
06067 push_data_value(t_idx);
06068 }
06069
06070 t_idx = IL_NEXT_LIST_IDX(t_idx);
06071 }
06072 }
06073 }
06074
06075
06076 #ifdef KEY
06077 SET_LCV_CONST(IL_IDX(IR_IDX_R(ir_idx)),
06078 CN_CONST(ATD_TMP_IDX(IL_IDX(IR_IDX_R(ir_idx)))),
06079 num_host_wds[TYP_LINEAR(
06080 ATD_TYPE_IDX(IL_IDX(IR_IDX_R(ir_idx))))],
06081 num_host_wds[TYP_LINEAR(
06082 CN_TYPE_IDX(ATD_TMP_IDX(IL_IDX(IR_IDX_R(ir_idx)))))]);
06083 #else
06084 SET_LCV_CONST(IL_IDX(IR_IDX_R(ir_idx)),
06085 CN_CONST(ATD_TMP_IDX(IL_IDX(IR_IDX_R(ir_idx)))),
06086 num_host_wds[TYP_LINEAR(
06087 ATD_TYPE_IDX(IL_IDX(IR_IDX_R(ir_idx))))]);
06088 #endif
06089
06090 }
06091 else {
06092 search_idx = IR_IDX_R(ir_idx);
06093 while (search_idx != NULL_IDX) {
06094 cvrt_exp_to_pdg(IL_IDX(search_idx),
06095 IL_FLD(search_idx));
06096
06097 search_idx = IL_NEXT_LIST_IDX(search_idx);
06098 }
06099
06100 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
06101 IR_FLD_L(ir_idx));
06102
06103 PDG_DBG_PRINT_START
06104 PDG_DBG_PRINT_C("fei_IO_list");
06105 PDG_DBG_PRINT_D("(1) list count", IR_LIST_CNT_L(ir_idx));
06106 PDG_DBG_PRINT_S("(2) io_type", p_io[io_type]);
06107 PDG_DBG_PRINT_END
06108
06109 # ifdef _ENABLE_FEI
06110 fei_IO_list(IR_LIST_CNT_L(ir_idx), io_type);
06111 # endif
06112
06113 PDG_DBG_PRINT_START
06114 PDG_DBG_PRINT_C("fei_implied_do");
06115 PDG_DBG_PRINT_END
06116
06117 # ifdef _ENABLE_FEI
06118 fei_implied_do();
06119 # endif
06120
06121 }
06122 break;
06123
06124
06125
06126
06127
06128 case Init_Opr :
06129 if ((IR_FLD_L(ir_idx) == IR_Tbl_Idx) &&
06130 (IR_OPR(IR_IDX_L(ir_idx)) == Implied_Do_Opr)) {
06131
06132 static_initialization = TRUE;
06133
06134 data_value_idx = IR_IDX_R(ir_idx);
06135 while (data_value_idx != NULL_IDX) {
06136 if (IL_FLD(data_value_idx) == IR_Tbl_Idx) {
06137 IL_LIST_CNT(data_value_idx) =
06138 CN_INT_TO_C(IR_IDX_L(IL_IDX(data_value_idx)));
06139 }
06140 else {
06141 IL_LIST_CNT(data_value_idx) = 1;
06142 }
06143 data_value_idx = IL_NEXT_LIST_IDX(data_value_idx);
06144 }
06145 data_value_idx = IR_IDX_R(ir_idx);
06146
06147 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
06148 IR_FLD_L(ir_idx));
06149
06150 static_initialization = FALSE;
06151 }
06152 else {
06153 data_attr = NULL_IDX;
06154 stack_data_object = TRUE;
06155 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
06156 IR_FLD_L(ir_idx));
06157 stack_data_object = FALSE;
06158
06159 list_idx1 = IR_IDX_R(ir_idx);
06160 stack_data_constant = TRUE;
06161 cvrt_exp_to_pdg(IL_IDX(list_idx1),
06162 IL_FLD(list_idx1));
06163 stack_data_constant = FALSE;
06164
06165 list_idx2 = IL_NEXT_LIST_IDX(list_idx1);
06166 list_idx3 = IL_NEXT_LIST_IDX(list_idx2);
06167
06168 if (TYP_TYPE(CN_TYPE_IDX(IL_IDX(list_idx1))) == Typeless ||
06169 (TYP_TYPE(CN_TYPE_IDX(IL_IDX(list_idx1))) == Character &&
06170 TYP_TYPE(ATD_TYPE_IDX(data_attr)) != Character)) {
06171 ignore_types = TRUE;
06172 }
06173 else {
06174 ignore_types = FALSE;
06175 }
06176 rep_count = CN_INT_TO_C(IL_IDX(list_idx2));
06177 stride = CN_INT_TO_C(IL_IDX(list_idx3));
06178
06179 # if defined(_TARGET_OS_MAX) || defined(_HOST32)
06180
06181
06182 if (TYP_LINEAR(CN_TYPE_IDX(IL_IDX(list_idx3))) != Integer_8) {
06183 SIGN_EXTEND(stride);
06184 }
06185 # endif
06186
06187 PDG_DBG_PRINT_START
06188 PDG_DBG_PRINT_C("fei_static_simple_init");
06189 PDG_DBG_PRINT_LLD("(1) rep_count", rep_count);
06190 PDG_DBG_PRINT_LLD("(2) stride", stride);
06191 PDG_DBG_PRINT_D("(3) ignore_types", ignore_types);
06192 PDG_DBG_PRINT_D("(4) unused", 0);
06193 PDG_DBG_PRINT_END
06194
06195 # ifdef _ENABLE_FEI
06196 fei_static_simple_init(rep_count,
06197 stride,
06198 ignore_types,
06199 0);
06200 # endif
06201 }
06202
06203 break;
06204
06205
06206
06207 case Init_Reloc_Opr :
06208 data_attr = NULL_IDX;
06209 stack_data_object = TRUE;
06210 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
06211 IR_FLD_L(ir_idx));
06212 stack_data_object = FALSE;
06213
06214 offset = 0;
06215
06216 # ifdef _INIT_RELOC_BASE_OFFSET
06217
06218 offset2.idx = IL_IDX(IL_NEXT_LIST_IDX(IR_IDX_R(ir_idx)));
06219 offset2.fld = IL_FLD(IL_NEXT_LIST_IDX(IR_IDX_R(ir_idx)));
06220
06221 COPY_OPND(opnd, IL_OPND(IR_IDX_R(ir_idx)));
06222 attr_idx = find_left_attr(&opnd);
06223 send_attr_ntry(attr_idx);
06224 offset1.idx = ATD_OFFSET_IDX(attr_idx);
06225 offset1.fld = ATD_OFFSET_FLD(attr_idx);
06226 result.idx = ATD_OFFSET_IDX(
06227 SB_FIRST_ATTR_IDX(ATD_STOR_BLK_IDX(attr_idx)));
06228 result.fld = ATD_OFFSET_FLD(
06229 SB_FIRST_ATTR_IDX(ATD_STOR_BLK_IDX(attr_idx)));
06230
06231 size_offset_binary_calc(&offset1, &result, Minus_Opr, &result);
06232 size_offset_binary_calc(&offset2, &result, Plus_Opr, &result);
06233
06234
06235
06236 if (result.fld == CN_Tbl_Idx) {
06237 offset = CN_INT_TO_C(CN_CONST(result.idx));
06238
06239 # if defined(_TARGET_OS_MAX) || defined(_HOST32)
06240 if (TYP_LINEAR(CN_TYPE_IDX(result.idx)) != Integer_8) {
06241 SIGN_EXTEND(offset);
06242 }
06243 # endif
06244 }
06245 else {
06246 offset = F_INT_TO_C(result.constant, TYP_LINEAR(result.type_idx));
06247 }
06248
06249 attr_idx = SB_FIRST_ATTR_IDX(ATD_STOR_BLK_IDX(attr_idx));
06250 send_attr_ntry(attr_idx);
06251
06252 OPND_FLD(opnd) = AT_Tbl_Idx;
06253 OPND_IDX(opnd) = attr_idx;
06254 OPND_LINE_NUM(opnd) = IR_LINE_NUM(ir_idx);
06255 OPND_COL_NUM(opnd) = IR_COL_NUM(ir_idx);
06256
06257 if (TYP_TYPE(ATD_TYPE_IDX(attr_idx)) == Character) {
06258 unused = gen_whole_substring(&opnd, 0);
06259 }
06260
06261
06262 COPY_OPND(IR_OPND_L(IL_IDX(IR_IDX_R(ir_idx))), opnd);
06263 # endif
06264
06265 cvrt_exp_to_pdg(IL_IDX(IR_IDX_R(ir_idx)),
06266 IL_FLD(IR_IDX_R(ir_idx)));
06267
06268 PDG_DBG_PRINT_START
06269 PDG_DBG_PRINT_C("fei_static_simple_reloc_init");
06270 PDG_DBG_PRINT_LLD("(1) offset", offset);
06271 PDG_DBG_PRINT_LLD("(2) rep count", (long64) 1);
06272 PDG_DBG_PRINT_D("(3) stride", TARGET_BITS_PER_WORD);
06273 PDG_DBG_PRINT_LLD("(4) bit size", (long64) 0);
06274 PDG_DBG_PRINT_D("(5) ignore_types", 1);
06275 PDG_DBG_PRINT_END
06276
06277 # ifdef _ENABLE_FEI
06278 fei_static_simple_reloc_init(offset,
06279 (long64) 1,
06280 (long64) TARGET_BITS_PER_WORD,
06281 (long64) 0,
06282 1);
06283 # endif
06284 break;
06285
06286
06287
06288 case Whole_Subscript_Opr :
06289 case Section_Subscript_Opr:
06290 case Subscript_Opr :
06291 whole_subscript = IR_WHOLE_ARRAY(ir_idx);
06292 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
06293 IR_FLD_L(ir_idx));
06294 whole_subscript = FALSE;
06295
06296
06297 if (IR_OPR(ir_idx) == Whole_Subscript_Opr &&
06298 !processing_io_stmt &&
06299 IR_CONTIG_ARRAY(ir_idx) != 0) {
06300
06301
06302
06303
06304 PDG_DBG_PRINT_START
06305 PDG_DBG_PRINT_C("fei_as_ref");
06306 PDG_DBG_PRINT_END
06307
06308 # ifdef _ENABLE_FEI
06309 fei_as_ref(null_type);
06310 # endif
06311 break;
06312 }
06313
06314 attr_idx = find_base_attr(&IR_OPND_L(ir_idx), &line, &col);
06315 bound_idx = ATD_ARRAY_IDX(attr_idx);
06316 # if defined(_F_MINUS_MINUS) && defined(_TARGET_OS_MAX)
06317 pe_bd_idx = ATD_PE_ARRAY_IDX(attr_idx);
06318 # endif
06319 base_attr = find_left_attr(&(IR_OPND_L(ir_idx)));
06320
06321 bound_chk = (cdir_switches.bounds ||
06322 ATD_BOUNDS_CHECK(base_attr)) &&
06323 !ATD_NOBOUNDS_CHECK(base_attr);
06324
06325 bound_chk &= ! (IR_WHOLE_ARRAY(ir_idx));
06326
06327 if (IR_BOUNDS_DONE(ir_idx)) {
06328 bound_chk = FALSE;
06329 }
06330
06331 next_idx = IR_IDX_R(ir_idx);
06332 dim = IR_LIST_CNT_R(ir_idx);
06333 while (dim != 1) {
06334 next_idx = IL_NEXT_LIST_IDX(next_idx);
06335 dim = dim - 1;
06336 }
06337
06338 dim = IR_LIST_CNT_R(ir_idx);
06339 ss = 0;
06340 while (dim > 0) {
06341 if (stack_data_object) {
06342 COPY_OPND(l_opnd, IL_OPND(next_idx));
06343
06344 vv = 1;
06345 cn_idx = get_next_array_expr_element(&l_opnd, &vv);
06346 COPY_OPND(IL_OPND(next_idx), l_opnd);
06347 static_subscripts[ss] = CN_INT_TO_C(cn_idx);
06348
06349 # if defined(_TARGET_OS_MAX) || defined(_HOST32)
06350 if (TYP_LINEAR(CN_TYPE_IDX(cn_idx)) != Integer_8) {
06351 SIGN_EXTEND(static_subscripts[ss]);
06352 }
06353 # endif
06354 goto CONTINUE;
06355 }
06356
06357 cvrt_exp_to_pdg(IL_IDX(next_idx),
06358 IL_FLD(next_idx));
06359
06360 if (ATD_IM_A_DOPE(attr_idx)) {
06361 cvrt_exp_to_pdg(IR_IDX_L(IR_IDX_L(ir_idx)),
06362 IR_FLD_L(IR_IDX_L(ir_idx)));
06363
06364 PDG_DBG_PRINT_START
06365 PDG_DBG_PRINT_C("fei_get_dv_low_bnd");
06366 PDG_DBG_PRINT_D("(1) dim", dim);
06367 PDG_DBG_PRINT_D("(2) expand immed", EXPAND);
06368 PDG_DBG_PRINT_END
06369 # ifdef _ENABLE_FEI
06370 fei_get_dv_low_bnd(dim, EXPAND);
06371 # endif
06372 }
06373 # if defined(_F_MINUS_MINUS) && defined(_TARGET_OS_MAX)
06374 else if (IL_PE_SUBSCRIPT(next_idx)) {
06375 cvrt_exp_to_pdg(CN_INTEGER_ONE_IDX,
06376 CN_Tbl_Idx);
06377 }
06378 # endif
06379 else {
06380 cvrt_exp_to_pdg(BD_LB_IDX(bound_idx, dim),
06381 BD_LB_FLD(bound_idx, dim));
06382 }
06383
06384 if (ATD_IM_A_DOPE(attr_idx)) {
06385 cvrt_exp_to_pdg(IR_IDX_L(IR_IDX_L(ir_idx)),
06386 IR_FLD_L(IR_IDX_L(ir_idx)));
06387
06388 PDG_DBG_PRINT_START
06389 PDG_DBG_PRINT_C("fei_get_dv_extent");
06390 PDG_DBG_PRINT_D("(1) dim", dim);
06391 PDG_DBG_PRINT_D("(2) expand immed", EXPAND);
06392 PDG_DBG_PRINT_END
06393 # ifdef _ENABLE_FEI
06394 fei_get_dv_extent(dim, EXPAND);
06395 # endif
06396 }
06397 # if defined(_F_MINUS_MINUS) && defined(_TARGET_OS_MAX)
06398 else if (IL_PE_SUBSCRIPT(next_idx)) {
06399 cvrt_exp_to_pdg(BD_LEN_IDX(pe_bd_idx),
06400 BD_LEN_FLD(pe_bd_idx));
06401 }
06402 # endif
06403 else {
06404 cvrt_exp_to_pdg(BD_XT_IDX(bound_idx, dim),
06405 BD_XT_FLD(bound_idx, dim));
06406 }
06407
06408 if (ATD_IM_A_DOPE(attr_idx)) {
06409 cvrt_exp_to_pdg(IR_IDX_L(IR_IDX_L(ir_idx)),
06410 IR_FLD_L(IR_IDX_L(ir_idx)));
06411
06412 PDG_DBG_PRINT_START
06413 PDG_DBG_PRINT_C("fei_get_dv_str_mult");
06414 PDG_DBG_PRINT_D("(1) dim", dim);
06415 PDG_DBG_PRINT_D("(2) expand immed", EXPAND);
06416 PDG_DBG_PRINT_END
06417 # ifdef _ENABLE_FEI
06418 fei_get_dv_str_mult(dim, EXPAND);
06419 # endif
06420 }
06421 # if defined(_EXTENDED_CRI_CHAR_POINTER)
06422 else if (AT_OBJ_CLASS(attr_idx) == Data_Obj &&
06423 ATD_CLASS(attr_idx) == CRI_Pointee &&
06424 TYP_TYPE(ATD_TYPE_IDX(attr_idx)) == Character &&
06425 TYP_CHAR_CLASS(ATD_TYPE_IDX(attr_idx)) ==
06426 Assumed_Size_Char) {
06427 cvrt_exp_to_pdg(BD_SM_IDX(bound_idx, dim),
06428 BD_SM_FLD(bound_idx, dim));
06429
06430 cvrt_exp_to_pdg(attr_idx, AT_Tbl_Idx);
06431
06432 basic = get_basic_type(ATD_TYPE_IDX(attr_idx),
06433 ATD_ALIGNMENT(attr_idx),
06434 attr_idx);
06435
06436 PDG_DBG_PRINT_START
06437 PDG_DBG_PRINT_C("fei_len");
06438 PDG_DBG_PRINT_END
06439
06440 # ifdef _ENABLE_FEI
06441 fei_len(basic);
06442 # endif
06443
06444 basic = get_basic_type(INTEGER_DEFAULT_TYPE,
06445 type_alignment_tbl[INTEGER_DEFAULT_TYPE],
06446 NULL_IDX);
06447
06448 PDG_DBG_PRINT_START
06449 PDG_DBG_PRINT_C("fei_mult");
06450 PDG_DBG_PRINT_END
06451
06452 # ifdef _ENABLE_FEI
06453 fei_mult(basic);
06454 # endif
06455 }
06456 # endif
06457 # if defined(_F_MINUS_MINUS) && defined(_TARGET_OS_MAX)
06458 else if (IL_PE_SUBSCRIPT(next_idx)) {
06459 cvrt_exp_to_pdg(CN_INTEGER_ONE_IDX,
06460 CN_Tbl_Idx);
06461 }
06462 # endif
06463 else {
06464 cvrt_exp_to_pdg(BD_SM_IDX(bound_idx, dim),
06465 BD_SM_FLD(bound_idx, dim));
06466 }
06467
06468 if (BD_ARRAY_CLASS(bound_idx) == Assumed_Size) {
06469 if (BD_RANK(bound_idx) == IR_LIST_CNT_R(ir_idx) && ss == 0) {
06470 bound_chk = FALSE;
06471 }
06472 }
06473
06474 PDG_DBG_PRINT_START
06475 PDG_DBG_PRINT_C("fei_subscr_size");
06476 PDG_DBG_PRINT_T("(1) type", pdg_type_void);
06477 PDG_DBG_PRINT_D("(2) bound_chk", bound_chk);
06478 PDG_DBG_PRINT_END
06479 # ifdef _ENABLE_FEI
06480 fei_subscr_size(pdg_type_void, bound_chk);
06481 # endif
06482
06483 if (ATD_IM_A_DOPE(attr_idx)) {
06484 PDG_DBG_PRINT_START
06485 PDG_DBG_PRINT_C("fei_nseq_subscr");
06486 PDG_DBG_PRINT_T("(1) type", null_type);
06487 PDG_DBG_PRINT_END
06488 # ifdef _ENABLE_FEI
06489 fei_nseq_subscr(null_type);
06490 # endif
06491 }
06492 else {
06493 PDG_DBG_PRINT_START
06494 PDG_DBG_PRINT_C("fei_seq_subscr");
06495 PDG_DBG_PRINT_T("(1) type", null_type);
06496 PDG_DBG_PRINT_END
06497 # ifdef _ENABLE_FEI
06498 fei_seq_subscr(null_type);
06499 # endif
06500 }
06501
06502 CONTINUE:
06503 next_idx = IL_PREV_LIST_IDX(next_idx);
06504 dim = dim - 1;
06505 ss = ss + 1;
06506 }
06507
06508 if (stack_data_object) {
06509 PDG_DBG_PRINT_START
06510 PDG_DBG_PRINT_C("fei_static_subscripts");
06511 for (i = 0; i < ss; i++) {
06512 PDG_DBG_PRINT_LLD("static subscript", static_subscripts[i]);
06513 }
06514 PDG_DBG_PRINT_END
06515
06516 # ifdef _ENABLE_FEI
06517 fei_static_subscripts(static_subscripts);
06518 # endif
06519 }
06520 break;
06521
06522
06523
06524
06525
06526 case Present_Opr :
06527 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
06528 IR_FLD_L(ir_idx));
06529
06530 PDG_DBG_PRINT_START
06531 PDG_DBG_PRINT_C("fei_present");
06532 PDG_DBG_PRINT_END
06533
06534 # ifdef _ENABLE_FEI
06535 fei_present();
06536 # endif
06537 break;
06538
06539
06540
06541
06542 case Argchck_Present_Opr :
06543 PDG_DBG_PRINT_START
06544 PDG_DBG_PRINT_C("fei_argchk");
06545 PDG_DBG_PRINT_END
06546
06547 # ifdef _ENABLE_FEI
06548 fei_argchk();
06549 # endif
06550
06551 break;
06552
06553
06554
06555
06556 case Argchck_Loc_Opr :
06557 PDG_DBG_PRINT_START
06558 PDG_DBG_PRINT_C("fei_argloc");
06559 PDG_DBG_PRINT_END
06560
06561 # ifdef _ENABLE_FEI
06562 fei_argloc();
06563 # endif
06564
06565 break;
06566
06567
06568
06569
06570
06571 case Aloc_Opr :
06572 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
06573 IR_FLD_L(ir_idx));
06574
06575 global_attr_idx = NULL_IDX;
06576 global_attr_idx = find_left_attr(&(IR_OPND_L(ir_idx)));
06577 basic = get_basic_type(IR_TYPE_IDX(ir_idx), 0, NULL_IDX);
06578 global_attr_idx = NULL_IDX;
06579
06580 PDG_DBG_PRINT_START
06581 PDG_DBG_PRINT_C("fei_arg_addr");
06582 PDG_DBG_PRINT_END
06583
06584 # ifdef _ENABLE_FEI
06585 fei_arg_addr(basic);
06586 # endif
06587 break;
06588
06589
06590
06591
06592
06593
06594 case Dv_Deref_Opr :
06595 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
06596 IR_FLD_L(ir_idx));
06597
06598 PDG_DBG_PRINT_START
06599 PDG_DBG_PRINT_C("fei_dv_deref");
06600 PDG_DBG_PRINT_END
06601
06602 # ifdef _ENABLE_FEI
06603 fei_dv_deref(null_type);
06604 # endif
06605 break;
06606
06607
06608
06609
06610
06611 case Dv_Whole_Def_Opr :
06612 processing_call = processing_call + 1;
06613
06614 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
06615 IR_FLD_L(ir_idx));
06616
06617 PDG_DBG_PRINT_START
06618 PDG_DBG_PRINT_C("fei_dv_def");
06619 PDG_DBG_PRINT_D("dim", IR_DV_DIM(ir_idx));
06620 PDG_DBG_PRINT_END
06621
06622 # ifdef _ENABLE_FEI
06623 #ifdef KEY
06624 fei_dv_def(IR_DV_DIM(ir_idx), IR_DV_N_ALLOC_CPNT(ir_idx));
06625 #else
06626 fei_dv_def(IR_DV_DIM(ir_idx));
06627 #endif
06628 # endif
06629 processing_call = processing_call - 1;
06630 break;
06631
06632
06633
06634
06635
06636
06637
06638
06639 case Dv_Access_Stride_Mult :
06640 case Dv_Access_Extent :
06641 case Dv_Access_Low_Bound :
06642 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
06643 IR_FLD_L(ir_idx));
06644
06645 switch (IR_OPR(ir_idx)) {
06646 case Dv_Access_Stride_Mult :
06647 PDG_DBG_PRINT_START
06648 PDG_DBG_PRINT_C("fei_get_dv_str_mult");
06649 PDG_DBG_PRINT_D("(1) dim", IR_DV_DIM(ir_idx));
06650 PDG_DBG_PRINT_D("(2) expand", EXPAND);
06651 PDG_DBG_PRINT_END
06652 # ifdef _ENABLE_FEI
06653 fei_get_dv_str_mult(IR_DV_DIM(ir_idx), EXPAND);
06654 # endif
06655 break;
06656
06657 case Dv_Access_Extent :
06658 PDG_DBG_PRINT_START
06659 PDG_DBG_PRINT_C("fei_get_dv_extent");
06660 PDG_DBG_PRINT_D("(1) dim", IR_DV_DIM(ir_idx));
06661 PDG_DBG_PRINT_D("(2) expand", EXPAND);
06662 PDG_DBG_PRINT_END
06663 # ifdef _ENABLE_FEI
06664 fei_get_dv_extent(IR_DV_DIM(ir_idx), EXPAND);
06665 # endif
06666 break;
06667
06668 case Dv_Access_Low_Bound :
06669 PDG_DBG_PRINT_START
06670 PDG_DBG_PRINT_C("fei_get_dv_low_bnd");
06671 PDG_DBG_PRINT_D("(1) dim", IR_DV_DIM(ir_idx));
06672 PDG_DBG_PRINT_D("(2) expand", EXPAND);
06673 PDG_DBG_PRINT_END
06674 # ifdef _ENABLE_FEI
06675 fei_get_dv_low_bnd(IR_DV_DIM(ir_idx), EXPAND);
06676 # endif
06677 break;
06678 }
06679 break;
06680
06681
06682
06683
06684
06685
06686
06687
06688 case Dv_Set_Stride_Mult :
06689 case Dv_Set_Extent :
06690 case Dv_Set_Low_Bound :
06691 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
06692 IR_FLD_L(ir_idx));
06693
06694 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
06695 IR_FLD_R(ir_idx));
06696
06697 switch (IR_OPR(ir_idx)) {
06698 case Dv_Set_Stride_Mult :
06699 PDG_DBG_PRINT_START
06700 PDG_DBG_PRINT_C("fei_set_dv_str_mult");
06701 PDG_DBG_PRINT_D("(1) dim", IR_DV_DIM(ir_idx));
06702 PDG_DBG_PRINT_END
06703 # ifdef _ENABLE_FEI
06704 fei_set_dv_str_mult(IR_DV_DIM(ir_idx));
06705 # endif
06706 break;
06707
06708 case Dv_Set_Extent :
06709 PDG_DBG_PRINT_START
06710 PDG_DBG_PRINT_C("fei_set_dv_extent");
06711 PDG_DBG_PRINT_D("(1) dim", IR_DV_DIM(ir_idx));
06712 PDG_DBG_PRINT_END
06713 # ifdef _ENABLE_FEI
06714 fei_set_dv_extent(IR_DV_DIM(ir_idx));
06715 # endif
06716 break;
06717
06718 case Dv_Set_Low_Bound :
06719 PDG_DBG_PRINT_START
06720 PDG_DBG_PRINT_C("fei_set_dv_low_bnd");
06721 PDG_DBG_PRINT_D("(1) dim", IR_DV_DIM(ir_idx));
06722 PDG_DBG_PRINT_END
06723 # ifdef _ENABLE_FEI
06724 fei_set_dv_low_bnd(IR_DV_DIM(ir_idx));
06725 # endif
06726 break;
06727 }
06728 break;
06729
06730
06731
06732
06733
06734
06735
06736 case Dv_Set_Base_Addr :
06737 case Dv_Set_El_Len :
06738 case Dv_Set_Assoc :
06739 case Dv_Set_Ptr_Alloc :
06740 case Dv_Set_P_Or_A :
06741 case Dv_Set_A_Contig :
06742 case Dv_Set_N_Dim :
06743 case Dv_Set_Typ_Code :
06744 case Dv_Set_Orig_Base :
06745 case Dv_Set_Orig_Size :
06746 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
06747 IR_FLD_L(ir_idx));
06748
06749 if (IR_FLD_R(ir_idx) != NO_Tbl_Idx) {
06750 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
06751 IR_FLD_R(ir_idx));
06752 }
06753
06754 #ifndef KEY
06755 switch (IR_OPR(ir_idx)) {
06756 case Dv_Set_Base_Addr :
06757 fld = 1;
06758 break;
06759 case Dv_Set_El_Len :
06760 fld = 2;
06761 break;
06762 case Dv_Set_Assoc :
06763 fld = 3;
06764 break;
06765 case Dv_Set_Ptr_Alloc :
06766 fld = 4;
06767 break;
06768 case Dv_Set_P_Or_A :
06769 fld = 5;
06770 break;
06771 case Dv_Set_A_Contig :
06772 fld = 6;
06773 break;
06774 case Dv_Set_N_Dim :
06775 fld = 7;
06776 break;
06777 case Dv_Set_Typ_Code :
06778 fld = 8;
06779 break;
06780 case Dv_Set_Orig_Base :
06781 fld = 9;
06782 break;
06783 case Dv_Set_Orig_Size :
06784 fld = 10;
06785 break;
06786 }
06787 #endif
06788
06789 PDG_DBG_PRINT_START
06790 PDG_DBG_PRINT_C("fei_set_dv_hdr_fld");
06791 PDG_DBG_PRINT_D("(1) field num", fld);
06792 PDG_DBG_PRINT_END
06793 # ifdef _ENABLE_FEI
06794 # ifdef KEY
06795 fei_set_dv_hdr_fld(opr_to_dv_hdr_fld(ir_idx));
06796 # else
06797 fei_set_dv_hdr_fld(fld);
06798 # endif
06799 # endif
06800 break;
06801
06802
06803
06804
06805
06806 case Dv_Access_Base_Addr :
06807 case Dv_Access_El_Len :
06808 case Dv_Access_Assoc :
06809 case Dv_Access_Ptr_Alloc :
06810 case Dv_Access_P_Or_A :
06811 case Dv_Access_A_Contig :
06812 case Dv_Access_N_Dim :
06813 case Dv_Access_Typ_Code :
06814 case Dv_Access_Orig_Base :
06815 case Dv_Access_Orig_Size :
06816 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
06817 IR_FLD_L(ir_idx));
06818
06819 if (IR_FLD_R(ir_idx) != NO_Tbl_Idx) {
06820 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
06821 IR_FLD_R(ir_idx));
06822 }
06823
06824 #ifndef KEY
06825 switch (IR_OPR(ir_idx)) {
06826 case Dv_Access_Base_Addr :
06827 fld = 1;
06828 break;
06829 case Dv_Access_El_Len :
06830 fld = 2;
06831 break;
06832 case Dv_Access_Assoc :
06833 fld = 3;
06834 break;
06835 case Dv_Access_Ptr_Alloc :
06836 fld = 4;
06837 break;
06838 case Dv_Access_P_Or_A :
06839 fld = 5;
06840 break;
06841 case Dv_Access_A_Contig :
06842 fld = 6;
06843 break;
06844 case Dv_Access_N_Dim :
06845 fld = 7;
06846 break;
06847 case Dv_Access_Typ_Code :
06848 fld = 8;
06849 break;
06850 case Dv_Access_Orig_Base :
06851 fld = 9;
06852 break;
06853 case Dv_Access_Orig_Size :
06854 fld = 10;
06855 break;
06856 }
06857 #endif
06858
06859 PDG_DBG_PRINT_START
06860 PDG_DBG_PRINT_C("fei_get_dv_hdr_fld");
06861 PDG_DBG_PRINT_D("(1) field num", fld);
06862 PDG_DBG_PRINT_END
06863 # ifdef _ENABLE_FEI
06864 # ifdef KEY
06865 fei_get_dv_hdr_fld(opr_to_dv_hdr_fld(ir_idx));
06866 # else
06867 fei_get_dv_hdr_fld(fld);
06868 # endif
06869 # endif
06870 break;
06871
06872
06873
06874
06875
06876 case Allocate_Opr :
06877 case Deallocate_Opr :
06878
06879 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
06880 IR_FLD_R(ir_idx));
06881
06882 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
06883 IR_FLD_L(ir_idx));
06884
06885 PDG_DBG_PRINT_START
06886 PDG_DBG_PRINT_C("fei_allocate");
06887 PDG_DBG_PRINT_D("(1) list count", IR_LIST_CNT_L(ir_idx) + 3);
06888 PDG_DBG_PRINT_END
06889
06890 # ifdef _ENABLE_FEI
06891 fei_allocate(IR_LIST_CNT_L(ir_idx) + 3);
06892 # endif
06893 break;
06894
06895
06896
06897
06898 case Call_Opr :
06899 processing_call = processing_call + 1;
06900
06901 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
06902 IR_FLD_L(ir_idx));
06903
06904 if (IR_IDX_R(ir_idx) != NULL_IDX &&
06905 IR_LIST_CNT_R(ir_idx) > 0) {
06906 #ifdef KEY
06907
06908
06909
06910
06911
06912
06913
06914
06915
06916
06917
06918
06919
06920 if (IR_FLD_R(ir_idx) == IL_Tbl_Idx) {
06921 for (int arg_il_idx = IR_IDX_R(ir_idx);
06922 arg_il_idx != NULL_IDX;
06923 arg_il_idx = IL_NEXT_LIST_IDX(arg_il_idx)) {
06924 int arg_idx = IL_IDX(arg_il_idx);
06925 int arg_fld = IL_FLD(arg_il_idx);
06926 cvrt_exp_to_pdg(arg_idx, arg_fld);
06927 if (arg_fld == IR_Tbl_Idx && IR_OPR(arg_idx) == Subscript_Opr) {
06928 fei_array_element_by_value();
06929 }
06930 }
06931 }
06932 else
06933 #endif
06934 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
06935 IR_FLD_R(ir_idx));
06936 }
06937
06938 if (IR_IDX_R(ir_idx) == NULL_IDX) {
06939 number_actual_args = 0;
06940 }
06941 else {
06942 number_actual_args = IR_LIST_CNT_R(ir_idx);
06943 }
06944
06945 if (ATP_PGM_UNIT(IR_IDX_L(ir_idx)) == Subroutine ||
06946 #ifdef KEY
06947 special_case_fcn_to_sub(IR_IDX_L(ir_idx)) ||
06948 #endif
06949 ATP_EXTRA_DARG(IR_IDX_L(ir_idx))) {
06950 type_desc = pdg_type_void;
06951
06952 if (ATP_HAS_ALT_RETURN(IR_IDX_L(ir_idx))) {
06953 type_desc = get_basic_type(CG_INTEGER_DEFAULT_TYPE,
06954 type_alignment_tbl[CG_INTEGER_DEFAULT_TYPE],
06955 NULL_IDX);
06956 }
06957 }
06958 else {
06959 type_desc = get_type_desc(IR_IDX_L(ir_idx));
06960 }
06961
06962 flags = 0;
06963 flags |= ATP_DOES_NOT_RETURN(IR_IDX_L(ir_idx))
06964 << FEI_CALL_DOES_NOT_RETURN;
06965
06966
06967
06968
06969 PDG_DBG_PRINT_START
06970 PDG_DBG_PRINT_C("fei_call");
06971 PDG_DBG_PRINT_S("AT_OBJ_NAME", AT_OBJ_NAME_PTR(IR_IDX_L(ir_idx)));
06972 PDG_DBG_PRINT_D("(1) num actual args", number_actual_args);
06973 PDG_DBG_PRINT_T("(2) type", type_desc);
06974 PDG_DBG_PRINT_S("(3) call type", "By_Value");
06975 PDG_DBG_PRINT_S("(4) alt return", p_boolean[FALSE]);
06976 PDG_DBG_PRINT_D("(5) IR_INLINE_STATE", IR_INLINE_STATE(ir_idx));
06977 PDG_DBG_PRINT_LLO("(6) flags", flags);
06978 PDG_DBG_PRINT_END
06979
06980 # ifdef _ENABLE_FEI
06981 fei_call(number_actual_args,
06982 type_desc,
06983 By_Value_Call,
06984 FALSE,
06985 IR_INLINE_STATE(ir_idx),
06986 flags);
06987 # endif
06988 processing_call = processing_call - 1;
06989 break;
06990
06991
06992
06993
06994 case Br_Uncond_Opr :
06995 send_attr_ntry(IR_IDX_R(ir_idx));
06996
06997 PDG_DBG_PRINT_START
06998 PDG_DBG_PRINT_C("fei_goto");
06999 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX", PDG_AT_IDX(IR_IDX_R(ir_idx)));
07000 PDG_DBG_PRINT_END
07001
07002 # ifdef _ENABLE_FEI
07003 fei_goto(PDG_AT_IDX(IR_IDX_R(ir_idx)));
07004 # endif
07005 break;
07006
07007
07008
07009
07010
07011 case Br_True_Opr :
07012 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
07013 IR_FLD_L(ir_idx));
07014
07015 send_attr_ntry(IR_IDX_R(ir_idx));
07016
07017 PDG_DBG_PRINT_START
07018 PDG_DBG_PRINT_C("fei_brtrue");
07019 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX", PDG_AT_IDX(IR_IDX_R(ir_idx)));
07020 PDG_DBG_PRINT_END
07021
07022 # ifdef _ENABLE_FEI
07023 fei_brtrue(PDG_AT_IDX(IR_IDX_R(ir_idx)));
07024 # endif
07025 break;
07026
07027
07028 case If_Opr:
07029 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
07030 IR_FLD_L(ir_idx));
07031
07032 PDG_DBG_PRINT_START
07033 PDG_DBG_PRINT_C("fei_if");
07034 PDG_DBG_PRINT_END
07035 # ifdef _HIGH_LEVEL_IF_FORM
07036 # ifdef _ENABLE_FEI
07037 fei_if();
07038 # endif
07039 # endif
07040 break;
07041
07042
07043 case Else_Opr:
07044
07045 PDG_DBG_PRINT_START
07046 PDG_DBG_PRINT_C("fei_else");
07047 PDG_DBG_PRINT_END
07048 # ifdef _HIGH_LEVEL_IF_FORM
07049 # ifdef _ENABLE_FEI
07050 fei_else();
07051 # endif
07052 # endif
07053 break;
07054
07055 case Endif_Opr:
07056
07057 PDG_DBG_PRINT_START
07058 PDG_DBG_PRINT_C("fei_endif");
07059 PDG_DBG_PRINT_END
07060 # ifdef _HIGH_LEVEL_IF_FORM
07061 # ifdef _ENABLE_FEI
07062 fei_endif();
07063 # endif
07064 # endif
07065 break;
07066
07067
07068
07069 case Br_Aif_Opr :
07070 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
07071 IR_FLD_L(ir_idx));
07072
07073 send_attr_ntry(IL_IDX(IR_IDX_R(ir_idx)));
07074
07075 send_attr_ntry(IL_IDX(IL_NEXT_LIST_IDX(IR_IDX_R(ir_idx))));
07076
07077 send_attr_ntry(IL_IDX(IL_NEXT_LIST_IDX(
07078 IL_NEXT_LIST_IDX(IR_IDX_R(ir_idx)))));
07079
07080 PDG_DBG_PRINT_START
07081 PDG_DBG_PRINT_C("fei_arith_goto");
07082 PDG_DBG_PRINT_LD("label idx1", PDG_AT_IDX(IL_IDX(IR_IDX_R(ir_idx))));
07083 PDG_DBG_PRINT_LD("label idx2", PDG_AT_IDX(IL_IDX(IL_NEXT_LIST_IDX(
07084 IR_IDX_R(ir_idx)))));
07085 PDG_DBG_PRINT_LD("label idx3", PDG_AT_IDX(IL_IDX(IL_NEXT_LIST_IDX(
07086 IL_NEXT_LIST_IDX(IR_IDX_R(ir_idx))))));
07087 PDG_DBG_PRINT_END
07088
07089 # ifdef _ENABLE_FEI
07090 fei_arith_goto(
07091 PDG_AT_IDX(IL_IDX(IR_IDX_R(ir_idx))),
07092 PDG_AT_IDX(IL_IDX(IL_NEXT_LIST_IDX(IR_IDX_R(ir_idx)))),
07093 PDG_AT_IDX(IL_IDX(IL_NEXT_LIST_IDX(
07094 IL_NEXT_LIST_IDX(IR_IDX_R(ir_idx))))));
07095 # endif
07096 break;
07097
07098
07099
07100
07101
07102 case Br_Asg_Opr :
07103 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
07104 IR_FLD_L(ir_idx));
07105
07106 list_cnt = 0;
07107 i = SCP_ASSIGN_LBL_CHAIN(curr_scp_idx);
07108
07109 while (i != NULL_IDX) {
07110 send_attr_ntry(i);
07111
07112 PDG_DBG_PRINT_START
07113 PDG_DBG_PRINT_C("fei_label_ref");
07114 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX", PDG_AT_IDX(i));
07115 PDG_DBG_PRINT_END
07116
07117 # ifdef _ENABLE_FEI
07118 fei_label_ref(PDG_AT_IDX(i));
07119 # endif
07120
07121 list_cnt = list_cnt + 1;
07122 i = ATL_NEXT_ASG_LBL_IDX(i);
07123 }
07124
07125 PDG_DBG_PRINT_START
07126 PDG_DBG_PRINT_C("fei_indirect_goto");
07127 PDG_DBG_PRINT_D("(1) list_cnt", list_cnt);
07128 PDG_DBG_PRINT_D("(2) TRUE", TRUE);
07129 PDG_DBG_PRINT_END
07130
07131 # ifdef _ENABLE_FEI
07132 fei_indirect_goto(list_cnt, TRUE);
07133 # endif
07134 break;
07135
07136
07137
07138
07139 case Br_Index_Opr :
07140 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
07141 IR_FLD_L(ir_idx));
07142
07143 list_cnt = IR_LIST_CNT_R(ir_idx);
07144 tmp_ir_idx = IR_IDX_R(ir_idx);
07145
07146 for (i = 0; i < list_cnt; i++) {
07147 send_attr_ntry(IL_IDX(tmp_ir_idx));
07148
07149 PDG_DBG_PRINT_START
07150 PDG_DBG_PRINT_C("fei_label_ref");
07151 PDG_DBG_PRINT_LD("(1) label idx", PDG_AT_IDX(IL_IDX(tmp_ir_idx)));
07152 PDG_DBG_PRINT_END
07153
07154 # ifdef _ENABLE_FEI
07155 fei_label_ref(PDG_AT_IDX(IL_IDX(tmp_ir_idx)));
07156 # endif
07157 tmp_ir_idx = IL_NEXT_LIST_IDX(tmp_ir_idx);
07158 }
07159
07160 PDG_DBG_PRINT_START
07161 PDG_DBG_PRINT_C("fei_indirect_goto");
07162 PDG_DBG_PRINT_D("(1) list cnt", list_cnt);
07163 PDG_DBG_PRINT_D("(2) FALSE", FALSE);
07164 PDG_DBG_PRINT_END
07165
07166 # ifdef _ENABLE_FEI
07167 fei_indirect_goto(list_cnt, FALSE);
07168 # endif
07169 break;
07170
07171
07172
07173
07174
07175
07176 case Where_Opr :
07177 if (IR_LIST_CNT_L(ir_idx) == 4) {
07178
07179 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
07180 proc_idx = IR_IDX_L(ir_idx);
07181 lhs_idx = IL_NEXT_LIST_IDX(proc_idx);
07182 mask_idx = IL_NEXT_LIST_IDX(lhs_idx);
07183 rhs_idx = IL_NEXT_LIST_IDX(mask_idx);
07184 cvrt_exp_to_pdg(IL_IDX(proc_idx),
07185 IL_FLD(proc_idx));
07186
07187 cvrt_exp_to_pdg(IL_IDX(lhs_idx),
07188 IL_FLD(lhs_idx));
07189
07190 cvrt_exp_to_pdg(IL_IDX(rhs_idx),
07191 IL_FLD(rhs_idx));
07192
07193 cvrt_exp_to_pdg(IL_IDX(mask_idx),
07194 IL_FLD(mask_idx));
07195 # else
07196 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
07197 IR_FLD_L(ir_idx));
07198 # endif
07199
07200 PDG_DBG_PRINT_START
07201 PDG_DBG_PRINT_C("fei_where");
07202 PDG_DBG_PRINT_END
07203
07204 # ifdef _ENABLE_FEI
07205 fei_where(TRUE, IR_INLINE_STATE(ir_idx));
07206 # endif
07207 }
07208 else {
07209 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
07210 lhs_idx = IR_IDX_L(ir_idx);
07211 mask_idx = IL_NEXT_LIST_IDX(lhs_idx);
07212 rhs_idx = IL_NEXT_LIST_IDX(mask_idx);
07213 cvrt_exp_to_pdg(IL_IDX(lhs_idx),
07214 IL_FLD(lhs_idx));
07215
07216 cvrt_exp_to_pdg(IL_IDX(rhs_idx),
07217 IL_FLD(rhs_idx));
07218
07219 cvrt_exp_to_pdg(IL_IDX(mask_idx),
07220 IL_FLD(mask_idx));
07221 # else
07222 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
07223 IR_FLD_L(ir_idx));
07224 # endif
07225
07226 PDG_DBG_PRINT_START
07227 PDG_DBG_PRINT_C("fei_where");
07228 PDG_DBG_PRINT_END
07229
07230 # ifdef _ENABLE_FEI
07231 fei_where(FALSE, 0);
07232 # endif
07233 }
07234 break;
07235
07236
07237 case Where_Cnstrct_Opr:
07238 case Else_Where_Mask_Opr:
07239 case Else_Where_Opr:
07240
07241 break;
07242
07243
07244 case Bounds_Cdir_Opr :
07245 case Nobounds_Cdir_Opr :
07246 bounds_cdir_handler(ir_idx);
07247 break;
07248
07249
07250
07251
07252
07253 case Case_Cmic_Opr:
07254 PDG_DBG_PRINT_START
07255 PDG_DBG_PRINT_C("fei_par_case");
07256 PDG_DBG_PRINT_D("(1) cmic vpr idx", case_cmic_vpr_idx);
07257 PDG_DBG_PRINT_D("(2) line num", IR_LINE_NUM(ir_idx));
07258 PDG_DBG_PRINT_END
07259
07260 # ifdef _ENABLE_FEI
07261 task_tbl_idx = fei_par_case(case_cmic_vpr_idx,
07262 IR_LINE_NUM(ir_idx));
07263 # endif
07264
07265 if (case_cmic_vpr_idx == NULL_IDX) {
07266 case_cmic_vpr_idx = task_tbl_idx;
07267 }
07268 break;
07269
07270
07271
07272
07273
07274
07275
07276 case Endcase_Cmic_Opr:
07277 PDG_DBG_PRINT_START
07278 PDG_DBG_PRINT_C("fei_par_endcase");
07279 PDG_DBG_PRINT_D("(1) cmic vpr idx", case_cmic_vpr_idx);
07280 PDG_DBG_PRINT_D("(2) line num", IR_LINE_NUM(ir_idx));
07281 PDG_DBG_PRINT_END
07282
07283 # ifdef _ENABLE_FEI
07284 fei_par_endcase(case_cmic_vpr_idx, IR_LINE_NUM(ir_idx));
07285 # endif
07286
07287 case_cmic_vpr_idx = NULL_IDX;
07288 break;
07289
07290
07291
07292
07293 case Send_Cmic_Opr:
07294 if (IR_FLD_L(ir_idx) == CN_Tbl_Idx ||
07295 IR_FLD_L(ir_idx) == AT_Tbl_Idx) {
07296 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
07297 IR_FLD_L(ir_idx));
07298 point = 1;
07299 }
07300
07301
07302 if (IR_FLD_R(ir_idx) == AT_Tbl_Idx) {
07303 send_attr_ntry(IR_IDX_R(ir_idx));
07304 task_if_idx = PDG_AT_IDX(IR_IDX_R(ir_idx));
07305 }
07306
07307 PDG_DBG_PRINT_START
07308 PDG_DBG_PRINT_C("fei_task_send");
07309 PDG_DBG_PRINT_LD("(1) point", point);
07310 PDG_DBG_PRINT_D("(2) task_if_idx", task_if_idx);
07311 PDG_DBG_PRINT_END
07312
07313 # ifdef _ENABLE_FEI
07314 fei_task_send(point, task_if_idx);
07315 # endif
07316
07317 break;
07318
07319
07320
07321
07322 case Wait_Cmic_Opr:
07323 if (IR_FLD_L(ir_idx) == CN_Tbl_Idx ||
07324 IR_FLD_L(ir_idx) == AT_Tbl_Idx) {
07325 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
07326 IR_FLD_L(ir_idx));
07327 point = 1;
07328 }
07329
07330 if (IR_FLD_R(ir_idx) == CN_Tbl_Idx) {
07331 span = (long) CN_INT_TO_C(IR_IDX_R(ir_idx));
07332 }
07333
07334 PDG_DBG_PRINT_START
07335 PDG_DBG_PRINT_C("fei_task_wait");
07336 PDG_DBG_PRINT_LD("(1) point", point);
07337 PDG_DBG_PRINT_LD("(2) span", span);
07338 PDG_DBG_PRINT_END
07339
07340 # ifdef _ENABLE_FEI
07341 fei_task_wait(point, span);
07342 # endif
07343
07344 break;
07345
07346
07347
07348 case Guard_Cmic_Opr:
07349 if (IR_FLD_L(ir_idx) == AT_Tbl_Idx) {
07350 send_attr_ntry(IR_IDX_L(ir_idx));
07351 }
07352
07353 PDG_DBG_PRINT_START
07354 PDG_DBG_PRINT_C("fei_guard");
07355 PDG_DBG_PRINT_LD("(1) idx", (IR_FLD_L(ir_idx) == NO_Tbl_Idx) ?
07356 0 : PDG_AT_IDX(IR_IDX_L(ir_idx)));
07357 PDG_DBG_PRINT_D("(2) line num", IR_LINE_NUM(ir_idx));
07358 PDG_DBG_PRINT_END
07359
07360 # ifdef _ENABLE_FEI
07361 guard_cmic_vpr_idx = fei_guard((IR_FLD_L(ir_idx) == NO_Tbl_Idx) ?
07362 0 : PDG_AT_IDX(IR_IDX_L(ir_idx)),
07363 IR_LINE_NUM(ir_idx));
07364 # endif
07365
07366 break;
07367
07368
07369
07370
07371
07372
07373 case Endguard_Cmic_Opr:
07374 if (IR_FLD_L(ir_idx) == AT_Tbl_Idx) {
07375 send_attr_ntry(IR_IDX_L(ir_idx));
07376 }
07377
07378 PDG_DBG_PRINT_START
07379 PDG_DBG_PRINT_C("fei_endguard");
07380 PDG_DBG_PRINT_LD("(1) guard idx", (IR_FLD_L(ir_idx) == NO_Tbl_Idx) ? 0 :
07381 PDG_AT_IDX(IR_IDX_L(ir_idx)));
07382 PDG_DBG_PRINT_D("(2) line num", IR_LINE_NUM(ir_idx));
07383 PDG_DBG_PRINT_END
07384
07385 # ifdef _ENABLE_FEI
07386 fei_endguard(guard_cmic_vpr_idx,
07387 (IR_FLD_L(ir_idx) == NO_Tbl_Idx) ? 0 :
07388 PDG_AT_IDX(IR_IDX_L(ir_idx)),
07389 IR_LINE_NUM(ir_idx));
07390 # endif
07391
07392 guard_cmic_vpr_idx = NULL_IDX;
07393 break;
07394
07395
07396
07397
07398
07399 case Numcpus_Cmic_Opr :
07400 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
07401 IR_FLD_L(ir_idx));
07402
07403 PDG_DBG_PRINT_START
07404 PDG_DBG_PRINT_C("fei_numcpus");
07405 PDG_DBG_PRINT_D("(1) line num", IR_LINE_NUM(ir_idx));
07406 PDG_DBG_PRINT_END
07407
07408 # ifdef _ENABLE_FEI
07409 fei_numcpus(IR_LINE_NUM(ir_idx));
07410 # endif
07411 break;
07412
07413
07414
07415
07416
07417
07418 case Ranf_Opr :
07419 basic = get_basic_type(IR_TYPE_IDX(ir_idx), 0, NULL_IDX);
07420
07421 PDG_DBG_PRINT_START
07422 PDG_DBG_PRINT_C("fei_ranf");
07423 PDG_DBG_PRINT_END
07424
07425 # ifdef _ENABLE_FEI
07426 fei_ranf(basic);
07427 # endif
07428
07429 break;
07430
07431
07432
07433
07434
07435
07436
07437 case Regionbegin_Star_Opr:
07438 case Regionend_Star_Opr:
07439 case End_Critical_Section_Par_Opr:
07440 case End_Parallel_Par_Opr:
07441 case Section_Par_Opr:
07442 case Barrier_Par_Opr:
07443 switch (IR_OPR(ir_idx)) {
07444 case Regionbegin_Star_Opr:
07445 PDG_DBG_PRINT_START
07446 PDG_DBG_PRINT_C("fei_regionbegin");
07447 PDG_DBG_PRINT_END
07448 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
07449 # ifdef _ENABLE_FEI
07450 fei_regionbegin();
07451 # endif
07452 # endif
07453 break;
07454
07455 case Regionend_Star_Opr :
07456 PDG_DBG_PRINT_START
07457 PDG_DBG_PRINT_C("fei_regionend");
07458 PDG_DBG_PRINT_END
07459 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
07460 # ifdef _ENABLE_FEI
07461 fei_regionend();
07462 # endif
07463 # endif
07464 break;
07465
07466 case End_Critical_Section_Par_Opr :
07467 PDG_DBG_PRINT_START
07468 PDG_DBG_PRINT_C("fei_endcriticalsection");
07469 PDG_DBG_PRINT_END
07470 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
07471 # ifdef _ENABLE_FEI
07472 fei_endcriticalsection();
07473 # endif
07474 # endif
07475 break;
07476
07477 case End_Parallel_Par_Opr :
07478 PDG_DBG_PRINT_START
07479 PDG_DBG_PRINT_C("fei_endparallel");
07480 PDG_DBG_PRINT_END
07481 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
07482 # ifdef _ENABLE_FEI
07483 fei_endparallel();
07484 # endif
07485 # endif
07486 break;
07487
07488 case Section_Par_Opr :
07489 PDG_DBG_PRINT_START
07490 PDG_DBG_PRINT_C("fei_section");
07491 PDG_DBG_PRINT_END
07492 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
07493 # ifdef _ENABLE_FEI
07494 fei_section();
07495 # endif
07496 # endif
07497 break;
07498
07499 case Barrier_Par_Opr :
07500 PDG_DBG_PRINT_START
07501 PDG_DBG_PRINT_C("fei_barrier");
07502 PDG_DBG_PRINT_END
07503 # ifdef _ENABLE_FEI
07504 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
07505 fei_barrier();
07506 # endif
07507 # endif
07508 break;
07509 }
07510 break;
07511
07512
07513
07514
07515
07516
07517
07518
07519
07520
07521 case End_Pdo_Par_Opr:
07522 if (IR_FLD_L(ir_idx) == CN_Tbl_Idx) {
07523 nowait = (long) CN_INT_TO_C(IR_IDX_L(ir_idx));
07524 }
07525
07526 PDG_DBG_PRINT_START
07527 PDG_DBG_PRINT_C("fei_endpdo");
07528 PDG_DBG_PRINT_LD("(1) nowait", nowait);
07529 PDG_DBG_PRINT_END
07530
07531
07532 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
07533 # ifdef _ENABLE_FEI
07534 fei_endpdo(nowait);
07535 # endif
07536 # endif
07537 break;
07538
07539
07540
07541
07542 case End_Psection_Par_Opr:
07543 if (IR_FLD_L(ir_idx) == CN_Tbl_Idx) {
07544 nowait = (long) CN_INT_TO_C(IR_IDX_L(ir_idx));
07545 }
07546
07547 PDG_DBG_PRINT_START
07548 PDG_DBG_PRINT_C("fei_endpsection");
07549 PDG_DBG_PRINT_LD("(1) nowait", nowait);
07550 PDG_DBG_PRINT_END
07551
07552
07553 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
07554 # ifdef _ENABLE_FEI
07555 fei_endpsection(nowait);
07556 # endif
07557 # endif
07558 break;
07559
07560
07561
07562 case End_Singleprocess_Par_Opr:
07563 if (IR_FLD_L(ir_idx) == CN_Tbl_Idx) {
07564 nowait = (long) CN_INT_TO_C(IR_IDX_L(ir_idx));
07565 }
07566
07567 PDG_DBG_PRINT_START
07568 PDG_DBG_PRINT_C("fei_endsingleprocess");
07569 PDG_DBG_PRINT_LD("(1) nowait", nowait);
07570 PDG_DBG_PRINT_END
07571
07572
07573 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
07574 # ifdef _ENABLE_FEI
07575 fei_endsingleprocess(nowait);
07576 # endif
07577 # endif
07578 break;
07579
07580
07581
07582
07583 case Critical_Section_Par_Opr:
07584 if (IR_FLD_L(ir_idx) != NO_Tbl_Idx) {
07585 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
07586 IR_FLD_L(ir_idx));
07587 varcount = 1;
07588 }
07589
07590 PDG_DBG_PRINT_START
07591 PDG_DBG_PRINT_C("fei_criticalsection");
07592 PDG_DBG_PRINT_LD("(1) varcount", varcount);
07593 PDG_DBG_PRINT_END
07594
07595
07596 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
07597 # ifdef _ENABLE_FEI
07598 fei_criticalsection(varcount);
07599 # endif
07600 # endif
07601 break;
07602
07603
07604 case User_Code_Start_Opr:
07605 PDG_DBG_PRINT_START
07606 PDG_DBG_PRINT_C("fei_user_code_start");
07607 PDG_DBG_PRINT_END
07608
07609 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
07610 # ifdef _ENABLE_FEI
07611 fei_user_code_start();
07612 # endif
07613 # endif
07614 break;
07615
07616
07617
07618 case Psection_Par_Opr:
07619 case Singleprocess_Par_Opr:
07620 case Parallel_Do_Par_Opr:
07621 case Parallel_Par_Opr:
07622 case Pdo_Par_Opr:
07623 case Doacross_Dollar_Opr:
07624 list_idx1 = IR_IDX_L(ir_idx);
07625
07626 for (i = 0; i < MP_DIR_LIST_CNT; i++) {
07627 list_array[i] = list_idx1;
07628 list_idx1 = IL_NEXT_LIST_IDX(list_idx1);
07629 }
07630
07631
07632
07633 if (IL_FLD(list_array[MP_DIR_IF_IDX]) == NO_Tbl_Idx) {
07634 task_if_idx = 0;
07635 }
07636 else {
07637 send_attr_ntry(IL_IDX(list_array[MP_DIR_IF_IDX]));
07638 task_if_idx = PDG_AT_IDX(IL_IDX(list_array[MP_DIR_IF_IDX]));
07639 }
07640
07641
07642
07643 if (IL_FLD(list_array[MP_DIR_ORDERED_IDX]) == CN_Tbl_Idx) {
07644 ordered = (long) CN_INT_TO_C(IL_IDX(list_array[MP_DIR_ORDERED_IDX]));
07645 }
07646
07647
07648
07649 if (IL_FLD(list_array[MP_DIR_MP_SCHEDTYPE_IDX]) == CN_Tbl_Idx) {
07650 schedtype = (long)
07651 CN_INT_TO_C(IL_IDX(list_array[MP_DIR_MP_SCHEDTYPE_IDX]));
07652 }
07653
07654
07655
07656 if (IL_FLD(list_array[MP_DIR_LASTTHREAD_IDX]) == AT_Tbl_Idx) {
07657 send_attr_ntry(IL_IDX(list_array[MP_DIR_LASTTHREAD_IDX]));
07658
07659 PDG_DBG_PRINT_START
07660 PDG_DBG_PRINT_C("fei_task_var");
07661 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX",
07662 PDG_AT_IDX(IL_IDX(list_array[MP_DIR_LASTTHREAD_IDX])));
07663 PDG_DBG_PRINT_S("(2) context",
07664 p_tasking_context[Context_Lastthread]);
07665 PDG_DBG_PRINT_END
07666
07667 # ifdef _ENABLE_FEI
07668 last_task_idx = fei_task_var(
07669 PDG_AT_IDX(IL_IDX(list_array[MP_DIR_LASTTHREAD_IDX])),
07670 Context_Lastthread);
07671 # endif
07672 }
07673
07674
07675
07676 if (IL_FLD(list_array[MP_DIR_SHARE_IDX]) == IL_Tbl_Idx) {
07677 list_idx2 = IL_IDX(list_array[MP_DIR_SHARE_IDX]);
07678
07679 while (list_idx2) {
07680 if (IL_FLD(list_idx2) == AT_Tbl_Idx) {
07681 send_attr_ntry(IL_IDX(list_idx2));
07682
07683 PDG_DBG_PRINT_START
07684 PDG_DBG_PRINT_C("fei_task_var");
07685 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX",
07686 PDG_AT_IDX(IL_IDX(list_idx2)));
07687 PDG_DBG_PRINT_S("(2) context",
07688 p_tasking_context[Context_Shared]);
07689
07690 PDG_DBG_PRINT_END
07691
07692 # ifdef _ENABLE_FEI
07693 last_task_idx = fei_task_var(PDG_AT_IDX(IL_IDX(list_idx2)),
07694 Context_Shared);
07695 # endif
07696
07697 }
07698
07699 list_idx2 = IL_NEXT_LIST_IDX(list_idx2);
07700 }
07701 }
07702
07703
07704
07705 if (IL_FLD(list_array[MP_DIR_LASTLOCAL_IDX]) == IL_Tbl_Idx) {
07706 list_idx2 = IL_IDX(list_array[MP_DIR_LASTLOCAL_IDX]);
07707
07708 while (list_idx2) {
07709 if (IL_FLD(list_idx2) == AT_Tbl_Idx) {
07710 send_attr_ntry(IL_IDX(list_idx2));
07711
07712 PDG_DBG_PRINT_START
07713 PDG_DBG_PRINT_C("fei_task_var");
07714 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX",
07715 PDG_AT_IDX(IL_IDX(list_idx2)));
07716 PDG_DBG_PRINT_S("(2) context",
07717 p_tasking_context[Context_Lastlocal]);
07718
07719 PDG_DBG_PRINT_END
07720
07721 # ifdef _ENABLE_FEI
07722 last_task_idx = fei_task_var(PDG_AT_IDX(IL_IDX(list_idx2)),
07723 Context_Lastlocal);
07724 # endif
07725
07726 }
07727
07728 list_idx2 = IL_NEXT_LIST_IDX(list_idx2);
07729 }
07730 }
07731
07732
07733
07734
07735
07736
07737
07738 if (IL_FLD(list_array[MP_DIR_LOCAL_IDX]) == IL_Tbl_Idx) {
07739 list_idx2 = IL_IDX(list_array[MP_DIR_LOCAL_IDX]);
07740
07741 while (list_idx2) {
07742 if (IL_FLD(list_idx2) == AT_Tbl_Idx) {
07743 send_attr_ntry(IL_IDX(list_idx2));
07744
07745 PDG_DBG_PRINT_START
07746 PDG_DBG_PRINT_C("fei_task_var");
07747 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX",
07748 PDG_AT_IDX(IL_IDX(list_idx2)));
07749 PDG_DBG_PRINT_S("(2) context",
07750 p_tasking_context[Context_Private]);
07751
07752 PDG_DBG_PRINT_END
07753
07754 # ifdef _ENABLE_FEI
07755 last_task_idx = fei_task_var(PDG_AT_IDX(IL_IDX(list_idx2)),
07756 Context_Private);
07757 # endif
07758
07759 }
07760
07761 list_idx2 = IL_NEXT_LIST_IDX(list_idx2);
07762 }
07763 }
07764
07765
07766
07767
07768
07769 if (IL_FLD(list_array[MP_DIR_NEST_IDX]) == IL_Tbl_Idx) {
07770 list_idx2 = IL_IDX(list_array[MP_DIR_NEST_IDX]);
07771
07772 while (list_idx2) {
07773 if (IL_FLD(list_idx2) == AT_Tbl_Idx) {
07774 send_attr_ntry(IL_IDX(list_idx2));
07775
07776 PDG_DBG_PRINT_START
07777 PDG_DBG_PRINT_C("fei_task_var");
07778 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX",
07779 PDG_AT_IDX(IL_IDX(list_idx2)));
07780 PDG_DBG_PRINT_S("(2) context",
07781 p_tasking_context[Context_Nest]);
07782 PDG_DBG_PRINT_END
07783
07784 # ifdef _ENABLE_FEI
07785 last_task_idx = fei_task_var(PDG_AT_IDX(IL_IDX(list_idx2)),
07786 Context_Nest);
07787 # endif
07788
07789 }
07790
07791 list_idx2 = IL_NEXT_LIST_IDX(list_idx2);
07792 }
07793 }
07794
07795
07796
07797
07798 if (IL_FLD(list_array[MP_DIR_AFFINITY_IDX]) == IL_Tbl_Idx) {
07799 list_idx2 = IL_IDX(list_array[MP_DIR_AFFINITY_IDX]);
07800
07801 while (list_idx2 != NULL_IDX) {
07802 if (IL_FLD(list_idx2) == AT_Tbl_Idx) {
07803 send_attr_ntry(IL_IDX(list_idx2));
07804
07805 PDG_DBG_PRINT_START
07806 PDG_DBG_PRINT_C("fei_task_var");
07807 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX",
07808 PDG_AT_IDX(IL_IDX(list_idx2)));
07809 PDG_DBG_PRINT_S("(2) context",
07810 p_tasking_context[Context_Affinity]);
07811 PDG_DBG_PRINT_END
07812
07813 # ifdef _ENABLE_FEI
07814 last_task_idx = fei_task_var(PDG_AT_IDX(IL_IDX(list_idx2)),
07815 Context_Affinity);
07816 # endif
07817
07818 }
07819
07820 list_idx2 = IL_NEXT_LIST_IDX(list_idx2);
07821 }
07822
07823 cvrt_exp_to_pdg(IL_IDX(list_array[MP_DIR_THREAD_DATA_IDX]),
07824 IL_FLD(list_array[MP_DIR_THREAD_DATA_IDX]));
07825
07826 cvrt_exp_to_pdg(IL_IDX(list_array[MP_DIR_THREAD_DATA_IDX]),
07827 IL_FLD(list_array[MP_DIR_THREAD_DATA_IDX]));
07828
07829 which = (long) CN_INT_TO_C(IL_IDX(list_array[MP_DIR_IS_THREAD_IDX]));
07830
07831 if (which == 1) {
07832 threadcount = 1;
07833 }
07834 else {
07835 datacount = 1;
07836 }
07837 }
07838
07839
07840
07841
07842
07843 if (IL_FLD(list_array[MP_DIR_ONTO_IDX]) == IL_Tbl_Idx) {
07844 list_idx2 = IL_IDX(list_array[MP_DIR_ONTO_IDX]);
07845
07846 ontocount = 0;
07847 while (list_idx2 != NULL_IDX) {
07848 cvrt_exp_to_pdg(IL_IDX(list_idx2),
07849 IL_FLD(list_idx2));
07850
07851 list_idx2 = IL_NEXT_LIST_IDX(list_idx2);
07852 ontocount = ontocount + 1;
07853 }
07854 }
07855
07856
07857
07858
07859
07860 if (IL_FLD(list_array[MP_DIR_REDUCTION_IDX]) == IL_Tbl_Idx) {
07861 list_idx2 = IL_IDX(list_array[MP_DIR_REDUCTION_IDX]);
07862
07863 reductioncount = 0;
07864 while (list_idx2 != NULL_IDX) {
07865 cvrt_exp_to_pdg(IL_IDX(list_idx2),
07866 IL_FLD(list_idx2));
07867
07868 list_idx2 = IL_NEXT_LIST_IDX(list_idx2);
07869 reductioncount = reductioncount + 1;
07870 }
07871 }
07872
07873
07874
07875
07876 if (IL_FLD(list_array[MP_DIR_CHUNK_IDX]) != NO_Tbl_Idx) {
07877 cvrt_exp_to_pdg(IL_IDX(list_array[MP_DIR_CHUNK_IDX]),
07878 IL_FLD(list_array[MP_DIR_CHUNK_IDX]));
07879 chunkcount = 1;
07880 }
07881
07882
07883
07884 switch (IR_OPR(ir_idx)) {
07885
07886 case Doacross_Dollar_Opr :
07887 PDG_DBG_PRINT_START
07888 PDG_DBG_PRINT_C("fei_doacross");
07889 PDG_DBG_PRINT_D("(1) if idx", task_if_idx);
07890 PDG_DBG_PRINT_LD("(2) schedtype", schedtype);
07891 PDG_DBG_PRINT_LD("(3) threadcount", threadcount);
07892 PDG_DBG_PRINT_LD("(4) datacount", datacount);
07893 PDG_DBG_PRINT_LD("(5) ontocount", ontocount);
07894 PDG_DBG_PRINT_LD("(6) reductioncount", reductioncount);
07895 PDG_DBG_PRINT_LD("(7) chunkcount", chunkcount);
07896 PDG_DBG_PRINT_END
07897
07898 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
07899 # ifdef _ENABLE_FEI
07900 fei_doacross(task_if_idx,
07901 schedtype,
07902 threadcount,
07903 datacount,
07904 ontocount,
07905 reductioncount,
07906 chunkcount);
07907
07908 # endif
07909 # endif
07910 break;
07911
07912
07913
07914 case Pdo_Par_Opr :
07915 PDG_DBG_PRINT_START
07916 PDG_DBG_PRINT_C("fei_pdo");
07917 PDG_DBG_PRINT_LD("(1) schedtype", schedtype);
07918 PDG_DBG_PRINT_LD("(2) ordered", ordered);
07919 PDG_DBG_PRINT_LD("(3) threadcount", threadcount);
07920 PDG_DBG_PRINT_LD("(4) datacount", datacount);
07921 PDG_DBG_PRINT_LD("(5) ontocount", ontocount);
07922 PDG_DBG_PRINT_LD("(6) reductioncount", reductioncount);
07923 PDG_DBG_PRINT_LD("(7) chunkcount", chunkcount);
07924 PDG_DBG_PRINT_END
07925
07926 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
07927 # ifdef _ENABLE_FEI
07928 fei_pdo(schedtype,
07929 ordered,
07930 threadcount,
07931 datacount,
07932 ontocount,
07933 reductioncount,
07934 chunkcount);
07935 # endif
07936 # endif
07937 break;
07938
07939
07940
07941 case Parallel_Do_Par_Opr :
07942 PDG_DBG_PRINT_START
07943 PDG_DBG_PRINT_C("fei_paralleldo");
07944 PDG_DBG_PRINT_D("(1) if idx", task_if_idx);
07945 PDG_DBG_PRINT_LD("(2) schedtype", schedtype);
07946 PDG_DBG_PRINT_LD("(3) threadcount", threadcount);
07947 PDG_DBG_PRINT_LD("(4) datacount", datacount);
07948 PDG_DBG_PRINT_LD("(5) ontocount", ontocount);
07949 PDG_DBG_PRINT_LD("(6) reductioncount", reductioncount);
07950 PDG_DBG_PRINT_LD("(7) chunkcount", chunkcount);
07951 PDG_DBG_PRINT_END
07952
07953
07954 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
07955 # ifdef _ENABLE_FEI
07956 fei_paralleldo(task_if_idx,
07957 schedtype,
07958 threadcount,
07959 datacount,
07960 ontocount,
07961 reductioncount,
07962 chunkcount);
07963 # endif
07964 # endif
07965 break;
07966
07967
07968
07969
07970 case Parallel_Par_Opr :
07971 PDG_DBG_PRINT_START
07972 PDG_DBG_PRINT_C("fei_parallel");
07973 PDG_DBG_PRINT_D("(1) if idx", task_if_idx);
07974 PDG_DBG_PRINT_END
07975
07976
07977 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
07978 # ifdef _ENABLE_FEI
07979 fei_parallel(task_if_idx);
07980 # endif
07981 # endif
07982 break;
07983
07984
07985
07986 case Singleprocess_Par_Opr :
07987 PDG_DBG_PRINT_START
07988 PDG_DBG_PRINT_C("fei_singleprocess");
07989 PDG_DBG_PRINT_END
07990
07991
07992 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
07993 # ifdef _ENABLE_FEI
07994 fei_singleprocess();
07995 # endif
07996 # endif
07997 break;
07998
07999
08000
08001
08002 case Psection_Par_Opr:
08003 PDG_DBG_PRINT_START
08004 PDG_DBG_PRINT_C("fei_psection");
08005 PDG_DBG_PRINT_END
08006
08007
08008 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
08009 # ifdef _ENABLE_FEI
08010 fei_psection();
08011 # endif
08012 # endif
08013 break;
08014
08015 }
08016 break;
08017
08018
08019
08020
08021
08022 case Concurrentize_Star_Opr:
08023 PDG_DBG_PRINT_START
08024 PDG_DBG_PRINT_C("fei_concurrentize");
08025 PDG_DBG_PRINT_D("(1) state", TRUE);
08026 PDG_DBG_PRINT_END
08027
08028 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
08029 # ifdef _ENABLE_FEI
08030 fei_concurrentize(TRUE);
08031 # endif
08032 # endif
08033
08034 break;
08035
08036
08037
08038
08039
08040 case Noconcurrentize_Star_Opr:
08041 PDG_DBG_PRINT_START
08042 PDG_DBG_PRINT_C("fei_concurrentize");
08043 PDG_DBG_PRINT_D("(1) state", FALSE);
08044 PDG_DBG_PRINT_END
08045
08046 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
08047 # ifdef _ENABLE_FEI
08048 fei_concurrentize(FALSE);
08049 # endif
08050 # endif
08051
08052 break;
08053
08054
08055
08056
08057
08058
08059
08060
08061 case Interchange_Dir_Opr:
08062
08063 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
08064 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
08065 IR_FLD_L(ir_idx));
08066
08067 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
08068 IR_FLD_R(ir_idx));
08069
08070 PDG_DBG_PRINT_START
08071 PDG_DBG_PRINT_C("fei_interchange");
08072 PDG_DBG_PRINT_D("(1) expressions", IR_LIST_CNT_L(ir_idx));
08073 PDG_DBG_PRINT_END
08074
08075 # ifdef _ENABLE_FEI
08076 fei_interchange(IR_LIST_CNT_L(ir_idx));
08077 # endif
08078 # endif
08079 break;
08080
08081
08082
08083
08084
08085
08086 case Blockable_Dir_Opr:
08087
08088 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
08089
08090 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
08091 IR_FLD_L(ir_idx));
08092
08093 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
08094 IR_FLD_R(ir_idx));
08095
08096 PDG_DBG_PRINT_START
08097 PDG_DBG_PRINT_C("fei_blockable");
08098 PDG_DBG_PRINT_D("(1) expressions", IR_LIST_CNT_L(ir_idx));
08099 PDG_DBG_PRINT_END
08100
08101 # ifdef _ENABLE_FEI
08102 fei_blockable(IR_LIST_CNT_L(ir_idx));
08103 # endif
08104 # endif
08105 break;
08106
08107
08108
08109 case Fission_Star_Opr:
08110 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
08111 IR_FLD_L(ir_idx));
08112
08113 PDG_DBG_PRINT_START
08114 PDG_DBG_PRINT_C("fei_fission");
08115 PDG_DBG_PRINT_END
08116
08117 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
08118 # ifdef _ENABLE_FEI
08119 fei_fission();
08120 # endif
08121 # endif
08122 break;
08123
08124
08125 #ifdef KEY
08126 case Forall_Opr:
08127 PDG_DBG_PRINT_START
08128 PDG_DBG_PRINT_C("fei_forall");
08129 PDG_DBG_PRINT_END
08130
08131 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
08132 # ifdef _ENABLE_FEI
08133 fei_forall();
08134 # endif
08135 # endif
08136 break;
08137 #endif
08138
08139
08140 case Flush_Star_Opr:
08141 list_cnt = 0;
08142 if (IR_FLD_L(ir_idx) == IL_Tbl_Idx) {
08143 list_cnt = IR_LIST_CNT_L(ir_idx);
08144 }
08145
08146 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
08147 IR_FLD_L(ir_idx));
08148
08149 PDG_DBG_PRINT_START
08150 PDG_DBG_PRINT_C("fei_flush");
08151 PDG_DBG_PRINT_D("(1) list_cnt", list_cnt);
08152 PDG_DBG_PRINT_END
08153
08154
08155 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
08156 # ifdef _ENABLE_FEI
08157 fei_flush(list_cnt);
08158 # endif
08159 # endif
08160 break;
08161
08162 case Fuse_Star_Opr:
08163 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
08164 IR_FLD_L(ir_idx));
08165
08166 if (IR_FLD_R(ir_idx) == CN_Tbl_Idx) {
08167 level = (long) CN_INT_TO_C(IR_IDX_R(ir_idx));
08168 }
08169
08170 PDG_DBG_PRINT_START
08171 PDG_DBG_PRINT_C("fei_fuse");
08172 PDG_DBG_PRINT_LD("(1) level", level);
08173 PDG_DBG_PRINT_END
08174
08175 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
08176 # ifdef _ENABLE_FEI
08177 fei_fuse(level);
08178 # endif
08179 # endif
08180 break;
08181
08182
08183
08184
08185
08186
08187
08188
08189 case Assert_Star_Opr:
08190 assertion = (long) CN_INT_TO_C(IR_IDX_L(ir_idx));
08191
08192 if (IR_FLD_R(ir_idx) == NO_Tbl_Idx) {
08193 count = 0;
08194 }
08195 else if (IR_FLD_R(ir_idx) == IL_Tbl_Idx) {
08196 count = IR_LIST_CNT_R(ir_idx);
08197 }
08198 else {
08199 count = 1;
08200 }
08201
08202 if (IR_FLD_R(ir_idx) != NO_Tbl_Idx) {
08203 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
08204 IR_FLD_R(ir_idx));
08205 }
08206
08207 PDG_DBG_PRINT_START
08208 PDG_DBG_PRINT_C("fei_assert");
08209 PDG_DBG_PRINT_LD("(1) assertion", assertion);
08210 PDG_DBG_PRINT_D("(2) count ", count);
08211 PDG_DBG_PRINT_END
08212
08213 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
08214 # ifdef _ENABLE_FEI
08215 fei_assert(assertion, count);
08216 # endif
08217 # endif
08218 break;
08219
08220
08221
08222
08223
08224 case Unroll_Star_Opr:
08225
08226 #ifdef KEY
08227 case Unroll_Cdir_Opr:
08228 #endif
08229 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
08230 IR_FLD_L(ir_idx));
08231
08232 PDG_DBG_PRINT_START
08233 PDG_DBG_PRINT_C("fei_unroll");
08234 PDG_DBG_PRINT_END
08235
08236 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
08237 # ifdef _ENABLE_FEI
08238 fei_unroll();
08239 # endif
08240 # endif
08241 break;
08242
08243
08244
08245
08246
08247 case Section_Nongp_Star_Opr:
08248 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
08249 IR_FLD_L(ir_idx));
08250
08251 PDG_DBG_PRINT_START
08252 PDG_DBG_PRINT_C("fei_section_nongp");
08253 PDG_DBG_PRINT_D("(1) list count", IR_LIST_CNT_L(ir_idx));
08254 PDG_DBG_PRINT_END
08255
08256 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
08257 # ifdef _ENABLE_FEI
08258 fei_section_nongp(IR_LIST_CNT_L(ir_idx));
08259 # endif
08260 # endif
08261 break;
08262
08263
08264
08265
08266
08267
08268 case Section_Gp_Star_Opr:
08269 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
08270 IR_FLD_L(ir_idx));
08271
08272 PDG_DBG_PRINT_START
08273 PDG_DBG_PRINT_C("fei_section_gp");
08274 PDG_DBG_PRINT_D("(1) list count", IR_LIST_CNT_L(ir_idx));
08275 PDG_DBG_PRINT_END
08276
08277 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
08278 # ifdef _ENABLE_FEI
08279 fei_section_gp(IR_LIST_CNT_L(ir_idx));
08280 # endif
08281 # endif
08282 break;
08283
08284
08285
08286
08287
08288 case Copyin_Dollar_Opr:
08289 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
08290 IR_FLD_L(ir_idx));
08291
08292 PDG_DBG_PRINT_START
08293 PDG_DBG_PRINT_C("fei_copy_in");
08294 PDG_DBG_PRINT_D("(1) list count", IR_LIST_CNT_L(ir_idx));
08295 PDG_DBG_PRINT_END
08296
08297 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
08298 # ifdef _ENABLE_FEI
08299 fei_copy_in(IR_LIST_CNT_L(ir_idx));
08300 # endif
08301 # endif
08302 break;
08303
08304
08305
08306
08307
08308
08309
08310
08311
08312 case Align_Symbol_Star_Opr:
08313 if (IR_FLD_L(ir_idx) == NO_Tbl_Idx) {
08314 list_cnt = 0;
08315 }
08316 else {
08317 list_cnt = 1;
08318 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
08319 IR_FLD_L(ir_idx));
08320 }
08321
08322 if (IR_FLD_R(ir_idx) == CN_Tbl_Idx) {
08323 C_value = (long) CN_INT_TO_C(IR_IDX_R(ir_idx));
08324 }
08325
08326 PDG_DBG_PRINT_START
08327 PDG_DBG_PRINT_C("fei_align_symbol");
08328 PDG_DBG_PRINT_D("(1) list_cnt", list_cnt);
08329 PDG_DBG_PRINT_LD("(2) C_value", C_value);
08330 PDG_DBG_PRINT_END
08331
08332
08333 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
08334 # ifdef _ENABLE_FEI
08335 fei_align_symbol(list_cnt, C_value);
08336 # endif
08337 # endif
08338
08339 break;
08340
08341
08342
08343
08344
08345 case Fill_Symbol_Star_Opr:
08346 if (IR_FLD_L(ir_idx) == NO_Tbl_Idx) {
08347 list_cnt = 0;
08348 }
08349 else {
08350 list_cnt = 1;
08351 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
08352 IR_FLD_L(ir_idx));
08353 }
08354
08355 if (IR_FLD_R(ir_idx) == CN_Tbl_Idx) {
08356 C_value = (long) CN_INT_TO_C(IR_IDX_R(ir_idx));
08357 }
08358
08359 PDG_DBG_PRINT_START
08360 PDG_DBG_PRINT_C("fei_fill_symbol");
08361 PDG_DBG_PRINT_D("(1) list_cnt", list_cnt);
08362 PDG_DBG_PRINT_LD("(2) C_value", C_value);
08363 PDG_DBG_PRINT_END
08364
08365
08366 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
08367 # ifdef _ENABLE_FEI
08368 fei_fill_symbol(list_cnt, C_value);
08369 # endif
08370 # endif
08371 break;
08372
08373
08374
08375
08376
08377
08378
08379 case Blockingsize_Dir_Opr:
08380 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
08381 IR_FLD_L(ir_idx));
08382
08383 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
08384 IR_FLD_R(ir_idx));
08385
08386 PDG_DBG_PRINT_START
08387 PDG_DBG_PRINT_C("fei_blocking_size");
08388 PDG_DBG_PRINT_END
08389
08390 # if !defined(_TARGET_OS_MAX)
08391 # ifdef _ENABLE_FEI
08392 fei_blocking_size();
08393 # endif
08394 # endif
08395 break;
08396
08397
08398
08399
08400 case Purpleconditional_Star_Opr:
08401 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
08402 IR_FLD_L(ir_idx));
08403
08404 PDG_DBG_PRINT_START
08405 PDG_DBG_PRINT_C("fei_purple_conditional");
08406 PDG_DBG_PRINT_END
08407
08408 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
08409 # ifdef _ENABLE_FEI
08410 fei_purple_conditional();
08411 # endif
08412 # endif
08413 break;
08414
08415
08416
08417
08418
08419
08420 case Opaque_Star_Opr:
08421 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
08422 IR_FLD_L(ir_idx));
08423
08424 PDG_DBG_PRINT_START
08425 PDG_DBG_PRINT_C("fei_opaque");
08426 PDG_DBG_PRINT_END
08427
08428 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
08429 # ifdef _ENABLE_FEI
08430 fei_opaque();
08431 # endif
08432 # endif
08433 break;
08434
08435
08436
08437
08438
08439
08440
08441 case Purpleunconditional_Star_Opr:
08442 PDG_DBG_PRINT_START
08443 PDG_DBG_PRINT_C("fei_purple_unconditional");
08444 PDG_DBG_PRINT_END
08445
08446 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
08447 # ifdef _ENABLE_FEI
08448 fei_purple_unconditional();
08449 # endif
08450 # endif
08451 break;
08452
08453
08454
08455
08456 case Dynamic_Dollar_Opr:
08457 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
08458 IR_FLD_L(ir_idx));
08459
08460 list_cnt = IR_LIST_CNT_L(ir_idx);
08461
08462 PDG_DBG_PRINT_START
08463 PDG_DBG_PRINT_C("fei_dynamic");
08464 PDG_DBG_PRINT_D("(1) list count", list_cnt);
08465 PDG_DBG_PRINT_END
08466
08467 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
08468 # ifdef _ENABLE_FEI
08469 fei_dynamic(list_cnt);
08470 # endif
08471 # endif
08472 break;
08473
08474
08475
08476
08477
08478 case Page_Place_Dollar_Opr:
08479 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
08480 IR_FLD_L(ir_idx));
08481
08482 PDG_DBG_PRINT_START
08483 PDG_DBG_PRINT_C("fei_page_place");
08484 PDG_DBG_PRINT_END
08485
08486 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
08487 # ifdef _ENABLE_FEI
08488 fei_page_place();
08489 # endif
08490 # endif
08491 break;
08492
08493
08494
08495
08496 case Prefetch_Manual_Star_Opr:
08497 if (IR_FLD_L(ir_idx) == CN_Tbl_Idx) {
08498 prefetch_manual = (long) CN_INT_TO_C(IR_IDX_L(ir_idx));
08499 }
08500
08501 PDG_DBG_PRINT_START
08502 PDG_DBG_PRINT_C("fei_prefetch_manual");
08503 PDG_DBG_PRINT_LD("(1) prefetch_manual", prefetch_manual);
08504 PDG_DBG_PRINT_END
08505
08506 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
08507 # ifdef _ENABLE_FEI
08508 fei_prefetch_manual(prefetch_manual);
08509 # endif
08510 # endif
08511 break;
08512
08513
08514
08515
08516
08517
08518 case Prefetch_Star_Opr:
08519 if (IR_FLD_L(ir_idx) == CN_Tbl_Idx) {
08520 n1 = (long) CN_INT_TO_C(IR_IDX_L(ir_idx));
08521 }
08522
08523 if (IR_FLD_R(ir_idx) == CN_Tbl_Idx) {
08524 n2 = (long) CN_INT_TO_C(IR_IDX_R(ir_idx));
08525 }
08526
08527 PDG_DBG_PRINT_START
08528 PDG_DBG_PRINT_C("fei_prefetch");
08529 PDG_DBG_PRINT_LD("(1) n1", n1);
08530 PDG_DBG_PRINT_LD("(2) n2", n2);
08531 PDG_DBG_PRINT_END
08532
08533 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
08534 # ifdef _ENABLE_FEI
08535 fei_prefetch(n1, n2);
08536 # endif
08537 # endif
08538 break;
08539
08540 #ifdef KEY
08541 case Options_Dir_Opr:
08542 {
08543 char *c1 = (char *) &CN_CONST(IR_IDX_L(ir_idx));
08544
08545 PDG_DBG_PRINT_START
08546 PDG_DBG_PRINT_C("fei_options");
08547 PDG_DBG_PRINT_S("(1) c1", c1);
08548 PDG_DBG_PRINT_END
08549
08550 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
08551 # ifdef _ENABLE_FEI
08552 fei_options(c1);
08553 # endif
08554 # endif
08555 }
08556 break;
08557 #endif
08558
08559
08560
08561
08562
08563 case Prefetch_Ref_Disable_Star_Opr:
08564 if (IR_FLD_L(ir_idx) == AT_Tbl_Idx) {
08565 send_attr_ntry(IR_IDX_L(ir_idx));
08566 prefetch_array = (long) PDG_AT_IDX(IR_IDX_L(ir_idx));
08567 }
08568
08569 if (IR_FLD_R(ir_idx) == CN_Tbl_Idx) {
08570 prefetch_size = (long) CN_INT_TO_C(IR_IDX_R(ir_idx));
08571 }
08572
08573 PDG_DBG_PRINT_START
08574 PDG_DBG_PRINT_C("fei_prefetch_ref_disable");
08575 PDG_DBG_PRINT_LD("(1) prefetch_array", prefetch_array);
08576 PDG_DBG_PRINT_LD("(2) prefetch_size", prefetch_size);
08577 PDG_DBG_PRINT_END
08578
08579 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
08580 # ifdef _ENABLE_FEI
08581 fei_prefetch_ref_disable(prefetch_array, prefetch_size);
08582 # endif
08583 # endif
08584 break;
08585
08586
08587
08588
08589
08590
08591
08592 case Prefetch_Ref_Star_Opr:
08593 list_idx1 = IR_IDX_L(ir_idx);
08594
08595 for (i = 0; i < 5; i++) {
08596 list_array[i] = list_idx1;
08597 list_idx1 = IL_NEXT_LIST_IDX(list_idx1);
08598 }
08599
08600
08601 cvrt_exp_to_pdg(IL_IDX(list_array[0]),
08602 IL_FLD(list_array[0]));
08603
08604
08605 cvrt_exp_to_pdg(IL_IDX(list_array[1]),
08606 IL_FLD(list_array[1]));
08607 if (IL_FLD(list_array[1]) != NO_Tbl_Idx) {
08608 stride_list = IL_LIST_CNT(list_array[1]);
08609 }
08610
08611
08612 cvrt_exp_to_pdg(IL_IDX(list_array[2]),
08613 IL_FLD(list_array[2]));
08614 if (IL_FLD(list_array[2]) != NO_Tbl_Idx) {
08615 level_list = IL_LIST_CNT(list_array[2]);
08616 }
08617
08618 if (IL_FLD(list_array[3]) == CN_Tbl_Idx) {
08619 prefetch_kind = (long) CN_INT_TO_C(IL_IDX(list_array[3]));
08620 }
08621
08622 if (IL_FLD(list_array[4]) == CN_Tbl_Idx) {
08623 prefetch_size = (long) CN_INT_TO_C(IL_IDX(list_array[4]));
08624 }
08625
08626 PDG_DBG_PRINT_START
08627 PDG_DBG_PRINT_C("fei_prefetch_ref");
08628 PDG_DBG_PRINT_D("(1) stride_list", stride_list);
08629 PDG_DBG_PRINT_D("(2) level_list", level_list);
08630 PDG_DBG_PRINT_LD("(3) prefetch_kind", prefetch_kind);
08631 PDG_DBG_PRINT_LD("(4) prefetch_size", prefetch_size);
08632 PDG_DBG_PRINT_END
08633
08634 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
08635 # ifdef _ENABLE_FEI
08636 fei_prefetch_ref(stride_list,
08637 level_list,
08638 prefetch_kind,
08639 prefetch_size);
08640 # endif
08641 # endif
08642
08643 break;
08644
08645
08646
08647
08648
08649
08650 case Redistribute_Dollar_Opr:
08651 if (IR_FLD_L(ir_idx) == AT_Tbl_Idx) {
08652 send_attr_ntry(IR_IDX_L(ir_idx));
08653 redistribute_array = PDG_AT_IDX(IR_IDX_L(ir_idx));
08654 }
08655
08656 cyclic_list = IR_IDX_R(ir_idx);
08657 list_cnt = IL_LIST_CNT(cyclic_list);
08658 onto_list = IL_NEXT_LIST_IDX(cyclic_list);
08659 cyclic_list = IL_IDX(cyclic_list);
08660
08661 if (onto_list) {
08662 onto_list = IL_IDX(onto_list);
08663 }
08664
08665 for (j = 1; j <= list_cnt; j++) {
08666 cyclic_exists = 0;
08667 onto_exists = 0;
08668
08669 if (onto_list) {
08670 cvrt_exp_to_pdg(IL_IDX(onto_list),
08671 IL_FLD(onto_list));
08672 if (IL_FLD(onto_list) != NO_Tbl_Idx) {
08673 onto_exists = 1;
08674 }
08675 }
08676
08677 cvrt_exp_to_pdg(IL_IDX(cyclic_list),
08678 IL_FLD(cyclic_list));
08679 if (IL_FLD(cyclic_list) != NO_Tbl_Idx) {
08680 cyclic_exists = 1;
08681 }
08682
08683 PDG_DBG_PRINT_START
08684 PDG_DBG_PRINT_C("fei_redistribute");
08685 PDG_DBG_PRINT_S("AT_OBJ_NAME",
08686 AT_OBJ_NAME_PTR(IR_IDX_L(ir_idx)));
08687 PDG_DBG_PRINT_D("(1) array", redistribute_array);
08688 PDG_DBG_PRINT_D("(2) dimension", j);
08689 PDG_DBG_PRINT_D("(3) distribution", IL_DISTRIBUTION(cyclic_list));
08690 PDG_DBG_PRINT_LD("(4) cyclic_exists", cyclic_exists);
08691 PDG_DBG_PRINT_LD("(5) onto_exists", onto_exists);
08692 PDG_DBG_PRINT_END
08693
08694 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
08695 # ifdef _ENABLE_FEI
08696 fei_redistribute(redistribute_array,
08697 j,
08698 IL_DISTRIBUTION(cyclic_list),
08699 cyclic_exists,
08700 onto_exists);
08701 # endif
08702 # endif
08703 cyclic_list = IL_NEXT_LIST_IDX(cyclic_list);
08704
08705 if (onto_list) {
08706 onto_list = IL_NEXT_LIST_IDX(onto_list);
08707 }
08708 }
08709 break;
08710
08711
08712
08713 case Doall_Cmic_Opr:
08714 list_idx1 = IR_IDX_L(ir_idx);
08715
08716 for (i = 0; i < 10; i++) {
08717 list_array[i] = list_idx1;
08718 list_idx1 = IL_NEXT_LIST_IDX(list_idx1);
08719 }
08720
08721 first_task_idx = NULL_IDX;
08722 last_task_idx = first_task_idx;
08723
08724
08725
08726 if (IL_FLD(list_array[1]) == IL_Tbl_Idx) {
08727 list_idx2 = IL_IDX(list_array[1]);
08728
08729 while (list_idx2) {
08730 if (IL_FLD(list_idx2) == AT_Tbl_Idx) {
08731 send_attr_ntry(IL_IDX(list_idx2));
08732
08733 PDG_DBG_PRINT_START
08734 PDG_DBG_PRINT_C("fei_task_var");
08735 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX",
08736 PDG_AT_IDX(IL_IDX(list_idx2)));
08737 PDG_DBG_PRINT_S("(2) context",
08738 p_tasking_context[Context_Shared]);
08739 PDG_DBG_PRINT_END
08740
08741 # ifdef _ENABLE_FEI
08742 last_task_idx = fei_task_var(PDG_AT_IDX(IL_IDX(list_idx2)),
08743 Context_Shared);
08744 # endif
08745
08746 if (first_task_idx == NULL_IDX) {
08747 first_task_idx = last_task_idx;
08748 }
08749 }
08750
08751 list_idx2 = IL_NEXT_LIST_IDX(list_idx2);
08752 }
08753 }
08754
08755
08756
08757 if (IL_FLD(list_array[2]) == IL_Tbl_Idx) {
08758 list_idx2 = IL_IDX(list_array[2]);
08759
08760 idx = Context_Private;
08761 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
08762 if (IL_FLD(list_array[6]) == CN_Tbl_Idx) {
08763 idx = Context_Lastlocal;
08764 }
08765 # endif
08766
08767 while (list_idx2) {
08768 if (IL_FLD(list_idx2) == AT_Tbl_Idx) {
08769 send_attr_ntry(IL_IDX(list_idx2));
08770
08771 PDG_DBG_PRINT_START
08772 PDG_DBG_PRINT_C("fei_task_var");
08773 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX",
08774 PDG_AT_IDX(IL_IDX(list_idx2)));
08775 PDG_DBG_PRINT_S("(2) context", p_tasking_context[idx]);
08776 PDG_DBG_PRINT_END
08777
08778 # ifdef _ENABLE_FEI
08779 last_task_idx = fei_task_var(PDG_AT_IDX(IL_IDX(list_idx2)),
08780 idx);
08781 # endif
08782
08783 if (first_task_idx == NULL_IDX) {
08784 first_task_idx = last_task_idx;
08785 }
08786 }
08787
08788 list_idx2 = IL_NEXT_LIST_IDX(list_idx2);
08789 }
08790 }
08791
08792
08793
08794 if (IL_FLD(list_array[3]) == IL_Tbl_Idx) {
08795 list_idx2 = IL_IDX(list_array[3]);
08796
08797 while (list_idx2) {
08798 if (IL_FLD(list_idx2) == AT_Tbl_Idx) {
08799 send_attr_ntry(IL_IDX(list_idx2));
08800
08801 PDG_DBG_PRINT_START
08802 PDG_DBG_PRINT_C("fei_task_var");
08803 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX",
08804 PDG_AT_IDX(IL_IDX(list_idx2)));
08805 PDG_DBG_PRINT_S("(2) context",
08806 p_tasking_context[Context_Getfirst]);
08807 PDG_DBG_PRINT_END
08808
08809 # ifdef _ENABLE_FEI
08810 last_task_idx = fei_task_var(PDG_AT_IDX(IL_IDX(list_idx2)),
08811 Context_Getfirst);
08812 # endif
08813
08814 if (first_task_idx == NULL_IDX) {
08815 first_task_idx = last_task_idx;
08816 }
08817 }
08818
08819 list_idx2 = IL_NEXT_LIST_IDX(list_idx2);
08820 }
08821 }
08822
08823
08824
08825
08826 if (IL_FLD(list_array[5]) == IL_Tbl_Idx) {
08827 list_idx2 = IL_IDX(list_array[5]);
08828
08829 while (list_idx2) {
08830 if (IL_FLD(list_idx2) == AT_Tbl_Idx) {
08831 send_attr_ntry(IL_IDX(list_idx2));
08832
08833 PDG_DBG_PRINT_START
08834 PDG_DBG_PRINT_C("fei_task_var");
08835 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX",
08836 PDG_AT_IDX(IL_IDX(list_idx2)));
08837 PDG_DBG_PRINT_S("(2) context",
08838 p_tasking_context[Context_Control]);
08839 PDG_DBG_PRINT_END
08840
08841 # ifdef _ENABLE_FEI
08842 last_task_idx = fei_task_var(PDG_AT_IDX(IL_IDX(list_idx2)),
08843 Context_Control);
08844 # endif
08845
08846 if (first_task_idx == NULL_IDX) {
08847 first_task_idx = last_task_idx;
08848 }
08849 }
08850
08851 list_idx2 = IL_NEXT_LIST_IDX(list_idx2);
08852 }
08853 }
08854
08855 j = 0;
08856
08857 if (IL_FLD(list_array[4]) == CN_Tbl_Idx) {
08858
08859 j = j + 2;
08860 }
08861
08862 if (IL_FLD(list_array[6]) == CN_Tbl_Idx) {
08863
08864 j = j + 1;
08865 }
08866
08867 if (IL_FLD(list_array[0]) == NO_Tbl_Idx) {
08868 task_if_idx = 0;
08869 }
08870 else {
08871 send_attr_ntry(IL_IDX(list_array[0]));
08872 task_if_idx = PDG_AT_IDX(IL_IDX(list_array[0]));
08873 }
08874
08875 if (IL_FLD(list_array[7]) == NO_Tbl_Idx) {
08876 task_maxcpus_idx = 0;
08877 }
08878 else {
08879 send_attr_ntry(IL_IDX(list_array[7]));
08880 task_maxcpus_idx = PDG_AT_IDX(IL_IDX(list_array[7]));
08881 }
08882
08883 if (IL_FLD(list_array[9]) == NO_Tbl_Idx) {
08884 task_wdist_idx = 0;
08885 }
08886 else {
08887 send_attr_ntry(IL_IDX(list_array[9]));
08888 task_wdist_idx = PDG_AT_IDX(IL_IDX(list_array[9]));
08889 }
08890
08891 send_attr_ntry(IR_IDX_R(ir_idx));
08892 big_int = CN_INT_TO_C(IL_IDX(list_array[8]));
08893
08894 PDG_DBG_PRINT_START
08895 PDG_DBG_PRINT_C("fei_doall");
08896 PDG_DBG_PRINT_D("(1) if idx", task_if_idx);
08897 PDG_DBG_PRINT_D("(2) maxcpus idx", task_maxcpus_idx);
08898 PDG_DBG_PRINT_D("(3) first task idx", first_task_idx);
08899 PDG_DBG_PRINT_D("(4) last task idx", last_task_idx);
08900 PDG_DBG_PRINT_LD("(5) obj idx", PDG_AT_IDX(IR_IDX_R(ir_idx)));
08901 #if defined(_HOST32) && defined(_TARGET64)
08902 PDG_DBG_PRINT_D("(6) const", big_int);
08903 #else
08904 PDG_DBG_PRINT_VD("(6) const", big_int);
08905 #endif
08906 PDG_DBG_PRINT_D("(7) wdist idx", task_wdist_idx);
08907 PDG_DBG_PRINT_D("(8) ", j);
08908 PDG_DBG_PRINT_D("(9) line num", IR_LINE_NUM(ir_idx));
08909 PDG_DBG_PRINT_END
08910
08911 # ifdef _ENABLE_FEI
08912 fei_doall(task_if_idx,
08913 task_maxcpus_idx,
08914 first_task_idx,
08915 last_task_idx,
08916 PDG_AT_IDX(IR_IDX_R(ir_idx)),
08917 big_int,
08918 task_wdist_idx,
08919 j,
08920 IR_LINE_NUM(ir_idx));
08921 # endif
08922
08923 break;
08924
08925
08926
08927
08928
08929 case Doparallel_Cmic_Opr:
08930 list_idx1 = IR_IDX_L(ir_idx);
08931
08932 for (i = 0; i < 2; i++) {
08933 list_array[i] = list_idx1;
08934 list_idx1 = IL_NEXT_LIST_IDX(list_idx1);
08935 }
08936
08937 if (IL_FLD(list_array[1]) == NO_Tbl_Idx) {
08938 task_wdist_idx = 0;
08939 }
08940 else {
08941 send_attr_ntry(IL_IDX(list_array[1]));
08942 task_wdist_idx = PDG_AT_IDX(IL_IDX(list_array[1]));
08943 }
08944
08945 send_attr_ntry(IR_IDX_R(ir_idx));
08946 big_int = CN_INT_TO_C(IL_IDX(list_array[0]));
08947
08948 PDG_DBG_PRINT_START
08949 PDG_DBG_PRINT_C("fei_doparallel");
08950 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX", PDG_AT_IDX(IR_IDX_R(ir_idx)));
08951 #if defined(_HOST32) && defined(_TARGET64)
08952 PDG_DBG_PRINT_D("(2) const", big_int);
08953 #else
08954 PDG_DBG_PRINT_VD("(2) const", big_int);
08955 #endif
08956 PDG_DBG_PRINT_D("(3) task idx", task_wdist_idx);
08957 PDG_DBG_PRINT_D("(4) line num", IR_LINE_NUM(ir_idx));
08958 PDG_DBG_PRINT_END
08959
08960
08961 # ifdef _ENABLE_FEI
08962 doparallel_cmic_vpr_idx =
08963 fei_doparallel(PDG_AT_IDX(IR_IDX_R(ir_idx)),
08964 big_int,
08965 task_wdist_idx,
08966 IR_LINE_NUM(ir_idx));
08967 # endif
08968
08969 break;
08970
08971
08972
08973
08974 case Enddo_Cmic_Opr:
08975
08976 if (IR_FLD_L(ir_idx) == CN_Tbl_Idx) {
08977 nowait = (long) CN_INT_TO_C(IR_IDX_L(ir_idx));
08978 }
08979
08980 PDG_DBG_PRINT_START
08981 PDG_DBG_PRINT_C("fei_task_endloop");
08982 PDG_DBG_PRINT_D("(1) pdg idx", doparallel_cmic_vpr_idx);
08983 PDG_DBG_PRINT_D("(2) line num", IR_LINE_NUM(ir_idx));
08984 PDG_DBG_PRINT_LD("(3) nowait", nowait);
08985 PDG_DBG_PRINT_END
08986
08987 # ifdef _ENABLE_FEI
08988 fei_task_endloop(doparallel_cmic_vpr_idx,
08989 IR_LINE_NUM(ir_idx),
08990 nowait);
08991 # endif
08992 doparallel_cmic_vpr_idx = NULL_IDX;
08993 break;
08994
08995
08996
08997
08998
08999
09000 case Parallel_Cmic_Opr:
09001 list_idx1 = IR_IDX_L(ir_idx);
09002
09003 for (i = 0; i < 7; i++) {
09004 list_array[i] = list_idx1;
09005 list_idx1 = IL_NEXT_LIST_IDX(list_idx1);
09006 }
09007
09008 first_task_idx = NULL_IDX;
09009
09010
09011
09012 if (IL_FLD(list_array[1]) == IL_Tbl_Idx) {
09013 list_idx2 = IL_IDX(list_array[1]);
09014
09015 while (list_idx2) {
09016 if (IL_FLD(list_idx2) == AT_Tbl_Idx) {
09017 send_attr_ntry(IL_IDX(list_idx2));
09018
09019 PDG_DBG_PRINT_START
09020 PDG_DBG_PRINT_C("fei_task_var");
09021 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX",
09022 PDG_AT_IDX(IL_IDX(list_idx2)));
09023 PDG_DBG_PRINT_S("(2) context",
09024 p_tasking_context[Context_Shared]);
09025 PDG_DBG_PRINT_END
09026
09027 # ifdef _ENABLE_FEI
09028 last_task_idx = fei_task_var(PDG_AT_IDX(IL_IDX(list_idx2)),
09029 Context_Shared);
09030 # endif
09031
09032 if (first_task_idx == NULL_IDX) {
09033 first_task_idx = last_task_idx;
09034 }
09035 }
09036
09037 list_idx2 = IL_NEXT_LIST_IDX(list_idx2);
09038 }
09039 }
09040
09041
09042
09043 if (IL_FLD(list_array[2]) == IL_Tbl_Idx) {
09044 list_idx2 = IL_IDX(list_array[2]);
09045
09046 while (list_idx2) {
09047 if (IL_FLD(list_idx2) == AT_Tbl_Idx) {
09048 send_attr_ntry(IL_IDX(list_idx2));
09049
09050 PDG_DBG_PRINT_START
09051 PDG_DBG_PRINT_C("fei_task_var");
09052 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX",
09053 PDG_AT_IDX(IL_IDX(list_idx2)));
09054 PDG_DBG_PRINT_S("(2) context",
09055 p_tasking_context[Context_Private]);
09056 PDG_DBG_PRINT_END
09057
09058 # ifdef _ENABLE_FEI
09059 last_task_idx = fei_task_var(PDG_AT_IDX(IL_IDX(list_idx2)),
09060 Context_Private);
09061 # endif
09062
09063 if (first_task_idx == NULL_IDX) {
09064 first_task_idx = last_task_idx;
09065 }
09066 }
09067
09068 list_idx2 = IL_NEXT_LIST_IDX(list_idx2);
09069 }
09070 }
09071
09072
09073
09074 if (IL_FLD(list_array[3]) == IL_Tbl_Idx) {
09075 list_idx2 = IL_IDX(list_array[3]);
09076
09077 while (list_idx2) {
09078 if (IL_FLD(list_idx2) == AT_Tbl_Idx) {
09079 send_attr_ntry(IL_IDX(list_idx2));
09080
09081 PDG_DBG_PRINT_START
09082 PDG_DBG_PRINT_C("fei_task_var");
09083 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX",
09084 PDG_AT_IDX(IL_IDX(list_idx2)));
09085 PDG_DBG_PRINT_S("(2) context",
09086 p_tasking_context[Context_Getfirst]);
09087 PDG_DBG_PRINT_END
09088
09089 # ifdef _ENABLE_FEI
09090 last_task_idx = fei_task_var(PDG_AT_IDX(IL_IDX(list_idx2)),
09091 Context_Getfirst);
09092 # endif
09093
09094 if (first_task_idx == NULL_IDX) {
09095 first_task_idx = last_task_idx;
09096 }
09097 }
09098
09099 list_idx2 = IL_NEXT_LIST_IDX(list_idx2);
09100 }
09101 }
09102
09103
09104
09105 if (IL_FLD(list_array[5]) == IL_Tbl_Idx) {
09106 list_idx2 = IL_IDX(list_array[5]);
09107
09108 while (list_idx2) {
09109 if (IL_FLD(list_idx2) == AT_Tbl_Idx) {
09110 send_attr_ntry(IL_IDX(list_idx2));
09111
09112 PDG_DBG_PRINT_START
09113 PDG_DBG_PRINT_C("fei_task_var");
09114 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX",
09115 PDG_AT_IDX(IL_IDX(list_idx2)));
09116 PDG_DBG_PRINT_S("(2) context",
09117 p_tasking_context[Context_Control]);
09118 PDG_DBG_PRINT_END
09119
09120 # ifdef _ENABLE_FEI
09121 last_task_idx = fei_task_var(PDG_AT_IDX(IL_IDX(list_idx2)),
09122 Context_Control);
09123 # endif
09124
09125 if (first_task_idx == NULL_IDX) {
09126 first_task_idx = last_task_idx;
09127 }
09128 }
09129
09130 list_idx2 = IL_NEXT_LIST_IDX(list_idx2);
09131 }
09132 }
09133
09134 i = 0L;
09135
09136 if (IL_FLD(list_array[4]) == CN_Tbl_Idx) {
09137 i = 2;
09138 }
09139
09140 if (IL_FLD(list_array[0]) == NO_Tbl_Idx) {
09141 task_if_idx = 0;
09142 }
09143 else {
09144 send_attr_ntry(IL_IDX(list_array[0]));
09145 task_if_idx = PDG_AT_IDX(IL_IDX(list_array[0]));
09146 }
09147
09148 if (IL_FLD(list_array[6]) == NO_Tbl_Idx) {
09149 task_maxcpus_idx = 0;
09150 }
09151 else {
09152 send_attr_ntry(IL_IDX(list_array[6]));
09153 task_maxcpus_idx = PDG_AT_IDX(IL_IDX(list_array[6]));
09154 }
09155
09156 PDG_DBG_PRINT_START
09157 PDG_DBG_PRINT_C("fei_parallel_region");
09158 PDG_DBG_PRINT_D("(1) if idx", task_if_idx);
09159 PDG_DBG_PRINT_D("(2) maxcpus idx", task_maxcpus_idx);
09160 PDG_DBG_PRINT_D("(3) first task idx", first_task_idx);
09161 PDG_DBG_PRINT_D("(4) last task idx", last_task_idx);
09162 PDG_DBG_PRINT_D("(5) line num", IR_LINE_NUM(ir_idx));
09163 PDG_DBG_PRINT_D("(6) ", (int) i);
09164 PDG_DBG_PRINT_END
09165
09166 # ifdef _ENABLE_FEI
09167 parallel_cmic_vpr_idx = fei_parallel_region(task_if_idx,
09168 task_maxcpus_idx,
09169 first_task_idx,
09170 last_task_idx,
09171 IR_LINE_NUM(ir_idx),
09172 i);
09173 # endif
09174
09175 break;
09176
09177
09178
09179
09180
09181 case Endparallel_Cmic_Opr:
09182 PDG_DBG_PRINT_START
09183 PDG_DBG_PRINT_C("fei_endparallel_region");
09184 PDG_DBG_PRINT_D("(1) cmic vpr idx", doparallel_cmic_vpr_idx);
09185 PDG_DBG_PRINT_D("(2) line num", IR_LINE_NUM(ir_idx));
09186 PDG_DBG_PRINT_END
09187
09188 # ifdef _ENABLE_FEI
09189 fei_endparallel_region(parallel_cmic_vpr_idx, IR_LINE_NUM(ir_idx));
09190 # endif
09191 parallel_cmic_vpr_idx = NULL_IDX;
09192 break;
09193
09194
09195
09196
09197
09198 case Suppress_Opr:
09199 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
09200 IR_FLD_L(ir_idx));
09201
09202 send_label_def(ir_idx);
09203 break;
09204
09205
09206 case Use_Opr:
09207
09208 # if defined(_MODULE_TO_DOT_o)
09209 if (!on_off_flags.module_to_mod &&
09210 # else
09211 if (
09212 # endif
09213 !ATP_IN_CURRENT_COMPILE(IR_IDX_L(ir_idx))) {
09214
09215 PDG_DBG_PRINT_START
09216 PDG_DBG_PRINT_C("fei_next_name");
09217 PDG_DBG_PRINT_D("(1) logical", TRUE);
09218 PDG_DBG_PRINT_END
09219
09220 # ifdef _ENABLE_FEI
09221 path_idx = fei_next_name(TRUE);
09222 # endif
09223
09224 PDG_DBG_PRINT_START
09225 PDG_DBG_PRINT_C("fei_name");
09226 PDG_DBG_PRINT_S("(1) name_ptr",
09227 &name_pool[ATP_MOD_PATH_IDX(IR_IDX_L(ir_idx))].name_char);
09228 PDG_DBG_PRINT_D("(2) unused", 0);
09229 PDG_DBG_PRINT_D("(3) unused", 0);
09230 PDG_DBG_PRINT_D("(4) unused", 0);
09231 PDG_DBG_PRINT_D("(5) index to use", path_idx);
09232 PDG_DBG_PRINT_END
09233
09234 # ifdef _ENABLE_FEI
09235 fei_name(&name_pool[ATP_MOD_PATH_IDX(IR_IDX_L(ir_idx))].name_char,
09236 0,
09237 0,
09238 0,
09239 path_idx);
09240 # endif
09241
09242
09243 PDG_DBG_PRINT_START
09244 PDG_DBG_PRINT_C("fei_next_name");
09245 PDG_DBG_PRINT_D("(1) logical", TRUE);
09246 PDG_DBG_PRINT_END
09247
09248 # ifdef _ENABLE_FEI
09249 name_idx = fei_next_name(TRUE);
09250 # endif
09251
09252 PDG_DBG_PRINT_START
09253 PDG_DBG_PRINT_C("fei_name");
09254 PDG_DBG_PRINT_S("(1) AT_OBJ_NAME",
09255 AT_OBJ_NAME_PTR(IR_IDX_L(ir_idx)));
09256 PDG_DBG_PRINT_D("(2) unused", 0);
09257 PDG_DBG_PRINT_D("(3) unused", 0);
09258 PDG_DBG_PRINT_D("(4) unused", 0);
09259 PDG_DBG_PRINT_D("(5) index to use", name_idx);
09260 PDG_DBG_PRINT_END
09261
09262 # ifdef _ENABLE_FEI
09263 fei_name(AT_OBJ_NAME_PTR(IR_IDX_L(ir_idx)),
09264 0,
09265 0,
09266 0,
09267 name_idx);
09268 # endif
09269
09270 PDG_DBG_PRINT_START
09271 PDG_DBG_PRINT_C("fei_add_use_path");
09272 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX",
09273 PDG_AT_IDX(SCP_ATTR_IDX(curr_scp_idx)));
09274 PDG_DBG_PRINT_D("(2) path index", path_idx);
09275 PDG_DBG_PRINT_D("(3) name index", name_idx);
09276 PDG_DBG_PRINT_END
09277
09278 # ifdef _ENABLE_FEI
09279 fei_add_use_path(PDG_AT_IDX(SCP_ATTR_IDX(curr_scp_idx)),
09280 path_idx,
09281 name_idx);
09282 # endif
09283 }
09284 break;
09285
09286
09287
09288
09289 case Symbolic_Mult_Opr:
09290 save_symbolic_constant_expr = symbolic_constant_expr;
09291 symbolic_constant_expr = TRUE;
09292
09293 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
09294 IR_FLD_L(ir_idx));
09295
09296 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
09297 IR_FLD_R(ir_idx));
09298
09299 PDG_DBG_PRINT_START
09300 PDG_DBG_PRINT_C("npex_mult");
09301 PDG_DBG_PRINT_END
09302
09303 # ifdef _ENABLE_FEI
09304 npex_mult();
09305 # endif
09306
09307 symbolic_constant_expr = save_symbolic_constant_expr;
09308
09309 if (!symbolic_constant_expr) {
09310 finish_symbolic_expr();
09311 }
09312 break;
09313
09314
09315
09316
09317
09318 case Symbolic_Div_Opr:
09319 save_symbolic_constant_expr = symbolic_constant_expr;
09320 symbolic_constant_expr = TRUE;
09321
09322 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
09323 IR_FLD_L(ir_idx));
09324
09325 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
09326 IR_FLD_R(ir_idx));
09327
09328 PDG_DBG_PRINT_START
09329 PDG_DBG_PRINT_C("npex_div");
09330 PDG_DBG_PRINT_END
09331
09332 # ifdef _ENABLE_FEI
09333 npex_div();
09334 # endif
09335
09336 symbolic_constant_expr = save_symbolic_constant_expr;
09337
09338 if (!symbolic_constant_expr) {
09339 finish_symbolic_expr();
09340 }
09341 break;
09342
09343
09344
09345
09346 case Symbolic_Plus_Opr:
09347 save_symbolic_constant_expr = symbolic_constant_expr;
09348 symbolic_constant_expr = TRUE;
09349
09350 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
09351 IR_FLD_L(ir_idx));
09352
09353 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
09354 IR_FLD_R(ir_idx));
09355
09356 PDG_DBG_PRINT_START
09357 PDG_DBG_PRINT_C("npex_plus");
09358 PDG_DBG_PRINT_END
09359
09360 # ifdef _ENABLE_FEI
09361 npex_plus();
09362 # endif
09363
09364 symbolic_constant_expr = save_symbolic_constant_expr;
09365
09366 if (!symbolic_constant_expr) {
09367 finish_symbolic_expr();
09368 }
09369 break;
09370
09371
09372
09373
09374
09375 case Symbolic_Minus_Opr:
09376 save_symbolic_constant_expr = symbolic_constant_expr;
09377 symbolic_constant_expr = TRUE;
09378
09379 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
09380 IR_FLD_L(ir_idx));
09381
09382 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
09383 IR_FLD_R(ir_idx));
09384
09385 PDG_DBG_PRINT_START
09386 PDG_DBG_PRINT_C("npex_minus");
09387 PDG_DBG_PRINT_END
09388
09389 # ifdef _ENABLE_FEI
09390 npex_minus();
09391 # endif
09392
09393 symbolic_constant_expr = save_symbolic_constant_expr;
09394
09395 if (!symbolic_constant_expr) {
09396 finish_symbolic_expr();
09397 }
09398 break;
09399
09400
09401
09402
09403
09404 case Symbolic_Uminus_Opr :
09405 save_symbolic_constant_expr = symbolic_constant_expr;
09406 symbolic_constant_expr = TRUE;
09407
09408 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
09409 IR_FLD_L(ir_idx));
09410
09411 PDG_DBG_PRINT_START
09412 PDG_DBG_PRINT_C("npex_uminus");
09413 PDG_DBG_PRINT_END
09414
09415 # ifdef _ENABLE_FEI
09416 npex_uminus();
09417 # endif
09418
09419 symbolic_constant_expr = save_symbolic_constant_expr;
09420
09421 if (!symbolic_constant_expr) {
09422 finish_symbolic_expr();
09423 }
09424 break;
09425
09426
09427
09428
09429 case Symbolic_Uplus_Opr :
09430 save_symbolic_constant_expr = symbolic_constant_expr;
09431 symbolic_constant_expr = TRUE;
09432
09433 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
09434 IR_FLD_L(ir_idx));
09435
09436
09437 symbolic_constant_expr = save_symbolic_constant_expr;
09438
09439 if (!symbolic_constant_expr) {
09440 finish_symbolic_expr();
09441 }
09442 break;
09443
09444
09445
09446
09447 case Symbolic_Mod_Opr:
09448 save_symbolic_constant_expr = symbolic_constant_expr;
09449 symbolic_constant_expr = TRUE;
09450
09451 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
09452 IR_FLD_L(ir_idx));
09453
09454 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
09455 IR_FLD_R(ir_idx));
09456
09457 PDG_DBG_PRINT_START
09458 PDG_DBG_PRINT_C("npex_mod");
09459 PDG_DBG_PRINT_END
09460
09461 # ifdef _ENABLE_FEI
09462 npex_mod();
09463 # endif
09464
09465 symbolic_constant_expr = save_symbolic_constant_expr;
09466
09467 if (!symbolic_constant_expr) {
09468 finish_symbolic_expr();
09469 }
09470 break;
09471
09472
09473
09474
09475 case Symbolic_Shiftr_Opr:
09476 save_symbolic_constant_expr = symbolic_constant_expr;
09477 symbolic_constant_expr = TRUE;
09478
09479 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
09480 IR_FLD_L(ir_idx));
09481
09482 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
09483 IR_FLD_R(ir_idx));
09484
09485 PDG_DBG_PRINT_START
09486 PDG_DBG_PRINT_C("npex_shiftr");
09487 PDG_DBG_PRINT_END
09488
09489 # ifdef _ENABLE_FEI
09490 npex_shiftr();
09491 # endif
09492
09493 symbolic_constant_expr = save_symbolic_constant_expr;
09494
09495 if (!symbolic_constant_expr) {
09496 finish_symbolic_expr();
09497 }
09498 break;
09499
09500
09501
09502
09503
09504 case Symbolic_Shiftl_Opr:
09505 save_symbolic_constant_expr = symbolic_constant_expr;
09506 symbolic_constant_expr = TRUE;
09507
09508 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
09509 IR_FLD_L(ir_idx));
09510
09511 cvrt_exp_to_pdg(IR_IDX_R(ir_idx),
09512 IR_FLD_R(ir_idx));
09513
09514 PDG_DBG_PRINT_START
09515 PDG_DBG_PRINT_C("npex_shiftl");
09516 PDG_DBG_PRINT_END
09517
09518 # ifdef _ENABLE_FEI
09519 npex_shiftl();
09520 # endif
09521
09522 symbolic_constant_expr = save_symbolic_constant_expr;
09523
09524 if (!symbolic_constant_expr) {
09525 finish_symbolic_expr();
09526 }
09527 break;
09528
09529
09530
09531
09532
09533 case Symbolic_Max_Opr :
09534 save_symbolic_constant_expr = symbolic_constant_expr;
09535 symbolic_constant_expr = TRUE;
09536
09537 tmp_ir_idx = IR_IDX_L(ir_idx);
09538 count = 0;
09539
09540 while (tmp_ir_idx != NULL_IDX) {
09541
09542 if (IL_IDX(tmp_ir_idx) != NULL_IDX) {
09543 cvrt_exp_to_pdg(IL_IDX(tmp_ir_idx),
09544 IL_FLD(tmp_ir_idx));
09545 count += 1;
09546 }
09547 tmp_ir_idx = IL_NEXT_LIST_IDX(tmp_ir_idx);
09548 }
09549
09550
09551 PDG_DBG_PRINT_START
09552 PDG_DBG_PRINT_C("npex_max");
09553 PDG_DBG_PRINT_END
09554
09555 # ifdef _TARGET_OS_MAX
09556 # ifdef _ENABLE_FEI
09557 npex_max();
09558 # endif
09559 # endif
09560
09561 symbolic_constant_expr = save_symbolic_constant_expr;
09562
09563 if (!symbolic_constant_expr) {
09564 finish_symbolic_expr();
09565 }
09566 break;
09567
09568
09569
09570
09571
09572 case Symbolic_Min_Opr :
09573 save_symbolic_constant_expr = symbolic_constant_expr;
09574 symbolic_constant_expr = TRUE;
09575
09576 tmp_ir_idx = IR_IDX_L(ir_idx);
09577 count = 0;
09578
09579 while (tmp_ir_idx != NULL_IDX) {
09580
09581 if (IL_IDX(tmp_ir_idx) != NULL_IDX) {
09582 cvrt_exp_to_pdg(IL_IDX(tmp_ir_idx),
09583 IL_FLD(tmp_ir_idx));
09584 count += 1;
09585 }
09586 tmp_ir_idx = IL_NEXT_LIST_IDX(tmp_ir_idx);
09587 }
09588
09589
09590 PDG_DBG_PRINT_START
09591 PDG_DBG_PRINT_C("npex_min");
09592 PDG_DBG_PRINT_END
09593
09594 # ifdef _TARGET_OS_MAX
09595 # ifdef _ENABLE_FEI
09596 npex_min();
09597 # endif
09598 # endif
09599
09600 symbolic_constant_expr = save_symbolic_constant_expr;
09601
09602 if (!symbolic_constant_expr) {
09603 finish_symbolic_expr();
09604 }
09605 break;
09606
09607
09608
09609 case Parallel_Open_Mp_Opr:
09610 case Do_Open_Mp_Opr:
09611 case Sections_Open_Mp_Opr:
09612 case Single_Open_Mp_Opr:
09613 case Workshare_Open_Mp_Opr:
09614 case Paralleldo_Open_Mp_Opr:
09615 case Parallelsections_Open_Mp_Opr:
09616 case Parallelworkshare_Open_Mp_Opr:
09617 list_idx1 = IR_IDX_L(ir_idx);
09618
09619 for (i = 0; i < OPEN_MP_LIST_CNT; i++) {
09620 list_array[i] = list_idx1;
09621 list_idx1 = IL_NEXT_LIST_IDX(list_idx1);
09622 }
09623
09624
09625
09626 if (IL_FLD(list_array[OPEN_MP_IF_IDX]) == AT_Tbl_Idx) {
09627 send_attr_ntry(IL_IDX(list_array[OPEN_MP_IF_IDX]));
09628 task_if_idx = PDG_AT_IDX(IL_IDX(list_array[OPEN_MP_IF_IDX]));
09629 }
09630
09631
09632 if(IL_FLD(list_array[OPEN_MP_NUM_THREADS]) == AT_Tbl_Idx){
09633 send_attr_ntry(IL_IDX(list_array[OPEN_MP_NUM_THREADS]));
09634 task_num_threads_idx = PDG_AT_IDX(IL_IDX(list_array[OPEN_MP_NUM_THREADS]));
09635 }
09636
09637
09638
09639
09640
09641 if (IL_FLD(list_array[OPEN_MP_PRIVATE_IDX]) == IL_Tbl_Idx) {
09642 list_idx2 = IL_IDX(list_array[OPEN_MP_PRIVATE_IDX]);
09643
09644 while (list_idx2) {
09645 if (IL_FLD(list_idx2) == AT_Tbl_Idx) {
09646 send_attr_ntry(IL_IDX(list_idx2));
09647
09648 PDG_DBG_PRINT_START
09649 PDG_DBG_PRINT_C("fei_task_var");
09650 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX",
09651 PDG_AT_IDX(IL_IDX(list_idx2)));
09652 PDG_DBG_PRINT_S("(2) context",
09653 p_tasking_context[Context_Omp_Private]);
09654 PDG_DBG_PRINT_END
09655
09656 # ifdef _ENABLE_FEI
09657 last_task_idx = fei_task_var(PDG_AT_IDX(IL_IDX(list_idx2)),
09658 Context_Omp_Private);
09659 # endif
09660
09661 }
09662
09663 list_idx2 = IL_NEXT_LIST_IDX(list_idx2);
09664 }
09665 }
09666
09667
09668
09669
09670 if (IL_FLD(list_array[OPEN_MP_SHARED_IDX]) == IL_Tbl_Idx) {
09671 list_idx2 = IL_IDX(list_array[OPEN_MP_SHARED_IDX]);
09672
09673 while (list_idx2) {
09674 if (IL_FLD(list_idx2) == AT_Tbl_Idx) {
09675 send_attr_ntry(IL_IDX(list_idx2));
09676
09677 PDG_DBG_PRINT_START
09678 PDG_DBG_PRINT_C("fei_task_var");
09679 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX",
09680 PDG_AT_IDX(IL_IDX(list_idx2)));
09681 PDG_DBG_PRINT_S("(2) context",
09682 p_tasking_context[Context_Omp_Shared]);
09683 PDG_DBG_PRINT_END
09684
09685 # ifdef _ENABLE_FEI
09686 last_task_idx = fei_task_var(PDG_AT_IDX(IL_IDX(list_idx2)),
09687 Context_Omp_Shared);
09688 # endif
09689
09690 }
09691
09692 list_idx2 = IL_NEXT_LIST_IDX(list_idx2);
09693 }
09694 }
09695
09696
09697
09698
09699 if (IL_FLD(list_array[OPEN_MP_FIRSTPRIVATE_IDX]) == IL_Tbl_Idx) {
09700 list_idx2 = IL_IDX(list_array[OPEN_MP_FIRSTPRIVATE_IDX]);
09701
09702 while (list_idx2) {
09703 if (IL_FLD(list_idx2) == AT_Tbl_Idx) {
09704 send_attr_ntry(IL_IDX(list_idx2));
09705
09706 PDG_DBG_PRINT_START
09707 PDG_DBG_PRINT_C("fei_task_var");
09708 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX",
09709 PDG_AT_IDX(IL_IDX(list_idx2)));
09710 PDG_DBG_PRINT_S("(2) context",
09711 p_tasking_context[Context_Omp_Firstprivate]);
09712 PDG_DBG_PRINT_END
09713
09714 # ifdef _ENABLE_FEI
09715 last_task_idx = fei_task_var(PDG_AT_IDX(IL_IDX(list_idx2)),
09716 Context_Omp_Firstprivate);
09717 # endif
09718
09719 }
09720
09721 list_idx2 = IL_NEXT_LIST_IDX(list_idx2);
09722 }
09723 }
09724
09725
09726
09727
09728 if (IL_FLD(list_array[OPEN_MP_DEFAULT_IDX]) == CN_Tbl_Idx) {
09729 defaultt =(long)CN_INT_TO_C(IL_IDX(list_array[OPEN_MP_DEFAULT_IDX]));
09730 }
09731
09732
09733
09734
09735
09736 if (IL_FLD(list_array[OPEN_MP_COPYIN_IDX]) == IL_Tbl_Idx) {
09737 list_idx2 = IL_IDX(list_array[OPEN_MP_COPYIN_IDX]);
09738
09739 while (list_idx2) {
09740 if (IL_FLD(list_idx2) == AT_Tbl_Idx) {
09741 send_attr_ntry(IL_IDX(list_idx2));
09742
09743 PDG_DBG_PRINT_START
09744 PDG_DBG_PRINT_C("fei_task_var");
09745 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX",
09746 PDG_AT_IDX(IL_IDX(list_idx2)));
09747 PDG_DBG_PRINT_S("(2) context",
09748 p_tasking_context[Context_Omp_Copyin]);
09749 PDG_DBG_PRINT_END
09750
09751 # ifdef _ENABLE_FEI
09752 last_task_idx = fei_task_var(PDG_AT_IDX(IL_IDX(list_idx2)),
09753 Context_Omp_Copyin);
09754 # endif
09755
09756 }
09757
09758 list_idx2 = IL_NEXT_LIST_IDX(list_idx2);
09759 }
09760 }
09761
09762
09763
09764
09765
09766
09767 if (IL_FLD(list_array[OPEN_MP_REDUCTION_OPR_IDX]) == IL_Tbl_Idx &&
09768 IL_FLD(list_array[OPEN_MP_REDUCTION_LIST_IDX]) == IL_Tbl_Idx) {
09769 list_idx2 = IL_IDX(list_array[OPEN_MP_REDUCTION_OPR_IDX]);
09770 list_idx3 = IL_IDX(list_array[OPEN_MP_REDUCTION_LIST_IDX]);
09771
09772 while (list_idx2) {
09773 if (IL_FLD(list_idx2) == IR_Tbl_Idx &&
09774 IL_FLD(list_idx3) == IL_Tbl_Idx) {
09775 switch (IR_OPR(IL_IDX(list_idx2))) {
09776 case Max_Opr :
09777 context = Context_Omp_Reduction_Max;
09778 break;
09779 case Min_Opr :
09780 context = Context_Omp_Reduction_Min;
09781 break;
09782 case Band_Opr :
09783 context = Context_Omp_Reduction_Band;
09784 break;
09785 case Bor_Opr :
09786 context = Context_Omp_Reduction_Bor;
09787 break;
09788 case Bneqv_Opr :
09789 context = Context_Omp_Reduction_Bneqv;
09790 break;
09791 case Plus_Opr :
09792 context = Context_Omp_Reduction_Plus;
09793 break;
09794 case Mult_Opr :
09795 context = Context_Omp_Reduction_Mult;
09796 break;
09797 case Minus_Opr :
09798 context = Context_Omp_Reduction_Minus;
09799 break;
09800 case And_Opr :
09801 context = Context_Omp_Reduction_And;
09802 break;
09803 case Or_Opr :
09804 context = Context_Omp_Reduction_Or;
09805 break;
09806 case Eqv_Opr :
09807 context = Context_Omp_Reduction_Eqv;
09808 break;
09809 case Neqv_Opr :
09810 context = Context_Omp_Reduction_Neqv;
09811 break;
09812 }
09813 list_idx4 = IL_IDX(list_idx3);
09814 while (list_idx4) {
09815
09816 if (IL_FLD(list_idx4) == AT_Tbl_Idx) {
09817 send_attr_ntry(IL_IDX(list_idx4));
09818
09819 PDG_DBG_PRINT_START
09820 PDG_DBG_PRINT_C("fei_task_var");
09821 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX",
09822 PDG_AT_IDX(IL_IDX(list_idx4)));
09823 PDG_DBG_PRINT_S("(2) context",
09824 p_tasking_context[context]);
09825 PDG_DBG_PRINT_END
09826
09827 # ifdef _ENABLE_FEI
09828 last_task_idx = fei_task_var(
09829 PDG_AT_IDX(IL_IDX(list_idx4)),
09830 context);
09831 # endif
09832 }
09833 list_idx4 = IL_NEXT_LIST_IDX(list_idx4);
09834 }
09835 }
09836
09837 list_idx2 = IL_NEXT_LIST_IDX(list_idx2);
09838 list_idx3 = IL_NEXT_LIST_IDX(list_idx3);
09839 }
09840 }
09841
09842
09843
09844
09845
09846
09847
09848 if (IL_FLD(list_array[OPEN_MP_LASTPRIVATE_IDX]) == IL_Tbl_Idx) {
09849 list_idx2 = IL_IDX(list_array[OPEN_MP_LASTPRIVATE_IDX]);
09850
09851 while (list_idx2) {
09852 if (IL_FLD(list_idx2) == AT_Tbl_Idx) {
09853 send_attr_ntry(IL_IDX(list_idx2));
09854
09855 PDG_DBG_PRINT_START
09856 PDG_DBG_PRINT_C("fei_task_var");
09857 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX",
09858 PDG_AT_IDX(IL_IDX(list_idx2)));
09859 PDG_DBG_PRINT_S("(2) context",
09860 p_tasking_context[Context_Omp_Lastprivate]);
09861 PDG_DBG_PRINT_END
09862
09863 # ifdef _ENABLE_FEI
09864 last_task_idx = fei_task_var(PDG_AT_IDX(IL_IDX(list_idx2)),
09865 Context_Omp_Lastprivate);
09866 # endif
09867
09868 }
09869
09870 list_idx2 = IL_NEXT_LIST_IDX(list_idx2);
09871 }
09872 }
09873
09874
09875
09876
09877
09878 if (IL_FLD(list_array[OPEN_MP_ORDERED_IDX]) == CN_Tbl_Idx) {
09879 ordered = (long)CN_INT_TO_C(IL_IDX(list_array[OPEN_MP_ORDERED_IDX]));
09880 }
09881
09882
09883
09884
09885 if (IL_FLD(list_array[OPEN_MP_SCHEDULE_TYPE_IDX]) == CN_Tbl_Idx) {
09886 scheduletype = (long)
09887 CN_INT_TO_C(IL_IDX(list_array[OPEN_MP_SCHEDULE_TYPE_IDX]));
09888 }
09889
09890
09891
09892
09893 if (IL_FLD(list_array[OPEN_MP_SCHEDULE_CHUNK_IDX]) == AT_Tbl_Idx) {
09894 send_attr_ntry(IL_IDX(list_array[OPEN_MP_SCHEDULE_CHUNK_IDX]));
09895 schedulechunk =
09896 PDG_AT_IDX(IL_IDX(list_array[OPEN_MP_SCHEDULE_CHUNK_IDX]));
09897 }
09898
09899
09900 if (IL_FLD(list_array[OPEN_MP_NEST_IDX]) == IL_Tbl_Idx) {
09901 list_idx2 = IL_IDX(list_array[OPEN_MP_NEST_IDX]);
09902
09903 while (list_idx2) {
09904 if (IL_FLD(list_idx2) == AT_Tbl_Idx) {
09905 send_attr_ntry(IL_IDX(list_idx2));
09906
09907 PDG_DBG_PRINT_START
09908 PDG_DBG_PRINT_C("fei_task_var");
09909 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX",
09910 PDG_AT_IDX(IL_IDX(list_idx2)));
09911 PDG_DBG_PRINT_S("(2) context",
09912 p_tasking_context[Context_Omp_Nest]);
09913 PDG_DBG_PRINT_END
09914
09915 # ifdef _ENABLE_FEI
09916 last_task_idx = fei_task_var(PDG_AT_IDX(IL_IDX(list_idx2)),
09917 Context_Omp_Nest);
09918 # endif
09919
09920 }
09921
09922 list_idx2 = IL_NEXT_LIST_IDX(list_idx2);
09923 }
09924 }
09925
09926
09927
09928
09929 if (IL_FLD(list_array[OPEN_MP_AFFINITY_IDX]) == IL_Tbl_Idx) {
09930 list_idx2 = IL_IDX(list_array[OPEN_MP_AFFINITY_IDX]);
09931
09932 while (list_idx2 != NULL_IDX) {
09933 if (IL_FLD(list_idx2) == AT_Tbl_Idx) {
09934 send_attr_ntry(IL_IDX(list_idx2));
09935
09936 PDG_DBG_PRINT_START
09937 PDG_DBG_PRINT_C("fei_task_var");
09938 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX",
09939 PDG_AT_IDX(IL_IDX(list_idx2)));
09940 PDG_DBG_PRINT_S("(2) context",
09941 p_tasking_context[Context_Omp_Affinity]);
09942 PDG_DBG_PRINT_END
09943
09944 # ifdef _ENABLE_FEI
09945 last_task_idx = fei_task_var(PDG_AT_IDX(IL_IDX(list_idx2)),
09946 Context_Omp_Affinity);
09947 # endif
09948
09949 }
09950
09951 list_idx2 = IL_NEXT_LIST_IDX(list_idx2);
09952 }
09953
09954 cvrt_exp_to_pdg(IL_IDX(list_array[OPEN_MP_THREAD_DATA_IDX]),
09955 IL_FLD(list_array[OPEN_MP_THREAD_DATA_IDX]));
09956
09957 cvrt_exp_to_pdg(IL_IDX(list_array[OPEN_MP_THREAD_DATA_IDX]),
09958 IL_FLD(list_array[OPEN_MP_THREAD_DATA_IDX]));
09959
09960 which = (long)CN_INT_TO_C(IL_IDX(list_array[OPEN_MP_IS_THREAD_IDX]));
09961 if (which == 1) {
09962 threadcount = 1;
09963 }
09964 else {
09965 datacount = 1;
09966 }
09967 }
09968
09969
09970
09971
09972
09973 if (IL_FLD(list_array[OPEN_MP_ONTO_IDX]) == IL_Tbl_Idx) {
09974 list_idx2 = IL_IDX(list_array[OPEN_MP_ONTO_IDX]);
09975
09976 ontocount = 0;
09977 while (list_idx2 != NULL_IDX) {
09978 cvrt_exp_to_pdg(IL_IDX(list_idx2),
09979 IL_FLD(list_idx2));
09980
09981 list_idx2 = IL_NEXT_LIST_IDX(list_idx2);
09982 ontocount = ontocount + 1;
09983 }
09984 }
09985
09986
09987
09988 switch (IR_OPR(ir_idx)) {
09989
09990 case Parallel_Open_Mp_Opr:
09991 PDG_DBG_PRINT_START
09992 PDG_DBG_PRINT_C("fei_parallel_open_mp");
09993 PDG_DBG_PRINT_D("(1) if idx", task_if_idx);
09994 PDG_DBG_PRINT_D("(2) num_threads idx", task_num_threads_idx);
09995 PDG_DBG_PRINT_LD("(3) defaultt", defaultt);
09996 PDG_DBG_PRINT_END
09997
09998 # ifdef _ENABLE_FEI
09999 fei_parallel_open_mp(task_if_idx,
10000 task_num_threads_idx,
10001 defaultt);
10002
10003 # endif
10004 break;
10005
10006
10007
10008 case Do_Open_Mp_Opr:
10009 PDG_DBG_PRINT_START
10010 PDG_DBG_PRINT_C("fei_do_open_mp");
10011 PDG_DBG_PRINT_LD("(1) ordered", ordered);
10012 PDG_DBG_PRINT_LD("(2) scheduletype", scheduletype);
10013 PDG_DBG_PRINT_D("(3) schedulechunk", schedulechunk);
10014 PDG_DBG_PRINT_LD("(4) threadcount", threadcount);
10015 PDG_DBG_PRINT_LD("(5) datacount", datacount);
10016 PDG_DBG_PRINT_LD("(6) ontocount", ontocount);
10017 PDG_DBG_PRINT_END
10018
10019 # ifdef _ENABLE_FEI
10020 fei_do_open_mp(ordered,
10021 scheduletype,
10022 schedulechunk,
10023 threadcount,
10024 datacount,
10025 ontocount);
10026 # endif
10027 break;
10028
10029
10030
10031 case Sections_Open_Mp_Opr:
10032 PDG_DBG_PRINT_START
10033 PDG_DBG_PRINT_C("fei_sections_open_mp");
10034 PDG_DBG_PRINT_END
10035
10036
10037 # ifdef _ENABLE_FEI
10038 fei_sections_open_mp();
10039 # endif
10040 break;
10041
10042
10043
10044
10045
10046 case Single_Open_Mp_Opr:
10047 PDG_DBG_PRINT_START
10048 PDG_DBG_PRINT_C("fei_single_open_mp");
10049 PDG_DBG_PRINT_END
10050
10051
10052 # ifdef _ENABLE_FEI
10053 fei_single_open_mp();
10054 # endif
10055 break;
10056
10057 case Workshare_Open_Mp_Opr:
10058 PDG_DBG_PRINT_START
10059 PDG_DBG_PRINT_C("fei_workshare_open_mp");
10060 PDG_DBG_PRINT_END
10061
10062 # ifdef _ENABLE_FEI
10063 fei_workshare_open_mp();
10064 # endif
10065 break;
10066
10067 case Parallelworkshare_Open_Mp_Opr:
10068 PDG_DBG_PRINT_START
10069 PDG_DBG_PRINT_C("fei_parallelworkshare_open_mp");
10070 PDG_DBG_PRINT_D("(1) if idx", task_if_idx);
10071 PDG_DBG_PRINT_D("(2) num_threads idx", task_num_threads_idx);
10072 PDG_DBG_PRINT_LD("(3) defaultt", defaultt);
10073 PDG_DBG_PRINT_END
10074
10075 # ifdef _ENABLE_FEI
10076 fei_parallelworkshare_open_mp(task_if_idx,
10077 task_num_threads_idx,
10078 defaultt);
10079 # endif
10080 break;
10081
10082 case Paralleldo_Open_Mp_Opr:
10083 PDG_DBG_PRINT_START
10084 PDG_DBG_PRINT_C("fei_paralleldo_open_mp");
10085 PDG_DBG_PRINT_D("(1) if idx", task_if_idx);
10086 PDG_DBG_PRINT_D("(2) num_threads idx", task_num_threads_idx);
10087 PDG_DBG_PRINT_LD("(3) defaultt", defaultt);
10088 PDG_DBG_PRINT_LD("(4) ordered", ordered);
10089 PDG_DBG_PRINT_LD("(5) scheduletype", scheduletype);
10090 PDG_DBG_PRINT_D("(6) schedulechunk", schedulechunk);
10091 PDG_DBG_PRINT_LD("(7) threadcount", threadcount);
10092 PDG_DBG_PRINT_LD("(8) datacount", datacount);
10093 PDG_DBG_PRINT_LD("(9) ontocount", ontocount);
10094 PDG_DBG_PRINT_END
10095
10096
10097 # ifdef _ENABLE_FEI
10098 fei_paralleldo_open_mp(task_if_idx,
10099 task_num_threads_idx,
10100 defaultt,
10101 ordered,
10102 scheduletype,
10103 schedulechunk,
10104 threadcount,
10105 datacount,
10106 ontocount);
10107 # endif
10108 break;
10109
10110 case Parallelsections_Open_Mp_Opr:
10111 PDG_DBG_PRINT_START
10112 PDG_DBG_PRINT_C("fei_parallelsections_open_mp");
10113 PDG_DBG_PRINT_D("(1) if idx", task_if_idx);
10114 PDG_DBG_PRINT_D("(2) num_threads idx", task_num_threads_idx);
10115 PDG_DBG_PRINT_LD("(3) defaultt", defaultt);
10116 PDG_DBG_PRINT_END
10117
10118
10119 # ifdef _ENABLE_FEI
10120 fei_parallelsections_open_mp(task_if_idx,
10121 task_num_threads_idx,
10122 defaultt);
10123 # endif
10124 break;
10125 }
10126 break;
10127
10128
10129 case Endworkshare_Open_Mp_Opr:
10130 if (IR_FLD_L(ir_idx) == CN_Tbl_Idx) {
10131 nowait = (long) CN_INT_TO_C(IR_IDX_L(ir_idx));
10132 }
10133
10134 PDG_DBG_PRINT_START
10135 PDG_DBG_PRINT_C("fei_endworkshare_open_mp");
10136 PDG_DBG_PRINT_LD("(1) nowait", nowait);
10137 PDG_DBG_PRINT_END
10138
10139 # ifdef _ENABLE_FEI
10140 fei_endworkshare_open_mp(nowait);
10141 # endif
10142 break;
10143
10144 case Endparallelworkshare_Open_Mp_Opr:
10145 PDG_DBG_PRINT_START
10146 PDG_DBG_PRINT_C("fei_endparallelworkshare_open_mp");
10147 PDG_DBG_PRINT_END
10148
10149 # ifdef _ENABLE_FEI
10150 fei_endparallelworkshare_open_mp();
10151 # endif
10152 break;
10153
10154 case Barrier_Open_Mp_Opr:
10155 PDG_DBG_PRINT_START
10156 PDG_DBG_PRINT_C("fei_barrier_open_mp");
10157 PDG_DBG_PRINT_END
10158
10159
10160 # ifdef _ENABLE_FEI
10161 fei_barrier_open_mp();
10162 # endif
10163 break;
10164
10165
10166
10167 case Master_Open_Mp_Opr:
10168 PDG_DBG_PRINT_START
10169 PDG_DBG_PRINT_C("fei_master_open_mp");
10170 PDG_DBG_PRINT_END
10171
10172
10173 # ifdef _ENABLE_FEI
10174 fei_master_open_mp();
10175 # endif
10176 break;
10177
10178
10179
10180 case Endmaster_Open_Mp_Opr:
10181 PDG_DBG_PRINT_START
10182 PDG_DBG_PRINT_C("fei_endmaster_open_mp");
10183 PDG_DBG_PRINT_END
10184
10185
10186 # ifdef _ENABLE_FEI
10187 fei_endmaster_open_mp();
10188 # endif
10189 break;
10190
10191
10192
10193 case Ordered_Open_Mp_Opr:
10194 PDG_DBG_PRINT_START
10195 PDG_DBG_PRINT_C("fei_ordered_open_mp");
10196 PDG_DBG_PRINT_END
10197
10198
10199 # ifdef _ENABLE_FEI
10200 fei_ordered_open_mp();
10201 # endif
10202 break;
10203
10204
10205
10206 case Endordered_Open_Mp_Opr:
10207 PDG_DBG_PRINT_START
10208 PDG_DBG_PRINT_C("fei_endordered_open_mp");
10209 PDG_DBG_PRINT_END
10210
10211
10212 # ifdef _ENABLE_FEI
10213 fei_endordered_open_mp();
10214 # endif
10215 break;
10216
10217
10218
10219 case Endparalleldo_Open_Mp_Opr:
10220 PDG_DBG_PRINT_START
10221 PDG_DBG_PRINT_C("fei_endparalleldo_open_mp");
10222 PDG_DBG_PRINT_END
10223
10224
10225 # ifdef _ENABLE_FEI
10226 fei_endparalleldo_open_mp();
10227 # endif
10228 break;
10229
10230
10231
10232 case Endparallel_Open_Mp_Opr:
10233 PDG_DBG_PRINT_START
10234 PDG_DBG_PRINT_C("fei_endparallel_open_mp");
10235 PDG_DBG_PRINT_END
10236
10237
10238 # ifdef _ENABLE_FEI
10239 fei_endparallel_open_mp();
10240 # endif
10241 break;
10242
10243
10244
10245 case Endparallelsections_Open_Mp_Opr:
10246 PDG_DBG_PRINT_START
10247 PDG_DBG_PRINT_C("fei_endparallelsections_open_mp");
10248 PDG_DBG_PRINT_END
10249
10250
10251 # ifdef _ENABLE_FEI
10252 fei_endparallelsections_open_mp();
10253 # endif
10254 break;
10255
10256
10257
10258 case Section_Open_Mp_Opr:
10259 PDG_DBG_PRINT_START
10260 PDG_DBG_PRINT_C("fei_section_open_mp");
10261 PDG_DBG_PRINT_END
10262
10263
10264 # ifdef _ENABLE_FEI
10265 fei_section_open_mp();
10266 # endif
10267 break;
10268
10269
10270
10271 case Enddo_Open_Mp_Opr:
10272 if (IR_FLD_L(ir_idx) == CN_Tbl_Idx) {
10273 nowait = (long) CN_INT_TO_C(IR_IDX_L(ir_idx));
10274 }
10275
10276 PDG_DBG_PRINT_START
10277 PDG_DBG_PRINT_C("fei_enddo_open_mp");
10278 PDG_DBG_PRINT_LD("(1) nowait", nowait);
10279 PDG_DBG_PRINT_END
10280
10281
10282 # ifdef _ENABLE_FEI
10283 fei_enddo_open_mp(nowait);
10284 # endif
10285 break;
10286
10287
10288
10289 case Endsections_Open_Mp_Opr:
10290 if (IR_FLD_L(ir_idx) == CN_Tbl_Idx) {
10291 nowait = (long) CN_INT_TO_C(IR_IDX_L(ir_idx));
10292 }
10293
10294 PDG_DBG_PRINT_START
10295 PDG_DBG_PRINT_C("fei_endsections_open_mp");
10296 PDG_DBG_PRINT_LD("(1) nowait", nowait);
10297 PDG_DBG_PRINT_END
10298
10299
10300 # ifdef _ENABLE_FEI
10301 fei_endsections_open_mp(nowait);
10302 # endif
10303 break;
10304
10305
10306
10307 case Endsingle_Open_Mp_Opr:
10308
10309 list_idx1 = IR_IDX_L(ir_idx);
10310
10311 if(IL_FLD(list_idx1) == CN_Tbl_Idx){
10312 nowait = (long) CN_INT_TO_C(IL_IDX(list_idx1));
10313 }
10314 else if(IL_FLD(IL_NEXT_LIST_IDX(list_idx1)) == IL_Tbl_Idx){
10315 list_idx2 = IL_IDX(IL_NEXT_LIST_IDX(list_idx1));
10316
10317 while (list_idx2) {
10318 if (IL_FLD(list_idx2) == AT_Tbl_Idx) {
10319 send_attr_ntry(IL_IDX(list_idx2));
10320
10321 PDG_DBG_PRINT_START
10322 PDG_DBG_PRINT_C("fei_task_var");
10323 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX",
10324 PDG_AT_IDX(IL_IDX(list_idx2)));
10325 PDG_DBG_PRINT_S("(2) context",
10326 p_tasking_context[Context_Omp_Copyprivate]);
10327 PDG_DBG_PRINT_END
10328
10329 # ifdef _ENABLE_FEI
10330 last_task_idx = fei_task_var(PDG_AT_IDX(IL_IDX(list_idx2)),
10331 Context_Omp_Copyprivate);
10332 # endif
10333
10334 }
10335
10336 list_idx2 = IL_NEXT_LIST_IDX(list_idx2);
10337 }
10338 }
10339
10340 PDG_DBG_PRINT_START
10341 PDG_DBG_PRINT_C("fei_endsingle_open_mp");
10342 PDG_DBG_PRINT_LD("(1) nowait", nowait);
10343 PDG_DBG_PRINT_END
10344
10345
10346 # ifdef _ENABLE_FEI
10347 fei_endsingle_open_mp(nowait);
10348 # endif
10349 break;
10350
10351
10352
10353
10354 case Flush_Open_Mp_Opr:
10355 list_cnt = 0;
10356 if (IR_FLD_L(ir_idx) == IL_Tbl_Idx) {
10357 list_cnt = IR_LIST_CNT_L(ir_idx);
10358 }
10359
10360 cvrt_exp_to_pdg(IR_IDX_L(ir_idx),
10361 IR_FLD_L(ir_idx));
10362
10363 PDG_DBG_PRINT_START
10364 PDG_DBG_PRINT_C("fei_flush_open_mp");
10365 PDG_DBG_PRINT_D("(1) list_cnt", list_cnt);
10366 PDG_DBG_PRINT_END
10367
10368
10369 # ifdef _ENABLE_FEI
10370 fei_flush_open_mp(list_cnt);
10371 # endif
10372 break;
10373
10374
10375
10376
10377 case Critical_Open_Mp_Opr:
10378 if (IR_FLD_L(ir_idx) == CN_Tbl_Idx) {
10379 criticalname = (char *) &CN_CONST(IR_IDX_L(ir_idx));
10380 }
10381
10382 PDG_DBG_PRINT_START
10383 PDG_DBG_PRINT_C("fei_critical_open_mp");
10384 PDG_DBG_PRINT_S("(1) criticalname", criticalname);
10385 PDG_DBG_PRINT_END
10386
10387
10388 # ifdef _ENABLE_FEI
10389 fei_critical_open_mp(criticalname);
10390 # endif
10391 break;
10392
10393
10394
10395 case Atomic_Open_Mp_Opr:
10396 PDG_DBG_PRINT_START
10397 PDG_DBG_PRINT_C("fei_atomic_open_mp");
10398 PDG_DBG_PRINT_END
10399
10400
10401 # ifdef _ENABLE_FEI
10402 fei_atomic_open_mp();
10403 # endif
10404 break;
10405
10406
10407
10408
10409 case Endcritical_Open_Mp_Opr:
10410 if (IR_FLD_L(ir_idx) == CN_Tbl_Idx) {
10411 criticalname = (char *) &CN_CONST(IR_IDX_L(ir_idx));
10412 }
10413
10414 PDG_DBG_PRINT_START
10415 PDG_DBG_PRINT_C("fei_endcritical_open_mp");
10416 PDG_DBG_PRINT_S("(1) criticalname", criticalname);
10417 PDG_DBG_PRINT_END
10418
10419
10420 # ifdef _ENABLE_FEI
10421 fei_endcritical_open_mp(criticalname);
10422 # endif
10423 break;
10424
10425 }
10426 }
10427
10428
10429 TRACE (Func_Exit, "cvrt_exp_to_pdg", NULL);
10430
10431 return;
10432
10433 }
10434
10435
10436
10437
10438
10439
10440
10441
10442
10443
10444
10445
10446
10447
10448
10449
10450
10451 static void finish_symbolic_expr()
10452 {
10453 int npex_expr_idx;
10454
10455
10456 TRACE (Func_Entry, "finish_symbolic_expr", NULL);
10457
10458 PDG_DBG_PRINT_START
10459 PDG_DBG_PRINT_C("npex_end");
10460 PDG_DBG_PRINT_END
10461
10462 # ifdef _ENABLE_FEI
10463 npex_expr_idx = npex_end();
10464 # endif
10465
10466 PDG_DBG_PRINT_START
10467 PDG_DBG_PRINT_D("(r) npex_expr_idx", npex_expr_idx);
10468 PDG_DBG_PRINT_END
10469
10470 PDG_DBG_PRINT_START
10471 PDG_DBG_PRINT_C("npex_to_expr");
10472 PDG_DBG_PRINT_D("npex_expr_idx", npex_expr_idx);
10473 PDG_DBG_PRINT_END
10474
10475 # ifdef _ENABLE_FEI
10476 npex_to_expr(npex_expr_idx);
10477 # endif
10478
10479 TRACE (Func_Exit, "finish_symbolic_expr", NULL);
10480
10481 return;
10482
10483 }
10484
10485
10486
10487
10488
10489
10490
10491
10492
10493
10494
10495
10496
10497
10498
10499
10500 static void cvrt_ir_to_pdg(int scp_idx)
10501 {
10502 long flag;
10503
10504
10505 TRACE (Func_Entry, "cvrt_ir_to_pdg", NULL);
10506
10507 curr_sh = SCP_FIRST_SH_IDX(scp_idx);
10508
10509 PDG_DBG_PRINT_START
10510 PDG_DBG_PRINT_C("fei_proc_body");
10511 PDG_DBG_PRINT_D("(1) SH_GLB_LINE", SH_GLB_LINE(curr_sh));
10512 PDG_DBG_PRINT_END
10513
10514 # ifdef _ENABLE_FEI
10515 fei_proc_body(SH_GLB_LINE(curr_sh));
10516 # endif
10517
10518 while (curr_sh != NULL_IDX) {
10519
10520 flag = ((long) (SH_STMT_TYPE(curr_sh) == Automatic_Base_Calc_Stmt)
10521 << FEI_STMT_ARY_BASE);
10522
10523 flag = flag | ((long) (SH_STMT_TYPE(curr_sh) == Automatic_Base_Size_Stmt)
10524 << FEI_STMT_ARY_SIZE);
10525
10526 flag = flag | ((long) SH_COMPILER_GEN(curr_sh) << FEI_STMT_INTERNAL);
10527
10528 PDG_DBG_PRINT_START
10529 PDG_DBG_PRINT_C("fei_stmt");
10530 PDG_DBG_PRINT_D("(1) SH_GLB_LINE", SH_GLB_LINE(curr_sh));
10531 PDG_DBG_PRINT_LO("(2) flags", flag);
10532 PDG_DBG_PRINT_END
10533
10534 # ifdef _ENABLE_FEI
10535 fei_stmt(SH_GLB_LINE(curr_sh), flag);
10536 # endif
10537
10538 if (SH_IR_IDX(curr_sh) != NULL_IDX) {
10539 stmt_start_line = SH_GLB_LINE(curr_sh);
10540 cvrt_exp_to_pdg(SH_IR_IDX(curr_sh), IR_Tbl_Idx);
10541 }
10542
10543 curr_sh = SH_NEXT_IDX(curr_sh);
10544 }
10545
10546 TRACE (Func_Exit, "cvrt_ir_to_pdg", NULL);
10547
10548 return;
10549
10550 }
10551
10552
10553
10554
10555
10556
10557
10558
10559
10560
10561
10562
10563
10564
10565
10566
10567
10568
10569 static TYPE get_basic_type(int type_idx,
10570 int alignment,
10571 int input_attr_idx)
10572
10573 {
10574 int align;
10575 long64 bit_size;
10576 INTPTR cdx;
10577 int flags = 0;
10578 TYPE idx;
10579
10580 # if !defined(_ALTERNATIVE_INTERFACE_FOR_POINTEES)
10581 int attr_idx;
10582 int p_idx;
10583 int save_pdg_at_idx;
10584 # endif
10585
10586
10587 TRACE (Func_Entry, "get_basic_type", NULL);
10588
10589
10590
10591
10592
10593
10594 idx = null_type;
10595
10596 if (input_attr_idx != NULL_IDX && ATD_VOLATILE(input_attr_idx)) {
10597 flags = flags | (1 << FEI_DESCRIPTOR_VOLAT_C);
10598 }
10599
10600 switch (TYP_TYPE(type_idx)) {
10601
10602 case Typeless:
10603 align = pdg_align[type_alignment_tbl[Long_Typeless]];
10604
10605 PDG_DBG_PRINT_START
10606 PDG_DBG_PRINT_C("fei_descriptor");
10607 PDG_DBG_PRINT_O("(1) flags", flags);
10608 PDG_DBG_PRINT_S("(2) table type", p_table_type[Basic]);
10609 PDG_DBG_PRINT_LLD("(3) bit len", TYP_BIT_LEN(type_idx));
10610 PDG_DBG_PRINT_S("(4) basic type", p_basic_type[T_ypeless]);
10611 PDG_DBG_PRINT_D("(5) aux info", 0);
10612 PDG_DBG_PRINT_D("(6) alignment", align);
10613 PDG_DBG_PRINT_END
10614 # ifdef _ENABLE_FEI
10615 idx = fei_descriptor(flags,
10616 Basic,
10617 TYP_BIT_LEN(type_idx),
10618 T_ypeless,
10619 0,
10620 align);
10621 # endif
10622 PDG_DBG_PRINT_START
10623 PDG_DBG_PRINT_T("(r) type", idx);
10624 PDG_DBG_PRINT_END
10625 break;
10626
10627
10628
10629 case CRI_Parcel_Ptr:
10630 if (global_attr_idx == NULL_IDX) {
10631 PRINTMSG(1, 993, Internal, 1);
10632 }
10633
10634 # ifdef _ALTERNATIVE_INTERFACE_FOR_POINTEES
10635 PDG_DBG_PRINT_START
10636 PDG_DBG_PRINT_C("fei_descriptor");
10637 PDG_DBG_PRINT_O("(1) flags", flags);
10638 PDG_DBG_PRINT_S("(2) table type", p_table_type[Func_tion]);
10639 PDG_DBG_PRINT_LD("(3) PDG_AT_IDX", PDG_AT_IDX(global_attr_idx));
10640 PDG_DBG_PRINT_S("(4) basic type", p_basic_type[BT_func_ptr]);
10641 PDG_DBG_PRINT_D("(5) aux info", 0);
10642 PDG_DBG_PRINT_D("(6) alignment", 0);
10643 PDG_DBG_PRINT_END
10644 # ifdef _ENABLE_FEI
10645 idx = fei_descriptor(flags,
10646 Func_tion,
10647 PDG_AT_IDX(global_attr_idx),
10648 BT_func_ptr,
10649 0,
10650 0);
10651 # endif
10652 PDG_DBG_PRINT_START
10653 PDG_DBG_PRINT_T("(r) type", idx);
10654 PDG_DBG_PRINT_END
10655
10656 # else
10657
10658 attr_idx = global_attr_idx;
10659 save_pdg_at_idx = PDG_AT_IDX(attr_idx);
10660 PDG_AT_IDX(attr_idx) = NULL_IDX;
10661
10662 send_procedure(attr_idx,
10663 NULL_IDX,
10664 Definition);
10665
10666 PDG_DBG_PRINT_START
10667 PDG_DBG_PRINT_C("fei_pointee");
10668 PDG_DBG_PRINT_T("(1) type", pdg_type_void);
10669 PDG_DBG_PRINT_END
10670 # ifdef _ENABLE_FEI
10671 p_idx = fei_pointee(pdg_type_void);
10672 # endif
10673 PDG_DBG_PRINT_START
10674 PDG_DBG_PRINT_D("(r) p_idx", p_idx);
10675 PDG_DBG_PRINT_END
10676
10677
10678
10679 PDG_DBG_PRINT_START
10680 PDG_DBG_PRINT_C("fei_descriptor");
10681 PDG_DBG_PRINT_O("(1) flags", flags);
10682 PDG_DBG_PRINT_S("(2) table type", p_table_type[Func_tion]);
10683 PDG_DBG_PRINT_D("(3) PDG_AT_IDX", PDG_AT_IDX(attr_idx));
10684 PDG_DBG_PRINT_S("(4) basic type", p_basic_type[V_oid]);
10685 PDG_DBG_PRINT_D("(5) aux info", p_idx);
10686 PDG_DBG_PRINT_D("(6) alignment", 0);
10687 PDG_DBG_PRINT_END
10688 # ifdef _ENABLE_FEI
10689 idx = fei_descriptor(flags,
10690 Func_tion,
10691 PDG_AT_IDX(attr_idx),
10692 V_oid,
10693 p_idx,
10694 0);
10695 # endif
10696 PDG_DBG_PRINT_START
10697 PDG_DBG_PRINT_T("(r) type", idx);
10698 PDG_DBG_PRINT_END
10699
10700
10701
10702
10703 PDG_DBG_PRINT_START
10704 PDG_DBG_PRINT_C("fei_pointee");
10705 PDG_DBG_PRINT_T("(1) idx", idx);
10706 PDG_DBG_PRINT_END
10707 # ifdef _ENABLE_FEI
10708 p_idx = fei_pointee(idx);
10709 # endif
10710 PDG_DBG_PRINT_START
10711 PDG_DBG_PRINT_D("(r) p_idx", p_idx);
10712 PDG_DBG_PRINT_END
10713
10714
10715
10716
10717 PDG_DBG_PRINT_START
10718 PDG_DBG_PRINT_C("fei_descriptor");
10719 PDG_DBG_PRINT_O("(1) flags", flags);
10720 PDG_DBG_PRINT_S("(2) table type", p_table_type[Pointer]);
10721 PDG_DBG_PRINT_D("(3) p_idx", p_idx);
10722 PDG_DBG_PRINT_S("(4) basic type", p_basic_type[V_oid]);
10723 PDG_DBG_PRINT_D("(5) aux info", 0);
10724 PDG_DBG_PRINT_D("(6) alignment", 0);
10725 PDG_DBG_PRINT_END
10726 # ifdef _ENABLE_FEI
10727 idx = fei_descriptor(flags,
10728 Pointer,
10729 p_idx,
10730 V_oid,
10731 0,
10732 0);
10733 # endif
10734 PDG_DBG_PRINT_START
10735 PDG_DBG_PRINT_T("(r) type", idx);
10736 PDG_DBG_PRINT_END
10737
10738 PDG_AT_IDX(attr_idx) = save_pdg_at_idx;
10739 # endif
10740 break;
10741
10742
10743
10744 case Integer:
10745 case Logical:
10746 case Real:
10747 case Complex:
10748 case CRI_Ch_Ptr:
10749 idx = send_non_standard_aligned_type(alignment, type_idx);
10750 break;
10751
10752
10753 case Character:
10754 switch (TYP_CHAR_CLASS(type_idx)) {
10755 case Assumed_Size_Char:
10756 case Var_Len_Char:
10757 if (global_attr_idx != NULL_IDX) {
10758 if (ATD_CLASS(global_attr_idx) == CRI__Pointee &&
10759 ATD_PTR_IDX(global_attr_idx) != NULL_IDX) {
10760 global_attr_idx = ATD_PTR_IDX(global_attr_idx);
10761 }
10762
10763 if (ATD_STOR_BLK_IDX(global_attr_idx) != NULL_IDX &&
10764 SB_SCP_IDX(ATD_STOR_BLK_IDX(global_attr_idx)) != curr_scp_idx) {
10765 flags = flags | (1 << FEI_DESCRIPTOR_HOSTED_TYPE);
10766 }
10767 }
10768
10769 send_attr_ntry(TYP_IDX(type_idx));
10770 flags = flags | (1 << FEI_DESCRIPTOR_AUTO_F);
10771
10772 PDG_DBG_PRINT_START
10773 PDG_DBG_PRINT_C("fei_descriptor");
10774 PDG_DBG_PRINT_O("(1) flags", flags);
10775 PDG_DBG_PRINT_S("(2) table type", p_table_type[Basic]);
10776 PDG_DBG_PRINT_LD("(3) PDG_AT_IDX", PDG_AT_IDX(TYP_IDX(type_idx)));
10777 PDG_DBG_PRINT_S("(4) basic type", p_basic_type[Char_Fortran]);
10778 PDG_DBG_PRINT_D("(5) aux info", CHAR_BIT);
10779 PDG_DBG_PRINT_D("(6) alignment", Align_Bit);
10780 PDG_DBG_PRINT_END
10781 # ifdef _ENABLE_FEI
10782 idx = fei_descriptor(flags,
10783 Basic,
10784 PDG_AT_IDX(TYP_IDX(type_idx)),
10785 Char_Fortran,
10786 CHAR_BIT,
10787 Align_Bit);
10788 # endif
10789 PDG_DBG_PRINT_START
10790 PDG_DBG_PRINT_T("(r) type", idx);
10791 PDG_DBG_PRINT_END
10792 break;
10793
10794
10795 case Const_Len_Char:
10796 if (global_attr_idx != NULL_IDX) {
10797 if (ATD_CLASS(global_attr_idx) == CRI__Pointee &&
10798 ATD_PTR_IDX(global_attr_idx) != NULL_IDX) {
10799 global_attr_idx = ATD_PTR_IDX(global_attr_idx);
10800 }
10801
10802 if (ATD_STOR_BLK_IDX(global_attr_idx) != NULL_IDX &&
10803 SB_SCP_IDX(ATD_STOR_BLK_IDX(global_attr_idx)) != curr_scp_idx) {
10804 flags = flags | (1 << FEI_DESCRIPTOR_HOSTED_TYPE);
10805 }
10806 }
10807 bit_size = CN_INT_TO_C(TYP_IDX(type_idx));
10808 bit_size = bit_size * CHAR_BIT;
10809
10810 idx = get_basic_type(Integer_8,type_alignment_tbl[Integer_8],NULL_IDX);
10811
10812 PDG_DBG_PRINT_START
10813 PDG_DBG_PRINT_C("fei_arith_con");
10814 PDG_DBG_PRINT_T("(1) type", idx);
10815 PDG_DBG_PRINT_LLD("(2) bit_size", bit_size);
10816 PDG_DBG_PRINT_END
10817 # ifdef _ENABLE_FEI
10818 cdx = fei_arith_con(idx, (long *)&bit_size);
10819 # endif
10820 PDG_DBG_PRINT_START
10821 PDG_DBG_PRINT_LD("(r) PDG_CN_IDX", cdx);
10822 PDG_DBG_PRINT_END
10823
10824
10825 PDG_DBG_PRINT_START
10826 PDG_DBG_PRINT_C("fei_descriptor");
10827 PDG_DBG_PRINT_O("(1) flags", flags);
10828 PDG_DBG_PRINT_S("(2) table type", p_table_type[Basic]);
10829 PDG_DBG_PRINT_LD("(3) PDG_CN_IDX", cdx);
10830 PDG_DBG_PRINT_S("(4) basic type", p_basic_type[Char_Fortran]);
10831 PDG_DBG_PRINT_D("(5) aux info", CHAR_BIT);
10832 PDG_DBG_PRINT_D("(6) alignment", Align_Bit);
10833 PDG_DBG_PRINT_END
10834 # ifdef _ENABLE_FEI
10835 idx = fei_descriptor(flags,
10836 Basic,
10837 cdx,
10838 Char_Fortran,
10839 CHAR_BIT,
10840 Align_Bit);
10841 # endif
10842 PDG_DBG_PRINT_START
10843 PDG_DBG_PRINT_T("(r) type", idx);
10844 PDG_DBG_PRINT_END
10845 break;
10846 }
10847 break;
10848
10849
10850 case Structure:
10851 idx = send_derived_type(type_idx);
10852 break;
10853
10854
10855 case CRI_Ptr:
10856 # ifdef _TARGET32
10857 if (TYP_PTR_INCREMENT(type_idx) > TARGET_BITS_PER_WORD) {
10858 PDG_DBG_PRINT_START
10859 PDG_DBG_PRINT_C("fei_descriptor");
10860 PDG_DBG_PRINT_O("(1) flags", flags);
10861 PDG_DBG_PRINT_S("(2) table type", p_table_type[Basic]);
10862 PDG_DBG_PRINT_D("(3) bit_size", storage_bit_size_tbl[CRI_Ptr_8]);
10863 PDG_DBG_PRINT_S("(4) basic type", p_basic_type[CRI_Pointer]);
10864 PDG_DBG_PRINT_D("(5) aux info", DWord_Align);
10865 PDG_DBG_PRINT_D("(6) alignment", 0);
10866 PDG_DBG_PRINT_END
10867 # ifdef _ENABLE_FEI
10868 idx = fei_descriptor(flags,
10869 Basic,
10870 storage_bit_size_tbl[CRI_Ptr_8],
10871 CRI_Pointer,
10872 DWord_Align,
10873 0);
10874 # endif
10875 PDG_DBG_PRINT_START
10876 PDG_DBG_PRINT_T("(r) type", idx);
10877 PDG_DBG_PRINT_END
10878 }
10879 else
10880 # endif
10881
10882 if (TYP_PTR_INCREMENT(type_idx) >= TARGET_BITS_PER_WORD) {
10883 PDG_DBG_PRINT_START
10884 PDG_DBG_PRINT_C("fei_descriptor");
10885 PDG_DBG_PRINT_O("(1) flags", flags);
10886 PDG_DBG_PRINT_S("(2) table type", p_table_type[Basic]);
10887 PDG_DBG_PRINT_D("(3) unused", 0);
10888 PDG_DBG_PRINT_S("(4) basic type", p_basic_type[CRI_Pointer]);
10889 PDG_DBG_PRINT_D("(5) aux info", Word_Align);
10890 PDG_DBG_PRINT_D("(6) alignment", 0);
10891 PDG_DBG_PRINT_END
10892 # ifdef _ENABLE_FEI
10893 idx = fei_descriptor(flags,
10894 Basic,
10895 0,
10896 CRI_Pointer,
10897 Word_Align,
10898 0);
10899 # endif
10900 PDG_DBG_PRINT_START
10901 PDG_DBG_PRINT_T("(r) type", idx);
10902 PDG_DBG_PRINT_END
10903 }
10904 else {
10905 PDG_DBG_PRINT_START
10906 PDG_DBG_PRINT_C("fei_descriptor");
10907 PDG_DBG_PRINT_O("(1) flags", flags);
10908 PDG_DBG_PRINT_S("(2) table type", p_table_type[Basic]);
10909 PDG_DBG_PRINT_D("(3) unused", 0);
10910 PDG_DBG_PRINT_S("(4) basic type", p_basic_type[CRI_Pointer]);
10911 PDG_DBG_PRINT_D("(5) aux info", HWord_Align);
10912 PDG_DBG_PRINT_D("(6) alignment", 0);
10913 PDG_DBG_PRINT_END
10914 # ifdef _ENABLE_FEI
10915 idx = fei_descriptor(flags,
10916 Basic,
10917 0,
10918 CRI_Pointer,
10919 HWord_Align,
10920 0);
10921 # endif
10922 PDG_DBG_PRINT_START
10923 PDG_DBG_PRINT_T("(r) type", idx);
10924 PDG_DBG_PRINT_END
10925 }
10926 break;
10927
10928 }
10929
10930 TRACE (Func_Exit, "get_basic_type", NULL);
10931
10932 return(idx);
10933
10934 }
10935
10936
10937
10938
10939
10940
10941
10942
10943
10944
10945
10946
10947
10948
10949
10950
10951
10952 static TYPE get_type_desc(int input_idx)
10953 {
10954 int bd_idx;
10955 int dist_idx;
10956 int distribution = 0;
10957 int kind_type = 0;
10958 #ifdef KEY
10959 int attr_idx = 0;
10960 #else
10961 int attr_idx;
10962 #endif
10963 int temp_attr_idx;
10964 int basic_type;
10965 long64 extent;
10966 int i = 1;
10967 long64 lbound;
10968 long64 ubound;
10969 int flag = 0;
10970 boolean lb_vble;
10971 boolean lb_symcon = FALSE;
10972 boolean ub_vble;
10973 boolean ub_symcon = FALSE;
10974 boolean xt_vble;
10975 boolean xt_symcon = FALSE;
10976 long pdg_array_idx;
10977 int rank;
10978 size_offset_type size;
10979 long64 span;
10980 boolean template_tmp = FALSE;
10981 int tmp_idx;
10982 int type_flag = 0;
10983 TYPE type_idx;
10984
10985 # if defined(_TARGET_OS_MAX)
10986 int pe_bd_idx;
10987 # endif
10988
10989
10990 TRACE (Func_Entry, "get_type_desc", NULL);
10991
10992 type_idx = null_type;
10993
10994 switch (AT_OBJ_CLASS(input_idx)) {
10995
10996 case Data_Obj:
10997 attr_idx = input_idx;
10998 global_attr_idx = attr_idx;
10999 type_idx = get_basic_type(ATD_TYPE_IDX(attr_idx),
11000 ATD_ALIGNMENT(attr_idx),
11001 attr_idx);
11002 global_attr_idx = NULL_IDX;
11003 break;
11004
11005 case Pgm_Unit:
11006 if (ATP_PGM_UNIT(input_idx) == Function) {
11007 attr_idx = ATP_RSLT_IDX(input_idx);
11008
11009
11010
11011
11012
11013
11014
11015
11016
11017
11018 if (ATP_EXPL_ITRFC(input_idx) && !ATP_SCP_ALIVE(input_idx)) {
11019 template_tmp = TRUE;
11020
11021 if (TYP_TYPE(ATD_TYPE_IDX(attr_idx)) == Character &&
11022 TYP_CHAR_CLASS(ATD_TYPE_IDX(attr_idx)) != Const_Len_Char &&
11023 PDG_AT_IDX(TYP_IDX(ATD_TYPE_IDX(attr_idx))) == NULL_IDX) {
11024 tmp_idx = TYP_IDX(ATD_TYPE_IDX(attr_idx));
11025 COPY_ATTR_NTRY(AT_WORK_IDX, tmp_idx);
11026 AT_REFERENCED(tmp_idx) = Referenced;
11027 ATD_OFFSET_ASSIGNED(tmp_idx) = FALSE;
11028 ATD_STOR_BLK_IDX(tmp_idx) = SCP_SB_STACK_IDX(curr_scp_idx);
11029 send_attr_ntry(tmp_idx);
11030 COPY_ATTR_NTRY(tmp_idx, AT_WORK_IDX);
11031 }
11032 }
11033
11034 type_idx = get_basic_type(ATD_TYPE_IDX(attr_idx),
11035 ATD_ALIGNMENT(attr_idx),
11036 attr_idx);
11037 }
11038 else {
11039 type_idx = pdg_type_void;
11040 goto EXIT;
11041 }
11042 break;
11043 }
11044
11045
11046 if (ATD_IM_A_DOPE(attr_idx)) {
11047 rank = (ATD_ARRAY_IDX(attr_idx) == NULL_IDX) ? 0 :
11048 BD_RANK(ATD_ARRAY_IDX(attr_idx));
11049
11050 if (ATD_STOR_BLK_IDX(attr_idx) != NULL_IDX &&
11051 SB_SCP_IDX(ATD_STOR_BLK_IDX(attr_idx)) != curr_scp_idx) {
11052 type_flag = type_flag | (1 << FEI_DOPE_VECTOR_HOSTED_TYPE);
11053 }
11054
11055 type_flag = type_flag |
11056 (ATD_POINTER(attr_idx) << FEI_DOPE_VECTOR_POINTER);
11057
11058 PDG_DBG_PRINT_START
11059 PDG_DBG_PRINT_C("fei_dope_vector");
11060 PDG_DBG_PRINT_D("(1) rank", rank);
11061 PDG_DBG_PRINT_T("(2) type", type_idx);
11062 PDG_DBG_PRINT_O("(3) flags", type_flag);
11063 PDG_DBG_PRINT_END
11064
11065 # ifdef _ENABLE_FEI
11066 type_idx = fei_dope_vector(rank, type_idx, type_flag,
11067 #ifdef KEY
11068
11069 do_count_allocatable_cpnt(attr_idx, rank)
11070 #endif
11071 );
11072 # endif
11073 }
11074 else if (ATD_ARRAY_IDX(attr_idx) != NULL_IDX) {
11075 bd_idx = ATD_ARRAY_IDX(attr_idx);
11076 dist_idx = ATD_DISTRIBUTION_IDX(attr_idx);
11077 basic_type = pdg_basic_type[TYP_TYPE(ATD_TYPE_IDX(attr_idx))];
11078
11079 switch (TYP_LINEAR(ATD_TYPE_IDX(attr_idx))) {
11080 case Integer_1:
11081 case Logical_1:
11082 kind_type = 1;
11083 break;
11084
11085 case Integer_2:
11086 case Logical_2:
11087 kind_type = 2;
11088 break;
11089
11090 case Integer_4:
11091 case Logical_4:
11092 case Complex_4:
11093 case Real_4:
11094 kind_type = 4;
11095 break;
11096
11097 case Integer_8:
11098 case Logical_8:
11099 case Complex_8:
11100 case Real_8:
11101 kind_type = 8;
11102 break;
11103
11104 case Complex_16:
11105 case Real_16:
11106 kind_type = 16;
11107 break;
11108 }
11109
11110 temp_attr_idx = attr_idx;
11111
11112 if (ATD_CLASS(attr_idx) == CRI__Pointee &&
11113 ATD_PTR_IDX(attr_idx) != NULL_IDX) {
11114 temp_attr_idx = ATD_PTR_IDX(attr_idx);
11115 }
11116 else if (ATD_AUTOMATIC(attr_idx) &&
11117 ATD_AUTO_BASE_IDX(attr_idx) != NULL_IDX) {
11118 temp_attr_idx = ATD_AUTO_BASE_IDX(attr_idx);
11119 }
11120
11121 if (ATD_STOR_BLK_IDX(temp_attr_idx) != NULL_IDX &&
11122 SB_SCP_IDX(ATD_STOR_BLK_IDX(temp_attr_idx)) != curr_scp_idx) {
11123 type_flag = type_flag | (1 << FEI_DESCRIPTOR_HOSTED_TYPE);
11124 }
11125
11126 size = stor_bit_size_of(attr_idx, FALSE, FALSE);
11127
11128 if (size.fld == CN_Tbl_Idx) {
11129 span = CN_INT_TO_C(size.idx);
11130 }
11131 else {
11132 span = F_INT_TO_C(size.constant, TYP_LINEAR(size.type_idx));
11133 }
11134
11135 # ifdef _DEBUG
11136 if (! BD_RESOLVED(bd_idx)) {
11137 PRINTMSG(1, 626, Internal, 1,
11138 "resolved bounds entry",
11139 "get_type_desc");
11140 }
11141 # endif
11142
11143 for (i = 1; i <= BD_RANK(bd_idx); i++) {
11144 if (BD_LB_FLD(bd_idx, i) == CN_Tbl_Idx) {
11145 lbound = CN_INT_TO_C(BD_LB_IDX(bd_idx, i));
11146 lb_vble = FALSE;
11147 }
11148 else {
11149 lbound = BD_LB_IDX(bd_idx, i);
11150 lb_vble = TRUE;
11151
11152 # ifdef _TARGET_OS_MAX
11153 lb_symcon = ATD_SYMBOLIC_CONSTANT(lbound);
11154 lb_vble = !ATD_SYMBOLIC_CONSTANT(lbound);
11155 # endif
11156
11157 if (PDG_AT_IDX(lbound) == NULL_IDX) {
11158
11159 if (template_tmp) {
11160 COPY_ATTR_NTRY(AT_WORK_IDX, lbound);
11161 AT_REFERENCED(lbound) = Referenced;
11162 ATD_OFFSET_ASSIGNED(lbound) = FALSE;
11163 ATD_STOR_BLK_IDX(lbound) = SCP_SB_STACK_IDX(curr_scp_idx);
11164 send_attr_ntry(lbound);
11165 COPY_ATTR_NTRY(lbound, AT_WORK_IDX);
11166 }
11167 else {
11168 send_attr_ntry(lbound);
11169 }
11170 }
11171 lbound = PDG_AT_IDX(lbound);
11172 }
11173
11174 if (BD_UB_FLD(bd_idx, i) == CN_Tbl_Idx) {
11175 ubound = CN_INT_TO_C(BD_UB_IDX(bd_idx, i));
11176 ub_vble = FALSE;
11177 }
11178 else {
11179 ubound = BD_UB_IDX(bd_idx, i);
11180 ub_vble = TRUE;
11181
11182 # ifdef _TARGET_OS_MAX
11183 ub_symcon = ATD_SYMBOLIC_CONSTANT(ubound);
11184 ub_vble = !ATD_SYMBOLIC_CONSTANT(ubound);
11185 # endif
11186
11187 if (PDG_AT_IDX(ubound) == NULL_IDX) {
11188
11189 if (template_tmp) {
11190 COPY_ATTR_NTRY(AT_WORK_IDX, ubound);
11191 AT_REFERENCED(ubound) = Referenced;
11192 ATD_OFFSET_ASSIGNED(ubound) = FALSE;
11193 ATD_STOR_BLK_IDX(ubound) = SCP_SB_STACK_IDX(curr_scp_idx);
11194 send_attr_ntry(ubound);
11195 COPY_ATTR_NTRY(ubound, AT_WORK_IDX);
11196 }
11197 else {
11198 send_attr_ntry(ubound);
11199 }
11200 }
11201 ubound = PDG_AT_IDX(ubound);
11202 }
11203
11204 if (BD_XT_FLD(bd_idx, i) == CN_Tbl_Idx) {
11205 extent = CN_INT_TO_C(BD_XT_IDX(bd_idx, i));
11206 xt_vble = FALSE;
11207 span = extent * span;
11208 }
11209 else {
11210 extent = BD_XT_IDX(bd_idx, i);
11211 xt_vble = TRUE;
11212
11213 # ifdef _TARGET_OS_MAX
11214 xt_symcon = ATD_SYMBOLIC_CONSTANT(extent);
11215 xt_vble = !ATD_SYMBOLIC_CONSTANT(extent);
11216 # endif
11217
11218 if (PDG_AT_IDX(extent) == NULL_IDX) {
11219
11220 if (template_tmp) {
11221 COPY_ATTR_NTRY(AT_WORK_IDX, extent);
11222 AT_REFERENCED(extent) = Referenced;
11223 ATD_OFFSET_ASSIGNED(extent) = FALSE;
11224 ATD_STOR_BLK_IDX(extent) = SCP_SB_STACK_IDX(curr_scp_idx);
11225 send_attr_ntry(extent);
11226 COPY_ATTR_NTRY(extent, AT_WORK_IDX);
11227 }
11228 else {
11229 send_attr_ntry(extent);
11230 }
11231 }
11232 extent = PDG_AT_IDX(extent);
11233 span = (long64) 0;
11234 }
11235
11236 flag = (lb_symcon << FEI_ARRAY_DIMEN_SCON_LB)|
11237 (lb_vble << FEI_ARRAY_DIMEN_VARY_LB)|
11238 (ub_symcon << FEI_ARRAY_DIMEN_SCON_UB)|
11239 (ub_vble << FEI_ARRAY_DIMEN_VARY_UB)|
11240 (xt_symcon << FEI_ARRAY_DIMEN_SCON_EXT)|
11241 (xt_vble << FEI_ARRAY_DIMEN_VARY_EXT);
11242
11243 flag |= (BD_FLOW_DEPENDENT(bd_idx) << FEI_ARRAY_DIMEN_FLOW_DEPENDENT);
11244
11245 temp_attr_idx = attr_idx;
11246 if (ATD_CLASS(attr_idx) == CRI__Pointee &&
11247 ATD_PTR_IDX(attr_idx) != NULL_IDX) {
11248 temp_attr_idx = ATD_PTR_IDX(attr_idx);
11249 }
11250
11251 if (ATD_STOR_BLK_IDX(temp_attr_idx) != NULL_IDX &&
11252 SB_SCP_IDX(ATD_STOR_BLK_IDX(temp_attr_idx)) != curr_scp_idx) {
11253 flag = flag | (1 << FEI_ARRAY_DIMEN_HOSTED_TYPE);
11254 }
11255
11256 if (dist_idx != NULL_IDX) {
11257 if (BD_CYCLIC_IDX(dist_idx, i) != NULL_IDX) {
11258 cvrt_exp_to_pdg(BD_CYCLIC_IDX(dist_idx, i),
11259 BD_CYCLIC_FLD(dist_idx, i));
11260 flag = flag | (1 << FEI_ARRAY_DIMEN_DIST_EXPR);
11261 }
11262
11263 if (BD_ONTO_IDX(dist_idx, i) != NULL_IDX) {
11264 cvrt_exp_to_pdg(BD_ONTO_IDX(dist_idx, i),
11265 BD_ONTO_FLD(dist_idx, i));
11266 flag = flag | (1 << FEI_ARRAY_DIMEN_ONTO_EXPR);
11267 }
11268
11269 distribution = BD_DISTRIBUTION(dist_idx, i);
11270
11271 flag = flag | (BD_DISTRIBUTE_RESHAPE(dist_idx) <<
11272 FEI_ARRAY_DIMEN_DIST_RESHAPE);
11273 }
11274
11275 PDG_DBG_PRINT_START
11276 PDG_DBG_PRINT_C("fei_array_dimen");
11277 PDG_DBG_PRINT_O("(1) flags", flag);
11278 PDG_DBG_PRINT_LLD("(2) lbound", lbound);
11279 PDG_DBG_PRINT_LLD("(3) extent", extent);
11280 PDG_DBG_PRINT_D("(4) rank", i);
11281 PDG_DBG_PRINT_T("(5) type", type_idx);
11282 PDG_DBG_PRINT_LLD("(6) span", span);
11283 PDG_DBG_PRINT_S("(7) distribution", p_distribution[distribution]);
11284 PDG_DBG_PRINT_LLD("(8) ubound", ubound);
11285 PDG_DBG_PRINT_END
11286
11287 # ifdef _ENABLE_FEI
11288 pdg_array_idx = fei_array_dimen(flag,
11289 lbound,
11290 extent,
11291 i,
11292 type_idx,
11293 span,
11294 distribution,
11295 ubound);
11296 # endif
11297
11298 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
11299 if (i == BD_RANK(bd_idx)) {
11300 # endif
11301 PDG_DBG_PRINT_START
11302 PDG_DBG_PRINT_C("fei_descriptor");
11303 PDG_DBG_PRINT_O("(1) flags", type_flag);
11304 PDG_DBG_PRINT_S("(2) table type", p_table_type[Array]);
11305 PDG_DBG_PRINT_LD("(3) pdg_array_idx", pdg_array_idx);
11306 PDG_DBG_PRINT_S("(4) basic type", p_basic_type[basic_type]);
11307 PDG_DBG_PRINT_D("(5) aux info", kind_type);
11308 PDG_DBG_PRINT_D("(6) alignment",pdg_align[ATD_ALIGNMENT(attr_idx)]);
11309 PDG_DBG_PRINT_END
11310 # ifdef _ENABLE_FEI
11311 type_idx = fei_descriptor(type_flag,
11312 Array,
11313 pdg_array_idx,
11314 basic_type,
11315 kind_type,
11316 pdg_align[ATD_ALIGNMENT(attr_idx)]);
11317 # endif
11318 PDG_DBG_PRINT_START
11319 PDG_DBG_PRINT_T("(r) type", type_idx);
11320 PDG_DBG_PRINT_END
11321
11322 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
11323 }
11324 # endif
11325 }
11326 }
11327
11328 # if defined(_F_MINUS_MINUS)
11329 # if defined(_TARGET_OS_MAX)
11330 pe_bd_idx = ATD_PE_ARRAY_IDX(attr_idx);
11331
11332 if (pe_bd_idx &&
11333 ! ATD_ALLOCATABLE(attr_idx)) {
11334
11335 dist_idx = NULL_IDX;
11336 basic_type = pdg_basic_type[TYP_TYPE(ATD_TYPE_IDX(attr_idx))];
11337
11338 switch (TYP_LINEAR(ATD_TYPE_IDX(attr_idx))) {
11339 case Integer_1:
11340 case Logical_1:
11341 kind_type = 1;
11342 break;
11343
11344 case Integer_2:
11345 case Logical_2:
11346 kind_type = 2;
11347 break;
11348
11349 case Integer_4:
11350 case Logical_4:
11351 case Complex_4:
11352 case Real_4:
11353 kind_type = 4;
11354 break;
11355
11356 case Integer_8:
11357 case Logical_8:
11358 case Complex_8:
11359 case Real_8:
11360 kind_type = 8;
11361 break;
11362
11363 case Complex_16:
11364 case Real_16:
11365 kind_type = 16;
11366 break;
11367 }
11368
11369 lbound = (long64) 1;
11370 span = (long64) 0;
11371
11372 if (BD_LEN_FLD(pe_bd_idx) == CN_Tbl_Idx) {
11373 extent = CN_INT_TO_C(BD_LEN_IDX(pe_bd_idx));
11374 xt_vble = FALSE;
11375 }
11376 else {
11377 extent = BD_LEN_IDX(pe_bd_idx);
11378 xt_vble = TRUE;
11379
11380 # ifdef _TARGET_OS_MAX
11381 xt_symcon = ATD_SYMBOLIC_CONSTANT(extent);
11382 xt_vble = !ATD_SYMBOLIC_CONSTANT(extent);
11383 # endif
11384
11385 if (PDG_AT_IDX(extent) == NULL_IDX) {
11386 send_attr_ntry(extent);
11387 }
11388 extent = PDG_AT_IDX(extent);
11389 }
11390
11391 flag = (xt_symcon << FEI_ARRAY_DIMEN_SCON_EXT)|
11392 (xt_vble << FEI_ARRAY_DIMEN_VARY_EXT);
11393
11394
11395 flag |= 1 << FEI_ARRAY_DIMEN_F_MINUS_MINUS_REMOTE;
11396
11397 flag |= (BD_FLOW_DEPENDENT(pe_bd_idx) << FEI_ARRAY_DIMEN_FLOW_DEPENDENT);
11398
11399 temp_attr_idx = attr_idx;
11400 if (ATD_CLASS(attr_idx) == CRI__Pointee &&
11401 ATD_PTR_IDX(attr_idx) != NULL_IDX) {
11402 temp_attr_idx = ATD_PTR_IDX(attr_idx);
11403 }
11404
11405 if (ATD_STOR_BLK_IDX(temp_attr_idx) != NULL_IDX &&
11406 SB_SCP_IDX(ATD_STOR_BLK_IDX(temp_attr_idx)) != curr_scp_idx) {
11407 flag = flag | (1 << FEI_ARRAY_DIMEN_HOSTED_TYPE);
11408 }
11409
11410 PDG_DBG_PRINT_START
11411 PDG_DBG_PRINT_C("fei_array_dimen");
11412 PDG_DBG_PRINT_O("(1) flags", flag);
11413 PDG_DBG_PRINT_LLD("(2) lbound", lbound);
11414 PDG_DBG_PRINT_LLD("(3) extent", extent);
11415 PDG_DBG_PRINT_D("(4) rank", i);
11416 PDG_DBG_PRINT_T("(5) type", type_idx);
11417 PDG_DBG_PRINT_LLD("(6) span", span);
11418 PDG_DBG_PRINT_S("(7) distribution", p_distribution[distribution]);
11419 PDG_DBG_PRINT_LLD("(8) ubound", ubound);
11420 PDG_DBG_PRINT_END
11421
11422 # ifdef _ENABLE_FEI
11423 pdg_array_idx = fei_array_dimen(flag,
11424 lbound,
11425 extent,
11426 i,
11427 type_idx,
11428 span,
11429 distribution,
11430 ubound);
11431 # endif
11432
11433 PDG_DBG_PRINT_START
11434 PDG_DBG_PRINT_C("fei_descriptor");
11435 PDG_DBG_PRINT_O("(1) flags", type_flag);
11436 PDG_DBG_PRINT_S("(2) table type", p_table_type[Array]);
11437 PDG_DBG_PRINT_D("(3) pdg_array_idx", pdg_array_idx);
11438 PDG_DBG_PRINT_S("(4) basic type", p_basic_type[basic_type]);
11439 PDG_DBG_PRINT_D("(5) aux info", kind_type);
11440 PDG_DBG_PRINT_D("(6) alignment", pdg_align[ATD_ALIGNMENT(attr_idx)]);
11441 PDG_DBG_PRINT_END
11442 # ifdef _ENABLE_FEI
11443 type_idx = fei_descriptor(type_flag,
11444 Array,
11445 pdg_array_idx,
11446 basic_type,
11447 kind_type,
11448 pdg_align[ATD_ALIGNMENT(attr_idx)]);
11449 # endif
11450 PDG_DBG_PRINT_START
11451 PDG_DBG_PRINT_T("(r) type", type_idx);
11452 PDG_DBG_PRINT_END
11453 }
11454 # endif
11455 # endif
11456
11457 EXIT:
11458 #ifdef KEY
11459
11460
11461
11462
11463
11464
11465
11466
11467 if (AT_OBJ_CLASS(input_idx) == Data_Obj && ATD_VOLATILE(input_idx)) {
11468 type_idx.table_index = fei_set_volatile(type_idx.table_index);
11469 }
11470 #endif
11471
11472 TRACE (Func_Exit, "get_type_desc", NULL);
11473
11474 return(type_idx);
11475
11476 }
11477
11478
11479
11480
11481
11482
11483
11484
11485
11486
11487
11488
11489
11490
11491
11492
11493 static void send_stor_blk(int sb_idx,
11494 int *pdg_sym_class)
11495
11496 {
11497 long64 blk_len = (long64) 0;
11498 int flag;
11499 int host_sb_idx = NULL_IDX;
11500 int local_sb_idx;
11501 char *name_ptr;
11502 int parent_idx;
11503 sb_type_type sb_type;
11504
11505 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
11506 int i;
11507 char new_name[256];
11508 # endif
11509
11510
11511 TRACE (Func_Entry, "send_stor_blk", NULL);
11512
11513 if (sb_idx == NULL_IDX) {
11514 goto EXIT;
11515 }
11516
11517 sb_type = SB_BLK_TYPE(sb_idx);
11518
11519 flag = (SB_MODULE(sb_idx) << FEI_SEG_MODULE) |
11520 (SB_SAVED(sb_idx) << FEI_SEG_SAVED) |
11521 (SB_EQUIVALENCED(sb_idx) << FEI_SEG_EQUIVALENCED) |
11522 (SB_DUPLICATE_COMMON(sb_idx) << FEI_SEG_DUPLICATE) |
11523 (SB_VOLATILE(sb_idx) << FEI_SEG_VOLATILE) |
11524 (SB_SYMMETRIC(sb_idx) << FEI_SEG_SHARED);
11525
11526
11527 if (sb_type == Threadprivate) {
11528 sb_type = Common;
11529 flag |= 1 << FEI_SEG_THREADPRIVATE;
11530 }
11531
11532 if (sb_type == Coment) {
11533 *pdg_sym_class = Name;
11534 }
11535
11536 switch (SB_LEN_FLD(sb_idx)) {
11537 case CN_Tbl_Idx :
11538 blk_len = CN_INT_TO_C(SB_LEN_IDX(sb_idx));
11539 # ifdef KEY
11540 if (TYP_LINEAR(CN_TYPE_IDX(SB_LEN_IDX(sb_idx))) == Integer_4 && blk_len != 0)
11541 blk_len = (unsigned) blk_len;
11542 # endif
11543 break;
11544
11545 case AT_Tbl_Idx :
11546 flag = flag | (1 << FEI_SEG_SCON_LEN);
11547 send_attr_ntry(SB_LEN_IDX(sb_idx));
11548 blk_len = (long64) PDG_AT_IDX(SB_LEN_IDX(sb_idx));
11549 break;
11550 }
11551
11552 if (SB_SCP_IDX(sb_idx) != curr_scp_idx) {
11553
11554 if (SB_HOSTED_STACK(sb_idx)) {
11555 sb_type = Non_Local_Stack;
11556 *pdg_sym_class = Hosted_User_Variable;
11557 }
11558 else if (sb_type == Formal) {
11559 sb_type = Non_Local_Formal;
11560 *pdg_sym_class = Hosted_Dummy_Arg;
11561 }
11562 else if (sb_type == Based) {
11563 *pdg_sym_class = Hosted_User_Variable;
11564 }
11565 else if (PDG_SB_IDX(sb_idx) == NULL_IDX) {
11566
11567
11568
11569 local_sb_idx = srch_stor_blk_tbl(SB_NAME_PTR(sb_idx),
11570 SB_NAME_LEN(sb_idx),
11571 curr_scp_idx);
11572
11573
11574
11575 if (local_sb_idx != NULL_IDX) {
11576 if (PDG_SB_IDX(local_sb_idx) != NULL_IDX) {
11577 PDG_SB_IDX(sb_idx) = PDG_SB_IDX(local_sb_idx);
11578 }
11579 else {
11580 host_sb_idx = sb_idx;
11581 sb_idx = local_sb_idx;
11582 }
11583 }
11584 }
11585 }
11586 else if (SB_HOSTED_STACK(sb_idx)) {
11587 sb_type = Hosted_Stack;
11588 }
11589
11590 if (PDG_SB_IDX(sb_idx) != NULL_IDX) {
11591 goto EXIT;
11592 }
11593
11594 name_ptr = SB_NAME_PTR(sb_idx);
11595
11596 if (sb_type == Task_Common) {
11597
11598 }
11599 else if (SB_MODULE(sb_idx)) {
11600 sb_type = Common;
11601 }
11602 else if (sb_type == Static) {
11603 if (SB_HOSTED_STATIC(sb_idx)) {
11604 flag = flag | (1 << FEI_SEG_DUPLICATE);
11605 sb_type = Common;
11606 }
11607 else {
11608 sb_type = Static_Local;
11609 }
11610 }
11611
11612
11613
11614
11615
11616 if ((opt_flags.inline_lvl > Inline_Lvl_0 || opt_flags.modinline) &&
11617 (sb_type == Static_Local || sb_type == Static_Named)) {
11618 flag = flag | (1 << FEI_SEG_LOCAL_COMMON);
11619 }
11620
11621 if (sb_type == Common || sb_type == Task_Common) {
11622
11623 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
11624 #ifdef KEY
11625 if (SB_EXT_NAME_IDX(sb_idx)) {
11626 name_ptr = SB_EXT_NAME_PTR(sb_idx);
11627 }
11628 else
11629 #endif
11630 if (! SB_BLANK_COMMON(sb_idx) &&
11631 ! SB_NAME_IN_STONE(sb_idx)) {
11632
11633 int underscores = 0;
11634
11635
11636
11637
11638 for (i = 0; i < SB_NAME_LEN(sb_idx); i++) {
11639 new_name[i] = tolower(name_ptr[i]);
11640 if (name_ptr[i] == '_') {
11641 underscores++;
11642 }
11643 }
11644
11645 #ifdef KEY
11646 i = decorate(new_name, i, underscores);
11647 #else
11648 if (on_off_flags.underscoring) {
11649 new_name[i++] = '_';
11650 if (on_off_flags.second_underscore && (underscores > 0)) {
11651 new_name[i++] = '_';
11652 }
11653 }
11654 #endif
11655
11656 for ( ; i < 256; i++) {
11657 new_name[i] = '\0';
11658 }
11659 name_ptr = &new_name[0];
11660 }
11661 # endif
11662
11663 parent_idx = NULL_IDX;
11664 }
11665 else {
11666 parent_idx = PDG_AT_IDX(SCP_ATTR_IDX(SB_SCP_IDX(sb_idx)));
11667 }
11668 #ifdef KEY
11669 check_duplicate_external_name(SB_Tbl_Idx, sb_idx, name_ptr);
11670 #endif
11671
11672 PDG_DBG_PRINT_START
11673 PDG_DBG_PRINT_C("fei_seg");
11674 PDG_DBG_PRINT_S("(1) name_ptr", name_ptr);
11675 PDG_DBG_PRINT_S("(2) segment type", p_sb_blk_type_str[sb_type]);
11676 PDG_DBG_PRINT_S("(3) parent_idx",
11677 AT_OBJ_NAME_PTR(SCP_ATTR_IDX(SB_SCP_IDX(sb_idx))));
11678 PDG_DBG_PRINT_D("(4) unused", 0);
11679 PDG_DBG_PRINT_D("(5) unused", 0);
11680 PDG_DBG_PRINT_O("(6) flags", flag);
11681 PDG_DBG_PRINT_D("(7) unused", 0);
11682 PDG_DBG_PRINT_LLD("(8) blk_len", blk_len);
11683 PDG_DBG_PRINT_END
11684
11685 # ifdef _ENABLE_FEI
11686 PDG_SB_IDX(sb_idx) = fei_seg(name_ptr,
11687 sb_type,
11688 parent_idx,
11689 0,
11690 0,
11691 flag,
11692 0,
11693 blk_len);
11694 # endif
11695
11696 PDG_DBG_PRINT_START
11697 PDG_DBG_PRINT_LD("(r) PDG_SB_IDX", PDG_SB_IDX(sb_idx));
11698 PDG_DBG_PRINT_END
11699
11700 if (host_sb_idx != NULL_IDX) {
11701 PDG_SB_IDX(host_sb_idx) = PDG_SB_IDX(sb_idx);
11702 }
11703
11704 EXIT:
11705
11706 TRACE (Func_Exit, "send_stor_blk", NULL);
11707
11708 return;
11709
11710 }
11711
11712
11713
11714
11715
11716
11717
11718
11719
11720
11721
11722
11723
11724
11725
11726
11727
11728
11729 static void send_dummy_procedure(int attr_idx)
11730
11731 {
11732 long64 flag;
11733 long64 size;
11734 size_offset_type stor_size;
11735 TYPE type_idx;
11736 int class;
11737
11738
11739 TRACE (Func_Entry, "send_dummy_procedure", NULL);
11740
11741 send_stor_blk(SCP_SB_DARG_IDX(curr_scp_idx), &class);
11742
11743 class = Dummy_Procedure;
11744
11745 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
11746 if (curr_scp_idx != ATP_SCP_IDX(attr_idx)) {
11747 class = Hosted_Dummy_Procedure;
11748 }
11749 # endif
11750
11751 if (ATP_RSLT_IDX(attr_idx) == NULL_IDX) {
11752 type_idx = get_type_desc(attr_idx);
11753 }
11754 else {
11755 type_idx = get_type_desc(ATP_RSLT_IDX(attr_idx));
11756 }
11757
11758 if (ATP_PGM_UNIT(attr_idx) == Function &&
11759 TYP_TYPE(ATD_TYPE_IDX(ATP_RSLT_IDX(attr_idx))) == Character) {
11760 stor_size = stor_bit_size_of(attr_idx, FALSE, FALSE);
11761
11762 if (stor_size.fld == CN_Tbl_Idx) {
11763 size = CN_INT_TO_C(stor_size.idx);
11764 }
11765 else {
11766 size = F_INT_TO_C(stor_size.constant, TYP_LINEAR(stor_size.type_idx));
11767 }
11768 }
11769 else {
11770 size = (long64) TARGET_BITS_PER_WORD;
11771 }
11772
11773
11774 flag = ((long64) AT_REF_IN_CHILD(attr_idx) << FEI_OBJECT_INNER_REF) |
11775 ((long64) AT_DEF_IN_CHILD(attr_idx) << FEI_OBJECT_INNER_DEF) |
11776 ((long64) AT_DEFINED(attr_idx) << FEI_OBJECT_DEFINED);
11777
11778 PDG_DBG_PRINT_START
11779 PDG_DBG_PRINT_C("fei_object");
11780 PDG_DBG_PRINT_S("(1) AT_OBJ_NAME", AT_OBJ_NAME_PTR(attr_idx));
11781 PDG_DBG_PRINT_T("(2) type", type_idx);
11782 PDG_DBG_PRINT_LLO("(3) flags", flag);
11783 PDG_DBG_PRINT_S("(4) symbol class", p_obj_sym_class[class]);
11784 PDG_DBG_PRINT_S("(5) block", SB_NAME_PTR(SCP_SB_DARG_IDX(curr_scp_idx)));
11785 PDG_DBG_PRINT_D("(6) unused", 0);
11786 PDG_DBG_PRINT_D("(7) unused", 0);
11787 PDG_DBG_PRINT_D("(8) unused", 0);
11788 PDG_DBG_PRINT_S("(9) intent", p_intent[Intent_Inout]);
11789 PDG_DBG_PRINT_LLD("(10) bit size", size);
11790 PDG_DBG_PRINT_D("(11) unused", 0);
11791 PDG_DBG_PRINT_D("(12) storage align", Word_Align);
11792 PDG_DBG_PRINT_D("(13) unused", 0);
11793 PDG_DBG_PRINT_D("(14) unused", 0);
11794 PDG_DBG_PRINT_D("(15) unused", 0);
11795 PDG_DBG_PRINT_D("(16) def line", AT_DEF_LINE(attr_idx));
11796 PDG_DBG_PRINT_END
11797
11798 # ifdef _ENABLE_FEI
11799 PDG_AT_IDX(attr_idx) = fei_object(AT_OBJ_NAME_PTR(attr_idx),
11800 type_idx,
11801 flag,
11802 class,
11803 PDG_SB_IDX(SCP_SB_DARG_IDX(curr_scp_idx)),
11804 0,
11805 0,
11806 0,
11807 Intent_Inout,
11808 size,
11809 0,
11810 Word_Align,
11811 0,
11812 0,
11813 0,
11814 AT_DEF_LINE(attr_idx));
11815 # endif
11816
11817 PDG_DBG_PRINT_START
11818 PDG_DBG_PRINT_LD("(r) PDG_AT_IDX", PDG_AT_IDX(attr_idx));
11819 PDG_DBG_PRINT_END
11820
11821 TRACE (Func_Exit, "send_dummy_procedure", NULL);
11822
11823 return;
11824
11825 }
11826
11827
11828
11829
11830
11831
11832
11833
11834
11835
11836
11837
11838
11839
11840
11841
11842
11843
11844
11845
11846
11847
11848
11849
11850
11851
11852
11853
11854 static void send_procedure(int attr_idx,
11855 int alt_entry_idx,
11856 int call_type)
11857
11858 {
11859 int darg_pdg_sn_fw_idx = NULL_IDX;
11860 boolean pure;
11861 long64 flag3 = (long64) 0;
11862 int main_entry_idx;
11863 char *name_ptr;
11864 int num_dargs = 0;
11865 int parent_idx;
11866 int pdg_alt_entry_idx = NULL_IDX;
11867 int pgm_unit;
11868 long prev_idx;
11869 int proc;
11870 #ifdef KEY
11871 TYPE type_desc = pdg_type_void;
11872 #else
11873 TYPE type_desc;
11874 #endif
11875
11876
11877 TRACE (Func_Entry, "send_procedure", NULL);
11878
11879 if (call_type == Imported) {
11880 if (ATP_PROC(attr_idx) == Dummy_Proc) {
11881 send_dummy_procedure(attr_idx);
11882 goto EXIT;
11883 }
11884
11885 if (ATP_PGM_UNIT(attr_idx) == Module && ATP_IN_CURRENT_COMPILE(attr_idx)){
11886
11887
11888 goto EXIT;
11889 }
11890
11891 if (ATP_PGM_UNIT(SCP_ATTR_IDX(curr_scp_idx)) == Module) {
11892
11893 goto EXIT;
11894 }
11895
11896 if (AT_USE_ASSOCIATED(attr_idx) &&
11897 AT_REFERENCED(attr_idx) == Not_Referenced &&
11898 ATP_IN_INTERFACE_BLK(attr_idx) &&
11899 ATP_EXPL_ITRFC(attr_idx) &&
11900 ATP_PROC(attr_idx) == Extern_Proc) {
11901 name_ptr = &name_pool[ATP_EXT_NAME_IDX(attr_idx)].name_char;
11902 if (strcmp(AT_OBJ_NAME_PTR(SCP_ATTR_IDX(curr_scp_idx)),
11903 name_ptr) == 0) {
11904
11905
11906
11907
11908
11909 goto EXIT;
11910 }
11911 }
11912 }
11913
11914 pgm_unit = ATP_PGM_UNIT(attr_idx);
11915 name_ptr = &name_pool[ATP_EXT_NAME_IDX(attr_idx)].name_char;
11916 parent_idx = NULL_IDX;
11917
11918
11919 pure = ATP_NOSIDE_EFFECTS(attr_idx) ||
11920 ATP_PURE(attr_idx) ||
11921 ATP_ELEMENTAL(attr_idx);
11922
11923 flag3 =
11924 ((long64) ATP_VFUNCTION(attr_idx) << FEI_PROC_VFUNC)|
11925 ((long64) pure << FEI_PROC_CNGA)|
11926 ((long64) pure << FEI_PROC_CNAA)|
11927 ((long64) pure << FEI_PROC_CNGO)|
11928 ((long64) pure << FEI_PROC_RNGO)|
11929 ((long64) !SCP_DOES_IO(curr_scp_idx) << FEI_PROC_NOIO)|
11930 ((long64) !SCP_HAS_CALLS(curr_scp_idx) << FEI_PROC_NOCALLS)|
11931 ((long64) ATP_ALL_INTENT_IN(attr_idx) << FEI_PROC_DNDA)|
11932 ((long64) ATP_RECURSIVE(attr_idx) << FEI_PROC_RECURSE)|
11933 ((long64) ATP_HAS_TASK_DIRS(SCP_ATTR_IDX(curr_scp_idx))
11934 << FEI_PROC_MICROTASK)|
11935 ((long64) opt_flags.taskinner << FEI_PROC_TASKINNER)|
11936 ((long64) !opt_flags.threshold << FEI_PROC_NOTHRESHOLDS)|
11937 ((long64) 1 << FEI_PROC_TOLERANT)|
11938 ((long64) on_off_flags.alloc_autos_on_stack << FEI_PROC_LIMHEAP)|
11939 ((long64) ATP_DCL_EXTERNAL(attr_idx) << FEI_PROC_IMMORT)|
11940 ((long64) ATP_EXTRA_DARG(attr_idx) << FEI_PROC_HASRSLT)|
11941 ((long64) on_off_flags.indef_init << FEI_PROC_INDEFSTK)|
11942 ((long64) (cmd_line_flags.solaris_profile | cdir_switches.flow)
11943 << FEI_PROC_DOFLOWTR)|
11944 ((long64) opt_flags.zeroinc << FEI_PROC_ZEROINC)|
11945 ((long64) ATP_ALIGN(attr_idx) << FEI_PROC_ALGNINST)|
11946 ((long64) ATP_NAME_IN_STONE(attr_idx) << FEI_PROC_PERM_NAME)|
11947 ((long64) on_off_flags.round_mult_operations << FEI_PROC_STRROUND)|
11948 ((long64) !on_off_flags.round_mult_operations << FEI_PROC_TRUNCATE)|
11949 ((long64) (opt_flags.over_index |
11950 ATP_HAS_OVER_INDEXING(SCP_ATTR_IDX(curr_scp_idx)))
11951 << FEI_PROC_NCOADDR)|
11952 ((long64) ((ATP_PGM_UNIT(attr_idx) == Function) & on_off_flags.recursive)
11953 << FEI_PROC_RECURSE)|
11954 ((long64) ((ATP_PGM_UNIT(attr_idx) == Subroutine) & on_off_flags.recursive)
11955 << FEI_PROC_RECURSE)|
11956 ((long64) ((attr_idx == SCP_ATTR_IDX(curr_scp_idx)) &
11957 (ATP_PGM_UNIT(attr_idx) == Module))
11958 << FEI_PROC_MOD_FIRST)|
11959 ((long64) ((attr_idx == SCP_ATTR_IDX(curr_scp_idx)) &
11960 (ATP_PROC(attr_idx) == Module_Proc))
11961 << FEI_PROC_MOD_JUST)|
11962 ((long64) (attr_idx == AT_WORK_IDX) << FEI_PROC_MOD_LAST)|
11963 ((long64) ATP_ARGCHCK_CALL(attr_idx) << FEI_PROC_ARG_CHECK)|
11964 ((long64) on_off_flags.zero_init << FEI_PROC_ZERO_INIT)|
11965 ((long64) ATP_OPTIONAL_DIR(attr_idx) << FEI_PROC_OPTIONAL_DIR)|
11966 ((long64) (call_type == Definition) << FEI_PROC_DEFINITION)|
11967 ((long64) (call_type == Imported) << FEI_PROC_IMPORTED)|
11968 ((long64) (call_type == Parent) << FEI_PROC_PARENT)|
11969 ((long64) (ATP_NOSIDE_EFFECTS(attr_idx) | ATP_PURE(attr_idx))
11970 << FEI_PROC_NOSIDE_EFFECTS)|
11971 ((long64) ATP_ELEMENTAL(attr_idx) << FEI_PROC_ELEMENTAL);
11972
11973 if (ATP_PGM_UNIT(attr_idx) == Module &&
11974 (ATP_SCP_IDX(attr_idx) != curr_scp_idx ||
11975 !ATP_IN_CURRENT_COMPILE(attr_idx))) {
11976 flag3 = flag3 | ((long64) 1 << FEI_PROC_IMMORT);
11977 }
11978
11979
11980 if (call_type == Definition || call_type == Parent) {
11981 if (SCP_ALT_ENTRY_CNT(ATP_SCP_IDX(attr_idx)) > 0) {
11982 flag3 = flag3 | ((long64) 1 << FEI_PROC_HAS_ALT_ENTRY);
11983 }
11984
11985 if (ATP_SGI_GLOBAL_INLINE(attr_idx)) {
11986 flag3 = flag3 | ((long64) 1 << FEI_PROC_GLOBAL_INLINE);
11987 }
11988
11989 proc = ATP_PROC(attr_idx);
11990
11991 if (SCP_PARENT_IDX(curr_scp_idx) != NULL_IDX &&
11992 ATP_PGM_UNIT(SCP_ATTR_IDX(SCP_PARENT_IDX(curr_scp_idx))) != Module) {
11993 parent_idx = PDG_AT_IDX(SCP_ATTR_IDX(SCP_PARENT_IDX(curr_scp_idx)));
11994 }
11995
11996 if (ATP_PROC(attr_idx) == Unknown_Proc ||
11997 ATP_PROC(attr_idx) == Module_Proc) {
11998 proc = Extern_Proc;
11999 }
12000
12001 if (alt_entry_idx != NULL_IDX) {
12002 if (ATP_ALT_ENTRY(attr_idx)) {
12003 pdg_alt_entry_idx = alt_entry_idx;
12004 flag3 = flag3 | ((long64) 1 << FEI_PROC_ENTRY);
12005 }
12006 else {
12007 PDG_DBG_PRINT_START
12008 PDG_DBG_PRINT_C("fei_next_name");
12009 PDG_DBG_PRINT_D("(1) logical", TRUE);
12010 PDG_DBG_PRINT_END
12011
12012 # ifdef _ENABLE_FEI
12013 pdg_alt_entry_idx = fei_next_name(TRUE);
12014 # endif
12015 }
12016 }
12017
12018 if (ATP_PROC(attr_idx) == Intern_Proc) {
12019 pdg_alt_entry_idx = parent_idx;
12020 }
12021 }
12022 else {
12023 proc = (ATP_PROC(attr_idx) == Intern_Proc) ? Intern_Proc_Refd :
12024 Imported_Proc;
12025
12026 if (attr_idx == glb_tbl_idx[Buffer_In_Attr_Idx]) {
12027 flag3 = flag3 | ((long64) 1 << FEI_PROC_BUFIN);
12028 }
12029 else if (attr_idx == glb_tbl_idx[Buffer_Out_Attr_Idx]) {
12030 flag3 = flag3 | ((long64) 1 << FEI_PROC_BUFOUT);
12031 }
12032 }
12033
12034 switch (pgm_unit) {
12035
12036 case Module:
12037 case Blockdata:
12038 case Program:
12039 case Pgm_Unknown:
12040 type_desc = pdg_type_void;
12041 break;
12042
12043
12044 case Subroutine:
12045 num_dargs = (call_type == Imported) ? 0 : ATP_NUM_DARGS(attr_idx);
12046
12047 if (ATP_HAS_ALT_RETURN(attr_idx)) {
12048 pgm_unit = Function;
12049 type_desc = get_basic_type(CG_INTEGER_DEFAULT_TYPE,
12050 type_alignment_tbl[CG_INTEGER_DEFAULT_TYPE],
12051 NULL_IDX);
12052 }
12053 else {
12054 type_desc = pdg_type_void;
12055 }
12056 break;
12057
12058
12059 case Function:
12060 num_dargs = (call_type == Imported) ? 0 : ATP_NUM_DARGS(attr_idx);
12061
12062 if (ATP_EXTRA_DARG(attr_idx)) {
12063 pgm_unit = Subroutine;
12064
12065 # ifdef KEY
12066 if (TYP_LINEAR(ATD_TYPE_IDX(ATP_RSLT_IDX(attr_idx))) == Structure_Type)
12067 type_desc = get_type_desc(attr_idx);
12068 else
12069 type_desc = pdg_type_void;
12070 # else
12071 type_desc = pdg_type_void;
12072 # endif
12073 }
12074 else {
12075
12076
12077
12078
12079
12080
12081
12082 type_desc = get_type_desc(attr_idx);
12083
12084 if (call_type == Definition ||
12085 (call_type == Parent &&
12086 SB_HOSTED_STACK(ATD_STOR_BLK_IDX(ATP_RSLT_IDX(attr_idx))))) {
12087
12088
12089
12090
12091
12092
12093
12094
12095
12096
12097
12098 send_attr_ntry(ATP_RSLT_IDX(attr_idx));
12099 }
12100 }
12101 break;
12102 }
12103
12104 if (num_dargs != 0) {
12105 PDG_DBG_PRINT_START
12106 PDG_DBG_PRINT_C("fei_next_name");
12107 PDG_DBG_PRINT_D("(1) logical", TRUE);
12108 PDG_DBG_PRINT_END
12109
12110 # ifdef _ENABLE_FEI
12111 darg_pdg_sn_fw_idx = fei_next_name(TRUE);
12112 # endif
12113 }
12114
12115 PDG_DBG_PRINT_START
12116 PDG_DBG_PRINT_C("fei_proc");
12117 PDG_DBG_PRINT_S("(1) name_ptr", name_ptr);
12118 PDG_DBG_PRINT_D("(2) AT_DEF_LINE", AT_DEF_LINE(attr_idx));
12119 PDG_DBG_PRINT_S("(3) pgm_unit", p_atp_pgm_unit[pgm_unit]);
12120 PDG_DBG_PRINT_S("(4) proc", p_proc[proc]);
12121 PDG_DBG_PRINT_D("(5) num_dargs", num_dargs);
12122 PDG_DBG_PRINT_D("(6) parent_idx", parent_idx);
12123 PDG_DBG_PRINT_D("(7) pdg darg list", darg_pdg_sn_fw_idx);
12124 PDG_DBG_PRINT_D("(8) alt link idx", pdg_alt_entry_idx);
12125 PDG_DBG_PRINT_T("(9) type", type_desc);
12126 PDG_DBG_PRINT_LD("(10) PDG_AT_IDX", PDG_AT_IDX(attr_idx));
12127 PDG_DBG_PRINT_LLO("(11) flags", flag3);
12128 PDG_DBG_PRINT_END
12129 # ifdef _ENABLE_FEI
12130 PDG_AT_IDX(attr_idx) = fei_proc(name_ptr,
12131 AT_DEF_LINE(attr_idx),
12132 pgm_unit,
12133 proc,
12134 num_dargs,
12135 parent_idx,
12136 darg_pdg_sn_fw_idx,
12137 pdg_alt_entry_idx,
12138 type_desc,
12139 PDG_AT_IDX(attr_idx),
12140 flag3);
12141 # endif
12142
12143 PDG_DBG_PRINT_START
12144 PDG_DBG_PRINT_LD("(r) PDG_AT_IDX", PDG_AT_IDX(attr_idx));
12145 PDG_DBG_PRINT_END
12146
12147
12148
12149 if (cmd_line_flags.debug_lvl <= Debug_Lvl_2) {
12150 if (ATP_PROC(attr_idx) == Intrin_Proc) {
12151 if (ATP_INTERFACE_IDX(attr_idx) != NULL_IDX) {
12152 PDG_DBG_PRINT_START
12153 PDG_DBG_PRINT_C("fei_smt_actual_to_generic");
12154 PDG_DBG_PRINT_LD("PDG_AT_IDX", PDG_AT_IDX(attr_idx));
12155 PDG_DBG_PRINT_END
12156
12157 # ifdef _ENABLE_FEI
12158 fei_smt_actual_to_generic(PDG_AT_IDX(attr_idx),
12159 AT_OBJ_NAME_PTR(ATP_INTERFACE_IDX(attr_idx)));
12160 # endif
12161 }
12162 }
12163
12164 if (ATP_EXT_NAME_IDX(attr_idx) != AT_NAME_IDX(attr_idx)) {
12165
12166
12167 PDG_DBG_PRINT_START
12168 PDG_DBG_PRINT_C("fei_smt_original_to_qualified");
12169 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX", PDG_AT_IDX(attr_idx));
12170 PDG_DBG_PRINT_S("(2) AT_OBJ_NAME", AT_OBJ_NAME_PTR(attr_idx));
12171 PDG_DBG_PRINT_END
12172
12173 # ifdef _ENABLE_FEI
12174 fei_smt_original_to_qualified(PDG_AT_IDX(attr_idx),
12175 AT_OBJ_NAME_PTR(attr_idx));
12176 # endif
12177 }
12178 }
12179
12180 if (num_dargs != 0) {
12181 send_darg_list(attr_idx, darg_pdg_sn_fw_idx);
12182 }
12183
12184 if (alt_entry_idx != NULL_IDX && !ATP_ALT_ENTRY(attr_idx)) {
12185
12186
12187
12188
12189 prev_idx = NULL_IDX;
12190 main_entry_idx = attr_idx;
12191
12192 while (alt_entry_idx != NULL_IDX) {
12193 attr_idx = AL_ATTR_IDX(alt_entry_idx);
12194 #ifdef KEY
12195 check_duplicate_external_name(AT_Tbl_Idx, attr_idx,
12196 ATP_EXT_NAME_PTR(attr_idx));
12197 #endif
12198
12199
12200
12201
12202
12203
12204 ATP_SCP_ALIVE(attr_idx) = TRUE;
12205
12206 send_procedure(attr_idx,
12207 PDG_AT_IDX(main_entry_idx),
12208 call_type);
12209
12210 ATP_SCP_ALIVE(attr_idx) = FALSE;
12211
12212 name_ptr = &name_pool[ATP_EXT_NAME_IDX(attr_idx)].name_char;
12213
12214
12215
12216
12217 PDG_DBG_PRINT_START
12218 PDG_DBG_PRINT_C("fei_name");
12219 PDG_DBG_PRINT_S("(1) name_ptr", name_ptr);
12220 PDG_DBG_PRINT_S("(2) table", "PDGCS_Function");
12221 PDG_DBG_PRINT_LD("(3) PDG_AT_IDX", PDG_AT_IDX(attr_idx));
12222 PDG_DBG_PRINT_D("(4) prev_idx", prev_idx);
12223 PDG_DBG_PRINT_D("(5) pdg_alt_entry_idx", pdg_alt_entry_idx);
12224 PDG_DBG_PRINT_END
12225
12226 # ifdef _ENABLE_FEI
12227 prev_idx = fei_name(name_ptr,
12228 Sym_Function,
12229 PDG_AT_IDX(attr_idx),
12230 prev_idx,
12231 pdg_alt_entry_idx);
12232 # endif
12233 alt_entry_idx = AL_NEXT_IDX(alt_entry_idx);
12234
12235 if (alt_entry_idx != NULL_IDX) {
12236 PDG_DBG_PRINT_START
12237 PDG_DBG_PRINT_C("fei_next_name");
12238 PDG_DBG_PRINT_D("(1) logical", TRUE);
12239 PDG_DBG_PRINT_END
12240
12241 # ifdef _ENABLE_FEI
12242 pdg_alt_entry_idx = fei_next_name(TRUE);
12243 # endif
12244 }
12245 }
12246 }
12247
12248 EXIT:
12249
12250 TRACE (Func_Exit, "send_procedure", NULL);
12251
12252 return;
12253
12254 }
12255
12256
12257
12258
12259
12260
12261
12262
12263
12264
12265
12266
12267
12268
12269
12270
12271
12272 static TYPE send_derived_type(int type_idx)
12273
12274 {
12275 int attr_idx;
12276 int cpnt_idx;
12277 int dt_attr_idx;
12278 long flag = 0;
12279 int dt_idx;
12280 long prev_idx;
12281 int sequence;
12282 int sn_idx;
12283 long64 size;
12284 TYPE pdg_type_idx;
12285
12286
12287 TRACE (Func_Entry, "send_derived_type", NULL);
12288
12289 dt_attr_idx = TYP_IDX(type_idx);
12290
12291 while (AT_ATTR_LINK(dt_attr_idx) != NULL_IDX) {
12292 dt_attr_idx = AT_ATTR_LINK(dt_attr_idx);
12293 }
12294
12295 if (PDG_AT_IDX(dt_attr_idx) != NULL_IDX) {
12296 pdg_type_idx = pdg_type_tbl[PDG_AT_TYP_IDX(dt_attr_idx)];
12297 pdg_type_tbl[type_idx] = pdg_type_idx;
12298 goto EXIT;
12299 }
12300 #ifdef KEY
12301 if (c_ptr_abi_trouble(dt_attr_idx)) {
12302 pdg_type_idx = fei_descriptor(0, Basic, bit_size_tbl[Integer_4], Integral,
12303 0 , pdg_align[Word_Align]);
12304 return pdg_type_idx;
12305 }
12306 #endif
12307
12308 flag = ((long) (ATT_SCP_IDX(dt_attr_idx) != curr_scp_idx)
12309 << FEI_NEXT_TYPE_IDX_HOSTED_TYPE);
12310
12311 PDG_DBG_PRINT_START
12312 PDG_DBG_PRINT_C("fei_next_name");
12313 PDG_DBG_PRINT_D("(1) logical", TRUE);
12314 PDG_DBG_PRINT_END
12315
12316 # ifdef _ENABLE_FEI
12317 cpnt_idx = fei_next_name(TRUE);
12318 # endif
12319
12320 PDG_DBG_PRINT_START
12321 PDG_DBG_PRINT_C("fei_next_type_idx");
12322 PDG_DBG_PRINT_LO("(1) flags", flag);
12323 PDG_DBG_PRINT_D("(2) alignment", pdg_align[ATT_ALIGNMENT(dt_attr_idx)]);
12324 PDG_DBG_PRINT_END
12325
12326 # ifdef _ENABLE_FEI
12327 dt_idx = fei_next_type_idx(flag, pdg_align[ATT_ALIGNMENT(dt_attr_idx)]);
12328 # endif
12329
12330 sequence = (ATT_CHAR_SEQ(dt_attr_idx)) ? Seq_Char : Seq_Mixed;
12331
12332 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
12333 if (ATT_CHAR_SEQ(dt_attr_idx)) {
12334 sequence = Seq_Char;
12335 }
12336 else if (ATT_DCL_NUMERIC_SEQ(dt_attr_idx)) {
12337 sequence = Seq_Numeric;
12338 }
12339 else if (ATT_SEQUENCE_SET(dt_attr_idx)) {
12340 sequence = Seq_Mixed;
12341 }
12342 else {
12343 sequence = Seq_None;
12344 }
12345 # endif
12346
12347 size = CN_INT_TO_C(ATT_STRUCT_BIT_LEN_IDX(dt_attr_idx));
12348
12349 PDG_DBG_PRINT_START
12350 PDG_DBG_PRINT_C("fei_user_type");
12351 PDG_DBG_PRINT_S("(1) AT_OBJ_NAME", AT_OBJ_NAME_PTR(dt_attr_idx));
12352 PDG_DBG_PRINT_D("(2) ATT_NUM_CPNTS", ATT_NUM_CPNTS(dt_attr_idx));
12353 PDG_DBG_PRINT_D("(3) cpnt_idx", cpnt_idx);
12354 PDG_DBG_PRINT_LLD("(4) struct size", size);
12355 PDG_DBG_PRINT_S("(5) sequence", p_sequence[sequence]);
12356 PDG_DBG_PRINT_D("(6) dt_idx", dt_idx);
12357 PDG_DBG_PRINT_D("(7) alignment", pdg_align[ATT_ALIGNMENT(dt_attr_idx)]);
12358 PDG_DBG_PRINT_END
12359
12360 # ifdef _ENABLE_FEI
12361 fei_user_type(AT_OBJ_NAME_PTR(dt_attr_idx),
12362 ATT_NUM_CPNTS(dt_attr_idx),
12363 cpnt_idx,
12364 size,
12365 sequence,
12366 dt_idx,
12367 pdg_align[ATT_ALIGNMENT(dt_attr_idx)]);
12368 # endif
12369
12370
12371 PDG_DBG_PRINT_START
12372 PDG_DBG_PRINT_C("fei_descriptor");
12373 PDG_DBG_PRINT_D("(1) flags",0);
12374 PDG_DBG_PRINT_S("(2) table type", p_table_type[Basic]);
12375 PDG_DBG_PRINT_D("(3) dt_idx", dt_idx);
12376 PDG_DBG_PRINT_S("(4) basic type", p_basic_type[S_tructure]);
12377 PDG_DBG_PRINT_D("(5) aux info",0);
12378 PDG_DBG_PRINT_D("(6) alignment", pdg_align[ATT_ALIGNMENT(dt_attr_idx)]);
12379 PDG_DBG_PRINT_END
12380 # ifdef _ENABLE_FEI
12381 pdg_type_idx = fei_descriptor(0,
12382 Basic,
12383 dt_idx,
12384 S_tructure,
12385 0,
12386 pdg_align[ATT_ALIGNMENT(dt_attr_idx)]);
12387 # endif
12388 PDG_DBG_PRINT_START
12389 PDG_DBG_PRINT_T("(r) type", pdg_type_idx);
12390 PDG_DBG_PRINT_END
12391
12392 pdg_type_tbl[type_idx] = pdg_type_idx;
12393 PDG_AT_IDX(dt_attr_idx) = dt_idx;
12394 PDG_AT_TYP_IDX(dt_attr_idx) = type_idx;
12395 dt_attr_idx = TYP_IDX(type_idx);
12396
12397 while (AT_ATTR_LINK(dt_attr_idx) != NULL_IDX) {
12398 PDG_AT_IDX(dt_attr_idx) = dt_idx;
12399 dt_attr_idx = AT_ATTR_LINK(dt_attr_idx);
12400 }
12401
12402 prev_idx = NULL_IDX;
12403 sn_idx = ATT_FIRST_CPNT_IDX(dt_attr_idx);
12404
12405 do {
12406 #ifdef KEY
12407
12408 if (sn_idx == NULL_IDX) {
12409 break;
12410 }
12411 #endif
12412 attr_idx = SN_ATTR_IDX(sn_idx);
12413 send_attr_ntry(attr_idx);
12414
12415 PDG_DBG_PRINT_START
12416 PDG_DBG_PRINT_C("fei_name");
12417 PDG_DBG_PRINT_S("(1) AT_OBJ_NAME", AT_OBJ_NAME_PTR(attr_idx));
12418 PDG_DBG_PRINT_S("(2) table", "PDGCS_Member");
12419 PDG_DBG_PRINT_LD("(3) PDG_AT_IDX", PDG_AT_IDX(attr_idx));
12420 PDG_DBG_PRINT_D("(4) prev_idx", prev_idx);
12421 PDG_DBG_PRINT_D("(5) cpnt_idx", cpnt_idx);
12422 PDG_DBG_PRINT_END
12423
12424 # ifdef _ENABLE_FEI
12425 prev_idx = fei_name(AT_OBJ_NAME_PTR(attr_idx),
12426 Sym_Member,
12427 PDG_AT_IDX(attr_idx),
12428 prev_idx,
12429 cpnt_idx);
12430 # endif
12431
12432 sn_idx = SN_SIBLING_LINK(sn_idx);
12433
12434 if (sn_idx != NULL_IDX) {
12435 PDG_DBG_PRINT_START
12436 PDG_DBG_PRINT_C("fei_next_name");
12437 PDG_DBG_PRINT_D("(1) logical", TRUE);
12438 PDG_DBG_PRINT_END
12439
12440 # ifdef _ENABLE_FEI
12441 cpnt_idx = fei_next_name(TRUE);
12442 # endif
12443 }
12444
12445 } while (sn_idx != NULL_IDX);
12446
12447 EXIT:
12448
12449 TRACE (Func_Exit, "send_derived_type", NULL);
12450
12451 return(pdg_type_idx);
12452
12453 }
12454
12455
12456
12457
12458
12459
12460
12461
12462
12463
12464
12465
12466
12467
12468
12469
12470
12471 static void send_label(int attr_idx)
12472
12473 {
12474 int label_flag;
12475 int label_class = ATL_CLASS(attr_idx);
12476 char *fmt_ptr = NULL;
12477
12478
12479 TRACE (Func_Entry, "send_label", NULL);
12480
12481 if (!ATL_EXECUTABLE(attr_idx) && ATL_CLASS(attr_idx) <= Lbl_User) {
12482
12483
12484
12485 return;
12486 }
12487
12488 label_flag = (ATL_ALIGN(attr_idx) << FEI_LABEL_ALGNINST) |
12489 (opt_flags.loopalign << FEI_LABEL_ALGNLOOP);
12490
12491 switch (ATL_CLASS(attr_idx)) {
12492
12493 case Lbl_Construct:
12494 label_class = Lbl_User;
12495 break;
12496
12497 case Lbl_Format:
12498 fmt_ptr = (char *) &CN_CONST(ATD_TMP_IDX(ATL_FORMAT_TMP(attr_idx)));
12499 break;
12500
12501 }
12502
12503 PDG_DBG_PRINT_START
12504 PDG_DBG_PRINT_C("fei_label");
12505 PDG_DBG_PRINT_S("(1) AT_OBJ_NAME", AT_OBJ_NAME_PTR(attr_idx));
12506 PDG_DBG_PRINT_O("(2) flags", label_flag);
12507 PDG_DBG_PRINT_S("(3) label class", p_label[label_class]);
12508 PDG_DBG_PRINT_S("(4) fmt_ptr", fmt_ptr);
12509 PDG_DBG_PRINT_S("(5) ATL_DEBUG_CLASS",
12510 p_dbg_label[ATL_DEBUG_CLASS(attr_idx)]);
12511 PDG_DBG_PRINT_END
12512
12513 # ifdef _ENABLE_FEI
12514 PDG_AT_IDX(attr_idx) = fei_label(AT_OBJ_NAME_PTR(attr_idx),
12515 label_flag,
12516 label_class,
12517 fmt_ptr,
12518 ATL_DEBUG_CLASS(attr_idx));
12519 # endif
12520
12521 TRACE (Func_Exit, "send_label", NULL);
12522
12523 return;
12524 }
12525
12526
12527
12528
12529
12530
12531
12532
12533
12534
12535
12536
12537
12538
12539
12540
12541
12542 static void send_label_def(int ir_idx)
12543 {
12544 int attr_idx;
12545 int blockable_idx;
12546 int cache_bypass_count;
12547 int il_idx;
12548 int interchange_idx;
12549 int interchange_level_idx;
12550 boolean keepme;
12551 long64 label_flag = (long64) 0;
12552 int mark_name_idx;
12553 int safe_distance_idx;
12554 int safevl_idx;
12555 int suppress_cnt = 0;
12556 int task_lvl;
12557 int unroll_idx;
12558
12559
12560 TRACE (Func_Entry, "send_label_def", NULL);
12561
12562 if (IR_OPR(ir_idx) == Label_Opr) {
12563 attr_idx = IR_IDX_L(ir_idx);
12564 keepme = (cmd_line_flags.debug_lvl <= Debug_Lvl_2) ||
12565 ATL_IN_ASSIGN(attr_idx);
12566 send_attr_ntry(attr_idx);
12567 }
12568 else {
12569 keepme = FALSE;
12570 attr_idx = IR_IDX_R(ir_idx);
12571 label_flag = label_flag | ((long64) 1 << FEI_LABEL_DEF_NAMED_SUPPRESS);
12572
12573 if (IR_IDX_L(ir_idx) == NULL_IDX) {
12574
12575 IR_LIST_CNT_L(ir_idx) = 0;
12576 }
12577 else {
12578 suppress_cnt = IR_LIST_CNT_L(ir_idx);
12579 }
12580 }
12581
12582 task_lvl = (ATL_NOTASK(attr_idx)) ? Task_Lvl_0: opt_flags.task_lvl;
12583
12584 label_flag |=
12585 ((long64) ATL_IVDEP(attr_idx) << FEI_LABEL_DEF_NAMED_IVDEP)|
12586 ((long64) ATL_FISSIONABLE(attr_idx) << FEI_LABEL_DEF_NAMED_FISSIONABLE)|
12587 ((long64) ATL_FUSABLE(attr_idx) << FEI_LABEL_DEF_NAMED_FUSABLE)|
12588 ((long64) ATL_NOFISSION(attr_idx) << FEI_LABEL_DEF_NAMED_NOFISSION)|
12589 ((long64) ATL_NOFUSION(attr_idx) << FEI_LABEL_DEF_NAMED_NOFUSION)|
12590 ((long64) ATL_FUSION(attr_idx) << FEI_LABEL_DEF_NAMED_FUSION)|
12591 ((long64) ATL_NOINTERCHANGE(attr_idx)
12592 << FEI_LABEL_DEF_NAMED_NOINTERCHANGE)|
12593 ((long64) ATL_NOBLOCKING(attr_idx) << FEI_LABEL_DEF_NAMED_NOBLOCKING)|
12594 ((long64) ATL_AGGRESSIVEINNERLOOPFISSION(attr_idx)
12595 << FEI_LABEL_DEF_NAMED_AGGRESSIVEINNERLOOPFISSION)|
12596 ((long64) ATL_NORECURRENCE(attr_idx)<< FEI_LABEL_DEF_NAMED_NOREDUCE)|
12597 ((long64) ATL_NOVECTOR(attr_idx) << FEI_LABEL_DEF_NAMED_NOVECTOR)|
12598 ((long64) ATL_STREAM(attr_idx) << FEI_LABEL_DEF_NAMED_STREAM)|
12599 ((long64) ATL_PREFERSTREAM(attr_idx)
12600 << FEI_LABEL_DEF_NAMED_PREFERSTREAM)|
12601 ((long64) ATL_PREFERSTREAM_NOCINV(attr_idx)<<
12602 FEI_LABEL_DEF_NAMED_PSTREAM_NOCINV)|
12603 ((long64) ATL_SHORTLOOP(attr_idx) << FEI_LABEL_DEF_NAMED_SHORTLOOP)|
12604 ((long64) ATL_NOVSEARCH(attr_idx) << FEI_LABEL_DEF_NAMED_NOVSEARCH)|
12605 ((long64) ATL_TOP_OF_LOOP(attr_idx) << FEI_LABEL_DEF_NAMED_LOOPCHK)|
12606 ((long64) ATL_INFORM_ONLY(attr_idx) << FEI_LABEL_DEF_NAMED_INFORM_ONLY)|
12607 ((long64) ATL_BL(attr_idx) << FEI_LABEL_DEF_NAMED_DO_BL)|
12608 ((long64) (task_lvl == Task_Lvl_3) << FEI_LABEL_DEF_NAMED_NOSYNCBARR)|
12609 ((long64) (opt_flags.vector_lvl == Vector_Lvl_3)
12610 << FEI_LABEL_DEF_NAMED_EXTTABLES)|
12611 ((long64) (opt_flags.vector_lvl == Vector_Lvl_3)
12612 << FEI_LABEL_DEF_NAMED_EXTTIME)|
12613 ((long64) (AT_REFERENCED(attr_idx) == Not_Referenced)
12614 << FEI_LABEL_DEF_NAMED_NOT_REFERENCED)|
12615 ((long64) ATL_CNCALL(attr_idx) << FEI_LABEL_DEF_NAMED_CONCCALLS)|
12616 ((long64) ATL_PERMUTATION(attr_idx) << FEI_LABEL_DEF_NAMED_PERMUTATION)|
12617 ((long64) ATL_NEXTSCALAR(attr_idx) << FEI_LABEL_DEF_NAMED_NEXTSCALAR)|
12618 ((long64) ATL_SHORTLOOP128(attr_idx)
12619 << FEI_LABEL_DEF_NAMED_SHORTLOOP128)|
12620 ((long64) ATL_PREFERVECTOR(attr_idx)<< FEI_LABEL_DEF_NAMED_SELECT_VEC)|
12621 ((long64) ATL_PREFERTASK(attr_idx) << FEI_LABEL_DEF_NAMED_SELECT_TASK)|
12622 ((long64) ATL_NOTASK(attr_idx) << FEI_LABEL_DEF_NAMED_NOTASK)|
12623 ((long64) ATL_UNROLL_DIR(attr_idx) << FEI_LABEL_DEF_NAMED_UNROLL)|
12624 ((long64) ATL_SPLIT(attr_idx) << FEI_LABEL_DEF_NAMED_STREAMSPLIT)|
12625 ((long64) ATL_PATTERN(attr_idx) << FEI_LABEL_DEF_NAMED_PATTERN)|
12626 ((long64) ATL_CONSTRUCTOR_LOOP(attr_idx)
12627 << FEI_LABEL_DEF_NAMED_CONSTRUCTOR_LOOP)|
12628 ((long64) ATL_CONCURRENT(attr_idx) << FEI_LABEL_DEF_NAMED_CONCURRENT)|
12629 ((long64) ATL_CASE_LABEL(attr_idx) << FEI_LABEL_DEF_NAMED_CASE);
12630
12631
12632
12633
12634 safevl_idx = NULL_IDX;
12635 unroll_idx = NULL_IDX;
12636 mark_name_idx = NULL_IDX;
12637 cache_bypass_count = 0;
12638 safe_distance_idx = NULL_IDX;
12639 blockable_idx = NULL_IDX;
12640 interchange_idx = NULL_IDX;
12641 interchange_level_idx= NULL_IDX;
12642
12643 if (ATL_DIRECTIVE_LIST(attr_idx) != NULL_IDX) {
12644 il_idx = IL_IDX(ATL_DIRECTIVE_LIST(attr_idx)) + Safevl_Dir_Idx;
12645
12646 if (IL_FLD(il_idx) == CN_Tbl_Idx) {
12647 safevl_idx = IL_IDX(il_idx);
12648 }
12649
12650 il_idx = IL_IDX(ATL_DIRECTIVE_LIST(attr_idx)) + Unroll_Dir_Idx;
12651
12652 if (IL_FLD(il_idx) == CN_Tbl_Idx) {
12653 unroll_idx = IL_IDX(il_idx);
12654 }
12655
12656 il_idx = IL_IDX(ATL_DIRECTIVE_LIST(attr_idx)) + Mark_Dir_Idx;
12657
12658 if (IL_FLD(il_idx) == CN_Tbl_Idx) {
12659 mark_name_idx = IL_IDX(il_idx);
12660 }
12661
12662 il_idx = IL_IDX(ATL_DIRECTIVE_LIST(attr_idx)) + Cache_Bypass_Dir_Idx;
12663
12664 if (IL_FLD(il_idx) == IL_Tbl_Idx) {
12665 cache_bypass_count = IL_LIST_CNT(il_idx);
12666 il_idx = IL_IDX(il_idx);
12667
12668 while (il_idx != NULL_IDX) {
12669 cvrt_exp_to_pdg(IL_IDX(il_idx), AT_Tbl_Idx);
12670 il_idx = IL_NEXT_LIST_IDX(il_idx);
12671 }
12672 }
12673
12674 il_idx = IL_IDX(ATL_DIRECTIVE_LIST(attr_idx)) + Concurrent_Dir_Idx;
12675
12676 if (IL_FLD(il_idx) == CN_Tbl_Idx) {
12677 safe_distance_idx = IL_IDX(il_idx);
12678 }
12679
12680 il_idx = IL_IDX(ATL_DIRECTIVE_LIST(attr_idx)) + Blockable_Dir_Idx;
12681
12682 if (IL_FLD(il_idx) == CN_Tbl_Idx) {
12683 blockable_idx = IL_IDX(il_idx);
12684 }
12685
12686 il_idx = IL_IDX(ATL_DIRECTIVE_LIST(attr_idx)) + Interchange_Dir_Idx;
12687
12688 if (IL_FLD(il_idx) == CN_Tbl_Idx) {
12689 interchange_idx = IL_IDX(il_idx);
12690 }
12691
12692 il_idx = IL_IDX(ATL_DIRECTIVE_LIST(attr_idx)) + Interchange_Level_Dir_Idx;
12693
12694 if (IL_FLD(il_idx) == CN_Tbl_Idx) {
12695 interchange_level_idx = IL_IDX(il_idx);
12696 }
12697 }
12698
12699
12700 PDG_DBG_PRINT_START
12701 PDG_DBG_PRINT_C("fei_label_def_named");
12702 PDG_DBG_PRINT_S("AT_OBJ_NAME", AT_OBJ_NAME_PTR(attr_idx));
12703 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX", PDG_AT_IDX(attr_idx));
12704 PDG_DBG_PRINT_LLO("(2) flags", label_flag);
12705 PDG_DBG_PRINT_D("(3) line num", IR_LINE_NUM(ir_idx));
12706 PDG_DBG_PRINT_D("(4) suppress cnt", suppress_cnt);
12707 PDG_DBG_PRINT_D("(5) keepme", keepme);
12708 PDG_DBG_PRINT_LVD("(7) safevl", (ATL_IVDEP(attr_idx)?
12709 (long) CN_INT_TO_C(safevl_idx):0));
12710 PDG_DBG_PRINT_LVD("(8) unroll cnt", ((ATL_UNROLL_DIR(attr_idx)) ?
12711 (long) CN_INT_TO_C(unroll_idx) : 1));
12712 PDG_DBG_PRINT_S("(9) mark name", mark_name_idx == NULL_IDX ? " " :
12713 (char *)&CN_CONST(mark_name_idx));
12714 PDG_DBG_PRINT_D("(10) cache bypass ct", cache_bypass_count);
12715 PDG_DBG_PRINT_LVD("(11) safe distance", (safe_distance_idx != NULL_IDX ?
12716 (long) CN_INT_TO_C(safe_distance_idx):0));
12717 PDG_DBG_PRINT_LVD("(12) blockable grp", (blockable_idx != NULL_IDX ?
12718 (long) CN_INT_TO_C(blockable_idx):0));
12719 PDG_DBG_PRINT_LVD("(13) interchange grp", (interchange_idx != NULL_IDX ?
12720 (long) CN_INT_TO_C(interchange_idx):0));
12721 PDG_DBG_PRINT_LVD("(13) interchange lvl",(interchange_level_idx != NULL_IDX?
12722 (long) CN_INT_TO_C(interchange_level_idx):0));
12723 PDG_DBG_PRINT_END
12724
12725 # ifdef _ENABLE_FEI
12726 fei_label_def_named(PDG_AT_IDX(attr_idx),
12727 label_flag,
12728 IR_LINE_NUM(ir_idx),
12729 suppress_cnt,
12730 keepme,
12731 0,
12732 (ATL_IVDEP(attr_idx) ?
12733 (long) CN_INT_TO_C(safevl_idx) : 0),
12734 (ATL_UNROLL_DIR(attr_idx)) ?
12735 (long) CN_INT_TO_C(unroll_idx) : 1,
12736 mark_name_idx == NULL_IDX ? NULL :
12737 (char *) &CN_CONST(mark_name_idx),
12738 cache_bypass_count,
12739 (safe_distance_idx != NULL_IDX) ?
12740 (long) CN_INT_TO_C(safe_distance_idx) : 0,
12741 (blockable_idx != NULL_IDX) ?
12742 (long) CN_INT_TO_C(blockable_idx) : 0,
12743 (interchange_idx != NULL_IDX) ?
12744 (long) CN_INT_TO_C(interchange_idx) : 0,
12745 (interchange_level_idx != NULL_IDX) ?
12746 (long) CN_INT_TO_C(interchange_level_idx) : 0);
12747 # endif
12748
12749 TRACE (Func_Exit, "send_label_def", NULL);
12750
12751 return;
12752
12753 }
12754
12755
12756
12757
12758
12759
12760
12761
12762
12763
12764
12765
12766
12767
12768
12769
12770
12771 static void send_namelist_group(int ng_attr_idx)
12772
12773 {
12774 int attr_idx;
12775 int count;
12776 int name_idx;
12777 long prev_idx;
12778 int sn_idx;
12779
12780
12781 TRACE (Func_Entry, "send_namelist_group", NULL);
12782
12783
12784 PDG_DBG_PRINT_START
12785 PDG_DBG_PRINT_C("fei_next_name");
12786 PDG_DBG_PRINT_D("(1) logical", TRUE);
12787 PDG_DBG_PRINT_END
12788
12789 # ifdef _ENABLE_FEI
12790 name_idx = fei_next_name(TRUE);
12791 # endif
12792
12793 prev_idx = NULL_IDX;
12794 sn_idx = ATN_FIRST_NAMELIST_IDX(ng_attr_idx);
12795 count = 0;
12796
12797 do {
12798 attr_idx = SN_ATTR_IDX(sn_idx);
12799 send_attr_ntry(attr_idx);
12800
12801 PDG_DBG_PRINT_START
12802 PDG_DBG_PRINT_C("fei_name");
12803 PDG_DBG_PRINT_S("(1) AT_OBJ_NAME", AT_OBJ_NAME_PTR(attr_idx));
12804 PDG_DBG_PRINT_S("(2) table", "PDGCS_Namelist");
12805 PDG_DBG_PRINT_LD("(3) PDG_AT_IDX", PDG_AT_IDX(attr_idx));
12806 PDG_DBG_PRINT_LD("(4) prev_idx", prev_idx);
12807 PDG_DBG_PRINT_D("(5) name_idx", name_idx);
12808 PDG_DBG_PRINT_END
12809
12810 # ifdef _ENABLE_FEI
12811 prev_idx = fei_name(AT_OBJ_NAME_PTR(attr_idx),
12812 Sym_Namelist,
12813 PDG_AT_IDX(attr_idx),
12814 prev_idx,
12815 name_idx);
12816 # endif
12817
12818 count = count + 1;
12819 sn_idx = SN_SIBLING_LINK(sn_idx);
12820
12821 if (sn_idx != NULL_IDX) {
12822 PDG_DBG_PRINT_START
12823 PDG_DBG_PRINT_C("fei_next_name");
12824 PDG_DBG_PRINT_D("(1) logical", TRUE);
12825 PDG_DBG_PRINT_END
12826
12827 # ifdef _ENABLE_FEI
12828 name_idx = fei_next_name(TRUE);
12829 # endif
12830 }
12831 } while (sn_idx != NULL_IDX);
12832
12833 PDG_DBG_PRINT_START
12834 PDG_DBG_PRINT_C("fei_namelist");
12835 PDG_DBG_PRINT_S("(1) AT_OBJ_NAME", AT_OBJ_NAME_PTR(ng_attr_idx));
12836 PDG_DBG_PRINT_D("(2) count", count);
12837 PDG_DBG_PRINT_LD("(3) prev_idx", prev_idx);
12838 PDG_DBG_PRINT_END
12839
12840 # ifdef _ENABLE_FEI
12841 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
12842 PDG_AT_IDX(ng_attr_idx) = fei_namelist(AT_OBJ_NAME_PTR(ng_attr_idx),
12843 count,
12844 prev_idx);
12845 # endif
12846 # endif
12847
12848 TRACE (Func_Exit, "send_namelist_group", NULL);
12849
12850 return;
12851
12852 }
12853
12854
12855
12856
12857
12858
12859
12860
12861
12862
12863
12864
12865
12866
12867
12868
12869 static void allocate_pdg_link_tbls(void)
12870
12871 {
12872 register int i;
12873 int new_size;
12874 long *pdg_tbl_base;
12875
12876
12877 TRACE (Func_Entry, "allocate_pdg_link_tbls", NULL);
12878
12879
12880
12881
12882 new_size = (attr_tbl_idx > const_tbl_idx) ? attr_tbl_idx : const_tbl_idx;
12883 new_size = (new_size > stor_blk_tbl_idx) ? new_size : stor_blk_tbl_idx;
12884 new_size = (new_size > type_tbl_idx) ? new_size : type_tbl_idx;
12885
12886 new_size++;
12887
12888 CHECK_TBL_ALLOC_SIZE(pdg_link_tbl, new_size);
12889 pdg_link_tbl_idx = pdg_link_tbl_size - 1;
12890 pdg_tbl_base = (long *) pdg_link_tbl;
12891
12892 for (i = 0; i < (pdg_link_tbl_size * NUM_PDG_WDS); i++) {
12893 pdg_tbl_base[i] = 0;
12894 }
12895
12896 new_size = type_tbl_idx + 1;
12897
12898 CHECK_TBL_ALLOC_SIZE(pdg_type_tbl, new_size);
12899 pdg_type_tbl_idx = pdg_type_tbl_size - 1;
12900 pdg_tbl_base = (long *) pdg_type_tbl;
12901
12902 for (i = 0; i < (pdg_type_tbl_size * NUM_PDG_TYP_WDS); i++) {
12903 pdg_tbl_base[i] = 0;
12904 }
12905
12906
12907 TRACE (Func_Exit, "allocate_pdg_link_tbls", NULL);
12908
12909 return;
12910
12911 }
12912
12913
12914
12915
12916
12917
12918
12919
12920
12921
12922
12923
12924
12925
12926
12927
12928
12929 static void send_attr_ntry(int attr_idx)
12930
12931 {
12932 char str[3000];
12933 int len;
12934 # if defined(_TARGET32)
12935 int align = HWord_Align;
12936 # else
12937 int align = Word_Align;
12938 # endif
12939 TYPE basic;
12940 long64 bit_len = 0;
12941 int class = 0;
12942 int const_idx;
12943
12944
12945
12946 long_type constant[2];
12947 int constant_class;
12948 long64 flag;
12949 int i;
12950 int il_idx;
12951 int al_idx;
12952 int defining_attr = NULL_IDX;
12953 int dv_alias = NULL_IDX;
12954 int intent = Intent_Unseen;
12955 long io_type_code_pdg_idx = NULL_IDX;
12956 long64 offset = 0;
12957 int ptr_align = 0;
12958 long ptr_idx = NULL_IDX;
12959 int sb_idx = NULL_IDX;
12960 int child_idx = NULL_IDX;
12961 size_offset_type size;
12962 int sn_idx;
12963 int save_pdg_cn_const;
12964 boolean save_sym_constant_expr;
12965 boolean sym_offset = FALSE;
12966 TYPE type_idx;
12967
12968 # ifdef _TARGET_OS_MAX
12969 long_type ii;
12970 # endif
12971
12972
12973 TRACE (Func_Entry, "send_attr_ntry", NULL);
12974
12975 flag = (long64) 0;
12976
12977 if (PDG_AT_IDX(attr_idx) != NULL_IDX) {
12978 goto EXIT;
12979 }
12980
12981 if (!AT_IGNORE_ATTR_LINK(attr_idx)) {
12982
12983 if (AT_ATTR_LINK(attr_idx) != NULL_IDX) {
12984 child_idx = attr_idx;
12985
12986 while (AT_ATTR_LINK(attr_idx) != NULL_IDX) {
12987 attr_idx = AT_ATTR_LINK(attr_idx);
12988 }
12989
12990 if (PDG_AT_IDX(attr_idx) != NULL_IDX) {
12991 PDG_AT_IDX(child_idx) = PDG_AT_IDX(attr_idx);
12992 goto EXIT;
12993 }
12994 }
12995 }
12996
12997
12998 switch (AT_OBJ_CLASS(attr_idx)) {
12999 case Data_Obj:
13000
13001 switch (ATD_CLASS(attr_idx)) {
13002
13003 case Variable:
13004 # ifdef _TARGET_OS_MAX
13005
13006 if (ATD_SYMBOLIC_CONSTANT(attr_idx)) {
13007 goto EXIT;
13008 }
13009 # endif
13010
13011 if (ATD_FLD(attr_idx) != NO_Tbl_Idx) {
13012
13013
13014
13015 if (ATD_FLD(attr_idx) == AT_Tbl_Idx) {
13016 send_attr_ntry(ATD_VARIABLE_TMP_IDX(attr_idx));
13017 }
13018 else if (ATD_FLD(attr_idx) == IL_Tbl_Idx) {
13019 il_idx = ATD_VARIABLE_TMP_IDX(attr_idx);
13020
13021 while (il_idx != NULL_IDX) {
13022 send_attr_ntry(IL_IDX(il_idx));
13023 il_idx = IL_NEXT_LIST_IDX(il_idx);
13024 }
13025 }
13026 }
13027
13028
13029
13030 case Atd_Unknown:
13031 class = User_Variable;
13032
13033 if (ATD_AUTOMATIC(attr_idx)) {
13034 send_attr_ntry(ATD_AUTO_BASE_IDX(attr_idx));
13035 offset = (long64) PDG_AT_IDX(ATD_AUTO_BASE_IDX(attr_idx));
13036 }
13037 break;
13038
13039 case CRI__Pointee:
13040 class = CRI_Pointee;
13041 send_attr_ntry(ATD_PTR_IDX(attr_idx));
13042 ptr_idx = PDG_AT_IDX(ATD_PTR_IDX(attr_idx));
13043 break;
13044
13045 case Function_Result:
13046 if (SB_BLK_TYPE(ATD_STOR_BLK_IDX(attr_idx)) == Formal) {
13047
13048
13049
13050 intent = Intent_Out;
13051 class = Dummy_Arg;
13052 flag = flag | ((long64) 1 << FEI_OBJECT_RESULT_TEMP);
13053 }
13054 else {
13055 class = Function_Rslt;
13056 flag = flag | ((long64) AT_HOST_ASSOCIATED(attr_idx) <<
13057 FEI_OBJECT_RESULT_TEMP);
13058 }
13059 break;
13060
13061 case Dummy_Argument:
13062 # ifdef _NAME_SUBSTITUTION_INLINING
13063 if (!AT_IS_DARG(attr_idx)) {
13064 goto EXIT;
13065 }
13066 # endif
13067
13068 class = Dummy_Arg;
13069 flag = flag | ((long64) ATD_SF_DARG(attr_idx) << FEI_OBJECT_SF_DARG);
13070 flag = flag | ((long64) AT_OPTIONAL(attr_idx) << FEI_OBJECT_OPTIONAL);
13071
13072 intent = ATD_INTENT(attr_idx);
13073 if (intent == Intent_Unseen) {
13074 intent = Intent_Inout;
13075 }
13076 break;
13077
13078 case Compiler_Tmp:
13079 if (ATD_SYMBOLIC_CONSTANT(attr_idx)) {
13080
13081
13082
13083 save_sym_constant_expr = symbolic_constant_expr;
13084 symbolic_constant_expr = TRUE;
13085
13086 if (ATD_FLD(attr_idx) == IR_Tbl_Idx &&
13087 IR_OPR(ATD_TMP_IDX(attr_idx)) == Asg_Opr) {
13088 cvrt_exp_to_pdg(IR_IDX_R(ATD_TMP_IDX(attr_idx)),
13089 IR_FLD_R(ATD_TMP_IDX(attr_idx)));
13090 }
13091 else {
13092 cvrt_exp_to_pdg(ATD_TMP_IDX(attr_idx),
13093 (fld_type) ATD_FLD(attr_idx));
13094 }
13095
13096 PDG_DBG_PRINT_START
13097 PDG_DBG_PRINT_C("npex_end");
13098 PDG_DBG_PRINT_END
13099
13100 # ifdef _ENABLE_FEI
13101 PDG_AT_IDX(attr_idx) = npex_end();
13102 # endif
13103 PDG_DBG_PRINT_START
13104 PDG_DBG_PRINT_LD("(r) PDG_AT_IDX", PDG_AT_IDX(attr_idx));
13105 PDG_DBG_PRINT_END
13106
13107 symbolic_constant_expr = save_sym_constant_expr;
13108 goto EXIT;
13109 }
13110
13111 class = Compiler_Temp;
13112
13113 if (ATD_AUTOMATIC(attr_idx)) {
13114 send_attr_ntry(ATD_AUTO_BASE_IDX(attr_idx));
13115 offset = (long64) PDG_AT_IDX(ATD_AUTO_BASE_IDX(attr_idx));
13116 }
13117
13118 # if ! (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN)) && ! defined(_TARGET_OS_MAX)
13119 if (ATD_DEFINING_ATTR_IDX(attr_idx) != NULL_IDX) {
13120 send_attr_ntry(ATD_DEFINING_ATTR_IDX(attr_idx));
13121 defining_attr = PDG_AT_IDX(ATD_DEFINING_ATTR_IDX(attr_idx));
13122 }
13123 # endif
13124 break;
13125
13126 case Constant:
13127 if (ATD_FLD(attr_idx) == AT_Tbl_Idx) {
13128
13129
13130
13131 ATD_CLASS(ATD_CONST_IDX(attr_idx)) = Variable;
13132 send_attr_ntry(ATD_CONST_IDX(attr_idx));
13133 ATD_CLASS(ATD_CONST_IDX(attr_idx)) = Compiler_Tmp;
13134 goto EXIT;
13135 }
13136
13137 if (cmd_line_flags.debug_lvl > Debug_Lvl_2 &&
13138 !cmd_line_flags.dwarf_debug) {
13139 goto EXIT;
13140 }
13141
13142 if (AT_COMPILER_GEND(attr_idx)) {
13143 goto EXIT;
13144 }
13145
13146
13147
13148
13149 const_idx = ATD_CONST_IDX(attr_idx);
13150 type_idx = get_basic_type(ATD_TYPE_IDX(attr_idx),
13151 ATD_ALIGNMENT(attr_idx),
13152 attr_idx);
13153 constant_class = 1;
13154
13155 if (TYP_TYPE(ATD_TYPE_IDX(attr_idx)) == Character) {
13156 constant_class = 3;
13157 bit_len = CN_INT_TO_C(TYP_IDX(CN_TYPE_IDX(const_idx)));
13158 bit_len = bit_len * CHAR_BIT;
13159 }
13160 else if (TYP_LINEAR(ATD_TYPE_IDX(attr_idx)) == Long_Typeless) {
13161 constant_class = Pattern_Const;
13162 bit_len = TYP_BIT_LEN(CN_TYPE_IDX(const_idx));
13163 }
13164
13165 if (PDG_CN_IDX(const_idx) == 0) {
13166 if (bit_len == 0 && TYP_TYPE(ATD_TYPE_IDX(attr_idx)) != Character) {
13167 PDG_DBG_PRINT_START
13168 PDG_DBG_PRINT_C("fei_arith_con");
13169 PDG_DBG_PRINT_T("(1) type", type_idx);
13170 #if defined(_HOST32) && defined(_TARGET64)
13171 PDG_DBG_PRINT_VD("(2) const", CN_CONST(const_idx));
13172 #else
13173 PDG_DBG_PRINT_LVD("(2) const", CN_CONST(const_idx));
13174 #endif
13175 PDG_DBG_PRINT_END
13176
13177 # ifdef _ENABLE_FEI
13178 # ifdef _TARGET_OS_MAX
13179 if (TYP_LINEAR(CN_TYPE_IDX(const_idx)) == Complex_4) {
13180
13181 ii = CN_CONST(const_idx) << 32;
13182 ii |= CP_CONSTANT(CN_POOL_IDX(const_idx) + 1);
13183
13184 PDG_CN_IDX(const_idx) = fei_arith_con(type_idx, (long *)&ii);
13185 }
13186 else {
13187 PDG_CN_IDX(const_idx) = fei_arith_con(type_idx,
13188 (long *)&CN_CONST(const_idx));
13189 }
13190 # else
13191 PDG_CN_IDX(const_idx) = fei_arith_con(type_idx,
13192 (long *)&CN_CONST(const_idx));
13193 # endif
13194 # endif
13195 PDG_DBG_PRINT_START
13196 PDG_DBG_PRINT_LD("(r) PDG_CN_IDX", PDG_CN_IDX(const_idx));
13197 PDG_DBG_PRINT_END
13198 }
13199 else {
13200 PDG_DBG_PRINT_START
13201 PDG_DBG_PRINT_C("fei_pattern_con");
13202 PDG_DBG_PRINT_T("(1) type", type_idx);
13203 #if defined(_HOST32) && defined(_TARGET64)
13204 PDG_DBG_PRINT_VD("(2) const", CN_CONST(const_idx));
13205 #else
13206 PDG_DBG_PRINT_LVD("(2) const", CN_CONST(const_idx));
13207 #endif
13208 PDG_DBG_PRINT_LLD("(3) bit length", bit_len);
13209 PDG_DBG_PRINT_END
13210
13211 # ifdef _ENABLE_FEI
13212 PDG_CN_IDX(const_idx) = fei_pattern_con(type_idx,
13213 (char *)&CN_CONST(const_idx),
13214 bit_len);
13215 # endif
13216 PDG_DBG_PRINT_START
13217 PDG_DBG_PRINT_LD("(r) PDG_CN_IDX", PDG_CN_IDX(const_idx));
13218 PDG_DBG_PRINT_END
13219 }
13220 save_pdg_cn_const = 0;
13221 }
13222 else {
13223 save_pdg_cn_const = PDG_CN_IDX(const_idx);
13224 }
13225
13226
13227 PDG_DBG_PRINT_START
13228 PDG_DBG_PRINT_C("fei_smt_parameter");
13229 PDG_DBG_PRINT_S("(1) AT_OBJ_NAME", AT_OBJ_NAME_PTR(attr_idx));
13230 PDG_DBG_PRINT_T("(2) type", type_idx);
13231 PDG_DBG_PRINT_LD("(3) PDG_CN_IDX", PDG_CN_IDX(const_idx));
13232 PDG_DBG_PRINT_D("(4) constant_class", constant_class);
13233 PDG_DBG_PRINT_D("(5) line num", AT_DEF_LINE(attr_idx));
13234 PDG_DBG_PRINT_END
13235
13236 # ifdef _ENABLE_FEI
13237 fei_smt_parameter(AT_OBJ_NAME_PTR(attr_idx),
13238 type_idx,
13239 PDG_CN_IDX(const_idx),
13240 constant_class,
13241 AT_DEF_LINE(attr_idx));
13242 # endif
13243
13244 if (cmd_line_flags.dwarf_debug) {
13245 PDG_CN_IDX(const_idx) = save_pdg_cn_const;
13246 }
13247 goto EXIT;
13248
13249 case Struct_Component:
13250 class = Component;
13251 offset = CN_INT_TO_C(ATD_CPNT_OFFSET_IDX(attr_idx));
13252 break;
13253
13254 }
13255
13256 if (ATD_OFFSET_ASSIGNED(attr_idx) &&
13257 ATD_CLASS(attr_idx) != Struct_Component) {
13258
13259 if (ATD_OFFSET_FLD(attr_idx) == CN_Tbl_Idx) {
13260 offset = CN_INT_TO_C(ATD_OFFSET_IDX(attr_idx));
13261
13262 # if defined(_TARGET_OS_MAX) || defined(_HOST32)
13263 # ifdef KEY
13264 if (TYP_LINEAR(CN_TYPE_IDX(ATD_OFFSET_IDX(attr_idx))) == Integer_4 && offset != 0){
13265 offset = (unsigned)offset;
13266 }
13267 else if (TYP_LINEAR(CN_TYPE_IDX(ATD_OFFSET_IDX(attr_idx))) != Integer_8){
13268 SIGN_EXTEND(offset);
13269 }
13270 # else
13271 if (TYP_LINEAR(CN_TYPE_IDX(ATD_OFFSET_IDX(attr_idx))) != Integer_8){
13272 SIGN_EXTEND(offset);
13273 }
13274 # endif
13275 # endif
13276 }
13277 else if (ATD_OFFSET_FLD(attr_idx) == AT_Tbl_Idx) {
13278 send_attr_ntry(ATD_OFFSET_IDX(attr_idx));
13279 sym_offset = TRUE;
13280 offset = (long64) PDG_AT_IDX(ATD_OFFSET_IDX(attr_idx));
13281 }
13282 else {
13283 PRINTMSG(AT_DEF_LINE(attr_idx), 1213, Internal,
13284 AT_DEF_COLUMN(attr_idx),
13285 "ATD_OFFSET_IDX", AT_OBJ_NAME_PTR(attr_idx));
13286 }
13287 }
13288
13289
13290 size = stor_bit_size_of(attr_idx, FALSE, FALSE);
13291
13292 if (size.fld == CN_Tbl_Idx) {
13293 bit_len = CN_INT_TO_C(size.idx);
13294 }
13295 else {
13296 bit_len = F_INT_TO_C(size.constant, TYP_LINEAR(size.type_idx));
13297 }
13298
13299 sb_idx = ATD_STOR_BLK_IDX(attr_idx);
13300
13301 if (SB_BLK_TYPE(sb_idx) == Based &&
13302 child_idx != NULL_IDX &&
13303 !ATD_AUTOMATIC(attr_idx)) {
13304 sb_idx = ATD_STOR_BLK_IDX(child_idx);
13305 }
13306
13307 send_stor_blk(sb_idx, &class);
13308
13309 # if (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN))
13310 if (ATD_CLASS(attr_idx) == Compiler_Tmp) {
13311 if (sb_idx != NULL_IDX &&
13312 SB_SCP_IDX(sb_idx) != NULL_IDX &&
13313 SB_SCP_IDX(sb_idx) != curr_scp_idx &&
13314 (!SB_HOSTED_STATIC(sb_idx))) {
13315 class = Hosted_Compiler_Temp;
13316 }
13317 }
13318 # endif
13319
13320 type_idx = get_type_desc(attr_idx);
13321
13322 if (TYP_TYPE(ATD_TYPE_IDX(attr_idx)) == CRI_Ptr) {
13323 ptr_align = Word_Align;
13324
13325 # if defined(_TARGET32)
13326 if (TYP_PTR_INCREMENT(ATD_TYPE_IDX(attr_idx)) == TARGET_BITS_PER_WORD){
13327 ptr_align = HWord_Align;
13328 }
13329 # endif
13330 }
13331 else if (TYP_TYPE(ATD_TYPE_IDX(attr_idx)) == CRI_Ch_Ptr) {
13332 ptr_align = Byte_Align;
13333 }
13334 else {
13335 ptr_align = 0;
13336
13337 if (TYP_TYPE(ATD_TYPE_IDX(attr_idx)) == Character) {
13338
13339 if (ATD_IN_COMMON(attr_idx) ||
13340 ATD_CLASS(attr_idx) == Struct_Component ||
13341 ATD_CLASS(attr_idx) == Function_Result) {
13342 align = Byte_Align;
13343 }
13344 }
13345 else if (ATD_CLASS(attr_idx) == Function_Result &&
13346 TYP_TYPE(ATD_TYPE_IDX(attr_idx)) == Structure) {
13347 align = (ATT_CHAR_SEQ(TYP_IDX(ATD_TYPE_IDX(attr_idx)))) ?
13348 Byte_Align : Word_Align;
13349 }
13350 else if (TYP_TYPE(ATD_TYPE_IDX(attr_idx)) == Structure) {
13351 align = pdg_align[ATT_ALIGNMENT(TYP_IDX(ATD_TYPE_IDX(attr_idx)))];
13352 }
13353 # if defined(_ALIGN_REAL16_TO_16_BYTES)
13354
13355 else if (TYP_LINEAR(ATD_TYPE_IDX(attr_idx)) == Complex_16 ||
13356 TYP_LINEAR(ATD_TYPE_IDX(attr_idx)) == Real_16) {
13357 align = FWord_Align;
13358 }
13359 # endif
13360
13361 # if defined(_INTEGER_1_AND_2)
13362 else if (on_off_flags.integer_1_and_2 &&
13363 PACK_8_BIT_TEST_CONDITION(ATD_TYPE_IDX(attr_idx))) {
13364 align = 8;
13365 }
13366 else if (on_off_flags.integer_1_and_2 &&
13367 PACK_16_BIT_TEST_CONDITION(ATD_TYPE_IDX(attr_idx))) {
13368 align = 16;
13369 }
13370 # endif
13371
13372 # if defined(_TARGET_PACK_HALF_WORD_TYPES)
13373
13374
13375
13376
13377 else if (PACK_HALF_WORD_TEST_CONDITION(ATD_TYPE_IDX(attr_idx))) {
13378 align = HWord_Align;
13379 }
13380 # endif
13381 }
13382
13383 if (ATD_CLASS(attr_idx) == Variable ||
13384 ATD_CLASS(attr_idx) == Dummy_Argument ||
13385 ATD_CLASS(attr_idx) == Function_Result ||
13386 ATD_CLASS(attr_idx) == Struct_Component ||
13387 ATD_CLASS(attr_idx) == Compiler_Tmp ||
13388 ATD_CLASS(attr_idx) == CRI__Pointee) {
13389
13390 make_io_type_code(ATD_TYPE_IDX(attr_idx), constant);
13391 basic = get_basic_type(IO_TYPE_CODE_TYPE,
13392 type_alignment_tbl[IO_TYPE_CODE_TYPE],
13393 NULL_IDX);
13394
13395 PDG_DBG_PRINT_START
13396 PDG_DBG_PRINT_C("fei_arith_con");
13397 PDG_DBG_PRINT_T("(1) type", basic);
13398 #if defined(_HOST32) && defined(_TARGET64)
13399 PDG_DBG_PRINT_VD("(2) value", constant[0]);
13400 #else
13401 PDG_DBG_PRINT_LVD("(2) value", constant[0]);
13402 #endif
13403 PDG_DBG_PRINT_END
13404
13405 # ifdef _ENABLE_FEI
13406 io_type_code_pdg_idx = fei_arith_con(basic,
13407 (long *)constant);
13408 # endif
13409 PDG_DBG_PRINT_START
13410 PDG_DBG_PRINT_LD("(r) PDG_CN_IDX", io_type_code_pdg_idx);
13411 PDG_DBG_PRINT_END
13412 }
13413
13414 if (ATD_ARRAY_IDX(attr_idx) != NULL_IDX) {
13415 switch (BD_ARRAY_CLASS(ATD_ARRAY_IDX(attr_idx))) {
13416 case Assumed_Size:
13417 flag = flag | ((long64) 1 << FEI_OBJECT_ASSUMED_SIZE);
13418 break;
13419
13420 case Assumed_Shape:
13421 flag = flag | ((long64) 1 << FEI_OBJECT_ASSUMD_SHAPE);
13422 break;
13423 }
13424 }
13425
13426 # ifdef _TARGET_OS_MAX
13427 if ((ATD_CLASS(attr_idx) != Compiler_Tmp &&
13428 ATD_CACHE_ALIGN(attr_idx)) ||
13429 (ATD_STOR_BLK_IDX(attr_idx) != NULL_IDX &&
13430 SB_CACHE_ALIGN(ATD_STOR_BLK_IDX(attr_idx)))) {
13431
13432 flag = flag | ((long64) 1 << FEI_OBJECT_CACHE_ALIGN);
13433 }
13434 # endif
13435
13436 if (ATD_IM_A_DOPE(attr_idx) &&
13437 ATD_DV_ALIAS(attr_idx) != NULL_IDX) {
13438 send_attr_ntry(AL_ATTR_IDX(ATD_DV_ALIAS(attr_idx)));
13439 dv_alias = PDG_AT_IDX(AL_ATTR_IDX(ATD_DV_ALIAS(attr_idx)));
13440
13441 al_idx = AL_NEXT_IDX(ATD_DV_ALIAS(attr_idx));
13442 if (al_idx != NULL_IDX) {
13443 send_attr_ntry(AL_ATTR_IDX(al_idx));
13444 ptr_idx = PDG_AT_IDX(AL_ATTR_IDX(al_idx));
13445 }
13446 }
13447
13448 if (SB_DEF_MULT_SCPS(sb_idx)) {
13449 ATD_EQUIV(attr_idx) = TRUE;
13450 }
13451
13452 flag = (flag |
13453 ((long64) ATD_TARGET(attr_idx) << FEI_OBJECT_TARGET) |
13454 ((long64) ATD_EQUIV(attr_idx) << FEI_OBJECT_EQUIV) |
13455 ((long64) ATD_SAVED(attr_idx) << FEI_OBJECT_SAVED) |
13456 ((long64) ATD_ALLOCATABLE(attr_idx) << FEI_OBJECT_ALLOCATE) |
13457 ((long64) ATD_OFFSET_ASSIGNED(attr_idx) << FEI_OBJECT_OFF_ASSIGNED) |
13458 ((long64) sym_offset << FEI_OBJECT_SYMCON_OFFST) |
13459 ((long64) ATD_AUXILIARY(attr_idx) << FEI_OBJECT_AUXILIARY) |
13460 ((long64) ATD_DATA_INIT(attr_idx) << FEI_OBJECT_INITIALD) |
13461 ((long64) AT_DEFINED(attr_idx) << FEI_OBJECT_DEFINED) |
13462 ((long64) AT_REF_IN_CHILD(attr_idx) << FEI_OBJECT_INNER_REF) |
13463 ((long64) AT_DEF_IN_CHILD(attr_idx) << FEI_OBJECT_INNER_DEF) |
13464 ((long64) ATD_POINTER(attr_idx) << FEI_OBJECT_DV_IS_PTR) |
13465 ((long64) ATD_IM_A_DOPE(attr_idx) << FEI_OBJECT_IS_DOPE_VEC) |
13466 ((long64) ATD_IN_COMMON(attr_idx) << FEI_OBJECT_IN_COMMON) |
13467 ((long64) ATD_PERMUTATION(attr_idx) << FEI_OBJECT_PERMUTATION) |
13468 ((long64) ATD_SYMMETRIC(attr_idx) << FEI_OBJECT_SYMMETRIC) |
13469 ((long64) ATD_PTR_ASSIGNED(attr_idx) << FEI_OBJECT_PTR_ASSIGNED) |
13470 ((long64) AT_ACTUAL_ARG(attr_idx) << FEI_OBJECT_ACTUAL_ARG) |
13471 ((long64) ATD_READ_ONLY_VAR(attr_idx) << FEI_OBJECT_READ_ONLY) |
13472 ((long64) ATD_NOT_PT_UNIQUE_MEM(attr_idx)
13473 << FEI_OBJECT_NOT_PT_TO_UNIQUE_MEM) |
13474 #ifdef KEY
13475 ((long64) (ATD_CLASS(attr_idx) == Dummy_Argument &&
13476 ATD_VALUE_ATTR(attr_idx)) << FEI_OBJECT_PASS_BY_VALUE) |
13477 #endif
13478 ((long64) AT_NAMELIST_OBJ(attr_idx) << FEI_OBJECT_NAMELIST_ITEM));
13479
13480
13481 if (ATD_CLASS(attr_idx) == Compiler_Tmp ||
13482 ATD_CLASS(attr_idx) == Variable) {
13483 flag = flag | ((long64) 1 << FEI_OBJECT_ADDRTAKEN);
13484 }
13485
13486 if (class == Component) {
13487 PDG_DBG_PRINT_START
13488 PDG_DBG_PRINT_C("fei_member");
13489 PDG_DBG_PRINT_S("(1) AT_OBJ_NAME", AT_OBJ_NAME_PTR(attr_idx));
13490 PDG_DBG_PRINT_T("(2) type", type_idx);
13491 PDG_DBG_PRINT_LLD("(3) offset", offset);
13492 PDG_DBG_PRINT_LLD("(4) bit_len", bit_len);
13493 PDG_DBG_PRINT_D("(5) storage align", align);
13494 PDG_DBG_PRINT_D("(6) AT_DEF_LINE", AT_DEF_LINE(attr_idx));
13495 PDG_DBG_PRINT_LLO("(7) flags", flag);
13496 PDG_DBG_PRINT_LD("(8) io descriptor", io_type_code_pdg_idx);
13497 PDG_DBG_PRINT_END
13498
13499 # ifdef _ENABLE_FEI
13500 PDG_AT_IDX(attr_idx) = fei_member(AT_OBJ_NAME_PTR(attr_idx),
13501 type_idx,
13502 offset,
13503 bit_len,
13504 align,
13505 AT_DEF_LINE(attr_idx),
13506 flag,
13507 io_type_code_pdg_idx);
13508 # endif
13509 }
13510 else {
13511
13512 # ifdef _DEBUG
13513
13514 if (dv_alias != NULL_IDX && defining_attr != NULL_IDX) {
13515 PRINTMSG(AT_DEF_LINE(attr_idx), 626, Internal,
13516 AT_DEF_COLUMN(attr_idx),
13517 "dv_alias or defining_attr",
13518 "send_attr_ntry");
13519 }
13520 # endif
13521
13522 # if ! (defined(_TARGET_OS_IRIX) || defined(_TARGET_OS_LINUX) || defined(_TARGET_OS_DARWIN)) && ! defined(_TARGET_OS_MAX)
13523 if (dv_alias == NULL_IDX) {
13524 dv_alias = defining_attr;
13525 }
13526 # endif
13527
13528
13529 if (class == Name && ATD_TMP_IDX(attr_idx) != NULL_IDX) {
13530 len = strlen((char *)&CN_CONST(ATD_TMP_IDX(attr_idx)));
13531 # ifdef _DEBUG
13532 if (len > 3000) {
13533 PRINTMSG(AT_DEF_LINE(attr_idx), 626, Internal,
13534 AT_DEF_COLUMN(attr_idx),
13535 "a valid length",
13536 "send_attr_ntry");
13537 }
13538 # endif
13539 strcpy(str, (char *)&CN_CONST(ATD_TMP_IDX(attr_idx)) );
13540 len = CN_INT_TO_C(TYP_IDX(CN_TYPE_IDX(ATD_TMP_IDX(attr_idx))));
13541 # ifdef _DEBUG
13542 if (len > 3000) {
13543 PRINTMSG(AT_DEF_LINE(attr_idx), 626, Internal,
13544 AT_DEF_COLUMN(attr_idx),
13545 "a valid length",
13546 "send_attr_ntry");
13547 }
13548 # endif
13549 str[len] = NULL_CHAR;
13550 }
13551
13552 PDG_DBG_PRINT_START
13553 PDG_DBG_PRINT_C("fei_object");
13554 PDG_DBG_PRINT_S("(1) AT_OBJ_NAME", AT_OBJ_NAME_PTR(attr_idx));
13555 PDG_DBG_PRINT_T("(2) type", type_idx);
13556 PDG_DBG_PRINT_LLO("(3) flags", flag);
13557 PDG_DBG_PRINT_S("(4) symbol class", p_obj_sym_class[class]);
13558 PDG_DBG_PRINT_S("(5) PDG_SB_IDX", SB_NAME_PTR(sb_idx));
13559 PDG_DBG_PRINT_D("(6) dv_alias", dv_alias);
13560 PDG_DBG_PRINT_LD("(7) ptr_idx", ptr_idx);
13561 PDG_DBG_PRINT_LLD("(8) offset", offset);
13562 PDG_DBG_PRINT_S("(9) intent", p_intent[intent]);
13563 PDG_DBG_PRINT_LLD("(10) bit_len", bit_len);
13564 PDG_DBG_PRINT_D("(11) pointee align", ptr_align);
13565 PDG_DBG_PRINT_D("(12) storage align", align);
13566 PDG_DBG_PRINT_D("(13) unused", 0);
13567 PDG_DBG_PRINT_LD("(14) io descriptor", io_type_code_pdg_idx);
13568 PDG_DBG_PRINT_D("(15) unused", 0);
13569 PDG_DBG_PRINT_D("(16) AT_DEF_LINE", AT_DEF_LINE(attr_idx));
13570 PDG_DBG_PRINT_END
13571
13572 # ifdef _ENABLE_FEI
13573 PDG_AT_IDX(attr_idx) = fei_object(class == Name ?
13574 str : AT_OBJ_NAME_PTR(attr_idx),
13575 type_idx,
13576 flag,
13577 class,
13578 PDG_SB_IDX(sb_idx),
13579 dv_alias,
13580 ptr_idx,
13581 offset,
13582 intent,
13583 bit_len,
13584 ptr_align,
13585 align,
13586 0,
13587 io_type_code_pdg_idx,
13588 0,
13589 AT_DEF_LINE(attr_idx));
13590 # endif
13591 }
13592
13593 PDG_DBG_PRINT_START
13594 PDG_DBG_PRINT_LD("(r) PDG_AT_IDX", PDG_AT_IDX(attr_idx));
13595 PDG_DBG_PRINT_END
13596 break;
13597
13598 case Pgm_Unit:
13599 if (PDG_AT_IDX(attr_idx) == NULL_IDX) {
13600
13601 send_procedure(attr_idx,
13602 NULL_IDX,
13603 Imported);
13604 }
13605 break;
13606
13607 case Label:
13608 send_label(attr_idx);
13609 break;
13610
13611 case Interface:
13612 if (ATP_PGM_UNIT(SCP_ATTR_IDX(curr_scp_idx)) != Module) {
13613
13614
13615
13616
13617
13618 if (ATI_PROC_IDX(attr_idx) != NULL_IDX &&
13619 PDG_AT_IDX(ATI_PROC_IDX(attr_idx)) == NULL_IDX) {
13620 send_procedure(ATI_PROC_IDX(attr_idx),
13621 NULL_IDX,
13622 Imported);
13623 }
13624
13625
13626
13627 if (cmd_line_flags.debug_lvl <= Debug_Lvl_2) {
13628 sn_idx = ATI_FIRST_SPECIFIC_IDX(attr_idx);
13629
13630 for (i = 0; i < ATI_NUM_SPECIFICS(attr_idx); i++) {
13631 if (AT_REFERENCED(SN_ATTR_IDX(sn_idx)) != Not_Referenced) {
13632 if (PDG_AT_IDX(SN_ATTR_IDX(sn_idx)) == NULL_IDX) {
13633 send_procedure(SN_ATTR_IDX(sn_idx),
13634 NULL_IDX,
13635 Imported);
13636 }
13637
13638 PDG_DBG_PRINT_START
13639 PDG_DBG_PRINT_C("fei_smt_actual_to_generic");
13640 PDG_DBG_PRINT_LD("(1) PDG_AT_IDX",
13641 PDG_AT_IDX(SN_ATTR_IDX(sn_idx)));
13642 PDG_DBG_PRINT_S("(2) AT_OBJ_NAME",
13643 AT_OBJ_NAME_PTR(attr_idx));
13644 PDG_DBG_PRINT_END
13645
13646 # ifdef _ENABLE_FEI
13647 fei_smt_actual_to_generic(PDG_AT_IDX(SN_ATTR_IDX(sn_idx)),
13648 AT_OBJ_NAME_PTR(attr_idx));
13649 # endif
13650 }
13651 sn_idx = SN_SIBLING_LINK(sn_idx);
13652 }
13653 }
13654 }
13655 break;
13656
13657 case Derived_Type:
13658
13659 goto EXIT;
13660
13661 case Namelist_Grp:
13662 if (ATP_PGM_UNIT(SCP_ATTR_IDX(curr_scp_idx)) != Module) {
13663 send_namelist_group(attr_idx);
13664 }
13665 break;
13666
13667 }
13668
13669 if (child_idx != NULL_IDX) {
13670 PDG_AT_IDX(child_idx) = PDG_AT_IDX(attr_idx);
13671 }
13672
13673 EXIT:
13674
13675 TRACE (Func_Exit, "send_attr_ntry", NULL);
13676
13677 return;
13678
13679 }
13680
13681
13682
13683
13684
13685
13686
13687
13688
13689
13690
13691
13692
13693
13694
13695
13696
13697
13698 static void send_mod_file_name (void)
13699
13700 {
13701 int fp_idx;
13702
13703 # if defined(_TARGET_OS_MAX) || defined(_TARGET_OS_UNICOS)
13704 long opt_flag;
13705 int pgm_code = 0;
13706 int pgm_data = 0;
13707 # endif
13708
13709
13710 TRACE (Func_Entry, "send_mod_file_name", NULL);
13711
13712 fp_idx = SCP_FILE_PATH_IDX(MAIN_SCP_IDX);
13713
13714 if (!FP_OUTPUT_TO_O(fp_idx)) {
13715 return;
13716 }
13717
13718
13719 # if defined(_TARGET_OS_MAX) || defined(_TARGET_OS_UNICOS)
13720
13721 CREATE_ID(TOKEN_ID(token), "@%%", 3);
13722 COPY_ATTR_NTRY(AT_WORK_IDX, SCP_ATTR_IDX(MAIN_SCP_IDX));
13723
13724 if (ATP_PGM_UNIT(AT_WORK_IDX) != Module) {
13725 CLEAR_VARIANT_ATTR_INFO(AT_WORK_IDX, Pgm_Unit);
13726 ATP_PGM_UNIT(AT_WORK_IDX) = Module;
13727 }
13728
13729 AT_CIF_SYMBOL_ID(AT_WORK_IDX) = 0;
13730 CLEAR_TBL_NTRY(name_pool, NULL_IDX);
13731
13732 name_pool[NULL_IDX].name_long = TOKEN_STR_WD(token, 0);
13733 AT_NAME_IDX(AT_WORK_IDX) = NULL_IDX;
13734 AT_NAME_LEN(AT_WORK_IDX) = 3;
13735 ATP_EXT_NAME_IDX(AT_WORK_IDX) = NULL_IDX;
13736 ATP_EXT_NAME_LEN(AT_WORK_IDX) = 3;
13737
13738 PDG_DBG_PRINT_START
13739 PDG_DBG_PRINT_C("fei_next_func_idx");
13740 PDG_DBG_PRINT_END
13741
13742 # ifdef _ENABLE_FEI
13743 PDG_AT_IDX(AT_WORK_IDX) = fei_next_func_idx(ATP_PGM_UNIT(AT_WORK_IDX),
13744 ATP_PROC(AT_WORK_IDX),
13745 ATP_ALT_ENTRY(AT_WORK_IDX));
13746 # endif
13747
13748 send_procedure(AT_WORK_IDX,
13749 NULL_IDX,
13750 Definition);
13751
13752 PDG_DBG_PRINT_START
13753 PDG_DBG_PRINT_C("PDGCS_comp_unit");
13754 PDG_DBG_PRINT_S("(1) AT_OBJ_NAME", AT_OBJ_NAME_PTR(AT_WORK_IDX));
13755 PDG_DBG_PRINT_D("(2) unused", 0);
13756 PDG_DBG_PRINT_END
13757
13758 PDGCS_comp_unit(AT_OBJ_NAME_PTR(AT_WORK_IDX), NULL_IDX);
13759
13760 opt_flag = ((long) opt_flags.aggress << PDGCS_NEW_PROC_IGNORE_THROTTLE)|
13761 ((long) opt_flags.pattern << PDGCS_NEW_PROC_PATTERN_MATCHING)|
13762 ((long) (cmd_line_flags.debug_lvl != Debug_Lvl_0)
13763 << PDGCS_NEW_PROC_ELIM_DEAD_CODE)|
13764 ((long) on_off_flags.reciprical_divide
13765 << PDGCS_NEW_PROC_IEEE_RECIPS)|
13766 ((long) cmd_line_flags.runtime_conformance
13767 << PDGCS_NEW_PROC_CONFORM_CHECK)|
13768 ((long) (opt_flags.task_lvl == Task_Lvl_3)
13769 << PDGCS_NEW_PROC_TASK_INNER_LOOPS)|
13770 ((long) cmd_line_flags.do_UDB_checks
13771 << PDGCS_NEW_PROC_DO_UBD_ANALYSIS);
13772
13773 PDG_DBG_PRINT_START
13774 PDG_DBG_PRINT_C("PDGCS_new_proc");
13775 PDG_DBG_PRINT_D("(1) num ir", 100);
13776 PDG_DBG_PRINT_D("(2) PDG_AT_IDX", PDG_AT_IDX(AT_WORK_IDX));
13777 PDG_DBG_PRINT_D("(3) alt entries", 0);
13778 PDG_DBG_PRINT_D("(4) scalar level", opt_flags.scalar_lvl);
13779 PDG_DBG_PRINT_D("(5) vector level", opt_flags.vector_lvl);
13780 PDG_DBG_PRINT_D("(6) task level", opt_flags.task_lvl);
13781 PDG_DBG_PRINT_O("(7) flags", opt_flag);
13782 PDG_DBG_PRINT_D("(8) user mobes", 0);
13783 PDG_DBG_PRINT_D("(9) user sades", 0);
13784 PDG_DBG_PRINT_D("(10) pipeline level", opt_flags.pipeline_lvl);
13785 PDG_DBG_PRINT_D("(11) stream level", opt_flags.stream_lvl);
13786 PDG_DBG_PRINT_END
13787
13788 PDGCS_new_proc(100,
13789 PDG_AT_IDX(AT_WORK_IDX),
13790 0,
13791 opt_flags.scalar_lvl,
13792 opt_flags.vector_lvl,
13793 opt_flags.task_lvl,
13794 opt_flag,
13795 0,
13796 0,
13797 opt_flags.pipeline_lvl,
13798 opt_flags.stream_lvl);
13799
13800 PDG_DBG_PRINT_START
13801 PDG_DBG_PRINT_C("PDGCS_do_proc");
13802
13803 # ifdef _DEBUG
13804 fflush(debug_file);
13805 # endif
13806
13807 PDG_DBG_PRINT_END
13808
13809 #ifdef KEY
13810 PDGCS_do_proc(1);
13811 #else
13812 PDGCS_do_proc();
13813 #endif
13814
13815 PDG_DBG_PRINT_START
13816 PDG_DBG_PRINT_C("PDGCS_end_procs");
13817 PDG_DBG_PRINT_D("(1) pgm code", pgm_code);
13818 PDG_DBG_PRINT_D("(2) pgm data", pgm_data);
13819 PDG_DBG_PRINT_END
13820
13821 PDGCS_end_procs(&pgm_code,
13822 &pgm_data);
13823
13824 create_mod_info_tbl();
13825 output_mod_info_file();
13826
13827 # endif
13828
13829 if (fp_idx != NULL_IDX) {
13830 PDG_DBG_PRINT_START
13831 PDG_DBG_PRINT_C("fei_module_file");
13832 PDG_DBG_PRINT_END
13833
13834 # ifdef _ENABLE_FEI
13835 fei_module_file(FP_NAME_PTR(fp_idx));
13836 # endif
13837 }
13838
13839 # if defined(_TARGET_OS_MAX) || defined(_TARGET_OS_UNICOS)
13840
13841 PDG_DBG_PRINT_START
13842 PDG_DBG_PRINT_C("PDGCS_end_comp_unit");
13843 PDG_DBG_PRINT_END
13844
13845 PDGCS_end_comp_unit();
13846
13847 # endif
13848
13849 TRACE (Func_Exit, "send_mod_file_name", NULL);
13850
13851 return;
13852
13853 }
13854
13855
13856
13857
13858
13859
13860
13861
13862
13863
13864
13865
13866
13867
13868
13869
13870
13871
13872 void terminate_PDGCS(void)
13873
13874 {
13875
13876 TRACE (Func_Entry, "terminate_PDGCS", NULL);
13877
13878 if (binary_output || assembly_output) {
13879 PDG_DBG_PRINT_START
13880 PDG_DBG_PRINT_C("PDGCS_terminate");
13881 PDG_DBG_PRINT_END
13882
13883 # ifdef _ENABLE_FEI
13884 PDGCS_terminate();
13885 # endif
13886 }
13887
13888 TRACE (Func_Exit, "terminate_PDGCS", NULL);
13889
13890 return;
13891
13892 }
13893
13894
13895
13896
13897
13898
13899
13900
13901
13902
13903
13904
13905
13906
13907
13908
13909
13910
13911
13912
13913
13914 static void send_darg_list(int pgm_attr_idx,
13915 int darg_pdg_sn_fw_idx)
13916
13917 {
13918 int attr_idx;
13919 int darg_idx;
13920 int end_idx;
13921 long prev_idx;
13922 int sn_idx;
13923
13924
13925 TRACE (Func_Entry, "send_darg_list", NULL);
13926
13927 prev_idx = NULL_IDX;
13928 darg_idx = darg_pdg_sn_fw_idx;
13929 end_idx = ATP_NUM_DARGS(pgm_attr_idx) + ATP_FIRST_IDX(pgm_attr_idx);
13930 sn_idx = ATP_FIRST_IDX(pgm_attr_idx);
13931
13932 do {
13933 attr_idx = SN_ATTR_IDX(sn_idx);
13934
13935 if (PDG_AT_IDX(attr_idx) == NULL_IDX) {
13936 if (AT_OBJ_CLASS(attr_idx) == Data_Obj) {
13937 send_attr_ntry(attr_idx);
13938 }
13939 else {
13940 send_dummy_procedure(attr_idx);
13941 }
13942 }
13943
13944 PDG_DBG_PRINT_START
13945 PDG_DBG_PRINT_C("fei_name");
13946 PDG_DBG_PRINT_S("(1) AT_OBJ_NAME", AT_OBJ_NAME_PTR(attr_idx));
13947 PDG_DBG_PRINT_S("(2) table", "PDGCS_Object");
13948 PDG_DBG_PRINT_LD("(3) PDG_AT_IDX", PDG_AT_IDX(attr_idx));
13949 PDG_DBG_PRINT_D("(4) prev_idx", prev_idx);
13950 PDG_DBG_PRINT_D("(5) darg_idx", darg_idx);
13951 PDG_DBG_PRINT_END
13952
13953
13954
13955 # ifdef _ENABLE_FEI
13956 prev_idx = fei_name(AT_OBJ_NAME_PTR(attr_idx),
13957 Sym_Object,
13958 PDG_AT_IDX(attr_idx),
13959 prev_idx,
13960 darg_idx);
13961 # endif
13962
13963 if (++sn_idx < end_idx) {
13964 PDG_DBG_PRINT_START
13965 PDG_DBG_PRINT_C("fei_next_name");
13966 PDG_DBG_PRINT_D("(1) logical", TRUE);
13967 PDG_DBG_PRINT_END
13968
13969 # ifdef _ENABLE_FEI
13970 darg_idx = fei_next_name(TRUE);
13971 # endif
13972 }
13973 }
13974 while (sn_idx != end_idx);
13975
13976 TRACE (Func_Exit, "send_darg_list", NULL);
13977
13978 return;
13979
13980 }
13981
13982
13983
13984
13985
13986
13987
13988
13989
13990
13991
13992
13993
13994
13995
13996
13997
13998
13999
14000
14001
14002 static TYPE send_non_standard_aligned_type(int align,
14003 int type_idx)
14004 {
14005 #ifdef KEY
14006 int aux_info = 0;
14007 int basic_type = 0;
14008 int bit_size = 0;
14009 #else
14010 int aux_info;
14011 int basic_type;
14012 int bit_size;
14013 #endif
14014 int flags = 0;
14015 TYPE pdg_type_idx;
14016
14017
14018 TRACE (Func_Entry, "send_non_standard_aligned_type", NULL);
14019
14020 switch (TYP_LINEAR(type_idx)) {
14021
14022 case Integer_1:
14023 bit_size = bit_size_tbl[Integer_1];
14024 basic_type = Integral;
14025 aux_info = 1;
14026 flags = 2;
14027 break;
14028
14029 case Integer_2:
14030 bit_size = bit_size_tbl[Integer_2];
14031 basic_type = Integral;
14032 aux_info = 2;
14033 flags = 2;
14034 break;
14035
14036 case Integer_4:
14037 bit_size = bit_size_tbl[Integer_4];
14038 basic_type = Integral;
14039 aux_info = 4;
14040 flags = 2;
14041 break;
14042
14043 case Integer_8:
14044 bit_size = bit_size_tbl[Integer_8];
14045 basic_type = Integral;
14046 aux_info = 8;
14047 flags = 2;
14048
14049 # ifdef _TARGET_HAS_FAST_INTEGER
14050 if (opt_flags.set_allfastint_option ||
14051 (opt_flags.set_fastint_option &&
14052 TYP_DESC(type_idx) == Default_Typed)) {
14053 bit_size = 46;
14054 aux_info = 6;
14055 }
14056 # endif
14057 break;
14058
14059 case Logical_1:
14060 bit_size = bit_size_tbl[Logical_1];
14061 basic_type = L_ogical;
14062 aux_info = 1;
14063 break;
14064
14065 case Logical_2:
14066 bit_size = bit_size_tbl[Logical_2];
14067 basic_type = L_ogical;
14068 aux_info = 2;
14069 break;
14070
14071 case Logical_4:
14072 bit_size = bit_size_tbl[Logical_4];
14073 basic_type = L_ogical;
14074 aux_info = 4;
14075 break;
14076
14077 case Logical_8:
14078 bit_size = bit_size_tbl[Logical_8];
14079 basic_type = L_ogical;
14080 aux_info = 8;
14081 break;
14082
14083 case Real_4:
14084 bit_size = bit_size_tbl[Real_4];
14085 basic_type = Floating_Pt;
14086 aux_info = 4;
14087 break;
14088
14089 case Real_8:
14090 bit_size = bit_size_tbl[Real_8];
14091 basic_type = Floating_Pt;
14092 aux_info = 8;
14093 break;
14094
14095 case Real_16:
14096 bit_size = bit_size_tbl[Real_16];
14097 basic_type = Floating_Pt;
14098 aux_info = 16;
14099 break;
14100
14101 case Complex_4:
14102 bit_size = bit_size_tbl[Complex_4];
14103 basic_type = C_omplex;
14104 aux_info = 4;
14105 break;
14106
14107 case Complex_8:
14108 bit_size = bit_size_tbl[Complex_8];
14109 basic_type = C_omplex;
14110 aux_info = 8;
14111 break;
14112
14113 case Complex_16:
14114 bit_size = bit_size_tbl[Complex_16];
14115 basic_type = C_omplex;
14116 aux_info = 16;
14117 break;
14118
14119 case CRI_Ch_Ptr_8:
14120 bit_size = bit_size_tbl[CRI_Ch_Ptr_8];
14121 basic_type = CRI_Pointer_Char;
14122 aux_info = 0;
14123 break;
14124
14125 default:
14126 PRINTMSG(stmt_start_line, 179, Internal, stmt_start_col,
14127 "send_non_standard_aligned_type");
14128 break;
14129 }
14130
14131 PDG_DBG_PRINT_START
14132 PDG_DBG_PRINT_C("fei_descriptor");
14133 PDG_DBG_PRINT_O("(1) flags", flags);
14134 PDG_DBG_PRINT_S("(2) table type", p_table_type[Basic]);
14135 PDG_DBG_PRINT_D("(3) bit_size", bit_size);
14136 PDG_DBG_PRINT_S("(4) basic type", p_basic_type[basic_type]);
14137 PDG_DBG_PRINT_D("(5) aux info", aux_info);
14138 PDG_DBG_PRINT_D("(6) alignment", pdg_align[align]);
14139 PDG_DBG_PRINT_END
14140 # ifdef _ENABLE_FEI
14141 pdg_type_idx = fei_descriptor(flags,
14142 Basic,
14143 bit_size,
14144 basic_type,
14145 aux_info,
14146 pdg_align[align]);
14147 # endif
14148 PDG_DBG_PRINT_START
14149 PDG_DBG_PRINT_T("(r) type", pdg_type_idx);
14150 PDG_DBG_PRINT_END
14151
14152 TRACE (Func_Exit, "send_non_standard_aligned_type", NULL);
14153
14154 return(pdg_type_idx);
14155
14156 }